@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,4 +1,4 @@
1
- import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "remix/component/jsx-runtime";
1
+ import { jsx as _jsx, jsxs as _jsxs } from "remix/component/jsx-runtime";
2
2
  import { ChevronDownIcon, MenuIcon, XIcon } from "@sdxc/icons";
3
3
  import { keyframes } from "@sdxc/u/animation";
4
4
  import { combine, raw, mergeMix } from "@sdxc/u/general";
@@ -15,6 +15,18 @@ const CONTAINER = "ui-site-header";
15
15
  const DEFAULT_VARIANT = "bar";
16
16
  /** Breakpoint {@link SiteHeader} switches to the inline navigation at when `collapseAt` is omitted. */
17
17
  const DEFAULT_COLLAPSE_AT = "xl";
18
+ /** Accessible name of the navigation landmarks and the sheet when `navLabel` is omitted. */
19
+ const DEFAULT_NAV_LABEL = "Main";
20
+ /** What a part reads when it renders outside a {@link SiteHeader}, as in a test or a story. */
21
+ const DEFAULT_CONTEXT = {
22
+ variant: DEFAULT_VARIANT,
23
+ collapseAt: DEFAULT_COLLAPSE_AT,
24
+ navLabel: DEFAULT_NAV_LABEL,
25
+ prefetch: "none",
26
+ base: "site-header",
27
+ anchor: "--site-header-bar",
28
+ groups: { next: 0 },
29
+ };
18
30
  /** Block size of the bar; mega panels and their backdrop start right under it. */
19
31
  const BAR_HEIGHT = "4rem";
20
32
  /** Block size of the floating bar, which sits {@link FLOAT_GAP} below the viewport top. */
@@ -34,33 +46,65 @@ const FLOAT_FILL_KEYFRAMES = "ui-site-header-float-fill";
34
46
  /** Keyframes for the phone sheet's entry. */
35
47
  const SHEET_ENTER_KEYFRAMES = "ui-site-header-sheet-enter";
36
48
  /**
37
- * Renders a sticky header whose bar fills as the page scrolls under it. Groups open a
38
- * full-width panel anchored to the bar; below `collapseAt` the links, groups and actions
39
- * move into a full-screen sheet that keeps every row at least 44px tall.
49
+ * Inline padding of a mega panel's content, which its footer row cancels and restores so
50
+ * the footer's hairline spans the same measure as the columns.
51
+ */
52
+ const PANEL_GUTTER = "--ui-site-header-panel-gutter";
53
+ /**
54
+ * Parts are selected by a marker the header owns, so a caller's own `data-slot` leaves the
55
+ * layout intact.
56
+ */
57
+ const BRAND = "[data-site-header-part='brand']";
58
+ /** Selects the navigation, centered on a wide bar and the sheet's scrolling row. */
59
+ const NAV = "[data-site-header-part='nav']";
60
+ /** Selects the actions, at the bar's inline end. */
61
+ const ACTIONS = "[data-site-header-part='actions']";
62
+ /** Selects the menu button the header draws after the caller's parts. */
63
+ const MENU = "[data-site-header-part='menu']";
64
+ /** Selects a mega panel column, which the panel counts to size its tracks. */
65
+ const COLUMN = "[data-site-header-part='column']";
66
+ /** Selects a mega panel's closing row. */
67
+ const PANEL_FOOTER = "[data-site-header-part='panel-footer']";
68
+ /** Selects a panel link's glyph well. */
69
+ const LINK_ICON = "[data-site-header-part='column-link-icon']";
70
+ /** Selects a panel link's second line. */
71
+ const LINK_DESCRIPTION = "[data-site-header-part='column-link-description']";
72
+ /**
73
+ * Renders a sticky header whose bar fills as the page scrolls under it, laying out the parts
74
+ * it is given: a {@link SiteHeader.Brand} at the start, a {@link SiteHeader.Nav} centered from
75
+ * `collapseAt`, and {@link SiteHeader.Actions} at the end, followed by the menu button. Below
76
+ * `collapseAt` the same parts draw again in a full-screen sheet of rows at least 44px tall,
77
+ * so the links are written once for both surfaces. Its children are parts only, since the
78
+ * header renders them once per surface.
40
79
  *
41
80
  * @param handle Runtime handle carrying the host `<header>`'s props.
42
81
  * @returns The render function producing the header's markup.
43
82
  * @example
44
- * <SiteHeader
45
- * brand={<a href="/" aria-label="Keel home"><KeelLogo /></a>}
46
- * items={[{ label: "Pricing", href: "/pricing" }, { label: "Product", columns }]}
47
- * actions={[{ label: "Log in", href: "/login" }]}
48
- * cta={{ label: "Start free", href: "/signup" }}
49
- * />
83
+ * <SiteHeader>
84
+ * <SiteHeader.Brand><a href="/" aria-label="Keel home"><KeelLogo /></a></SiteHeader.Brand>
85
+ * <SiteHeader.Nav><SiteHeader.Link href="/pricing">Pricing</SiteHeader.Link></SiteHeader.Nav>
86
+ * <SiteHeader.Actions><SiteHeader.Action href="/signup" variant="primary">Start free</SiteHeader.Action></SiteHeader.Actions>
87
+ * </SiteHeader>
50
88
  */
51
89
  export function SiteHeader(handle) {
52
90
  return () => {
53
- let { actions, brand, closeLabel, collapseAt, cta, items, menuLabel, mix, navLabel, prefetch, sheet, tools, variant, ...rest } = handle.props;
91
+ let { children, closeLabel, collapseAt, menuLabel, mix, navLabel, prefetch, variant, ...rest } = handle.props;
54
92
  let resolvedVariant = variant ?? DEFAULT_VARIANT;
55
93
  let breakpoint = collapseAt ?? DEFAULT_COLLAPSE_AT;
56
94
  let isFloating = resolvedVariant === "floating";
57
- let resolvedItems = items ?? [];
58
- let resolvedActions = actions ?? [];
59
- let label = navLabel ?? "Main";
95
+ let label = navLabel ?? DEFAULT_NAV_LABEL;
60
96
  let base = rest.id ?? handle.id;
61
97
  let sheetId = `${base}-sheet`;
62
98
  let anchor = `--${base}-bar`;
63
- let linkPrefetch = prefetchAttribute(prefetch ?? "none");
99
+ handle.context.set({
100
+ variant: resolvedVariant,
101
+ collapseAt: breakpoint,
102
+ navLabel: label,
103
+ prefetch: prefetch ?? "none",
104
+ base,
105
+ anchor,
106
+ groups: { next: 0 },
107
+ });
64
108
  return (_jsxs("header", { ...rest, "data-slot": "site-header", "data-variant": resolvedVariant, mix: mergeMix([
65
109
  container(CONTAINER),
66
110
  raw({
@@ -71,43 +115,369 @@ export function SiteHeader(handle) {
71
115
  paddingInline: isFloating ? FLOAT_GAP : "0",
72
116
  paddingBlockStart: isFloating ? FLOAT_GAP : "0",
73
117
  }),
74
- ], mix), children: [_jsx("div", { "data-slot": "site-header-bar", style: { anchorName: anchor }, mix: [isFloating ? floatingBar() : fullBar()], children: _jsxs("div", { "data-slot": "site-header-row", mix: [row(isFloating, breakpoint)], children: [_jsx("div", { "data-slot": "site-header-brand", mix: [brandSlot()], children: brand }), resolvedItems.length > 0 ? (_jsx("nav", { "aria-label": label, "data-slot": "site-header-nav", mix: [showFrom(breakpoint, "flex")], children: _jsx("ul", { mix: [navList()], children: resolvedItems.map((item, index) => (_jsx("li", { children: isGroup(item) ? (_jsx(GroupEntry, { group: item, panelId: `${base}-panel-${index}`, anchor: anchor, floating: isFloating, prefetch: prefetch })) : (_jsx("a", { href: item.href, "aria-current": item.current ? "page" : undefined, "data-rmx-prefetch": linkPrefetch, mix: [navTrigger()], children: item.label })) }, index))) }) })) : null, _jsxs("div", { "data-slot": "site-header-end", mix: [endSlot()], children: [tools, resolvedActions.map((action, index) => (_jsx("span", { mix: [showFrom(breakpoint, "inline-flex")], children: _jsx(LinkButton, { href: action.href, variant: "ghost", color: "neutral", prefetch: prefetch, children: action.label }) }, index))), cta ? (_jsx(LinkButton, { href: cta.href, color: "brand", prefetch: prefetch, children: cta.label })) : null, _jsx("button", { type: "button", commandfor: sheetId, command: "show-modal", "aria-label": menuLabel ?? "Open menu", "aria-haspopup": "dialog", "data-slot": "site-header-menu-button", mix: [menuButton(), hideFrom(breakpoint, "inline-grid")], children: _jsx(MenuIcon, { "aria-hidden": "true" }) })] })] }) }), _jsxs("dialog", { id: sheetId, closedby: "any", "aria-label": label, "data-slot": "site-header-sheet", mix: [sheetSurface()], children: [_jsxs("div", { mix: [sheetTop()], children: [_jsx("div", { "data-slot": "site-header-brand", mix: [brandSlot()], children: brand }), _jsx("button", { type: "button", commandfor: sheetId, command: "close", "aria-label": closeLabel ?? "Close menu", mix: [menuButton(), raw({ display: "inline-grid" })], children: _jsx(XIcon, { "aria-hidden": "true" }) })] }), _jsx("nav", { "aria-label": label, "data-slot": "site-header-sheet-nav", mix: [sheetBody()], children: _jsx("ul", { mix: [raw({ listStyle: "none", margin: "0", padding: "0" })], children: resolvedItems.map((item, index) => (_jsx("li", { mix: [raw({ borderBlockEnd: "1px solid var(--ui-landing-hairline)" })], children: isGroup(item) ? (_jsx(SheetGroup, { group: item, prefetch: prefetch })) : (_jsx("a", { href: item.href, "aria-current": item.current ? "page" : undefined, "data-rmx-prefetch": linkPrefetch, mix: [sheetRow()], children: item.label })) }, index))) }) }), cta || resolvedActions.length > 0 ? (_jsxs("div", { "data-slot": "site-header-sheet-actions", mix: [sheetActions()], children: [resolvedActions.map((action, index) => (_jsx(LinkButton, { href: action.href, prefetch: prefetch, variant: "surface", color: "neutral", size: "lg", mix: [raw({ inlineSize: "100%", justifyContent: "center" })], children: action.label }, index))), cta ? (_jsx(LinkButton, { href: cta.href, prefetch: prefetch, color: "brand", size: "lg", mix: [raw({ inlineSize: "100%", justifyContent: "center" })], children: cta.label })) : null] })) : null, sheet] })] }));
118
+ ], mix), children: [_jsx("div", { "data-slot": "site-header-bar", style: { anchorName: anchor }, mix: [isFloating ? floatingBar() : fullBar()], children: _jsxs("div", { "data-slot": "site-header-row", mix: [row(isFloating, breakpoint)], children: [_jsx(SiteHeaderSurface, { surface: "bar", children: children }), _jsx("button", { type: "button", commandfor: sheetId, command: "show-modal", "aria-label": menuLabel ?? "Open menu", "aria-haspopup": "dialog", "data-slot": "site-header-menu-button", "data-site-header-part": "menu", mix: [menuButton(), hideFrom(breakpoint, "inline-grid")], children: _jsx(MenuIcon, { "aria-hidden": "true" }) })] }) }), _jsxs("dialog", { id: sheetId, closedby: "any", "aria-label": label, "data-slot": "site-header-sheet", mix: [sheetSurface()], children: [_jsxs("div", { "data-slot": "site-header-sheet-top", mix: [sheetTop()], children: [_jsx(SiteHeaderSurface, { surface: "sheet-top", children: children }), _jsx("button", { type: "button", commandfor: sheetId, command: "close", "aria-label": closeLabel ?? "Close menu", mix: [menuButton(), raw({ display: "inline-grid", marginInlineStart: "auto" })], children: _jsx(XIcon, { "aria-hidden": "true" }) })] }), _jsx(SiteHeaderSurface, { surface: "sheet", children: children })] })] }));
75
119
  };
76
120
  }
77
121
  /**
78
- * A group's trigger and the mega panel it toggles. The panel follows the trigger in the
79
- * document, so the trigger's chevron turns from `:has(+ :popover-open)` with no script.
122
+ * The home link with the logo, at the bar's start and again beside the sheet's close button.
123
+ *
124
+ * @param handle Runtime handle carrying the host `<div>`'s props.
125
+ * @returns The render function producing the brand cell.
126
+ * @example
127
+ * <SiteHeader.Brand>
128
+ * <a href="/" aria-label="Keel home"><KeelLogo /></a>
129
+ * </SiteHeader.Brand>
80
130
  */
81
- function GroupEntry(handle) {
131
+ SiteHeader.Brand = function SiteHeaderBrand(handle) {
82
132
  return () => {
83
- let { anchor, floating, group, panelId, prefetch } = handle.props;
84
- let linkPrefetch = prefetchAttribute(prefetch ?? "none");
85
- return (_jsxs(_Fragment, { children: [_jsxs("button", { type: "button", commandfor: panelId, command: "toggle-popover", "data-slot": "site-header-group-trigger", mix: [navTrigger(), groupTrigger()], children: [group.label, _jsx(ChevronDownIcon, { "aria-hidden": "true" })] }), _jsxs("div", { id: panelId, popover: "auto", "data-slot": "site-header-panel", style: { positionAnchor: anchor }, mix: [panelSurface(floating)], children: [_jsx("div", { mix: [panelGrid(group.columns.length, floating)], children: group.columns.map((column, index) => (_jsxs("div", { "data-slot": "site-header-column", children: [_jsx("p", { "data-variant": "mono", mix: [eyebrow(), raw({ marginBlockEnd: "0.75rem" })], children: column.title }), _jsx("ul", { mix: [raw({ listStyle: "none", margin: "0", padding: "0" })], children: column.links.map((link, linkIndex) => (_jsx("li", { children: _jsxs("a", { href: link.href, "aria-current": link.current ? "page" : undefined, "data-rmx-prefetch": linkPrefetch, mix: [panelLink()], children: [link.icon ? (_jsx("span", { "aria-hidden": "true", mix: [panelIcon()], children: link.icon })) : null, _jsxs("span", { mix: [raw({ display: "grid", gap: "0.125rem", minInlineSize: "0" })], children: [_jsx("span", { mix: [
86
- raw({ fontWeight: "500", color: "var(--ui-neutral-fg-emphasis)" }),
87
- ], children: link.label }), link.description ? (_jsx("span", { mix: [
88
- raw({
89
- fontSize: "0.8125rem",
90
- lineHeight: "1.25rem",
91
- color: "var(--ui-neutral-fg-muted)",
92
- }),
93
- ], children: link.description })) : null] })] }) }, linkIndex))) })] }, index))) }), group.footer ? (_jsx("div", { mix: [panelFooter(floating)], children: _jsxs("a", { href: group.footer.href, "data-rmx-prefetch": linkPrefetch, mix: [panelFooterLink()], children: [group.footer.label, _jsx("span", { "aria-hidden": "true", children: "\u2192" })] }) })) : null] })] }));
133
+ if (readSurface(handle) === "sheet")
134
+ return null;
135
+ let { mix, ...rest } = handle.props;
136
+ return (_jsx("div", { "data-slot": "site-header-brand", ...rest, "data-site-header-part": "brand", mix: mergeMix([brandSlot()], mix) }));
94
137
  };
95
- }
138
+ };
139
+ /**
140
+ * The primary navigation: an inline row of {@link SiteHeader.Link} and {@link SiteHeader.Group}
141
+ * entries centered on the bar from `collapseAt`, and the scrolling list of the phone sheet.
142
+ *
143
+ * @param handle Runtime handle carrying the host `<nav>`'s props.
144
+ * @returns The render function producing the navigation landmark.
145
+ * @example
146
+ * <SiteHeader.Nav aria-label="Site">
147
+ * <SiteHeader.Link href="/docs" aria-current="page">Docs</SiteHeader.Link>
148
+ * </SiteHeader.Nav>
149
+ */
150
+ SiteHeader.Nav = function SiteHeaderNav(handle) {
151
+ return () => {
152
+ let surface = readSurface(handle);
153
+ if (surface === "sheet-top")
154
+ return null;
155
+ let context = readContext(handle);
156
+ let { children, mix, ...rest } = handle.props;
157
+ if (surface === "sheet") {
158
+ return (_jsx("nav", { "aria-label": context.navLabel, "data-slot": "site-header-sheet-nav", ...rest, "data-site-header-part": "nav", mix: mergeMix([sheetBody()], mix), children: _jsx("ul", { mix: [raw({ listStyle: "none", margin: "0", padding: "0" })], children: children }) }));
159
+ }
160
+ return (_jsx("nav", { "aria-label": context.navLabel, "data-slot": "site-header-nav", ...rest, "data-site-header-part": "nav", mix: mergeMix([showFrom(context.collapseAt, "flex")], mix), children: _jsx("ul", { mix: [navList()], children: children }) }));
161
+ };
162
+ };
163
+ /**
164
+ * A top-level destination: a quiet link on the bar and a full 3.25rem row in the sheet.
165
+ *
166
+ * @param handle Runtime handle carrying the host `<a>`'s props.
167
+ * @returns The render function producing the list item and its link.
168
+ * @example <SiteHeader.Link href="/pricing">Pricing</SiteHeader.Link>
169
+ */
170
+ SiteHeader.Link = function SiteHeaderLink(handle) {
171
+ return () => {
172
+ let surface = readSurface(handle);
173
+ let { mix, prefetch, ...rest } = handle.props;
174
+ let linkPrefetch = prefetchAttribute(prefetch ?? readContext(handle).prefetch);
175
+ if (surface === "sheet") {
176
+ return (_jsx("li", { mix: [raw({ borderBlockEnd: "1px solid var(--ui-landing-hairline)" })], children: _jsx("a", { "data-slot": "site-header-link", "data-rmx-prefetch": linkPrefetch, ...rest, mix: mergeMix([sheetRow()], mix) }) }));
177
+ }
178
+ return (_jsx("li", { children: _jsx("a", { "data-slot": "site-header-link", "data-rmx-prefetch": linkPrefetch, ...rest, mix: mergeMix([navTrigger()], mix) }) }));
179
+ };
180
+ };
181
+ /**
182
+ * A top-level entry that opens a mega panel on the bar and a disclosure in the sheet. Write
183
+ * its {@link SiteHeader.GroupTrigger} first and its {@link SiteHeader.Panel} right after, so
184
+ * the trigger's chevron turns while the panel is open.
185
+ *
186
+ * @param handle Runtime handle carrying the host `<li>`'s props.
187
+ * @returns The render function producing the group's list item.
188
+ * @example
189
+ * <SiteHeader.Group>
190
+ * <SiteHeader.GroupTrigger>Product</SiteHeader.GroupTrigger>
191
+ * <SiteHeader.Panel>…</SiteHeader.Panel>
192
+ * </SiteHeader.Group>
193
+ */
194
+ SiteHeader.Group = function SiteHeaderGroup(handle) {
195
+ return () => {
196
+ let surface = readSurface(handle);
197
+ let { children, mix, ...rest } = handle.props;
198
+ if (surface === "sheet") {
199
+ handle.context.set({ panelId: "" });
200
+ return (_jsx("li", { ...rest, mix: mergeMix([raw({ borderBlockEnd: "1px solid var(--ui-landing-hairline)" })], mix), children: _jsx("details", { "data-slot": "site-header-sheet-group", mix: [sheetGroup()], children: children }) }));
201
+ }
202
+ let context = readContext(handle);
203
+ let index = context.groups.next;
204
+ context.groups.next += 1;
205
+ handle.context.set({ panelId: `${context.base}-panel-${index}` });
206
+ return (_jsx("li", { "data-slot": "site-header-group", ...rest, mix: mix, children: children }));
207
+ };
208
+ };
209
+ /**
210
+ * The group's label with a chevron: a button toggling the panel on the bar, and the
211
+ * disclosure's summary row in the sheet.
212
+ *
213
+ * @param handle Runtime handle carrying the host `<button>`'s props.
214
+ * @returns The render function producing the trigger.
215
+ * @example <SiteHeader.GroupTrigger>Product</SiteHeader.GroupTrigger>
216
+ */
217
+ SiteHeader.GroupTrigger = function SiteHeaderGroupTrigger(handle) {
218
+ return () => {
219
+ let { children, mix, ...rest } = handle.props;
220
+ if (readSurface(handle) === "sheet") {
221
+ return (_jsxs("summary", { "data-slot": "site-header-group-trigger", ...rest, mix: mergeMix([sheetRow(), sheetSummary()], mix), children: [children, _jsx(ChevronDownIcon, { "aria-hidden": "true" })] }));
222
+ }
223
+ return (_jsxs("button", { type: "button", commandfor: readGroup(handle).panelId, command: "toggle-popover", "data-slot": "site-header-group-trigger", ...rest, mix: mergeMix([navTrigger(), groupTrigger()], mix), children: [children, _jsx(ChevronDownIcon, { "aria-hidden": "true" })] }));
224
+ };
225
+ };
226
+ /**
227
+ * The group's mega panel: fixed under the bar at its full width, with one equal track per
228
+ * {@link SiteHeader.Column} up to four, and a {@link SiteHeader.PanelFooter} ruled off below
229
+ * them. In the sheet it is the open disclosure's body.
230
+ *
231
+ * @param handle Runtime handle carrying the host `<div>`'s props.
232
+ * @returns The render function producing the panel.
233
+ * @example
234
+ * <SiteHeader.Panel>
235
+ * <SiteHeader.Column>…</SiteHeader.Column>
236
+ * <SiteHeader.PanelFooter href="/features">Browse all features</SiteHeader.PanelFooter>
237
+ * </SiteHeader.Panel>
238
+ */
239
+ SiteHeader.Panel = function SiteHeaderPanel(handle) {
240
+ return () => {
241
+ let { children, mix, ...rest } = handle.props;
242
+ if (readSurface(handle) === "sheet") {
243
+ return (_jsx("div", { "data-slot": "site-header-sheet-panel", ...rest, mix: mergeMix([raw({ display: "grid", gap: "1.25rem", paddingBlockEnd: "1rem" })], mix), children: children }));
244
+ }
245
+ let context = readContext(handle);
246
+ let floating = context.variant === "floating";
247
+ return (_jsx("div", { id: readGroup(handle).panelId, popover: "auto", "data-slot": "site-header-panel", ...rest, style: { positionAnchor: context.anchor }, mix: mergeMix([panelSurface(floating)], mix), children: _jsx("div", { "data-slot": "site-header-panel-grid", mix: [panelGrid(floating)], children: children }) }));
248
+ };
249
+ };
250
+ /**
251
+ * A titled column of links inside a panel, or a group of rows in the sheet's disclosure.
252
+ *
253
+ * @param handle Runtime handle carrying the host `<div>`'s props.
254
+ * @returns The render function producing the column.
255
+ * @example
256
+ * <SiteHeader.Column>
257
+ * <SiteHeader.ColumnTitle>Monitor</SiteHeader.ColumnTitle>
258
+ * <SiteHeader.ColumnList>…</SiteHeader.ColumnList>
259
+ * </SiteHeader.Column>
260
+ */
261
+ SiteHeader.Column = function SiteHeaderColumn(handle) {
262
+ return () => {
263
+ let { mix, ...rest } = handle.props;
264
+ return (_jsx("div", { "data-slot": "site-header-column", ...rest, "data-site-header-part": "column", mix: mergeMix([raw({ minInlineSize: "0" })], mix) }));
265
+ };
266
+ };
96
267
  /**
97
- * A group as a disclosure in the phone sheet: the summary is a full row, and the columns
98
- * open beneath it under their eyebrows, so a long menu drills down without script.
268
+ * The column's label, set as a mono eyebrow.
269
+ *
270
+ * @param handle Runtime handle carrying the host `<p>`'s props.
271
+ * @returns The render function producing the title.
272
+ * @example <SiteHeader.ColumnTitle>Monitor</SiteHeader.ColumnTitle>
99
273
  */
100
- function SheetGroup(handle) {
274
+ SiteHeader.ColumnTitle = function SiteHeaderColumnTitle(handle) {
101
275
  return () => {
102
- let { group, prefetch } = handle.props;
103
- let links = group.footer ? [group.footer] : [];
104
- let linkPrefetch = prefetchAttribute(prefetch ?? "none");
105
- return (_jsxs("details", { "data-slot": "site-header-sheet-group", mix: [sheetGroup()], children: [_jsxs("summary", { mix: [sheetRow(), sheetSummary()], children: [group.label, _jsx(ChevronDownIcon, { "aria-hidden": "true" })] }), _jsxs("div", { mix: [raw({ display: "grid", gap: "1.25rem", paddingBlockEnd: "1rem" })], children: [group.columns.map((column, index) => (_jsxs("div", { children: [_jsx("p", { "data-variant": "mono", mix: [eyebrow(), raw({ marginBlock: "0.25rem" })], children: column.title }), _jsx("ul", { mix: [raw({ listStyle: "none", margin: "0", padding: "0" })], children: column.links.map((link, linkIndex) => (_jsx("li", { children: _jsx("a", { href: link.href, "aria-current": link.current ? "page" : undefined, "data-rmx-prefetch": linkPrefetch, mix: [sheetSubRow()], children: link.label }) }, linkIndex))) })] }, index))), links.map((link, index) => (_jsxs("a", { href: link.href, "data-rmx-prefetch": linkPrefetch, mix: [sheetSubRow(), raw({ fontWeight: "600" })], children: [link.label, " ", _jsx("span", { "aria-hidden": "true", children: "\u2192" })] }, `footer-${index}`)))] })] }));
276
+ let { mix, ...rest } = handle.props;
277
+ let spacing = readSurface(handle) === "sheet"
278
+ ? raw({ marginBlock: "0.25rem" })
279
+ : raw({ marginBlockEnd: "0.75rem" });
280
+ return (_jsx("p", { "data-variant": "mono", "data-slot": "site-header-column-title", ...rest, mix: mergeMix([eyebrow(), spacing], mix) }));
106
281
  };
282
+ };
283
+ /**
284
+ * The column's links, as an unmarked list.
285
+ *
286
+ * @param handle Runtime handle carrying the host `<ul>`'s props.
287
+ * @returns The render function producing the list.
288
+ * @example
289
+ * <SiteHeader.ColumnList>
290
+ * <SiteHeader.ColumnLink href="/uptime">Uptime</SiteHeader.ColumnLink>
291
+ * </SiteHeader.ColumnList>
292
+ */
293
+ SiteHeader.ColumnList = function SiteHeaderColumnList(handle) {
294
+ return () => {
295
+ let { mix, ...rest } = handle.props;
296
+ return (_jsx("ul", { "data-slot": "site-header-column-list", ...rest, mix: mergeMix([raw({ listStyle: "none", margin: "0", padding: "0" })], mix) }));
297
+ };
298
+ };
299
+ /**
300
+ * One destination in a column: a 44px panel row with an optional
301
+ * {@link SiteHeader.ColumnLinkIcon} written first and a
302
+ * {@link SiteHeader.ColumnLinkDescription} under the label; the sheet shows the label alone.
303
+ *
304
+ * @param handle Runtime handle carrying the host `<a>`'s props.
305
+ * @returns The render function producing the list item and its link.
306
+ * @example
307
+ * <SiteHeader.ColumnLink href="/uptime">
308
+ * <SiteHeader.ColumnLinkIcon><ActivityIcon /></SiteHeader.ColumnLinkIcon>
309
+ * Uptime
310
+ * <SiteHeader.ColumnLinkDescription>Probes from 12 regions</SiteHeader.ColumnLinkDescription>
311
+ * </SiteHeader.ColumnLink>
312
+ */
313
+ SiteHeader.ColumnLink = function SiteHeaderColumnLink(handle) {
314
+ return () => {
315
+ let { mix, prefetch, ...rest } = handle.props;
316
+ let linkPrefetch = prefetchAttribute(prefetch ?? readContext(handle).prefetch);
317
+ let sheet = readSurface(handle) === "sheet";
318
+ return (_jsx("li", { children: _jsx("a", { "data-slot": "site-header-column-link", "data-rmx-prefetch": linkPrefetch, ...rest, mix: mergeMix([sheet ? sheetSubRow() : panelLink()], mix) }) }));
319
+ };
320
+ };
321
+ /**
322
+ * A decorative glyph well beside a panel link's label; the sheet leaves it out.
323
+ *
324
+ * @param handle Runtime handle carrying the host `<span>`'s props.
325
+ * @returns The render function producing the well.
326
+ * @example <SiteHeader.ColumnLinkIcon><ActivityIcon /></SiteHeader.ColumnLinkIcon>
327
+ */
328
+ SiteHeader.ColumnLinkIcon = function SiteHeaderColumnLinkIcon(handle) {
329
+ return () => {
330
+ if (readSurface(handle) === "sheet")
331
+ return null;
332
+ let { mix, ...rest } = handle.props;
333
+ return (_jsx("span", { "aria-hidden": "true", "data-slot": "site-header-column-link-icon", ...rest, "data-site-header-part": "column-link-icon", mix: mergeMix([panelIcon()], mix) }));
334
+ };
335
+ };
336
+ /**
337
+ * One muted line under a panel link's label; the sheet leaves it out.
338
+ *
339
+ * @param handle Runtime handle carrying the host `<span>`'s props.
340
+ * @returns The render function producing the line.
341
+ * @example <SiteHeader.ColumnLinkDescription>Probes from 12 regions</SiteHeader.ColumnLinkDescription>
342
+ */
343
+ SiteHeader.ColumnLinkDescription = function SiteHeaderColumnLinkDescription(handle) {
344
+ return () => {
345
+ if (readSurface(handle) === "sheet")
346
+ return null;
347
+ let { mix, ...rest } = handle.props;
348
+ return (_jsx("span", { "data-slot": "site-header-column-link-description", ...rest, "data-site-header-part": "column-link-description", mix: mergeMix([
349
+ raw({
350
+ fontSize: "0.8125rem",
351
+ lineHeight: "1.25rem",
352
+ fontWeight: "400",
353
+ color: "var(--ui-neutral-fg-muted)",
354
+ }),
355
+ ], mix) }));
356
+ };
357
+ };
358
+ /**
359
+ * The panel's closing link under a hairline, such as "Browse all integrations", with a
360
+ * trailing arrow; in the sheet it is the disclosure's last, bold row.
361
+ *
362
+ * @param handle Runtime handle carrying the host `<a>`'s props.
363
+ * @returns The render function producing the closing row.
364
+ * @example <SiteHeader.PanelFooter href="/features">Browse all features</SiteHeader.PanelFooter>
365
+ */
366
+ SiteHeader.PanelFooter = function SiteHeaderPanelFooter(handle) {
367
+ return () => {
368
+ let { children, mix, prefetch, ...rest } = handle.props;
369
+ let linkPrefetch = prefetchAttribute(prefetch ?? readContext(handle).prefetch);
370
+ if (readSurface(handle) === "sheet") {
371
+ return (_jsxs("a", { "data-slot": "site-header-panel-footer", "data-rmx-prefetch": linkPrefetch, ...rest, mix: mergeMix([sheetSubRow(), raw({ fontWeight: "600" })], mix), children: [children, " ", _jsx("span", { "aria-hidden": "true", children: "\u2192" })] }));
372
+ }
373
+ return (_jsx("div", { "data-site-header-part": "panel-footer", mix: [panelFooter()], children: _jsxs("a", { "data-slot": "site-header-panel-footer", "data-rmx-prefetch": linkPrefetch, ...rest, mix: mergeMix([panelFooterLink()], mix), children: [children, _jsx("span", { "aria-hidden": "true", children: "\u2192" })] }) }));
374
+ };
375
+ };
376
+ /**
377
+ * The bar's trailing cell holding {@link SiteHeader.Tools} and {@link SiteHeader.Action}
378
+ * parts, end-aligned before the menu button; in the sheet, the actions stack full width at
379
+ * its foot, and a foot with no action to show leaves no row.
380
+ *
381
+ * @param handle Runtime handle carrying the host `<div>`'s props.
382
+ * @returns The render function producing the actions cell.
383
+ * @example
384
+ * <SiteHeader.Actions>
385
+ * <SiteHeader.Action href="/login">Log in</SiteHeader.Action>
386
+ * <SiteHeader.Action href="/signup" variant="primary">Start free</SiteHeader.Action>
387
+ * </SiteHeader.Actions>
388
+ */
389
+ SiteHeader.Actions = function SiteHeaderActions(handle) {
390
+ return () => {
391
+ let surface = readSurface(handle);
392
+ if (surface === "sheet-top")
393
+ return null;
394
+ let { mix, ...rest } = handle.props;
395
+ if (surface === "sheet") {
396
+ return (_jsx("div", { "data-slot": "site-header-sheet-actions", ...rest, "data-site-header-part": "actions", mix: mergeMix([sheetActions(), when("&:not(:has(> *))", raw({ display: "none" }))], mix) }));
397
+ }
398
+ return (_jsx("div", { "data-slot": "site-header-actions", ...rest, "data-site-header-part": "actions", mix: mergeMix([endSlot()], mix) }));
399
+ };
400
+ };
401
+ /**
402
+ * Controls the bar shows before its actions, such as search, a theme toggle or a repository
403
+ * link. They render on the bar alone, so a control that owns a dialog or an id draws once.
404
+ *
405
+ * @param handle Runtime handle carrying the host `<div>`'s props.
406
+ * @returns The render function producing the tools.
407
+ * @example <SiteHeader.Tools><SearchTrigger /></SiteHeader.Tools>
408
+ */
409
+ SiteHeader.Tools = function SiteHeaderTools(handle) {
410
+ return () => {
411
+ if (readSurface(handle) !== "bar")
412
+ return null;
413
+ let { mix, ...rest } = handle.props;
414
+ return (_jsx("div", { "data-slot": "site-header-tools", ...rest, mix: mergeMix([raw({ display: "flex", alignItems: "center", gap: "0.5rem", minInlineSize: "0" })], mix) }));
415
+ };
416
+ };
417
+ /**
418
+ * An account action the header sizes per surface: on the bar a `primary` action is the brand
419
+ * button at every width and a `secondary` one a ghost button from `collapseAt`; in the sheet
420
+ * both are large and full width.
421
+ *
422
+ * @param handle Runtime handle carrying the host `<a>`'s props.
423
+ * @returns The render function producing the action.
424
+ * @example <SiteHeader.Action href="/signup" variant="primary">Start free</SiteHeader.Action>
425
+ */
426
+ SiteHeader.Action = function SiteHeaderAction(handle) {
427
+ return () => {
428
+ let surface = readSurface(handle);
429
+ let context = readContext(handle);
430
+ let { mix, prefetch, variant, ...rest } = handle.props;
431
+ let primary = variant === "primary";
432
+ let resolvedPrefetch = prefetch ?? context.prefetch;
433
+ if (surface === "sheet") {
434
+ return (_jsx(LinkButton, { "data-slot": "site-header-action", ...rest, prefetch: resolvedPrefetch, variant: primary ? "solid" : "surface", color: primary ? "brand" : "neutral", size: "lg", mix: [raw({ inlineSize: "100%", justifyContent: "center" }), mix] }));
435
+ }
436
+ if (primary) {
437
+ return (_jsx(LinkButton, { "data-slot": "site-header-action", ...rest, prefetch: resolvedPrefetch, color: "brand", mix: mix }));
438
+ }
439
+ return (_jsx("span", { mix: [showFrom(context.collapseAt, "inline-flex")], children: _jsx(LinkButton, { "data-slot": "site-header-action", ...rest, prefetch: resolvedPrefetch, variant: "ghost", color: "neutral", mix: mix }) }));
440
+ };
441
+ };
442
+ /**
443
+ * What the phone sheet ends with, under its actions, such as a few secondary links or a
444
+ * client island that closes the sheet when an in-page link is followed. The bar leaves it out.
445
+ *
446
+ * @param handle Runtime handle carrying the host `<div>`'s props.
447
+ * @returns The render function producing the sheet's closing content.
448
+ * @example <SiteHeader.Sheet><DialogDismiss /></SiteHeader.Sheet>
449
+ */
450
+ SiteHeader.Sheet = function SiteHeaderSheet(handle) {
451
+ return () => {
452
+ if (readSurface(handle) !== "sheet")
453
+ return null;
454
+ return _jsx("div", { "data-slot": "site-header-sheet-extra", ...handle.props });
455
+ };
456
+ };
457
+ /**
458
+ * Tells the parts beneath it which surface they draw on, so the header can render the same
459
+ * parts in the bar and the sheet and each part picks its markup there.
460
+ */
461
+ function SiteHeaderSurface(handle) {
462
+ return () => {
463
+ handle.context.set({ surface: handle.props.surface });
464
+ return handle.props.children;
465
+ };
466
+ }
467
+ /** The surface a part draws on, the bar when it renders outside a header. */
468
+ function readSurface(handle) {
469
+ let surface = handle.context.get(SiteHeaderSurface);
470
+ return surface?.surface ?? "bar";
107
471
  }
108
- /** Whether a navigation entry opens a panel rather than navigating. */
109
- function isGroup(item) {
110
- return "columns" in item;
472
+ /** The header's resolved values, or the defaults when a part renders alone. */
473
+ function readContext(handle) {
474
+ return handle.context.get(SiteHeader) ?? DEFAULT_CONTEXT;
475
+ }
476
+ /** The enclosing group's ids, empty when a trigger or panel renders alone. */
477
+ function readGroup(handle) {
478
+ return (handle.context.get(SiteHeader.Group) ?? {
479
+ panelId: `${readContext(handle).base}-panel`,
480
+ });
111
481
  }
112
482
  /** Hides an element until the header reaches `breakpoint`, then shows it with `display`. */
113
483
  function showFrom(breakpoint, display) {
@@ -185,7 +555,9 @@ function floatingBar() {
185
555
  /**
186
556
  * The bar's row. A full bar uses the content measure, so the brand lines up with every
187
557
  * band's copy; a floating bar's padding is the gutter less its own inset, which keeps the
188
- * same alignment. From `breakpoint` the row is three tracks, so the links sit centered.
558
+ * same alignment. Below `breakpoint` the brand pushes everything after it to the end; from
559
+ * it the row is three tracks with the brand, the navigation and the actions each in its own,
560
+ * whatever order they are written in, so the links sit centered.
189
561
  */
190
562
  function row(floating, breakpoint) {
191
563
  return [
@@ -199,14 +571,19 @@ function row(floating, breakpoint) {
199
571
  raw({
200
572
  display: "flex",
201
573
  alignItems: "center",
202
- justifyContent: "space-between",
203
574
  gap: "1rem",
204
575
  blockSize: floating ? FLOAT_HEIGHT : BAR_HEIGHT,
576
+ [`& > ${BRAND}`]: { marginInlineEnd: "auto" },
577
+ [`& > ${MENU}`]: { marginInlineStart: "-0.5rem" },
205
578
  }),
206
579
  at(breakpoint, CONTAINER, raw({
207
580
  display: "grid",
208
581
  gridTemplateColumns: "1fr auto 1fr",
209
582
  gap: "2rem",
583
+ "& > *": { gridRow: "1" },
584
+ [`& > ${BRAND}`]: { gridColumn: "1" },
585
+ [`& > ${NAV}`]: { gridColumn: "2" },
586
+ [`& > ${ACTIONS}`]: { gridColumn: "3" },
210
587
  })),
211
588
  ];
212
589
  }
@@ -220,7 +597,7 @@ function brandSlot() {
220
597
  color: "var(--ui-neutral-fg-emphasis)",
221
598
  });
222
599
  }
223
- /** The trailing cell: tools, actions, the primary action and the menu button, end-aligned. */
600
+ /** The trailing cell: tools, actions and the primary action, end-aligned. */
224
601
  function endSlot() {
225
602
  return raw({
226
603
  display: "flex",
@@ -374,29 +751,53 @@ function panelSurface(floating) {
374
751
  ]);
375
752
  }
376
753
  /**
377
- * The panel's columns: as many equal tracks as the group has columns (one to four), on
378
- * the content measure, so a three-column group never leaves an empty fourth track.
754
+ * The panel's content on the content measure: one equal track per column, from one to four,
755
+ * counted from the columns written, so a three-column group never leaves an empty fourth
756
+ * track. A footer spans every track on the last row.
379
757
  */
380
- function panelGrid(count, floating) {
381
- let tracks = Math.min(Math.max(count, 1), 4);
758
+ function panelGrid(floating) {
382
759
  return [
383
- floating ? raw({ paddingInline: "1.5rem" }) : landingContainer(),
760
+ floating
761
+ ? raw({ [PANEL_GUTTER]: "1.5rem" })
762
+ : combine([
763
+ raw({ [PANEL_GUTTER]: "var(--ui-landing-gutter, 1rem)" }),
764
+ at("md", raw({ [PANEL_GUTTER]: "1.5rem" })),
765
+ at("lg", raw({ [PANEL_GUTTER]: "2rem" })),
766
+ ]),
384
767
  raw({
768
+ maxInlineSize: floating ? "none" : "var(--ui-landing-measure, 72rem)",
769
+ marginInline: "auto",
770
+ paddingInline: `var(${PANEL_GUTTER})`,
385
771
  display: "grid",
386
- gridTemplateColumns: `repeat(${tracks}, minmax(0, 1fr))`,
772
+ gridTemplateColumns: "minmax(0, 1fr)",
387
773
  columnGap: "2rem",
388
774
  rowGap: "1.5rem",
389
775
  paddingBlock: "1.75rem",
776
+ [`&:has(> :nth-child(2 of ${COLUMN}))`]: {
777
+ gridTemplateColumns: "repeat(2, minmax(0, 1fr))",
778
+ },
779
+ [`&:has(> :nth-child(3 of ${COLUMN}))`]: {
780
+ gridTemplateColumns: "repeat(3, minmax(0, 1fr))",
781
+ },
782
+ [`&:has(> :nth-child(4 of ${COLUMN}))`]: {
783
+ gridTemplateColumns: "repeat(4, minmax(0, 1fr))",
784
+ },
785
+ [`&:has(> ${PANEL_FOOTER})`]: { paddingBlockEnd: "0" },
390
786
  }),
391
787
  ];
392
788
  }
393
- /** A panel link: a 44px row with an optional glyph well, the label, and a muted line. */
789
+ /**
790
+ * A panel link: a 44px row with an optional glyph well spanning the label and its muted
791
+ * line. The label sets in the heading ink; a description sets its own size and ink.
792
+ */
394
793
  function panelLink() {
395
794
  return combine([
396
795
  raw({
397
- display: "flex",
398
- alignItems: "flex-start",
399
- gap: "0.75rem",
796
+ display: "grid",
797
+ gridTemplateColumns: "minmax(0, 1fr)",
798
+ alignItems: "start",
799
+ columnGap: "0.75rem",
800
+ rowGap: "0.125rem",
400
801
  minBlockSize: "2.75rem",
401
802
  marginInline: "-0.625rem",
402
803
  paddingBlock: "0.5rem",
@@ -404,7 +805,13 @@ function panelLink() {
404
805
  borderRadius: "0.625rem",
405
806
  fontSize: "0.9375rem",
406
807
  lineHeight: "1.375rem",
808
+ fontWeight: "500",
809
+ color: "var(--ui-neutral-fg-emphasis)",
407
810
  textDecoration: "none",
811
+ [`&:has(> ${LINK_ICON})`]: { gridTemplateColumns: "auto minmax(0, 1fr)" },
812
+ [`& > ${LINK_ICON}`]: { gridColumn: "1" },
813
+ [`&:has(> ${LINK_DESCRIPTION}) > ${LINK_ICON}`]: { gridRow: "span 2" },
814
+ [`& > ${LINK_DESCRIPTION}`]: { gridColumn: "-2" },
408
815
  }),
409
816
  hover(raw({ backgroundColor: "var(--ui-neutral-bg-tint-hover)" })),
410
817
  when("&:focus-visible", raw({
@@ -429,16 +836,21 @@ function panelIcon() {
429
836
  when("& > svg", raw({ inlineSize: "1.25rem", blockSize: "1.25rem" })),
430
837
  ]);
431
838
  }
432
- /** The panel's closing row, ruled off from the columns. */
433
- function panelFooter(floating) {
434
- return [
435
- floating ? raw({ paddingInline: "1.5rem" }) : landingContainer(),
436
- raw({
437
- display: "flex",
438
- paddingBlock: "1rem",
439
- borderBlockStart: "1px solid var(--ui-landing-hairline)",
440
- }),
441
- ];
839
+ /**
840
+ * The panel's closing row across every track, ruled off from the columns. It reaches back
841
+ * over the panel's gutter so the hairline spans the content measure, and keeps the 1.75rem
842
+ * the columns end with above the rule.
843
+ */
844
+ function panelFooter() {
845
+ return raw({
846
+ gridColumn: "1 / -1",
847
+ display: "flex",
848
+ marginBlockStart: "0.25rem",
849
+ marginInline: `calc(-1 * var(${PANEL_GUTTER}))`,
850
+ paddingInline: `var(${PANEL_GUTTER})`,
851
+ paddingBlock: "1rem",
852
+ borderBlockStart: "1px solid var(--ui-landing-hairline)",
853
+ });
442
854
  }
443
855
  /** The panel's closing link, set in the heading ink with a trailing arrow. */
444
856
  function panelFooterLink() {
@@ -457,8 +869,9 @@ function panelFooterLink() {
457
869
  }
458
870
  /**
459
871
  * The phone sheet: a modal dialog covering the viewport, opaque, with the bar repeated at
460
- * its top, a scrolling list, and the actions pinned to its foot. Its entry fades and drops
461
- * 0.5rem in 150ms when motion is allowed.
872
+ * its top, the scrolling navigation in the one stretching row, and the actions and the
873
+ * sheet's closing content after it. Its entry fades and drops 0.5rem in 150ms when motion
874
+ * is allowed.
462
875
  */
463
876
  function sheetSurface() {
464
877
  return combine([
@@ -482,7 +895,9 @@ function sheetSurface() {
482
895
  }),
483
896
  when("&[open]", raw({
484
897
  display: "grid",
485
- gridTemplateRows: "auto minmax(0, 1fr) auto",
898
+ gridTemplateRows: "auto minmax(0, 1fr)",
899
+ gridAutoRows: "auto",
900
+ [`& > ${NAV}`]: { gridRow: "2" },
486
901
  })),
487
902
  when("&::backdrop", raw({ backgroundColor: "var(--ui-bg)" })),
488
903
  motionSafe(when("&[open]", raw({