Localizations allow to run mobile apps in different languages.
The application language is picked by default from your browser settings. If your browser language is English, you will get the app in English. You will get English locale (date format, numbers format) also.
If you want to change the application language you can:
If you do not have the translation made for given language or it is not complete then the whole app or some literals appear in base language (usually English).
locales is the folder with localizations. It contains subfolder(s) with language JSON file(s) where the name of subfolder and the postfix for language file complies with locale notation e.g. ‘en’ for English, ‘en_US’ for American English, and the name of language file corresponds with translation_xx.json pattern.
To see more about app folder structure look at Configuration
Below there is an example from mwhs_dc1-11 app:
locales folder structure
The language file holds data in JSON format. It contains key/value pairs where:
In the example below we can see part of translation_fi.json language file taken from mwhs_dc1-11 app. It contains translations for predefined constants (e.g. app-trademark-title) and literals (e.g. Find) as well.
{
...
"Find": "Hae",
"Prel Package number labels print": "Väliaikainen keräyslaatikko tarra",
"Cancel": "Peruutus",
"Choose company": "Valitse yritys",
"Company": "Yritys",
"Print prel package labels": "Tarra keräyslaatikko",
"User ID": "Käyttäjätunnus",
"Password": "Tunnussana",
"Sign in": "Kirjaudu sisään",
"Sign out": "Kirjaudu ulos",
"app-trademark-title": "Iptor on Iptor Supply Chain Systems Ab:n rekisteröity tavaramerkki.",
"app-trademark-info": "Nämä tiedot ovat luonteeltaan yhteenveto ja voivat muuttua ja ovat tarkoitettu yleisluonteisiksi. Yksityiskohdat toimintaan liittyen Iptorin ohelmistossa, versiosta 10 eteenpäin. Päivitettyjen tietojen saamiseksi ota yhteys Iptor edustajaan.",
"client-session-expired": "Istunto on päättynyt. Paina OK uud.kirj.",
"form-msg-required-number": "Anna kelpaava numero"
}
To edit language file there is no need to have special tool. Any editor where you can handle text file is good (e.g. Notepad), but the tool supporting JSON is recommended.