Skip to content

feat(ui): the rest of the Studio strings and the metadata preview panes move into the studio i18n namespace (#25922 slice S5) - #26942

Merged
objectstack-fleet[bot] merged 4 commits into
mainfrom
claude/project-thread-n6i8le
Oct 28, 2026
Merged

objectstack-fleet[bot] merged 4 commits into
mainfrom
claude/project-thread-n6i8le

Conversation

@objectstack-fleet

Copy link
Copy Markdown
Contributor

Requested by Warren · project thread

Part of #25922

Clause-②: no
Metadata-protocol: none

维护者速读

  • 改了什么:Studio 设计器表里除 engine.studio.inspector 之外的全部 engine.studio.*(309 键,含上一片顺延的 rules),加上 19 个元数据预览面板家族(engine.*Preview、engine.previewShell,287 键),共 en、zh 各 596 键,从 app-shell 私有表搬进 @object-ui/i18n 的 studio 命名空间,文案一字未改,调用点不动。
  • 为什么改:执行 app-shell: a published library that is 66% Console product surface — retire the 67 zero-reference exports now, decide the split, and fold the second i18n table into @object-ui/i18n #25922 裁决 6431032267(Q2 = A,6431234244 维持),这是 (M) 的第 5 片(S5),派单 6453707890。
  • 风险与回滚:与前几片相同,zh 用户首次打开这些页面时标签先显示英文、zh 分片到达后同一挂载重渲染为中文;回滚即 revert 本 PR。
  • 先看:ui/packages/i18n/src/namespaces/studio/en.ts 末尾的 S5 段,再看钉测试新增的家族下限与 AddFieldPopover.studioNamespace-25922 的改写。
  • 两分钟验证:cd ui && pnpm run check:i18n-designer-parity && pnpm exec vitest run packages/app-shell/src/views/metadata-admin/inspectors/inspectorStrings.studioNamespace-25922.test.ts,应全绿。
  • 需要你做的:无,席位落地。

What changes

Why

Ruling 6431032267 Q2 = A (upheld by 6431234244): the designer table becomes one lazy @object-ui/i18n namespace, moved in slices.

Tests

  • Pin widened: inspectors/inspectorStrings.studioNamespace-25922.test.ts gains floors for engine.studio. as a whole (600), for rules, interfaces and designer, and for each of the 19 preview families. Every key in each family must resolve through t() to the namespace value in en-US, zh-CN and de-DE.
  • zh preloads (forced edits). Each suite below reads a moved S5 zh row synchronously, so it now loads the zh catalogue first with a top-level await loadStudioCatalogue('zh'). No assertion changed.
    • 10 dom suites:
      • in metadata-admin/previews/: AppPreview.areas-11027, DashboardPreview.i18nTitle-10847, ScreenPreview.fieldProjection-11190, automationPreviews.i18n-10862, previewStrings.i18n-10848
      • in metadata-admin/: studio-locale.i18n
      • in studio-design/: CreateItemDialog.notDerived-13389, ObjectFormDesigner.dndAnnouncements-11802, ObjectFormDesigner.roleDescription-11872, StudioDesignSurface.interfacePolish
    • 2 unit suites: studio-design/StudioDraftMark.test.ts and studio-design/metadataError.authorRefusal-11785.test.ts. Both are in the unit project (isolate: false). Each passed in the full run only because an earlier file had already loaded zh, and failed when run alone.
  • AddFieldPopover rewritten (forced edit). studio-design/AddFieldPopover.studioNamespace-25922.test.tsx from slice 1 contrasted the namespace with "a key still in the app-shell table". No engine.studio.* key that this popover renders is left in the table. The test now checks the same zh flow (English first, then Chinese on the same mount) for the field labels, read from the namespace directly, and for the chrome key engine.studio.cancel, read through t().

The sweep

I delayed the zh loader in namespaces/studio/index.ts by 4000 ms (scripts/ablation-replace.mjs --hold, restored byte-identical). Under that delay I ran every app-shell test that names zh (437 files), then each of the 54 unit-project files alone.

  • Before the fixes: 12 files failed in the full run and 2 failed when run alone.
    • One of the 12 is i18n/src/__tests__/studio-namespace-lazy.test.tsx. It fails by construction under the delay, because its findByText waits 1 s against a 4 s delay.
    • The other 13 are the suites listed above.
  • All 13 come from S5 itself. I checked out main's two homes, kept main's versions of the 13 test files, and ran them under the same delay. All 13 pass on main, so this sweep found no leftover from S1–S4.
  • After the fixes:
    • The 13 fixed files, the pin and the equivalence check pass with the delay and at normal speed (Tests 211 passed (211) both times).
    • The two unit suites pass alone, delayed and normal.
    • After the merge, the new main test PageBlockCanvas.addListView-26794, the pin and both block-config tests pass under the delay.

Acceptance notes

  • Every moved key resolves identically before and after. This was a one-off measurement and is not committed. I read the 596 + 596 base values by AST from the table at 57820085. I compared them with t() and tOptional() on this branch, with zh resident: the base en value in en-US, en, de-DE and fr, and the base zh value in zh-CN, zh and zh-TW. Result: 4,172 lookups, 0 differing.
  • Ablations (mutation landed by anchor count and blob, restored byte-identical to HEAD):
    • Removing the ?? studioString(key, locale) arm from lookupString turns 46 tests red: the pin's t() case for all 44 families, its zh-only case, and the equivalence check. The equivalence check reports 4,172 of 4,172 lookups differing.
    • Altering one moved zh row (engine.actionPreview.empty) makes the equivalence check report exactly 3 differing lookups (zh-CN, zh, zh-TW). The pin stays green, as designed.
  • Eager bundle: not re-measured locally, as in S2–S4. CI's Build & E2E UI measures it.

Verification

At 1e3fed1d (the merge of main into the two slice commits).

Tests and gates
  • pnpm --filter @object-ui/i18n --filter @object-ui/app-shell run type-check: VERDICT command-exit 0.
  • node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack: 34 commands, each exit 0, including pnpm --dir ui exec vitest run scripts/ (Test Files 178 passed | 2 skipped (180)). --ran: 34 derived, 34 run, 0 NOT-MEASURED.
  • ui check:i18n-designer-parity, check:i18n-dead-keys, check:i18n-drift (0 en values changed) and check:i18n-keys all exit 0, before and after the main merge. check:new-line-citations: exit 0 (0 new citations). node scripts/check-nul-bytes.mjs: exit 0.
  • Changed lines: 2,922 (+1,520 / −1,402) over 18 files, under the 3,000 threshold.

Human Minimum

  • 1. No packages/spec change.
  • 2. No new names; the only new file is the changeset.
  • 3. No formatter ran; pnpm lint is CI's.
  • 4. One card slice, one branch off main, one pull request.
  • 5. Patch changeset with both declaration lines.
  • 6. n/a.
  • 7. No hand edits to generated or release-owned files.
  • 8. English.

Generated by Claude Code

…es move into the studio namespace (slice S5)

Every remaining engine.studio.* row except engine.studio.inspector.*, and
the preview panes' engine.*Preview / engine.previewShell rows (the doc,
book, flow, page-block and translation previews stay for later slices),
596 keys in en and in zh, leave app-shell's designer table for
@object-ui/i18n's lazy studio namespace, text unchanged. lookupString
already asks the table first and the namespace second, so no call site
changes.

Claude-Session: https://claude.ai/code/session_01JQwxbX9LnJhjTQPJEmoBYi
Co-authored-by: Claude <noreply@anthropic.com>
…ed, zh preloads

The pin gains floors for engine.studio as a whole, its three largest S5
families and each preview family. Ten dom suites and two unit suites
that read moved S5 zh rows synchronously make the zh catalogue resident
first; the sweep ran every app-shell test naming zh with the zh loader
delayed 4000 ms, and each unit-project test alone. AddFieldPopover's
lazy-namespace test no longer has a table key to point at, so it reads
its chrome key through t() from the namespace.

Claude-Session: https://claude.ai/code/session_01JQwxbX9LnJhjTQPJEmoBYi
Co-authored-by: Claude <noreply@anthropic.com>
…-n6i8le

# Conflicts:
#	ui/packages/i18n/src/namespaces/studio/en.ts
#	ui/packages/i18n/src/namespaces/studio/zh.ts
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

维护者速读

  • 改了什么:除 engine.studio.inspector.* 外剩余的全部 engine.studio.*(含 engine.studio.rules)以及 19 个元数据预览面板族(engine.*Preview.*、engine.previewShell.*),中英各 596 个 key,从 app-shell 私有表搬进 @object-ui/i18n 的懒加载 studio 命名空间;原文不变,调用处不变。
  • 为什么改:执行裁决 6431032267 Q2 A(维护者「同意」,6431234244 维持);这是 S5,私有表再少约 1.4k 行。
  • 风险与回滚:中文首次打开相关页面时多一次懒加载;查找前后一致(4172 次查找 0 差异)。revert 即可。
  • 先看:ui/packages/i18n/src/namespaces/studio/en.ts 末尾的 S5 段与 inspectorStrings.studioNamespace-25922.test.ts 的新家族下限。
  • 两分钟验证:pin 按家族逐 key 比对中英两份,消融即红。
  • 需要你做的:无,席位落地。
  • 席位意见:席位在合并 main 后的头上独立复算:中英各删 596 个 key、加 596 个 key,值逐字相同,两边无重复,私有表只剩 engine.studio.inspector;比「约 650」少,是为守住 3000 行门槛,文档与书籍预览留给 S6。

席位核对

ACCEPT · seat domain:ui#1 · session_01JQwxbZeBv2y91towxasSUT · head f6d70b87 · 2026-10-27T23:24Z

  1. Shape: slice S5 of app-shell: a published library that is 66% Console product surface — retire the 67 zero-reference exports now, decide the split, and fold the second i18n table into @object-ui/i18n #25922 (Part of #25922); 18 files, +1520/−1402 (2,922 lines, under the 3000-line threshold). Rows leave metadata-admin/i18n.ts (−1379) and land in namespaces/studio/{en,zh}.ts (+747/+638). 12 suites gain the zh preload (10 dom, 2 unit), AddFieldPopover.studioNamespace-25922 drops its table key now that engine.studio.cancel lives in the namespace, the pin gains per-family floors for every moved family, and a patch changeset is added.
  2. Premise measured: the seat parsed both tables on the merge base 5ec398dc and on the head. In en and zh alike, 596 keys left ENGINE_STRINGS_*, the same 596 entered STUDIO_* with byte-identical values, no key sits in both homes, no row that stayed changed, and the only engine.studio.* family left in the app-shell table is engine.studio.inspector (feat(spec,ui)!: a record opens one way per object — navigation.mode keeps drawer (the default), page, new_window and none; modal, split and popover are retired; the split pane becomes a reader preference #26804 in flight). engine.translationPreview (feat(spec): a hook declares its refusal catalogue, and its body refuses by code, answered in the caller's language #26831) and the page-block canvas (feat(app-shell): the page designer's add-block picker offers the list view block #26915) stay in place. The same check held on the pre-merge head 1e3fed1d. The merge commit resolves only the namespace tails; the S5 section follows fix(app-shell): Studio Access refuses a new permission set over a taken identifier and can discard a set's draft #26916's access rows. Dev: 4,172 lookups, 0 differ; both ablations red, restored. The delayed-loader sweep (zh 4000 ms) found 13 S5 reds, each green on main under the same delay, and fixed all 13. On the merge it re-ran over 448 files, including the 11 the merge brought in; its only red is studio-namespace-lazy, by construction.
  3. Gates / check-runs: On head f6d70b87, 43 success · 9 skipped · 0 failed · 0 pending; mergeable_state: clean. Dev's local run on 1e3fed1d: 34/34 derived gates exit 0, --ran 0 NOT-MEASURED; after the merge, check:i18n-designer-parity, drift, dead-keys and keys exit 0, and type-check exits 0.
  4. Accepted deviations: about 600 keys moved, not "about 650", to stay under the 3000-line threshold. The doc and book previews, and flowPreview with the flow families, go to S6. The 34 gates were not re-run on the merge commit, since the PR's diff against main is unchanged in content; CI on the merged head is the verdict.
  5. Out of scope: none filed. Serial point for the next lander: open PR fix(metadata-protocol,runtime,app-shell)!: refuse a save or draft publish naming a package that is not installed #26920 (metadata: the save door and the package publish door accept a package id that is not installed (object, dashboard, page …), storing and even publishing items into a phantom package; Studio renders a writable builder for it #26708, another lane) adds engine.studio.notFound.{package,pillar} inside the app-shell region this PR deletes. Whichever lands second takes a textual conflict there, and the rows belong in namespaces/studio/{en,zh}.ts. They resolve from either home, since the table is read first. Skills-docs: none — strings move between homes, no metadata-protocol change.
  6. Landing: not Tier H; the seat readies and arms auto-merge. S6 (engine.studio.inspector once feat(spec,ui)!: a record opens one way per object — navigation.mode keeps drawer (the default), page, new_window and none; modal, split and popover are retired; the split pane becomes a reader preference #26804 lands, the remaining preview families, flow families) follows; S7 (the ci.yml step) stays Tier H.

Generated by Claude Code

@objectstack-fleet
objectstack-fleet Bot marked this pull request as ready for review October 27, 2026 23:24
@objectstack-fleet
objectstack-fleet Bot added this pull request to the merge queue Oct 27, 2026
Merged via the queue into main with commit 49b5059 Oct 28, 2026
53 checks passed
@objectstack-fleet
objectstack-fleet Bot deleted the claude/project-thread-n6i8le branch October 28, 2026 00:11
os-project-manager pushed a commit that referenced this pull request Oct 28, 2026
Brings in #26942, which moves the Studio strings into the studio i18n
namespace. The two Studio not-found strings this branch adds move with
them: from app-shell's metadata-admin table into
@object-ui/i18n's studio namespace (en and zh), beside desktopHint.

Claude-Session: https://claude.ai/code/session_01FEkQ5nhhuhjVQJ8R3qK9UB
Co-authored-by: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation size/xl tests tooling

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants