From cc607b3805ccff2b5abab1e40c06652f213b6631 Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 24 Aug 2026 21:32:57 +0000 Subject: [PATCH] docs(components): correct four props that no shipped type declares Four `content/docs/components` reference pages taught props the shipped types do not have. Each was resolved against a freshly built `packages/types/dist/*.d.ts` and against the zod schemas: - `feedback/toast.mdx` variant union -> 'default' | 'success' | 'warning' | 'error' | 'info'; 'destructive' is not a member (feedback.d.ts:123) - `form/radio-group.mdx` direction -> orientation (form.d.ts:377) - `form/combobox.mdx` drop searchPlaceholder and emptyText, declared nowhere and read by nothing (form.d.ts:1283) - `form/command.mdx` drop CommandItem.shortcut; CommandItem declares only value, label, icon (form.d.ts:1329) Every removal was checked against its renderer first, so a key a renderer genuinely reads would have been routed out as an undeclared capability rather than deleted. No type, export or union member minted. Nothing re-fenced, nothing annotated, no block changed shape: these blocks stay plaintext and stay outside the compile population. Co-Authored-By: Claude Opus 5 Claude-Session: https://claude.ai/code/session_019b5UBNMtTzKbVtZZGvFuxe --- .../6143-components-schema-corrections.md | 38 +++++++++++++++++++ content/docs/components/feedback/toast.mdx | 2 +- content/docs/components/form/combobox.mdx | 2 - content/docs/components/form/command.mdx | 1 - content/docs/components/form/radio-group.mdx | 2 +- 5 files changed, 40 insertions(+), 5 deletions(-) create mode 100644 .changeset/6143-components-schema-corrections.md diff --git a/.changeset/6143-components-schema-corrections.md b/.changeset/6143-components-schema-corrections.md new file mode 100644 index 0000000000..c23ec20ba2 --- /dev/null +++ b/.changeset/6143-components-schema-corrections.md @@ -0,0 +1,38 @@ +--- +--- + +Docs only, publishes nothing: four `content/docs/components` reference pages +taught props the shipped types do not have. Each correction was resolved +against a freshly built `packages/types/dist/*.d.ts` **and** against the zod +schemas that are the ruled enforcement boundary, so both layers agree: + +| page | documented | shipped | declaration | +| --- | --- | --- | --- | +| `feedback/toast.mdx` | `variant?: 'default' \| 'destructive'` | `variant?: 'default' \| 'success' \| 'warning' \| 'error' \| 'info'` | `feedback.d.ts:123`, `zod/feedback.zod.js:59` | +| `form/radio-group.mdx` | `direction` | `orientation?: 'horizontal' \| 'vertical'` | `form.d.ts:377`, `zod/form.zod.js:263` | +| `form/combobox.mdx` | `searchPlaceholder`, `emptyText` | neither is declared | `form.d.ts:1283`, `zod/form.zod.js:378` | +| `form/command.mdx` | `CommandItem.shortcut` | `CommandItem` declares only `value`, `label`, `icon` | `form.d.ts:1329`, `zod/form.zod.js:76` | + +`toast.mdx` is the one that mattered most: `'destructive'` is not a member of +the union, it is the Shadcn vocabulary a reader arrives with, and it is the +value most likely to be copied verbatim into an authored schema. + +Each removal was checked against the renderer before it was made, because a +key a renderer genuinely reads is an undeclared capability rather than a doc +error. None of these four is read: `renderers/form/combobox.tsx` contains +neither `searchPlaceholder` nor `emptyText`, `renderers/form/command.tsx` +contains no `shortcut`, and `renderers/feedback/toast.tsx` contains no +`'destructive'`. The same sweep's genuinely-consumed keys went to +objectui#6150 instead of being edited away. + +`emptyText` is removed from `ComboboxSchema` only. `CommandSchema` really does +declare it (`form.d.ts:1368`), so `command.mdx` keeps it. + +No type, export or union member was minted, nothing was re-fenced, and no +block changed shape — these blocks stay `plaintext` and stay outside the +compile population. `check:doc-snippets` reports the same numbers before and +after: 248 blocks to compile, 111 declared fragments, 178 covered / 44 +ungated. The import mechanism this card originally proposed is sequenced +behind objectui#5155 and is deliberately not attempted here. + +Part of objectui#6143. diff --git a/content/docs/components/feedback/toast.mdx b/content/docs/components/feedback/toast.mdx index c00c17e884..b67e1391f1 100644 --- a/content/docs/components/feedback/toast.mdx +++ b/content/docs/components/feedback/toast.mdx @@ -29,7 +29,7 @@ interface ToastSchema { type: 'toast'; title?: string; // Toast title description?: string; // Toast message - variant?: 'default' | 'destructive'; + variant?: 'default' | 'success' | 'warning' | 'error' | 'info'; // Action button action?: { diff --git a/content/docs/components/form/combobox.mdx b/content/docs/components/form/combobox.mdx index a9bf345361..e04575735a 100644 --- a/content/docs/components/form/combobox.mdx +++ b/content/docs/components/form/combobox.mdx @@ -37,8 +37,6 @@ interface ComboboxSchema { // Text placeholder?: string; // Button placeholder - searchPlaceholder?: string; // Search input placeholder - emptyText?: string; // Text when no results // Events onChange?: (value: string) => void; diff --git a/content/docs/components/form/command.mdx b/content/docs/components/form/command.mdx index f475a19e43..460f2ccc62 100644 --- a/content/docs/components/form/command.mdx +++ b/content/docs/components/form/command.mdx @@ -16,7 +16,6 @@ interface CommandItem { value: string; label: string; icon?: string; - shortcut?: string[]; } interface CommandGroup { diff --git a/content/docs/components/form/radio-group.mdx b/content/docs/components/form/radio-group.mdx index 43acc4cb4f..fabf92601b 100644 --- a/content/docs/components/form/radio-group.mdx +++ b/content/docs/components/form/radio-group.mdx @@ -44,7 +44,7 @@ interface RadioGroupSchema { value?: string; // Selected value // Layout - direction?: 'vertical' | 'horizontal'; + orientation?: 'horizontal' | 'vertical'; // Events onChange?: (value: string | number) => void;