Open fosterlynn opened 7 years ago
There's already a module in the UI for translation- https://www.npmjs.com/package/i18n-react
And a YAML file in packages/store/intl
which defines the English translations. We just need to take a pass at the UI and replace hardcoded text with the translation components and put said text in that file. Then we can start to create separate files for other languages.
There's also a bit of work to do in initialisation, to detect the user's language from the browser locale settings and load the appropriate translation file.
Translation of the strings in the OCP UI to Spanish has been done: https://github.com/FreedomCoop/valuenetwork/blob/master/locale/es/LC_MESSAGES/django.po @XaviP understands how it all works, and where the translations were done.
@XaviP says, this is how it's done in django: To update translations in code:
@fosterlynn @bhaugen and I have admin permissions in transifex to upload updated po file. If someone needs that permissions we can give them. Once translators finish or make a notable amount of translation, the po file of the language must be downloaded, compile the language (explained in the same link bob sent), and push it to master github to deploy it.
We will need some facility so different people can translate the UI into multiple languages.