Skip to content

fix(i18n): use 停止 for the local branch refresh warning action in zh - #51938

Merged
AmethystLiang merged 1 commit into
mainfrom
AmethystLiang/fix-disable-translation-in
Nov 28, 2026
Merged

AmethystLiang merged 1 commit into
mainfrom
AmethystLiang/fix-disable-translation-in

Conversation

@AmethystLiang

@AmethystLiang AmethystLiang commented Nov 28, 2026 •

Copy link
Copy Markdown
Contributor

ELI5

Changes the Simplified Chinese action button on the main 未更新 local branch warning from 禁用 to 停止 so it clearly means stopping the background refresh check rather than disabling the branch.

Files Added Deleted Net
Test 0 0 0 0
Prod 1 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​1 $\color{#cf222e}{\Huge{\mathbf{−}}}$​1 0

What Changed

  • Updated auto.store.slices.worktrees.localBaseRefRefreshDisable in src/renderer/src/i18n/locales/zh.json from "禁用" to "停止".
  • Verified this key has a single caller (showLocalBaseRefRefreshToast in src/renderer/src/store/slices/worktrees/create/local-base-ref-refresh-toast.tsx), paired with the existing tooltip "停止检查 {{value0}}".
  • Left localBaseRefRefreshTurnOff ("禁用检查") on the shallow-clone notice and all unrelated "禁用" entries untouched.

Why

In the main 未更新 / main 有仅存在于本地的提交 warning card, 禁用 reads ambiguously next to the branch name, whereas 停止 matches both the underlying action (stopRefreshingLocalBaseRef) and its tooltip (停止检查 main). Checked against how comparable products handle this.

Visual Proof

i18n-2359-zh-dark-expanded.png

Testing

  • Verified seeded zh-CN fixture render (local-base-ref-refresh-toast:notFastForward, dark & light), hover tooltip (停止检查 main), and click flow (Orca 将不再更新本地 main) with 0 console errors.
  • Ran pnpm test src/renderer/src/store/slices/worktrees/create/local-base-ref-refresh-toast.test.tsx --maxWorkers=2 (13/13 passed) and pnpm check:changed (29/29 passed, including format, localization catalogs/coverage/extraction, typecheck, and ratchets).
  • No new unit test added: single-string copy update covered by existing catalog validation and toast tests.

Performance

None, because this replaces a single 2-character Simplified Chinese string ("禁用" → "停止", identical 6 UTF-8 bytes) in zh.json with one caller (showLocalBaseRefRefreshToast), adding no runtime lookups, allocations, I/O, timers, subscriptions, or layout width changes (code reasoning; no formal timing run).

Risk

Level: Low — affects only the Simplified Chinese button label on the non-shallow local-base-ref refresh warning card; a plain revert restores the previous label.

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.

@coderabbitai

coderabbitai Bot commented Nov 28, 2026

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The Chinese translation for localBaseRefRefreshDisable changes from “禁用” to “停止”.

Merge Risk: Minimal · up to 1c6f1

This updates one Chinese button label from "禁用" to "停止" so it describes stopping the background refresh check. It has no functional or performance impact and is safe to merge.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the change (zh locale label for the local branch refresh warning action changed to 停止) and uses the conventional fix(i18n) prefix. It matches the single-line zh.json change in the summ…
Description check Passed The description follows the template closely. It has ELI5, What Changed, Why, Visual Proof (an image of the after state), Testing with checked items, Performance with the required 'None, because' line…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names the change (zh locale label for the local branch refresh warning action changed to 停止) and uses the conventional fix(i18n) prefix. It matches the single-line zh.json change in the summary and the PR objectives. It is specific enough for a reviewer scanning history.

Full details: Description check

Explanation

The description follows the template closely. It has ELI5, What Changed, Why, Visual Proof (an image of the after state), Testing with checked items, Performance with the required 'None, because' line, Risk with a level, and the Agent skill boundary section. The Linked Issue section is missing: 'Fixes #' is left blank. The Before image is absent, so the Visual Proof section shows only one screenshot and no before/after pair, which the template requires for UI changes. The Review, Notes, and Checklist sections are not filled in, and the AI Disclosure section is left as template text.

Resolution

Consider adding: (1) the issue number under Linked Issue, replacing the blank 'Fixes #'; (2) a BEFORE screenshot next to the existing AFTER image in Visual Proof, since the template asks for both; (3) the Level value in Risk is set to Low, which is fine. Optionally tick the Checklist items or remove the unused sections.

  • 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

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: 09aca2f7-3b67-4b27-bcd9-b4f37933f1b6
Commits

Reviewing files that changed from the base of the PR and between 323d49f and 1c6f1e2.

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; 8 remain after this review.

@AmethystLiang
AmethystLiang merged commit f70ecb4 into main Nov 28, 2026
54 checks passed
@AmethystLiang
AmethystLiang deleted the AmethystLiang/fix-disable-translation-in branch November 28, 2026 19:04
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