HomePhabricator

[Cashtab] Prevent translation of address prefix

Description

[Cashtab] Prevent translation of address prefix

Summary:
T1894

Similar to D9785. Because Cashtab does not have localization, some users are using browser translation features to translate the entire app. This is particularly bad for the mnemonic field (already protected with this approach). However it also impacts the address itself.

This diff prevents the address prefix ecash: or etoken: from being translated by the browser.

This problem will not be properly solved until Cashtab has full localization, which will discourage users from using default browser translation features.

Test Plan:
npm start

Navigate to localhost:3000 in Google Chrome
Right click page and select Translate to... ... select Indonesian as this is where we get most of these bug reports
Verify that the address displayed still retains ecash: prefix and etoken: prefix when tokens are selected

Reviewers: #bitcoin_abc, PiRK

Reviewed By: #bitcoin_abc, PiRK

Differential Revision: https://reviews.bitcoinabc.org/D10259

Details

Provenance
Joey King <joseph.roy.king@gmail.com>Authored on Oct 5 2021, 21:35
bytesofmanPushed on Oct 6 2021, 17:40
Reviewer
Restricted Project
Differential Revision
D10259: [Cashtab] Prevent translation of address prefix
Parents
rABC3af59c095289: test: use OP_TRUE p2sh address in p2p_permissions
Branches
Unknown
Tags
Unknown