Skip to content

[i18n] Improve translation coverage across the application #15

@eloiberlinger1

Description

@eloiberlinger1

Improve i18n coverage across the application

Context

We use react-i18next with translation files in frontend/src/locales/ for five languages: English, French, German, Russian, and Chinese. However, many user-facing strings in the codebase are still hardcoded (especially in the editor feature) rather than using the useTranslation() hook with proper translation keys.

Current state

  • Locale files exist for: en, fr, de, ru, cn
  • Some sections are well-translated: nav, hero, footer, split section, hold info modal
  • Many editor strings are hardcoded in French or English directly in components, for example:
    • "Ajouter une prise", "Chercher par nom...", "Ajout de la prise en cours" in AddHoldModal.tsx
    • "Inspecteur des retenues", "Supprimer le parent", "Child Holds" in HoldInspector.tsx
    • "Contrôles 3D" and control descriptions in Tutorial.tsx
    • "SetRsoft Creator Studio", "Click on a hold and drag it to the left", "Quick Access", "Holds (Hand/Foot)", "Volumes", "Hide" / "Show" in Sidebar.tsx and SidebarHoldsSection.tsx
    • "Loading wall..." in MainCanvas.tsx
    • "Color", "Upload", "Walls" in SidebarWallsSection.tsx
    • Various alert() messages in FileManager.tsx
    • "Parent Hold", "Rotation", "Rotate" in HoldInspector.tsx
  • Some locale files have English fallback where translations are missing (e.g. editor keys in ru.json and de.json still contain English text)

What needs to be done

  1. Identify all hardcoded strings in frontend/src/ (especially under features/editor/)
  2. Add proper translation keys in all five locale JSON files
  3. Replace hardcoded strings with t('key') calls using the useTranslation() hook
  4. Ensure consistency — all five locale files should have the same set of keys

How to contribute

You don't need to know all five languages! Pick the language(s) you're comfortable with:

Language File Code
English src/locales/en.json en
French src/locales/fr.json fr
German src/locales/de.json de
Russian src/locales/ru.json ru
Chinese src/locales/cn.json cn

Steps:

  1. Look for hardcoded strings in the components (start with features/editor/components/)
  2. Add the English key in en.json under the appropriate namespace (e.g. editor.xxx)
  3. Add translations for the languages you know
  4. Replace the hardcoded string in the component with t('editor.xxx')
  5. Open a PR — partial translations are welcome, others can fill in the rest

Convention reminder

From AGENTS.md:

Any user-facing string must use the useTranslation() hook from react-i18next mapped to the JSON files in src/locales/. Never hardcode display text.

Labels

good first issue, i18n, help wanted

Any questions ?
https://discord.gg/BdyfNU9TpR

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    Status

    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions