Conversation
The current "允许本会话" reads as "allow (the session itself)": 本会话 sits in object position after 允许, not as a scope adverb. "本次会话内允许" moves the scope up front, matching the CLI's approval.allowed_session.
tonydwb
left a comment
There was a problem hiding this comment.
Code Review Summary
Verdict: LGTM (reviewer's token is read-only — submitted as COMMENT instead of APPROVE; maintainer can formally approve).
Pure i18n string alignment — changes two catalog strings in apps/desktop/src/i18n/zh.ts and zh-hant.ts so the desktop button label allowSession matches the CLI's existing allowed_session scope-adverbial phrasing (本次会话内允许 / 本次工作階段內允許).
The diff is minimal and well-scoped: 2 lines changed across 2 files, no behavior change, no test surface needed for catalog strings. The PR description documents the rationale clearly (scope-as-adverbial reading) and the source-of-truth for the new wording (locales/en.yaml:22, locales/{zh,zh-hant}.yaml).
Looks good.
Reviewed by Hermes Agent
|
cc @JimLiu, would love your take! |
LGTM, but I can't approve or merge :D |
What does this PR do?
Improves the zh/zh-hant translation of the desktop "Allow this session" button to match the CLI's existing wording.
English sources
The intended reading of "Allow this session" is "allow (this command) for this session", not "allow the session itself". The session is the scope of the allow, not the object being allowed. The CLI's "Allowed for this session" makes the same scope reading explicit by keeping the preposition.
Current Chinese (desktop) — mistranslates the scope as the object
zh.ts:允许本会话(reads as "allow the session itself")zh-hant.ts:允許本工作階段(same ambiguity)CLI already ships the correct scope-adverbial wording
Key
approval.allowed_session:zh.yaml:本次会话内允许zh-hant.yaml:本次工作階段內允許This PR brings the desktop labels in line. Both surfaces (button vs. confirmation) describe the same scope; Chinese should express it uniformly. No behavior change.
Type of Change
Changes Made
apps/desktop/src/i18n/zh.ts:allowSession→本次会话内允许apps/desktop/src/i18n/zh-hant.ts:allowSession→本次工作階段內允許How to Test
Switch desktop to Simplified / Traditional Chinese, trigger an approval prompt, open the "▼" menu next to Run. The middle item now matches the CLI approval prompt.
Checklist
Code
fix(i18n): ...)pytest tests/ -q— N/A (TypeScript catalog string)Documentation & Housekeeping
cli-config.yaml.example— N/ACONTRIBUTING.md/AGENTS.md— N/A