fix(i18n): console.ai.pendingDrafts lands in the eight remaining locale packs (#5705) - #5708
Merged
Merged
Conversation
…cale packs (#5705) The standing unpublished-changes bar's five strings existed only in `en` and `zh`, so `all-locales-key-parity` was red on `main` and on every PR whose diff touched source. `ar`, `ru`, `pt`, `es`, `fr`, `de`, `ko` and `ja` had no `console.ai.pendingDrafts` block at all — eight packs x five keys. objectui#5696 landed the feature `en`-only; objectui#5697, titled for the locale packs, reached `zh` only. Source-free diffs skip the shard that runs the parity test, which is why the breakage survived several merges. Each pack keeps its own conventions rather than `en`'s: all eight quote with `"`, `ru` puts the number last (`...: {{count}}`) as it already does for the sibling `home.pendingDrafts` counts, and `ja` takes the full-width `:` before `{{detail}}` because that value is a runtime message rather than a single token. Both deviations carry an in-pack note. Terminology comes from each pack's existing publish-bar vocabulary so the two banners read alike. Both interpolations survive verbatim everywhere - `{{count}}` in `count`, `{{detail}}` in `publishedWithFindings` - checked against the evaluated packs rather than by eye. The unrelated `home.pendingDrafts` block (`message` / `cta`) is a different node and is untouched. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012u2pRjcqAYtoEjgr3wwhnK
Contributor
✅ Console Performance Budget
The eager closure is every chunk the entry reaches through static imports — what the browser fetches and parses before the app renders. The entry chunk on its own is a small fraction of it. 📦 Bundle Size Report
Size Limits
|
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.
Fixes #5705
mainis red onpackages/i18n/src/__tests__/all-locales-key-parity.test.ts: thestanding unpublished-changes bar's
console.ai.pendingDraftsblock existed only inenandzh. The other eight packs —ar,ru,pt,es,fr,de,ko,ja— had no such block at all. Eight packs x five keys.
#5696 landed the feature
en-only; #5697, titled for the locale packs, reachedzhonly. Source-free diffs skip the shard that runs this test, which is why it survived
several merges.
What changed
The five keys —
count,publish,published,failed,publishedWithFindings—added to the eight packs, translated, at
en's position: first key insideconsole.ai, immediately beforeusage. Insertion was anchored on the parsedai: {line, never on a grep forpendingDrafts— there are two unrelatedblocks by that name and an occurrence count answers wrongly in both directions.
Nothing else: 60 insertions, 0 deletions, 8 locale files plus the changeset. No
reordering, no other parity gaps touched.
Each pack keeps its own conventions rather than
en's:"(enuses').ruputs the number last (...: {{count}}), the convention that pack alreadydocuments for the sibling
home.pendingDraftscounts.jauses the full-width:before{{detail}}, because that pack's documentedrule is full-width when the interpolation carries a message and half-width when it
carries a single token —
{{detail}}is a joined list of runtime probe messages.how these files already annotate translation choices.
Terminology is lifted from each pack's existing publish-bar vocabulary
(
home.pendingDrafts,console.ai.seedWarn,console.ai.publishFailed) so the twobanners read alike.
Verification
All results below are at the final commit,
739dd78b6.Red leg, captured before the fix (
origin/main@83ec61881):...identically for
ko,de,fr,es,pt,ru,ar. Exactly the five keys,nothing else.
Green leg — same file,
--reporter=verbose, so the assertions are named ratherthan aggregated:
That includes all nine
%s defines every en keycases, all nine of the sibling%s defines no key that en lacks(the other direction — a mis-nested key would failhere),
placeholders match en in every pack, and both non-vacuity guards.Placeholders, checked mechanically against the evaluated packs rather than the
file text — for all ten packs,
console.ai.pendingDraftshas exactlyen's fivekeys,
{{count}}is present incount,{{detail}}inpublishedWithFindings, theper-key placeholder shape equals
en's, and the unrelatedhome.pendingDraftsblockstill has its
message/ctaand gained nothing:Scoped suite — the edited package plus the one provable consumer of these keys
(
packages/app-shell/src/console/ai/PendingDraftsBar.tsx, found by grepping everycall site of
console.ai.pendingDrafts; it is the only one):This is a provable superset for an i18n-data change, not app-shell's full 493-file
suite.
Gates:
check-i18n-en-drift.mjsenvalue changedcheck-i18n-call-site-keys.mjscheck-i18n-dead-keys.mjscheck-control-bytes.mjsOK (scanned 4756 tracked text file(s); skipped 85 binary)pnpm --filter @object-ui/i18n type-checktsc --noEmit && tsc -p tsconfig.test.json)pnpm --filter @object-ui/i18n lint34 problems (0 errors, 34 warnings)— all pre-existing, none in a locale fileLint narrowing, stated as a measurement:
eslint --no-inline-config --format jsononthe diff reports 8 files, 0 errors, 0 warnings. The full repo population eslint
itself resolves is 3544 files; that run also reports 0 findings in any
packages/i18n/src/locales/file. The config sets noprojectService/project:, so linting is not type-aware and this diff cannot move the verdict of anyuntouched file.
Not in scope
mainis separately red onBuild Docs(#5668) andTest (coverage)(#5402). Thoseare not addressed here and remain open.
The card also raises whether the parity test should run in a cheap, unskippable job
rather than only inside a shard that a source-free diff skips — that is a real gap
(it is why this survived several merges) but it is a CI-topology decision, left for
the maintainer rather than ridden along on a blocker fix.
Generated by Claude Code