Translations
The translations package stores translation lines in the
tenant database. A line has a group, a key and a text per language, and a
public flag. Two screens under Configuration edit them; both need the
translation_list permission, the ulams/translations package, and can be hidden with the
hideInMenu-ConfigurationTranslations and hideInMenu-ConfigurationAdminTranslations
settings. Creating, updating and deleting lines need translation_create,
translation_update and translation_delete.
Translations (API and frontends)
Section titled “Translations (API and frontends)”
/configuration/translations lists all database lines with their group, key and texts, and
filters them by group and key. New and Edit open a form with:
- Group and Key: for API messages, the Laravel translation file and key. For example
group
validation, keyrequiredoverridesvalidation.required. - Public: the line is returned without signing in by
GET /api/translations, so a frontend can load its labels from the API. - Text: a JSON object with one entry per language, for example
{"en": "Required", "pl": "Wymagane"}.
How the lines are used:
- API messages: when the API translates a key, a database line with the same group and
key replaces the value from the package’s language files. The language comes from the
request’s locale header (
en-USuses theenfiles). - Frontends: public lines are available at
GET /api/translationsfor any frontend that wants editable labels.
Panel translations
Section titled “Panel translations”/configuration/admin_translations changes the labels of the admin panel. The list shows every
message of the panel’s built-in language files (language, key, value), searchable by language,
key and text. Edit on a key opens the values in all languages; saving stores them as a
database line in the Admin group with that key.
- Search for the label, for example key
menu.Usersor the textUsers. - Click Edit, change the text in the languages you need and save.
- The change applies immediately in your browser. Other administrators see it after they
sign in again or reload the panel, which loads the
Admingroup on start.