Skip to content

Commit 33f4a19

Browse files
os-warrenclaude
andauthored
docs(types): point nine @default tags at a measured read site (objectui#8318) (#8756)
* docs(types): point nine `@default` tags at a measured read site (objectui#8318) Maintainer ruling 2026-09-09 (decision batch #104 item 4): a documentation-vs-implementation mismatch is a documentation fix. No key is retired, no renderer's behaviour moves, no zod file is touched. `DetailSchema.loading` / `DetailViewSchema.loading`: `@default true` -> `false`. `DetailView.tsx:995` reads the key as a bare disjunct beside the component's own fetch state, so an omitted key contributes nothing and draws no skeleton. The `true` came from `6f132f29` (2026-07-13), a bulk JSDoc pass copying the zod mirror's old `.default(true)`. `CardSchema.variant`, `PageNodeSchema.isDefault`, `ActionSchema.level` and the four `CRUDDialogSchema` keys lose the tag: nothing applies those values. Each docblock carries its own evidence rather than one sentence copied nine times -- which is the same defect this card is about, one level up. The pin grows from 15 rows to 24, both sides still derived off disk. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Jmxdo7bmeqCQHLSfmLVX9w * test(types): name the row in each objectui#8318 absence assertion Rows 18-20 shared one assertion title (`publishes NO @default block tag, and says why`), so an ablation report could not tell which row had reddened. The titles now carry the member. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Jmxdo7bmeqCQHLSfmLVX9w --------- Co-authored-by: Claude <noreply@anthropic.com>
1 parent e3fb3b6 commit 33f4a19

5 files changed

Lines changed: 503 additions & 38 deletions

File tree

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
---
2+
'@object-ui/types': patch
3+
---
4+
5+
Nine published `@default` JSDoc tags now describe a measured read site
6+
(objectui#8318, maintainer ruling 2026-09-09: a documentation-vs-implementation
7+
mismatch is a documentation fix — no key is retired and no renderer's behaviour
8+
moves).
9+
10+
`packages/types`' build carries JSDoc into `dist/*.d.ts`, and `dist` is in this
11+
package's `files`, so these are edits to PUBLISHED TEXT: an author reading
12+
`DetailSchema.loading` in an editor tooltip was being told the opposite of what
13+
the renderer does. No accept set, no exported symbol and no payload key changes.
14+
15+
**Two tags were wrong** — `DetailSchema.loading` and `DetailViewSchema.loading`
16+
published `@default true`, while `plugin-detail/src/DetailView.tsx:995` reads the
17+
key as a bare disjunct, `if (loading || schema.loading)`, beside the component's
18+
own fetch state. An omitted key is `undefined` and contributes nothing, so the
19+
value applied on absence is `false`. The `true` arrived in `6f132f29`
20+
(2026-07-13), a bulk JSDoc pass copying the zod mirror's old `.default(true)`;
21+
it was never an authored intent. Giving the reader the `?? true` the tag
22+
promised would draw a skeleton on every detail view that omits the key — a
23+
behaviour change, and a product question of its own that this ruling did not
24+
open.
25+
26+
**Seven tags had no reader to describe**, and they are not one fact — each
27+
docblock now carries its own evidence instead of a shared sentence:
28+
29+
- `CRUDDialogSchema.size` / `.closeOnOutsideClick` / `.closeOnEscape` /
30+
`.showClose` — there is no `register('crud-dialog'` anywhere, so no node of
31+
that type ever reaches a renderer. Recorded once on the interface. Per key,
32+
the name census differs: two spellings occur nowhere outside the declaration
33+
and its zod twin, and `showClose`'s one other occurrence
34+
(`renderers/overlay/drawer.tsx:38`) belongs to `DrawerSchema`.
35+
- `ActionSchema.level` — `type: 'action'` is not a rendered node type, and
36+
`core/src/actions/ActionRunner.ts`, which is what makes `method` / `chainMode`
37+
/ `reload` / `close` live, does not read `level`.
38+
- `CardSchema.variant` — `card` IS registered, twice, and neither registration
39+
reads it: the `ui` route forwards the key to `ui/card.tsx`, which spreads onto
40+
a `div` and mentions `variant` nowhere, and the `page` route forwards only its
41+
designer props.
42+
- `PageNodeSchema.isDefault` — `page` IS registered, and `PageRenderer` neither
43+
reads the key nor forwards it: the wrapper element gets `toDomProps(props)`,
44+
an allow-list that does not carry it.
45+
46+
Until objectui#7735 the zod mirror's `.default()` substituted these values into
47+
parsed documents, which is what the tags were describing; with that gone they
48+
described nothing that runs.
49+
50+
The pin `packages/types/src/__tests__/layout-default-jsdoc-7361.test.ts` grows
51+
from 15 rows to 24, both sides derived off disk as before.

0 commit comments

Comments
 (0)