feat: UI localization (i18n) with Simplified Chinese — reviving the approach from #1993

オープン
#3,849 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
25/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
活発
技術スタック
typescript

調査の方向性

This is a scope question before it is a patch: read the closed PR #1993 and issue #3333 first, and wait for a maintainer to say whether localization is in scope before writing code. If it is, the surface is the ~229 hardcoded English strings across packages/review-editor and packages/ui, plus a new packages/ui/i18n provider and a uiLanguage entry registered through SettingDef/ConfigStore. Done means a language selector in Settings → General, navigator.language detection with English fallback, and no bundle-size or dependency regressions.

索引モデルが issue の本文から書いたものです。

説明

Summary

The Plannotator UI is English-only, which is a hard barrier for non-English-speaking users. Before proposing anything
new I searched existing work and found PR #1993 ("feat(ui): add lightweight zero-dependency i18n and Simplified
Chinese localization"). It appears to have implemented exactly this, but was closed without merge on 2026-10-28 with
no review comments or discussion.

The first question is therefore: was #1993 closed because the approach was wrong, because localization is planned
differently, or because localized UI is out of scope?

Why this matters

Plannotator sits directly in the review loop — plan approval, code review, annotation. Users click Approve / Reject /
Comment / Submit Feedback every session. Non-English speakers either misread the decision they are making or guess,
which is risky in a tool that gates plan execution.

There is also open issue #3333 (Simplified Chinese README), so community interest in zh-CN already exists at the
documentation level.

Suggested approach (only if localization is welcome)

Reuse the architecture from #1993 rather than designing from scratch:

  • Zero-dependency I18nProvider + useTranslation under packages/ui/i18n, with plain typed dictionaries — keeps
    the single-file HTML bundle small.
  • uiLanguage: 'auto' | 'en' | 'zh-CN' registered through the existing SettingDef / ConfigStore, inheriting the
    same port-independent cookie scoping and server sync as other preferences.
  • Auto-detect via navigator.language, fall back to English on missing keys.
  • Language selector in Settings → General.

This stays additive: English remains the source of truth, translations are pure data files, and adding a locale later
means adding one dictionary.

What I can contribute

If this direction is acceptable, I am willing to:

  • Rebase/revive the #1993 implementation against current main, or submit a fresh PR in the shape above.
  • Provide a reviewed zh-CN dictionary covering all UI strings (currently ~229 hardcoded English UI strings across
    packages/review-editor and packages/ui).

If localization is out of scope for the project, please say so and close this — I will not push a PR you do not want.

Notes

  • No runtime machine translation; dictionaries are static and reviewed.
  • No new runtime dependencies proposed.

主要言語
TypeScript
スター
8.7k
フォーク
649
平均マージ
16時間 1分
マージ済み PR(30日)
756

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

backnotprop/plannotator のほかの issue

backnotprop/plannotator の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。