Skip to content

fix(metadata-protocol): title a record-share search hit by its recipient, not the raw recipient id - #36523

Merged
objectstack-fleet[bot] merged 2 commits into
mainfrom
claude/issue-35307-share-hit-title
Nov 22, 2026
Merged

objectstack-fleet[bot] merged 2 commits into
mainfrom
claude/issue-35307-share-hit-title

Conversation

@objectstack-fleet

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

Copy link
Copy Markdown
Contributor

Requested by Steve · project thread
Fixes #35307
Clause-②: no
Metadata-protocol: none

维护者速读

  • 用户在 ⌘K 面板和全局搜索里搜到一条记录共享时,标题从一串用户编号变成被共享人的名字;看不到该用户的人仍看到编号。
  • 跟进全局搜索把关联字段标题显示成目标记录名的那次修复,替搜索用户解决共享记录标题看不懂的问题。
  • 出错时最多是搜索标题又显示回编号,或目录读取故障时整次搜索报错(与关联字段一致);直接回退本次改动即可撤回。
  • 无。

What changes

sys_record_share is titled by recipient_id, a text column whose principal kind recipient_type names. searchAll followed only a reference-typed title pointer (referenceTargetOf), so every record-share hit in the palette read as a raw user id.

searchAll now recognises a title pointer that is a recipient id by the declaration the console's recipient face already reads: a text field with widget: 'recipient-picker' and recipient_type in its dependsOn (no object-name special case; another object carrying the declaration is titled the same way). The hit is titled by the directory record its row's kind names, mirroring the console's RECIPIENT_RECORD_KINDS table:

recipient_type directory read title
user sys_user by id its ADR-0079 title (name)
unit_and_subordinates (and business_unit) sys_business_unit by id name
team (not offered on sys_record_share) sys_team by id name
group none: no directory object exists anywhere stored id kept (the console keeps it too)
position none: a registry kind, read by the console through the metadata store, not as the searcher stored value kept

Each directory is read once per swept object (id $in), through the existing readReferenceTitles, so the read is the searcher's and every gate and disposition of the #34175 reference follow applies unchanged: exposure must serve get, disabled-package targets are not read, canReadObject is asked first, a typed PERMISSION_DENIED / row scope / field-level security leaves the bare id, an unprovisioned table titles nothing, and any other read failure propagates (the 2026-08-29 search ruling: a read that could not run is never answered as no match). The hit wire shape does not move; record still carries the stored id.

Files: packages/metadata-protocol/src/protocol-record-reads.ts, new packages/metadata-protocol/src/protocol.search-title-recipient-35307.test.ts, .changeset/35307-search-recipient-title.md. No existing test was changed.

Read first: protocol-record-reads.ts recipientKindFieldOf (the declaration gate) and readRecipientTitles (grouping ids by directory), then the renderTitle call in the sweep loop.

Tests

New file protocol.search-title-recipient-35307.test.ts (12 cases): user and business-unit recipients titled by name while group and position keep the stored value; one read per directory as the searcher (id+name only); wire shape unchanged; object-level refusal (never read), refusal thrown by the read, row scope and FLS each keep the bare id; recipient_type hidden from the searcher pays no read; unprovisioned table keeps the hit; a failing directory read fails the search with its own code/status; another object with the declaration is titled the same; without the widget or without dependsOn nothing changes; a reference-typed nameField still follows its target.

Acceptance notes

  • The kind-to-directory table is a second copy of the console's RECIPIENT_RECORD_KINDS (objectui @object-ui/fields); the server cannot import the UI package. Lifting it into a spec contract both sides read is a spec change outside this card.
  • A failing (non-refusal) directory read fails the whole search, as a failing reference title read already does; it is not turned into a bare-id title, which the read-invention gate and the search ruling both forbid.

Verification

Two-minute check: pnpm --filter @objectstack/metadata-protocol exec vitest run src/protocol.search-title-recipient-35307.test.ts, expected 12 passed.

Readings at head e8b22f7 (merge base 316f757, origin/main unchanged at PR open):

Package typecheck and tests
  • pnpm --filter @objectstack/metadata-protocol typecheck exit 0; vitest run: 363 files passed, 9 skipped; 23336 tests passed, 45 skipped (lock VERDICT command-exit 0).
  • New file plus the two sibling title suites (search-title-lookup, search-title-namefield): 3 files, 32 tests passed.
  • test:repo not run locally (declared to CI Test Core).
Ablation (one-shot, not kept)

The fix's call site (renderTitle(row, referenceTitles ?? ...recipientTitles...) back to renderTitle(row, referenceTitles)) mutated on disk by scripts/ablation-replace.mjs (anchor 1 to 0, blob 34aaaee9 to 20eb4f9f); the new file went 5 failed / 7 passed (the pin, the business-unit and refusal legs, the unprovisioned-table leg, the other-object leg); restored blob equals HEAD and git diff HEAD empty. The suite imports ./protocol.js from source, so no dist rebuild applies.

Derived gate families

node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack: 67 families, each run with stdin closed, exit captured before any pipe: 67 exit 0. Three first answered exit 3 (prerequisite): the teardown-shape self-test (shallow clone, unshallowed) and check:dual-build-cjs-loads / check:lean-entry-closure (dists absent, full build at concurrency 2); each re-run exit 0. --ran: 67 derived, 67 run, 0 NOT-MEASURED, 0 UNRUN.

https://claude.ai/code/session_01ADHkmRB34k9WUWeGpRnVNm

🤖 Generated with Claude Code

@github-actions github-actions Bot added size/m documentation Improvements or additions to documentation tests tooling Fix lands in tooling, not a product package — enters pm:queue only with Unblocks: or a named surface labels Nov 22, 2026
@github-actions

Copy link
Copy Markdown
Contributor

📓 Docs Drift Check

This PR changes 1 package(s): @objectstack/metadata-protocol, touching 12 documentable anchor(s).

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

  • content/docs/automation/approvals.mdx (via sys_business_unit (literal, a string literal in business_unit; a string literal in unit_and_subordinates))
  • content/docs/automation/queues-and-assignment-rules.mdx (via business_unit (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS), unit_and_subordinates (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS), recipient_type (literal, a string literal in RECIPIENT_KIND_FIELD))
  • content/docs/data-modeling/objects.mdx (via business_unit (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS))
  • content/docs/deployment/validating-metadata.mdx (via business_unit (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS))
  • content/docs/kernel/runtime-services/sharing-service.mdx (via unit_and_subordinates (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS))
  • content/docs/permissions/administrator-guide.mdx (via unit_and_subordinates (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS), sys_business_unit (literal, a string literal in business_unit; a string literal in unit_and_subordinates), sys_team (literal, a string literal in team))
  • content/docs/permissions/authorization.mdx (via sys_business_unit (literal, a string literal in business_unit; a string literal in unit_and_subordinates))
  • content/docs/permissions/delegated-administration.mdx (via sys_business_unit (literal, a string literal in business_unit; a string literal in unit_and_subordinates))
  • content/docs/permissions/index.mdx (via business_unit (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS), unit_and_subordinates (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS))
  • content/docs/permissions/permissions-matrix.mdx (via business_unit (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS), unit_and_subordinates (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS), sys_business_unit (literal, a string literal in business_unit; a string literal in unit_and_subordinates))
  • content/docs/permissions/positions.mdx (via unit_and_subordinates (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS), sys_business_unit (literal, a string literal in business_unit; a string literal in unit_and_subordinates))
  • content/docs/permissions/sharing-rules.mdx (via business_unit (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS), unit_and_subordinates (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS), sys_business_unit (literal, a string literal in business_unit; a string literal in unit_and_subordinates), sys_team (literal, a string literal in team))
  • content/docs/protocol/objectql/security.mdx (via business_unit (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS), unit_and_subordinates (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS), sys_business_unit (literal, a string literal in business_unit; a string literal in unit_and_subordinates))

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

  • content/docs/releases/implementation-status.mdx (via business_unit (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS), unit_and_subordinates (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS))
  • content/docs/releases/v13.mdx (via unit_and_subordinates (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS), sys_business_unit (literal, a string literal in business_unit; a string literal in unit_and_subordinates))
  • content/docs/releases/v15.mdx (via recipient_type (literal, a string literal in RECIPIENT_KIND_FIELD))
  • content/docs/releases/v16.mdx (via sys_business_unit (literal, a string literal in business_unit; a string literal in unit_and_subordinates))
  • content/docs/releases/v17/17-0.mdx (via business_unit (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS), unit_and_subordinates (symbol, a field of const object RECIPIENT_DIRECTORY_OBJECTS), sys_team (literal, a string literal in team))
  • content/docs/releases/v17/17-1.mdx (via searchAll (symbol, a top-level function), recipient_type (literal, a string literal in RECIPIENT_KIND_FIELD))
  • content/docs/releases/v17/17-4.mdx (via sys_business_unit (literal, a string literal in business_unit; a string literal in unit_and_subordinates))
  • content/docs/releases/v18/18-3.mdx (via sys_business_unit (literal, a string literal in business_unit; a string literal in unit_and_subordinates))

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
  • 1 anchor(s) matched too much of the corpus to be a work list: sys_user (literal, 56 pages)
  • 2 name(s) were too generic to anchor anything (single lowercase words)
  • 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 — 10 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 316f7571617e0f22b260c457ec87692f5fc1ff5e → packageMentionDocs.

Which tree this was computed on

This run read content/docs from 6e8e38a638b360c3b53307fe5f68e491f215b173 — the merge of head e8b22f7fdf0add5fc29513625eeed3a7f7138578 into base 316f7571617e0f22b260c457ec87692f5fc1ff5e, 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 6e8e38a638b360c3b53307fe5f68e491f215b173 && git checkout 6e8e38a638b360c3b53307fe5f68e491f215b173
# afterwards, rebuild it from the two parents, which stay fetchable
git fetch origin 316f7571617e0f22b260c457ec87692f5fc1ff5e e8b22f7fdf0add5fc29513625eeed3a7f7138578 && git checkout -B drift-repro 316f7571617e0f22b260c457ec87692f5fc1ff5e && git merge --no-ff e8b22f7fdf0add5fc29513625eeed3a7f7138578

node scripts/docs-audit/affected-docs.mjs --json 316f7571617e0f22b260c457ec87692f5fc1ff5e

⚠️ 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 316f7571617e0f22b260c457ec87692f5fc1ff5e → 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

repo:objectstack#2 · os-steve · session_01ADHkmRB34k9WUWeGpRnVNm

席位核对

ACCEPT — PR #36523 @ e8b22f7 · card #35307 · L1 first read by area s2-B (area order rule 9) · 2026-11-22T18:00Z

  • Shape: open, draft, base main; first line Fixes #35307, and the PR delivers the whole card (the card's only ask is the hit title); no closing keyword near another card (l1-face.mjs --pr 36523, all rows ok).
  • Premise: held (claim 7082444246). The dev corrected one PM assumption in the report (7083127305): recipient_type values are user / group / position / unit_and_subordinates, there is no role kind. Accepted; it narrows nothing the card asked.
  • Scope: 3 files, all on the claim's file surface: protocol-record-reads.ts (+90/-1), a new card-named test file, one changeset. sys-record-share.object.ts and packages/spec/src/** untouched. Not governed (check-governed-merges.mjs --pr 36523: 0 of 3 paths), 389 changed lines.
  • Diff read: the recipient pointer is recognised by the declaration the console face reads (type: text, widget: 'recipient-picker', dependsOn naming recipient_type), not by object name; only when the pointer is not reference-typed (!titleTarget), so the fix(metadata-protocol): search titles a reference-typed nameField by its target's title #35292 follow is untouched. Ids are grouped per directory and each directory is read once through the existing readReferenceTitles, so the searcher, the gates (canServeApiOperation, canReadObject) and the dispositions are the reference follow's. A row whose kind is unreadable or has no directory pays no read and keeps the stored value.
  • Changeset .changeset/35307-search-recipient-title.md, read sentence by sentence against the diff: @objectstack/metadata-protocol patch; the kind→directory list (user→sys_user, team→sys_team, business_unit / unit_and_subordinates→sys_business_unit), "read once per swept object, as the searcher", "a directory read that fails fails the search", "group or position keeps its stored value" and "record still carries the stored id" each match the code.
  • Tests and gates: 12 cases in protocol.search-title-recipient-35307.test.ts; the failure case asserts code SERVICE_UNAVAILABLE and status 503; refusal cases (object, row scope, field-level security, a refusal thrown by the read) keep the bare id; two controls (no declaration; reference-typed nameField). Ablation reported 5 red / 7 green with the call site reverted. The existing fix(metadata-protocol): search titles a reference-typed nameField by its target's title #35292 test files are unchanged. Check-runs at this head: 39 success, 18 expected skip, 0 failed, 0 pending; Lint & Repo Gates and TypeScript Type Check success. Local gate ledger: /mnt/project-files/objectstack-seat2/35307-gates-ran.txt (67 families, 0 NOT-MEASURED).
  • Accepted deviations: (1) the dispatch suggested "a failing directory read keeps the hit with the bare id"; the dev kept the ⌘K palette hit titles a record by its raw lookup id when the object's nameField is a lookup #34175 disposition (a non-refusal failure fails the search), which is what the 2026-08-29 search ruling and the pinned fix(metadata-protocol): search titles a reference-typed nameField by its target's title #35292 tests require; the PM suggestion was wrong, the PR is right. (2) Maintainer brief has four lines (os-dev.md), not six. (3) New test file instead of extending search-title-lookup.test.ts (claim surface).
  • Out of scope: the kind→directory table now lives twice (console RECIPIENT_RECORD_KINDS, server RECIPIENT_DIRECTORY_OBJECTS), each naming the other — Acceptance notes, not filed: no defect today and zero pull for a spec-owned table. group recipients have no directory object on either side and no producer writes them — Acceptance notes, not filed (zero pull). position titles via the registry — dropped: no producer writes a non-user row.
  • Landing: non-governed, ≤3000 lines, K = 1 (landing-k.mjs: ok) ⇒ area lands it in this stroke (ready + auto-merge).

@objectstack-fleet
objectstack-fleet Bot marked this pull request as ready for review November 22, 2026 18:00
@objectstack-fleet
objectstack-fleet Bot added this pull request to the merge queue Nov 22, 2026
Merged via the queue into main with commit 07b1754 Nov 22, 2026
58 checks passed
@objectstack-fleet
objectstack-fleet Bot deleted the claude/issue-35307-share-hit-title branch November 22, 2026 18:37
247257110 pushed a commit to 247257110/objectstack that referenced this pull request Nov 23, 2026
… rating (objectstack-ai#36043) (objectstack-ai#36392)

<!-- claude-projects-attribution: {"github_login":"zhuangjianguo"} -->
_Requested by **Steedos** · [project
thread](https://claude.ai/code/project/chan_018ETKaNwMZCNRYD7D8Q9Ubb?thread=cmsg_018ETKaNwMZCNRYD7D8Q9UbbCxiFE11rsKwyNffJZKYqJs)_

Fixes objectstack-ai#36043

repo:objectstack#7 · zhuangjianguo · session_01QsR2jTbWpneBrqq7SJvrNt

Clause-②: yes (widening)
Metadata-protocol: semantic
Skills-docs: none — no skill names the inline grid column `type` values
or keys (`git grep` of `skills/` for `inlineColumns` and the column type
list: one passing mention in `objectstack-data/rules/relationships.md`,
which lists no types)

## 维护者速读

-
表单里的明细表(主从表单的行项目表格)中,人员格子可以直接搜索选人,多选格子可以选多个选项,标签格子可以加标签,勾选格子是复选框,评分格子是星星;以前这些都是普通文本框,人员要手填用户编号,多选只能填一个值。
- 属于列表页重做专题的单元格编辑那一组,替在主从表单里录入明细行的用户解决「人员、多选填不进去」的问题。
-
已有表单的明细表会直接变样:布尔字段从「是/否」下拉变成复选框,评分字段从数字框变成星星;作者在列上明确写了类型的不受影响;出错时最坏是这几类格子不好用,已存的数据不受影响,可直接撤回。
- 无

## What changes

The card's words map onto the enum by the spec's existing rule that
every column type is spelled as its namesake field type (the
`inline-grid-column-carriers` probe and the `field.json` liveness note
rely on it): people = `user`, multi-select = `multiselect`, tags =
`tags`, check = `boolean`, rating = `rating`.

**Spec (`packages/spec/src/data/field.zod.ts`).**
`InlineGridColumnSchema.type` gains `user`, `multiselect`, `tags`,
`boolean` and `rating` (nine → fourteen). The column gains one optional
key, `max`: the star count of a `rating` cell (default 5), because a
column carries no field definition and a `max: 10` rating would
otherwise draw five stars. `options` and `multiple` describe what the
new cells read from them. `inline-grid-columns.ts`
(`deriveInlineGridColumns`' cell-type mirror) maps the same way, and
each new cell type keeps the fill priority its field types had before,
so which derived columns are visible by default does not change (the
existing budget pins stay green unchanged). Liveness ledger: the `type`
note lists fourteen types, and a `max` child row. Regenerated: reference
docs, `authorable-surface/data.json` (one new key), liveness state
counts.

**Derivation (`ui/packages/plugin-form/src/deriveMasterDetail.ts`).**
`fieldTypeToColumnType` maps `user` → `user`, `multiselect` /
`checkboxes` → `multiselect`, `tags` → `tags`, `boolean` / `toggle` →
`boolean`, `rating` → `rating`. A derived or hydrated column carries
`multiple` from a multi-person field, `max` from a rating field, and the
child's options on `multiselect` columns. A `tags` column takes no
options: its cell holds free-form tags and reads no option list. A
`boolean` column keeps the two options it carried as a select (`'true'`
/ `'false'`, labelled with the session's words through `booleanLabel`):
they are the words its read-only and list-mode cells read as, so
`booleanLabel` stays live. A column that declares its `type` is left
alone, as before.

**Cells
(`ui/packages/fields/src/widgets/grid-field/GridFieldWidget.tsx`,
`gridCellPanels.tsx`).** The cells reuse the main list's in-cell faces
rather than forking them:

- `GridPanelCell` (new, beside S5's `GridSelectCell`) is a panel shell
under the cell that hosts a widget's own `inCell` face over a draft: a
click outside or Tab writes the draft, Esc writes nothing, and a face
that ends on one pick calls `commit`. The cell keeps drawing its value
while the panel is open.
- `multiselect` hosts `MultiSelectField inCell`, `tags` hosts `TagsField
inCell`, and `user` hosts `UserField inCell` (the main list's person
picker: searchable list, recents, Clear; a single pick writes and
closes).
- `boolean` is the `Checkbox` primitive (click / Space), writing `true`
/ `false`.
- `rating` draws `RatingField inCell` (a click on a star sets it); a
digit key on the cell sets that many stars, 0 clears, a digit above
`max` does nothing.
- Read-only table and list mode: people by name (`UserField readonly`),
a rating as its stars, a multi-select's option labels, a check cell as
its option word (else the session's yes/no word).
- A required cell holding an empty list (multi-select, tags, several
people) reads invalid, as an empty scalar does.
- A multi-select, tags or several-people cell that is emptied writes
`null`, not `[]`: the save path counts only `null` / `''` as blank
(`isBlankRow`), and a cleared multi-value field stores `null` elsewhere
too. An emptied cell reads `—`.

Item 2 of the card (interim read-only columns) is not built: the seat
reads it as superseded once item 1 ships, and this PR ships item 1.

**Visible change on existing master-detail forms** (named in the
changeset): a derived `boolean` / `toggle` column is a checkbox instead
of the yes/no select and writes booleans instead of the strings `'true'`
/ `'false'` (the server's write normalisation reads both the same); a
derived `rating` column is stars instead of a number box; `user`,
`multiselect`, `checkboxes` and `tags` columns are no longer plain text
boxes.

## Tests

- `ui/packages/fields/src/widgets/GridField.test.tsx`, new top-level
`describe` "the cells that edit as in the main list": multi-select
(labels, several picks staged then written on leaving, Esc writes
nothing, empty list reads invalid when required), tags (a new tag added
from the list, Tab writes and moves to the next cell), check (checkbox
over `true` and `'false'`, click writes a boolean, read-only reads the
option word), rating (five stars by default, a click sets, digit keys
set and 0 clears, a digit above the stars sets nothing, `max: 10` draws
ten), people (the person picker opens under the cell; its Clear writes
and closes). An emptied multi-select and an emptied tags cell each write
`null` (both pins go red with the fix taken out), and the emptied tags
cell reads `—`.
- `ui/packages/plugin-form/src/deriveMasterDetail.test.ts`: the five
mappings with their neighbours as controls; a new `describe` pinning the
extras on both the derive and the hydrate path (`multiple`, options on a
multi-select and none on a tags column, the check column's two words,
`max` from the field and none when the field declares none), and that an
authored column, a `type: 'select'` over a boolean field included, keeps
its type and extras.
- `deriveMasterDetail.booleanOptions-12924.test.tsx`: the derived
boolean column is now `type: 'boolean'` with the same two
session-language options; the editable grid pins read checkbox states
instead of picker text; the language-switch pin now re-labels the
read-only table (the editable check cell shows no word).
- `MasterDetailForm.lateCatalogue-12924.test.tsx`: the late-catalogue
re-label is read where the grid still draws a boolean's word, a second
detail in `inlineMode: 'form'`; the editable `Lines` detail keeps the
unsaved edit and its checkboxes through the catalogue landing.
- `deriveMasterDetail.inlineGridColumns-11345.test.ts`: the "output
unchanged" corpus moves its one derived boolean column (`gift`) from
`select` to `boolean`, marked where it sits; nothing else in the corpus
moves.

## Deviations

Four files outside the claim's surface, each a direct consequence of the
widening. Seat 7 counts them inside the card.

- `packages/metadata-core/src/object-schema-fls-references.ts`:
`INLINE_COLUMN_POSITIONS` classifies the new `max` key as `keep` (a
number, never a field name). `object-schema-fls-references.test.ts`
refuses an unclassified `InlineGridColumnSchema` key, so it was red in
Test Core 3/10 at `10767ef3`.
- `ui/packages/types/src/__tests__/strict-face-read-keys-11070.test.ts`:
the refused-column-type row used `boolean`, which is now a cell type, so
it moves to `toggle`, which is still refused. It was red in Test UI
12/16 at `10767ef3`.
- `ui/packages/types/src/form.ts`: a docblock no longer counts "nine"
cell controls.
- `content/docs/data-modeling/field-types.mdx`: the inline grid bullets
list the fourteen cell types and the checkbox booleans, and add the
people, multi-select, tags and rating cells.

The changeset adds `'@objectstack/metadata-core': patch` and
`'@object-ui/types': patch` for the first two packages.

## Acceptance notes

- A click outside a multi-select / tags / people panel writes through
the popover's own dismiss (`onOpenChange`). The jsdom pins leave the
panel through Tab, because that harness's pointer events do not reach
the dismiss. The click outside is measured live below.

## Live click-through

Showcase app (`objectstack dev --seed-admin`, fresh database) plus the
Console from source (Vite), Chromium through Playwright. To host the
three cells, the run added, without committing, `inlineEdit: 'grid'` and
`inlineColumns` (`name`, `f_multiselect`, `f_tags`, `f_users`) to
`showcase_field_zoo.f_master_detail`, and a `fieldGroups` entry placing
that child on `showcase_project`. The edits were reverted afterwards.
Project "Website Relaunch", Edit, row 0 of the zoo grid. "Outside" is a
click on the dialog's "Edit Project" heading.

| Step | Multi-select | Tags | People (multiple) |
| --- | --- | --- | --- |
| Stored before | `["red","green"]` | `["alpha","beta"]` | `null` |
| Pick | Blue | type `gamma`, Enter | Dev Admin |
| Panels open after the click outside | 0 | 0 | 0 |
| Cell after the click outside | Red, Green, Blue | alpha, beta, gamma |
Dev Admin |
| Stored after Update | `["red","green","blue"]` |
`["alpha","beta","gamma"]` | `["<Dev Admin's user id>"]` |
| Cell after a page reload and Edit again | Red, Green, Blue | alpha,
beta, gamma | Dev Admin |
| Emptied, click outside, Update: cell / stored | — / `null` | — /
`null` | not run |

The run found one defect, fixed in `2197dbdd`: an emptied tags cell drew
nothing instead of `—`. The display helper now reads an empty list as
empty for every type. It is pinned in `GridField.test.tsx`, and the
final row above was read with the fix served.
- `rating` cells keep `RatingField`'s one button per star, so Tab visits
each star; the arrows and digit keys work from any of them.

## Verification

Final head `6185caed`. It adds three commits to `f73a4351`:

- `6e74cfe0`: the review rework. Metadata-protocol is `semantic`; a
`tags` column takes no options; an emptied multi-value cell writes
`null`; the stale "twenty keys" and liveness prose is fixed.
- `2197dbdd`: the emptied tags cell reads `—`, found by the live run.
- A merge of `origin/main` at `07b17542` (objectstack-ai#36523, objectstack-ai#36478, objectstack-ai#36522,
objectstack-ai#36514, objectstack-ai#36508), and `6185caed`, which regenerates
`content/docs/references/ui/component.mdx` from the merged tree. The
merge had taken that page's `mobileMaxVisible` line from one side.

Checks at the final head:

- `dispatch-gates --ran` at `6185caed`: 120 derived families accounted
for, 120 run, 0 NOT MEASURED, every one exit 0. That includes
`check:generated` and `check:liveness` after a spec rebuild, and `pnpm
--dir ui exec vitest run scripts/` run alone under the verify lock.
- `ui/packages/fields/` + `ui/packages/plugin-form/` (whole packages) at
`6185caed`: 567 files, 7,629 tests passed, 8 skipped.
- The new pins were ablated: both "emptied, it writes null" pins and the
tags `—` pin go red with their fix taken out.
- `overlap-check` at `6185caed`, verdict read before the push. It merges
cleanly with `origin/main` `a10987ae` and with 6 of 7 open PR heads.
objectstack-ai#36543 conflicts only in `packages/spec/liveness/state-counts/field.md`,
a generated count: whichever lands second regenerates it with
`gen:liveness-counts`, not a hand merge.
- Earlier heads: at `10767ef3`, `pnpm --filter @objectstack/spec test`
(871 files, 27,909 tests) and `test:repo` (92 files, 1,562 tests)
passed. CI was green at `f73a4351`.

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

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

https://claude.ai/code/session_01QsR2jTbWpneBrqq7SJvrNt

<!-- signed: repo:objectstack#7 · zhuangjianguo ·
session_01QsR2jTbWpneBrqq7SJvrNt -->

---------

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

Projects

None yet

2 participants