This project uses a centralized localization system so UI strings are not scattered across tools.
- Infrastructure: implemented
- Locale auto-detection: implemented (machine locale)
- Fallback behavior: implemented (
requested -> language -> en) - Default catalog: English (
en) - Additional locales: Greek (
el)
- Shared localization core:
src/shared/localization/index.ts - Base English catalog:
src/shared/localization/catalog.en.ts - Main shell, tools, and Bun runtime messages all read from the same localization module.
- No tool-local locale files are used.
At startup, Prometheus resolves locale in this order:
- Machine locale (browser/runtime)
- Language-only fallback (for example
pt-BR -> pt) - English fallback (
en)
If a key is missing in a non-English locale, Prometheus falls back to English for that key.
- Add a new locale catalog in
src/shared/localization/(for examplecatalog.es.ts). - Include all keys that exist in
catalog.en.ts. - Register the locale in
src/shared/localization/index.tsinCATALOG_BY_LOCALEandSUPPORTED_LOCALES. - Run validation:
bunx tsc --noEmitbun run build:dev
- Run app smoke check:
bun run start- verify menu labels, tool buttons, modal text, and repeated runtime status strings.
- Use domain-first keys:
common.*view.menu.*view.content.*settings.*modal.*runtime.*
- Prefer explicit key names over generic names.
- Reuse existing shared keys for repeated strings (buttons, status labels, common warnings).
- Keep meaning and tone practical and concise.
- Preserve placeholders exactly (for example
{count},{error},{runtime_os}). - Do not change key names in code.
- If wording is unclear in English, open an issue/PR note and propose improved source copy.