Skip to content

feat(i18n): add en and zh to shared texts and the conversation screen - #183

Merged
AliceSaikawa merged 3 commits into
mainfrom
feat/issue-78-i18n-shell
Oct 22, 2026
Merged

AliceSaikawa merged 3 commits into
mainfrom
feat/issue-78-i18n-shell

Conversation

@AliceSaikawa

@AliceSaikawa AliceSaikawa commented Oct 22, 2026 •

Copy link
Copy Markdown
Owner

Why

Part of the English and Simplified Chinese rollout (Issue #78). The shared texts (tab bar, error screens, sheets, start-up failures, Host errors, permission preset names) were in dictionaries without translations, the conversation screen and its picker still wrote Japanese inline, and several web/src/dsh modules threw Japanese errors that can reach the screen. Until the last PR enables the languages, the page stays Japanese.

Scope

  • en/zh for bootMessages, errorMessages, shellMessages, overlayMessages, markdownMessages (web/src/app/messages.ts), remoteErrorMessages, permissionPresetMessages (web/src/dsh/messages.ts).
  • New navigationErrorMessages, serviceErrorMessages used by session-navigation.ts, conversation-selection.ts, session.ts, services.ts; the texts are made with currentLocale() when the error is thrown. interactions-store.ts keeps its fixed Japanese rejection reasons, as docs/design/11-i18n.md decides, because they go back to the DSH requester.
  • New web/src/features/conversation/messages.ts for ConversationScreen.tsx, ConversationPicker.tsx, conversation-choices.ts.
  • app/router.ts: its developer error is English (never shown).
  • Terms: docs/i18n/terms/shell.md; the main terms are also rows in docs/i18n/glossary.md.

Tradeoffs

  • Permission preset names use the stock DSH English and Chinese, except that Auto review adds (experimental)/(实验性) as the Japanese name does. The descriptions are translated from the Japanese, not copied from DSH.
  • Tab labels are short (Sessions, Search, Inbox, Settings / 会话, 搜索, 待处理, 设置) to fit under the icons at 390 px.

Blast radius

No visible change: Japanese strings are identical. tests/11-shared-messages.test.ts now expects these catalogs to be translated instead of untranslated.

Verification

  • pnpm typecheck, pnpm test (1,459 tests, 1,457 pass, 2 existing skips), git diff --check pass.
  • tests/00-i18n-shell.test.ts checks the remote error texts, preset names and conversation choices in English and Chinese.

Refs #78

…rsation screen

The tab bar, error screens, sheets, start-up failures, Host error texts and permission preset names now have English and Simplified Chinese next to the Japanese. The conversation screen and its picker read their texts from web/src/features/conversation/messages.ts, and errors thrown in web/src/dsh are made in the page language.

Copy link
Copy Markdown
Owner Author

独立レビュー(自動)の結果です。

判定:直してからマージ

指摘(優先度順)

  1. 起動失敗の文で、英語・中国語の主語が日本語と逆(web/src/app/messages.ts:18 英語、:25 中国語)
    • 日本語 (L11) は「この DSH の版に M3E の画面が対応していない可能性」(M3E が DSH に対応していない)ですが、英語 This version of DSH may not support the M3E screen.、中国語 此版本的 DSH 可能不支持 M3E 页面。 は「DSH が M3E に対応していない」になっています。
    • 直し方:英語 The M3E screen may not support this version of DSH.、中国語 M3E 页面可能不支持此版本的 DSH。 にしてください。
  2. 権限の説明の訳ずれ(web/src/dsh/messages.ts)
    • autoReview:日本語「自動レビュー(実験的)」(L109) に対し、英語 Auto review (L119)・中国語 自动审查 (L129) は「実験的」が抜けています。Auto review (experimental)/自动审查(实验性) にしてください。
    • autoReviewDescription:英語 (L123)・中国語 (L133) が日本語 (L113) にない「native tool call and PTC inner call」を足しています。日本語の原文どおりに訳すか、三言語の内容をそろえてください。workspaceWriteDescription・dangerFullAccessDescription も日本語との差を確認してください。
    • steerUnavailable:英語 (L56) が steer のままで、日本語「実行中の処理に割り込めません」の意味が伝わりません。This message cannot interrupt the running task. など訳してください。
  3. 承認・質問を断った理由の文を、表示中の言語で訳している(web/src/dsh/interactions-store.ts)
    • 設計書(docs/design/11-i18n.md:213)は「dsh/interactions-store.ts の Error の文言は移さない(画面に出ず、言語で変えると DSH の要求元へ返す文が変わる)」と決めています。この PR は errorText()(interactionErrorMessages)で言語ごとに変えています。
    • 直し方:interactions-store.ts の Error 文言を元の固定の日本語に戻し、interactionErrorMessages を削除してください。変える場合は設計書の決定を先に更新する必要があります。
  4. PR タイトルが 83 字:AGENTS.md の上限 72 字を超えていて、.github/workflows/pr-title.yml で落ちます。
    • 短縮案:feat(i18n): add en and zh to shared texts and the conversation screen(69 字)
  5. glossary 未更新
    • docs/design/11-i18n.md:118 の規則(訳を足す PR では docs/i18n/glossary.md に新しい用語を足す)に反しています。用語は docs/i18n/terms/shell.md にだけ書かれています。
    • 新しい用語を docs/i18n/glossary.md の表に行として追記してください(terms ファイルを残すなら glossary.md からリンク)。

確認済み

  • typecheck・test(失敗 0)は通っています。

@AliceSaikawa AliceSaikawa changed the title feat(i18n): add English and Chinese to the shared texts and the conversation screen feat(i18n): add en and zh to shared texts and the conversation screen Oct 22, 2026
The English and Chinese start-up failure now says that the M3E screen may not support this DSH version, as the Japanese does. The permission preset names and descriptions follow the Japanese text instead of the stock DSH wording, and the steer failure says the message cannot interrupt the running operation.

The rejection reasons in interactions-store.ts go back to fixed Japanese and interactionErrorMessages is removed, because docs/design/11-i18n.md keeps those texts out of the dictionaries: they are returned to the DSH requester and are not shown on the page.
docs/design/11-i18n.md asks each translation PR to add its new terms to docs/i18n/glossary.md. The rows link to docs/i18n/terms/shell.md for the rest.
@AliceSaikawa
AliceSaikawa merged commit d7cbb62 into main Oct 22, 2026
7 checks passed
@AliceSaikawa
AliceSaikawa deleted the feat/issue-78-i18n-shell branch October 22, 2026 12:56
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