|
|
@ -47,6 +47,7 @@ If you want to add your own translation, edit `interface_localization.js` like t |
|
|
|
|
|
|
|
|
|
|
|
1. fork the repo, checkout `i18n` and create a new branch |
|
|
|
1. fork the repo, checkout `i18n` and create a new branch |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
git clone git@github.com:yournickname/twister-html.git ~/.twister/html |
|
|
|
git clone git@github.com:yournickname/twister-html.git ~/.twister/html |
|
|
|
cd ~/.twister/html |
|
|
|
cd ~/.twister/html |
|
|
|
git checkout i18n |
|
|
|
git checkout i18n |
|
|
@ -55,13 +56,15 @@ If you want to add your own translation, edit `interface_localization.js` like t |
|
|
|
2. add your language to the list of available choices. You should use your ISO code here, |
|
|
|
2. add your language to the list of available choices. You should use your ISO code here, |
|
|
|
it should match what the browser reports. The Klingon ISO is "tlh", so: |
|
|
|
it should match what the browser reports. The Klingon ISO is "tlh", so: |
|
|
|
|
|
|
|
|
|
|
|
var knownLanguages = ["en","nl","it","fr","tlh"]; |
|
|
|
|
|
|
|
|
|
|
|
var knownLanguages = ["en","nl","it","fr","tlh"];` |
|
|
|
|
|
|
|
|
|
|
|
For multi-region languages, if you want to catch them all, use only the first half |
|
|
|
For multi-region languages, if you want to catch them all, use only the first half |
|
|
|
(e.g. to match it and it-ch, specify "it"). |
|
|
|
(e.g. to match it and it-ch, specify "it"). |
|
|
|
|
|
|
|
|
|
|
|
3. add a new wordset block after existing ones |
|
|
|
3. add a new wordset block after existing ones |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(preferredLanguage == "tlh"){ |
|
|
|
if(preferredLanguage == "tlh"){ |
|
|
|
polyglot.locale("tlh"); |
|
|
|
polyglot.locale("tlh"); |
|
|
|
wordset = { |
|
|
|
wordset = { |
|
|
@ -70,10 +73,12 @@ For multi-region languages, if you want to catch them all, use only the first ha |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
4. commit & push |
|
|
|
4. commit & push |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
git commit -m "Klingon translation" |
|
|
|
git commit -m "Klingon translation" |
|
|
|
git push |
|
|
|
git push |
|
|
|
|
|
|
|
|
|
|
|
3. When opening the pull request on github, make sure you're pointing to miguelfreitas:i18n |
|
|
|
3. When opening the pull request on github, make sure you're pointing to `miguelfreitas:i18n` |
|
|
|
as the base, so we can merge it straight away in the right place. For any help, ping @toyg. |
|
|
|
as the base, so we can merge it straight away in the right place. For any help, ping @toyg. |
|
|
|