Skip to content

Commit 84e6bbb

Browse files
feat(app-shell): the action result dialog draws table answer fields, and Import Users shows its result per row (#34647)
<!-- claude-projects-attribution: {"github_login":"os-steve"} --> _Requested by **Steve** · [project thread](https://claude.ai/code/project/chan_01FdL1XeUyvVNxLreh3F4Qi9?thread=cmsg_01FdL1XeUyvVNxLreh3F4Qi99ewj5JRWXTB3u38E9HLhnj)_ Part of #33187. This PR draws the per-row import result. One part stays open: the Add User result still does not say that an email-only re-add was already pending. The renderer contract cannot hide a `false` row on a fresh add, so that half moves to #34651 (see Acceptance notes). Clause-②: yes (widening) Metadata-protocol: none Skills-docs: follow-up #34648 Ruling-ref: 6915677641 ## 维护者速读 - 改了什么:控制台的动作结果弹窗和预读面板现在能画 `table` 格式,按列逐行显示;托管环境「设置 → 用户 → 导入用户」的结果从一大块 JSON 变成逐行表格(邮箱、是否成功、是否已待激活、是否已通知托管方及原因、未添加原因、未生效的列、上级未关联)。 - 为什么改:您在本卡选了 A(记录 6915677641);spec 半边(#34500)已落地,这是渲染半边。 - 风险与回滚:只加不减。其他五种格式照旧;唯一行为变化是 `code-list` 只在值为字符串数组时按代码列表画,否则画 JSON(契约本来就这么写)。回滚即撤本 PR。 - 先看:`ui/packages/app-shell/src/views/ActionResultDialog.tsx`(`TableBlock` / `TableCellValue`,`null` 画空格;`ui/packages/core/src/actions/ActionRunner.ts` 的 `columns` 类型从契约派生)、`packages/platform-objects/src/identity/sys-user.object.ts`(导入结果的列)、`packages/spec/liveness/action.json`(`columns` 转 live)。 - 两分钟验证:`cd ui && pnpm exec vitest run packages/app-shell/src/views/__tests__/ActionResultDialog.test.tsx`,预期 25 例全绿。 - 需要你做的:本 PR 改了 `packages/spec/src` 的描述文字,席位会请您批一次。「加用户」重加一个待激活的人时仍不显示「已待激活」,已另立 #34651(排在 PR #34531 之后)。 ## What changes - **Console renderer** (`ui/packages/app-shell/src/views/ActionResultDialog.tsx`). `ResultField` gains a `table` branch, following the `table` bullet of the `resultDialog` renderer contract in `packages/spec/src/ui/action.zod.ts`: - an array value draws as a table, one row per element and one cell per entry of `columns`, in order; the header is the column's `label` (an inline locale map is resolved), falling back to its `path`; - a cell reads the column's dot `path` in the element; a missing key and a `null` both draw an empty cell, never the text `null` (renderer note 1 of 6934494528); - a present value draws in the column's `format` (omitted: `text`) when it fits it (`qrcode` / `secret` / `text` a string, `code-list` an array of strings); any other value, and every `json` cell, draws as one line of JSON; - an element that is not a plain object (an array, `null`, a scalar) draws as compact JSON in its row's first cell, the other cells empty; - `[]` draws the header over the existing `table.noRows` line ("No rows to display"); no new UI string, so no `@object-ui/i18n` pack is touched; - a value that is not an array draws as `json`; a missing value is skipped, as for any field. The dialog widens from `max-w-lg` to `max-w-3xl` when it draws a table. The preflight panel draws its `fields` through the same exported `ResultField` (`ActionParamDialog.tsx#PreflightPanel`), so `preflight.fields` gets the table with no further change. - **`@object-ui/core` (r2, review nit N2).** `ResultDialogFieldSpec` in `ui/packages/core/src/actions/ActionRunner.ts` gains `columns?: SpecResultDialogField['columns']`, derived from the contract row as its `label` and `format` already are; no hand-written copy. The renderer now reads `columns` off the runner's own type, so its local intersection type is gone and the test casts (`as never`) are dropped. - **`code-list` fit test** (renderer note 2). The field-level fit test is now the contract's: an array of strings. Before, any array drew as a code list. One shared `valueFitsFormat` serves the field and the cell. - **`sys_user.import_sso_users`** (`packages/platform-objects/src/identity/sys-user.object.ts`). The `rows` field changes from `json` to `table`. Its columns are read off the door's row answer (`ImportSsoUserRowResult` in `packages/plugins/plugin-auth/src/pending-sso-users.ts`, unchanged): Row, Email, Succeeded (`ok`), Already pending, told again (`alreadyPending`), Hosting organization told (`host.notified`), Why not told (`host.reason`), Not added because (`error.message`), Not applied (`notApplied`, a code list) and Manager (`managerError`). The three summary counts are unchanged. - **Spec wrap-up** (prose and ledger only; no key, format value or refusal changes): - `columns`' describe loses `[PLANNED — not yet rendered]` and the "draws its label alone" sentence; the field `format` describe loses the marker too; - N3: the `table` bullet now says "not a plain object (an array, `null` or a scalar)"; - the bullet and the column `format` describe now say that a `null` cell value draws an empty cell. This writes renderer note 1 into the contract, so the renderer and the text agree. It goes one sentence past the delta's list, and the contract review should read it; - (r2, S1 of the contract review 6939815806) the `table` bullet and the column `format` describe now say that inside a cell `text` and `code-list` draw the value alone with no copy control, while `secret` keeps its mask, reveal and copy and `qrcode` keeps its code and copy. Prose only: no key, value or behaviour moves; - `packages/spec/liveness/action.json`: `preflight.fields.columns` and its three children go `planned` → `live`, with evidence anchored on `ResultField`, `TableBlock`, `TableCellValue` and `PreflightPanel`. The `resultDialog` row's note is updated, and `liveness/state-counts/action.md` is regenerated (live 79 → 82, planned 5 → 2). - **Docs (r2)**: `content/docs/protocol/objectui/actions.mdx` lists `table` among the answer-field formats, with its `columns` and the refusals, in the contract's wording (the item both #34500 contract records left to the renderer half). - **Changeset**: `.changeset/33187-action-answer-table-renderer.md`, patch for `@object-ui/app-shell`, `@object-ui/core`, `@objectstack/platform-objects` and `@objectstack/spec`. ## Tests - `ui/packages/app-shell/src/views/__tests__/ActionResultDialog.test.tsx` has two new top-level `describe`s in the shared harness, 13 cases. They cover: the header (label, else path) and column order; one row per element, read at each path; the empty cell for a missing key and for `null`; a misfit value drawn as compact JSON (a boolean under `text`, an object, a non-string array under `code-list`, a number under `secret`); a `secret` cell staying masked; a non-plain-object element (array, `null`, string, number) in the first cell; `[]` drawn as header plus empty line; a non-array value drawn as `json`; a missing `table` field skipped; an inline locale-map column label; the preflight path through `ResultField`; and the `code-list` string-array fit with its CONTROL. The 12 existing cases are the CONTROL for the five formats. They pass unchanged. - `packages/platform-objects/src/identity/cloud-managed-visibility.test.ts` has a new top-level `describe` (2 cases): `rows` is a `table` whose column paths are the door's row members, in order, and the summary fields stay as they were (CONTROL). - (r2) `ui/packages/core/src/actions/__tests__/ActionRunner.resultDialog.test.ts` has a new top-level `describe` with compile-time pins, compiled by the package's `tsconfig.test.json` (chained off `type-check`): `ResultDialogFieldSpec['columns']` is structurally `Equal` to the contract row's `columns`, is not `any`, and is optional. - No existing assertion changed. ## Acceptance notes - **Add User `alreadyPending` (the owed should-fix) is not delivered here, so this PR says `Part of`.** The door answers `alreadyPending: false` on every fresh add (`runAddSsoUser`). The dialog skips only a path that resolves to `undefined`, and a boolean fits no format, so it would draw as `false`. A field reading `alreadyPending` would therefore draw the misleading "false" row on every fresh add that ruling A turned down (option C). The contract offers no condition on a field. The seat chose the door route (a key present only on a re-add, widening only): it is #34651, sequenced after PR #34531, together with the real-answer alignment pin. - **The #33186 changeset sentence cannot be corrected in this changeset.** `.changeset/33186-managed-add-people-actions.md` has been released. It shipped in `@objectstack/platform-objects` 18.5.0 (entry `2e1e3b9`, `packages/platform-objects/CHANGELOG.md`), and #34042 removed it from `.changeset/`. Under AGENTS.md (Documentation Guardrails, `CHANGELOG.md` row), a released entry is amended in a dedicated docs-only PR, never by an erratum in a later changeset. The sentence becomes true when #34651 lands; that card's Done when carries the docs-only fallback. - **Column headers are not translated from bundles.** The i18n extractor (`packages/lint/src/i18n-walk.ts`) keys `resultDialog.fields.PATH` to a field's label alone, and the console overlay keys the same way, so a column `label` gets no bundle key. The import table's headers are therefore English in every locale. The field label "Result per row" above the table is still translated. Filed as #34652 (a bundle-key convention for column labels). - **Cell chrome.** In a cell, `text` and `code-list` draw the value alone, with no per-cell copy button, because a 500-row import with a copy button in every cell is unusable. `secret` keeps its mask, reveal and copy, and `qrcode` keeps its code and copy. Since r2 the contract says so in the `table` bullet and the column `format` describe (S1). - **Known limitation: `readPath` reads inherited members (review nit N1).** The dot-path reader is plain property lookup, shared by fields and cells, so a path naming a member the value does not own (`constructor`, `toString`, `email.length`) resolves to it rather than to nothing. It predates this PR, the field-level read on `main` behaves the same, and no declared path reaches it. Not changed here. - **Booleans draw as `true` / `false`.** No format draws a boolean any other way, so Succeeded, Already pending and Hosting organization told show `true` / `false`. This is the table-wide status that ruling A accepted, not a stray `false` row. - **The alignment pin does not use a real door answer.** Only `plugin-auth`'s `pending-sso-users.test.ts` can produce one while also reading the `sys_user` declaration, and this run may not edit `packages/plugins/plugin-auth/**`. So the platform-objects pin holds the column paths, the renderer pins use a sample in the door's documented row shape, and the real-answer pin rides with #34651. - **Skills text.** The `skills/objectstack-ui/rules/actions.md` sentence for `resultDialog` / `table` is governed (Tier H) and goes in #34648, after this lands. - No `ui/packages/i18n` change, so the `git merge-tree` check against PR #34531 does not apply. ## Verification Readings at head `82f384a572`. <details><summary>Ablations (each mutation landed on disk via scripts/ablation-replace.mjs, then restored to the HEAD blob)</summary> On `ui/packages/app-shell/src/views/ActionResultDialog.tsx`, against `ActionResultDialog.test.tsx` (the test imports the source file, not `dist/`): - A1, `table` branch removed (`format === 'table'` returns `json`): 9 failed, 16 passed. - A2, `null` handling removed (only `undefined` draws empty): 1 failed, the `null` empty-cell case. - A3, `code-list` fit reverted to `Array.isArray`: 2 failed, the misfit-cell case and the field-level non-string array case. Each leg restored: the blob after restore equals HEAD (`eea0d1ad0638`), and `git diff HEAD` is empty. </details> <details><summary>Local runs</summary> - `vitest run packages/app-shell/src/views/__tests__/ActionResultDialog.test.tsx`: 25 passed. - NOT MEASURED: the full `@object-ui/app-shell` suite (2284 test files). Stopped unfinished after about 49 minutes at `--maxWorkers=2` on the shared box, with no failure line printed by then. This is a declared narrowing, and the `Test UI` check carries it. - `pnpm --filter @object-ui/app-shell type-check` (src and `tsconfig.test.json`): exit 0. - `pnpm --filter @objectstack/platform-objects test`: 123 files, 2046 passed. `typecheck`: exit 0. - `pnpm --filter @objectstack/spec test`: 847 files, 27134 passed, 1 todo. `typecheck`: exit 0. - Targeted spec run (`action-answer-table-format`, `action-preflight`, `component`, `action` tests): 616 passed. - `pnpm --filter @objectstack/spec check:generated`: all 14 artifacts current after a rebuild on the merged tree. `check:liveness`: exit 0 (action: live 82, dead 1, planned 2). - `node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack` derived 98 commands on head 82f384a; each was run with stdin closed and its exit captured before any pipe. All 98 exit 0. Three needed a second run: `check-plugin-teardown-shape --self-test` first exited 3 (shallow clone; its fixture commit was fetched), `check:dual-build-cjs-loads` first exited 3 (no full build; it was rerun after `turbo run build`), and `pnpm --dir ui exec vitest run scripts/` was killed by the OOM killer while sharing the box, then passed alone (171 files passed, 2 skipped). `--ran` reconciliation: 98 derived, 98 run, 0 NOT-MEASURED, 0 UNRUN. - Not run locally: a browser pass of the dialog on a managed environment. </details> <details><summary>Round r2 (head d854d10)</summary> Old head `82f384a572` → new head `d854d108bd`. Commits: `02ecb823` (S1 prose and the actions page), `d4a79d7f` (core `columns` derived; renderer and tests use it), `d854d108` (changeset names core and the cell sentence), plus merge `6dbbf712` of `origin/main` (PR #34531 included). - Ablations of the derivation, via `scripts/ablation-replace.mjs` on `ActionRunner.ts`, each read by `tsc -p tsconfig.test.json` in `ui/packages/core`: B1, the derived `columns` member deleted → exit 2, TS2339/TS2353 at the new pins; B2, `columns` restated by hand as an array of `{ path: string; label?: string }` → exit 2, TS2344 (`_IsTheSpecColumns` false) and TS2353. Both legs restored: blob equals HEAD (`f47c1e3b9716`), `git diff HEAD` empty. A first B1 attempt passed an empty `--replacement`; the tool refused it (count rose 0, not 1) and nothing ran, so it was rerun with `--delete`. The S1 and docs edits are prose only, so they get no ablation. - `@object-ui/core` type-check and `@object-ui/app-shell` type-check: exit 0. `ActionResultDialog.test.tsx` and `ActionRunner.resultDialog.test.ts`: 2 files, 40 passed. - Spec: `action-answer-table-format`, `action-preflight`, `component`, `action` and `check-liveness` tests: 5 files, 699 passed. `check:generated`: all 14 current. A first run reported `check:test-typecheck` stale because `tsc` exited without diagnostics on the shared box; rerun alone under the lock: all current, nothing regenerated. - `dispatch-gates --commands` derived 119 commands on `d854d108bd` (the merge brought docs families). Each was run with stdin closed and its exit captured before any pipe: all 119 exit 0. `--ran`: 119 derived, 119 run, 0 NOT-MEASURED, 0 UNRUN. </details> 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01ADHkmSYVw1sqCsaHSJS9JC <!-- signed: repo:objectstack#2 · os-steve · session_01ADHkmSYVw1sqCsaHSJS9JC --> --------- Co-authored-by: Claude <noreply@anthropic.com>
1 parent a1082f3 commit 84e6bbb

11 files changed

Lines changed: 481 additions & 37 deletions

File tree

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
---
2+
'@object-ui/app-shell': patch
3+
'@object-ui/core': patch
4+
'@objectstack/platform-objects': patch
5+
'@objectstack/spec': patch
6+
---
7+
8+
feat(app-shell): the action result dialog draws a `table` answer field as rows, and Import Users shows its result per row in one
9+
10+
Clause-②: yes (widening) — the console now draws `format: 'table'` fields (declared since the spec half) instead of their label alone, and `sys_user.import_sso_users` draws its per-row report as a table instead of JSON; no input is refused that was accepted before
11+
Metadata-protocol: none
12+
13+
The console's action result dialog, and the param dialog's preflight panel that shares its field renderer, draw a field with `format: 'table'` as a table: one row per element of the array, one cell per entry of the field's `columns`, in order, under the column's `label` (or its `path`). A cell reads its `path` in the element; a missing key or a `null` draws an empty cell, a value that fits the column's `format` draws in it, and anything else draws as one line of JSON. An element that is not a plain object draws as JSON in its row's first cell. An empty array draws the header over a "No rows to display" line. The dialog widens when it draws a table.
14+
15+
A `code-list` field now draws as a code list only when its value is an array of strings, as the renderer contract says; any other array draws as JSON.
16+
17+
`@objectstack/platform-objects`: on a cloud-managed environment, the Import Users result shows one row per CSV line, with the email, whether it succeeded, whether the address was already pending, whether the hosting organization was told and why not, why a row was not added, the columns that were not applied, and a manager that was not linked. The summary counts stay above it.
18+
19+
`@objectstack/spec`: `columns` is no longer marked `[PLANNED — not yet rendered]`, and the renderer contract now says that a `null` cell value draws an empty cell and that only a plain object is read by column paths (an array or `null` element draws as JSON). It also says that inside a table cell `text` and `code-list` draw the value alone with no copy control, while `secret` keeps its mask, reveal and copy and `qrcode` keeps its code and copy. Its liveness rows are `live`.
20+
21+
`@object-ui/core`: `ResultDialogFieldSpec` gains `columns`, derived from the contract's answer-field row like its `label` and `format`, so the console's table renderer reads it off the runner's own type.

‎content/docs/protocol/objectui/actions.mdx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -480,7 +480,7 @@ resultDialog:
480480
- { path: client.client_secret, label: Client Secret, format: secret }
481481
```
482482

483-
Each `fields[].path` is a dot path into `result.data`. The per-field `format` (`qrcode`, `code-list`, `secret`, `text`, `json`) controls rendering.
483+
Each `fields[].path` is a dot path into `result.data`. The per-field `format` (`qrcode`, `code-list`, `secret`, `text`, `json`, `table`) controls rendering. `table` draws an array as rows and requires `columns: [{ path, label?, format? }]`, one entry per cell, with `path` read in one element of the array; `columns` is refused beside any other format, and a cell takes any format but `table`.
484484

485485
#### ⚠️ That `target` is not interchangeable with the SDK's registration door
486486

‎packages/platform-objects/src/identity/cloud-managed-visibility.test.ts‎

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -293,3 +293,45 @@ describe('features.cloudManaged hides every other action whose door writes or de
293293
expect(offeredOn(SysInvitation, 'reject_invitation', INVITATION_ROW, { ...MULTI, cloudManaged: true })).toBe(true);
294294
});
295295
});
296+
297+
/**
298+
* objectstack#33187: the import door answers one report row per CSV line
299+
* (plugin-auth `ImportSsoUserRowResult`: `row`, `email`, `ok`,
300+
* `alreadyPending`, `host`, `error`, `notApplied`, `managerError`), and the
301+
* result dialog draws that report as a `table`, one cell per member a reader
302+
* needs, instead of a block of JSON. The columns are the contract's
303+
* (`resultDialog.fields[].columns`), so the declaration parses as the
304+
* console's `ResultField` reads it.
305+
*/
306+
describe('import_sso_users draws the per-row report as a table', () => {
307+
const rowsField = () => {
308+
const dialog = declared('import_sso_users').resultDialog as { fields?: Array<Record<string, unknown>> };
309+
return (dialog.fields ?? []).find((field) => field.path === 'rows');
310+
};
311+
312+
it('declares `rows` as a `table` whose columns read the door row members, in reading order', () => {
313+
const field = rowsField();
314+
expect(field?.format).toBe('table');
315+
expect((field?.columns as Array<{ path: string }>).map((column) => column.path)).toEqual([
316+
'row',
317+
'email',
318+
'ok',
319+
'alreadyPending',
320+
'host.notified',
321+
'host.reason',
322+
'error.message',
323+
'notApplied',
324+
'managerError',
325+
]);
326+
});
327+
328+
it('CONTROL: the summary counts stay fields of their own, ahead of the table', () => {
329+
const dialog = declared('import_sso_users').resultDialog as { fields?: Array<{ path: string; format?: string }> };
330+
expect(dialog.fields?.map((field) => [field.path, field.format])).toEqual([
331+
['summary.added', 'text'],
332+
['summary.alreadyPending', 'text'],
333+
['summary.failed', 'text'],
334+
['rows', 'table'],
335+
]);
336+
});
337+
});

‎packages/platform-objects/src/identity/sys-user.object.ts‎

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -548,11 +548,32 @@ export const SysUser = ObjectSchema.create({
548548
resultDialog: {
549549
title: 'Import Finished',
550550
acknowledge: 'Done',
551+
// `rows` is the door's per-row report (plugin-auth
552+
// `ImportSsoUserRowResult`), drawn as a table: one row per CSV line, a
553+
// cell per answer member. A member a row does not carry draws an empty
554+
// cell: `alreadyPending` and `host` only on a row that was added,
555+
// `error` only on one that was not, `notApplied` only on a re-add that
556+
// sent columns, `managerError` only when no manager was linked.
551557
fields: [
552558
{ path: 'summary.added', label: 'Added', format: 'text' },
553559
{ path: 'summary.alreadyPending', label: 'Already pending, told again', format: 'text' },
554560
{ path: 'summary.failed', label: 'Not added', format: 'text' },
555-
{ path: 'rows', label: 'Result per row', format: 'json' },
561+
{
562+
path: 'rows',
563+
label: 'Result per row',
564+
format: 'table',
565+
columns: [
566+
{ path: 'row', label: 'Row', format: 'json' },
567+
{ path: 'email', label: 'Email' },
568+
{ path: 'ok', label: 'Succeeded', format: 'json' },
569+
{ path: 'alreadyPending', label: 'Already pending, told again', format: 'json' },
570+
{ path: 'host.notified', label: 'Hosting organization told', format: 'json' },
571+
{ path: 'host.reason', label: 'Why not told' },
572+
{ path: 'error.message', label: 'Not added because' },
573+
{ path: 'notApplied', label: 'Not applied (set these on the record)', format: 'code-list' },
574+
{ path: 'managerError', label: 'Manager' },
575+
],
576+
},
556577
],
557578
},
558579
},

‎packages/spec/liveness/action.json‎

Lines changed: 14 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,7 @@
277277
},
278278
"resultDialog": {
279279
"status": "live",
280-
"note": "objectui one-shot result reveal {title,description,acknowledge,format,fields}. `fields[].format: 'table'` and its `columns` (#34391) are PLANNED until the console reader #33187 lands (see `preflight.fields.columns`, the same row): the spec refuses the contradictions at parse, and the console draws a `table` row's label alone today."
280+
"note": "objectui one-shot result reveal {title,description,acknowledge,format,fields}. `fields[].format: 'table'` and its `columns` (#34391) are LIVE since the console reader #33187 (see `preflight.fields.columns`, the same row): the spec refuses the contradictions at parse, and the console's `ResultField` draws a `table` row as a table, one row per element and one cell per column."
281281
},
282282
"preflight": {
283283
"status": "live",
@@ -327,24 +327,25 @@
327327
"note": "Live with its container `preflight.fields`: the row's display format, from resultDialog's format set."
328328
},
329329
"columns": {
330-
"status": "planned",
331-
"verifiedAt": "2026-11-16",
332-
"note": "PLANNED (spec card #34391; reader #33187, maintainer ruling A 6915677641). The cells of a `format: 'table'` row, `[{ path, label?, format? }]`, from the row builder `resultDialog.fields` shares (packages/spec/src/ui/action.zod.ts#actionAnswerFieldRow). Enforced at parse today: required by `table`, refused beside any other format (#refuseTableColumnContradictions), and a cell takes the field formats minus `table`. NOT yet drawn: the console's `ResultField` (ui/packages/app-shell/src/views/ActionResultDialog.tsx) has no `table` branch, so until #33187 lands a `table` row draws its label alone. Re-grade `live` in the PR that lands that renderer.",
330+
"status": "live",
331+
"verifiedAt": "2026-11-17",
332+
"evidence": "ui/packages/app-shell/src/views/ActionResultDialog.tsx#ResultField (the `table` branch: an array value draws through `TableBlock`, any other value as `json`); ui/packages/app-shell/src/views/ActionResultDialog.tsx#TableBlock (one row per element, one cell per entry of `columns`, in order); ui/packages/app-shell/src/views/ActionResultDialog.tsx#TableCellValue (the cell, in the column's format or as compact JSON); ui/packages/app-shell/src/views/ActionParamDialog.tsx#PreflightPanel (each preflight `fields` row through the same `ResultField`)",
333+
"note": "LIVE (spec card #34391; reader #33187, maintainer ruling A 6915677641). The cells of a `format: 'table'` row, `[{ path, label?, format? }]`, from the row builder `resultDialog.fields` shares (packages/spec/src/ui/action.zod.ts#actionAnswerFieldRow). Enforced at parse: required by `table`, refused beside any other format (#refuseTableColumnContradictions), and a cell takes the field formats minus `table`. Drawn by the console's `ResultField`, which the result dialog and the preflight panel share, by the `table` bullet of the `resultDialog` renderer contract; pinned in ui/packages/app-shell/src/views/__tests__/ActionResultDialog.test.tsx. First producer: `sys_user.import_sso_users`, whose per-row report draws as a table (packages/platform-objects/src/identity/sys-user.object.ts).",
333334
"children": {
334335
"path": {
335-
"status": "planned",
336-
"verifiedAt": "2026-11-16",
337-
"note": "Planned with its container `preflight.fields.columns`: the dot path, in ONE element of the array, of the value a cell draws; a path that resolves to nothing draws an empty cell, and an element that is not an object draws as compact JSON text in its row's first cell."
336+
"status": "live",
337+
"verifiedAt": "2026-11-17",
338+
"note": "Live with its container `preflight.fields.columns`: the dot path, in ONE element of the array, of the value a cell draws; a path that resolves to nothing or to `null` draws an empty cell, and an element that is not a plain object draws as compact JSON text in its row's first cell."
338339
},
339340
"label": {
340-
"status": "planned",
341-
"verifiedAt": "2026-11-16",
342-
"note": "Planned with its container `preflight.fields.columns`: the column header; omitted, the header is the column's `path`."
341+
"status": "live",
342+
"verifiedAt": "2026-11-17",
343+
"note": "Live with its container `preflight.fields.columns`: the column header; omitted, the header is the column's `path`."
343344
},
344345
"format": {
345-
"status": "planned",
346-
"verifiedAt": "2026-11-16",
347-
"note": "Planned with its container `preflight.fields.columns`: the cell format, the field formats minus `table` (refused at parse: a table does not nest); omitted, `text`. A value that does not fit the cell's format, whatever it is, draws as compact JSON text, and a missing value draws an empty cell (the `table` bullet of the `resultDialog` renderer contract)."
346+
"status": "live",
347+
"verifiedAt": "2026-11-17",
348+
"note": "Live with its container `preflight.fields.columns`: the cell format, the field formats minus `table` (refused at parse: a table does not nest); omitted, `text`. A value that does not fit the cell's format, whatever it is, draws as compact JSON text, and a missing or `null` value draws an empty cell (the `table` bullet of the `resultDialog` renderer contract)."
348349
}
349350
}
350351
}

‎packages/spec/liveness/state-counts/action.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,4 @@ committed anywhere: `check:liveness` sums the shards when it reads them.
1212

1313
| Type | live | exp | elsewhere | dead | planned | classified |
1414
|---|---|---|---|---|---|---|
15-
| `action` | 79 | 0 | 0 | 1 | 5 | 85 |
15+
| `action` | 82 | 0 | 0 | 1 | 2 | 85 |

‎packages/spec/src/ui/action.zod.ts‎

Lines changed: 16 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -873,7 +873,7 @@ const ActionAnswerTableColumnSchema = strictObject({
873873
'`table` is a field format, not a cell format: a cell draws one value of one row, and a table does not '
874874
+ 'nest. Drop `format` (a cell value that does not fit its format, an object or an array included, draws as compact JSON text), or '
875875
+ "write `format: 'json'`.",
876-
).optional().describe('Cell format: the field formats minus `table`; omitted, `text`. A value that does not fit the cell\'s format, whatever it is (an object or an array under `text`, a number under `secret`), draws as compact JSON text; a missing value draws an empty cell.'),
876+
).optional().describe('Cell format: the field formats minus `table`; omitted, `text`. A value that does not fit the cell\'s format, whatever it is (an object or an array under `text`, a number under `secret`), draws as compact JSON text; a missing or `null` value draws an empty cell. Inside a cell, `text` and `code-list` draw the value alone with no copy control, while `secret` keeps its mask, reveal and copy and `qrcode` keeps its code and copy.'),
877877
});
878878

879879
/**
@@ -935,8 +935,8 @@ function actionAnswerFieldRow(surface: string, pathDescription: string) {
935935
}, {
936936
path: z.string().describe(pathDescription),
937937
label: I18nLabelSchema.optional(),
938-
format: ActionAnswerFieldFormatSchema.optional().describe('Per-field format override. `table` [PLANNED — not yet rendered] draws an array as rows and requires `columns`.'),
939-
columns: z.array(ActionAnswerTableColumnSchema).optional().describe("[PLANNED — not yet rendered] The cells of a `format: 'table'` field, in order: `[{ path, label?, format? }]`, `path` read in ONE element of the array. Required by `table` (never guessed from the element's keys) and refused beside any other format. Until the console's table renderer lands, a `table` field draws its label alone."),
938+
format: ActionAnswerFieldFormatSchema.optional().describe('Per-field format override. `table` draws an array as rows and requires `columns`.'),
939+
columns: z.array(ActionAnswerTableColumnSchema).optional().describe("The cells of a `format: 'table'` field, in order: `[{ path, label?, format? }]`, `path` read in ONE element of the array. Required by `table` (never guessed from the element's keys) and refused beside any other format."),
940940
}).superRefine(refuseTableColumnContradictions);
941941
}
942942

@@ -1809,15 +1809,19 @@ const actionObject = () => strictObject({
18091809
* each entry of the field's `columns` one cell, in `columns` order. The
18101810
* header of a column is its `label`, falling back to its `path`. A cell
18111811
* reads the column's dot `path` in the element; a missing value (the
1812-
* path resolves to `undefined`) draws an empty cell. A present value
1813-
* draws in the column's `format` (omitted: `text`) when it fits that
1814-
* format the way a field's value must: `qrcode`, `secret` and `text` take
1815-
* a string, `code-list` an array of strings. Any value that does not fit,
1816-
* whatever the column's format (an object or an array under the omitted
1817-
* `text`, a number under `secret`), draws as compact JSON text, which is
1818-
* also how `json` draws in a cell. An element that is not an object has no
1819-
* paths to read: its row draws the element itself as compact JSON text in
1820-
* the first cell and leaves the other cells empty. `[]` draws the header
1812+
* path resolves to `undefined`) and a `null` draw an empty cell. A
1813+
* present value draws in the column's `format` (omitted: `text`) when it
1814+
* fits that format the way a field's value must: `qrcode`, `secret` and
1815+
* `text` take a string, `code-list` an array of strings. Any value that
1816+
* does not fit, whatever the column's format (an object or an array under
1817+
* the omitted `text`, a number under `secret`), draws as compact JSON
1818+
* text, which is also how `json` draws in a cell. Inside a cell, `text`
1819+
* and `code-list` draw the value alone with no copy control, while
1820+
* `secret` keeps its mask, reveal and copy and `qrcode` keeps its code
1821+
* and copy. An element that is not
1822+
* a plain object (an array, `null` or a scalar) has no paths to read: its
1823+
* row draws the element itself as compact JSON text in the first cell and
1824+
* leaves the other cells empty. `[]` draws the header
18211825
* row over an empty-state line. A field value that is missing is skipped
18221826
* like any other field's, and one that is not an array draws as `json`,
18231827
* as `code-list` does.

0 commit comments

Comments
 (0)