Skip to content

Add dashboard localization foundation#28

Merged
douglasmonsky merged 6 commits into
mainfrom
i18n-foundation
Jun 10, 2026
Merged

Add dashboard localization foundation#28
douglasmonsky merged 6 commits into
mainfrom
i18n-foundation

Conversation

@douglasmonsky

Copy link
Copy Markdown
Owner

Summary

Builds on #27 by @HoangVung to add dashboard localization infrastructure.

This keeps the dashboard i18n work from #27, fixes dashboard regressions found during review, and refactors translations into a broader language-catalog foundation with starter locale support.

Changes

  • Add external dashboard locale catalogs with English as canonical.
  • Add starter locale catalogs for English, Vietnamese, Spanish, French, German, Portuguese, Japanese, Simplified Chinese, Korean, Russian, Italian, and Arabic.
  • Preserve dashboard --lang and CODEX_USAGE_TRACKER_LANG support.
  • Preserve dashboard language selector and browser language persistence.
  • Generate language selector options from supported language metadata.
  • Add catalog validation tests for key parity, placeholder parity, metadata parity, supported-language coverage, and Arabic RTL direction.
  • Replace brittle English-string dynamic translation lookups with stable recommendation and flag keys where practical, while keeping backwards-compatible English fields.
  • Fix expanded thread-call row rendering.
  • Fix language switching so runtime live status and selected details are preserved.
  • Update README, CLI reference, and dashboard guide documentation for dashboard localization and future language additions.
  • Extend release and installed-package smoke checks so locale JSON resources must ship in packaged artifacts.

Validation

  • node --check src/codex_usage_tracker/plugin_data/dashboard/dashboard.js
  • .venv/bin/python -m compileall src/codex_usage_tracker
  • .venv/bin/python -m pytest tests/test_i18n.py tests/test_recommendations.py tests/test_pricing.py
  • .venv/bin/python -m pytest tests/test_cli_release.py
  • .venv/bin/python -m pytest tests/test_store_dashboard_mcp.py
  • .venv/bin/python -m pytest
  • .venv/bin/python -m build
  • .venv/bin/python -m twine check dist/*
  • .venv/bin/python scripts/check_release.py --dist
  • git diff --check --cached

Attribution

Based on the i18n work in #27 by @HoangVung. The branch preserves the original commits from @HoangVung and the integration commit includes Co-authored-by: hvung1982 <vungcpa@gmail.com> so attribution survives a squash merge.

@douglasmonsky douglasmonsky merged commit ddeec4d into main Jun 10, 2026
12 checks passed
@douglasmonsky douglasmonsky deleted the i18n-foundation branch June 10, 2026 17:27
@HoangVung

HoangVung commented Jun 11, 2026 via email

Copy link
Copy Markdown
Contributor

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.

2 participants