Repository navigation
fix(app-shell): the curated page, report and dashboard inspectors name a select's options in Chinese under zh-CN - #37698
Conversation
…e a select's options in Chinese under zh-CN The console's metadataForms overlay named a select's row but not its options, so under zh-CN the page Type and Record action selects and the report and dashboard Default Period selects listed English choices beside Chinese labels. The overlay now carries those four rows' option names in the options slot resolveMetadataFormLabels reads, copied from the platform's zh-CN pack and pinned byte-equal to it (metadata-form-option-names.test.ts). The console-side Default Period renaming (default-period-labels.ts) is retired; #36835's pin now also holds the zh names to the period chip's rows. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01L6bhgUpnvPnJ1hR74pUrVj
|
repo:objectstack#2 · os-sales · session_01L6bhgV6i8jfWwSXjpWJrjA Contract reviewServed-tier: Inputs: card #37607 (body, triage comment 7196185847, claim comment 7203073274), the PR body, its 8-file list, the net diff against merge-base ① Derived judgments
② Semver level
Clause-②: no — confirmed. No published accept-set, schema or exported surface moves. ③ Boundary flags
Implemented-by: VERDICT: PASS |
|
repo:objectstack#2 · os-sales · session_01L6bhgV6i8jfWwSXjpWJrjA 席位核对 — ACCEPT · head 8df05bb · card #37607 · area s2-ux-T · 2026-11-26T21:28ZL1 checklist
Tier: S. Landing: ready + auto-merge by this stroke. |
Requested by Sales · project thread
Fixes #37607
Clause-②: no
Metadata-protocol: none
Skills-docs: none (no page under
skills/**names the console's curated inspector overlay)维护者速读
What changes
ui/packages/app-shell/src/views/metadata-admin/metadata-form-zh-cn.ts: thepagerowstypeandinterfaceConfig.recordActionand thereportrowdateRange.defaultRangegainoptions: { <value>: … }, the slotresolveMetadataFormLabelsreads since feat(spec): Studio metadata-form select choices are translatable (metadataForms options slot) #37569. Each map is the platform pack's map (packages/platform-objects/src/apps/translations/zh-CN.metadata-forms.generated.ts), copied as is. The header now lists option names among the strings the table carries.metadata-form-i18n.ts: thedashboardrowdateRange.defaultRangegains the same map.default-period-labels.tsretired, with its calls inReportDefaultInspector.tsxandDashboardDefaultInspector.tsx(and their now-unuseduseObjectTranslation). It renamed the Default Period options from the console'sdashboard.filters.range.*rows for zh only; the overlay names them now, and the platform words equal those rows (pinned below).metadata-form-option-names.test.ts:ZH_CN_SPEC_FORMSequals the platform pack's map, byte for byte (JSON.stringify), and the table names exactly the three expected rows;page/report/dashboard/viewforms, so a new one is copied rather than missed;getPageForm/getReportForm/getDashboardFormrenders underzh-CNreads the pack's name (this is what pins the dashboard map, which lives inmetadata-form-i18n.ts);en-UScontrol keeping the spec's English.The pack is read from the checkout's source with a run-time
import()(a data-only module whose one import is type-only).ReportDefaultInspector.defaultPeriodLabels-36835.test.tsx: no longer imports the retired helper. A new case pins the zh namesgetReportForm('zh-CN')gives to the zh pack'sdashboard.filters.range.*/dashboard.filters.customrows the period chip reads, beside the existing en case; the rendered zh case is unchanged and passes through the new route.@object-ui/app-shellpatch.Small calls made here (no card):
default-period-labels.tsis retired in full rather than reduced: the slot now covers everything it did (it was zh-only), and the period-chip parity it guarded is kept by the 报表检视器「期间与导出」:默认期间下拉显示原始值(this_month),没有选项名 #36835 test.Why
Out-of-diff note 1 of the Contract review record 7195508409 on PR #37569: under zh-CN the curated page, report and dashboard inspectors showed English select options beside Chinese labels, and #36950's slot did not reach them.
Verification
Head
8df05bb67:pnpm --dir ui exec vitest runonmetadata-form-option-names.test.ts,metadata-form-i18n.test.ts,page-schema.test.ts,report-schema.test.ts,dashboard-schema.test.ts,ReportDefaultInspector.test.tsx,ReportDefaultInspector.i18nTitle.test.tsx,ReportDefaultInspector.defaultPeriodLabels-36835.test.tsx,DashboardDefaultInspector.test.tsx,DashboardDefaultInspector.layoutColumns-11796.test.tsx: 10 files, 96 tests passed.eslinton the 6 touched source and test files: 0 errors.check:test-source-alias,check:changeset-fixed,uicheck:changeset-claims: exit 0.node scripts/pm/overlap-check.mjs: clean (sharesmetadata-form-zh-cn.tswith refactor(spec)!: rename the Studio helper defineForm to defineMetadataForm and its modules to *.metadata-form.ts #37366, merges cleanly).Human Minimum
packages/specholds no runtime logic (not touched).main, one pull request.packages/specnot touched.content/docs/references/,packages/*/CHANGELOG.mdorcontent/docs/releases/.🤖 Generated with Claude Code
https://claude.ai/code/session_01L6bhgUpnvPnJ1hR74pUrVj
Generated by Claude Code