Overview¶
Localisation comprises all activities related to recreating the strings and potentially other assets in other languages, taking in account cultural, sociodemographic, and geopolitical specifics of each language and the region where it is spoken. Localisation is not mere translation; for example, one should not run a winter campaign with pictures of snow in December in countries on the southern hemisphere, as there is no snow at that time. Such errors show disrespect to the users and might damage the app's reputation irreparably.
We use Weblate, which is a Czech web-based localisation tool.
String keys naming convention¶
The general logic of a string key is "app area" + ("sub area") + "general content of the string" + "type of UI", joined by underscores. A good example is premium_individual_renew_button. We can easily guess that the graphical element is a button, it is located on the Premium screen, it regards the individual subscription and its meaning is to renew it.
However, sometimes enforcing these rules would result in unnecessarily long and convoluted keys. For example, in a key that's used for placeholder purposes, we only need to state sample_purpose_1 to make it understandable enough; no need to append _text at the end. On the other hand, we have no idea what this string contains. Use your brain to decide what's right.
App areas
This is not an updated and full list of areas, more like a suggestion. It is good practice to first check up on existing strings in Weblate. Go to English and then click on Browse to search for key words and phrases.
- premium_: any Premium-related screens and elements
- group_: most often it is related to any edits of group settings
- member_
- transactions_: strings in the group's transaction list
- transaction_: related to individual transaction strings
- auto_categorize_: in regard to AI-powered categorisation in the web app
- changes_: recent activity – a card in the app, or notification strings
- category_ or categories_
- charts_: related to statistics and graphs
- email_
- filter_: searching in transactions
- campaign_
- scan_qr_code_
- share_
- notification_body_: this is needed by the iOS app to send notifications
- who_are_you_: this is lengthy, but understandable – related to selecting which member the user wants to be connected to
- password_: anything connected to changing, resetting the password or migrating the account to another login provider
- pay_via_bank_app_: special library that opens bank apps
- widget_: 😄
- app_: such as app_language or app_version; force_update_
- ln_: lightning network
Note: Verbs as prefixes can be used, but tread carefully: create_, save_, clone_, copy_, archive_, delete_, edit_, join_, leave_, split_, ...
UI elements
UI elements describe on which type of graphical items the string is located. Notifications usually don't contain this label while they are suffixed with the relevant verb (changed, deleted, added etc.). A similar things happens with recurring transaction strings, as it would add unnecessary length to the key (e.g. transaction_repeat_monthly_same_day).
- _button
- _text: usually a short string
- _description: usually longer than text, it might be an explanation of sorts
- _title: headings of cards etc.
- _hint: a short explanation of what will happen
- _prompt: a nudge to make the user perform an action
- _toast: a short text briefly appearing at the bottom of the screen
- _link: clicking this will take the user somewhere else
- _message: texts on popups
- _warning: describes destructive actions
- _action: rare; should have been button
Not all elements have to be used all the time, and new ones might eventually emerge. This is quite tightly linked to the app design. Especially links are on their way to extinction.
Examples of badly named strings:
- missing UI element:
new_member: is this a button – a call to action, a heading on a card, or what? - too short:
next,about,assignetc.: where is it, what does it do, what element is it? - unclear:
paid: is this the past tense or an adjective? How will this translate to languages with declination and genders? - mysterious abbreviation:
desc_contacts. Generally, do not use abbreviations. We are not looking to save memory bytes... - similar wording not saved as variations: Weblate can save variations of two or more similar strings, which are then showed in its UI, so we can see that there is already a similar string at all. For example, "You are offline" and "You're offline" are incorrectly saved as individual strings under keys
offline_warning_titleandpremium_offline_title.