Skip to content

fix(i18n): replace Chinese fallback strings with English in t() calls#1651

Merged
kaizhou-lab merged 1 commit intoiOfficeAI:mainfrom
amanharshx:fix/i18n-chinese-fallbacks
Mar 24, 2026
Merged

fix(i18n): replace Chinese fallback strings with English in t() calls#1651
kaizhou-lab merged 1 commit intoiOfficeAI:mainfrom
amanharshx:fix/i18n-chinese-fallbacks

Conversation

@amanharshx
Copy link
Copy Markdown
Contributor

@amanharshx amanharshx commented Mar 23, 2026

Closes #1652

Summary

  • Replace 49 hardcoded Chinese fallback strings (2nd argument to t()) with English equivalents across 7 renderer files
  • When i18n key resolution fails, the fallback now renders English instead of Chinese in an otherwise English UI

Motivation

The t('key', 'fallback') pattern uses the fallback when the key lookup fails. Several components had Chinese strings as fallbacks, causing Chinese text to appear in English-language UIs when keys didn't resolve correctly.

Diff

+49 −49 across 7 files (string-only, no logic changes)

Files changed

  • CodeBlock.tsx — 1 fix
  • LarkConfigForm.tsx — 7 fixes
  • TelegramConfigForm.tsx — 5 fixes
  • ConversationTitleMinimap/index.tsx — 1 fix
  • AddCustomPathModal.tsx — 7 fixes
  • CssThemeModal.tsx — 1 fix
  • SkillsHubSettings.tsx — 27 fixes

Testing

  • bunx tsc --noEmit — no type errors
  • bun run lint:fix — clean
  • Manual: verified no Chinese characters remain in fallback strings across changed files

Risks / Side effects

  • Minimal — string-only changes, no logic modified
  • Some fallback strings may not exactly match the en-US locale values (pre-existing issue, not introduced here)
  • 4 keys (common.name, common.refreshSuccess, common.import, common.processing) don't exist in locale files — pre-existing, noted as follow-up

@kaizhou-lab kaizhou-lab merged commit bd5dbea into iOfficeAI:main Mar 24, 2026
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.

[Bug]: Chinese fallback strings appear in English UI when i18n key resolution fails

2 participants