feat: i18n support for desktop application menu - #35602
Conversation
Add menu.* i18n keys to en.ts and zh.ts, update desktop-menu.ts labels to use i18n keys, wire translation in windows-app-menu.tsx via useLanguage(), and resolve labels in menu.ts for macOS native menu.
|
The following comment was made by an LLM, it may be inaccurate: Potential Duplicate FoundPR #34103: fix(i18n): translate Windows desktop app menu (File/Edit/View/Go) for all locales Why it's related: This PR also addresses translating the desktop application menu (File/Edit/View/Go menu items). PR #35602 appears to be a continuation or expansion of this work, adding complete i18n support for all menu categories with Chinese (zh-CN) translations, while #34103 focused on the initial translation implementation for Windows desktop menu. You should check if #34103 is already merged or if there's overlap in the menu translation work between these two PRs. |
|
Thanks for updating your PR! It now meets our contributing guidelines. 👍 |
|
Automated PR Cleanup Thank you for contributing to opencode. Due to the high volume of PRs from users and AI agents, we periodically close older PRs using automated criteria so maintainers can focus review time on the most active and community-supported contributions. This PR was closed because it matched the following cleanup criteria:
PRs created within the last month are not affected by this cleanup. If you believe this PR was closed incorrectly, or if you are still actively working on it, please leave a comment explaining why it should be reopened. A maintainer can review and reopen it if appropriate. Thanks again for taking the time to contribute. |
Issue for this PR
Closes #35601
Type of change
What does this PR do?
Add Chinese (zh-CN) i18n support for the desktop application menu bar (File/Edit/View/Go/Window/Help and all sub-items). Menu labels were previously hardcoded English strings in
desktop-menu.ts. This PR integrates them into the existing i18n framework viauseLanguage().Related: #34103 targets the same area but hasn't been merged. This PR takes a different approach - adding dedicated
menu.*i18n keys to the dictionary instead of reusing command keys, and also handles the macOS native menu viamenu.ts.How did you verify your code works?
bun test- i18n parity and desktop-menu tests passbun typecheck- zero errorsChecklist