Wire ~80 Svelte components and App.svelte through svelte-i18n ($_),
replacing hard-coded English strings across the header/navigation,
sidebar and session list, message/tool/thinking content, the session
analysis panel, analytics dashboards (heatmaps, velocity, tools,
skills), usage, trends, insights, activity, all modals, filters, and
every settings section.
Expand en.json and zh-CN.json to 869 keys each with full parity. Use
ICU plurals for counts and parameterized messages for dynamic
sentences; leave technical identifiers (agent/model names, CLI
snippets, paths) untranslated.
Default the interface to English: chooseInitialLocale now honors only
an explicit stored preference instead of auto-detecting the browser
language, so the UI stays English until the user opts into another
locale.
Fix the language-switcher dropdown being clipped by adding an
allowOverflow option to SettingsSection. Initialize i18n in the vitest
setup so component tests can format messages.
Title:
feat(frontend): localize UI into Chinese and default to English
Description:
Adds full Simplified Chinese (zh-CN) localization for the SPA and makes
English the default interface language.
What changed
App.sveltethroughsvelte-i18n(
$_), replacing hard-coded English strings across theheader/navigation, sidebar and session list, message/tool/thinking
content, the session analysis panel, analytics dashboards (heatmaps,
velocity, tool/skill usage), usage, trends, insights, activity, all
modals, filters, and every settings section.
en.jsonandzh-CN.jsonto 869 keys each with full parity.Counts use ICU plurals and dynamic sentences use parameterized
messages rather than concatenated fragments. Technical identifiers
(agent/model names, CLI snippets, file paths, API paths) are left
untranslated.
chooseInitialLocalenow honorsonly an explicit stored preference instead of auto-detecting the
browser language, so the UI stays English until the user opts into
another locale via Settings → Language.
Fixes
SettingsSectiongains an opt-inallowOverflowprop so atypeahead popover can escape the rounded container; the header keeps
its own corner clipping.
Notes
initI18n()is now called in the vitest setup so component tests canformat messages; tests resolve to the
enlocale, so existingEnglish-facing assertions are unaffected.
OptionTypeahead) continue to receivetranslated labels/placeholders from their callers rather than holding
copy internally.
Where to look
frontend/src/lib/i18n/index.ts— locale selection / default.frontend/src/lib/i18n/locales/{en,zh-CN}.json— dictionaries.frontend/src/lib/components/settings/SettingsSection.svelte—allowOverflow.