feat: add project-wide i18n support#209
Conversation
|
There were a lot of files changed, very hard to look at everything, but in general looks fine from my point of view. Don't forget to add docstrings and specify which files you said were incorrectly merged |
| }, | ||
|
|
||
| async down(queryInterface, Sequelize) { | ||
| // Intentionally left as no-op because original free-text values were not uniquely preserved. |
There was a problem hiding this comment.
Is there any way that we can avoid breaking undoing of migrations? Once we run these migrations we cannot go back to a previous version of the app.
| }, | ||
|
|
||
| async down(queryInterface, Sequelize) { | ||
| // No-op: reverse mapping is intentionally omitted. |
There was a problem hiding this comment.
Same as mentioned before
| }, | ||
|
|
||
| async down(queryInterface, Sequelize) { | ||
| // No-op: reverse mapping intentionally omitted. |
The commit where I adapted the first ~100 files and where old logic was accidentally merged is:
This was the part where I initially tried to port changes that looked safe, but later noticed that some old logic had been brought back unintentionally. Because of that, I manually re-checked these files afterwards against the current (caution, a lot of files) Full list of files included in this commit |
Use arrow functions in Papa.parse and ConfirmModal handlers so $t works, and move online/offline translations to common.json.
Migrate placeholder labels and descriptions to i18n keys, add translations in templates.json, and resolve them on the frontend with translateMaybeKey while keeping help tooltips in json.
Wire tag colorCode option names to tags.tag.form.colorCode.options so Select shows translated labels.
Show translated name/description in the project list and edit form while the DB still has the English seed values. Saving persists the field text as-is. Use empty Coordinator button prop defaults so footer labels fall back to common.* i18n.
Pass users.roles.* keys to the select so Select.vue can render localized labels; show translated role name on step two.
Render description column via i18n keys in RightsManagementModal. Add templates/workflows right description keys and a follow-up migration for rights missed by the initial user_right i18n transform.
Migrate system workflow name and description to workflow.names/descriptions keys. Add en/de workflow.json strings, shared translateMaybeKey in utils, and render translated labels across workflow and assignment UIs. Fix RightsManagementModal to use the shared helper.
The description field incorrectly referenced workflow.fields.name label and placeholder, which duplicated the name field in the new workflow modal.
Localize system settings descriptions via i18n keys and migrate existing DB descriptions.
Render log messages through translateMaybeKey so i18n keys in protocol entries are shown as localized text.
Use translateMaybeKey in the rename modal summary so seed workflow i18n keys are displayed as localized labels.
Show translated skill labels in the skills table and details modal, with i18n keys for all seed skill names and descriptions.
Build edit/new modal titles via editItem and newItem i18n keys instead of concatenating verb and noun.
Add migration-i18n-utils (resolveEnText) and replace no-op downs so migrate:undo can repopulate plain English from shared en JSON. Wire downs for user rights, roles, placeholders, workflow seed, settings, and workflow_step configuration keys. Restore default project UI to the seed-localization path without DB keys.
4848aba to
6468534
Compare
Closes #155
Adapts the project to the existing i18n setup across the frontend, including dashboard views, modals, navigation, model-driven forms, validation messages, and backend-provided messages.