Skip to content

feat(spec): a record-page tab title a relatedLists entry declares is translatable (objects.OBJECT._relatedLists.LIST.label) - #36574

Merged
objectstack-fleet[bot] merged 11 commits into
mainfrom
claude/project-thread-qwdwll
Nov 23, 2026
Merged

objectstack-fleet[bot] merged 11 commits into
mainfrom
claude/project-thread-qwdwll

Conversation

@objectstack-fleet

@objectstack-fleet objectstack-fleet Bot commented Nov 23, 2026 •

Copy link
Copy Markdown
Contributor

Requested by Steve · project thread
Fixes #36528

Clause-②: yes (widening)
Metadata-protocol: added
Skills-docs: follow-up #36575

维护者速读

  • 记录页上由父对象自己命名的子表页签标题,现在可以按语言翻译;切到中文等界面时显示译文,以前不论什么语言都显示原文。
  • 属于「记录页的页签和字段分组改由父对象一处声明」专题,补上父对象给页签起名后无法翻译的缺口。
  • 翻译写错只影响该页签标题的显示文字,数据与页签顺序不受影响;删掉这条翻译即恢复原文。
  • 无

What changes

A record page's tab title that an object-form relatedLists entry declares on the parent ({ list, label, columns }) wins over the child lookup field's relatedListTitle. The field's title had a translation key; the winning title did not. It now has one, on the parent, keyed by the entry's literal list (a dotted object.field is one key, indexed directly):

objects.OBJECT._relatedLists.LIST.label
Package Change
@objectstack/spec ObjectTranslationDataSchema._relatedLists: a record of closed leaves whose one key is label (aliases name / title / heading / text onto label, like _tabs), plus the un-prefixed alias relatedLists onto _relatedLists. translateObject overlays it onto the served object's labelled object-form entries (translateObjectRelatedLists), along the locale chain, under the ADR-0029 D9.2a / ADR-0146 D2 catalog rule every other slot follows (a label that diverged from the packaged entry of the same list reads only the pair's catalog).
@objectstack/lint The extractor walk emits the key for each labelled entry; the orphan rule (translation-target-unknown) flags a key naming no labelled entry, with a distinct verdict when the object names the list but gives it no label. The shared extension fold now carries an extension's relatedLists (the .custom arrangement, ADR-0146 D10) and place record entries, so a key over a labelled tab an extension brings resolves.
@objectstack/metadata-protocol The save door's translated-echo restore puts a translated entry label back to its source text (matched by list), with the existing info advisory, so a Studio save of an object read in another language does not store the translation as the title.
@objectstack/objectql getPackagedObjectBase (the packaged base the /meta read and the form route hand translateObject, and the echo restore translates with) carries the tabs a code extender's place splices into the owner's relatedLists, by the fold's own pass (applyExtensionPlacements, so only where the owner declares relatedLists), as it already carries the fields such an extender adds. A placed title therefore compares equal to its packaged text and reads the deployment catalog. The .custom arrangement stays the customization layer, never part of the base.

Precedence is unchanged (entry label, then the child FK's relatedListTitle, then the child's plural label). Only an AUTHORED entry label is translated: an entry with no label, a bare name and a built-in tab gain nothing from the key, the rule the field-level inlineTitle / relatedListTitle docblocks state.

Where the record page reads the title. The tab title comes from deriveRelatedLists (ui/packages/app-shell/src/utils/deriveRelatedLists.ts, title: entry.label), handed to buildDefaultPageSchema as options.related (label: rel.title ?? rel.objectName). Its objectDef is useMetadata().objects, the GET /meta/object list read, which the REST read exit translates per request (translateMetadataDocument('object', …) → translateObject), outside the ADR-0156 D3 cached part. So no ui/ change is made.

Extension-brought titles. The registry fold splices a list placement (place) and the paired .custom arrangement (relatedLists) into the parent's served relatedLists. A placed title is translated from the deployment catalog because the packaged base now carries the placed entry (round 2, see Acceptance notes); a .custom title diverges from the base and reads the pair's own translations (ADR-0146 D2). Pinned through the read's real options (packagedBase from ObjectStackProtocolImplementation#getPackagedObjectBase, the accessor the REST read's packagedObjectBaseOf asks) in packages/objectql/src/registry-related-lists-label-translation-36528.test.ts.

Also: content/docs/protocol/kernel/i18n-standard.mdx (example and the key-resolution table), the regenerated content/docs/references/system/translation.mdx, authorable-surface/system.json and the strictness-ledger count, the liveness ledger evidence for objects, and .changeset/36528-related-list-label-translation.md (minor on spec, lint, metadata-protocol, objectql).

Tests

Suite What it pins
packages/spec/src/system/i18n-related-lists-label-36528.test.ts schema accepts the key (dotted list included), refuses an unknown leaf key with the strict-object message, names title → label and relatedLists → _relatedLists; overlay on a plain and a dotted entry through the type dispatch, the served object still parses; label-less, bare and built-in entries untouched; same array back when nothing matched; locale ladder and fallback chain; catalog loses to a tenant rewrite; pair translation for a changed label
packages/lint/src/i18n-related-lists-label-36528.test.ts walk emits only labelled entries; orphan rule resolves labelled keys, flags a ghost / an unlabelled / a bare entry, resolves labelled entries a .custom arrangement or a place brings (with the unlabelled control); a key over a built-in tab and over a hidden .custom entry each get their own reason; a dotted list is bracketed in the finding path; verdict and hint each at most 200 characters
packages/metadata-protocol/src/protocol-translated-echo.related-lists-36528.test.ts a translated echo restored (dotted list included) with its advisory path; an author's own title kept; a title on an entry the source leaves untitled kept
packages/objectql/src/registry-related-lists-label-translation-36528.test.ts through the read's real options (an ObjectQL engine's registry, packagedBase from ObjectStackProtocolImplementation#getPackagedObjectBase): the packaged base carries a code extender's placed tab and its title reads the catalog; a tenant's rename of that title keeps its text; a .custom arrangement's title is not in the base and reads the pair's translations
validate-translation-references.test.ts, validate-security-posture.test.ts the schema-coverage table gains _relatedLists; the extension receiver's key-read table gains place and relatedLists
Package suites and typecheck (round 2, at `6fd5bb85`, after a full `pnpm build --concurrency=2`: 120 tasks, exit 0)
  • pnpm --filter @objectstack/objectql test: Test Files 633 passed (633), Tests 14345 passed (14345). This full suite holds every in-package reader of the packaged base (protocol-packaged-object-base, protocol-meta-effective-schema, engine-validation-tenant-rewrite, registry-field-patch-bases, registry-validation-rule-by-name).
  • pnpm --filter @objectstack/lint test: Test Files 227 passed (227), Tests 9461 passed (9461).
  • Scoped: src/system/i18n-related-lists-label-36528.test.ts (spec) Tests 10 passed (10); src/protocol-translated-echo.related-lists-36528.test.ts (metadata-protocol) Tests 3 passed (3). The spec and metadata-protocol sources are unchanged in round 2; their full suites were green in round 1 (dcab40cb, 4249fe4b) and are declared to CI here, as is @objectstack/rest (it reads the base; its source is unchanged).
  • typecheck on objectql and lint: exit 0.
Ablation: each changed behaviour broken once, the suite turns red, the file restored

Each leg via node scripts/ablation-replace.mjs (anchor hits once, blob before/after printed, restored blob equals HEAD, git diff HEAD empty). Every mutated file is imported from source by the suite that runs, so no rebuild is in a leg.

  • Round 2, at 8e2ca2b7: the relatedLists spread of the placed entries removed from PlatformGlobalFacet.getPackagedObjectBase (blob 31877522 to 4549c158): the objectql pin Tests 1 failed | 2 passed (3), expected [ 'Tasks', 'crm_note' ] to deeply equal [ 'Tasks', 'Audit trail', 'crm_note' ]; restored blob 31877522 equals HEAD, git diff HEAD empty.
  • Round 1: resolver overlay wiring removed from translateObject: Tests 4 failed | 6 passed (10).
  • Round 1: walk call pushRelatedListLabels removed: Tests 1 failed | 4 passed (5).
  • Round 1: orphan rule's labelled-entry continue removed: Tests 1 failed | 4 passed (5).
  • Round 1: echo restore's restored.push for an entry removed: Tests 1 failed | 2 passed (3).
  • Round 1: extension fold's labelled-entry add removed (at f0d2db85): Tests 1 failed | 5 passed (6).
Gates
  • node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack at 6fd5bb85: 122 commands, each run with stdin closed after the full build, all 122 exit 0 (among them check:facade-delegation-only, check:i18n-walk-parity, check:dual-build-cjs-loads, check-plugin-teardown-shape --self-test).
  • --ran: Run reconciliation — 122 derived, 122 run, 0 NOT-MEASURED, 0 UNRUN.
  • node scripts/pm/overlap-check.mjs --branch=HEAD before every push: VERDICT clean exit 0.
  • CI on 8e2ca2b7: Lint · repo & tooling gates failed on this PR's own change (check-facade-delegation-only --self-test N6: packages/objectql/src/registry.ts at 6438 lines, over its 6426 ceiling; the same lane is green on main at 06c3e5ac). Fixed in 6fd5bb85 (net zero lines in the facade, the paragraph moved to the facet). The Lint & Repo Gates, TypeScript Type Check and Test UI aggregates on 8e2ca2b7 read that failure plus lanes cancelled when the push of 6fd5bb85 superseded the run; no other lane failed.

Acceptance notes

  • Merged main once (65ce7983, which carries PR feat(spec): the paired .custom package declares an installed object's field-group and tab arrangement #36517's .custom arrangement). The orphan rule's extension fold accepts _relatedLists keys for labelled entries a .custom arrangement or a place list placement brings; its docblock that said relatedLists is not translatable through an extension is corrected.
  • The extractor walk does not read objectExtensions (for fields neither): a labelled tab an extension brings is not scaffolded by os i18n extract and not counted by coverage. The resolver translates it and the orphan rule accepts its key; scaffolding extension surfaces is a separate, pre-existing gap of the walk.
  • A place entry's label applies only where the extended object declares relatedLists (the registry's rule, and the packaged base follows it). The orphan rule accepts its key regardless, the permissive direction: its fold does not read whether the target declares the list (the target may be another package's object the stack does not carry).
  • Sibling gap, not changed here: the save door's echo restore does not restore listViews copy or validations[].message, which translateObject also translates.
  • No in-repo object declares a labelled relatedLists entry today, so no shipped bundle and no coverage ratchet moves.

Round 2 (contract review 7088121343)

  • M1, route (a). getPackagedObjectBase now carries the list entries a code extender's place splices into the owner's relatedLists, computed by the fold's own pass (applyExtensionPlacements over the enabled code extenders, same child-package rule), as it carries their added fields; only the lists are read off. A placed title therefore compares equal to its packaged base on the /meta read and the deployment catalog applies; a tenant's rename still diverges and keeps its text. Every reader of the packaged base was measured: the REST /meta list and item reads and the form route (through translateObject, where translateObjectRelatedLists, new in this PR, is the only code that reads the base's relatedLists), the save door's echo restore (its relatedLists slot is this PR's, and it now restores exactly what the read translates), the share-link label (translates { name, label } only), the validation-message reader (reads validations only) and getPackagedFieldPatchBases (its bases are read for fields only). No reader outside this card's slot changes its verdict; Studio, the .custom arrangement fold and the customization-diff and divergence checks do not read this base. Pinned through the protocol accessor the REST read asks, with one ablation (red without the carry). The @objectstack/objectql changeset entry is minor, as the kind takes, with a sentence true of the head.
  • N1. A key over a built-in tab (sys_activity, sys_attachment, sys_approval_request) gets its own reason and hint, naming neither { list, label } nor relatedListTitle.
  • N2. A .custom entry with hidden: true no longer counts as labelled; its key is flagged with its own reason.
  • N3. A dotted list is bracketed in the finding path (_relatedLists["event.owner_id"]).
  • Facade ceiling. registry.ts is a facade at its 6426-line ceiling; its docblock stays net zero there and the why-paragraph lives on the facet's packagedPlacedRelatedLists.

Verification

Read first, by risk:

  1. packages/spec/src/system/i18n-resolver.ts, translateObjectRelatedLists: which entries are translated (labelled object-form only) and which catalog a label reads (valueOverridesPackagedBase against the packaged entry of the same list).
  2. packages/metadata-protocol/src/protocol-translated-echo.ts, the relatedLists block in restoreTranslatedEchoes: a save's entry label is put back only when a read of the source translates to exactly it.
  3. packages/lint/src/validate-translation-references.ts, the _relatedLists leg and the extension-fold addition.

Two-minute check, one command:

pnpm --filter @objectstack/spec exec vitest run --maxWorkers=2 src/system/i18n-related-lists-label-36528.test.ts

Expected: 10 tests pass, among them the zh-CN title served on the parent's contact and event.related_to entries.

🤖 Generated with Claude Code

https://claude.ai/code/session_01ADHkmRdKNUzzADvuRJx6UT

…ECT._relatedLists.LIST.label

The record page's tab title an object-form relatedLists entry declares on the
parent had no translation key, so it printed in its authoring language in every
locale while the child FK's relatedListTitle it overrides was translatable.

- spec: ObjectTranslationDataSchema._relatedLists (strict leaf, label only),
  alias relatedLists -> _relatedLists; translateObject overlays it onto the
  served parent's labelled object entries (ADR-0029 D9.2a catalog rule).
- lint: the extractor walk emits the key for labelled entries; the orphan rule
  flags a key naming no labelled entry.
- metadata-protocol: the save door's translated-echo restore puts a translated
  entry label back to its source.

Claude-Session: https://claude.ai/code/session_01ADHkmRdKNUzzADvuRJx6UT
Co-authored-by: Claude <noreply@anthropic.com>
… rule and echo restore

Claude-Session: https://claude.ai/code/session_01ADHkmRdKNUzzADvuRJx6UT
Co-authored-by: Claude <noreply@anthropic.com>
… ledger; changeset

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

A .custom arrangement's relatedLists entry (ADR-0146 D10) and a list placement
in place each title a tab of the served target, which translateObject
translates; the extension fold now carries them to the orphan rule.

Claude-Session: https://claude.ai/code/session_01ADHkmRdKNUzzADvuRJx6UT
Co-authored-by: Claude <noreply@anthropic.com>
…ads the meta-test scans

Claude-Session: https://claude.ai/code/session_01ADHkmRdKNUzzADvuRJx6UT
Co-authored-by: Claude <noreply@anthropic.com>
@github-actions github-actions Bot added size/l documentation Improvements or additions to documentation protocol:system tests tooling Fix lands in tooling, not a product package — enters pm:queue only with Unblocks: or a named surface labels Nov 23, 2026
@github-actions

github-actions Bot commented Nov 23, 2026 •

Copy link
Copy Markdown
Contributor

📓 Docs Drift Check

This PR changes 4 package(s): @objectstack/lint, @objectstack/metadata-protocol, @objectstack/objectql, @objectstack/spec, touching 29 documentable anchor(s). ⚠️ 2 changed file(s) yielded no anchor (packages/spec/authorable-surface/system.json, packages/spec/liveness/translation.json), so the pages documenting them are NOT COVERED by this run — this is not a clean bill of health for those files.

8 hand-written doc(s) NAME something this change touched and may need an implementation-accuracy re-verification:

  • content/docs/concepts/metadata-lifecycle.mdx (via SchemaRegistry (symbol, a top-level class))
  • content/docs/data-modeling/object-extensions.mdx (via relatedLists (literal, a string literal in getPackagedObjectBase))
  • content/docs/deployment/environment-variables.mdx (via SchemaRegistry (symbol, a top-level class))
  • content/docs/kernel/services-checklist.mdx (via SchemaRegistry (symbol, a top-level class))
  • content/docs/plugins/adding-a-metadata-type.mdx (via SchemaRegistry (symbol, a top-level class))
  • content/docs/protocol/kernel/i18n-standard.mdx (via relatedLists (literal, a string literal in getPackagedObjectBase))
  • content/docs/protocol/kernel/plugin-spec.mdx (via SchemaRegistry (symbol, a top-level class))
  • content/docs/ui/pages.mdx (via relatedLists (literal, a string literal in getPackagedObjectBase))

⛔ 2 release-owned page(s) also name something this change touched. These are read-only:

  • content/docs/releases/v17/17-4.mdx (via SchemaRegistry (symbol, a top-level class))
  • content/docs/releases/v18/18-3.mdx (via relatedLists (literal, a string literal in getPackagedObjectBase))

content/docs/releases/ is RELEASE-OWNED (AGENTS.md "Documentation Guardrails"): release
notes are written centrally at release time, and a code PR that edits them is the exact PR
that guardrail exists to stop. They are still audited — read-only. If one of them is actually
wrong, file an issue or open a dedicated docs-only PR; do not edit it here.

What this run could not see
  • 2 changed file(s) yielded no anchor (packages/spec/authorable-surface/system.json, packages/spec/liveness/translation.json) — pages documenting those are invisible to this run
  • the SDK route bridge reached 68 of 251 client-bound route-ledger rows — the other 183 have no registrar path: tail to select them, so pages documenting THEIR client methods cannot appear above, on this or any run. Of those 183: 0 are remediable by widening that discovery convention (an in-repo file declares the path; the convention did not scan it); 59 are structural — on a ledger where NOT ONE row is declared in-repo, so no discovery change reaches them at any price; 124 are undecided (no in-repo declaration, on a ledger that has other in-repo registrars — absence and an unreadable spelling are not distinguishable here). The rows themselves: node scripts/docs-audit/affected-docs.mjs --bridge-coverage
  • a page that states a rule by its inputs shares no identifier with the emitter that implements the rule, so an emitter-only diff cannot list it — not on this run and not on any run. Measured on fix(driver-sql): emit varchar(maxLength) for a text field a declared index keys on #11430: content/docs/protocol/objectql/types.mdx documents the text-family column mapping by the ObjectQL type names it maps FROM (text / textarea / html) while the diff changed createColumn; it went unlisted, and it was the page that diff falsified, in four places. No shared token exists to detect this on, so a rule your change carries has to be re-read by hand in the pages that restate it.
  • a key NAME is not a key, so the hand re-read the line above prescribes can land on the wrong schema. The same spelling is authorable on one governed type and a [REMOVED] tombstone on another for each of active, aria, joins, objects, template, tools and version (censused on [finding] tools is a key on BOTH AgentSchema (tombstoned, dead) and SkillSchema (live, cloud-attested), so a name-based search attributes skill examples to the agent key — it produced a false stop-the-line alarm on PR #19059 #19093 over the liveness ledger's governed types, top-level keys); nothing in a search result distinguishes the two, so a grep hit on a LIVE example reads as evidence about the DEAD key. Measured on fix(spec): the agent.tools liveness row says dead — it claimed live on a key the schema tombstoned #19059: content/docs/ai/agents.mdx was reported as contradicting the agent.tools tombstone over its tools: example at :161, which is inside the defineSkill({ block opened at :155 — the page was already correct. Settle ownership by PARSING the value against both schemas, never by the name: that literal PASSES SkillSchema, and as an AgentSchema it FAILS at tools with the tombstone prescription. ⛔ These names are not the whole class — a key retired through a .strict() guidance map leaves no tombstone in the walked shape and none of them here (tool.category, live as AIToolDefinition.category).

Coarse fallback — 178 page(s) merely mention a changed package (the pre-#9192 predicate, kept for the deliberately-wide backstop): node scripts/docs-audit/affected-docs.mjs --json 84853fd18eb28a5481415c2d698d04025aa629e1 → packageMentionDocs.

Which tree this was computed on

This run read content/docs from 3d4ed3cb7db98f51c3c00465d9568acba5722dad — the merge of head 6fd5bb8573ec4fbcdb37772a5e6aabbf48871b17 into base 84853fd18eb28a5481415c2d698d04025aa629e1, which is what actions/checkout gives a pull_request run. Not the PR head.

A worktree cut from an older main holds a different content/docs, so re-deriving there can legitimately return a different list — that is a different tree, not a wrong row. To answer on the same tree:

# while this PR is open — GitHub drops the merge commit once it closes
git fetch origin 3d4ed3cb7db98f51c3c00465d9568acba5722dad && git checkout 3d4ed3cb7db98f51c3c00465d9568acba5722dad
# afterwards, rebuild it from the two parents, which stay fetchable
git fetch origin 84853fd18eb28a5481415c2d698d04025aa629e1 6fd5bb8573ec4fbcdb37772a5e6aabbf48871b17 && git checkout -B drift-repro 84853fd18eb28a5481415c2d698d04025aa629e1 && git merge --no-ff 6fd5bb8573ec4fbcdb37772a5e6aabbf48871b17

node scripts/docs-audit/affected-docs.mjs --json 84853fd18eb28a5481415c2d698d04025aa629e1

⚠️ That checkout carried uncommitted changes, so the commit above does not fully identify what was read.

Advisory only, and a precision-first one (#9192): a page is listed because it names a
symbol, wire route or SDK method this diff touched — not because it mentions a changed
package. Each row says which anchor put it there, so a wrong row is reportable rather than
merely annoying. To re-verify, run the docs-accuracy-audit workflow scoped to these files:
node scripts/docs-audit/affected-docs.mjs 84853fd18eb28a5481415c2d698d04025aa629e1 → pass the list as
args.docs, on the commit named under Which tree this was computed on.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

l2-review#4 · os-steve · session_01ADHkmT4eA4YqtxfiPyLPih

Contract-review-claim: session_01ADHkmT4eA4YqtxfiPyLPih · head 4249fe4 · 2026-11-23T00:04Z

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

l2-review#4 · os-steve · session_01ADHkmT4eA4YqtxfiPyLPih

Contract review

Served-tier: CONTRACT_REVIEW_TIER
Head-sha: 4249fe4ba842b1a047bc9c9e68dbce5ce0dae0f2
Local-runs: none
Scope: packages/spec/src/system/i18n-resolver.ts, packages/spec/src/system/translation.zod.ts + packages/lint/src/i18n-walk.ts, packages/lint/src/object-graph.ts, packages/lint/src/validate-translation-references.ts, packages/metadata-protocol/src/protocol-translated-echo.ts

Read: card #36528 (body and its 3 comments: triage, claim, dev report), PR #36574 (body, 18-file list, net diff against merge-base 65ce7983), the 47 check-runs on the head. Code outside the diff was read at the head, never reviewed: packages/spec/src/data/object.zod.ts, packages/spec/src/data/related-list-entry.ts, packages/spec/src/kernel/metadata-read-decorations.ts, packages/objectql/src/registry-platform-global.ts, packages/objectql/src/registry-custom-arrangement.ts, packages/rest/src/meta-item-read-gate.ts, ui/packages/app-shell/src/utils/deriveRelatedLists.ts. Everything below is derived by reading; nothing was run.

① Derived judgments

  • Accept-set, ObjectTranslationDataSchema: gains _relatedLists, a record of closed leaves with the one key label. Right as a widening: the parent schema is a strict object, so the key was refused as unknown before and is accepted now; no other key's verdict moves, and every other unknown key is refused as before. The un-prefixed relatedLists gains an alias row onto _relatedLists: it was refused before and is still refused, now with the rename named. Right.
  • Key shape (check a): _relatedLists sits beside _views, _actions, _sections, _tabs, _validations and follows their spelling (the authoring key with the underscore prefix, plus the un-prefixed alias). It does not collide with a read decoration: METADATA_READ_DECORATIONS is an exact-name list (_diagnostics, _draft, _withheldFields, _relatedListsArrangement) stripped from served metadata documents, and this key lives in translation data, where its siblings already carry the prefix. LIST is the entry's literal list, the same spelling RelatedListEntryObjectSchema.list takes (child object, or object.field as one key); the built-in tabs cannot be object-form entries, so they have no key. The slot it overrides is the entry's own label (z.string().min(1).optional() on main), which the console reads at deriveRelatedLists.ts:657. Right.
  • Public surface, translateObject: one more overlaid slot on the served object (relatedLists[].label of a labelled object-form entry). It maps existing entries only: a key for a list with no entry is dropped, no entry is created, the array reference is kept when nothing matched, _relatedListsArrangement is untouched, so which tabs show and their order cannot change. Right for the object's own entries. Wrong for an entry a code package's place brings, on the read the REST exit actually makes: see M1.
  • Lint accept-set: translation-target-unknown gains a _relatedLists leg through the shared orphan helper, severity error as its siblings (pinned in the lane's test). Right for the object's own entries; over-accepts for place-brought entries: see M1.
  • VisibleObjectExtension (lint, internal fold shape) gains relatedListEntries. Additive; right.
  • Echo restore: one more restored slot, matched by list, with the existing advisory. Right (④, check d).
  • Generated surface agrees with the zod: authorable-surface/system.json gains system/ObjectTranslationData:_relatedLists; content/docs/references/system/translation.mdx gains the row in each of the five object-translation tables and the nested shape; the strictness-ledger count moves 408 to 409 for the one new strict site. Nothing previously accepted is refused.

② Semver level

Changeset .changeset/36528-related-list-label-translation.md: minor on @objectstack/spec, @objectstack/lint, @objectstack/metadata-protocol. That matches what the diff publishes: an additive authorable key and an additive overlay (spec), an additive rule leg and walk entry (lint), an additive restored slot (metadata-protocol). @objectstack/objectql gains a test file only and needs no entry. The Check Changeset run on the head concluded success.

Clause-②: yes (widening), on the PR body and the changeset. The declaration is the lane's; as a judgment of the diff, nothing narrows.

Metadata-protocol: added is on both; Skills-docs: follow-up owed names the two skill files.

One sentence of the changeset is not true of the head and is published text: "A labelled entry an object extension brings (a list placement in place, ...) ... its key resolves and is translated too." For place it is not translated on the REST read (M1). It moves with M1's fix.

③ Boundary flags

  • Dev deviation, files outside the claim's File surface (packages/lint/src/object-graph.ts, two lint meta-tests, the objectql pin test, packages/spec/liveness/translation.json): object-graph.ts is the fold the orphan rule reads and is reviewed here as an implementing file; the rest are the lane's ACCEPT. Answered.
  • Dev deviation, worktree branch pushed as claude/project-thread-qwdwll: process only. Answered.
  • Acceptance note "the extractor walk does not read objectExtensions": true at the head (collectExpectedEntries reads obj.relatedLists only) and the same gap fields have. Accepted as pre-existing; it bears on M1 only in that nothing scaffolds the key M1 is about.
  • Acceptance note "a place entry's label applies only where the extended object declares relatedLists; the orphan rule accepts its key regardless": answered by M1, which is the stronger form of it.
  • Acceptance note "the echo restore does not restore listViews copy or validations[].message": pre-existing and outside this diff; a follow-up card, not this PR's.
  • open_questions: the dev report carries none.
  • Serial constraint feat(spec): the paired .custom package declares an installed object's field-group and tab arrangement #36517: merged; the merge-base 65ce7983 carries it, and the diff builds on its fold.
  • SQL push-down: the diff adds no query, no id materialisation and no in-app join; every change is over in-memory documents. Nothing to flag.
  • Check-runs on the head, read 2026-11-23: completed with success: Check Changeset, Spec property liveness, Governed Surface Queue Guard, Check PR Size, Check Documentation Links, Flag docs affected by code changes, PR-body guards, Lint · PM dispatch-gates, Lint · scoped · tooling self-tests, Dogfood Regression Gate, Plan Test Core shards, Plan Test UI shards, filter, Auto Label. Skipped by their own conditions: 8 (queue verdicts, opt-in harnesses, dogfood shards). PENDING, not waited for: Test Core 1/10 to 10/10, Build Core, Build Docs, Build UI Deps, Live E2E UI, the four Type Check runs, Lint · ESLint, Lint · repo & tooling gates, Lint · docs & code guards, Lint · CI, release & engine gates, Lint · scoped · slot lookup & corpus, Lint · scoped · query-options erasure. None has failed. The dev's own 118-command claim is not a gate verdict and is not adopted.

④ Design judgment

packages/spec/src/system/translation.zod.ts. The key holds against the claim comment's naming call and its first consumer: a closed leaf, label only, keyed by a free string (the dotted event.related_to is one record key, which the resolver indexes directly and never splits). The docblock's sentences are true of translateObjectRelatedLists for an object's own entries: only an authored label is translated, nothing is swapped in for an entry without one, built-in tabs have no key.

packages/spec/src/system/i18n-resolver.ts. translateObjectRelatedLists is a faithful twin of translateObjectListViews: same early return, same valueOverridesPackagedBase comparison (no second copy), same three edges (no base: catalog applies; base without the entry: diverged; base with the same label: catalog applies), same-reference return. Locale chain as _tabs. An empty or equal translation leaves the entry alone. For the object's own entries, a tenant rewrite and a .custom arrangement's relabel, this is the ADR-0029 D9.2a / ADR-0146 D2 order and it is right. The break is at the one case the PR adds on top of the card:

M1 (must-fix) — A tab title a CODE package's place brings is not translated on the real read, while the lint rule, three docblocks, the changeset and the PR body say it is. Trace at the head: the registry fold splices place: [{ list, after, label }] into the served parent's relatedLists as { list, label }. The REST read exit (packages/rest/src/meta-item-read-gate.ts, both the list and the single-item path) hands translateObject packagedBase = getPackagedObjectBase(name), which is the OWNER's declaration before the fold (registry-platform-global.ts: it adds only code extenders' validations and added fields; relatedLists stays the owner's, and the TranslateDocumentOptions.packagedBase docblock says the same). In translateObjectRelatedLists the base is then known and carries no entry for the placed list, so packagedEntry is {}, valueOverridesPackagedBase({}, 'label', label) is true, and the label reads catalogs.changed: the base's paired .custom bundle, or nothing. The deployment catalog, where the placing package's own objects.TARGET._relatedLists.LIST.label lands, is never asked. A place label applies only where the target declares relatedLists, so the base's array is always present in that case and this is the only outcome. Consequences in the reviewed files: (1) validate-translation-references.ts accepts that key as resolving (extension-fold leg, and the docblock sentence "the served target carries that entry, which translateObject translates as it does the target's own" plus the "FOUR of this rule's rungs are reachable through an extension" paragraph), so os validate is green on a key no served read uses, the false-green the orphan rule exists to prevent; (2) object-graph.ts carries place entries for that reader on the same premise; (3) the changeset and PR body publish "translated too". The lane's pin, packages/objectql/src/registry-related-lists-label-translation-36528.test.ts, calls translateObject(served, BUNDLE, { locale }) with no packagedBase, which is not the read's option set, so it is green on a path production does not take. The same shape was already solved twice for fields: a field a code extender adds is carried into the packaged base (packagedAddedFields, the #27559 principle), and a patched slot reads its package's bundle (patchBundles, #33952). Two fixes close it; the lane picks one. (a) Make it true: getPackagedObjectBase carries the list entries code extenders place, as it carries their added fields, so the placed label compares equal and the catalog applies; pin it through the read's real options (with packagedBase from the registry), and the echo restore then follows for free because it translates with the same base. (b) Make the claim match the code: the orphan rule stops accepting a place-brought key (a .custom arrangement's stays, it reads the pair's bundle by design), the docblocks, changeset and PR body drop "place", the pin is either removed or given the real options, and the gap gets a follow-up card. The .custom arrangement half of the same claim holds: its label is diverged by design and reads the pair's own translations, which is ADR-0146 D2's first rank.

packages/lint/src/i18n-walk.ts. pushRelatedListLabels emits exactly the entries the resolver overlays (object-form, string list, non-empty string label), the dotted list as one path segment, seeded from the label. Agrees with the contract.

packages/lint/src/validate-translation-references.ts. For an object's own entries the leg is right: it resolves over labelled entries only, flags a ghost name with a suggestion, and gives the named-but-unlabelled case its own verdict; an object with no relatedLists flags every key. Beyond M1:

N1 (nit) — The named-but-unlabelled hint, "Give the entry a label ({ list, label }) ... or translate the child lookup field's relatedListTitle", is also what a key over a bare built-in tab (sys_attachment, sys_approval_request, sys_activity) gets, and for those the schema refuses the object form and there is no child field. The flag is right; only the prescription misleads, for a key few will write.

N2 (nit) — The extension leg adds a .custom entry's list to the labelled set whenever it has a label, { list, hidden: true, label } included. The registry fold drops hidden entries from the served list, so a key over one resolves nothing and is not flagged. Permissive, and narrow.

N3 (nit) — A finding's path prints a dotted list unbracketed (..._relatedLists.event.related_to) where the locale segment is bracketed (["zh-CN"]), so the path reads as two segments. Display only.

packages/lint/src/object-graph.ts. The fold's new relatedListEntries filters to record entries of relatedLists and place; a field or group placement has no list and is skipped by the reader. Sound as a carrier; its place half serves the claim M1 refutes and moves with M1's fix.

packages/metadata-protocol/src/protocol-translated-echo.ts (check d). The stored source's relatedLists is put on the stored document, each locale's read is made with the read's own options (the same packagedBase), and an incoming entry label is put back only when some read of the source translates the source label to exactly it and the two differ; an author's own title, and a title on an entry the source leaves untitled, are kept (NOT_DECLARED). Entries are matched by list, the array is copied only on a hit, other entries and columns are untouched. Patch and injected sources declare no relatedLists, so they answer nothing here. A translated read written back therefore stores the source title: round-trip safe. Agrees with the contract sentence added to the module header.

Implemented-by: claude/project-thread-qwdwll
Reviewed-by: session_01ADHkmT4eA4YqtxfiPyLPih

VERDICT: FAIL

getPackagedObjectBase splices the list entries a code extender's place
brings into the owner's relatedLists, as the fold does, so the /meta read
compares a placed tab title with the packaged text and reads the catalog.
Lint: a key over a built-in tab or a hidden .custom entry gets its own
reason, and a dotted list is bracketed in the finding path.

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

The pin asks ObjectStackProtocolImplementation#getPackagedObjectBase for the
base, the accessor the REST read's packagedObjectBaseOf asks, over an
ObjectQL engine's registry. The objectql changeset entry is minor, as the
kind takes; the changeset and the lint docblocks say a placed tab is
applied (and translated) only where the target declares relatedLists.

Claude-Session: https://claude.ai/code/session_01ADHkmRdKNUzzADvuRJx6UT
Co-authored-by: Claude <noreply@anthropic.com>
registry.ts is a facade file whose ceiling is 6426 lines
(check-facade-delegation-only, N6); the getPackagedObjectBase docblock
grew it by 12. The why-paragraph for placed tabs moves to the facet's
packagedPlacedRelatedLists docblock, and the facade keeps one reflowed
sentence naming the third widening: net zero lines.

Claude-Session: https://claude.ai/code/session_01ADHkmRdKNUzzADvuRJx6UT
Co-authored-by: Claude <noreply@anthropic.com>
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#2 · os-steve · session_01ADHkmRdKNUzzADvuRJx6UT

席位核对

ACCEPT at 6fd5bb8 · L1 read 2026-11-23T01:27Z by the #36528 card thread (seat repo:objectstack#2, area s2-A); contract review owed separately (L2 delta requested at this head; first record 7088121343 FAIL at 4249fe4).

  • Shape: draft to main, first line Fixes #36528 (the whole card: key, overlay, its readers); no closing keyword near another card; Clause-②: yes (widening), Metadata-protocol: added, Skills-docs: follow-up #36575 (filed by the seat, Blocked-by this PR). 20 files, +904/-17, non-governed, under 3000.
  • Premise measured: on main 87c7bba the translation schema had only the field-level relatedListTitle; the entry label had no key (claim 7086869811). The dev traced the tab title to the translated /meta/object read (deriveRelatedLists → buildDefaultPageSchema), so no ui/ change; read and agreed.
  • Diff read by the reviewer: translation.zod.ts _relatedLists (closed leaf, label only, alias relatedLists); i18n-resolver.ts translateObjectRelatedLists (labelled object-form entries only, valueOverridesPackagedBase, same-reference return); protocol-translated-echo.ts restore by list; lint walk, orphan leg, extension fold; round 2: registry-platform-global.ts packagedPlacedRelatedLists (the fold's own applyExtensionPlacements over enabled code extenders, lists only, only where the owner declares relatedLists) answering M1 by route (a); registry.ts docblock at net 0 lines. Changeset read sentence by sentence (objectql entry added in round 2; the extension sentence now true of the head: a placed title is translated from the deployment catalog, a .custom title reads the pair's); i18n-standard.mdx example and key-resolution row read; references/system/translation.mdx is generated.
  • Gates: check-runs at this head: 62 success, 12 expected skip, 0 failed, 0 pending (Lint & Repo Gates and TypeScript Type Check success). The red on 8e2ca2b (check-facade-delegation-only N6, registry.ts over its line ceiling) was this PR's and is fixed here. Dev's local reconciliation /mnt/project-files/objectstack-seat2/36528-gates-ran-r2.txt: 122 derived, 122 run, 0 NOT-MEASURED (supporting only; CI is the reading). Ablations: overlay, walk, orphan leg, echo restore, extension fold, and round 2's base carry each turn their pin red, restored to HEAD.
  • Accepted deviations: files beyond the claim's surface (object-graph.ts, registry-platform-global.ts, registry.ts, two lint meta-tests, liveness ledger evidence) are each required by the fix and named in the PR body; the lint fold stays permissive for a place key where the target does not declare relatedLists (documented; it can only miss a finding, never raise a false one). @objectstack/objectql minor is right now that a shipped file changes.
  • Out of scope, where it goes: extractor walk reads no objectExtensions (pre-existing, fields too) and echo restore not covering listViews / validations[].message (pre-existing) — noted in Acceptance notes; the seat decides whether to file. Skills text → Skills: teach the related-list entry title translation key objects.OBJECT._relatedLists.LIST.label (follow-up of #36528) #36575.
  • Landing: non-governed, under 3000 lines: lands by the seat (label-write --land) once a same-head contract-review PASS is on record; Fixes closes Related list entry label (relatedLists[].label) has no translation key: a declared tab title cannot be localised #36528 and clears pm:dispatched on merge.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

l2-review#4 · os-steve · session_01ADHkmT4eA4YqtxfiPyLPih

Contract-review-claim: session_01ADHkmT4eA4YqtxfiPyLPih · head 6fd5bb8 · 2026-11-23T01:27Z

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

l2-review#4 · os-steve · session_01ADHkmT4eA4YqtxfiPyLPih

Contract review

Served-tier: CONTRACT_REVIEW_TIER
Head-sha: 6fd5bb8573ec4fbcdb37772a5e6aabbf48871b17
Local-runs: none
Scope: packages/spec/src/system/i18n-resolver.ts, packages/spec/src/system/translation.zod.ts + packages/lint/src/i18n-walk.ts, packages/lint/src/object-graph.ts, packages/lint/src/validate-translation-references.ts, packages/metadata-protocol/src/protocol-translated-echo.ts, packages/objectql/src/registry-platform-global.ts, packages/objectql/src/registry.ts

Delta round 1 on the record of PR #36574 comment 7088121343 (FAIL at 4249fe4b: M1, N1, N2, N3). Read: card #36528 (body and its 4 comments: triage, claim, two dev reports), PR #36574 (body, its 5 comments, the 20-file net diff against merge-base 06c3e5ac, and the PR's own round-2 commits 45f534f4, 8e2ca2b7, 6fd5bb85), the 74 check-runs on the head. The merge of main (43b75eba) is not reviewed. Code outside the diff was read at the head, never reviewed: packages/objectql/src/registry-extension-placement.ts, registry-custom-arrangement.ts, registry-object-registration.ts (the fold, withholdDisabledExtensions), engine-validation-messages.ts, packages/rest/src/meta-item-read-gate.ts, packages/metadata-protocol/src/protocol-discovery-and-bases.ts, protocol-credential-carry-forward.ts, protocol-meta-item-reads.ts, protocol.ts, packages/types/src/share-link-resolve-answer.ts, packages/metadata-core/src/code-artifact-provenance.ts, packages/spec/src/data/related-list-entry.ts. Everything below is derived by reading; nothing was run.

① Derived judgments

  • Unchanged since the first record and still right: the ObjectTranslationDataSchema._relatedLists accept-set (a widening; closed leaf, label only, the relatedLists alias row), the translateObject overlay, the walk entry, the echo slot, the generated surface. The two hits files, i18n-walk.ts, object-graph.ts and protocol-translated-echo.ts carry no round-2 change.
  • Public surface, SchemaRegistry#getPackagedObjectBase (new in this round): the answer's relatedLists now carries the entries an enabled CODE extender's place splices into the owner's declared tab list. Additive on a read: nothing an author could write is refused, and the answer is the owner's definition by reference exactly as before when no code extender ships a rule, adds a field or places a list. Right. Its effect on the served /meta read is the one intended: a placed title now compares equal to its packaged entry and reads the deployment catalog (it read the pair's bundle or nothing before). Right.
  • Every other reader of the base, checked at the head (git grep over packages): packagedRuleLookup (engine-validation-messages.ts) reads validations only; getPackagedFieldPatchBases reads base.fields and spreads the rest, and its patchedBase is read for fields only by the resolver and the echo; the share-link label translates a { name, label } document, which has no relatedLists, so the new slot returns at its first line; the REST list and item exits and the form route go through translateObject, where translateObjectRelatedLists is the only reader of the base's relatedLists; withoutStaleObjectPlural reads label, pluralLabel and _packageId; the echo restore reads the base's relatedLists only in this PR's own block, and with no stored row takes the base as its source. No reader compares the base whole, by identity or by serialisation. The dev's claim that only this card's slot moves a verdict holds.
  • Lint accept-set: translation-target-unknown gains two distinct reasons (built-in tab, hidden .custom entry) and a hidden .custom entry no longer counts as labelled, so one key that was accepted at 4249fe4b is now flagged. Inside this PR that is a correction of its own unreleased leg, not a narrowing of anything published. Right.

② Semver level

Changeset .changeset/36528-related-list-label-translation.md: minor on @objectstack/spec, @objectstack/lint, @objectstack/metadata-protocol and, new, @objectstack/objectql. The diff now moves a shipped objectql file (registry-platform-global.ts; registry.ts in comment only), and AGENTS.md sets the level by the kind alone: Metadata-protocol: added takes at least minor on a package the diff moves. Right. Check Changeset on the head concluded success (both runs).

Clause-②: yes (widening), on the PR body and the changeset. As a judgment of the diff, nothing narrows.

The corrected sentences are true of the head: the objectql bullet (the base carries a code package's placed tabs as the fold splices them, only where the owner declares relatedLists; a placed title reads the deployment catalog; a tenant rename keeps its text; a .custom title reads the pair's translations) and the lint bullet's claim that a placed or shown .custom entry's key resolves. The sentence the first record refuted ("translated too", unconditionally) is gone. One clause is loose, see N6.

③ Boundary flags

  • Dev deviation, files beyond the claim's File surface in round 2 (registry-platform-global.ts, registry.ts): they are route (a) of M1, which the first record offered, and are reviewed here as implementing files. Answered.
  • Dev deviation, spec / metadata-protocol / rest full suites left to CI: Test Core 1/10 to 10/10 and its aggregate concluded success on the head. Answered by the check-runs.
  • Dev deviation, the lint fold stays permissive for a place key whose target declares no relatedLists: true at the head and now said in the fold's comment and docblock. The fold cannot see another package's target, and the direction can only miss a finding. Accepted.
  • open_questions (one): "contract review delta owed at this head". Answered by this record.
  • out_of_scope_findings (one): the lint union can accept an owner's labelled key whose entry a .custom arrangement hides or replaces. Confirmed at the head (the labelled check runs before the hidden check). Permissive, lint-only, no false red; the seat decides whether to card it.
  • Escalated to the seat, for a follow-up card on the echo door, not graded on this head: route (a) makes a placed title translated on the real read, so it can now come back on a save. The restore follows only where the source carries the entry: with no stored row the source is the packaged base (carries it, restored), and a stored row that carries the entry restores too. A stored overlay row that declares relatedLists WITHOUT the placed entry (saved before the placing package was installed) explains nothing for it (relatedListLabel answers not-declared in every source), so a non-source-locale save of the folded read would store the translation as the title. This is the door's documented edge ("a field the source does not declare has nothing to be compared with"; the lane pins "a title on an entry the source leaves untitled is kept"), and a field a code extender adds has had the same edge since the base began carrying added fields. Whether a Studio save reaches it depends on the draft read, which is not folded (A tenant object overlay drops every objectExtensions field from the resolved schema, and effective contradicts code in the same response #8027 note in protocol-meta-item-reads.ts); not established by reading alone. One fix would serve both slots (the packaged base as a last source for what a code extender brings), which is why it is a card and not this PR's.
  • SQL push-down: round 2 adds no query, no id materialisation and no in-app join; packagedPlacedRelatedLists is a pure pass over in-memory contributors. Nothing to flag. (It runs the fold's group and field passes and discards them, per call and uncached, only for objects some code extender places into; small.)
  • Check-runs on the head, read 2026-11-23: 74 runs, all completed: 62 success, 12 skipped by their own conditions (queue verdicts, opt-in harnesses, dogfood shards, schedule gate, the body-edit re-run's Auto Label and Check PR Size, Lint UI), 0 failed, 0 pending. Among the successes: Lint & Repo Gates, Lint · repo & tooling gates (the facade ceiling), TypeScript Type Check and its four lanes, Test Core and its ten shards, Test UI and its sixteen, Build Core, Build Docs, Check Changeset, Spec property liveness, Governed Surface Queue Guard, PR-body guards. The dev's 122-command reconciliation and ablation are not gate verdicts and are not adopted.

④ Design judgment

No must-fix, no should-fix.

M1: closed — traced again end to end at the head. (1) Fold: foldExtendersOntoDefinition runs applyExtensionPlacements(merged, placementContributorsOf(contributors, ownFields), ...) and the lists pass splices { list, label?, columns? } (or the bare name) into relatedLists, only where the list is declared, skipping a child another package owns and a list the tabs already arrange. (2) Base: PlatformGlobalFacet.getPackagedObjectBase calls the same two functions over the owner's definition with the enabled code extenders, the same ownFieldNamesOf(owner), the same childPackageOf closure body and the owner's group keys, and reads off relatedLists only when the pass changed it. The splice is one function, so label, columns, the after/before rounds, the priority-then-package order and the trailing built-in rule cannot drift between the two. (3) REST exit: packagedObjectBaseOf asks the protocol's getPackagedObjectBase, which asks the registry's; both the list and the item path hand it to translateMetadataDocument. (4) translateObjectRelatedLists finds the placed entry by list in the base, the label compares equal, and catalogs.unchanged (pair, then deployment catalog) applies. Cases tried:

  • Disabled package: the fold drops every disabled extender (withholdDisabledExtensions), the base filters !isPackageDisabled. Agree. (A fold made with asEnabled / includeDisabledExtensions serves a placement the base lacks; it then reads as diverged and keeps its text, the same edge added fields have.)
  • Target with no relatedLists: neither side splices (arrangementDeclared), the base is the owner's by reference, nothing is served to translate. Agree.
  • Tenant rename of the placed title: served label differs from the base entry's, diverged, text kept. Pinned.
  • .custom arrangement (ADR-0146 D10) replacing the list whole: never in the base. An entry it names with its own label diverges and reads the pair's translations; an entry it names bare has no label and nothing is translated; a placed entry it does not name is carried over by applyCustomArrangement with its label, still equals the base and still reads the catalog. All three are the ruled order.
  • A tenant-provenance extender's place (the pair's included) is in the fold and not in the base (isCodeArtifactBody): diverged, the pair's bundle. Consistent with the field rule.
  • Order differences between base and served (an anchor only a non-code extender brings) cannot matter: the comparison is by list, never by position.
    The pin (registry-related-lists-label-translation-36528.test.ts, the lane's) now builds an ObjectQL engine, takes the base from ObjectStackProtocolImplementation#getPackagedObjectBase and translates through translateMetadataDocument with packagedBase (and pairBundle for the pair case): the read's option set, and it asserts the base's own tab list. Test Core is green on the head.

N1: closed — a key over a built-in tab (isRecordPageBuiltinTab) has its own verdict and hint, naming neither the object form nor relatedListTitle.
N2: closed — a .custom entry with hidden: true (relatedListEntryHidden, the fold's own predicate) is recorded as hidden, not labelled, and its key gets its own reason.
N3: closed — the finding path goes through memberPath, so a dotted list is bracketed.

packages/objectql/src/registry-platform-global.ts. packagedPlacedRelatedLists agrees with its docblock sentence by sentence: undefined when no extender places anything or the owner declares no list; only the lists pass is read off (after !== before), the groups, fields and notes are dropped; the owner's definition is not mutated (the pass copies before it writes). The call site's comment ("the same filter as the added fields") is true up to the explicit code-artifact test, which packagedAddedFields applies inside.

packages/objectql/src/registry.ts. Comment only, net zero lines. "Exactly three widen" and "by reference when no code extender ships a rule, adds a field or places a list" are true of the facet.

packages/lint/src/validate-translation-references.ts. The fold comment and the "FOUR rungs" docblock now say what the code and the registry do: a placement is spliced where the target declares relatedLists, into the served target and into the packaged base; a key on a target that declares none is accepted all the same, and says so.

packages/spec/src/system/i18n-resolver.ts, translation.zod.ts, i18n-walk.ts, object-graph.ts, protocol-translated-echo.ts. Unchanged in this round; the first record's judgment stands. object-graph.ts's place half now serves a claim that is true. The echo's residual is in ③.

N4 (nit) — The base judges "declares relatedLists" on the OWNER; the fold judges it on its base layer (overlay ?? own). Where a tenant overlay row declares a tab list the owner does not, the fold splices a placed entry and the base has none, so that title reads as diverged and is not translated from the catalog (the state before this PR; no wrong text). The objectql docblocks and changeset say "the owner", which is true; the lint comment's "where the target declares" is the looser spelling. Follow-up card or accepted deviation.

N5 (nit) — TranslateDocumentOptions.packagedBase (i18n-resolver.ts, a hits file) still lists what an object's base carries beyond the owner as validations and added fields; it does not name the placed relatedLists entries. No sentence of it is made false for the slots it names, and the registry docblock it defers to is right, but both earlier widenings updated this paragraph and this one did not. Ride it on #36575 or a follow-up; a fix here moves the head.

N6 (nit) — Changeset, lint bullet: "the record page shows a placed tab only where that object declares relatedLists". Where it declares none the list still shows, in the automatic tab order; what does not apply is the placement and its label (the fold's own note says so). Wording only.

Implemented-by: claude/project-thread-qwdwll
Reviewed-by: session_01ADHkmT4eA4YqtxfiPyLPih

VERDICT: PASS

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#2 · os-steve · session_01ADHkmRY38EZf38Yy3zthbY

维护者速读

  • 改了什么:子表页签标题(含代码包插入的页签)可以按语言翻译,Studio 保存时不会把译文存成标题。
  • 风险:只加不收(Clause-② widening),非受管面,904 行。
  • 要你做什么:无,席位落地。

ACCEPT → PR #36574 comment 7089156314 · Contract review PASS → comment 7089245527 · Head-sha 6fd5bb8573ec4fbcdb37772a5e6aabbf48871b17 · check-runs 62 success, 12 skipped, 0 failed.

Out of scope: review ③ (save door edge), N4, N5 and the dev's lint-union finding → filed #36595. N6 (changeset wording) accepted as is.

@objectstack-fleet
objectstack-fleet Bot marked this pull request as ready for review November 23, 2026 01:36
@objectstack-fleet
objectstack-fleet Bot added this pull request to the merge queue Nov 23, 2026
Merged via the queue into main with commit f66340a Nov 23, 2026
75 checks passed
@objectstack-fleet
objectstack-fleet Bot deleted the claude/project-thread-qwdwll branch November 23, 2026 02:13
247257110 pushed a commit to 247257110/objectstack that referenced this pull request Nov 23, 2026
…ep name (objectstack-ai#36576)

<!-- claude-projects-attribution: {"github_login":"os-steve"} -->
_Requested by **Steve** · [project
thread](https://claude.ai/code/project/chan_01FdL1XeUyvVNxLreh3F4Qi9?thread=cmsg_01FdL1XeUyvVNxLreh3F4Qi9App7SwcDfGUokz2R18dPK7)_
Fixes objectstack-ai#36530
repo:objectstack#2 · os-steve · session_01ADHkmQ19xzW4F83HZd4Up6
Clause-②: yes (widening: `objectstack validate` accepts
`flows.FLOW.nodes.NODE_ID.label` over a screen that authors a non-empty
`config.title`; `@objectstack/spec/automation` gains
`flowDecisionEdgeBranch`, `FlowDecisionEdgeBranch`,
`FLOW_DECISION_DEFAULT_BRANCH_LABEL`)
Metadata-protocol: added
Skills-docs: follow-up objectstack-ai#36401

## 维护者速读

- 用户能看到什么变化:译文语言下的流程说明书和流程设计器里,自带标题的界面步骤现在显示译名;标题里带占位符的步骤不再显示原文或未填充的模板。
- 为什么做:补齐流程步骤名翻译这项工作的最后一块,让每个画出来的步骤都有译名位置。
- 出错会怎样:最坏情况是某个界面步骤仍显示原文名称,不影响流程运行;改动只涉及显示和校验,可以直接撤回。
- 要你做什么:无。

## What changes

Ruling 7076440876 (on objectstack-ai#35979) says every drawn step can carry a label
per language. A screen that sets its own `config.title` was the one gap:
its heading had a key (`screens.NODE_ID.title`) but its canvas label had
none, because `objectstack validate` refused `nodes.NODE_ID.label` over
any screen. The key name, `flows.FLOW.nodes.NODE_ID.label`, is the
seat's call in claim 7086969804. `screens.NODE_ID.label` was not used
because `screens` already aliases `label` onto `title`.

- **Validator**
(`packages/lint/src/validate-translation-references.ts`):
`ScreenFacts.titled` records whether a screen has a non-empty string
`config.title`. A `nodes` key over a titled screen is accepted. Over an
untitled screen it is still refused (`TRANSLATION_TARGET_UNKNOWN`) and
pointed at `screens.NODE_ID.title`, and the message now says why. Over
an approval it is still pointed at `approvals.NODE_ID.label`.
Did-you-mean suggestions now include titled screens.
- **Reader** (`ui/packages/i18n/src/flowLabels.ts`): `stepLabel` returns
`nodes.NODE_ID.label` for a titled screen. For an untitled screen, a
translated `screens.NODE_ID.title` that holds a `{{` hole now returns
`undefined`, so the drawing falls back to the authored label (card item
2).
- **Docs embed** (`metadata-viewer.tsx` `flowStepName`): the heading
test now runs before `stepLabel`. A titled screen is still named by its
translated heading when that heading has no hole. Only a holed heading
falls to the `nodes` key, then to the authored label.
- **Studio canvas**: no code change. `FlowCanvas` already draws
`stepLabel(node) ?? node.label`, so it now draws a titled screen's
`nodes` translation.
- **Walk** (`packages/lint/src/i18n-walk.ts`): asks for
`nodes.NODE_ID.label` on a top-level screen whose authored
`config.title` holds `{{`. That is where the docs embed draws the label.
The rule, and why the Studio canvas read does not widen it, is under
Acceptance notes.
- **One branch rule** (comment 7084469163):
`flowDecisionEdgeBranch(edge, conditions)` and
`FLOW_DECISION_DEFAULT_BRANCH_LABEL` now live in
`packages/spec/src/automation/flow-altitude.ts` beside
`FLOW_TECHNICAL_NODE_TYPES`. `decisionBranches` (`flow-branches.ts`) and
`decisionBranchTechnicalTargets` (`i18n-walk.ts`) both call it. Both
local `'default'` constants are deleted. It is a pure function over
plain records, so no UI guard types move into spec.
- **Spec prose**: the `nodes` group docblock, the comment and the two
`.describe` strings in `translation.zod.ts` now describe the
titled-screen case. There is no shape change: the group is still a plain
`z.record`. `content/docs/references/system/translation.mdx`,
`api-surface/automation.json` and `export-origins/automation.json` were
regenerated with `check:generated --fix`. The
`liveness/translation.json` evidence and notes were updated; no cited
symbol moved.

## Tests

- Validator: accepts `nodes` over a titled screen next to its `screens`
heading key. Still refuses it over an untitled screen (rule, severity,
path, plus the redirect key) and over an approval. Offers a titled
screen as did-you-mean.
- Embed (`metadata-viewer.test.tsx`): a holed-title screen is named by
its `nodes` key and never by its heading. A plain-title screen keeps its
heading even when a `nodes` key exists. An untitled screen whose
translated title adds a hole is named by its authored label.
- Studio (`FlowCanvas.test.tsx`): the canvas draws a titled screen's
`nodes` translation, and an untitled screen whose translation adds a
hole keeps its authored label. The `stepLabel` unit assertion for a
titled screen moves from `undefined` to the `nodes` value.
- Walk (`packages/cli/test/i18n-flow-node-coverage.test.ts`): asks for
the key on a top-level holed-title screen. Does not ask on a plain-title
screen, an untitled screen or a nested holed-title screen.

<details><summary>Local runs (tree 6f3b8c8)</summary>

- `pnpm --filter @objectstack/lint test`: Test Files 225 passed (225),
Tests 9446 passed. `typecheck`: exit 0.
- `pnpm --filter @objectstack/spec test`: Test Files 875 passed (875),
Tests 27972 passed, 1 todo.
- `pnpm --filter @objectstack/cli exec vitest run --project unit`: Test
Files 436 passed (436), Tests 6208 passed. The integration layer is left
to CI: the diff touches no integration file and no spawn entry.
- UI: `vitest run` over metadata-viewer, the basic renderer tests,
FlowCanvas and `packages/i18n/`: Test Files 133 passed, Tests 2355
passed, 13 skipped. `type-check` for `@object-ui/i18n`,
`@object-ui/components` and `@object-ui/app-shell`: all three Done, exit
0.
- `pnpm --filter @objectstack/spec check:generated`: 3 stale
(api-surface, export-origins, docs), fixed with `--fix`; the re-check
after the write is green.

</details>

<details><summary>Ablations (one per behaviour the tests pin; every
mutation landed, every restore verified as blob == HEAD)</summary>

- Validator: deleted the `titled` skip. Red: 1 failed (the accept test).
- `stepLabel` hole test: replaced with a bare `return title`. Red: 2
failed (the embed test and the canvas test for an untitled screen with a
hole).
- `stepLabel` titled screen: returned `undefined` for every screen. Red:
3 failed (the embed holed-title test, the `stepLabel` unit test and the
canvas test).
- `flowStepName` order: put `stepLabel` back before the heading. Red: 1
failed ("never by its heading").
- Walk: always skipped screens. Red: 1 failed (the cli walk test). The
mutated lint build failed its DTS step (TS6133 on the now-unused
`title`), and the dist preflight showed the marker absent. So the red
came through the cli suite's source resolution of the walk, not through
`dist`. Restore: lint rebuilt, `--absent` preflight exit 0.

</details>

## Acceptance notes

- **Walk rule chosen (A4).** The walk asks for `nodes.NODE_ID.label` on
a **top-level** screen whose **authored** `config.title` is a string
holding `{{`. That is exactly where the docs embed draws the label at
`detail: business`. The Studio canvas draws the label for every titled
screen, but the walk already asks only for what the docs embed draws. It
does not ask for the technical steps the canvas also draws either, so
the canvas read does not widen the demand. The validator accepts the key
over **every** titled screen, at any depth, because the canvas reads it
there.
- **Coverage baseline**: unchanged. A static read of every `type:
'screen'` node in `examples/`, `packages/platform-objects` and
`packages/plugins` finds 14 screens and no `config.title` holding `{{`,
so each config moves by +0. The local `check:i18n-coverage` run was NOT
MEASURED (PREREQUISITE NOT MET: the example closure is not built); CI
runs it.
- **`FLOW_DECISION_DEFAULT_BRANCH_LABEL`** has the same word as the
engine's `DEFAULT_BRANCH_LABEL` (`service-automation` `engine.ts`). The
engine keeps its own constant: switching it to the spec export is
outside this card's file surface.
- Not merged with `origin/main` before opening. `overlap-check.mjs` was
run before each push and was clean against main and against objectstack-ai#36574,
which shares six of these files and merges cleanly.

## Verification

Read first, by risk:
1. `ui/packages/components/src/renderers/basic/metadata-viewer.tsx`
`flowStepName`: the reorder. A plain heading must still win over a
`nodes` key.
2. `packages/lint/src/validate-translation-references.ts`, the `nodes`
block: the `titled` skip and its fact in `collectFlowRecord`.
3. `packages/spec/src/automation/flow-altitude.ts`
`flowDecisionEdgeBranch`: it must match the two readers it replaced.

Two-minute check: `cd ui && pnpm exec vitest run
packages/components/src/__tests__/metadata-viewer.test.tsx -t "titled
screen"`. Expect `Tests 4 passed | 20 skipped`, including "names a
titled screen whose heading holds a hole by its nodes key, and never by
its heading".

Out of scope, kept as notes: the ADR wording for the key goes to objectstack-ai#36086,
and the skill text for the key to objectstack-ai#36401.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

https://claude.ai/code/session_01ADHkmQ19xzW4F83HZd4Up6

---------

Co-authored-by: Claude <noreply@anthropic.com>
247257110 pushed a commit to 247257110/objectstack that referenced this pull request Nov 23, 2026
…custom package (objectstack-ai#36499, PR 2 of 2) (objectstack-ai#36624)

<!-- claude-projects-attribution: {"github_login":"os-steve"} -->
_Requested by **Steve** · [project
thread](https://claude.ai/code/project/chan_01FdL1XeUyvVNxLreh3F4Qi9?thread=cmsg_01FdL1XeUyvVNxLreh3F4Qi9Wq5utqEodnDCBh6heq37AG)_
Fixes objectstack-ai#36499

Clause-②: yes (widening)
Metadata-protocol: none

## 维护者速读

-
用户能看到什么变化:管理员在已安装(只读)应用的记录页「…」第一项就能「配置页签」,可拖动全部页签、隐藏或恢复关联页签,每个页签标明来自原包、其他包还是本环境;保存后所有人看到新排列,原包不动。自建应用的入口也挪到「…」第一项。
- 为什么做:本卡「记录页就地配置页签」的第二个也是最后一个合并请求,替管理员省去进 Studio 改已安装对象的绕路。
-
出错会怎样:只影响已安装对象记录页的页签排列,写在该应用配对的定制包里;管理员可再次进入配置改回,原包始终不变。定制总览读接口暂不列出页签排列,已另开卡跟进(定制总览列出页签排列)。
- 要你做什么:无(是否允许在已安装对象上隐藏附件、审批、动态三个内置页签,已另开决策卡等你裁定)。

## What changes

**Installed objects (card items 4 and 7).** On the record page of an
object whose package is installed read-only, 「Configure tabs」 is now
offered too. The gate is PR 1's admin gate (Studio opens the object,
posture `view` here) plus `useCustomizeDoorWalled()`: where the
customization door is walled (`group` / `isolated`), the entry is not
offered. The edit state is the same one PR 1 built: the design-mode
shell from objectstack-ai#36437, reused unchanged.

- Every tab can be moved: the object's own lists, a list another package
brings, and the built-in 附件 / 审批 / 动态.
- A related tab can be hidden and shown again. A built-in tab cannot be
hidden here, because the `.custom` list cannot hide it (spec: "cannot be
hidden here"). An attachments tab the base does not draw waits in
「Hidden」 and can be shown from there.
- Each related tab carries a source mark: 「Original package」, 「From
PACKAGE」 or 「This environment」.
- 「Save」 writes the `relatedLists` of the pair's object extension
(`object_extension`, filed under the object's name, in the base's paired
`.custom` package), in objectstack-ai#36498's shape. The write lists every shown tab
in order (a built-in by its bare name) and then every hidden related tab
as `{ list, hidden: true }`. A tab the list does not name is served
after the named ones.
- The pair is resolved through the ensure door (`POST
/packages/:id/ensure-customization`). That door creates the pair on the
first save, as Studio does. A pair the server does not list as writable
is refused before any write.

**One shared writer.** `views/objectExtensionArrangementSave.ts`,
`saveObjectExtensionArrangement`, is the only write of an installed
object's arrangement keys (`CUSTOM_ARRANGEMENT_KEYS`).

- It reads the pair's STORED extension and the object as stored (the
layered read).
- It replaces only the keys its caller returns. Every other key is kept:
`fields`, `fieldPatches`, `place`, the other arrangement key.
- It saves a draft with the first-write pin (`ifNoneMatch: '*'`), then
publishes. A refused publish discards that draft.
- It announces the refresh through the door.

The field-layout editor in objectstack-ai#36505 is meant to be its second caller
(`fieldGroups`). objectstack-ai#36505 is not implemented here.
`resolveRecordTabsSaveTarget` now answers `{ kind: 'package' } | { kind:
'pair' }`.

**The 「…」 entry is the first item (card item 1).** `page:header`
(`containers.tsx`): a host overflow entry that declares `leadsMenu:
true` is drawn first, ahead of Refresh, with a separator. Only host
entries can claim this place; an authored action cannot. The record
page's 「Configure tabs」 declares it, on self-built and installed objects
alike. No other entry declares it, so no other menu changes.

**A stored title is kept (fix to PR 1's write).** Since objectstack-ai#36574, the
served `relatedLists` labels are translated for the reader. PR 1 wrote
the editor's labels back as they were, which would have stored a
reader's translation as the title. Now a tab's stored label is written
unless the administrator renamed it (`recordTabLabelToWrite`). This
holds on both paths.

**i18n.** New keys under `designMode.recordTabs`: `pairNotWritable`,
`builtinMoves`, `sourceBase`, `sourcePackage`, `sourceEnvironment`. They
are added to all eleven locales; zh-Hant is regenerated by
`gen-zh-hant`.

## Tests

New files, named for the card:
-
`ui/packages/app-shell/src/views/__tests__/objectExtensionArrangementSave-36499.test.ts`
(6)
-
`ui/packages/app-shell/src/views/__tests__/recordTabsInstalled-36499.test.ts`
(7)
-
`ui/packages/app-shell/src/views/__tests__/RecordTabsConfigInstalled-36499.test.tsx`
(3)

**Existing tests changed** (both are PR 1's):
-
`ui/packages/app-shell/src/views/__tests__/recordTabsConfigSave-36499.test.ts`:
  - the doors gain `ensureCustomization` and `client.get`;
  - TEXTS gains `pairNotWritable`;
  - the read-only refusal case is replaced by the pair target;
  - the seam test expects the pair target.
-
`ui/packages/components/src/__tests__/page-header-overflow-close-36499.test.tsx`:
  - `renderHeader` takes `headerSystemActions`;
  - a new describe has 2 cases for `leadsMenu`.

Ablations. The fix was committed first. Each mutation was written with
`ablation-replace.mjs`, and each restore was proven by blob == HEAD.
- Dropping the `leadsMenu` flag: 1 test red.
- `recordTabLabelToWrite` returning the served label: 2 tests red.

<details><summary>Test and gate runs at head c7f9b58 (all through
os-verify-lock)</summary>

- The card's files plus PR 1's: 7 files, 44/44 passed.
- `packages/app-shell/src/views/RecordDetailView.*`: 99 files, 826/826
passed.
- components `page-header*`, `layout-containers*`,
`horizontal-overflow*`, `page-tabs*`, plus plugin-detail
`RecordPageColumns*` and `RecordRelatedListRenderer*`: 64 files, 598/598
passed.
- i18n `src/__tests__`: 106 files, 1978 passed and 13 skipped.
- `ui/scripts/` (a derived family): 174 files, 5127 passed and 2
skipped.
- `type-check` (both `tsconfig.json` and `tsconfig.test.json`) for
app-shell, components and i18n: exit 0.
- `dispatch-gates --commands`: 41 derived families, all run, all exit 0.
`--ran` reconciles them as 41 run, 0 NOT-MEASURED.
- The 40 `ui` lint-workflow checks, including `check:spec-symbols`,
`check:i18n-keys`, `check:i18n-drift` and `check:metadata-write-doors`:
exit 0.
- `check:doc-examples`, `check:doc-snippets` and `check:readme-exports`
first answered PRECONDITION NOT MET because `@object-ui/cli` was not
built. After building it, all three gave exit 0.
- `check:new-line-citations`: exit 0.
- `check:test-source-alias` and `check:nul-bytes` (both derived): exit
0.
- eslint with the ADR-0054 `no-synthetic-event-trigger` ratchet, on the
24 changed ui files: exit 0.
</details>

At head 28193db (patch round 1, after a merge of main): own and PR 1
files plus `DataPillar.panelHold-27629` 8 files 49/49; `ui/scripts/`
5127 passed and 2 skipped; app-shell and components `type-check` exit 0;
41 derived families exit 0, with `--ran` reporting 0 NOT-MEASURED;
`check:i18n-keys`, `check:i18n-drift`, `check:spec-symbols`,
`check:new-line-citations` and the three `check:vi-mock-*` checks exit
0. The large neighbour suites (RecordDetailView.*, i18n, page-header)
were not re-run locally after this merge; CI runs them.

## Acceptance notes

- **The customizations read does not list an arrangement: moved to
objectstack-ai#36626** (seat routing, 2026-11-23 04:26Z). After the save, `GET
/api/v1/packages/com.example.showcase/customizations` answered `200`
with every list empty. The extension itself is there: `GET
/api/v1/meta/object_extension/showcase_account?package=com.example.showcase.custom`
answers it. The read's contract is strict and names exactly three member
kinds, `extensions.kind` = `field` | `validation` | `index`, so a
`relatedLists`-only extension (and a `fieldGroups`-only one, for objectstack-ai#36505)
has no entry to appear as. Making it appear is a spec and runtime
change, carried by objectstack-ai#36626, not by this PR.
- **H2 (a per-tab source on `_relatedListsArrangement`) does not hold;
the narrow gap below is an accepted deviation** (seat routing,
2026-11-23 04:26Z; no card). The decoration carries `{ packageId,
hidden, unlisted }` and nothing per tab. The source marks are derived
from data the client already has:
- the child object's `_packageId`: the base means the original package;
`sys_metadata` or a `.custom` package means this environment; anything
else means that package;
  - a relationship field named `__c` means this environment.

The remaining gap: a relationship field that another package's extension
adds to a base-owned child object shows as 「Original package」. Closing
it needs a per-tab source from the server. No spec or server change is
made here.
- **Built-in tabs stay locked here: hiding them goes to decision card
objectstack-ai#36627** (seat routing, 2026-11-23 04:26Z). On installed objects 附件 / 审批
/ 动态 can be moved but not hidden: the spec says the `.custom` list
cannot hide them ("cannot be hidden here"). They are not renamable
either, on either path: a built-in entry is a bare name in the spec's
shape and carries no label, so there is no place to store a rename. Seat
ruling 7089839334 (no spec card for hiding 审批/动态 on self-built objects)
is unchanged.
- **Translated labels.** PR 1 combined with objectstack-ai#36574 would have written a
reader's translated tab title into the stored definition on any save.
Fixed on both paths; see What changes.
- **Visible effect beyond the card.** 「Configure tabs」 now sits above
Refresh in every record 「…」 where it is offered, including on self-built
objects (PR 1 placed it after Refresh). No other menu entry moves.
- **Observation, not filed.** For an installed object, the layered
read's `code` layer (`GET
/meta/object/showcase_account/layers?package=com.example.showcase`)
answered the extension-folded `relatedLists`, while the showcase source
declares none. The writer reads entries in the order extension first,
then owner, so this does not change what is written. I note it because a
reader of `code` would take the result for the package's own definition.
- **CI patch round 1 (head 28193db).** At c7f9b58, `Test UI (13/16)`
went red on one test that this change does not touch:
`DataPillar.panelHold-27629` › "Show me" reopens the action…, a 3000 ms
`waitFor` on the held line. That test was last changed by objectstack-ai#36597 on
main. No file in its import graph is in this diff, and the dom project
runs `isolate: true`, so no other file's mocks reach it. Under
os-verify-lock it passed alone (5/5) and with all 41 `DataPillar.*`
files on 4 workers (209/209). The merge group's CI for objectstack-ai#36597 and the
later runs on main are green. I read it as a timing flake in a loaded
shard (that file took 10 s there), not a defect of this change, so no
code or test was changed for it. The new head is a merge of main
(3110de5), which re-runs CI.
- **H1 holds.** The extension is written as `object_extension` in the
pair, and only `relatedLists` is replaced (unit:
`objectExtensionArrangementSave-36499` keeps `fields`, `fieldPatches`,
`place` and `fieldGroups`). Live: the second save in the browser pass
read back the first save's extension and replaced only its list.

## Verification

Browser pass at head `0aacc5aad`, with the same code as this head; the
merge of main brought in no file this change reads.

- Booted example app: `examples/app-showcase` (`objectstack dev --ui
--seed-admin`, own port and DB). The console was rebuilt from this
branch.
- Installed read-only package: `com.example.showcase` (type app,
`writable: false`).
- Object: `showcase_account`, record Northwind.
- Before the first save: no `com.example.showcase.custom` package
existed, and the customizations read was empty.
- To show a tab from another package, the run's DB holds a QA package
`com.qa.tabs` with an object `qtab_visit` that looks up
`showcase_account`. It exists only in the run's DB.

<details><summary>Admin, 1440: reorder, hide, save, reload</summary>

- 「…」 read `Configure tabs, Refresh, Share, Change Owner, Delete`.
- Editor chips:
  - `showcase_contact` [Original package]
  - `showcase_field_zoo.f_lookup` [Original package]
  - `showcase_field_zoo.f_lookups` [Original package]
  - `qtab_visit` [From Tabs QA]
  - 审批
  - 动态
- I dragged Visits first, hid 「Field Zoo · Lookup → Accounts (multiple)」
and saved. The writes, in order:
  - `POST /api/v1/packages/com.example.showcase/ensure-customization`
- `PUT
/api/v1/meta/object_extension/showcase_account?mode=draft&package=com.example.showcase.custom`
- `POST
/api/v1/meta/object_extension/showcase_account/publish?package=com.example.showcase.custom`
- Nothing was written to `com.example.showcase`.
- Tabs after save and after a reload: `Details, Visits, Contacts, Field
Zoo, Activity`.
- The pair's extension then read
`{"extend":"showcase_account","relatedLists":["qtab_visit","showcase_contact","showcase_field_zoo.f_lookup","sys_approval_request","sys_activity",{"list":"showcase_field_zoo.f_lookups","hidden":true}]}`.
- The served object carries `_relatedListsArrangement:
{"packageId":"com.example.showcase.custom","hidden":["showcase_field_zoo.f_lookups"],"unlisted":"shown"}`.
</details>

<details><summary>Original package unchanged</summary>

- `GET
/meta/object/showcase_account/layers?package=com.example.showcase`
answers `overlay: null`, `draft: null`, `provenance: package`,
`editable: false`.
- `GET /meta/object_extension?package=com.example.showcase` answers
`items: []`.
- `git status examples/` is clean.
- The customizations read: see Acceptance notes.
</details>

<details><summary>Another account (plain member), 1440 and
1280</summary>

- 「…」 read `Refresh, Share`: no entry.
- The member's served object carries the same `relatedLists` and the
same `_relatedListsArrangement`.
- Tabs drawn: `Details, Field Zoo, Activity`. The multi-lookup tab is
hidden. Visits and Contacts are not drawn because the member has no read
on `qtab_visit` and `showcase_contact` (`403 PERMISSION_DENIED` on the
data read), as before this change.
</details>

<details><summary>Admin, 1280: second save over the existing
extension</summary>

- The menu's first item is 「Configure tabs」.
- On reopening, the editor shows the saved order and 「Field Zoo · Lookup
→ Accounts (multiple)」 in 「Hidden」.
- I moved 动态 ahead of 审批, showed the hidden tab again and saved. The
same three writes followed (ensure, pinned draft, publish).
- After a reload: `Details, Visits, Contacts, Field Zoo · Lookup →
Account, Field Zoo · Lookup → Accounts (multiple), Activity`.
- A separate drag (not saved) moved 动态 to the very front, so built-ins
move to any place.
</details>

<details><summary>Self-built path (PR 1), admin, 1280</summary>

- On `qtab_account` (package `com.qa.tabs`, writable), 「…」 read
`Configure tabs, Refresh, …`.
- Chips carry no source mark.
- I dragged People first and saved. The writes were `PUT
/meta/object/qtab_account?mode=draft&package=com.qa.tabs`, then `POST
…/publish?package=com.qa.tabs`.
- After a reload: `People, Deals, Tickets, Attachments, Activity`.
</details>

The 「This environment」 mark is covered by
`RecordTabsConfigInstalled-36499` and `recordTabsInstalled-36499`. It
was not set up in the browser.

Screenshots (`/mnt/project-files/objectstack-seat2/shots/36499-pr2/`):
- `01-admin-1440-menu-first-item.png`: 「Configure tabs」 first in 「…」 on
the installed object
- `02-admin-1440-installed-edit-state.png`: the edit state with source
marks
- `03-admin-1440-installed-moved-hidden.png`: Visits moved first,
multi-lookup tab in 「Hidden」
- `04-admin-1440-installed-after-reload.png`: after save and reload
- `05-member-1440-installed-menu-no-entry.png`,
`05-member-1280-installed-menu-no-entry.png`: the member's 「…」 and tabs
- `06-admin-1280-menu-first-item.png`: the entry first at 1280
- `07-admin-1280-installed-reopened.png`: reopened on the saved
arrangement
- `08-admin-1280-installed-moved-restored.png`: 动态 moved, hidden tab
shown again
- `09-admin-1280-installed-after-reload.png`: after the second save and
reload
- `10-admin-1280-selfbuilt-edit.png`,
`11-admin-1280-selfbuilt-after-reload.png`: the self-built path

Files to read first, by risk:
1. `ui/packages/app-shell/src/views/objectExtensionArrangementSave.ts`:
which keys are kept and which are replaced, the pinned draft, publish,
and the discard on a refused publish.
2. `ui/packages/app-shell/src/views/recordTabsInstalled.ts`,
`installedTabsEntries`: what the pair's list holds (built-ins bare,
hidden related tabs, kept unknown entries, stored labels).
3. `ui/packages/components/src/renderers/layout/containers.tsx`:
`leadsMenu`, in the record bar and in the state-group menu.

Two-minute check: in `examples/app-showcase`, run `objectstack dev --ui
--seed-admin`. As admin, open any Account record and open 「…」. The first
item is 「Configure tabs」. Hide a tab, drag another, and save. `GET
/api/v1/meta/object_extension/showcase_account?package=com.example.showcase.custom`
answers the new `relatedLists`.

---

_Generated by [Claude
Code](https://claude.ai/code/session_01ADHkmP8GZoB2rUETxwNEDv)_

<!-- signed: repo:objectstack#2 · os-steve ·
session_01ADHkmP8GZoB2rUETxwNEDv -->

---------

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 protocol:system size/l tests tooling Fix lands in tooling, not a product package — enters pm:queue only with Unblocks: or a named surface

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Related list entry label (relatedLists[].label) has no translation key: a declared tab title cannot be localised

2 participants