Skip to content

fix(i18n): align non-English memory guard strings with JS placeholders#1730

Merged
jundot merged 1 commit into
jundot:mainfrom
fqx:fix/i18n-memory-guard-placeholder-mismatch
Jun 8, 2026
Merged

fix(i18n): align non-English memory guard strings with JS placeholders#1730
jundot merged 1 commit into
jundot:mainfrom
fqx:fix/i18n-memory-guard-placeholder-mismatch

Conversation

@fqx

@fqx fqx commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

Problem

The description_template and wired_limit_warning strings in all non-English locale files use placeholder names that do not match what the JavaScript actually interpolates.

description_template — JS replaces {tier}, {active_pct}, {reclaim_method}; non-English locales had {ceiling_gb} instead, so it appeared verbatim.

wired_limit_warning — JS replaces {kernel} with a value that already includes the unit (e.g. 37.4 GB); non-English locales had {kernel} GB causing double-GB output, and {requested} which is never replaced.

en.json was already correct. This fixes the 7 affected locales: zh, zh-TW, ja, ko, fr, ru, es.

Fix

Updated all 7 locale files to use the correct placeholders and added proper translations (previously these strings were left in English in the non-English files).

Testing

  1. Switch dashboard language to Chinese / Japanese / Korean / French / Russian / Spanish
  2. Open Settings > Resources > Memory Guard
  3. Tier description should show the actual percentage and reclaim method instead of {ceiling_gb}
  4. Kernel warning should show the GB value once, not twice, and no {requested} literal

Generated with Claude Code

…olders

`description_template` in all non-English locales used `{ceiling_gb}`
which the JS never replaces, leaving a literal `{ceiling_gb}` in the UI.
The JavaScript interpolates `{tier}`, `{active_pct}`, and `{reclaim_method}`.

`wired_limit_warning` had `{kernel} GB` (causing double "GB" after JS
injects `<strong>37.4 GB</strong>`) and `{requested}` which the JS
never replaces.

Updated 7 locale files (zh, zh-TW, ja, ko, fr, ru, es) with correct
placeholders and proper translations. English (`en.json`) was already
correct and is unchanged.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@jundot

jundot commented Jun 8, 2026

Copy link
Copy Markdown
Owner

Thanks for fixing this. The updated placeholders match the dashboard interpolation path, and I verified the non-English locale files no longer leave stale {ceiling_gb} or {requested} tokens behind. This looks good to me, and I'm going to merge it.

@jundot jundot merged commit 83c1fe6 into jundot:main Jun 8, 2026
4 checks passed
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.

2 participants