aboutsummaryrefslogtreecommitdiffstats
path: root/docs/translating-guide.md
diff options
context:
space:
mode:
authorkumavis <aaron@kumavis.me>2018-04-03 05:13:45 +0800
committerkumavis <aaron@kumavis.me>2018-04-03 05:13:45 +0800
commit98e0fc1ab95c17b9ea19eed04b1e60dc9ea9dccb (patch)
tree23176562ed22c97daa13f4f8f1081b581f2ba2b1 /docs/translating-guide.md
parent8db097d8d9307bc7a0bbb0cd802ad30ad0fc2740 (diff)
parentfd30fabfbd7707adf2e4bc3606362c1687aeed9a (diff)
downloadtangerine-wallet-browser-98e0fc1ab95c17b9ea19eed04b1e60dc9ea9dccb.tar
tangerine-wallet-browser-98e0fc1ab95c17b9ea19eed04b1e60dc9ea9dccb.tar.gz
tangerine-wallet-browser-98e0fc1ab95c17b9ea19eed04b1e60dc9ea9dccb.tar.bz2
tangerine-wallet-browser-98e0fc1ab95c17b9ea19eed04b1e60dc9ea9dccb.tar.lz
tangerine-wallet-browser-98e0fc1ab95c17b9ea19eed04b1e60dc9ea9dccb.tar.xz
tangerine-wallet-browser-98e0fc1ab95c17b9ea19eed04b1e60dc9ea9dccb.tar.zst
tangerine-wallet-browser-98e0fc1ab95c17b9ea19eed04b1e60dc9ea9dccb.zip
Merge branch 'master' of github.com:MetaMask/metamask-extension into ci-screens
Diffstat (limited to 'docs/translating-guide.md')
-rw-r--r--docs/translating-guide.md9
1 files changed, 6 insertions, 3 deletions
diff --git a/docs/translating-guide.md b/docs/translating-guide.md
index ae2dfecd3..8b2bc1785 100644
--- a/docs/translating-guide.md
+++ b/docs/translating-guide.md
@@ -6,9 +6,12 @@ The MetaMask browser extension supports new translations added in the form of ne
## Adding a new Language
-Each supported language is represented by a folder in `app/_locales` whose name is that language's subtag ([look up a language subtag using this tool](https://r12a.github.io/app-subtags/)).
+- Each supported language is represented by a folder in `app/_locales` whose name is that language's subtag (example: `app/_locales/es/`). (look up a language subtag using the [r12a "Find" tool](https://r12a.github.io/app-subtags/) or this [wikipedia list](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes)).
+- Inside that folder there should be a `messages.json`.
+- An easy way to start your translation is to first **make a copy** of `app/_locales/en/messages.json` (the english translation), and then **translate the `message` key** for each in-app message.
+- **The `description` key** is just to add context for what the translation is about, it **does not need to be translated**.
+- Add the language to the [locales index](https://github.com/MetaMask/metamask-extension/blob/master/app/_locales/index.json) `app/_locales/index.json`
-Inside that folder there should be a `messages.json` file that follows the specified format. An easy way to start your translation is to first duplicate `app/_locales/en/messages.json` (the english translation), and then update the `message` key for each in-app message.
That's it! When MetaMask is loaded on a computer with that language set as the system language, they will see your translation instead of the default one.
@@ -20,7 +23,7 @@ To automatically see if you are missing any phrases to translate, we have a scri
node development/verify-locale-strings.js $YOUR_LOCALE
```
-Where `$YOUR_LOCALE` is your [locale string](https://r12a.github.io/app-subtags/), i.e. the name of your language folder.
+Where `$YOUR_LOCALE` is your locale string (example: `es`), i.e. the name of your language folder.
To verify that your translation works in the app, you will need to [build a local copy](https://github.com/MetaMask/metamask-extension#building-locally) of MetaMask. You will need to change your browser language, your operating system language, and restart your browser (sorry it's so much work!).