Found while implementing #7082, which corrects the type name on these same rows. Filed rather than folded in: requiredness is a different defect class from the type name, it is the class #7073 already owns, and #7082's fence is the type name only.
Measured on origin/main2c3cd1b7572a8aca2958da3551c990164186c9c1.
The rows
| page row | shipped declaration | mirror |
|---|
content/docs/components/overlay/alert-dialog.mdx:30 — trigger:required | trigger?: SchemaNode — optional, packages/types/src/overlay.ts:91 | .optional(), zod/overlay.zod.ts:46 |
content/docs/components/overlay/sheet.mdx:26 — trigger:required | trigger?: SchemaNode — optional, overlay.ts:150 | .optional(), zod/overlay.zod.ts:65 |
content/docs/components/overlay/sheet.mdx:29 — content:required | content?: SchemaNode | SchemaNode[] — optional, overlay.ts:146 | .optional(), zod/overlay.zod.ts:64 |
All three surfaces agree with each other that these are optional; only the pages say otherwise. Both mirrors are .optional(), so a document omitting any of the three parses green today — the pages refuse what the platform accepts.
Why this is exactly #7073's class
#7073 corrected the same defect on context-menu.mdx, and its changeset states the rule it applied:
> trigger: ComponentSchema (required) | trigger?: SchemaNode | SchemaNode[] — optional at overlay.ts:486, .optional() at zod/overlay.zod.ts:191. […] a trigger-less document is legal today
That card was fenced to two pages (dropdown-menu, context-menu), so the three rows above were never in scope for it. ContextMenuSchema.trigger is now the corrected control: declared optional, published optional. These three are the remainder.
Why nothing red covers it
All three rows sit in plaintext fences. check:doc-snippets compiles ts/tsx/typescript only and check:doc-types reads only the type string literals, so no gate parses requiredness on these pages (#5250 / #5867).
They are, however, pinned as divergences by packages/types/src/__tests__/overlay-node-slot-doc-types-7082.test.ts (landing with #7082), in the requiredness divergences left to the objectui#7073 class block: it asserts the declaration is optional and the page still says required, alongside the ContextMenuSchema control. So the state is machine-recorded, and whoever fixes either side will see that file go red and be pointed here. Fixing this card means flipping those three assertions with the pages.
Fix
Mechanical, with a fixed correct form and no judgement call: spell all three trigger?: / content?:. No declaration changes; the declarations are already right.
⚠️ One caveat for whoever takes it: on alert-dialog.mdx the surrounding Schema block is diverged far more deeply than requiredness — see #7104, which may want to rewrite that whole fence rather than flip one ?. sheet.mdx has no such complication.
Refs: #7082 · #7073 · #7104 · #5250 · #5867.
Found while implementing #7082, which corrects the type name on these same rows. Filed rather than folded in: requiredness is a different defect class from the type name, it is the class #7073 already owns, and #7082's fence is the type name only.
Measured on
origin/main2c3cd1b7572a8aca2958da3551c990164186c9c1.The rows
content/docs/components/overlay/alert-dialog.mdx:30—trigger:requiredtrigger?: SchemaNode— optional,packages/types/src/overlay.ts:91.optional(),zod/overlay.zod.ts:46content/docs/components/overlay/sheet.mdx:26—trigger:requiredtrigger?: SchemaNode— optional,overlay.ts:150.optional(),zod/overlay.zod.ts:65content/docs/components/overlay/sheet.mdx:29—content:requiredcontent?: SchemaNode | SchemaNode[]— optional,overlay.ts:146.optional(),zod/overlay.zod.ts:64All three surfaces agree with each other that these are optional; only the pages say otherwise. Both mirrors are
.optional(), so a document omitting any of the three parses green today — the pages refuse what the platform accepts.Why this is exactly #7073's class
#7073 corrected the same defect on
context-menu.mdx, and its changeset states the rule it applied:>
trigger: ComponentSchema(required) |trigger?: SchemaNode | SchemaNode[]— optional atoverlay.ts:486,.optional()atzod/overlay.zod.ts:191. […] a trigger-less document is legal todayThat card was fenced to two pages (
dropdown-menu,context-menu), so the three rows above were never in scope for it.ContextMenuSchema.triggeris now the corrected control: declared optional, published optional. These three are the remainder.Why nothing red covers it
All three rows sit in
plaintextfences.check:doc-snippetscompilests/tsx/typescriptonly andcheck:doc-typesreads only thetypestring literals, so no gate parses requiredness on these pages (#5250 / #5867).They are, however, pinned as divergences by
packages/types/src/__tests__/overlay-node-slot-doc-types-7082.test.ts(landing with #7082), in therequiredness divergences left to the objectui#7073 classblock: it asserts the declaration is optional and the page still says required, alongside theContextMenuSchemacontrol. So the state is machine-recorded, and whoever fixes either side will see that file go red and be pointed here. Fixing this card means flipping those three assertions with the pages.Fix
Mechanical, with a fixed correct form and no judgement call: spell all three
trigger?:/content?:. No declaration changes; the declarations are already right.alert-dialog.mdxthe surrounding Schema block is diverged far more deeply than requiredness — see #7104, which may want to rewrite that whole fence rather than flip one?.sheet.mdxhas no such complication.Refs: #7082 · #7073 · #7104 · #5250 · #5867.