Skip to content

ADFA-4516 feat(dashboard): l10n parity with the app (6 locales) + de-…#114

Merged
luisguzman-adfa merged 1 commit into
mainfrom
feat/ADFA-4516-dashboard-l10n
Jul 2, 2026
Merged

ADFA-4516 feat(dashboard): l10n parity with the app (6 locales) + de-…#114
luisguzman-adfa merged 1 commit into
mainfrom
feat/ADFA-4516-dashboard-l10n

Conversation

@luisguzman-adfa

Copy link
Copy Markdown
Collaborator

…hardcode client UI

Brings the device dashboard's localization up to the app's level and removes hardcoded user-facing client strings.

  • i18n hardening (dashboard.js): supported langs en/es/fr/hi/pt/ru (was es/en only), fallback to en on missing locale/key, data-i18n-placeholder + data-i18n-title support, and a window.t(key, fallback) helper for dynamically-rendered strings.
  • De-hardcode: every user-facing static string in index/app_home/app_kiwix/app_books/ app_maps/sidebar/footer is keyed (data-i18n/-placeholder/-title); dynamic strings in the inline JS + dashboard.js go through window.t. Server-emitted '[System]' terminal logs in sockets/*.ts are intentionally left as English technical output (out of scope).
  • Locales: en.js/es.js rewritten and fr/hi/pt/ru.js added — 106 keys, identical set across all six (app strings reused where concepts matched).
  • Parity test (test/lang-parity.test.ts) asserts every locale has exactly en's key set; wired into 'npm test' (now 14 tests: 8 maps + 6 parity). typecheck stays green.

Known minor: two kiwix modal bodies wrap a path; applyTranslations sets innerText so the monospace styling flattens to plain text (the path text is preserved in every locale). Cosmetic-only; to be refined in the dashboard UX ticket.

…hardcode client UI

Brings the device dashboard's localization up to the app's level and removes hardcoded
user-facing client strings.

- i18n hardening (dashboard.js): supported langs en/es/fr/hi/pt/ru (was es/en only),
  fallback to en on missing locale/key, data-i18n-placeholder + data-i18n-title support,
  and a window.t(key, fallback) helper for dynamically-rendered strings.
- De-hardcode: every user-facing static string in index/app_home/app_kiwix/app_books/
  app_maps/sidebar/footer is keyed (data-i18n/-placeholder/-title); dynamic strings in the
  inline JS + dashboard.js go through window.t. Server-emitted '[System]' terminal logs in
  sockets/*.ts are intentionally left as English technical output (out of scope).
- Locales: en.js/es.js rewritten and fr/hi/pt/ru.js added — 106 keys, identical set across
  all six (app strings reused where concepts matched).
- Parity test (test/lang-parity.test.ts) asserts every locale has exactly en's key set;
  wired into 'npm test' (now 14 tests: 8 maps + 6 parity). typecheck stays green.

Known minor: two kiwix modal bodies wrap a <code> path; applyTranslations sets innerText
so the monospace styling flattens to plain text (the path text is preserved in every
locale). Cosmetic-only; to be refined in the dashboard UX ticket.
@luisguzman-adfa luisguzman-adfa marked this pull request as ready for review July 2, 2026 01:49
@luisguzman-adfa luisguzman-adfa merged commit d6f3202 into main Jul 2, 2026
2 checks passed
@luisguzman-adfa luisguzman-adfa deleted the feat/ADFA-4516-dashboard-l10n branch July 2, 2026 07:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant