Skip to content

docs(api): spell the object-view example's default list view at the node level - #7991

Merged
baozhoutao merged 1 commit into
mainfrom
claude/issue-7923-schema-reference-default-list-view
Sep 6, 2026
Merged

baozhoutao merged 1 commit into
mainfrom
claude/issue-7923-schema-reference-default-list-view

Conversation

@claude

@claude claude Bot commented Sep 6, 2026

Copy link
Copy Markdown
Contributor

Fixes #7923

content/docs/api/schema-reference.md's ObjectViewSchema example authored an
entry-level key that nothing declares and nothing reads, so the view it labelled
"default" never opened first — twenty rows above the same page's property table
that documents the correct key.

Before / after

     "my-deals": {
-      "label": "My Deals",
       "filter": [["owner", "=", "${currentUser.id}"]],
-      "default": true
+      "label": "My Deals"
     }
   },
+  "defaultListView": "my-deals",
   "table": {

Why the two remaining members are reordered rather than left alone: the
sibling pin packages/types/src/__tests__/object-view-unmirrored-keys-7779.test.ts:529
holds the filter line verbatim including its trailing comma —

expect(readRepo('content/docs/api/schema-reference.md')).toContain('"filter": [["owner", "=", "${currentUser.id}"]],');

— so deleting "default": true while filter stayed last would have dropped that
comma and reddened a pin held by draft PR #7969. filter therefore keeps a member
after it. No content was invented to fill the slot.

Premises, re-measured on origin/main e97e8e8

# Premise Verdict
A1 NamedListView (packages/types/src/objectql.ts:1983) declares no default; ObjectView.tsx:701 reads schema.defaultListView holds — control member label present; renderer line quoted below
A2 The page's own property table already documents defaultListView holds — content/docs/api/schema-reference.md:885
A3 No other doc authors an entry-level default holds — git grep -n '"default": true' -- content/docs returns exactly this one hit; the twelve default: true hits are all (default: true) prose in property comments, a different shape
A4 The page is on check:doc-snippets' scan surface holds — not one of the 22 UNGATED_DOCS entries; but TS_FENCE_LANGUAGES = {ts, tsx, typescript}, and this example is a ```json fence, so it is collected and never compiled (#5250). That is exactly the hole the fixture pin fills
packages/plugin-view/src/ObjectView.tsx:701:    if (schema.defaultListView && namedListViews?.[schema.defaultListView]) {
packages/plugin-view/src/ObjectView.tsx:702:      return schema.defaultListView;

The pin, and why it is a fixture pin and not a type annotation

packages/types/src/__tests__/schema-reference-named-list-view-keys-7923.test.ts
parses both sides off disk on every run — the shape #7925 points at
(packages/plugin-calendar/src/readme-calendar-view-schema.test.ts): the
declaration's own top-level members are brace-matched out of the interface source
(brace matching, not a line regex, because NamedListView carries JSDoc blocks and
four nested object members that a regex would miscount), and the example is located
by its ### ObjectViewSchema heading and parsed as JSON. Restating the member list
in the test would reproduce the original defect one layer up.

An annotation on the example would catch nothing. BaseSchema closes with
[key: string]: any (#7927), so every invented key type-checks through the index
signature — #7927 measured it directly (probe P5: renaming titleField to
titleFieldd inside an annotated block left check:doc-snippets at exit 0). The
annotation checks a key's type and never its name. What makes a name-level
comparison possible here at all is that NamedListView is a standalone interface
that does not extend BaseSchema, so its declared members are a genuinely closed
list.

The pin asserts four things: a live control (the declaration parsed to >30 members
including the required label, and the doc parsed to exactly the two named views),
the predicate itself (every authored listViews key is declared), the node-level
defaultListView naming a key that exists, and a positive control that runs on
every invocation
— it plants default into the parsed object and asserts the
same predicate function returns ['default'], so the harness cannot go quietly
green. That control opens by asserting NamedListView does not declare default,
which is the tripwire if that ever changes.

The pin imports only vitest and node builtins and reads files off disk, so it
needs no build
.

Reverse verification (post-commit, trap-protected, restore proven by blob hash)

Each leg mutated the committed doc, proved the mutation actually landed (on-disk
hash ≠ the HEAD blob hash 87e58fa…, so no leg was a silent no-op), ran the pin,
then restored with git checkout HEAD -- ABSOLUTE_PATH and proved the restore by
hash equality and an empty git diff HEAD.

Leg Mutation Predicted Observed
A put "default": true back into my-deals RED naming default RED, exit 1 — authors no key NamedListView does not declare … expected [ 'default' ] to deeply equal []
B delete the node-level "defaultListView" line RED on the presence assertion RED, exit 1 — must spell \defaultListView` … expected 'undefined' to be 'string'`
C rename the anchor heading (the example "moves") LOUD failure, never a vacuous pass RED, exit 1 — Error: "### ObjectViewSchema" heading not found … the example moved, Tests no tests
— unmutated tree GREEN GREEN, exit 0 — Test Files 1 passed (1), Tests 4 passed (4)

The positive control was among the 3 passing tests in every red leg, so it is
demonstrably executed rather than merely present.

Gates

Gate Verdict line
object-view-unmirrored-keys-7779.test.ts (the sibling pin on the filter line) exit 0 — green in the 10-file reader run below, and again at final HEAD: Test Files 2 passed (2), Tests 94 passed (94)
pnpm check:doc-snippets exit 0 — Semantic phase: 495 of 495 block(s) judged, 0 failed. (after its own scoped --build-filter build, 34 tasks, exit 0; the first run's exit 2 was "I could not run", not a verdict)
pnpm check:doc-fences exit 0 — every TypeScript block in 227 document(s) is fenced ts/tsx/typescript
node scripts/check-doc-links.mjs exit 0 — Links are valid across 17 scan roots.
pnpm check:doc-types exit 0 — Every documented component type is registered.
pnpm check:control-bytes exit 0 — scanned 6430 tracked text file(s); skipped 85 binary
node scripts/check-changeset-presence.mjs exit 0 — see the deviation below
pnpm changeset:check exit 0 — No changeset declares a major bump.
check-governed-queue-guard --test (all 3 paths) exit 0 — NOT GOVERNED — 3 path(s) checked against 5 governed surface(s)
pnpm --filter @object-ui/types type-check exit 0; tsc -p tsconfig.test.json --listFiles shows the new test IS in the program, so this is a measurement of it and not around it
pnpm --filter @object-ui/types lint exit 0 — 273 problems (0 errors, 273 warnings), all pre-existing; the new file contributes 0 errors, 0 warnings (--format json, 1 file)
pnpm exec vitest run packages/types/ exit 0 — Test Files 131 passed (131), Tests 2418 passed (2418)
pnpm check:doc-example-readers exit 0
node scripts/check-doc-expression-carriage.mjs exit 0 (report-only gate)
pnpm check:docs-route-closure exit 0

Readers of the page — git grep -l 'schema-reference.md' -- scripts/ packages/ .github/ content/ returns 16 sites; every test among them was run together and passed: Test Files 10 passed (10), Tests 354 passed (354) (object-view-unmirrored-keys-7779, component-docs-retired-handler-keys-7340, kanban-plugin-dialect-authoritative-7664, object-grid-title-mirrored, tree-view-data-retired-6951, zod-mirror-parity, table-column-contract, check-doc-component-types, check-doc-links, plus the new pin).

Lint narrowing — type-aware linting is not enabled in eslint.config.js (no
project / projectService), and markdown is not in eslint's file population, so
this diff cannot move the verdict on any file it does not contain; the whole
@object-ui/types package was linted anyway.

Deviation from the dispatch

The dispatch predicted check-changeset-presence would owe nothing ("docs + test
only — expect none owed"). It owes one. The gate reads any file under a
released package's src/, tests included:

1 source file(s) of 1 released package(s) changed, and this change adds no changeset — @object-ui/types / packages/types/src/__tests__/schema-reference-named-list-view-keys-7923.test.ts

Answered the way the gate itself names as the legitimate pass in this repo — an
empty-frontmatter .changeset/*.md declaring that nothing releases (⛔ not the
skip-changeset label, which this repo does not honour):

Every one of them has an EMPTY frontmatter — declared as releasing nothing, which is the explicit exemption and a complete answer to this gate.

⛔ The filter dialect is untouched, deliberately

Line 863's "filter": [["owner", "=", "${currentUser.id}"]], is byte-identical
to origin/main. Triage split this card in two and ruled the dialect half
(the ObjectQL tuple form here versus the { field, operator, value } objects
packages/plugin-view/README.md and content/docs/plugins/plugin-view.mdx teach)
out of scope until which spelling mergeFilterNodes actually runs is measured —
NamedListView.filter is an untyped array, so both are declared-legal and guessing
would risk making a correct page wrong. That is #2890's half. It was not measured
here. The new pin cannot and does not adjudicate it: it compares key names
against the declaration, and filter is a declared member under either dialect.

🤖 Generated with Claude Code

https://claude.ai/code/session_01MM7kaS4dPpYHV5BsMyu4tQ


Generated by Claude Code

…ode level

`content/docs/api/schema-reference.md`'s `ObjectViewSchema` example authored
`listViews["my-deals"].default: true`. `NamedListView` declares no `default`
member, and `ObjectView.tsx` picks the opening view from the NODE-level
`schema.defaultListView` (falling back to the first key) — nothing reads an
entry-level flag. `BaseSchema` is passthrough, so the example validated green
while the view it labelled "default" never opened first, twenty rows above the
same page's property table that documents `defaultListView` correctly.

The example now spells `"defaultListView": "my-deals"` on the node and drops the
undeclared key. `my-deals`' two remaining members are reordered so the filter
line keeps its trailing comma: `object-view-unmirrored-keys-7779.test.ts` holds
that line verbatim, comma included, and that file is held by another PR.

A new fixture pin, `schema-reference-named-list-view-keys-7923.test.ts`, holds
the example's `listViews` keys to `NamedListView`'s declared members, both sides
parsed off disk. A type annotation would catch nothing here: `BaseSchema` closes
with `[key: string]: any`, and the fence is JSON so no snippet gate compiles it.

The example's filter DIALECT is deliberately untouched — which spelling
`mergeFilterNodes` runs is unmeasured, and that is objectui#2890's half.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MM7kaS4dPpYHV5BsMyu4tQ
@github-actions

github-actions Bot commented Sep 6, 2026

Copy link
Copy Markdown
Contributor

✅ Console Performance Budget

Metric Value Budget
Eager closure (gzip, 50 chunks) 3186.0 KB 3191.4 KB
Main entry chunk (gzip) 143.5 KB 350 KB
Entry file index-BO0uFEv5.js —
Status PASS —

The eager closure is every chunk the entry reaches through static imports — what the browser fetches and parses before the app renders. The entry chunk on its own is a small fraction of it.


📦 Bundle Size Report

Package Size Gzipped
app-shell (consoleActionDispatch.js) 0.20KB 0.19KB
app-shell (index.js) 15.67KB 5.75KB
app-shell (runtime-config.js) 20.68KB 7.36KB
app-shell (types.js) 0.01KB 0.04KB
app-shell (urlParams.js) 10.06KB 3.86KB
auth (ActiveOrganizationStorage.js) 25.05KB 9.16KB
auth (AuthContext.js) 0.31KB 0.24KB
auth (AuthGuard.js) 2.07KB 1.00KB
auth (AuthProvider.js) 40.18KB 10.59KB
auth (AuthShell.js) 3.49KB 1.40KB
auth (ForgotPasswordForm.js) 12.21KB 3.45KB
auth (LoginForm.js) 18.15KB 5.39KB
auth (PreviewBanner.js) 0.90KB 0.50KB
auth (RegisterForm.js) 6.65KB 2.22KB
auth (SocialSignInButtons.js) 9.61KB 3.89KB
auth (UserMenu.js) 3.41KB 1.23KB
auth (auth-gate-events.js) 1.29KB 0.66KB
auth (authStyles.js) 5.04KB 1.72KB
auth (createAuthClient.js) 40.21KB 10.80KB
auth (createAuthenticatedFetch.js) 8.46KB 3.43KB
auth (index.js) 3.19KB 1.44KB
auth (invitation-status.js) 1.22KB 0.70KB
auth (org-roles.js) 6.66KB 2.78KB
auth (phone-identifier.js) 1.11KB 0.66KB
auth (types.js) 0.59KB 0.35KB
auth (useAuth.js) 5.30KB 1.02KB
auth (useWorkspaceAdminStatus.js) 5.13KB 2.35KB
collaboration (CommentThread.js) 26.08KB 7.56KB
collaboration (LiveCursors.js) 3.17KB 1.27KB
collaboration (PresenceAvatars.js) 6.49KB 2.64KB
collaboration (PresenceProvider.js) 2.79KB 1.13KB
collaboration (index.js) 1.68KB 0.73KB
collaboration (useCollaborationTranslation.js) 6.05KB 2.52KB
collaboration (useCommentSearch.js) 1.98KB 0.88KB
collaboration (useConflictResolution.js) 7.75KB 1.86KB
collaboration (useMentionNotifications.js) 1.81KB 0.68KB
collaboration (usePresence.js) 6.33KB 1.84KB
collaboration (useRealtimeSubscription.js) 7.91KB 2.01KB
components (index.js) 497.06KB 113.79KB
core (index.js) 6.96KB 2.79KB
create-plugin (index.js) 10.08KB 3.26KB
data-objectstack (index.js) 182.08KB 50.62KB
fields (index.js) 242.44KB 61.25KB
i18n (LocalizationContext.js) 1.76KB 0.96KB
i18n (builtinAggregateLabels.js) 0.86KB 0.49KB
i18n (currency.js) 1.22KB 0.64KB
i18n (fallbackInterpolation.js) 6.25KB 2.77KB
i18n (i18n.js) 4.28KB 1.75KB
i18n (index.js) 3.65KB 1.47KB
i18n (pickLocalized.js) 7.62KB 3.26KB
i18n (provider.js) 26.89KB 9.04KB
i18n (useDisplayLocale.js) 2.85KB 1.45KB
i18n (useObjectLabel.js) 34.34KB 9.17KB
i18n (useSafeTranslation.js) 5.60KB 2.33KB
layout (index.js) 38.84KB 10.94KB
mobile (MobileProvider.js) 0.92KB 0.49KB
mobile (ResponsiveContainer.js) 0.94KB 0.38KB
mobile (breakpoints.js) 1.51KB 0.70KB
mobile (createOfflineDataSource.js) 5.61KB 1.75KB
mobile (index.js) 1.99KB 0.87KB
mobile (offlineQueue.js) 3.91KB 1.35KB
mobile (pwa.js) 0.97KB 0.49KB
mobile (serviceWorker.js) 1.48KB 0.62KB
mobile (serviceWorkerSource.js) 3.41KB 1.48KB
mobile (useBreakpoint.js) 1.54KB 0.65KB
mobile (useGesture.js) 6.96KB 1.98KB
mobile (useOfflineSync.js) 1.99KB 0.72KB
mobile (usePullToRefresh.js) 2.53KB 0.85KB
mobile (useResponsive.js) 0.72KB 0.42KB
mobile (useSpecGesture.js) 4.39KB 1.66KB
mobile (useTouchTarget.js) 1.01KB 0.54KB
permissions (MePermissionsProvider.js) 11.71KB 4.29KB
permissions (PermissionContext.js) 0.31KB 0.25KB
permissions (PermissionGuard.js) 0.89KB 0.45KB
permissions (PermissionProvider.js) 6.24KB 2.16KB
permissions (discardProofCache.js) 1.04KB 0.55KB
permissions (evaluator.js) 5.12KB 1.74KB
permissions (index.js) 0.93KB 0.41KB
permissions (store.js) 0.91KB 0.42KB
permissions (useFieldPermissions.js) 1.28KB 0.53KB
permissions (usePermissions.js) 4.83KB 2.27KB
plugin-ai (index.js) 15.16KB 3.68KB
plugin-calendar (index.js) 47.35KB 13.21KB
plugin-charts (index.js) 70.31KB 19.62KB
plugin-chatbot (index.js) 193.53KB 46.05KB
plugin-dashboard (index.js) 131.41KB 34.43KB
plugin-designer (index.js) 211.51KB 43.01KB
plugin-detail (index.js) 247.59KB 63.48KB
plugin-editor (index.js) 2.23KB 1.05KB
plugin-form (index.js) 131.01KB 32.32KB
plugin-gantt (index.js) 167.16KB 40.99KB
plugin-grid (index.js) 208.56KB 56.63KB
plugin-kanban (index.js) 52.30KB 14.49KB
plugin-list (index.js) 113.24KB 27.66KB
plugin-map (index.js) 20.35KB 6.77KB
plugin-markdown (index.js) 13.88KB 4.80KB
plugin-report (index.js) 43.42KB 11.92KB
plugin-timeline (index.js) 29.95KB 8.67KB
plugin-tree (index.js) 9.16KB 3.18KB
plugin-view (index.js) 84.33KB 20.75KB
providers (DataSourceProvider.js) 0.75KB 0.39KB
providers (MetadataProvider.js) 1.37KB 0.59KB
providers (ThemeProvider.js) 1.90KB 0.85KB
providers (UploadProvider.js) 11.66KB 3.50KB
providers (index.js) 0.45KB 0.23KB
providers (types.js) 0.01KB 0.04KB
react-runtime (index.js) 5.62KB 2.34KB
react (LazyPluginLoader.js) 4.47KB 1.63KB
react (SchemaRenderer.js) 81.07KB 26.86KB
react (data-invalidation.js) 5.05KB 2.08KB
react (index.js) 4.63KB 2.18KB
react (schema-input.js) 2.32KB 1.24KB
react (spec-input.js) 0.20KB 0.18KB
sdui-parser (codegen.js) 5.41KB 2.34KB
sdui-parser (dashboard-widget-options.js) 3.08KB 1.30KB
sdui-parser (index.js) 4.93KB 2.24KB
sdui-parser (input-type.js) 2.84KB 1.40KB
sdui-parser (parse.js) 20.57KB 5.88KB
sdui-parser (provenance.js) 3.66KB 1.82KB
sdui-parser (types.js) 0.28KB 0.23KB
sdui-parser (validate.js) 10.35KB 3.60KB
types (ai.js) 0.20KB 0.17KB
types (api-types.js) 0.20KB 0.18KB
types (app.js) 2.87KB 1.00KB
types (base.js) 0.20KB 0.18KB
types (blocks.js) 0.20KB 0.18KB
types (complex.js) 2.74KB 1.41KB
types (crud.js) 0.20KB 0.18KB
types (dashboard-filter-alias.js) 6.23KB 2.74KB
types (data-display.js) 3.75KB 1.85KB
types (data-protocol.js) 0.20KB 0.19KB
types (data.js) 0.20KB 0.18KB
types (designer.js) 1.85KB 0.85KB
types (disclosure.js) 0.20KB 0.18KB
types (error-code.js) 1.54KB 0.88KB
types (expression.js) 0.20KB 0.18KB
types (feedback.js) 0.20KB 0.18KB
types (field-types.js) 0.20KB 0.18KB
types (form.js) 0.20KB 0.18KB
types (http-inflight.js) 8.87KB 3.73KB
types (http-retry.js) 4.32KB 2.02KB
types (icon-key-migration.js) 4.26KB 1.63KB
types (index.js) 4.74KB 2.25KB
types (layout.js) 0.20KB 0.18KB
types (managed-by.js) 0.19KB 0.18KB
types (mobile.js) 4.73KB 2.28KB
types (navigation.js) 0.20KB 0.18KB
types (objectql.js) 0.20KB 0.18KB
types (overlay.js) 0.20KB 0.18KB
types (permissions.js) 0.20KB 0.18KB
types (plugin-scope.js) 0.20KB 0.18KB
types (record-components.js) 0.20KB 0.19KB
types (record-semantics.js) 1.28KB 0.67KB
types (registry.js) 0.20KB 0.18KB
types (reports.js) 0.20KB 0.18KB
types (select-option.js) 0.20KB 0.19KB
types (spec-report.js) 5.05KB 1.93KB
types (spec-ui-namespace.js) 0.20KB 0.19KB
types (system-fields.js) 3.33KB 1.54KB
types (theme.js) 6.28KB 2.87KB
types (ui-action.js) 8.11KB 3.32KB
types (views.js) 0.20KB 0.18KB
types (widget.js) 0.20KB 0.18KB

Size Limits

  • ✅ Core packages should be < 50KB gzipped
  • ✅ Component packages should be < 100KB gzipped
  • ⚠️ Plugin packages should be < 150KB gzipped

Copy link
Copy Markdown
Contributor

Standing down on Live E2E (informational) — red on the base branch too, not this PR's. domain:devx @ objectui execution seat, PM session session_01MM7kaS4dPpYHV5BsMyu4tQ, R45, 2026-09-06T07:22Z. Same signature as main's scheduled run 34017174769 (job 101442890465): the published backend boots without its auth core (objectstack#16186); consumer-side anchor #7990. This diff is one doc example, one test file and an empty-frontmatter changeset — no backend pin, no e2e/ path. No fix to port, no re-run spent. Every other check on c7936621d is green (28 success, 3 skipped). Flipping to ready; arming after the post-flip guard completes (ACCEPT 5557665611 on #7923).


Generated by Claude Code

@baozhoutao
baozhoutao marked this pull request as ready for review September 6, 2026 07:22
@baozhoutao
baozhoutao added this pull request to the merge queue Sep 6, 2026
Merged via the queue into main with commit bac5e54 Sep 6, 2026
33 of 34 checks passed
@baozhoutao
baozhoutao deleted the claude/issue-7923-schema-reference-default-list-view branch September 6, 2026 07:39
akarma-synetal pushed a commit to akarma-synetal/objectui that referenced this pull request Sep 28, 2026
…55) (objectstack-ai#10504)

Fixes objectstack-ai#8255
Clause-②: no

The docs half of the objectui#7928 ruling (decision batch objectstack-ai#70, option
A). The renderer half, objectui#8254, landed as PR objectstack-ai#9605 and honours a
spec-shaped named view, including `columns` in either union arm and
`filter` as rule objects. This PR makes the four pages teach that shape:
the three the card names, plus the CRUD guide folded in by the seat
decision `5827390159` (patch round 1, head `9c7f893d3`).

## What changed

- `packages/plugin-view/README.md` and
`content/docs/plugins/plugin-view.mdx` (the same three examples in
each): every named view now carries `columns`, the one key
`ObjectListViewSchema` requires. The label-only `all` view in the
ObjectView overview gains `columns: ['name', 'email']` (the same list as
the snippet's `table.columns`), and its inline comment now says each
view needs `label` and `columns`. `cheap` (Read/List) gains `columns:
['name', 'price']` and `admins` (View tabs) gains `columns: ['name',
'email']`, matching their sibling views.
- `content/docs/api/schema-reference.md`, the `ObjectViewSchema`
example: both views gain `columns` (the example's own `table.columns`
list), and `my-deals` spells its filter as a spec rule object, `{
"field": "owner", "operator": "equals", "value": "{current_user_id}" }`,
instead of the ObjectQL tuple. The value is the spec's `CONTEXT_TOKENS`
spelling (patch round 1; it was an invented `${currentUser.id}` nothing
resolves), and one sentence beside the example says the host that
renders the list resolves the token, with the `object-view` node path
tracked in objectui#10506. The view is again written `label`-first. The
old order only existed to keep a pinned line byte-identical, and that
pin now reads this example differently (see below).
- `content/docs/guide/building-crud-app.md` (patch round 1):
`TaskSchema.listViews.active.filter` becomes the rule object `{ field:
'status', operator: 'not_equals', value: 'Done' }` instead of the tuple.
- `.changeset/object-view-unmirrored-keys-7779.md` (patch round 1): the
one sentence this PR falsified now reads in the past tense (the spec
refused the named views the docs taught when the entry was written;
objectui#8255 has since rewritten them). The front matter is
byte-identical.
- `scripts/markdown-test-inputs.mjs` (patch round 1): the 7779 pin's
ledger row gains the guide page in `reads`, because `--audit` refuses an
unadjudicated document the pin now resolves.
- No renderer, type or schema change.

## Validation against the installed spec

Schema: `ObjectListViewSchema` from `@objectstack/spec/ui`,
**`@objectstack/spec@17.4.0`**, resolved from `packages/types` (the
`^17.4.0` range there, `^17.0.0` in `plugin-view`, same install). This
scratch script was not committed. It finds every fenced block in the
three pages that mentions `listViews` and parses it with the TypeScript
parser (a `json` body is wrapped in an initializer). For each
`listViews` property it turns the literal into a value and runs each
entry through `ObjectListViewSchema.safeParse`.

Before (base `39395455a`), 12 entries in 7 blocks, **8 refused**:

```
REFUSE  packages/plugin-view/README.md:154 (typescript) listViews.all -> columns: invalid_union
ACCEPT  packages/plugin-view/README.md:464 (typescript) listViews.all
REFUSE  packages/plugin-view/README.md:464 (typescript) listViews.cheap -> columns: invalid_union
ACCEPT  packages/plugin-view/README.md:622 (typescript) listViews.active
REFUSE  packages/plugin-view/README.md:622 (typescript) listViews.admins -> columns: invalid_union
REFUSE  content/docs/plugins/plugin-view.mdx:72 (typescript) listViews.all -> columns: invalid_union
ACCEPT  content/docs/plugins/plugin-view.mdx:399 (typescript) listViews.all
REFUSE  content/docs/plugins/plugin-view.mdx:399 (typescript) listViews.cheap -> columns: invalid_union
ACCEPT  content/docs/plugins/plugin-view.mdx:523 (typescript) listViews.active
REFUSE  content/docs/plugins/plugin-view.mdx:523 (typescript) listViews.admins -> columns: invalid_union
REFUSE  content/docs/api/schema-reference.md:872 (json) listViews.all -> columns: invalid_union
REFUSE  content/docs/api/schema-reference.md:872 (json) listViews.my-deals -> columns: invalid_union | filter.0: invalid_type
SUMMARY listViews blocks=7 entries accepted=4 refused=8 controls=pass
```

After (this branch), **all 12 accepted, controls refused**:

```
ACCEPT  packages/plugin-view/README.md:154 (typescript) listViews.all
ACCEPT  packages/plugin-view/README.md:464 (typescript) listViews.all
ACCEPT  packages/plugin-view/README.md:464 (typescript) listViews.cheap
ACCEPT  packages/plugin-view/README.md:623 (typescript) listViews.active
ACCEPT  packages/plugin-view/README.md:623 (typescript) listViews.admins
ACCEPT  content/docs/plugins/plugin-view.mdx:72 (typescript) listViews.all
ACCEPT  content/docs/plugins/plugin-view.mdx:399 (typescript) listViews.all
ACCEPT  content/docs/plugins/plugin-view.mdx:399 (typescript) listViews.cheap
ACCEPT  content/docs/plugins/plugin-view.mdx:524 (typescript) listViews.active
ACCEPT  content/docs/plugins/plugin-view.mdx:524 (typescript) listViews.admins
ACCEPT  content/docs/api/schema-reference.md:872 (json) listViews.all
ACCEPT  content/docs/api/schema-reference.md:872 (json) listViews.my-deals
CONTROL ok  tuple filter: refused -> filter.0: invalid_type
CONTROL ok  label-only: refused -> columns: invalid_union
CONTROL ok  entry-level default: refused -> (root): unrecognized_keys ["default"]
CONTROL ok  catalog shape: accepted
SUMMARY listViews blocks=7 entries accepted=12 refused=0 controls=pass
```

Patch round 1, over four pages (the CRUD guide added). Base `39395455a`:
`SUMMARY listViews blocks=8 entries accepted=5 refused=9 controls=pass`
(the extra refusal: `content/docs/guide/building-crud-app.md:130 (ts)
listViews.active -> filter.0: invalid_type`). Head `9c7f893d3`:

```
SUMMARY listViews blocks=8 entries accepted=14 refused=0 controls=pass
```

The card named three examples. Measured, **seven blocks carried eight
refused entries**: the `cheap` and `admins` views in both the README and
the mdx were refused too (no `columns`), so all of them are rewritten.

## The pin that held the old forms, and its successor

`packages/types/src/__tests__/object-view-unmirrored-keys-7779.test.ts`
pinned the refused forms off disk as "still what the docs teach". That
was the input to the measurement keeping `listViews` ledgered. Rewriting
the docs turned it red, as designed. Before the successor was written it
failed one test out of 233 (`expected '# @object-ui/plugin-view…' to
contain 'listViews: { all: { label: 'All User…'`).

That test is replaced by its successor and is not weakened. The new test
reads every named view the four pages author off disk (three, plus the
CRUD guide from patch round 1), using the TypeScript parser, and
requires each one to parse under `ObjectListViewSchema`. It requires at
least one entry per page, so a page cannot pass vacuously. It also runs
a positive control through the same predicate: the retired label-only
and tuple forms must come back refused, and the spec shape must not. The
spec-side refusal assertions in the test before it are unchanged; only
its title and comments moved to the past tense. The file header sentence
that said the docs "teach" the refused forms is updated the same way.
The pin reads all four pages, and its `scripts/markdown-test-inputs.mjs`
ledger row names all four in `reads` (`--audit`: exit 0, `75 declared
entries, all present`).

This PR claims the pages validate. Per AGENTS.md objectstack-ai#9, that claim now
points at this pin as the instrument that re-derives it, not at the
scratch output above.

### Reverse verification (one-time, not committed)

Each leg ran through `ablation-replace.mjs`: the anchor had to hit, the
blob had to change on disk, and the restore was proven by blob == HEAD
plus an empty `git diff HEAD`.

- **Leg A**: drop `columns` from the README's `cheap` view. Predicted
red, naming that entry. Observed exit 1: `+
"packages/plugin-view/README.md:458 listViews.cheap"`. Restored, blob
`e7f0e491f2b4` == HEAD.
- **Leg B**: put the tuple filter back in `schema-reference.md`.
Predicted red naming `my-deals`, with the objectui#7923 pin still green.
Observed exit 1: `+ "content/docs/api/schema-reference.md:853
listViews.my-deals"`, `Test Files 1 failed | 1 passed (2)`. Restored,
blob `67508396a7c5` == HEAD.
- **Leg C**: set `columns: 'name'` on the README overview view, to prove
`check:doc-snippets` compiles that block. Observed exit 1:
`packages/plugin-view/README.md:154:43 TS2322: Type 'string' is not
assignable to type 'string[]'`. Restored.

- **Leg D** (patch round 1): put the tuple back in the CRUD guide.
Observed exit 1: `+ "content/docs/guide/building-crud-app.md:89
listViews.active"`, `Tests 1 failed | 228 passed (229)`. Restored: blob
`f390aef0ef41` == HEAD, `git diff HEAD` empty.

## Gates, at HEAD `9c7f893d3` (patch round 1 re-ran every gate below)

| gate | result |
|:--|:--|
| `pnpm check:doc-snippets` (after the gate's own `--build-filter`
closure, `Tasks: 35 successful, 35 total`) | exit 0: `Semantic phase:
673 of 673 block(s) judged, 0 failed.` |
| `pnpm check:doc-examples` | exit 0: `Every covered @example compiles,
or fails exactly as its ledger row declares.` No ledger row keys on
these examples (its three plugin-view rows are JSDoc blocks in the
ObjectView source) |
| `pnpm check:doc-fences` | exit 0 |
| `pnpm check:doc-types` | exit 0: `Every documented component type is
registered.` |
| `pnpm docs:check-links` | exit 0: `Links are valid across 17 scan
roots.` |
| `node scripts/check-doc-example-ids.mjs` · `pnpm check:readme-exports`
· `node scripts/check-shell-escape-residue.mjs` | exit 0 each |
| `pnpm check:control-bytes` | exit 0 |
| `pnpm check:new-line-citations` | exit 0: `0 new citation(s)` |
| `node scripts/check-changeset-presence.mjs` | exit 0. It owed a
changeset for the test file under `packages/types/src/`, answered with
the empty-frontmatter `.changeset/8255-docs-spec-shaped-list-view.md`.
The docs alone owed none |
| `node scripts/check-changeset-no-major.mjs` · `node
scripts/check-pending-changeset-literals.mjs` · `node
scripts/markdown-test-inputs.mjs --audit` | exit 0 each |
| doc-gate suites: 11 files under `scripts/__tests__/` (the
`check-doc-*` suites, `markdown-test-inputs`,
`check-pending-changeset-literals`) | exit 0: `Test Files 11 passed
(11)`, `Tests 634 passed (634)` |
| `@object-ui/types`, whole package: `pnpm exec vitest run
packages/types/` | exit 0: `Test Files 232 passed (232)`, `Tests 5156
passed (5156)` |
| `pnpm --filter @object-ui/types type-check` (includes
`tsconfig.test.json`; `--listFiles` shows the edited pin in the program,
1 hit) | exit 0 |
| `node scripts/check-governed-queue-guard.mjs --test` on the eight
paths | `NOT GOVERNED` |
| patch round 1 additions: `pnpm check:changeset-claims` (the 7779 entry
no longer flagged) · `node scripts/check-changeset-overwrite.mjs`
(report-only; 7779 front matter unchanged, `@object-ui/types: minor`) ·
the 7779 + 7923 pins and the `guideCrudAppRenders` readers in
plugin-detail and plugin-form (`Tests 249 passed (249)`) · 18
`scripts/__tests__` suites naming the edited gates (`Tests 991 passed
(991)`) | exit 0 each |

NOT MEASURED: the docs-site build (`Build Docs`), because CI owns it.
The mdx edit is inside a code fence.

## Premise check

- The card's line numbers were re-measured (see the output above).
- ⚠️ **The `default: true` half of the card's premise is already gone.**
PR objectstack-ai#7991 (objectui#7923) removed the entry-level flag and added the
node-level `defaultListView`, so it is not in this diff. The rest of the
premise held.

## Acceptance notes

- A present-tense paragraph in the **pending changeset
`.changeset/object-view-unmirrored-keys-7779.md` is falsified by this
PR**. It says the spec refuses "the named views this package's own
README and `content/docs/api/schema-reference.md` teach"
(`check:changeset-claims`, report-only, flags it). That file is outside
this claim's file surface, so it is left untouched here. It publishes
verbatim at the next release, and the open release PR objectstack-ai#5400 carries it.
⇒ **Corrected in patch round 1** (seat decision `5827390159`, option A):
the one sentence now reads in the past tense, and the front matter is
byte-identical.
- Comments that describe the docs as still teaching the refused forms:
the `listViews` ledger docblock in
`packages/types/src/zod/objectql.zod.ts` and the matching
`UnmirroredDeclared` entry comment in
`packages/types/src/__tests__/zod-mirror-parity.test.ts`. The owner is
objectui#7928's mirror flip, which rewrites both. The header of
`schema-reference-named-list-view-keys-7923.test.ts` says the filter
line is "held verbatim" by the 7779 pin and that the running dialect is
unmeasured; no carrier has been named for it. Its assertions stay green.
- `content/docs/guide/building-crud-app.md` also teaches a named view
the spec refuses: `TaskSchema.listViews.active` uses the tuple
`[['status', '!=', 'Done']]`, refused by the spec's
`ObjectSchema.listViews` at `active.filter.0`, while the rule-object
spelling parses. It was not one of this card's three pages. ⇒ **Folded
in by patch round 1** (seat decision `5827390159`): the rule-object
spelling now, and the page joins the pin.
- `my-deals` keeps its value `${currentUser.id}`, because only the
dialect was in scope. Nothing resolves that value on an `object-view`
node. `SchemaRenderer` does not evaluate `listViews` (the spec's
`expressionBindableTextKeysFor('object-view')` is empty), and
plugin-view, plugin-grid and plugin-list have zero
`resolveFilterPlaceholders` / `current_user_id` / `useFilterScope`
reads. For comparison, app-shell's `ObjectView.tsx` has 3. The spec's
context token is `{current_user_id}`. ⇒ **Patch round 1** (seat decision
`5827390159`, option B): the example now uses `{current_user_id}`, with
one sentence naming the host that resolves it; the `object-view` node
path's gap is filed as objectui#10506.

---

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

---------

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

docs(api): schema-reference.md's object-view example authors listViews.NAME.default: true, a key NamedListView never declared and ObjectView never reads

2 participants