Skip to content

feat(i18n): add Simplified Chinese locale using the existing translation layer - #413

Merged
BaaRai merged 4 commits into
BaaRai:mainfrom
BlackGownQ:feat/i18n-zh-cn
Nov 20, 2026
Merged

BaaRai merged 4 commits into
BaaRai:mainfrom
BlackGownQ:feat/i18n-zh-cn

Conversation

@BlackGownQ

Copy link
Copy Markdown
Contributor

The UI currently offers English and Turkish. This change adds Simplified Chinese (zh-CN) to the existing translation layer and Preferences language selector.

  • Add 2,620 Chinese entries, including the current HAR import/export strings. Reuse original Chinese wording from the repository history where applicable and translate subsequent additions, preserving placeholders, formatting markup and protocol identifiers.
  • Register zh-CN for saved preferences, browser-language detection, the HTML lang attribute and Intl formatting. Keep English as the static-export and unsupported-language default, with the existing English fallback for unknown keys.
  • Extend the existing i18n check to every shipped dictionary, including dynamic-key parity and placeholder validation. Add runtime regression tests for language detection, preference persistence, fallback and existing English/Turkish behavior.
  • Document how to maintain and extend the locale catalogs. No additional dependencies or backend/schema changes are required.

Validation:

  • npm run test:i18n: dictionary checks and five runtime tests.
  • npm run build:static: TypeScript check and static export.
  • Browser checks on the local deployment: Chinese/English switching, Chinese retained after reload, dashboard and model configuration form rendering; no browser console errors observed.

The review snapshot is based on main at 9465dfa. Browser smoke checks were performed on the installed base ab40834 with this localization; the review snapshot additionally includes translations for the 14 HAR-related entries added on main.

Backend data, user content, model responses and tool output are not rewritten. Chinese browser-language variants use the available Simplified Chinese catalog; a saved language preference always takes priority.

@BaaRai
BaaRai merged commit 2686930 into BaaRai:main Nov 20, 2026
6 checks passed
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