i18n: backfill EN keys for polish-pass defaultValue strings - #132
Merged
Merged
Conversation
Promote 5 strings from defaultValue fallbacks to proper keys:
- dashboard:shell.walletCreatedTitle / walletCreatedBody
- card.openDescription / card.viewFull
- toast.queueOverflow (preserves {{count}} interpolation)
Other 17 locales pick these up via the translation backfill flow.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
The polish pass left three template-literal aria-labels with hardcoded
English suffixes ("new bids", "accepted bids ready to decrypt",
"pending transactions"). Visually invisible — only screen-reader users
saw the English. Replace with i18next plural keys (_one / _other) so
the aria-label translates and reads grammatically at count == 1.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Add no-restricted-syntax ESLint rule that flags string literals and
template literals in user-facing JSX attributes (aria-label,
aria-description, aria-roledescription, alt, title). Test files are
exempted; placeholder is intentionally not covered (numeric-only in
this app, locale-agnostic).
Backfill the 5 call sites the new rule surfaced:
- LayoutPopover card-size + column-count buttons (4 sites) now look up
layoutPopover.cardSize{Small,Medium,Large} and the new
layoutPopover.columnsCount plural key.
- StorageSection disk-usage segment tooltip uses storage.segmentTooltip
with {{label}}, {{size}}, {{percent}} interpolation.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
formatAda + formatDate read i18next.language from the singleton and
pass it to toLocaleString / toLocaleDateString instead of `undefined`,
so number grouping and date format follow the user's selected app
language rather than the OS default. Falls back to undefined when
i18next isn't initialized — keeps unit tests stable.
formatRelativeTime swaps its hardcoded English buckets ("just now",
"5m ago", "2y ago") for Intl.RelativeTimeFormat with style:'narrow'.
English narrow CLDR matches the prior strings exactly except
"just now" → "now"; non-English locales now get their proper CLDR
forms (e.g. "5分钟前" instead of "5m ago"). Uses numeric:'auto' under
60s for the "now" form and numeric:'always' above so "1mo ago" / "1y
ago" don't collapse to "last mo." / "last yr."
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
defaultValue:fallbacks to proper EN translation keys.dashboard:shell.walletCreatedTitle/walletCreatedBodytoen/dashboard.jsonandcard.openDescription,card.viewFull,toast.queueOverflowtoen/common.json., { defaultValue: '...' }from eacht()call site inDashboard.tsx,EncryptionCard.tsx, andToast.tsx. Thecount:interpolation onqueueOverflowis preserved.defaultValue:calls inconfig/categories.tsare intentionally left alone — they use the dynamic-subkey + runtime-fallback pattern.Test plan
tsc --noEmitcleaneslintclean for the 3 changed.tsxfilesgrep -rn 'defaultValue:' fe/srcshows only the 2 pre-existingcategories.tsusagesdefaultValue:already showed them in EN); this PR is config tidy-up onlyThe other 17 locales pick these up via the translation team's backfill flow.
Generated with Claude Code