Repository navigation
fix(spec,app-shell): zh-CN view panel reads Chinese on every row of its collapsed sections - #30356
Conversation
…get catalog keys The view form declared selection, pagination, userFilters, appearance, userActions, navigation and sharing as composites with no children, so the i18n extractor emitted no key for any of their rows. Each child is now declared with the hint the panel already showed (its schema description), userFilters.fields is enumerated as a repeater with titled row properties, and the retired navigation.view / sharing.type tombstones are no longer offered. Claude-Session: https://claude.ai/code/session_01WGufzjGQVFPCizmQreyKkv Co-authored-by: Claude <noreply@anthropic.com>
Regenerated the metadata-forms catalogs for the newly declared view children and translated every new zh-CN leaf. ja-JP and es-ES carry their own text for the six userFilters.fields row properties (the repeater-row guard refuses an en echo there); their other new leaves are en fills, as the extractor leaves them. Claude-Session: https://claude.ai/code/session_01WGufzjGQVFPCizmQreyKkv Co-authored-by: Claude <noreply@anthropic.com>
…llapsed sections The console overlay copies the platform's zh-CN leaves for every newly declared view composite child, and the metadata-forms catalogs carry ja-JP and es-ES text for them too (the catalog-wide echo ledger reads zero in every translated locale). Pins: the overlay group in metadata-form-i18n.test.ts and a catalog test deriving its population from the form; the round-10 positive control moves 701 -> 731. Claude-Session: https://claude.ai/code/session_01WGufzjGQVFPCizmQreyKkv Co-authored-by: Claude <noreply@anthropic.com>
Before it was enumerated, userFilters.fields rendered as the panel's auto-detected master-detail table with a required marker on Field. The declared repeater now asks for the grid layout and marks the required row property, so the panel keeps that look with translated column heads. Claude-Session: https://claude.ai/code/session_01WGufzjGQVFPCizmQreyKkv Co-authored-by: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WGufzjGQVFPCizmQreyKkv Co-authored-by: Claude <noreply@anthropic.com>
…not offer The reconciliation walk resolves view.userFilters to the page-shaped UserFiltersSchema; the list arm the view form lays out refuses tabs, showAllRecords and allowAddTab, so they get omit rows. Claude-Session: https://claude.ai/code/session_01WGufzjGQVFPCizmQreyKkv Co-authored-by: Claude <noreply@anthropic.com>
📓 Docs Drift CheckThis PR changes 2 package(s): 17 hand-written doc(s) name something this change touched — list omitted above 15 rows. Re-derive on the tree named below: ⛔ 11 release-owned page(s) also affected — read-only, see AGENTS.md Documentation Guardrails. What this run could not see
Coarse fallback — 170 page(s) merely mention a changed package (the pre-#9192 predicate, kept for the deliberately-wide backstop): Which tree this was computed onThis run read A worktree cut from an older # while this PR is open — GitHub drops the merge commit once it closes
git fetch origin 39cf8e9e9420870b402c0cc6127db6f6336693ac && git checkout 39cf8e9e9420870b402c0cc6127db6f6336693ac
# afterwards, rebuild it from the two parents, which stay fetchable
git fetch origin 1013ef11617b578c6525e50300f74f2e0b072b3c fa3694dfa37337f8d125d75bcdde5a9d4c7bbcdd && git checkout -B drift-repro 1013ef11617b578c6525e50300f74f2e0b072b3c && git merge --no-ff fa3694dfa37337f8d125d75bcdde5a9d4c7bbcdd
node scripts/docs-audit/affected-docs.mjs --json 1013ef11617b578c6525e50300f74f2e0b072b3c
|
|
domain:ui#1 · os-support-ai · session_01WGufzfE4V9fzZgJLrLDmMC 维护者速读(席位终稿)
席位核对 · ACCEPT · head
|
#30321 and #30259 landed first. The four metadata-forms catalogs auto-merged and `check-i18n-bundles --write` on the merged tree reproduces them byte for byte. The echo-ledger positive control is main's 702 plus this branch's thirty view row labels: 732. Co-authored-by: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WGufzjGQVFPCizmQreyKkv
|
domain:ui#1 · os-support-ai · session_01WGufzfE4V9fzZgJLrLDmMC Contract-review-claim: session_01WGufzfE4V9fzZgJLrLDmMC · head fa3694d · 2026-11-05T11:23Z Seat correction: this PR touches published schema ( |
|
domain:ui#1 · os-support-ai · session_01WGufzfE4V9fzZgJLrLDmMC Contract reviewServed-tier: Inputs read: card #30267 (body, triage 6650062714, claim 6650537881, os-dev-report 6652270137), PR #30356 body and 13-file list, the net diff Check-runs on the head as read at the time of this record: ① Derived judgments
② Semver levelChangeset ③ Boundary flags
④ Design judgment
must-fix: none. Implemented-by: VERDICT: PASS |
|
domain:ui#1 · os-support-ai · session_01WGufzfE4V9fzZgJLrLDmMC 席位核对 · ACCEPT · head
|
Requested by Yibo Wang · project thread
Fixes #30267
Clause-②: no
Metadata-protocol: none
维护者速读
view、共享type),已存的值保存时原样保留。回滚即还原本 PR。packages/spec/src/ui/view.form.ts(逐项声明子字段与提示)、packages/platform-objects/src/apps/translations/zh-CN.metadata-forms.generated.ts(中文译文)、ui/packages/app-shell/src/views/metadata-admin/metadata-form-zh-cn.ts(控制台中文副本)。pnpm --dir ui exec vitest run packages/app-shell/src/views/metadata-admin/metadata-form-i18n.test.ts,预期全部通过,其中 objectstack#30267 一组断言四个区块下每一行的名称与说明都含中文、英文对照组不含中文。What changes
viewFormdeclaredselection,pagination,userFilters,appearance,userActions,navigationandsharingastype: 'composite'with no children. The panel (SchemaForm) then derives the child rows from the JSON Schema, andos i18n extractwalks only DECLARED children, so none of those rows had ametadataForms.view.fields['PARENT.CHILD']key. A zh-CN Studio read 70 English rows across the four collapsed sections.packages/spec/src/ui/view.form.tsspells out every live child of the seven composites (plus hints onaddRecord's two existing children), and gives the rows that had no hint one. Every declared hint is byte-equal to the schema.describe()text the panel already showed, so an English console reads the same text.userFilters.fieldsis enumerated as arepeaterwithwidget: 'grid'andrequired: trueonfield, which keeps the inline table it rendered as before (the auto-detected master-detail table), now with translatable column heads.packages/spec/src/ui/view.zod.ts:UserFilterFieldSchema's six properties carry.meta({ title })(Field / Label / Type / Options / Show Count / Default Values, the strings the panel already printed). The repeater-title guard requires it for any enumerated repeater.navigation.viewandsharing.typetombstones as editable rows; the declared lists omit them, asaddRecordalready did for its two tombstones. A stored value is not dropped by a panel save:CompositeFieldwrites{ ...obj, [child]: v }(SchemaForm.tsx, the compositeonChange), so a key the form does not render is carried through unchanged, exactly as before.packages/platform-objects/src/apps/translations/*.metadata-forms.generated.ts): regenerated withnode scripts/check-i18n-bundles.mjs --write; every new leaf is translated in zh-CN, ja-JP and es-ES (the catalog-wide echo ledgers hold all three translated locales at zero en echoes). The provenance companions lose the rows of leaves that are now translated, as the regenerator writes them.ui/packages/app-shell/src/views/metadata-admin/metadata-form-zh-cn.ts): copies the platform's zh-CN leaves for every new row, leaf for leaf.Tests
packages/spec/src/ui/view-form-composite-children.test.ts(new): each composite's declared children EQUAL the schema's live keys (tombstones excluded), so a key added to a block later cannot silently drop out of the panel; each declared hint equals its schema description; the repeater's row labels equal the item titles; no retired key is offered.packages/platform-objects/src/apps/translations/view-composite-children.test.ts(new): population derived from the form; every declared child is a key in all four catalogs, the en leaf is the form's text, zh-CN never echoes en.ui/.../metadata-form-i18n.test.ts: new objectstack#30267 group, every row label and hint under the four sections contains CJK in zh-CN, a sample per composite, the two retired rows gone, and an en control that reads the spec English with no CJK.object-lifecycle-panel-echo-decisions.test.ts: positive-control count 701 → 731 (thirty new row labels, authored in all three locales).metadata-form-zod-reconciliation.test.ts: threeomitrows forview/userFilters(tabs,showAllRecords,allowAddTab). The walk resolves the block through the view union to the page-shapedUserFiltersSchema; the list arm the form lays out isObjectUserFiltersSchema, which refuses those keys.Ablation (each through
scripts/ablation-replace.mjs, mutation proven on disk, restored to HEAD):'userActions.editInline'refreshdeclaration fromuserActionspagination.pageSizelabel back toPage SizeAcceptance notes
/studio/com.example.crm/interfaces?surface=view:crm_lead.all, four sections expanded, English lines counted per section: 表格选项 5 → 0, 分页 5 → 0, 终端用户控制 44 → 9, 导航与共享 16 → 0 (70 → 9). The 9 left are theappearance.allowedVisualizationsoption chips (Grid, Kanban, Gallery, Calendar, Timeline, Gantt, Map, Chart, Tree): enum values the widget prints raw. The metadata-forms catalog has no channel for a form field's option labels (the extractor emitslabel/helpText/placeholder), so they are reported, not fixed here. en-US after: the same English rows as before, minus the two tombstone rows; theuserFilters.fieldstable still showsField* Label Type Options Show Count Default Values.view.zod.ts(six titles), the two ledger tests above, and the ja-JP / es-ES catalogs (required by the echo ledgers).Verification
Commands and readings (final head)
Head
f5483a169f(branch merged withorigin/mainc1240a3 first;git merge-treeagainst main 8c9f48f is clean).npx turbo run build --filter='!@objectstack/docs'underos-verify-lock: VERDICT command-exit 0 (13m50s).pnpm --filter @objectstack/spec test: exit 0 (an earlier run on this branch failed onlymetadata-form-zod-reconciliation→ fixed by the three ledger rows).pnpm --filter @objectstack/spec typecheck: exit 0 ·pnpm --filter @objectstack/spec check:generated: exit 0, all 14 artifacts up to date.pnpm --filter @objectstack/platform-objects test/typecheck: exit 0 / exit 0.pnpm --dir ui exec vitest run packages/app-shell/src/views/metadata-admin/metadata-form-i18n.test.ts: exit 0 (22 tests) ·pnpm --dir ui --filter @object-ui/app-shell type-check: exit 0 · eslint on the touched ui and spec/platform-objects files: exit 0.node scripts/check-i18n-bundles.mjs: all 11 bundle sets in sync ·check:i18n-stale-fill: OK.dispatch-gates --ran: 84 derived, 84 run, 0 NOT-MEASURED.check-plugin-teardown-shape --self-testfirst exited 3 (shallow clone could not read its pinned fixture commit); aftergit fetch origin 621a4876…it exits 0.🤖 Generated with Claude Code
https://claude.ai/code/session_01WGufzjGQVFPCizmQreyKkv