Repository navigation
fix(i18n): the ru tab badge and reaction chip and the ar tab badge and comment thread read right at every count (objectui#10242) - #10415
Conversation
…b badge, reaction chip and comment thread (objectui#10242) The tab-count badge, the activity-feed reaction chip and the comment thread pick their plain count key at every count but one. In ru and ar that key held a single noun form, which is wrong at 2-4 and 21 in Russian and at 2 and 11+ in Arabic. The count-not-one half of five values becomes a count label (the objectui#10024 device), with the key set and call sites unchanged. Co-authored-by: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BP8CMtACxTdLjqR6rhd33C
…count labels (objectui#10242) The marketplace/preview namespace suite asserted, as a premise, that every pack's common.itemCount is the count, a space, then the unit noun. That pinned the exact ru and ar values this card turns into count labels. The other six packs keep the exact premise; ru and ar expect their label. Co-authored-by: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BP8CMtACxTdLjqR6rhd33C
✅ 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
|
…(objectui#10242) The opening sentence claimed Arabic on the activity-feed reaction chip too, but ar detail.reactionCount is not one of the five values this change rewrites. Russian is now claimed on the badge and the reaction chip, Arabic on the badge and the comment thread. A later sentence that read as if every surface's plain key held a single noun form is scoped to the ones that did. The frontmatter is unchanged. Co-authored-by: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BP8CMtACxTdLjqR6rhd33C
✅ 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
|
Contract reviewServed-tier: Rendered by an isolated review subagent spawned by the ① Derived judgments
② Semver level
③ Boundary flags
Implemented-by: VERDICT: PASS Seat note: both flagged body sentences are corrected in the body written in this act. The loop covers eight packs, not every pack, and the sibling-keys card is filed as objectui#10425. Generated by Claude Code |
Fixes #10242
Clause-②: no
What was wrong
The tab-count badge's accessible name, the activity-feed reaction chip and the comment thread each pick their
…Onekey at exactly one and the plain key at every other count. On the five values this card names, the plain key held a single noun form, which is wrong at some of the counts it serves:ruat 2-4 (few) and 21 (one),arat 2 (two) and from 11 up (many,other).In this body the i18next placeholders are spelled COUNT and EMOJI; the tree uses the double-brace form.
The pin reproduced the defect before any value changed:
Tests 15 failed | 15 passed (30). The received strings were the shipped ones:2 элементов,21 элементов,👍 2 реакций,2 عناصر,11 عناصر, and a thread header2 تعليقاتwith tooltip2 تفاعلات.The change: the objectui#10024 device, key by key
The count-not-one half of the five values named on the card becomes a count label: a label, a colon, then the number, so no noun has to agree with it.
common.itemCountCOUNT элементовЭлементов: COUNTdetail.reactionCountEMOJI COUNT реакцийEMOJI Реакций: COUNTcommon.itemCountCOUNT عناصرعدد العناصر: COUNTcollaboration.commentCountCOUNT تعليقاتعدد التعليقات: COUNTcollaboration.reactionCountCOUNT تفاعلاتعدد التفاعلات: COUNTrumatches the controls that already read right on the same two-key convention,collaboration.commentCount(Комментариев: COUNT) andcollaboration.reactionCount(Реакций: COUNT), anddetail.repeaterItemCount(Элементов: COUNT).aruses theعدد …: COUNTshape ofsearch.resultsCountPlural(objectui#10240),calendar.a11y.dayCellandai.formAssist.suggestionCount. عدد ("number of") heads a fixed phrase with the definite plural, and the number follows the colon as a value, so the dual, 3-10, 11-99 and 100+ rules never apply.runow reads right on the badge and the reaction chip, andaron the badge and the comment thread. Therucomment thread already did.ardetail.reactionCount(the Arabic reaction chip) is not in this card's key list and is unchanged; see Acceptance notes._few/_twokey:all-locales-key-parity.test.tsholds every pack toen's key set..changeset/10242-ru-ar-count-labels.mddeclares a patch for@object-ui/i18n.File surface: one file widened by the seat
The claim (comment 5822573875) named
ru.ts,ar.ts, one pin and one changeset. The seat's amendment (comment 5824097794) addedpackages/i18n/src/__tests__/marketplace-preview-namespace-3546.test.tsx, for its premise assertion only.That assertion required eight packs'
common.itemCountto be COUNT, a space, then the unit noun, which pinned exactly theruandarvalues this card corrects. It is re-derived, not loosened: the other six packs keep the exact premise, andruandarexpect their count label. The phrase checks onpreview.history.itemsbelow it are untouched.Pin
packages/app-shell/src/views/__tests__/countLabels.ruAr-10242.test.tsx, beside the objectui#10024 pin and in the same shape:createI18n, with the booted language asserted, andtis not mocked.enandruonly, sinceardetail.reactionCountis outside the card).app-shellis the one package that depends on all three:page:tabsfrom@object-ui/components,ReactionPickerfrom@object-ui/plugin-detail, andCommentThreadfrom@object-ui/collaboration. The reaction chip passescountas a number, so i18next's own plural lookup is in the path.ru2, 5 and 21 andar2, 3 and 11, plus 1 for the untouched singular half.enand therucomment thread are controls.Intl.PluralRulescategories.Onehalf.Evidence
The code evidence is at
6aa965ae7. HEADf0645e02achanges only the changeset's prose: its opening sentence no longer claims Arabic on the reaction chip. Atf0645e02a,check-changeset-presence,check:changeset-claims,check-changeset-no-major,-fixed,-overwrite,check:pending-changeset-literals,check:control-bytesandcheck:new-line-citationsall exit 0.Tests 30 passed (30).bac9cd4c5, which carries the values and the pin; the later commit changes only the marketplace premise. It used objectstack'sablation-replace.mjs, one nested leg per value, and every leg reported the mutation landed. Result:Tests 15 failed | 15 passed (30), identical to the reproduction. Every leg reportedok restored: blob == HEAD, an outer hash proof matched both packs to HEAD, andgit diff HEADwas empty.pnpm exec vitest runfrom the repo root readTest Files 83 passed (83),Tests 1493 passed (1493). The set was:packages/i18n/(includingall-locales-key-parityand the marketplace suite);defaults-maps-mirror-en-pack,page-tabs-count-badge-i18n,ReactionPicker.a11yNames;comment-thread-i18n,comment-thread-no-provider-fallback,presence-avatars-i18n;LocationField.residueI18n-6888,SettingsView.i18n-4024, andscripts/__tests__/check-i18n-dead-keys.test.ts.main:mainmoved after this branch was cut. It changed none of the touched files, but it did changepackages/i18n/src/provider.tsx(objectui#10382), so this branch's diff was also applied toa70719765in a throwaway tree.packages/i18n/plus the pin and the consumer suites readTest Files 76 passed (76),Tests 1257 passed (1257).check:i18n-keys,check:i18n-drift("No en value changed in this range") andcheck:i18n-dead-keys;check:control-bytes, andcheck:new-line-citations("0 new citation(s)");check-changeset-presence,-no-major,-fixedand-overwrite("1 changeset(s) added, 0 modified, 0 deleted");check:changeset-claims,check:pending-changeset-literals,check-test-path-rootsandcheck-vi-mock-override-shape.@object-ui/i18nexits 0 at6aa965ae7, after building its dependency closure.@object-ui/app-shellexited 0 atbac9cd4c5, afterturbo run build --filter=@object-ui/app-shell^...ran 28 of 28 tasks. The later commit does not touchapp-shell.tsc -p packages/app-shell/tsconfig.test.json --listFilesOnlylists the new pin.eslint --print-configshows noparserOptions.projectorprojectService, so no type-aware linting runs, and this diff cannot move any untouched file's verdict. The fullpnpm lintandpnpm testruns are CI's.Acceptance notes
=== 1two-key switch, and none is changed here:ardetail.reactionCount(ReactionPicker);arcollaboration.presentUserCountandcollaboration.moreUserCount(PresenceAvatars);ruandarlist.recordCount(ListView);arlookup.recordCount(RecordPickerDialog);ardetail.revisionFieldsChanged(PointInTimeRestore);arsearch.itemsAvailable(SearchResultsPage). Its value is also pinned insearchItemsAvailable-plural-9664.test.ts.عددplus the definite plural. objectui#9266 used a bare definite label (العناصر: COUNT) forpreview.history.items; the dispatch asked for the objectui#10240 form.Review-tier question
The closing sentence of
.changeset/9664-search-items-available-plural.mdsaysarsearch.itemsAvailable"now uses the same noun pair thatar'scommon.itemCount/itemCountOnealready uses". After this PR,arcommon.itemCountcarries that noun only asالعناصر, inside a count label. The sentence is loosened, not falsified, because the lemma pair عنصر / عناصر is unchanged. It is left unedited because it is outside this card's surface. Does the review tier want it reworded before release?Generated by Claude Code