Skip to content

fix(i18n): translate 229 missing Simplified Chinese UI strings - #34478

Merged
OrcaWin merged 6 commits into
stablyai:mainfrom
Aboysky:fix/zh-cn-missing-translation-keys
Oct 28, 2026
Merged

OrcaWin merged 6 commits into
stablyai:mainfrom
Aboysky:fix/zh-cn-missing-translation-keys

Conversation

@Aboysky

@Aboysky Aboysky commented Oct 27, 2026

Copy link
Copy Markdown
Contributor

ELI5

Orca's interface speaks Simplified Chinese, but 229 of its newest screens and messages were still coming up in English for Chinese users — the agent permission settings, worktree management messages, cookie import errors, SSH host dialogs and more. This PR translates all of them, using the same wording the rest of the Chinese interface already uses.

What Changed

Only src/renderer/src/i18n/locales/zh.json: 229 catalog keys added, no code changes, no existing translations modified.

Main areas covered:

  • Settings → Agents permission controls (settings.agents.permission*, 31 keys)
  • Browser history panel (browser.history.*, 20 keys)
  • Sidebar worktree/workspace management and batch actions
  • Cookie import failure toasts
  • SSH host server recovery dialog, Windows host errors, proxy connection reuse
  • Source-control dropdown states, Claude subagent navigation settings, native-chat queue reordering

Every {{placeholder}} matches the English source (validated mechanically), and terminology follows the existing catalog (智能体, 工作区, 工作树, 主机, 替我批准, 检出, 变基, 议题). Brand and product names (Claude, Linear, GitHub, Zen, Esc/Enter) stay in Latin script, as elsewhere in the catalog.

11 status-bar credit/balance keys (auto.components.status.bar.*) are deliberately not translated: provider-credit-balance-locales.test.ts requires target catalogs to stay sparse there and interpolates English copy at runtime.

Why

Fixes #34439. Recently added features have outpaced the zh-CN catalog, so zh-CN users get mixed-language UI in exactly those new surfaces. i18next falls back to English for missing keys, so completing the catalog is a pure data change with no behavior risk.

Visual Proof

Before/after of Settings → Agents (UI language set to 中文(简体)) — the Permissions section header and description fell back to English on main and are localized after this change:

Before (main) After (this PR)
TODO TODO

Before: header shows Permissions, description shows What every agent may do without asking….
After: header shows 权限, description shows 每个智能体无需询问即可执行的操作。….

Testing

  • Script validation: JSON parses; zh has 17,384 keys vs en's 17,395 — the only 11 missing are the sparse-catalog balance keys above (same as es/fr/ja/ko); no existing zh value changed; every {{placeholder}} set identical to the English source

  • pnpm test src/renderer/src/i18n --maxWorkers=2 — 60/60 pass (this is where the sparse-catalog rule was caught and honored)

  • pnpm test:changed src/renderer/src/i18n --maxWorkers=2 — pass

  • Manual: ran ORCA_BACKGROUND_LAUNCH=1 pnpm dev on macOS, set language to 中文(简体), walked Settings → Agents and verified the permission copy renders in Chinese; re-ran the same flow on main's catalog to confirm the English fallback

  • No new automated test: catalog content is translation data; the existing i18n suites cover fallback behavior and key parity was verified mechanically

  • I manually tested these changes locally

  • Automated tests added/updated, or explained why not below

AI Disclosure

Translations were drafted with AI assistance (GLM by Z.ai) and reviewed by the author, a native Simplified Chinese speaker.

Review

  • Cross-platform (macOS/Linux/Windows): N/A — renderer catalog data only, no platform-specific logic. Windows-host-facing strings (SSH host dialogs) are translated in place.
  • Remote/SSH: N/A — SSH host dialog strings are translations only, no connection logic changed.
  • Agents/integrations: provider-neutral; agent names interpolate via {{agent}} placeholders unchanged.
  • Performance: N/A — static JSON loaded through the existing i18n pipeline.
  • Security: N/A — static translation strings.

Agent skill upstream boundary

  • Not applicable, or this change copies or mechanically translates no upstream skill-installer source, tests, fixtures, registry entries, path tables, comments, or documentation.

Notes

No issues in security, cross-platform support, remote SSH, mobile, backwards compatibility, or performance — data-only change to one locale catalog.

Checklist

  • This PR is small and focused
  • I explained what changed and why (ELI5, the user-facing before/after, the mechanism, and why over the alternatives)
  • Before/after screenshots or videos attached for UI changes, or N/A with reason
  • Self-reviewed for correctness, security, and performance
  • Cross-platform, SSH/remote, and path/shortcut impact considered (or N/A)
  • pnpm lint, pnpm typecheck, pnpm test, and pnpm build pass (or CI will cover; local preferred)

Complete the zh-CN catalog for recently added surfaces: browser
history, agent permission settings, worktree/workspace management,
cookie import toasts, SSH host server dialogs and source-control
dropdown states. Terminology follows the existing catalog.

11 status-bar credit/balance keys stay untranslated on purpose:
provider-credit-balance-locales.test.ts keeps target catalogs sparse
and interpolates English copy at runtime.

Fixes stablyai#34439
@Aboysky
Aboysky requested a review from brennanb2025 as a code owner October 27, 2026 17:13
@coderabbitai

coderabbitai Bot commented Oct 27, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review.

Recent review info
Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: dfdacd0d-1ca1-449f-8234-cc67f5614e93
Commits

Reviewing files that changed from the base of the PR and between 7b46319 and 1c921b9.

Files selected for processing: 1
  • src/renderer/src/i18n/locales/zh.json
Files skipped from review as they are similar to previous changes: 1
  • src/renderer/src/i18n/locales/zh.json

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 0 remain after this review.

Walkthrough

The Simplified Chinese locale adds and updates translations across settings, agent permissions, worktree and project management, remote-host operations, Git and automation, chat, and browser interfaces. It also adds error messages, status labels, accessibility text, and guidance for these workflows.

Priority: Normal

Severity of issue fixed: Medium

Merge Risk: Low · up to 1c921

The port label may mislead Simplified Chinese users, but this PR does not introduce that wording. The change is mergeable with a follow-up to correct it.

Pre-merge checks: Passed 5
Check name Status Explanation
Title check Passed The title names the main change: adding Simplified Chinese translations for 229 missing UI strings in the zh.json locale catalog. It uses the conventional fix(i18n) prefix. It is specific and matches …
Description check Passed The description follows the template's main sections: ELI5, What Changed, Why (with a linked issue, Fixes #34439), Visual Proof, Testing, AI Disclosure, Review, Agent skill upstream boundary, Notes, a…
Linked Issues check Passed Issue #34439 requires Simplified Chinese coverage for recently added UI surfaces. The PR changes src/renderer/src/i18n/locales/zh.json and covers agent permissions, browser history, worktrees and wo…
Out of Scope Changes check Passed The changes are limited to Simplified Chinese catalog data. The added browser-extension, blocked-page, tab-hover-card, WSL, and workspace-sleep entries address newly added or affected UI strings and s…
Docstring Coverage Passed No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentat…
Full details: Title check

Explanation

The title names the main change: adding Simplified Chinese translations for 229 missing UI strings in the zh.json locale catalog. It uses the conventional fix(i18n) prefix. It is specific and matches the changeset, which only adds zh.json keys.

Full details: Description check

Explanation

The description follows the template's main sections: ELI5, What Changed, Why (with a linked issue, Fixes #34439), Visual Proof, Testing, AI Disclosure, Review, Agent skill upstream boundary, Notes, and Checklist. It explains the scope, the sparse-catalog exception for 11 balance keys, and the verification steps. Gaps: the Visual Proof section still has unfilled TODO placeholders for the before/after screenshots, and the Linked Issue line is written as Fixes #34439, which is an issue reference. The final lint/typecheck/test/build checklist item is unchecked. The template asks for screenshots when UI changes, so the missing screenshots are the main gap.

Resolution

Attach the before/after screenshots (or video) to the Visual Proof section and replace the TODO table. Check the pnpm lint, typecheck, test, and build item once those pass locally, or note that CI will cover it.

Full details: Linked Issues check

Explanation

Issue #34439 requires Simplified Chinese coverage for recently added UI surfaces. The PR changes src/renderer/src/i18n/locales/zh.json and covers agent permissions, browser history, worktrees and workspaces, cookie-import errors, SSH dialogs, source-control states, and related newer keys. The supplied validation reports show 17,472 of 17,483 English keys in zh.json; the 11 missing keys are the documented sparse status-bar balance keys. Placeholder parity and the 60 i18n tests pass. These results support compliance with the issue requirements.

Full details: Out of Scope Changes check

Explanation

The changes are limited to Simplified Chinese catalog data. The added browser-extension, blocked-page, tab-hover-card, WSL, and workspace-sleep entries address newly added or affected UI strings and support the catalog-completion objective in issue #34439. The reported wording revisions support terminology consistency. No unrelated code, locale, or runtime behavior changes are identified.

Full details: Docstring Coverage

Explanation

No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 0 functions across 0 files. (1 skipped: 1 unsupported.)

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1


Review info
Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 46c2ea01-ddfc-4523-a974-ce31b23d0eb2
Commits

Reviewing files that changed from the base of the PR and between 46c0a1f and 7b46319.

Files selected for processing: 1
  • src/renderer/src/i18n/locales/zh.json

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.

Comment thread src/renderer/src/i18n/locales/zh.json Resolved
# Conflicts:
#	src/renderer/src/i18n/locales/zh.json
…orkspace sleep wording

Add zh translations for the 83 English keys added since this branch was
cut (browser extensions, experimental pane, blocked-page load failure),
leaving the sparse status-bar balance keys untranslated as required.
Use 休眠 consistently for workspace sleep in the sidebar and terminal
close dialog.
@OrcaWin

OrcaWin commented Oct 27, 2026

Copy link
Copy Markdown
Collaborator

Thanks @Aboysky! I pushed maintainer edits so this can land:

  • Merged main and resolved the zh.json conflict at the key level: all 226 of your still-needed translations are kept unchanged.
  • Removed the 3 auto.components.ClaudeAgentViewIndicator.* keys. fix(sidebar): remove Claude subagent-view eye indicator #34558 deleted them from en.json, and verify:localization-catalogs rejects locale keys that aren't in en.
  • Translated the 83 en keys added after this branch was cut: browser.extensions.*, settings.browser.extensions.*, browserExtensions.*, the browser-extensions experimental toggle and search entries, browser.loadFailure.blocked* and tabHoverCard.namingFailure.settings. zh is now complete except for the 11 auto.components.status.bar.* balance keys, which have to stay sparse.
  • Workspace sleep now reads 休眠 everywhere in the sidebar and the terminal close dialog. The changed keys are WorktreeCardStatusSlot.sleeping, the sleep.worktree.flow failure toasts, sleepWithDescendants and CloseTerminalDialog.automatic_resume_warning. Agent sleep in Settings still uses 智能体睡眠.

Validation passed: verify:localization-catalogs (zh 17472/17483; the 11 missing are the sparse keys), verify:localization-extraction, verify:localization-coverage, pnpm test src/renderer/src/i18n (60/60) and check:changed (19/19).

Refs #10514

@OrcaWin
OrcaWin merged commit 74556bc into stablyai:main Oct 28, 2026
27 checks passed
OrcaWin added a commit that referenced this pull request Oct 28, 2026
* fix(i18n): translate missing ko/ja/es/fr/pt UI strings

Fill every en.json key missing from the ko, ja, es, fr and pt catalogs
(293 ko/es/fr, 244 ja, 316 pt leaves; purely additive). The provider
credit-balance status-bar keys stay sparse per
provider-credit-balance-locales.test.ts, and zh is left to #34478.

Also list Français and Português (Brasil) in the Settings docs.

Closes #34513

* fix(i18n): keep goal-change failure wording in English until reviewed

---------

Co-authored-by: OrcaWin <[email protected]>
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.

[Bug]: zh-CN UI falls back to English for 240 recently added strings

2 participants