Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upLocalization of Payments FAQ text on about:payments #4102
Comments
|
@luixxiul if you think about the spans that are in place as tokens (instead of a block of text that must be translated as-is), you can already solve this without code changes: <span data-l10n-id='paymentsWelcomeText6' />
<a href='https://brave.com/Payments_FAQ.html' target='_blank' data-l10n-id='paymentsWelcomeLink' />
<span data-l10n-id='paymentsWelcomeText7' />(I can't copy/paste your text above, since it's in an image, but I'll try to simulate) paymentsWelcomeText6=Words before link
paymentsWelcomeLink=link text goes here
paymentsWelcomeText7=words after linkThe variable strategy like you suggest is great- but in this case, it would be generating an HTML element (which I believe is out of scope for a translation). In this case, the folks doing the translation would need to be aware of how the strings are used in the UI, which I think is acceptable (instead of them blindly translating the strings) Thoughts? cc: @aekeus @alexwykoff @bbondy |
|
Removing ledger tag since this is really a content / i18n issue and not something that impacts Brave Payments functionality |
|
See #8162 (comment) |
Describe the issue you encountered:
These lines on about:payments should be localizable in languages whose grammar is different from English.
browser-laptop/js/about/preferences.js
Lines 915 to 917 in 238938e
In Japanese, based on the current status, they need to be sorted reversely. Also no whitespaces should exist there because it is gramatically wrong to have ones in a sentence.
Expected behavior:
Make
paymentsWelcomeText6andpaymentsWelcomeText7concatenated and include the URL in it as a variable like this: https://github.com/luixxiul/browser-laptop/commit/ef284caa8be29a62ea18f68cc38f8f7c4d0244fa. Also whitespaces should not be hardcorded, and let translators handle them.Currently you get this:
It could be improved like this, which is grammartically correct: