@sdxc/ui 2026.11.26 → 2026.11.29

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (418) hide show
  1. package/README.md +265 -162
  2. package/dist/app/app-shell.d.ts +85 -50
  3. package/dist/app/app-shell.js +419 -222
  4. package/dist/app/auto-refresh.d.ts +68 -51
  5. package/dist/app/auto-refresh.js +193 -61
  6. package/dist/app/board.d.ts +40 -17
  7. package/dist/app/board.js +173 -88
  8. package/dist/app/chart.d.ts +10 -63
  9. package/dist/app/chart.js +22 -29
  10. package/dist/app/code-view.d.ts +12 -11
  11. package/dist/app/code-view.js +83 -19
  12. package/dist/app/command-palette.d.ts +61 -33
  13. package/dist/app/command-palette.js +178 -32
  14. package/dist/app/contribution-graph.d.ts +30 -14
  15. package/dist/app/contribution-graph.js +87 -26
  16. package/dist/app/danger-zone.d.ts +40 -35
  17. package/dist/app/danger-zone.js +177 -34
  18. package/dist/app/detail-sheet.d.ts +42 -51
  19. package/dist/app/detail-sheet.js +156 -37
  20. package/dist/app/diff.d.ts +6 -5
  21. package/dist/app/diff.js +9 -6
  22. package/dist/app/drop-zone.d.ts +3 -13
  23. package/dist/app/drop-zone.js +2 -2
  24. package/dist/app/editor-layout.d.ts +69 -47
  25. package/dist/app/editor-layout.js +256 -115
  26. package/dist/app/empty.d.ts +16 -12
  27. package/dist/app/empty.js +45 -19
  28. package/dist/app/file-trigger.d.ts +5 -13
  29. package/dist/app/file-trigger.js +3 -4
  30. package/dist/app/filter-bar.d.ts +182 -120
  31. package/dist/app/filter-bar.js +509 -161
  32. package/dist/app/filter-menu.d.ts +51 -33
  33. package/dist/app/filter-menu.js +105 -40
  34. package/dist/app/gantt.d.ts +67 -27
  35. package/dist/app/gantt.js +320 -163
  36. package/dist/app/grid-list.d.ts +2 -15
  37. package/dist/app/grid-list.js +3 -3
  38. package/dist/app/merge-box.d.ts +58 -52
  39. package/dist/app/merge-box.js +107 -46
  40. package/dist/app/mixins/optimistic-toggle-sync.d.ts +2 -2
  41. package/dist/app/mixins/optimistic-toggle-sync.js +3 -2
  42. package/dist/app/mixins/range-picker-keys.d.ts +1 -1
  43. package/dist/app/mixins/range-picker-keys.js +1 -1
  44. package/dist/app/mixins/save-bar-sync.d.ts +1 -1
  45. package/dist/app/mixins/save-bar-sync.js +3 -2
  46. package/dist/app/mixins/split-view.d.ts +3 -1
  47. package/dist/app/mixins/split-view.js +16 -8
  48. package/dist/app/optimistic-toggle.d.ts +65 -37
  49. package/dist/app/optimistic-toggle.js +38 -15
  50. package/dist/app/page-header.d.ts +80 -58
  51. package/dist/app/page-header.js +329 -154
  52. package/dist/app/profile-picker.d.ts +31 -24
  53. package/dist/app/profile-picker.js +134 -58
  54. package/dist/app/range-picker.d.ts +62 -59
  55. package/dist/app/range-picker.js +124 -37
  56. package/dist/app/review-thread.d.ts +69 -66
  57. package/dist/app/review-thread.js +203 -53
  58. package/dist/app/save-bar.d.ts +56 -27
  59. package/dist/app/save-bar.js +66 -14
  60. package/dist/app/selection-bar.d.ts +64 -66
  61. package/dist/app/selection-bar.js +157 -56
  62. package/dist/app/settings-layout.d.ts +65 -52
  63. package/dist/app/settings-layout.js +198 -71
  64. package/dist/app/settings-section.d.ts +86 -93
  65. package/dist/app/settings-section.js +297 -120
  66. package/dist/app/shortcut-list.d.ts +19 -8
  67. package/dist/app/shortcut-list.js +50 -9
  68. package/dist/app/sparkline.d.ts +14 -16
  69. package/dist/app/sparkline.js +20 -7
  70. package/dist/app/split-view.d.ts +66 -42
  71. package/dist/app/split-view.js +235 -128
  72. package/dist/app/stat-card.d.ts +16 -4
  73. package/dist/app/stat-card.js +57 -21
  74. package/dist/app/status-strip.d.ts +24 -25
  75. package/dist/app/status-strip.js +82 -25
  76. package/dist/app/tab-bar.d.ts +15 -7
  77. package/dist/app/tab-bar.js +74 -37
  78. package/dist/app/table.d.ts +37 -38
  79. package/dist/app/table.js +101 -45
  80. package/dist/app/view-options.d.ts +100 -76
  81. package/dist/app/view-options.js +263 -129
  82. package/dist/audio/media-tile.d.ts +33 -21
  83. package/dist/audio/media-tile.js +139 -79
  84. package/dist/audio/player-bar.d.ts +24 -43
  85. package/dist/audio/player-bar.js +183 -118
  86. package/dist/audio/queue-list.d.ts +40 -36
  87. package/dist/audio/queue-list.js +172 -73
  88. package/dist/audio/track-list.d.ts +53 -54
  89. package/dist/audio/track-list.js +127 -35
  90. package/dist/blog/archive-list.d.ts +158 -0
  91. package/dist/blog/archive-list.js +353 -0
  92. package/dist/blog/article-layout.d.ts +81 -0
  93. package/dist/blog/article-layout.js +211 -0
  94. package/dist/blog/author-card.d.ts +99 -0
  95. package/dist/blog/author-card.js +184 -0
  96. package/dist/blog/blog-masthead.d.ts +55 -0
  97. package/dist/blog/blog-masthead.js +143 -0
  98. package/dist/blog/index.d.ts +21 -0
  99. package/dist/blog/index.js +21 -0
  100. package/dist/blog/link-host.d.ts +47 -0
  101. package/dist/blog/link-host.js +61 -0
  102. package/dist/blog/newsletter-form.d.ts +66 -0
  103. package/dist/blog/newsletter-form.js +100 -0
  104. package/dist/blog/post-byline.d.ts +96 -0
  105. package/dist/blog/post-byline.js +180 -0
  106. package/dist/blog/post-entry.d.ts +153 -0
  107. package/dist/blog/post-entry.js +402 -0
  108. package/dist/blog/post-stream.d.ts +92 -0
  109. package/dist/blog/post-stream.js +163 -0
  110. package/dist/blog/series-nav.d.ts +144 -0
  111. package/dist/blog/series-nav.js +275 -0
  112. package/dist/blog/tag-cloud.d.ts +103 -0
  113. package/dist/blog/tag-cloud.js +138 -0
  114. package/dist/blog/tag-list.d.ts +91 -0
  115. package/dist/blog/tag-list.js +92 -0
  116. package/dist/blog/widget.d.ts +68 -0
  117. package/dist/blog/widget.js +61 -0
  118. package/dist/chat/activity.d.ts +47 -15
  119. package/dist/chat/activity.js +124 -46
  120. package/dist/chat/mention-menu.d.ts +6 -7
  121. package/dist/chat/mention-menu.js +4 -4
  122. package/dist/chat/message-group.d.ts +17 -4
  123. package/dist/chat/message-group.js +29 -6
  124. package/dist/color/color-field.d.ts +41 -68
  125. package/dist/color/color-field.js +21 -38
  126. package/dist/color/color-picker.d.ts +10 -61
  127. package/dist/color/color-picker.js +7 -15
  128. package/dist/color/color-swatch-picker.d.ts +0 -11
  129. package/dist/color/color-swatch-picker.js +2 -3
  130. package/dist/color/color-wheel.d.ts +3 -13
  131. package/dist/color/color-wheel.js +1 -2
  132. package/dist/commerce/cart-drawer.d.ts +41 -24
  133. package/dist/commerce/cart-drawer.js +129 -58
  134. package/dist/commerce/cart-line.d.ts +34 -19
  135. package/dist/commerce/cart-line.js +94 -28
  136. package/dist/commerce/checkout-layout.d.ts +23 -19
  137. package/dist/commerce/checkout-layout.js +53 -24
  138. package/dist/commerce/facet-filters.d.ts +57 -59
  139. package/dist/commerce/facet-filters.js +219 -129
  140. package/dist/commerce/item-options-dialog.d.ts +69 -40
  141. package/dist/commerce/item-options-dialog.js +231 -104
  142. package/dist/commerce/menu-item-card.d.ts +36 -20
  143. package/dist/commerce/menu-item-card.js +114 -61
  144. package/dist/commerce/option-group.d.ts +46 -27
  145. package/dist/commerce/option-group.js +123 -52
  146. package/dist/commerce/order-summary.d.ts +41 -26
  147. package/dist/commerce/order-summary.js +103 -49
  148. package/dist/commerce/order-tracker.d.ts +32 -16
  149. package/dist/commerce/order-tracker.js +91 -66
  150. package/dist/commerce/price.d.ts +41 -25
  151. package/dist/commerce/price.js +131 -68
  152. package/dist/commerce/product-card.d.ts +66 -36
  153. package/dist/commerce/product-card.js +215 -100
  154. package/dist/commerce/product-gallery.d.ts +72 -38
  155. package/dist/commerce/product-gallery.js +187 -82
  156. package/dist/commerce/promo-code.d.ts +73 -37
  157. package/dist/commerce/promo-code.js +172 -77
  158. package/dist/commerce/question-list.d.ts +43 -35
  159. package/dist/commerce/question-list.js +146 -72
  160. package/dist/commerce/shipping-estimate.d.ts +68 -33
  161. package/dist/commerce/shipping-estimate.js +149 -25
  162. package/dist/commerce/sort-select.d.ts +33 -22
  163. package/dist/commerce/sort-select.js +55 -26
  164. package/dist/commerce/variant-picker.d.ts +25 -23
  165. package/dist/commerce/variant-picker.js +103 -29
  166. package/dist/{docs → components}/anchor-heading.d.ts +1 -1
  167. package/dist/{docs → components}/anchor-heading.js +1 -1
  168. package/dist/components/autocomplete.d.ts +19 -21
  169. package/dist/components/autocomplete.js +57 -21
  170. package/dist/components/banner.d.ts +48 -37
  171. package/dist/components/banner.js +69 -27
  172. package/dist/components/button.d.ts +2 -18
  173. package/dist/components/button.js +4 -3
  174. package/dist/components/callout.d.ts +52 -0
  175. package/dist/components/callout.js +77 -0
  176. package/dist/components/checkbox.d.ts +3 -12
  177. package/dist/components/checkbox.js +1 -2
  178. package/dist/components/code-block.d.ts +110 -0
  179. package/dist/{docs → components}/code-block.js +92 -23
  180. package/dist/components/confirm.d.ts +63 -130
  181. package/dist/components/confirm.js +133 -52
  182. package/dist/{docs → components}/copy-button.d.ts +1 -1
  183. package/dist/{docs → components}/copy-button.js +3 -3
  184. package/dist/components/date-field.d.ts +40 -60
  185. package/dist/components/date-field.js +23 -36
  186. package/dist/components/date-picker.d.ts +11 -67
  187. package/dist/components/date-picker.js +4 -15
  188. package/dist/components/date-range-picker.d.ts +20 -91
  189. package/dist/components/date-range-picker.js +13 -27
  190. package/dist/components/dialog-dismiss.d.ts +1 -1
  191. package/dist/components/dialog-dismiss.js +1 -1
  192. package/dist/components/field-parts.d.ts +158 -0
  193. package/dist/components/field-parts.js +237 -0
  194. package/dist/components/filter-links.d.ts +107 -0
  195. package/dist/components/filter-links.js +120 -0
  196. package/dist/components/form.d.ts +3 -1
  197. package/dist/components/form.js +3 -1
  198. package/dist/components/index.d.ts +14 -7
  199. package/dist/components/index.js +14 -7
  200. package/dist/components/lightbox.js +12 -6
  201. package/dist/components/listbox.d.ts +0 -9
  202. package/dist/components/listbox.js +2 -2
  203. package/dist/components/media-grid.d.ts +15 -16
  204. package/dist/components/media-grid.js +75 -34
  205. package/dist/components/pager.d.ts +103 -0
  206. package/dist/components/pager.js +187 -0
  207. package/dist/components/property-list.d.ts +38 -39
  208. package/dist/components/property-list.js +149 -96
  209. package/dist/components/radio-group.d.ts +0 -11
  210. package/dist/components/radio-group.js +5 -6
  211. package/dist/components/range-calendar.d.ts +2 -14
  212. package/dist/components/range-calendar.js +2 -2
  213. package/dist/components/range-months.d.ts +12 -2
  214. package/dist/components/range-months.js +32 -16
  215. package/dist/components/rating-input.d.ts +14 -6
  216. package/dist/components/rating-input.js +26 -12
  217. package/dist/components/rating.d.ts +13 -8
  218. package/dist/components/rating.js +19 -5
  219. package/dist/components/review-card.d.ts +51 -26
  220. package/dist/components/review-card.js +173 -40
  221. package/dist/components/search-field.js +18 -8
  222. package/dist/components/section-bar.d.ts +23 -15
  223. package/dist/components/section-bar.js +59 -37
  224. package/dist/components/sidebar.d.ts +27 -0
  225. package/dist/components/sidebar.js +49 -20
  226. package/dist/{docs → components}/table-of-contents.d.ts +1 -1
  227. package/dist/{docs → components}/table-of-contents.js +3 -3
  228. package/dist/components/text-field.d.ts +54 -81
  229. package/dist/components/text-field.js +30 -44
  230. package/dist/components/time-field.d.ts +45 -65
  231. package/dist/components/time-field.js +23 -35
  232. package/dist/components/timeline.d.ts +80 -86
  233. package/dist/components/timeline.js +383 -170
  234. package/dist/components/typeset.d.ts +5 -0
  235. package/dist/components/typeset.js +17 -2
  236. package/dist/docs/code-tabs.d.ts +50 -24
  237. package/dist/docs/code-tabs.js +91 -25
  238. package/dist/docs/docs-feedback.d.ts +70 -27
  239. package/dist/docs/docs-feedback.js +156 -27
  240. package/dist/docs/docs-footer.d.ts +36 -22
  241. package/dist/docs/docs-footer.js +76 -23
  242. package/dist/docs/docs-hub.d.ts +103 -73
  243. package/dist/docs/docs-hub.js +333 -83
  244. package/dist/docs/docs-layout.d.ts +111 -42
  245. package/dist/docs/docs-layout.js +371 -97
  246. package/dist/docs/docs-nav-tools.d.ts +11 -7
  247. package/dist/docs/docs-nav-tools.js +4 -3
  248. package/dist/docs/docs-nav.d.ts +53 -17
  249. package/dist/docs/docs-nav.js +125 -14
  250. package/dist/docs/docs-not-found.d.ts +61 -35
  251. package/dist/docs/docs-not-found.js +198 -52
  252. package/dist/docs/docs-page-header.d.ts +47 -30
  253. package/dist/docs/docs-page-header.js +114 -31
  254. package/dist/docs/docs-pager.d.ts +43 -27
  255. package/dist/docs/docs-pager.js +73 -23
  256. package/dist/docs/file-tree.d.ts +16 -6
  257. package/dist/docs/file-tree.js +19 -4
  258. package/dist/docs/index.d.ts +0 -7
  259. package/dist/docs/index.js +0 -7
  260. package/dist/docs/install-command.d.ts +7 -6
  261. package/dist/docs/install-command.js +8 -10
  262. package/dist/docs/mixins/docs-nav-tools.js +1 -1
  263. package/dist/docs/next-steps.d.ts +56 -23
  264. package/dist/docs/next-steps.js +121 -35
  265. package/dist/docs/page-actions.d.ts +68 -46
  266. package/dist/docs/page-actions.js +129 -21
  267. package/dist/docs/steps.d.ts +14 -11
  268. package/dist/docs/steps.js +36 -18
  269. package/dist/docs/ui-label.d.ts +7 -6
  270. package/dist/docs/ui-label.js +21 -8
  271. package/dist/finance/ledger.d.ts +33 -29
  272. package/dist/finance/ledger.js +190 -43
  273. package/dist/finance/payment-card.d.ts +43 -31
  274. package/dist/finance/payment-card.js +170 -67
  275. package/dist/landing/author-band.d.ts +57 -54
  276. package/dist/landing/author-band.js +218 -64
  277. package/dist/landing/case-study.d.ts +57 -57
  278. package/dist/landing/case-study.js +148 -17
  279. package/dist/landing/changelog-strip.d.ts +56 -36
  280. package/dist/landing/changelog-strip.js +176 -68
  281. package/dist/landing/closing-cta.d.ts +21 -41
  282. package/dist/landing/closing-cta.js +13 -19
  283. package/dist/landing/code-stage.d.ts +55 -47
  284. package/dist/landing/code-stage.js +198 -67
  285. package/dist/landing/contributor-wall.d.ts +4 -4
  286. package/dist/landing/contributor-wall.js +4 -4
  287. package/dist/landing/curriculum.d.ts +74 -45
  288. package/dist/landing/curriculum.js +220 -62
  289. package/dist/landing/drawn-chart.d.ts +18 -10
  290. package/dist/landing/drawn-chart.js +57 -26
  291. package/dist/landing/episode-player.d.ts +69 -43
  292. package/dist/landing/episode-player.js +213 -48
  293. package/dist/landing/event-ticker.d.ts +13 -7
  294. package/dist/landing/event-ticker.js +67 -32
  295. package/dist/landing/fan-out-diagram.d.ts +19 -8
  296. package/dist/landing/fan-out-diagram.js +60 -19
  297. package/dist/landing/faq-band.d.ts +30 -48
  298. package/dist/landing/faq-band.js +37 -30
  299. package/dist/landing/feature-band.d.ts +48 -76
  300. package/dist/landing/feature-band.js +71 -49
  301. package/dist/landing/flow-diagram.d.ts +16 -8
  302. package/dist/landing/flow-diagram.js +50 -18
  303. package/dist/landing/install-tabs.d.ts +16 -14
  304. package/dist/landing/install-tabs.js +87 -39
  305. package/dist/landing/landing-header.d.ts +75 -66
  306. package/dist/landing/landing-header.js +284 -57
  307. package/dist/landing/landing-hero.d.ts +59 -87
  308. package/dist/landing/landing-hero.js +157 -128
  309. package/dist/landing/landing-section.d.ts +0 -9
  310. package/dist/landing/landing-section.js +1 -2
  311. package/dist/landing/logo-cloud.d.ts +26 -9
  312. package/dist/landing/logo-cloud.js +62 -18
  313. package/dist/landing/phone-fan.d.ts +15 -7
  314. package/dist/landing/phone-fan.js +60 -17
  315. package/dist/landing/price-list.d.ts +29 -22
  316. package/dist/landing/price-list.js +175 -77
  317. package/dist/landing/pricing-band.d.ts +46 -53
  318. package/dist/landing/pricing-band.js +167 -51
  319. package/dist/landing/product-frame.d.ts +44 -42
  320. package/dist/landing/product-frame.js +182 -85
  321. package/dist/landing/proof-strip.d.ts +7 -2
  322. package/dist/landing/proof-strip.js +7 -2
  323. package/dist/landing/rails.d.ts +1 -1
  324. package/dist/landing/rails.js +1 -1
  325. package/dist/landing/segmented-stage.d.ts +19 -8
  326. package/dist/landing/segmented-stage.js +60 -16
  327. package/dist/landing/sequence-diagram.d.ts +18 -8
  328. package/dist/landing/sequence-diagram.js +49 -18
  329. package/dist/landing/site-footer.d.ts +89 -68
  330. package/dist/landing/site-footer.js +344 -111
  331. package/dist/landing/site-header.d.ts +118 -80
  332. package/dist/landing/site-header.js +482 -67
  333. package/dist/landing/sponsor-wall.d.ts +34 -15
  334. package/dist/landing/sponsor-wall.js +111 -34
  335. package/dist/landing/stat-strip.d.ts +7 -9
  336. package/dist/landing/stat-strip.js +57 -22
  337. package/dist/landing/step-list.d.ts +18 -21
  338. package/dist/landing/step-list.js +132 -38
  339. package/dist/landing/tabbed-stage.d.ts +23 -15
  340. package/dist/landing/tabbed-stage.js +103 -21
  341. package/dist/landing/testimonial-band.d.ts +58 -61
  342. package/dist/landing/testimonial-band.js +209 -71
  343. package/dist/landing/typed-terminal.d.ts +9 -6
  344. package/dist/landing/typed-terminal.js +16 -5
  345. package/dist/landing/usage-estimate.d.ts +83 -74
  346. package/dist/landing/usage-estimate.js +254 -113
  347. package/dist/landing/utils/has-parts.d.ts +17 -0
  348. package/dist/landing/utils/has-parts.js +24 -0
  349. package/dist/map/map-canvas.d.ts +15 -16
  350. package/dist/map/map-canvas.js +40 -24
  351. package/dist/map/map.d.ts +42 -33
  352. package/dist/map/map.js +149 -38
  353. package/dist/mixins/aria-checked.d.ts +1 -4
  354. package/dist/mixins/aria-checked.js +1 -4
  355. package/dist/mixins/clear-field.d.ts +2 -4
  356. package/dist/mixins/clear-field.js +2 -4
  357. package/dist/mixins/index.d.ts +2 -0
  358. package/dist/mixins/index.js +2 -0
  359. package/dist/schedule/agenda.d.ts +69 -41
  360. package/dist/schedule/agenda.js +273 -134
  361. package/dist/schedule/day-strip.d.ts +38 -26
  362. package/dist/schedule/day-strip.js +119 -88
  363. package/dist/test/map.d.ts +1 -1
  364. package/dist/test/map.js +1 -6
  365. package/dist/test/reels.js +1 -1
  366. package/dist/test/stories.js +2 -2
  367. package/dist/travel/boarding-pass.d.ts +94 -70
  368. package/dist/travel/boarding-pass.js +341 -144
  369. package/dist/travel/car-offer.d.ts +109 -49
  370. package/dist/travel/car-offer.js +424 -64
  371. package/dist/travel/fare-options.d.ts +58 -34
  372. package/dist/travel/fare-options.js +210 -69
  373. package/dist/travel/flight-itinerary.d.ts +62 -55
  374. package/dist/travel/flight-itinerary.js +230 -55
  375. package/dist/travel/flight-option.d.ts +65 -33
  376. package/dist/travel/flight-option.js +250 -69
  377. package/dist/travel/flight-segment.d.ts +121 -70
  378. package/dist/travel/flight-segment.js +358 -96
  379. package/dist/travel/package-savings.d.ts +79 -39
  380. package/dist/travel/package-savings.js +309 -65
  381. package/dist/travel/price-breakdown.d.ts +30 -22
  382. package/dist/travel/price-breakdown.js +72 -17
  383. package/dist/travel/rating-breakdown.d.ts +25 -18
  384. package/dist/travel/rating-breakdown.js +60 -23
  385. package/dist/travel/seat-map.d.ts +29 -22
  386. package/dist/travel/seat-map.js +140 -78
  387. package/dist/travel/trip-timeline.d.ts +77 -39
  388. package/dist/travel/trip-timeline.js +316 -107
  389. package/dist/utils/eyebrow.d.ts +2 -2
  390. package/dist/utils/eyebrow.js +3 -3
  391. package/dist/utils/index.d.ts +0 -1
  392. package/dist/utils/index.js +0 -1
  393. package/dist/video/episode-list.d.ts +22 -14
  394. package/dist/video/episode-list.js +89 -53
  395. package/dist/video/reel-feed.d.ts +21 -15
  396. package/dist/video/reel-feed.js +59 -24
  397. package/dist/video/story-viewer.d.ts +6 -5
  398. package/dist/video/story-viewer.js +84 -53
  399. package/dist/video/title-hero.d.ts +8 -8
  400. package/dist/video/title-hero.js +48 -34
  401. package/dist/video/video-card.d.ts +34 -20
  402. package/dist/video/video-card.js +119 -76
  403. package/dist/video/video-player.d.ts +17 -14
  404. package/dist/video/video-player.js +68 -30
  405. package/dist/video/video-shelf.d.ts +26 -14
  406. package/dist/video/video-shelf.js +88 -50
  407. package/package.json +4 -2
  408. package/dist/docs/callout.d.ts +0 -46
  409. package/dist/docs/callout.js +0 -61
  410. package/dist/docs/code-block.d.ts +0 -74
  411. package/dist/utils/field-parts.d.ts +0 -26
  412. package/dist/utils/field-parts.js +0 -12
  413. /package/dist/{docs/mixins → mixins}/copy-feedback.d.ts +0 -0
  414. /package/dist/{docs/mixins → mixins}/copy-feedback.js +0 -0
  415. /package/dist/{docs/mixins → mixins}/toc-spy.d.ts +0 -0
  416. /package/dist/{docs/mixins → mixins}/toc-spy.js +0 -0
  417. /package/dist/{docs/utils → utils}/reveal-in-scroller.d.ts +0 -0
  418. /package/dist/{docs/utils → utils}/reveal-in-scroller.js +0 -0
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "remix/component/jsx-runtime";
2
2
  import { MenuIcon, XIcon } from "@sdxc/icons";
3
3
  import { bg, borderEdge, fg } from "@sdxc/u/color";
4
- import { raw } from "@sdxc/u/general";
4
+ import { mergeMix, raw } from "@sdxc/u/general";
5
5
  import { hidden, hstack, inlineFlex, insBs, shrink, sticky, vstack } from "@sdxc/u/layout";
6
6
  import { overflowY } from "@sdxc/u/overflow";
7
7
  import { media } from "@sdxc/u/responsive";
@@ -12,7 +12,7 @@ import { overflowWrap, text, weight } from "@sdxc/u/typography";
12
12
  import { Button } from "../components/button.js";
13
13
  import { DialogDismiss } from "../components/dialog-dismiss.js";
14
14
  import { Sidebar } from "../components/sidebar.js";
15
- import { TOC_MIN_ITEMS, TableOfContents } from "./table-of-contents.js";
15
+ import { TOC_MIN_ITEMS, TableOfContents } from "../components/table-of-contents.js";
16
16
  /** Width each `dock` value docks the sidebar from; narrower, it opens in the drawer. */
17
17
  const DOCK_QUERY = { md: "(min-width: 48rem)", lg: "(min-width: 64rem)" };
18
18
  /** Every width under each `dock` value, where the drawer and its button take over. */
@@ -29,24 +29,65 @@ const BAR_HEIGHT = "2.75rem";
29
29
  * which its scroll box would otherwise clip; a matching negative margin keeps it aligned.
30
30
  */
31
31
  const RING_CLEARANCE = "0.375rem";
32
+ /** The marker attribute the shell lays its columns out by. */
33
+ const PART = "data-docs-layout-part";
34
+ /** The values a part reads when no layout surrounds it. */
35
+ const DEFAULT_CONTEXT = {
36
+ toc: [],
37
+ tocMinItems: TOC_MIN_ITEMS,
38
+ outlined: false,
39
+ dock: "lg",
40
+ drawerId: "docs-drawer",
41
+ measure: "64rem",
42
+ proseMeasure: "66ch",
43
+ maxWidth: "88rem",
44
+ };
32
45
  /**
33
- * Renders the three columns and their narrow-screen fallbacks. Load
34
- * `@sdxc/ui/docs/table-of-contents` and `@sdxc/ui/dialog-dismiss` in the browser entry. Headings
35
- * with an `id` in the article get a `scroll-margin-top` that clears the sticky chrome, and
36
- * `--ui-docs-scroll-margin` carries the same offset for anything else jumped to.
46
+ * Reads the layout's context, falling back to the defaults the layout uses so a part drawn
47
+ * alone still renders.
37
48
  *
49
+ * @param handle The part's handle.
50
+ * @returns The resolved layout values.
51
+ */
52
+ function readContext(handle) {
53
+ return handle.context.get(DocsLayout) ?? DEFAULT_CONTEXT;
54
+ }
55
+ /**
56
+ * Renders the shell's outer box and the offset a jumped-to element clears, and shares the
57
+ * headings, the dock and the widths with its parts. Write `.Header`, `.Shell` and `.Drawer`
58
+ * inside it. Load `@sdxc/ui/table-of-contents` and `@sdxc/ui/dialog-dismiss` in the browser
59
+ * entry. `--ui-docs-scroll-margin` carries the offset for anything jumped to.
60
+ *
61
+ * @param handle Runtime handle carrying the shell's props and providing the context.
62
+ * @returns The render function producing the shell's outer box.
38
63
  * @example
39
- * <DocsLayout sidebar={<DocsNav tree={tree} activePath={path} />} toc={anchors} tocLabel="On this page" menuLabel="Menu" drawerLabel="Documentation" closeLabel="Close menu">
40
- * <DocsPageHeader title="Install" crumbs={crumbs} />
64
+ * <DocsLayout toc={anchors}>
65
+ * <DocsLayout.Shell>
66
+ * <DocsLayout.Sidebar><DocsNav tree={tree} activePath={path} /></DocsLayout.Sidebar>
67
+ * <DocsLayout.Content>
68
+ * <DocsLayout.Bar><DocsLayout.Menu>Menu</DocsLayout.Menu><DocsLayout.BarOutline>On this page</DocsLayout.BarOutline></DocsLayout.Bar>
69
+ * <DocsLayout.Article>{page}</DocsLayout.Article>
70
+ * </DocsLayout.Content>
71
+ * <DocsLayout.Rail><DocsLayout.Outline>On this page</DocsLayout.Outline></DocsLayout.Rail>
72
+ * </DocsLayout.Shell>
73
+ * <DocsLayout.Drawer aria-label="Documentation">…</DocsLayout.Drawer>
41
74
  * </DocsLayout>
42
75
  */
43
76
  export function DocsLayout(handle) {
44
77
  return () => {
45
- let { sidebar, children, toc = [], tocLabel, tocMinItems = TOC_MIN_ITEMS, menuLabel, drawerLabel, closeLabel, railFooter, footer, header, stickyTop = "0px", dock = "lg", measure = "64rem", proseMeasure = "66ch", maxWidth = "88rem", main = true, drawerId = "docs-drawer", } = handle.props;
78
+ let { toc = [], tocMinItems = TOC_MIN_ITEMS, stickyTop = "0px", dock = "lg", measure = "64rem", proseMeasure = "66ch", maxWidth = "88rem", drawerId = "docs-drawer", mix, ...rest } = handle.props;
46
79
  let outlined = toc.length >= tocMinItems;
47
- let docked = DOCK_QUERY[dock];
48
- let undocked = UNDOCK_QUERY[dock];
49
- return (_jsxs("div", { "data-slot": "docs-layout", mix: [
80
+ handle.context.set({
81
+ toc,
82
+ tocMinItems,
83
+ outlined,
84
+ dock,
85
+ drawerId,
86
+ measure,
87
+ proseMeasure,
88
+ maxWidth,
89
+ });
90
+ return (_jsx("div", { ...rest, "data-slot": "docs-layout", mix: mergeMix([
50
91
  raw({
51
92
  inlineSize: "100%",
52
93
  "--docs-sticky-top": stickyTop,
@@ -54,89 +95,323 @@ export function DocsLayout(handle) {
54
95
  ? `calc(${stickyTop} + ${BAR_HEIGHT} + 1rem)`
55
96
  : `calc(${stickyTop} + 1rem)`,
56
97
  }),
57
- media(undocked, raw({ "--ui-docs-scroll-margin": `calc(${stickyTop} + ${BAR_HEIGHT} + 1rem)` })),
98
+ media(UNDOCK_QUERY[dock], raw({ "--ui-docs-scroll-margin": `calc(${stickyTop} + ${BAR_HEIGHT} + 1rem)` })),
58
99
  media(RAIL_QUERY, raw({ "--ui-docs-scroll-margin": `calc(${stickyTop} + 1.5rem)` })),
59
- ], children: [header ? (_jsx("div", { "data-slot": "docs-header", mix: [sticky(), insBs(0), z(3), bg()], children: header })) : null, _jsxs("div", { "data-slot": "docs-shell", mix: [
60
- raw({
61
- "--docs-gutter": "1rem",
62
- display: "grid",
63
- gridTemplateColumns: "minmax(0, 1fr)",
64
- columnGap: "2.5rem",
65
- alignItems: "start",
66
- maxInlineSize: maxWidth,
67
- marginInline: "auto",
68
- paddingInline: "var(--docs-gutter)",
69
- }),
70
- media("(min-width: 48rem)", raw({ "--docs-gutter": "1.5rem" })),
71
- media("(min-width: 64rem)", raw({ "--docs-gutter": "2rem" })),
72
- media(docked, raw({ gridTemplateColumns: "15rem minmax(0, 1fr)" })),
73
- outlined
74
- ? media(RAIL_QUERY, raw({ gridTemplateColumns: "15rem minmax(0, 1fr) 13rem" }))
75
- : [],
76
- ], children: [_jsx("div", { "data-slot": "docs-sidebar", mix: [
77
- hidden(),
78
- media(docked, [
79
- raw({
80
- display: "block",
81
- gridRow: "1 / span 2",
82
- alignSelf: "start",
83
- boxSizing: "border-box",
84
- }),
85
- sticky(),
86
- insBs("var(--docs-sticky-top)"),
87
- bs("calc(100dvh - var(--docs-sticky-top))"),
88
- overflowY("auto"),
89
- raw({
90
- overscrollBehavior: "contain",
91
- scrollbarWidth: "thin",
92
- paddingInline: RING_CLEARANCE,
93
- marginInline: `-${RING_CLEARANCE}`,
94
- }),
95
- pbs("2rem"),
96
- pbe("3rem"),
97
- ]),
98
- ], children: sidebar }), _jsxs("div", { "data-slot": "docs-content", mix: [minIs(0), media(docked, raw({ gridRow: "1" }))], children: [_jsxs("div", { "data-slot": "docs-bar", mix: [
99
- hstack({ gap: 1, align: "center" }),
100
- sticky(),
101
- insBs("var(--docs-sticky-top)"),
102
- z(2),
103
- raw({
104
- minBlockSize: BAR_HEIGHT,
105
- marginInline: "calc(-1 * var(--docs-gutter))",
106
- paddingInline: "calc(var(--docs-gutter) - 0.5rem) var(--docs-gutter)",
107
- }),
108
- bg(),
109
- borderEdge("block-end", { color: "neutral.border", width: 1, style: "solid" }),
110
- media(docked, [
111
- raw({ marginInline: 0, paddingInline: 0 }),
112
- outlined ? [] : hidden(),
113
- ]),
114
- media(RAIL_QUERY, hidden()),
115
- ], children: [_jsx("span", { mix: [
116
- inlineFlex(),
117
- shrink(0),
118
- outlined
119
- ? raw({
120
- borderInlineEnd: "1px solid var(--ui-neutral-border)",
121
- paddingInlineEnd: "0.25rem",
122
- })
123
- : [],
124
- media(docked, hidden()),
125
- ], children: _jsxs(Button, { type: "button", variant: "ghost", color: "neutral", size: "sm", commandfor: drawerId, command: "show-modal", children: [_jsx(MenuIcon, { size: 16, "aria-hidden": "true" }), menuLabel] }) }), outlined ? (_jsx(TableOfContents, { items: toc, label: tocLabel, layout: "bar", minItems: tocMinItems })) : null] }), main ? (_jsx("main", { "data-slot": "docs-article", mix: articleMixins(measure, proseMeasure, footer), children: children })) : (_jsx("div", { "data-slot": "docs-article", mix: articleMixins(measure, proseMeasure, footer), children: children }))] }), outlined ? (_jsxs("div", { "data-slot": "docs-rail", mix: [
126
- hidden(),
127
- media(RAIL_QUERY, [
128
- raw({ gridRow: "1" }),
129
- vstack({ gap: 6 }),
130
- sticky(),
131
- insBs("var(--docs-sticky-top)"),
132
- maxBs("calc(100dvh - var(--docs-sticky-top))"),
133
- overflowY("auto"),
134
- raw({ overscrollBehavior: "contain", scrollbarWidth: "thin" }),
135
- pb("2.5rem"),
136
- ]),
137
- ], children: [_jsx(TableOfContents, { items: toc, label: tocLabel, minItems: tocMinItems }), railFooter] })) : null, footer ? (_jsx("div", { "data-slot": "docs-footer-area", mix: [minIs(0), media(docked, raw({ gridColumn: "2 / -1", gridRow: "2" }))], children: footer })) : null] }), _jsxs(Sidebar.MobileNav, { id: drawerId, "aria-label": drawerLabel, children: [_jsxs(Sidebar.Header, { children: [_jsx("span", { mix: [text("base"), weight("semibold"), fg("neutral.emphasis")], children: drawerLabel }), _jsx("span", { mix: [mis("auto")], children: _jsx(Button, { type: "button", variant: "ghost", color: "neutral", size: "sm", commandfor: drawerId, command: "close", "aria-label": closeLabel, children: _jsx(XIcon, { size: 16, "aria-hidden": "true" }) }) })] }), _jsx(Sidebar.Content, { mix: [vstack({ gap: 0 }), pb("1rem")], children: sidebar }), _jsx(DialogDismiss, {})] })] }));
100
+ ], mix) }));
138
101
  };
139
102
  }
103
+ /**
104
+ * A site header drawn above the shell, kept on screen as the page scrolls; pass its height
105
+ * as the layout's `stickyTop`.
106
+ *
107
+ * @param handle Runtime handle carrying the header box's props.
108
+ * @returns The render function producing the header box.
109
+ */
110
+ DocsLayout.Header = function DocsLayoutHeader(handle) {
111
+ return () => {
112
+ let { mix, ...rest } = handle.props;
113
+ return (_jsx("div", { ...rest, "data-slot": "docs-header", mix: mergeMix([sticky(), insBs(0), z(3), bg()], mix) }));
114
+ };
115
+ };
116
+ /**
117
+ * The centred grid of columns: a 15rem `.Sidebar` docked from the dock width, the
118
+ * `.Content` column, a 13rem `.Rail` from 75rem when the page has enough headings, and a
119
+ * `.Footer` closing the article and rail columns, never under the sidebar, so the docked
120
+ * sidebar runs to the viewport's foot. A column left out takes no room.
121
+ *
122
+ * @param handle Runtime handle carrying the grid's props.
123
+ * @returns The render function producing the grid.
124
+ */
125
+ DocsLayout.Shell = function DocsLayoutShell(handle) {
126
+ return () => {
127
+ let { mix, ...rest } = handle.props;
128
+ let { dock, maxWidth } = readContext(handle);
129
+ let docked = DOCK_QUERY[dock];
130
+ let sidebar = `[${PART}=sidebar]`;
131
+ let rail = `[${PART}=rail]`;
132
+ return (_jsx("div", { ...rest, "data-slot": "docs-shell", mix: mergeMix([
133
+ raw({
134
+ "--docs-gutter": "1rem",
135
+ display: "grid",
136
+ gridTemplateColumns: "minmax(0, 1fr)",
137
+ columnGap: "2.5rem",
138
+ alignItems: "start",
139
+ maxInlineSize: maxWidth,
140
+ marginInline: "auto",
141
+ paddingInline: "var(--docs-gutter)",
142
+ }),
143
+ when(`&:has(> [${PART}=footer])`, raw({ "--docs-article-end": "3rem" })),
144
+ media("(min-width: 48rem)", raw({ "--docs-gutter": "1.5rem" })),
145
+ media("(min-width: 64rem)", raw({ "--docs-gutter": "2rem" })),
146
+ media(docked, [
147
+ when(`&:has(> ${sidebar})`, raw({ gridTemplateColumns: "15rem minmax(0, 1fr)" })),
148
+ when(`&:has(> ${sidebar}) > [${PART}=footer]`, raw({ gridColumn: "2 / -1", gridRow: "2" })),
149
+ ]),
150
+ media(RAIL_QUERY, [
151
+ when(`&:has(> ${rail})`, raw({ gridTemplateColumns: "minmax(0, 1fr) 13rem" })),
152
+ when(`&:has(> ${sidebar}):has(> ${rail})`, raw({ gridTemplateColumns: "15rem minmax(0, 1fr) 13rem" })),
153
+ when(`&:not(:has(> ${sidebar})) > [${PART}=footer]`, raw({ gridColumn: "1 / -1" })),
154
+ ]),
155
+ ], mix) }));
156
+ };
157
+ };
158
+ /**
159
+ * The docked sidebar: hidden below the dock width, where `.Drawer` takes over, and from it
160
+ * pinned from below the sticky chrome to the viewport's foot, scrolling on its own.
161
+ *
162
+ * @param handle Runtime handle carrying the column's props.
163
+ * @returns The render function producing the column.
164
+ */
165
+ DocsLayout.Sidebar = function DocsLayoutSidebar(handle) {
166
+ return () => {
167
+ let { mix, ...rest } = handle.props;
168
+ let { dock } = readContext(handle);
169
+ return (_jsx("div", { ...rest, "data-slot": "docs-sidebar", "data-docs-layout-part": "sidebar", mix: mergeMix([
170
+ hidden(),
171
+ media(DOCK_QUERY[dock], [
172
+ raw({
173
+ display: "block",
174
+ gridRow: "1 / span 2",
175
+ alignSelf: "start",
176
+ boxSizing: "border-box",
177
+ }),
178
+ sticky(),
179
+ insBs("var(--docs-sticky-top)"),
180
+ bs("calc(100dvh - var(--docs-sticky-top))"),
181
+ overflowY("auto"),
182
+ raw({
183
+ overscrollBehavior: "contain",
184
+ scrollbarWidth: "thin",
185
+ paddingInline: RING_CLEARANCE,
186
+ marginInline: `-${RING_CLEARANCE}`,
187
+ }),
188
+ pbs("2rem"),
189
+ pbe("3rem"),
190
+ ]),
191
+ ], mix) }));
192
+ };
193
+ };
194
+ /**
195
+ * The column holding the sticky `.Bar` and the `.Article`, so the bar stays on screen for the
196
+ * whole article.
197
+ *
198
+ * @param handle Runtime handle carrying the column's props.
199
+ * @returns The render function producing the column.
200
+ */
201
+ DocsLayout.Content = function DocsLayoutContent(handle) {
202
+ return () => {
203
+ let { mix, ...rest } = handle.props;
204
+ let { dock } = readContext(handle);
205
+ return (_jsx("div", { ...rest, "data-slot": "docs-content", "data-docs-layout-part": "content", mix: mergeMix([minIs(0), media(DOCK_QUERY[dock], raw({ gridRow: "1" }))], mix) }));
206
+ };
207
+ };
208
+ /**
209
+ * The sticky bar over the article on a narrow screen, bleeding to the screen's edges: the
210
+ * `.Menu` button below the dock width and the `.BarOutline` below 75rem. Docked on a page
211
+ * without enough headings it has nothing to show and hides.
212
+ *
213
+ * @param handle Runtime handle carrying the bar's props.
214
+ * @returns The render function producing the bar.
215
+ */
216
+ DocsLayout.Bar = function DocsLayoutBar(handle) {
217
+ return () => {
218
+ let { mix, ...rest } = handle.props;
219
+ let { dock, outlined } = readContext(handle);
220
+ return (_jsx("div", { ...rest, "data-slot": "docs-bar", mix: mergeMix([
221
+ hstack({ gap: 1, align: "center" }),
222
+ sticky(),
223
+ insBs("var(--docs-sticky-top)"),
224
+ z(2),
225
+ raw({
226
+ minBlockSize: BAR_HEIGHT,
227
+ marginInline: "calc(-1 * var(--docs-gutter))",
228
+ paddingInline: "calc(var(--docs-gutter) - 0.5rem) var(--docs-gutter)",
229
+ }),
230
+ bg(),
231
+ borderEdge("block-end", { color: "neutral.border", width: 1, style: "solid" }),
232
+ media(DOCK_QUERY[dock], [
233
+ raw({ marginInline: 0, paddingInline: 0 }),
234
+ outlined ? [] : hidden(),
235
+ ]),
236
+ media(RAIL_QUERY, hidden()),
237
+ ], mix) }));
238
+ };
239
+ };
240
+ /**
241
+ * The bar's button that opens `.Drawer` below the dock width, ruled off from the headings
242
+ * after it when the page has them. Its children are the label ("Menu").
243
+ *
244
+ * @param handle Runtime handle carrying the button's props.
245
+ * @returns The render function producing the button.
246
+ * @example <DocsLayout.Menu>Menu</DocsLayout.Menu>
247
+ */
248
+ DocsLayout.Menu = function DocsLayoutMenu(handle) {
249
+ return () => {
250
+ let { children, ...rest } = handle.props;
251
+ let { dock, drawerId, outlined } = readContext(handle);
252
+ return (_jsx("span", { "data-slot": "docs-menu", mix: [
253
+ inlineFlex(),
254
+ shrink(0),
255
+ outlined
256
+ ? raw({
257
+ borderInlineEnd: "1px solid var(--ui-neutral-border)",
258
+ paddingInlineEnd: "0.25rem",
259
+ })
260
+ : [],
261
+ media(DOCK_QUERY[dock], hidden()),
262
+ ], children: _jsxs(Button, { type: "button", variant: "ghost", color: "neutral", size: "sm", commandfor: drawerId, command: "show-modal", ...rest, children: [_jsx(MenuIcon, { size: 16, "aria-hidden": "true" }), children] }) }));
263
+ };
264
+ };
265
+ /**
266
+ * The page's headings as the bar's jump list, marking the one being read; it draws nothing
267
+ * when the page has too few headings. The children name it, such as "On this page".
268
+ *
269
+ * @param handle Runtime handle carrying the list's props.
270
+ * @returns The render function producing the list.
271
+ */
272
+ DocsLayout.BarOutline = function DocsLayoutBarOutline(handle) {
273
+ return () => {
274
+ let { children } = handle.props;
275
+ let { outlined, toc, tocMinItems } = readContext(handle);
276
+ if (!outlined)
277
+ return null;
278
+ return _jsx(TableOfContents, { items: toc, label: children, layout: "bar", minItems: tocMinItems });
279
+ };
280
+ };
281
+ /**
282
+ * The article: running text at the prose measure while code, images, tables and charts fill
283
+ * the column, long words broken, wide code or tables scrolled inside their own box, and
284
+ * headings with an `id` stopping clear of the sticky chrome.
285
+ *
286
+ * @param handle Runtime handle carrying the article's props.
287
+ * @returns The render function producing the article.
288
+ */
289
+ DocsLayout.Article = function DocsLayoutArticle(handle) {
290
+ return () => {
291
+ let { main = true, mix, ...rest } = handle.props;
292
+ let { measure, proseMeasure } = readContext(handle);
293
+ let mixins = mergeMix(articleMixins(measure, proseMeasure), mix);
294
+ return main ? (_jsx("main", { ...rest, "data-slot": "docs-article", mix: mixins })) : (_jsx("div", { ...rest, "data-slot": "docs-article", mix: mixins }));
295
+ };
296
+ };
297
+ /**
298
+ * The heading rail beside the article from 75rem, sticky below the chrome and scrolling on
299
+ * its own, stacking what it holds 1.5rem apart. It draws nothing on a page with too few
300
+ * headings, so the shell keeps two columns.
301
+ *
302
+ * @param handle Runtime handle carrying the rail's props.
303
+ * @returns The render function producing the rail.
304
+ */
305
+ DocsLayout.Rail = function DocsLayoutRail(handle) {
306
+ return () => {
307
+ let { mix, ...rest } = handle.props;
308
+ let { outlined } = readContext(handle);
309
+ if (!outlined)
310
+ return null;
311
+ return (_jsx("div", { ...rest, "data-slot": "docs-rail", "data-docs-layout-part": "rail", mix: mergeMix([
312
+ hidden(),
313
+ media(RAIL_QUERY, [
314
+ raw({ gridRow: "1" }),
315
+ vstack({ gap: 6 }),
316
+ sticky(),
317
+ insBs("var(--docs-sticky-top)"),
318
+ maxBs("calc(100dvh - var(--docs-sticky-top))"),
319
+ overflowY("auto"),
320
+ raw({ overscrollBehavior: "contain", scrollbarWidth: "thin" }),
321
+ pb("2.5rem"),
322
+ ]),
323
+ ], mix) }));
324
+ };
325
+ };
326
+ /**
327
+ * The page's headings as the rail's list, marking the one being read. The children name it,
328
+ * such as "On this page".
329
+ *
330
+ * @param handle Runtime handle carrying the list's props.
331
+ * @returns The render function producing the list.
332
+ */
333
+ DocsLayout.Outline = function DocsLayoutOutline(handle) {
334
+ return () => {
335
+ let { children } = handle.props;
336
+ let { outlined, toc, tocMinItems } = readContext(handle);
337
+ if (!outlined)
338
+ return null;
339
+ return _jsx(TableOfContents, { items: toc, label: children, minItems: tocMinItems });
340
+ };
341
+ };
342
+ /**
343
+ * What closes the page, usually a `DocsFooter`, across the article and rail columns and
344
+ * never under the docked sidebar.
345
+ *
346
+ * @param handle Runtime handle carrying the area's props.
347
+ * @returns The render function producing the area.
348
+ */
349
+ DocsLayout.Footer = function DocsLayoutFooter(handle) {
350
+ return () => {
351
+ let { mix, ...rest } = handle.props;
352
+ return (_jsx("div", { ...rest, "data-slot": "docs-footer-area", "data-docs-layout-part": "footer", mix: mergeMix([minIs(0)], mix) }));
353
+ };
354
+ };
355
+ /**
356
+ * The drawer the sidebar opens in below the dock width, a modal that closes on a click
357
+ * outside it. Write the tree again inside its `.DrawerContent`.
358
+ *
359
+ * @param handle Runtime handle carrying the drawer's props.
360
+ * @returns The render function producing the drawer.
361
+ */
362
+ DocsLayout.Drawer = function DocsLayoutDrawer(handle) {
363
+ return () => {
364
+ let { children, id, ...rest } = handle.props;
365
+ let { drawerId } = readContext(handle);
366
+ return (_jsxs(Sidebar.MobileNav, { ...rest, id: id ?? drawerId, "data-slot": "docs-drawer", children: [children, _jsx(DialogDismiss, {})] }));
367
+ };
368
+ };
369
+ /**
370
+ * The drawer's top row: its title, then its close button pushed to the end.
371
+ *
372
+ * @param handle Runtime handle carrying the row's props.
373
+ * @returns The render function producing the row.
374
+ */
375
+ DocsLayout.DrawerHeader = function DocsLayoutDrawerHeader(handle) {
376
+ return () => _jsx(Sidebar.Header, { ...handle.props, "data-slot": "docs-drawer-header" });
377
+ };
378
+ /**
379
+ * The drawer's heading, matching its accessible name ("Documentation").
380
+ *
381
+ * @param handle Runtime handle carrying the span's props.
382
+ * @returns The render function producing the heading.
383
+ */
384
+ DocsLayout.DrawerTitle = function DocsLayoutDrawerTitle(handle) {
385
+ return () => {
386
+ let { mix, ...rest } = handle.props;
387
+ return (_jsx("span", { ...rest, "data-slot": "docs-drawer-title", mix: mergeMix([text("base"), weight("semibold"), fg("neutral.emphasis")], mix) }));
388
+ };
389
+ };
390
+ /**
391
+ * The button that closes the drawer, at the end of its top row.
392
+ *
393
+ * @param handle Runtime handle carrying the button's props.
394
+ * @returns The render function producing the button.
395
+ * @example <DocsLayout.DrawerClose aria-label="Close menu" />
396
+ */
397
+ DocsLayout.DrawerClose = function DocsLayoutDrawerClose(handle) {
398
+ return () => {
399
+ let { drawerId } = readContext(handle);
400
+ return (_jsx("span", { "data-slot": "docs-drawer-close", mix: [mis("auto")], children: _jsx(Button, { type: "button", variant: "ghost", color: "neutral", size: "sm", commandfor: drawerId, command: "close", ...handle.props, children: _jsx(XIcon, { size: 16, "aria-hidden": "true" }) }) }));
401
+ };
402
+ };
403
+ /**
404
+ * The drawer's scrolling body, holding the tree.
405
+ *
406
+ * @param handle Runtime handle carrying the body's props.
407
+ * @returns The render function producing the body.
408
+ */
409
+ DocsLayout.DrawerContent = function DocsLayoutDrawerContent(handle) {
410
+ return () => {
411
+ let { mix, ...rest } = handle.props;
412
+ return (_jsx(Sidebar.Content, { ...rest, "data-slot": "docs-drawer-content", mix: mergeMix([vstack({ gap: 0 }), pb("1rem")], mix) }));
413
+ };
414
+ };
140
415
  /**
141
416
  * Running text in the article that stops at the prose measure. Elements a component draws
142
417
  * (`data-slot`) keep their own width unless listed, so a code block, file tree or props
@@ -147,17 +422,16 @@ const PROSE_SELECTOR = [
147
422
  '& :where([data-slot="anchor-heading"], [data-slot="callout"], [data-slot="docs-page-header"])',
148
423
  ].join(", ");
149
424
  /**
150
- * The article column: running text at a reading measure while code, images, tables and
151
- * charts fill the column, long words broken, wide code or tables scrolled inside their own
152
- * box, and headings that stop clear of the sticky chrome.
425
+ * The article column's mixins. Its end padding is 3rem when the shell has a footer after it
426
+ * and 5rem otherwise, read from the shell's `--docs-article-end`.
153
427
  */
154
- function articleMixins(measure, proseMeasure, footer) {
428
+ function articleMixins(measure, proseMeasure) {
155
429
  return [
156
430
  raw({ maxInlineSize: measure, "--ui-docs-prose-measure": proseMeasure }),
157
431
  when(PROSE_SELECTOR, raw({ maxInlineSize: "var(--ui-docs-prose-measure)" })),
158
432
  overflowWrap("break-word"),
159
433
  pbs("2rem"),
160
- pbe(footer ? "3rem" : "5rem"),
434
+ pbe("var(--docs-article-end, 5rem)"),
161
435
  media("(min-width: 48rem)", pbs("2.5rem")),
162
436
  when("& :is(h2, h3, h4, h5, h6)[id]", raw({ scrollMarginBlockStart: "var(--ui-docs-scroll-margin)" })),
163
437
  when("& :is(pre, table)", raw({ maxInlineSize: "100%", overflowX: "auto" })),
@@ -12,20 +12,24 @@ export declare namespace DocsNavTools {
12
12
  /** Plain data only, since the props cross into the browser with the island. */
13
13
  type Props = {
14
14
  /**
15
- * The title filter's accessible name, placeholder, the query parameter it submits as
16
- * and the query the page was rendered for; unset draws no field.
15
+ * The title filter's field: its id and the id of the label naming it, the query
16
+ * parameter it submits as, its placeholder and the query the page was rendered for.
17
+ * Unset, the island draws no field and its form stays hidden, revealing the current
18
+ * page only.
17
19
  */
18
- filter?: {
19
- label: string;
20
- placeholder: string;
20
+ field?: {
21
+ inputId: string;
22
+ labelId: string;
21
23
  name: string;
22
- query: string;
24
+ placeholder?: string;
25
+ defaultValue: string;
23
26
  };
24
27
  };
25
28
  }
26
29
  /**
27
30
  * Renders the filter field inside a `GET` form on the current address, so before or without
28
- * script, Enter reloads the page filtered by the server. `DocsNav` places it; load
31
+ * script, Enter reloads the page filtered by the server. `DocsNav` and `DocsNav.FilterInput`
32
+ * place it; load
29
33
  * `@sdxc/ui/docs/docs-nav-tools` in the browser entry to filter as the reader types.
30
34
  */
31
35
  export declare const DocsNavTools: EntryComponent<DocsNavTools.Props>;
@@ -4,12 +4,13 @@ import { SearchField } from "../components/search-field.js";
4
4
  import { docsNavTools } from "./mixins/docs-nav-tools.js";
5
5
  /**
6
6
  * Renders the filter field inside a `GET` form on the current address, so before or without
7
- * script, Enter reloads the page filtered by the server. `DocsNav` places it; load
7
+ * script, Enter reloads the page filtered by the server. `DocsNav` and `DocsNav.FilterInput`
8
+ * place it; load
8
9
  * `@sdxc/ui/docs/docs-nav-tools` in the browser entry to filter as the reader types.
9
10
  */
10
11
  export const DocsNavTools = clientEntry("@sdxc/ui/docs/docs-nav-tools#DocsNavTools", function DocsNavTools(handle) {
11
12
  return () => {
12
- let { filter } = handle.props;
13
- return (_jsx("form", { method: "get", mix: [docsNavTools()], children: filter ? (_jsx(SearchField, { "aria-label": filter.label, children: _jsx(SearchField.Input, { name: filter.name, defaultValue: filter.query, placeholder: filter.placeholder, autocomplete: "off" }) })) : null }));
13
+ let { field } = handle.props;
14
+ return (_jsx("form", { method: "get", hidden: field ? undefined : true, mix: [docsNavTools()], children: field ? (_jsx(SearchField, { "aria-labelledby": field.labelId, children: _jsx(SearchField.Input, { id: field.inputId, name: field.name, defaultValue: field.defaultValue, placeholder: field.placeholder, autocomplete: "off" }) })) : null }));
14
15
  };
15
16
  });