Commit 0d89da5
committed
docs(ui): correct the navigation item type count and document
The app shell doc claimed eight navigation item types and enumerated eight,
omitting `separator` — the schema has declared nine since the inverse-drift
fix (#1878/#1891/#1894) that added it to match the objectui renderer's
`item.type === 'separator'` branch.
The gap matters more now that this PR discriminates the union on `type`: a
mistyped `type` reports the valid discriminator list, so the doc's enumeration
is the thing authors check it against. And `SeparatorNavItemSchema` is
`.strict()` over only `type`/`id`/`order` — it does not spread
`BaseNavItemSchema` — so `label`/`icon`/`badge`/`visible`/`requiredPermissions`
on a separator are now hard errors where they used to be silently stripped.
The "all navigation items share these base properties" table was the exact
sentence that would send an author into that error, so it now names the
exception.
Both claims asserted against the live schema before writing: the union has
nine members, and a separator accepts type/id/order while rejecting each of
the five base props.
Refs #4001
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0147tNF4Snk7Ry1KGt4a5PY4separator
1 parent 74d3e57 commit 0d89da5
1 file changed
Lines changed: 16 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
57 | 57 | | |
58 | 58 | | |
59 | 59 | | |
60 | | - | |
| 60 | + | |
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
| |||
121 | 121 | | |
122 | 122 | | |
123 | 123 | | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
124 | 134 | | |
125 | 135 | | |
126 | | - | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
127 | 141 | | |
128 | 142 | | |
129 | 143 | | |
| |||
0 commit comments