@ngrok/mantle 0.94.0 → 0.95.0

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 (615) hide show
  1. package/README.md +11 -2
  2. package/dist/CaretDown-MgTrjdYK.js +1 -0
  3. package/dist/CaretLeft-CZIqCyEF.js +1 -0
  4. package/dist/CaretRight-BKz4JHCI.js +1 -0
  5. package/dist/Check-C5a1hX4x.js +1 -0
  6. package/dist/CheckCircle-Bi4tSau6.js +1 -0
  7. package/dist/CircleNotch-BKE0NAIr.js +1 -0
  8. package/dist/Copy-BYWMO6PW.js +1 -0
  9. package/dist/Desktop-BaSlSeg2.js +1 -0
  10. package/dist/Eye-C38LQkZ_.js +1 -0
  11. package/dist/EyeClosed-BvOq-W8o.js +1 -0
  12. package/dist/FileText-CqAezJDn.js +1 -0
  13. package/dist/Info-weHV1B4q.js +1 -0
  14. package/dist/MagnifyingGlass-DCAoDH5_.js +1 -0
  15. package/dist/Megaphone-Cir2KHXa.js +1 -0
  16. package/dist/Minus-KBzmC4_K.js +1 -0
  17. package/dist/Moon-hn_oivM6.js +1 -0
  18. package/dist/Plus-D90-H9Ei.js +1 -0
  19. package/dist/Question-BhvEyO0K.js +1 -0
  20. package/dist/SidebarSimple-BXKgNz4l.js +1 -0
  21. package/dist/SortAscending-CEk4rgu_.js +1 -0
  22. package/dist/SortDescending-C0cE7hpU.js +1 -0
  23. package/dist/Sun-C3SaXdLl.js +1 -0
  24. package/dist/Terminal-aKZ6Y9Lk.js +1 -0
  25. package/dist/Warning-DTwF27_O.js +1 -0
  26. package/dist/WarningDiamond-BwpdVJ34.js +1 -0
  27. package/dist/X-BPGjP4b6.js +1 -0
  28. package/dist/accordion-BmDXs1-q.js +1 -0
  29. package/dist/accordion-NpJz3Uer.js +1 -0
  30. package/dist/accordion-parts.d.ts +268 -0
  31. package/dist/accordion-parts.js +1 -0
  32. package/dist/accordion.d.ts +8 -359
  33. package/dist/accordion.js +1 -1
  34. package/dist/agent.json +464 -92
  35. package/dist/alert-DCGSrVTa.js +1 -0
  36. package/dist/{alert-HffaioZM.d.ts → alert-Dz541Ve9.d.ts} +10 -196
  37. package/dist/alert-center-Bb39SBqJ.js +1 -0
  38. package/dist/alert-center-CGBbqO-y.d.ts +391 -0
  39. package/dist/alert-center-parts.d.ts +6 -0
  40. package/dist/alert-center-parts.js +1 -0
  41. package/dist/alert-center.d.ts +9 -590
  42. package/dist/alert-center.js +1 -1
  43. package/dist/alert-dialog-CtKnvX5N.js +1 -0
  44. package/dist/alert-dialog-parts.d.ts +569 -0
  45. package/dist/alert-dialog-parts.js +1 -0
  46. package/dist/alert-dialog.d.ts +3 -1054
  47. package/dist/alert-dialog.js +1 -1
  48. package/dist/alert-parts.d.ts +6 -0
  49. package/dist/alert-parts.js +1 -0
  50. package/dist/alert.d.ts +43 -1
  51. package/dist/alert.js +1 -1
  52. package/dist/anchor-DW5_Gb-1.js +1 -0
  53. package/dist/anchor.d.ts +6 -6
  54. package/dist/anchor.js +1 -1
  55. package/dist/app-layout-D7kwv9su.js +1 -0
  56. package/dist/app-layout-k6UjK30v.d.ts +1167 -0
  57. package/dist/app-layout-parts.d.ts +6 -0
  58. package/dist/app-layout-parts.js +1 -0
  59. package/dist/app-layout.d.ts +98 -1883
  60. package/dist/app-layout.js +1 -1
  61. package/dist/area-chart-C6lKu7Un.d.ts +390 -0
  62. package/dist/area-chart-SAaGaZFD.js +1 -0
  63. package/dist/area-chart-parts.d.ts +6 -0
  64. package/dist/area-chart-parts.js +1 -0
  65. package/dist/area-chart.d.ts +6 -581
  66. package/dist/area-chart.js +1 -1
  67. package/dist/avatar-BMZ81f_5.js +1 -0
  68. package/dist/avatar-Ti8GKSnS.d.ts +201 -0
  69. package/dist/avatar-parts.d.ts +6 -0
  70. package/dist/avatar-parts.js +1 -0
  71. package/dist/avatar.d.ts +5 -277
  72. package/dist/avatar.js +1 -1
  73. package/dist/badge.d.ts +10 -9
  74. package/dist/badge.js +1 -1
  75. package/dist/bar-chart-C0Ra1ZpG.js +1 -0
  76. package/dist/bar-chart-Cb5fA8V7.d.ts +386 -0
  77. package/dist/bar-chart-parts.d.ts +6 -0
  78. package/dist/bar-chart-parts.js +1 -0
  79. package/dist/bar-chart.d.ts +4 -583
  80. package/dist/bar-chart.js +1 -1
  81. package/dist/behaviors-BW8RjkkS.js +1 -0
  82. package/dist/behaviors-BbOq5SFv.js +1 -0
  83. package/dist/behaviors-C7R7ZIoN.js +1 -0
  84. package/dist/behaviors-CHF5PT3C.js +1 -0
  85. package/dist/behaviors-CSZQSSfL.js +1 -0
  86. package/dist/behaviors-CcjvGa0d.js +1 -0
  87. package/dist/behaviors-CnarRd47.js +1 -0
  88. package/dist/behaviors-CoNi6Rd-.js +1 -0
  89. package/dist/behaviors-D9VIyDk1.js +1 -0
  90. package/dist/behaviors-DHVC34f9.js +1 -0
  91. package/dist/behaviors-DkCIgQ8w.js +1 -0
  92. package/dist/behaviors-Mkc_HjTB.js +1 -0
  93. package/dist/breadcrumb-CAzq3SlR.js +1 -0
  94. package/dist/breadcrumb-parts.d.ts +287 -0
  95. package/dist/breadcrumb-parts.js +1 -0
  96. package/dist/breadcrumb.d.ts +65 -555
  97. package/dist/breadcrumb.js +1 -1
  98. package/dist/browser-only-CokCtIvB.js +1 -0
  99. package/dist/browser-only-ymFoM3Ya.js +1 -0
  100. package/dist/browser-only.js +1 -1
  101. package/dist/button-Bqm7U0OC.js +1 -0
  102. package/dist/{button-K0pKc3GN.d.ts → button-C6-6TecO.d.ts} +5 -5
  103. package/dist/{button-BGwOPjGV.d.ts → button-CL17Dxza.d.ts} +28 -25
  104. package/dist/button-CRCiBPEF.js +1 -0
  105. package/dist/{button-Cgf2IcEC.d.ts → button-CRMoQyum.d.ts} +27 -28
  106. package/dist/button-Cr2iY2cI.js +1 -0
  107. package/dist/button-DhoE-BbZ.js +1 -0
  108. package/dist/button.d.ts +3 -3
  109. package/dist/button.js +1 -1
  110. package/dist/calendar-DQtapcSC.js +1 -0
  111. package/dist/calendar.d.ts +1 -1
  112. package/dist/calendar.js +1 -1
  113. package/dist/card-DbtGVKyo.d.ts +129 -0
  114. package/dist/card-parts.d.ts +6 -0
  115. package/dist/card-parts.js +1 -0
  116. package/dist/card.d.ts +3 -228
  117. package/dist/card.js +1 -1
  118. package/dist/centered-layout-parts.d.ts +169 -0
  119. package/dist/centered-layout-parts.js +1 -0
  120. package/dist/centered-layout.d.ts +3 -300
  121. package/dist/centered-layout.js +1 -1
  122. package/dist/chart-B0n2xyYi.js +1 -0
  123. package/dist/chart-BPsMxs1f.js +1 -0
  124. package/dist/chart-BmZoTjRu.js +1 -0
  125. package/dist/chart-Bybyh2Dc.js +1 -0
  126. package/dist/chart-CACfdGlp.d.ts +86 -0
  127. package/dist/chart-CBQJUTIX.js +1 -0
  128. package/dist/chart-Cb0MBaZx.js +1 -0
  129. package/dist/chart-CmMcfDmv.js +1 -0
  130. package/dist/chart-Dlp9FidW.js +2 -0
  131. package/dist/{chart-jitNqimS.d.ts → chart-XvStK-oM.d.ts} +23 -99
  132. package/dist/chart-wTwYzUMJ.js +1 -0
  133. package/dist/checkbox-DH7WFfuR.js +1 -0
  134. package/dist/checkbox-DsVXD96X.js +1 -0
  135. package/dist/checkbox-TX74-Iep.js +1 -0
  136. package/dist/checkbox-group-parts.d.ts +197 -0
  137. package/dist/checkbox-group-parts.js +1 -0
  138. package/dist/checkbox.d.ts +60 -9
  139. package/dist/checkbox.js +1 -1
  140. package/dist/choice-BekuLm-b.d.ts +217 -0
  141. package/dist/choice-DGI8VNR9.d.ts +1 -0
  142. package/dist/choice-PDT386cc.js +1 -0
  143. package/dist/choice-parts.d.ts +7 -0
  144. package/dist/choice-parts.js +1 -0
  145. package/dist/choice.d.ts +63 -1
  146. package/dist/choice.js +1 -1
  147. package/dist/code-UKPv6LVP.js +1 -0
  148. package/dist/{code-block-W3kWPxCJ.js → code-block-B-xD4_RW.js} +1 -1
  149. package/dist/code-block-B7XPzZnp.js +1 -0
  150. package/dist/code-block-BXXceNVo.js +1 -0
  151. package/dist/code-block-C7uzLs8t.js +1 -0
  152. package/dist/{code-block-BGdV4Yty.d.ts → code-block-Cs1Lcmdr.d.ts} +82 -253
  153. package/dist/code-block-Erv7wuWW.d.ts +173 -0
  154. package/dist/code-block-parts.d.ts +380 -0
  155. package/dist/code-block-parts.js +1 -0
  156. package/dist/code-block.d.ts +66 -693
  157. package/dist/code-block.js +6 -6
  158. package/dist/code-block_highlight-utils.d.ts +2 -1
  159. package/dist/code-block_highlight-utils.js +1 -1
  160. package/dist/code.d.ts +4 -4
  161. package/dist/code.js +1 -1
  162. package/dist/combobox-6LXe1cLx.js +1 -0
  163. package/dist/combobox-parts.d.ts +303 -0
  164. package/dist/combobox-parts.js +1 -0
  165. package/dist/combobox.d.ts +5 -468
  166. package/dist/combobox.js +1 -1
  167. package/dist/command-B8L-zjGt.js +1 -0
  168. package/dist/command-CCMWCjAK.js +1 -0
  169. package/dist/command-VKj84zAX.d.ts +859 -0
  170. package/dist/command-cbgO9CiG.js +1 -0
  171. package/dist/command-parts.d.ts +6 -0
  172. package/dist/command-parts.js +1 -0
  173. package/dist/command.d.ts +91 -1135
  174. package/dist/command.js +1 -1
  175. package/dist/compose-refs-BdRUneoc.js +1 -0
  176. package/dist/compose-refs-Ce1vWUz0.js +1 -0
  177. package/dist/cx-CfAFHj5_.js +73 -0
  178. package/dist/cx-DhYnQ07J.js +1 -0
  179. package/dist/cx.d.ts +23 -17
  180. package/dist/cx.js +1 -1
  181. package/dist/{data-slot-B-LqAcBB.d.ts → data-slot-BW8KQ9Xo.d.ts} +2 -2
  182. package/dist/data-table-C-FgaN3_.js +1 -0
  183. package/dist/data-table-Cw9dUo1w.js +1 -0
  184. package/dist/data-table-CwqrMtp0.js +1 -0
  185. package/dist/data-table-GUbt8mzo.d.ts +38 -0
  186. package/dist/data-table-parts.d.ts +763 -0
  187. package/dist/data-table-parts.js +1 -0
  188. package/dist/data-table.d.ts +21 -1217
  189. package/dist/data-table.js +1 -1
  190. package/dist/description-list-CjcKOOnr.d.ts +110 -0
  191. package/dist/description-list-parts.d.ts +6 -0
  192. package/dist/description-list-parts.js +1 -0
  193. package/dist/description-list.d.ts +3 -183
  194. package/dist/description-list.js +1 -1
  195. package/dist/dialog-4Ed3U7hz.js +1 -0
  196. package/dist/dialog-BDb_obii.d.ts +166 -0
  197. package/dist/dialog-BaR9D58J.js +1 -0
  198. package/dist/dialog-BkNxAcol.d.ts +467 -0
  199. package/dist/dialog-DSYuhFD5.js +1 -0
  200. package/dist/dialog-fXMCxM9W.js +1 -0
  201. package/dist/dialog-parts.d.ts +6 -0
  202. package/dist/dialog-parts.js +1 -0
  203. package/dist/dialog.d.ts +88 -2
  204. package/dist/dialog.js +1 -1
  205. package/dist/dropdown-menu-BuluRn0Z.js +1 -0
  206. package/dist/dropdown-menu-CDXlp0QT.d.ts +507 -0
  207. package/dist/dropdown-menu-parts.d.ts +6 -0
  208. package/dist/dropdown-menu-parts.js +1 -0
  209. package/dist/dropdown-menu.d.ts +57 -1
  210. package/dist/dropdown-menu.js +1 -1
  211. package/dist/empty-parts.d.ts +120 -0
  212. package/dist/empty-parts.js +1 -0
  213. package/dist/empty.d.ts +2 -216
  214. package/dist/empty.js +1 -1
  215. package/dist/field-BRYypbjO.js +1 -0
  216. package/dist/field-BVMx7HoG.js +1 -0
  217. package/dist/field-BwCq1b9R.js +1 -0
  218. package/dist/field-CYAaNexp.js +1 -0
  219. package/dist/field-DRHAcM1s.js +1 -0
  220. package/dist/field-parts.d.ts +767 -0
  221. package/dist/field-parts.js +1 -0
  222. package/dist/field.d.ts +21 -1201
  223. package/dist/field.js +1 -1
  224. package/dist/flag.d.ts +3 -3
  225. package/dist/flag.js +1 -1
  226. package/dist/float-C_vwTtzU.js +1 -0
  227. package/dist/float-JmSzKDHd.js +1 -0
  228. package/dist/float-OhVY3cf4.js +1 -0
  229. package/dist/hooks-B-Cd15iL.js +1 -0
  230. package/dist/hooks-BP_uqBsI.js +1 -0
  231. package/dist/hooks-BeLOGKwE.js +1 -0
  232. package/dist/hooks-BsOjpTgs.js +1 -0
  233. package/dist/hooks-BybaGF7O.js +1 -0
  234. package/dist/hooks-C9b-2wGy.js +1 -0
  235. package/dist/hooks-CMmpICCH.js +1 -0
  236. package/dist/hooks-CUYIUcp6.js +1 -0
  237. package/dist/hooks-DKbOd_pQ.js +1 -0
  238. package/dist/hooks-DejuqCNF.js +1 -0
  239. package/dist/hooks-GsDfo7Zl.js +1 -0
  240. package/dist/hooks-PsYFJkz2.js +1 -0
  241. package/dist/hooks-lDz_S9UG.js +1 -0
  242. package/dist/hooks.d.ts +126 -17
  243. package/dist/hooks.js +1 -1
  244. package/dist/hover-card-BEC5EQiH.js +1 -0
  245. package/dist/hover-card-parts.d.ts +160 -0
  246. package/dist/hover-card-parts.js +1 -0
  247. package/dist/hover-card.d.ts +9 -281
  248. package/dist/hover-card.js +1 -1
  249. package/dist/{icon-CgNqu-fl.d.ts → icon--purqHRo.d.ts} +1 -1
  250. package/dist/icon-0RoVrpGj.js +1 -0
  251. package/dist/icon-BSGMvJ0W.js +1 -0
  252. package/dist/icon-DIiKxRTh.js +1 -0
  253. package/dist/{icon-DXDyhy2N.d.ts → icon-Dqn_LLrR.d.ts} +2 -2
  254. package/dist/{icon-NYvyyRMG.d.ts → icon-KTcDR4--.d.ts} +2 -2
  255. package/dist/icon.d.ts +3 -3
  256. package/dist/icon.js +1 -1
  257. package/dist/icons-CVgj9Whd.js +1 -0
  258. package/dist/icons-D_4cZaL1.js +1 -0
  259. package/dist/icons-DucrvIOa.js +1 -0
  260. package/dist/icons.d.ts +2 -2
  261. package/dist/icons.js +1 -1
  262. package/dist/{in-view-B3nMAzfE.d.ts → in-view-C_daNafg.d.ts} +4 -23
  263. package/dist/{index-KJ06KK6t.d.ts → index-CCkilmv8.d.ts} +1 -1
  264. package/dist/input-83xaPZWK.js +1 -0
  265. package/dist/input-B78ah4AB.js +1 -0
  266. package/dist/{input-q8o5uMhW.d.ts → input-Bvpu3ruQ.d.ts} +2 -2
  267. package/dist/input.d.ts +5 -5
  268. package/dist/input.js +1 -1
  269. package/dist/kbd-Bz_Rbpv8.js +1 -0
  270. package/dist/kbd.d.ts +5 -5
  271. package/dist/kbd.js +1 -1
  272. package/dist/{label-r2sJcSQ4.d.ts → label-DZpKu3Pu.d.ts} +8 -8
  273. package/dist/label-DmkAp9xI.js +1 -0
  274. package/dist/label.d.ts +1 -1
  275. package/dist/label.js +1 -1
  276. package/dist/layer-container-DDOZJ0fn.js +1 -0
  277. package/dist/layer-container.d.ts +11 -3
  278. package/dist/layer-container.js +1 -1
  279. package/dist/line-chart-CBL7eCqF.js +1 -0
  280. package/dist/line-chart-CIDFDkyb.d.ts +380 -0
  281. package/dist/line-chart-parts.d.ts +6 -0
  282. package/dist/line-chart-parts.js +1 -0
  283. package/dist/line-chart.d.ts +5 -569
  284. package/dist/line-chart.js +1 -1
  285. package/dist/list-CC3Pi__V.js +1 -0
  286. package/dist/list-Cx4KNfgC.d.ts +286 -0
  287. package/dist/list-FiFQJ0BU.js +1 -0
  288. package/dist/list-parts.d.ts +6 -0
  289. package/dist/list-parts.js +1 -0
  290. package/dist/list.d.ts +9 -406
  291. package/dist/list.js +1 -1
  292. package/dist/live-region-78gbKwlB.js +1 -0
  293. package/dist/live-region.d.ts +2 -2
  294. package/dist/live-region.js +1 -1
  295. package/dist/llms.txt +50 -26
  296. package/dist/main-9d96oUPG.js +1 -0
  297. package/dist/main.d.ts +1 -1
  298. package/dist/main.js +1 -1
  299. package/dist/mantle.css +1304 -910
  300. package/dist/media-object-parts.d.ts +65 -0
  301. package/dist/media-object-parts.js +1 -0
  302. package/dist/media-object.d.ts +5 -121
  303. package/dist/media-object.js +1 -1
  304. package/dist/migrations/0017-select-owned-behavior.yml +117 -0
  305. package/dist/migrations/0018-combobox-owned-behavior.yml +1661 -0
  306. package/dist/migrations/0019-multi-select-owned-behavior.yml +1414 -0
  307. package/dist/migrations/0020-native-floats.yml +823 -0
  308. package/dist/migrations/0021-native-radio-group.yml +397 -0
  309. package/dist/migrations/0024-command-owned-behavior.yml +66 -0
  310. package/dist/migrations/0026-native-dropdown-menu.yml +351 -0
  311. package/dist/migrations/0029-data-attribute-contract.yml +1707 -0
  312. package/dist/migrations/0030-between-variant.yml +1954 -0
  313. package/dist/multi-select-parts.d.ts +487 -0
  314. package/dist/multi-select-parts.js +1 -0
  315. package/dist/multi-select-qC0BuYKD.js +1 -0
  316. package/dist/multi-select.d.ts +6 -803
  317. package/dist/multi-select.js +1 -1
  318. package/dist/otp-input-LPdkb_Fg.js +1 -0
  319. package/dist/otp-input-parts.d.ts +211 -0
  320. package/dist/otp-input-parts.js +1 -0
  321. package/dist/otp-input-zl6MVio6.js +1 -0
  322. package/dist/otp-input.d.ts +11 -252
  323. package/dist/otp-input.js +1 -1
  324. package/dist/overlay-prompt-BIzMQvx7.js +1 -0
  325. package/dist/overlay-prompt-CDnhSoPJ.js +1 -0
  326. package/dist/overlay-prompt.d.ts +57 -0
  327. package/dist/overlay-prompt.js +1 -0
  328. package/dist/pagination-B2ESEbMI.d.ts +171 -0
  329. package/dist/pagination-CxaLKZcE.js +1 -0
  330. package/dist/pagination-Df1gTCN-.js +1 -0
  331. package/dist/pagination-cursor-pagination-parts.d.ts +6 -0
  332. package/dist/pagination-cursor-pagination-parts.js +1 -0
  333. package/dist/pagination.d.ts +39 -304
  334. package/dist/pagination.js +1 -1
  335. package/dist/popover-DOd6zLvE.d.ts +226 -0
  336. package/dist/popover-DWvHbepV.js +1 -0
  337. package/dist/popover-parts.d.ts +6 -0
  338. package/dist/popover-parts.js +1 -0
  339. package/dist/popover.d.ts +60 -2
  340. package/dist/popover.js +1 -1
  341. package/dist/position-Cv3XpSur.d.ts +5 -0
  342. package/dist/progress-BE0c8GW8.js +1 -0
  343. package/dist/progress-ZhFJhv9u.js +1 -0
  344. package/dist/progress-bar-parts.d.ts +86 -0
  345. package/dist/progress-bar-parts.js +1 -0
  346. package/dist/progress-donut-parts.d.ts +94 -0
  347. package/dist/progress-donut-parts.js +1 -0
  348. package/dist/progress-mJQMhxMX.js +1 -0
  349. package/dist/progress-zDpT3TY4.d.ts +2 -0
  350. package/dist/progress.d.ts +4 -268
  351. package/dist/progress.js +1 -1
  352. package/dist/qr-code-0zh10iIE.d.ts +148 -0
  353. package/dist/qr-code-BOOubA9x.js +1 -0
  354. package/dist/qr-code-D8tBKtjP.js +1 -0
  355. package/dist/qr-code-DzJjumoc.d.ts +46 -0
  356. package/dist/qr-code-encoder.browser.d.ts +15 -0
  357. package/dist/qr-code-encoder.browser.js +1 -0
  358. package/dist/qr-code-encoder.d.ts +15 -0
  359. package/dist/qr-code-encoder.js +1 -0
  360. package/dist/qr-code-parts.d.ts +6 -0
  361. package/dist/qr-code-parts.js +1 -0
  362. package/dist/qr-code.d.ts +4 -227
  363. package/dist/qr-code.js +1 -1
  364. package/dist/query-C0e5VYNp.d.ts +440 -0
  365. package/dist/query-V5NifJGs.js +1 -0
  366. package/dist/query-filter.d.ts +6 -6
  367. package/dist/query-filter.js +1 -1
  368. package/dist/query-parts.d.ts +6 -0
  369. package/dist/query-parts.js +1 -0
  370. package/dist/query.d.ts +5 -634
  371. package/dist/query.js +1 -1
  372. package/dist/radio-group-B9jtIbV1.d.ts +39 -0
  373. package/dist/radio-group-BliblUqe.js +1 -0
  374. package/dist/radio-group-f3ThXQCx.js +1 -0
  375. package/dist/radio-group-parts.d.ts +249 -0
  376. package/dist/radio-group-parts.js +1 -0
  377. package/dist/radio-group-zA5DjlLg.js +1 -0
  378. package/dist/radio-group.d.ts +7 -399
  379. package/dist/radio-group.js +1 -1
  380. package/dist/sandbar-Cm2yMjEZ.js +1 -0
  381. package/dist/sandbar-DU4wpKRc.d.ts +345 -0
  382. package/dist/sandbar-parts.d.ts +6 -0
  383. package/dist/sandbar-parts.js +1 -0
  384. package/dist/sandbar.d.ts +6 -441
  385. package/dist/sandbar.js +1 -1
  386. package/dist/sandboxed-on-click-Cg3lewoG.js +1 -0
  387. package/dist/sandboxed-on-click-DOw_Jkhk.js +1 -0
  388. package/dist/sandboxed-on-click.d.ts +1 -1
  389. package/dist/sandboxed-on-click.js +1 -1
  390. package/dist/scatter-plot-1vFxkpjT.js +1 -0
  391. package/dist/scatter-plot-D25jLIVw.d.ts +388 -0
  392. package/dist/scatter-plot-parts.d.ts +6 -0
  393. package/dist/scatter-plot-parts.js +1 -0
  394. package/dist/scatter-plot.d.ts +5 -575
  395. package/dist/scatter-plot.js +1 -1
  396. package/dist/segmented-control-DuiDPKDZ.js +1 -0
  397. package/dist/segmented-control-parts.d.ts +72 -0
  398. package/dist/segmented-control-parts.js +1 -0
  399. package/dist/segmented-control.d.ts +4 -100
  400. package/dist/segmented-control.js +1 -1
  401. package/dist/select-08IEtypH.js +1 -0
  402. package/dist/select-DM2wWfOO.d.ts +478 -0
  403. package/dist/select-parts.d.ts +6 -0
  404. package/dist/select-parts.js +1 -0
  405. package/dist/select.d.ts +63 -1
  406. package/dist/select.js +1 -1
  407. package/dist/selectable-list-Ax5F2Gz1.js +1 -0
  408. package/dist/selectable-list-CyLc3EEt.d.ts +407 -0
  409. package/dist/selectable-list-GcpbbRM1.js +1 -0
  410. package/dist/selectable-list-parts.d.ts +6 -0
  411. package/dist/selectable-list-parts.js +1 -0
  412. package/dist/selectable-list.d.ts +7 -647
  413. package/dist/selectable-list.js +1 -1
  414. package/dist/separator-BB1ohsjn.js +1 -0
  415. package/dist/{separator-QfH0ot5K.d.ts → separator-BzHNVyyv.d.ts} +2 -2
  416. package/dist/separator.d.ts +1 -1
  417. package/dist/separator.js +1 -1
  418. package/dist/sheet-5JgxVaWC.js +1 -0
  419. package/dist/sheet-parts.d.ts +732 -0
  420. package/dist/sheet-parts.js +1 -0
  421. package/dist/sheet-qYPi5MP8.js +1 -0
  422. package/dist/sheet.d.ts +11 -1208
  423. package/dist/sheet.js +1 -1
  424. package/dist/sidebar-CsC9fyPL.js +1 -0
  425. package/dist/sidebar-OBA7L42d.d.ts +1480 -0
  426. package/dist/sidebar-parts.d.ts +6 -0
  427. package/dist/sidebar-parts.js +1 -0
  428. package/dist/sidebar.d.ts +108 -2518
  429. package/dist/sidebar.js +1 -1
  430. package/dist/skeleton-DB0oQyAx.js +1 -0
  431. package/dist/skeleton.d.ts +5 -5
  432. package/dist/skeleton.js +1 -1
  433. package/dist/skip-to-main-link-BGhAWSqB.js +1 -0
  434. package/dist/skip-to-main-link.d.ts +1 -1
  435. package/dist/skip-to-main-link.js +1 -1
  436. package/dist/slider-YlBozcPQ.js +1 -0
  437. package/dist/slider.d.ts +150 -16
  438. package/dist/slider.js +1 -1
  439. package/dist/slot-5ZSmrISx.d.ts +19 -0
  440. package/dist/slot-BxngGBJ2.js +1 -0
  441. package/dist/slot-CBcGhRdV.js +1 -0
  442. package/dist/slot-tuk2J6bY.d.ts +50 -0
  443. package/dist/slot.d.ts +1 -1
  444. package/dist/slot.js +1 -1
  445. package/dist/source-all.css +5 -1
  446. package/dist/split-button-DvJHD7cZ.js +1 -0
  447. package/dist/split-button-parts.d.ts +178 -0
  448. package/dist/split-button-parts.js +1 -0
  449. package/dist/split-button.d.ts +2 -314
  450. package/dist/split-button.js +1 -1
  451. package/dist/strata-parts.d.ts +256 -0
  452. package/dist/strata-parts.js +1 -0
  453. package/dist/strata.d.ts +6 -495
  454. package/dist/strata.js +1 -1
  455. package/dist/{suggestions-NkqYTT49.d.ts → suggestions-BJeGvwDa.d.ts} +7 -7
  456. package/dist/switch-DajWYrq3.js +1 -0
  457. package/dist/switch.d.ts +37 -5
  458. package/dist/switch.js +1 -1
  459. package/dist/{table-rWiVWEgB.d.ts → table-C2KnE83u.d.ts} +6 -445
  460. package/dist/table-DJHK48-8.js +1 -0
  461. package/dist/table-parts.d.ts +6 -0
  462. package/dist/table-parts.js +1 -0
  463. package/dist/table.d.ts +81 -1
  464. package/dist/table.js +1 -1
  465. package/dist/tabs-36-4SlRo.js +1 -0
  466. package/dist/tabs-CC_HAqr4.d.ts +193 -0
  467. package/dist/tabs-DayeszXP.js +1 -0
  468. package/dist/tabs-headless-tabs-parts.d.ts +6 -0
  469. package/dist/tabs-headless-tabs-parts.js +1 -0
  470. package/dist/tabs-parts.d.ts +237 -0
  471. package/dist/tabs-parts.js +1 -0
  472. package/dist/tabs.d.ts +43 -420
  473. package/dist/tabs.js +1 -1
  474. package/dist/text-area-D29JTaZg.js +1 -0
  475. package/dist/text-area.d.ts +2 -2
  476. package/dist/text-area.js +1 -1
  477. package/dist/theme-D6rP5Fy8.js +1 -0
  478. package/dist/theme-switcher-PKMCyJxT.js +1 -0
  479. package/dist/theme-switcher.d.ts +26 -22
  480. package/dist/theme-switcher.js +1 -1
  481. package/dist/theme-xoFnLba6.js +1 -0
  482. package/dist/theme.d.ts +84 -77
  483. package/dist/theme.js +1 -1
  484. package/dist/time-zone-CpWYKHdp.js +1 -0
  485. package/dist/time-zone-DZ4hUJ8K.js +1 -0
  486. package/dist/time-zone.d.ts +190 -0
  487. package/dist/time-zone.js +1 -0
  488. package/dist/toast-BJZ__22c.js +1 -0
  489. package/dist/toast-Cb9IN-6e.d.ts +185 -0
  490. package/dist/toast-DM_oq-3E.js +1 -0
  491. package/dist/toast-parts.d.ts +6 -0
  492. package/dist/toast-parts.js +1 -0
  493. package/dist/toast.d.ts +7 -256
  494. package/dist/toast.js +1 -1
  495. package/dist/tokens.dark.json +3026 -0
  496. package/dist/tokens.json +4867 -0
  497. package/dist/tokens.resolver.json +37 -0
  498. package/dist/tooltip-D4HZn19B.js +1 -0
  499. package/dist/tooltip-DP6Lz6jv.d.ts +180 -0
  500. package/dist/tooltip-Uy-kz0rK.d.ts +1 -0
  501. package/dist/tooltip-parts.d.ts +7 -0
  502. package/dist/tooltip-parts.js +1 -0
  503. package/dist/tooltip.d.ts +57 -1
  504. package/dist/tooltip.js +1 -1
  505. package/dist/truncated-text-B5u2AlNg.js +1 -0
  506. package/dist/truncated-text-BoXHP-cD.js +1 -0
  507. package/dist/truncated-text.d.ts +4 -6
  508. package/dist/truncated-text.js +1 -1
  509. package/dist/types.d.ts +1 -1
  510. package/dist/types.js +1 -1
  511. package/dist/typography-C2BmSH12.d.ts +148 -0
  512. package/dist/typography-parts.d.ts +6 -0
  513. package/dist/typography-parts.js +1 -0
  514. package/dist/typography.d.ts +52 -0
  515. package/dist/typography.js +1 -0
  516. package/dist/use-combobox-OhIEVioc.d.ts +23 -0
  517. package/dist/use-float-WEqqhXBE.d.ts +18 -0
  518. package/dist/use-listbox-D4uIonSN.d.ts +1 -0
  519. package/dist/utils-BN3rwHzz.js +1 -0
  520. package/dist/utils-BlLYcYik.js +1 -0
  521. package/dist/utils-C4astHJG.js +1 -0
  522. package/dist/utils-CPSttKPD.js +1 -0
  523. package/dist/{copy-to-clipboard-DInu78k_.js → utils-Dd83caRw.js} +1 -1
  524. package/dist/utils.d.ts +1 -1
  525. package/dist/utils.js +1 -1
  526. package/dist/visually-hidden.d.ts +2 -2
  527. package/dist/visually-hidden.js +1 -1
  528. package/dist/well.d.ts +2 -2
  529. package/dist/well.js +1 -1
  530. package/dist/world-map-BDd3N_Ap.d.ts +424 -0
  531. package/dist/world-map-D3c8Pq-h.js +1 -0
  532. package/dist/world-map-parts.d.ts +6 -0
  533. package/dist/world-map-parts.js +1 -0
  534. package/dist/world-map-t9U-IMKS.js +1 -0
  535. package/dist/world-map.d.ts +80 -0
  536. package/dist/world-map.js +1 -0
  537. package/package.json +30 -19
  538. package/dist/alert-CH99Rw-R.js +0 -1
  539. package/dist/anchor-CgcbWEUs.js +0 -1
  540. package/dist/browser-only-BTSrYWLj.js +0 -1
  541. package/dist/button-69InNC_m.js +0 -1
  542. package/dist/button-BQZ6eoD3.js +0 -1
  543. package/dist/button-BWGUuWnu.js +0 -1
  544. package/dist/button-Cu9e3SM7.js +0 -1
  545. package/dist/chart-BO9EwQ60.js +0 -1
  546. package/dist/chart-CE5Uaqz9.js +0 -1
  547. package/dist/chart-DCTGGlWL.js +0 -1
  548. package/dist/chart-DudCw24t.js +0 -2
  549. package/dist/checkbox-CS504fKk.js +0 -1
  550. package/dist/choice-BwfmbepO.d.ts +0 -405
  551. package/dist/choice-uyYccm0A.js +0 -1
  552. package/dist/clsx-DUGZgXfJ.js +0 -1
  553. package/dist/clsx-Dj3RWZ2l.js +0 -1
  554. package/dist/code-DUJzSl4K.js +0 -1
  555. package/dist/compose-refs-sFdxsL7k.js +0 -1
  556. package/dist/cx-CK7o_rVv.js +0 -1
  557. package/dist/dialog-B9JAGy_x.d.ts +0 -28
  558. package/dist/dialog-CsugEt2A.js +0 -1
  559. package/dist/dialog-DD5H3EH1.d.ts +0 -942
  560. package/dist/dropdown-menu-DHdgaw4P.js +0 -1
  561. package/dist/dropdown-menu-DmDxYPde.d.ts +0 -775
  562. package/dist/field-Bihblt8U.js +0 -1
  563. package/dist/field-CPvjazWN.js +0 -1
  564. package/dist/icon-BudQMD2S.js +0 -1
  565. package/dist/icon-kK0c-POG.js +0 -1
  566. package/dist/icons-4JA-SGfv.js +0 -1
  567. package/dist/icons-CDLz5lpI.js +0 -1
  568. package/dist/icons-CSwTVV2m.js +0 -1
  569. package/dist/input-DHovzBjS.js +0 -1
  570. package/dist/input-DQyN6gN0.js +0 -1
  571. package/dist/interactive-target-BXScNeOr.js +0 -1
  572. package/dist/kbd-CLHsJ99p.js +0 -1
  573. package/dist/label-DmDwzPD8.js +0 -1
  574. package/dist/layer-container-kEQiE4zV.js +0 -1
  575. package/dist/list-CO_yLdln.js +0 -1
  576. package/dist/live-region-DQ1QLv3L.js +0 -1
  577. package/dist/main-CC1L9IsH.js +0 -1
  578. package/dist/popover-BhTFutCz.d.ts +0 -1
  579. package/dist/popover-DxOqLKxy.js +0 -1
  580. package/dist/popover-lwkwWcRW.d.ts +0 -291
  581. package/dist/primitive-Dz9Al-us.js +0 -1
  582. package/dist/radio-group-jj2abc0t.js +0 -1
  583. package/dist/radio-group-sLz5AA9I.d.ts +0 -27
  584. package/dist/sandboxed-on-click-C7pPu-2M.js +0 -1
  585. package/dist/select-BqmpVJJT.d.ts +0 -890
  586. package/dist/select-C6Su0dU0.js +0 -1
  587. package/dist/separator-DfzxVutO.js +0 -1
  588. package/dist/shake-DL6WhMXM.js +0 -1
  589. package/dist/sheet-Bd2LIhzF.js +0 -1
  590. package/dist/skeleton-DBpI-ko5.js +0 -1
  591. package/dist/slot-D12N_fZJ.d.ts +0 -67
  592. package/dist/slot-DdYN1L1C.js +0 -1
  593. package/dist/table-CFHiDBW8.js +0 -1
  594. package/dist/theme-DdZgLvKH.js +0 -1
  595. package/dist/tooltip-CpK3XTor.d.ts +0 -283
  596. package/dist/tooltip-b6oiTaWq.js +0 -1
  597. package/dist/use-breakpoint--mo7kr9d.js +0 -1
  598. package/dist/use-callback-ref-BvVyI5K1.js +0 -1
  599. package/dist/use-copy-to-clipboard-Dy_0Qzb7.js +0 -1
  600. package/dist/use-inert-siblings-CNmNuS2h.js +0 -1
  601. package/dist/use-is-apple-platform-D4nifHMx.js +0 -1
  602. package/dist/use-is-hydrated-after-paint-r9Cl2mGp.js +0 -1
  603. package/dist/use-isomorphic-layout-effect-CLSmHzo4.js +0 -1
  604. package/dist/use-matches-media-query-m860lols.js +0 -1
  605. package/dist/use-prefers-reduced-motion-CU6mWmOe.js +0 -1
  606. package/dist/use-swipe-to-dismiss-i__cTF2v.js +0 -1
  607. /package/dist/{suggestions-Ciz2vaJO.js → query-filter-Ciz2vaJO.js} +0 -0
  608. /package/dist/{radio-group-HDVxTNPi.js → sidebar-HDVxTNPi.js} +0 -0
  609. /package/dist/{direction-CvDpql3O.js → sorting-CvDpql3O.js} +0 -0
  610. /package/dist/{booleanish-BfvnW6vy.js → types-BfvnW6vy.js} +0 -0
  611. /package/dist/{css-properties-D85fCNV3.js → types-D85fCNV3.js} +0 -0
  612. /package/dist/{alternate-announcement-BkH4bOKp.js → utils-BkH4bOKp.js} +0 -0
  613. /package/dist/{in-view-Dxv_GrUU.js → utils-Dxv_GrUU.js} +0 -0
  614. /package/dist/{data-slot-EM6s2WEU.js → utils-EM6s2WEU.js} +0 -0
  615. /package/dist/{cookie-ca4g5CKp.js → utils-ca4g5CKp.js} +0 -0
package/dist/sidebar.js CHANGED
@@ -1 +1 @@
1
- import{t as e}from"./use-callback-ref-BvVyI5K1.js";import{r as t}from"./use-breakpoint--mo7kr9d.js";import{n,t as r}from"./use-is-apple-platform-D4nifHMx.js";import{t as i}from"./use-is-hydrated-after-paint-r9Cl2mGp.js";import{t as a}from"./cx-CK7o_rVv.js";import{t as o}from"./data-slot-EM6s2WEU.js";import{t as s}from"./button-BWGUuWnu.js";import{n as c}from"./separator-DfzxVutO.js";import{t as l}from"./sheet-Bd2LIhzF.js";import{t as u}from"./slot-DdYN1L1C.js";import{t as d}from"./tooltip-b6oiTaWq.js";import{n as f}from"./cookie-ca4g5CKp.js";import{c as p}from"react/compiler-runtime";import{createContext as m,useContext as h,useEffect as g,useId as _,useLayoutEffect as v,useRef as y,useState as b}from"react";import x from"tiny-invariant";import{Fragment as S,jsx as C,jsxs as w}from"react/jsx-runtime";import{SidebarSimpleIcon as T}from"@phosphor-icons/react/SidebarSimple";const E={sm:`max-sm:not-data-hydrated:hidden`,md:`max-md:not-data-hydrated:hidden`,lg:`max-lg:not-data-hydrated:hidden`},D=`duration-200 ease-out-strong motion-reduce:transition-none group-not-data-hydrated/sidebar-nav:transition-none`,O=m(null);function k(){let e=h(O);return x(e,`useSidebar must be used within Sidebar.Root.`),e}function A(e){let t=h(O);return x(t,`Sidebar.${e} must be rendered inside Sidebar.Root.`),t}const j=[];function M(e){return e instanceof HTMLElement?e.isContentEditable||e.tagName===`INPUT`||e.tagName===`TEXTAREA`||e.tagName===`SELECT`:!1}function N(){let e=Symbol(`sidebar-keyboard-shortcut`);return j.push(e),{isOwner:()=>j[0]===e,release:()=>{let t=j.indexOf(e);t!==-1&&j.splice(t,1)}}}const P=r=>{let i=p(35),{children:a,defaultOpen:o,keyboardShortcut:s,mobileBreakpoint:c,onOpenChange:l,onOpenMobileChange:u,open:d,openMobile:f}=r,m=o===void 0||o,h=s===void 0||s,x=c===void 0?`lg`:c,S=t(x),w=_(),T=y(l),E=y(u),D;i[0]!==l||i[1]!==u?(D=()=>{T.current=l,E.current=u},i[0]=l,i[1]=u,i[2]=D):D=i[2],v(D);let k=d!=null,[A,j]=b(m),P=k?d:A,F;i[3]===k?F=i[4]:(F=e=>{k||j(e),T.current?.(e)},i[3]=k,i[4]=F);let I=F,L=f!=null,[R,z]=b(!1),B=L?f:R,V;i[5]===L?V=i[6]:(V=e=>{L||z(e),E.current?.(e)},i[5]=L,i[6]=V);let H=V,U=y(S),W,G;i[7]!==S||i[8]!==B||i[9]!==H?(W=()=>{let e=U.current&&!S;U.current=S,e&&B&&H(!1)},G=[S,B,H],i[7]=S,i[8]=B,i[9]=H,i[10]=W,i[11]=G):(W=i[10],G=i[11]),g(W,G);let K;i[12]!==S||i[13]!==P||i[14]!==B||i[15]!==I||i[16]!==H?(K=()=>{S?H(!B):I(!P)},i[12]=S,i[13]=P,i[14]=B,i[15]=I,i[16]=H,i[17]=K):K=i[17];let q=K,J=e(q),Y,X;i[18]!==h||i[19]!==J?(Y=()=>{if(!h)return;let e=N(),t=n(),r=n=>{if(!e.isOwner()||n.defaultPrevented||M(n.target))return;let r=t?n.metaKey:n.ctrlKey,i=t?n.ctrlKey:n.metaKey;n.key?.toLowerCase()===`b`&&r&&!i&&!n.altKey&&!n.shiftKey&&(n.preventDefault(),J())};return window.addEventListener(`keydown`,r),()=>{window.removeEventListener(`keydown`,r),e.release()}},X=[h,J],i[18]=h,i[19]=J,i[20]=Y,i[21]=X):(Y=i[20],X=i[21]),g(Y,X);let Z;i[22]!==S||i[23]!==h||i[24]!==x||i[25]!==w||i[26]!==P||i[27]!==B||i[28]!==I||i[29]!==H||i[30]!==q?(Z={isMobile:S,keyboardShortcut:h,mobileBreakpoint:x,navId:w,open:P,openMobile:B,setOpen:I,setOpenMobile:H,toggle:q},i[22]=S,i[23]=h,i[24]=x,i[25]=w,i[26]=P,i[27]=B,i[28]=I,i[29]=H,i[30]=q,i[31]=Z):Z=i[31];let Q=Z,$;return i[32]!==a||i[33]!==Q?($=/* @__PURE__ */ C(O.Provider,{value:Q,children:a}),i[32]=a,i[33]=Q,i[34]=$):$=i[34],$},F=e=>{let t=p(48),n,r,s,c,u,d;t[0]===e?(n=t[1],r=t[2],s=t[3],c=t[4],u=t[5],d=t[6]):({"aria-label":n,"aria-labelledby":r,children:s,className:c,"data-slot":u,...d}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=s,t[4]=c,t[5]=u,t[6]=d);let{isMobile:f,mobileBreakpoint:m,navId:h,open:g,openMobile:_,setOpenMobile:v}=A(`Nav`),y=i(),b=n??(r==null?`Main`:void 0);if(f){let e;t[7]===u?e=t[8]:(e=o(u,`sidebar-nav`),t[7]=u,t[8]=e);let n;t[9]===r?n=t[10]:(n=r==null?null:{"aria-labelledby":r},t[9]=r,t[10]=n);let i;t[11]===c?i=t[12]:(i=a(`bg-base w-(--sidebar-width-mobile,18rem) max-w-full p-0`,c),t[11]=c,t[12]=i);let f=b??`Sidebar`,p;t[13]===f?p=t[14]:(p=/* @__PURE__ */ C(l.Title,{className:`sr-only`,children:f}),t[13]=f,t[14]=p);let m;t[15]!==b||t[16]!==r||t[17]!==s||t[18]!==h?(m=/* @__PURE__ */ C(`nav`,{id:h,"aria-label":b,"aria-labelledby":r,className:`flex h-full w-full min-w-0 flex-col text-sm`,children:s}),t[15]=b,t[16]=r,t[17]=s,t[18]=h,t[19]=m):m=t[19];let g;t[20]!==d||t[21]!==e||t[22]!==n||t[23]!==i||t[24]!==p||t[25]!==m?(g=/* @__PURE__ */ w(l.Content,{side:`left`,preferredWidth:`sm:max-w-(--sidebar-width-mobile,18rem)`,"data-slot":e,"data-mobile":``,...n,className:i,...d,children:[p,m]}),t[20]=d,t[21]=e,t[22]=n,t[23]=i,t[24]=p,t[25]=m,t[26]=g):g=t[26];let y;return t[27]!==_||t[28]!==v||t[29]!==g?(y=/* @__PURE__ */ C(l.Root,{open:_,onOpenChange:v,children:g}),t[27]=_,t[28]=v,t[29]=g,t[30]=y):y=t[30],y}let x;t[31]===u?x=t[32]:(x=o(u,`sidebar-nav`),t[31]=u,t[32]=x);let S=E[m],T;t[33]!==c||t[34]!==S?(T=a(`group/sidebar-nav bg-base relative h-full w-(--sidebar-width,13rem) shrink-0 overflow-hidden`,`data-[state=collapsed]:w-(--sidebar-width-icon,3.25rem)`,S,`transition-[width] duration-200 ease-out-strong motion-reduce:transition-none not-data-hydrated:transition-none`,c),t[33]=c,t[34]=S,t[35]=T):T=t[35];let D=g?`expanded`:`collapsed`,O=y?``:void 0,k;t[36]!==b||t[37]!==r||t[38]!==s||t[39]!==h?(k=/* @__PURE__ */ C(`nav`,{id:h,"aria-label":b,"aria-labelledby":r,className:`absolute inset-y-0 left-0 flex w-full min-w-0 flex-col text-sm`,children:s}),t[36]=b,t[37]=r,t[38]=s,t[39]=h,t[40]=k):k=t[40];let j;return t[41]!==d||t[42]!==x||t[43]!==T||t[44]!==D||t[45]!==O||t[46]!==k?(j=/* @__PURE__ */ C(`div`,{"data-slot":x,className:T,...d,"data-state":D,"data-hydrated":O,children:k}),t[41]=d,t[42]=x,t[43]=T,t[44]=D,t[45]=O,t[46]=k,t[47]=j):j=t[47],j},I=/* @__PURE__ */ C(T,{}),L=e=>{let t=p(7),{label:n,shortcut:r}=e,i;t[0]===n?i=t[1]:(i=/* @__PURE__ */ C(`span`,{"data-slot":`sidebar-tooltip-label`,className:`contents`,children:n}),t[0]=n,t[1]=i);let a;t[2]===r?a=t[3]:(a=r!=null&&/* @__PURE__ */ C(`span`,{"aria-hidden":!0,"data-slot":`sidebar-tooltip-shortcut`,className:`inline-flex shrink-0 items-center gap-0.5 [&_kbd]:h-4 [&_kbd]:min-w-4 [&_kbd]:bg-neutral-500/25 [&_kbd]:px-0.5 [&_kbd]:text-xs`,translate:`no`,children:r}),t[2]=r,t[3]=a);let o;return t[4]!==i||t[5]!==a?(o=/* @__PURE__ */ w(`span`,{"data-slot":`sidebar-tooltip-row`,className:`flex items-center gap-1.5`,children:[i,a]}),t[4]=i,t[5]=a,t[6]=o):o=t[6],o},R=e=>{let t=p(34),n,i,a,c,l,u,f,m,h;t[0]===e?(n=t[1],i=t[2],a=t[3],c=t[4],l=t[5],u=t[6],f=t[7],m=t[8],h=t[9]):({appearance:l,"data-slot":n,icon:u,intent:f,label:m,onClick:i,shortcut:c,size:h,...a}=e,t[0]=e,t[1]=n,t[2]=i,t[3]=a,t[4]=c,t[5]=l,t[6]=u,t[7]=f,t[8]=m,t[9]=h);let g=l===void 0?`ghost`:l,_=u===void 0?I:u,v=f===void 0?`neutral`:f,y=m===void 0?`Toggle Sidebar`:m,b=h===void 0?`sm`:h,{isMobile:x,keyboardShortcut:S,navId:T,open:E,openMobile:D,toggle:O}=A(`Trigger`),k=r(),j=x?D:E,M=!x||D,N=S?c:void 0,P=k?`Meta+B`:`Control+B`,F=M?T:void 0,R=S?P:void 0,z;t[10]===n?z=t[11]:(z=o(n,`sidebar-trigger`),t[10]=n,t[11]=z);let B=j?`expanded`:`collapsed`,V;t[12]!==i||t[13]!==O?(V=e=>{i?.(e),e.defaultPrevented||O()},t[12]=i,t[13]=O,t[14]=V):V=t[14];let H;t[15]!==g||t[16]!==j||t[17]!==_||t[18]!==v||t[19]!==y||t[20]!==a||t[21]!==b||t[22]!==V||t[23]!==F||t[24]!==R||t[25]!==z||t[26]!==B?(H=/* @__PURE__ */ C(d.Trigger,{asChild:!0,children:/* @__PURE__ */ C(s,{appearance:g,"aria-controls":F,"aria-expanded":j,"aria-keyshortcuts":R,"data-slot":z,"data-state":B,icon:_,intent:v,label:y,onClick:V,size:b,...a})}),t[15]=g,t[16]=j,t[17]=_,t[18]=v,t[19]=y,t[20]=a,t[21]=b,t[22]=V,t[23]=F,t[24]=R,t[25]=z,t[26]=B,t[27]=H):H=t[27];let U;t[28]!==N||t[29]!==y?(U=/* @__PURE__ */ C(d.Content,{"data-slot":`sidebar-trigger-tooltip`,children:/* @__PURE__ */ C(L,{label:y,shortcut:N})}),t[28]=N,t[29]=y,t[30]=U):U=t[30];let W;return t[31]!==H||t[32]!==U?(W=/* @__PURE__ */ w(d.Root,{children:[H,U]}),t[31]=H,t[32]=U,t[33]=W):W=t[33],W},z=e=>{let t=p(16),n,r,i,s,c;t[0]===e?(n=t[1],r=t[2],i=t[3],s=t[4],c=t[5]):({asChild:n,children:r,className:i,"data-slot":s,...c}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=s,t[5]=c);let l=n?u:`div`,d;t[6]===s?d=t[7]:(d=o(s,`sidebar-header`),t[6]=s,t[7]=d);let f;t[8]===i?f=t[9]:(f=a(`grid grid-cols-1 grid-rows-(--sidebar-header-height,4.5rem) shrink-0 items-center px-3`,`group-data-[state=expanded]/sidebar-nav:pr-1`,i),t[8]=i,t[9]=f);let m;return t[10]!==l||t[11]!==r||t[12]!==c||t[13]!==d||t[14]!==f?(m=/* @__PURE__ */ C(l,{"data-slot":d,className:f,...c,children:r}),t[10]=l,t[11]=r,t[12]=c,t[13]=d,t[14]=f,t[15]=m):m=t[15],m},B=e=>{let t=p(16),n,r,i,s,c;t[0]===e?(n=t[1],r=t[2],i=t[3],s=t[4],c=t[5]):({asChild:n,children:r,className:i,"data-slot":s,...c}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=s,t[5]=c);let l=n?u:`div`,d;t[6]===s?d=t[7]:(d=o(s,`sidebar-body`),t[6]=s,t[7]=d);let f;t[8]===i?f=t[9]:(f=a(`scrollbar scrollbar-gutter-stable scroll-fade-y flex-1 scroll-py-6 space-y-2 overflow-y-auto overflow-x-hidden px-3 pt-1.5 pb-4`,`group-data-[state=expanded]/sidebar-nav:pr-1`,`transition-[padding]`,D,`group-data-[state=collapsed]/sidebar-nav:scrollbar-none`,`group-data-[state=collapsed]/sidebar-nav:scrollbar-gutter-auto`,`group-data-[state=collapsed]/sidebar-nav:[&::-webkit-scrollbar]:hidden`,i),t[8]=i,t[9]=f);let m;return t[10]!==l||t[11]!==r||t[12]!==c||t[13]!==d||t[14]!==f?(m=/* @__PURE__ */ C(l,{"data-slot":d,className:f,...c,children:r}),t[10]=l,t[11]=r,t[12]=c,t[13]=d,t[14]=f,t[15]=m):m=t[15],m},V=e=>{let t=p(16),n,r,i,s,c;t[0]===e?(n=t[1],r=t[2],i=t[3],s=t[4],c=t[5]):({asChild:n,children:r,className:i,"data-slot":s,...c}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=s,t[5]=c);let l=n?u:`div`,d;t[6]===s?d=t[7]:(d=o(s,`sidebar-footer`),t[6]=s,t[7]=d);let f;t[8]===i?f=t[9]:(f=a(`shrink-0 px-3 pt-3 pb-3.5`,`group-data-[state=expanded]/sidebar-nav:pr-1`,i),t[8]=i,t[9]=f);let m;return t[10]!==l||t[11]!==r||t[12]!==c||t[13]!==d||t[14]!==f?(m=/* @__PURE__ */ C(l,{"data-slot":d,className:f,...c,children:r}),t[10]=l,t[11]=r,t[12]=c,t[13]=d,t[14]=f,t[15]=m):m=t[15],m},H=m(null),U=e=>{let t=p(21),n,r,i,s,c;t[0]===e?(n=t[1],r=t[2],i=t[3],s=t[4],c=t[5]):({asChild:n,children:r,className:i,"data-slot":s,...c}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=s,t[5]=c);let[l,d]=b(null),f;t[6]===l?f=t[7]:(f={mountedLabelId:l,setMountedLabelId:d},t[6]=l,t[7]=f);let m=f,h=n?u:`div`,g;t[8]===s?g=t[9]:(g=o(s,`sidebar-group`),t[8]=s,t[9]=g);let _;t[10]===i?_=t[11]:(_=a(`pt-0.5`,i),t[10]=i,t[11]=_);let v;t[12]!==h||t[13]!==r||t[14]!==c||t[15]!==g||t[16]!==_?(v=/* @__PURE__ */ C(h,{"data-slot":g,className:_,...c,children:r}),t[12]=h,t[13]=r,t[14]=c,t[15]=g,t[16]=_,t[17]=v):v=t[17];let y;return t[18]!==m||t[19]!==v?(y=/* @__PURE__ */ C(H.Provider,{value:m,children:v}),t[18]=m,t[19]=v,t[20]=y):y=t[20],y},W=e=>{let t=p(22),n,r,i,s,c,l;t[0]===e?(n=t[1],r=t[2],i=t[3],s=t[4],c=t[5],l=t[6]):({asChild:n,children:r,className:i,"data-slot":s,id:c,...l}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=s,t[5]=c,t[6]=l);let d=h(H),f=_(),m=c??(d==null?void 0:f),v=d?.setMountedLabelId,y,b;t[7]!==m||t[8]!==v?(y=()=>{if(v!=null&&m!=null)return v(m),()=>{v(null)}},b=[v,m],t[7]=m,t[8]=v,t[9]=y,t[10]=b):(y=t[9],b=t[10]),g(y,b);let x=n?u:`div`,S;t[11]===s?S=t[12]:(S=o(s,`sidebar-group-label`),t[11]=s,t[12]=S);let w;t[13]===i?w=t[14]:(w=a(`text-muted flex min-w-0 items-center gap-2 truncate px-2 py-1 text-xs font-medium`,`group-data-[state=collapsed]/sidebar-nav:opacity-0`,`group-data-[state=collapsed]/sidebar-nav:pointer-events-none`,`transition-opacity`,D,i),t[13]=i,t[14]=w);let T;return t[15]!==x||t[16]!==r||t[17]!==m||t[18]!==l||t[19]!==S||t[20]!==w?(T=/* @__PURE__ */ C(x,{id:m,"data-slot":S,className:w,...l,children:r}),t[15]=x,t[16]=r,t[17]=m,t[18]=l,t[19]=S,t[20]=w,t[21]=T):T=t[21],T},G=e=>{let t=p(18),n,r,i,s,c,l;t[0]===e?(n=t[1],r=t[2],i=t[3],s=t[4],c=t[5],l=t[6]):({"aria-labelledby":n,asChild:r,children:i,className:s,"data-slot":c,...l}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=s,t[5]=c,t[6]=l);let d=h(H),f=r?u:`ul`,m=n??d?.mountedLabelId??void 0,g;t[7]===c?g=t[8]:(g=o(c,`sidebar-list`),t[7]=c,t[8]=g);let _;t[9]===s?_=t[10]:(_=a(`mb-2 space-y-px`,s),t[9]=s,t[10]=_);let v;return t[11]!==f||t[12]!==i||t[13]!==l||t[14]!==m||t[15]!==g||t[16]!==_?(v=/* @__PURE__ */ C(f,{"aria-labelledby":m,"data-slot":g,className:_,...l,children:i}),t[11]=f,t[12]=i,t[13]=l,t[14]=m,t[15]=g,t[16]=_,t[17]=v):v=t[17],v},K=e=>{let t=p(16),n,r,i,s,c;t[0]===e?(n=t[1],r=t[2],i=t[3],s=t[4],c=t[5]):({asChild:n,children:r,className:i,"data-slot":s,...c}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=s,t[5]=c);let l=n?u:`li`,d;t[6]===s?d=t[7]:(d=o(s,`sidebar-item`),t[6]=s,t[7]=d);let f;t[8]===i?f=t[9]:(f=a(`list-none`,i),t[8]=i,t[9]=f);let m;return t[10]!==l||t[11]!==r||t[12]!==c||t[13]!==d||t[14]!==f?(m=/* @__PURE__ */ C(l,{"data-slot":d,className:f,...c,children:r}),t[10]=l,t[11]=r,t[12]=c,t[13]=d,t[14]=f,t[15]=m):m=t[15],m},q=[`ring-focus-accent flex w-full min-w-0 items-center gap-2 truncate rounded-md px-2 py-1 text-left font-normal focus:outline-hidden focus-visible:ring-4`,`text-body hover:text-strong hover:bg-neutral-500/10`,`data-state-open:bg-neutral-500/15 data-state-open:text-strong`,`aria-expanded:bg-neutral-500/15 aria-expanded:text-strong`,`group-data-[state=collapsed]/sidebar-nav:ml-1`,`group-data-[state=collapsed]/sidebar-nav:w-7`,`group-data-[state=collapsed]/sidebar-nav:p-1`,`group-data-[state=collapsed]/sidebar-nav:text-clip`,`transition-[width,padding,margin] ${D}`].join(` `),J={Root:P,Nav:F,Trigger:R,Header:z,Body:B,Footer:V,Group:U,GroupLabel:W,List:G,Item:K,ItemButton:e=>{let t=p(21),n,r,i,s,c,l,d;t[0]===e?(n=t[1],r=t[2],i=t[3],s=t[4],c=t[5],l=t[6],d=t[7]):({asChild:n,children:r,className:i,current:s,"data-slot":c,type:d,...l}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=s,t[5]=c,t[6]=l,t[7]=d);let f=n?u:`button`,m;t[8]===c?m=t[9]:(m=o(c,`sidebar-item-button`),t[8]=c,t[9]=m);let h=s?``:void 0,g=s?`page`:void 0,_=n?d:d??`button`,v;t[10]===i?v=t[11]:(v=a(q,`data-current:bg-neutral-500/15 data-current:text-strong`,`aria-[current=page]:bg-neutral-500/15 aria-[current=page]:text-strong`,`[&>svg]:text-muted hover:[&>svg]:text-strong data-current:[&>svg]:text-strong aria-[current=page]:[&>svg]:text-strong [&>svg:first-child]:size-5 [&>svg]:shrink-0`,i),t[10]=i,t[11]=v);let y;return t[12]!==f||t[13]!==r||t[14]!==l||t[15]!==m||t[16]!==h||t[17]!==g||t[18]!==_||t[19]!==v?(y=/* @__PURE__ */ C(f,{"data-slot":m,"data-current":h,"aria-current":g,type:_,className:v,...l,children:r}),t[12]=f,t[13]=r,t[14]=l,t[15]=m,t[16]=h,t[17]=g,t[18]=_,t[19]=v,t[20]=y):y=t[20],y},SearchTrigger:e=>{let t=p(23),n,r,i,s,c,l,d;t[0]===e?(n=t[1],r=t[2],i=t[3],s=t[4],c=t[5],l=t[6],d=t[7]):({asChild:n,children:r,className:i,"data-slot":s,shortcut:l,type:d,...c}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=s,t[5]=c,t[6]=l,t[7]=d);let f=n?u:`button`,m;t[8]!==n||t[9]!==r||t[10]!==l?(m=n?r:/* @__PURE__ */ w(S,{children:[/* @__PURE__ */ C(`span`,{"data-slot":`sidebar-search-trigger-label`,className:`contents`,children:r}),/* @__PURE__ */ C(`span`,{"aria-hidden":!0,"data-slot":`sidebar-search-trigger-shortcut`,translate:`no`,className:a(`pointer-events-none -mr-1 ml-auto inline-flex shrink-0 items-center gap-0.5 opacity-0 select-none`,`group-hover:opacity-100 group-focus-visible:opacity-100`,`group-data-[state=collapsed]/sidebar-nav:hidden`,`[&_kbd]:text-body [&_kbd]:h-5 [&_kbd]:min-w-5 [&_kbd]:bg-neutral-500/20 [&_kbd]:px-1 [&_kbd]:text-xs [&_kbd]:font-normal`,`empty:hidden`),children:l})]}),t[8]=n,t[9]=r,t[10]=l,t[11]=m):m=t[11];let h=m,g;t[12]===s?g=t[13]:(g=o(s,`sidebar-search-trigger`),t[12]=s,t[13]=g);let _=n?d:d??`button`,v;t[14]===i?v=t[15]:(v=a(`group`,q,`[&>svg:first-child]:text-muted hover:[&>svg:first-child]:text-strong`,`[&>svg:first-child]:size-5`,`[&>[data-slot=sidebar-search-trigger-label]>svg:first-child]:text-muted`,`hover:[&>[data-slot=sidebar-search-trigger-label]>svg:first-child]:text-strong`,`[&>[data-slot=sidebar-search-trigger-label]>svg:first-child]:size-5`,`[&_svg]:shrink-0`,i),t[14]=i,t[15]=v);let y;return t[16]!==f||t[17]!==h||t[18]!==c||t[19]!==g||t[20]!==_||t[21]!==v?(y=/* @__PURE__ */ C(f,{"data-slot":g,type:_,className:v,...c,children:h}),t[16]=f,t[17]=h,t[18]=c,t[19]=g,t[20]=_,t[21]=v,t[22]=y):y=t[22],y},SwitcherTrigger:e=>{let t=p(18),n,r,i,s,c,l;t[0]===e?(n=t[1],r=t[2],i=t[3],s=t[4],c=t[5],l=t[6]):({asChild:n,children:r,className:i,"data-slot":s,type:l,...c}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=s,t[5]=c,t[6]=l);let d=n?u:`button`,f;t[7]===s?f=t[8]:(f=o(s,`sidebar-switcher-trigger`),t[7]=s,t[8]=f);let m=n?l:l??`button`,h;t[9]===i?h=t[10]:(h=a(`text-body hover:text-strong hover:bg-neutral-500/10 flex w-full min-w-0 items-center gap-2 rounded-[0.625rem] py-1 pr-1.5 pl-1 text-left font-medium`,`data-state-open:bg-neutral-500/15 data-state-open:text-strong`,`aria-expanded:bg-neutral-500/15 aria-expanded:text-strong`,`ring-focus-accent focus:outline-hidden focus-visible:ring-4`,`*:first:size-7`,`group-data-[state=collapsed]/sidebar-nav:w-9`,`group-data-[state=collapsed]/sidebar-nav:p-1`,`group-data-[state=collapsed]/sidebar-nav:[&>:not(:first-child)]:sr-only`,`transition-[width,padding]`,D,i),t[9]=i,t[10]=h);let g;return t[11]!==d||t[12]!==r||t[13]!==c||t[14]!==f||t[15]!==m||t[16]!==h?(g=/* @__PURE__ */ C(d,{"data-slot":f,type:m,className:h,...c,children:r}),t[11]=d,t[12]=r,t[13]=c,t[14]=f,t[15]=m,t[16]=h,t[17]=g):g=t[17],g},Tooltip:e=>{let t=p(26),n,r,i,a,s,c;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4],s=t[5],c=t[6]):({children:n,"data-slot":r,label:i,shortcut:s,side:c,...a}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a,t[5]=s,t[6]=c);let l=c===void 0?`right`:c,{isMobile:u,open:f}=A(`Tooltip`),m=!u&&!f,[h,g]=b(!1),[_,v]=b(m);_!==m&&(v(m),g(!1));let y;t[7]===m?y=t[8]:(y=e=>{g(e&&m)},t[7]=m,t[8]=y);let x=y,S=m&&h,T;t[9]===n?T=t[10]:(T=/* @__PURE__ */ C(d.Trigger,{asChild:!0,children:n}),t[9]=n,t[10]=T);let E;t[11]===r?E=t[12]:(E=o(r,`sidebar-tooltip`),t[11]=r,t[12]=E);let D;t[13]!==i||t[14]!==s?(D=/* @__PURE__ */ C(L,{label:i,shortcut:s}),t[13]=i,t[14]=s,t[15]=D):D=t[15];let O;t[16]!==a||t[17]!==l||t[18]!==E||t[19]!==D?(O=/* @__PURE__ */ C(d.Content,{"data-slot":E,side:l,...a,children:D}),t[16]=a,t[17]=l,t[18]=E,t[19]=D,t[20]=O):O=t[20];let k;return t[21]!==x||t[22]!==S||t[23]!==T||t[24]!==O?(k=/* @__PURE__ */ w(d.Root,{disableHoverableContent:!0,onOpenChange:x,open:S,children:[T,O]}),t[21]=x,t[22]=S,t[23]=T,t[24]=O,t[25]=k):k=t[25],k},Separator:e=>{let t=p(12),n,r,i;t[0]===e?(n=t[1],r=t[2],i=t[3]):({className:n,"data-slot":r,...i}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i);let s;t[4]===r?s=t[5]:(s=o(r,`sidebar-separator`),t[4]=r,t[5]=s);let l;t[6]===n?l=t[7]:(l=a(`my-3`,`group-data-[state=collapsed]/sidebar-nav:w-9`,`transition-[width]`,D,n),t[6]=n,t[7]=l);let u;return t[8]!==i||t[9]!==s||t[10]!==l?(u=/* @__PURE__ */ C(c,{"data-slot":s,className:l,...i}),t[8]=i,t[9]=s,t[10]=l,t[11]=u):u=t[11],u}},Y=`mantle-sidebar-state`,X={collapsed:`collapsed`,expanded:`expanded`};function Z(e){let t=f(e,Y);if(t===X.expanded)return!0;if(t===X.collapsed)return!1}function Q(e,t={}){let{domain:n,maxAge:r=31536e3,path:i=`/`,sameSite:a=`Lax`,secure:o=!1}=t,s=e?X.expanded:X.collapsed,c=[`${Y}=${s}`,`Max-Age=${r}`,`Path=${i}`];return n!=null&&c.push(`Domain=${n}`),c.push(`SameSite=${a}`),o&&c.push(`Secure`),c.join(`; `)}export{Y as SIDEBAR_STATE_COOKIE_NAME,J as Sidebar,Z as extractSidebarStateCookie,Q as serializeSidebarStateCookie,k as useSidebar};
1
+ import*as e from"./sidebar-parts.js";import{g as t}from"./sidebar-CsC9fyPL.js";import{n}from"./utils-ca4g5CKp.js";const r=`mantle-sidebar-state`,i={collapsed:`collapsed`,expanded:`expanded`};function a(e){let t=n(e,r);if(t===i.expanded)return!0;if(t===i.collapsed)return!1}function o(e,t={}){let{domain:n,maxAge:a=31536e3,path:o=`/`,sameSite:s=`Lax`,secure:c=!1}=t,l=e?i.expanded:i.collapsed,u=[`${r}=${l}`,`Max-Age=${a}`,`Path=${o}`];return n!=null&&u.push(`Domain=${n}`),u.push(`SameSite=${s}`),c&&u.push(`Secure`),u.join(`; `)}export{r as SIDEBAR_STATE_COOKIE_NAME,e as Sidebar,a as extractSidebarStateCookie,o as serializeSidebarStateCookie,t as useSidebar};
@@ -0,0 +1 @@
1
+ import{n as e}from"./cx-CfAFHj5_.js";import{t}from"./utils-EM6s2WEU.js";import{t as n}from"./slot-CBcGhRdV.js";import{jsx as r}from"react/jsx-runtime";const i=({"data-slot":i,asChild:a=!1,className:o,ref:s,...c})=>/* @__PURE__ */ r(a?n:`div`,{"data-slot":t(i,`skeleton`),"aria-hidden":!0,className:e(`h-4 animate-pulse rounded-md bg-gray-300/25 dark:bg-gray-950/10`,o),ref:s,...c});export{i as t};
@@ -3,9 +3,9 @@
3
3
  *
4
4
  * @see https://mantle.ngrok.com/components/feedback/skeleton
5
5
  */
6
- import { t as SelfClosingWithAsChild } from "./as-child-DFxX3U2i.js";
7
- import { t as WithDataSlot } from "./data-slot-B-LqAcBB.js";
8
6
  import { ComponentProps } from "react";
7
+ import { t as SelfClosingWithAsChild } from "./as-child-DFxX3U2i.js";
8
+ import { t as WithDataSlot } from "./data-slot-BW8KQ9Xo.js";
9
9
  type Props = Omit<ComponentProps<"div">, "children"> & SelfClosingWithAsChild & WithDataSlot;
10
10
  /**
11
11
  * A skeleton is a placeholder for content that is loading. By rendering a
@@ -19,14 +19,14 @@ type Props = Omit<ComponentProps<"div">, "children"> & SelfClosingWithAsChild &
19
19
  * - On initial page load, before data has resolved.
20
20
  *
21
21
  * **When not to use**
22
- * - For very short fetches (< 200 ms) — a flash of skeleton is more
22
+ * - For very short fetches (< 200 ms). A flash of skeleton is more
23
23
  * distracting than helpful.
24
24
  * - To convey error or empty states. Use {@link https://mantle.ngrok.com/components/feedback/empty Empty} instead.
25
25
  * - As a permanent decorative shape.
26
26
  *
27
27
  * **Sizing.** Default height is `1rem`. Override `className` with `h-*`,
28
- * `w-*`, and `rounded-*` utilities to match the real content's dimensions
29
- * — the more closely the skeleton matches, the less layout shift on swap.
28
+ * `w-*`, and `rounded-*` utilities to match the real content's dimensions.
29
+ * The more closely the skeleton matches, the less layout shift on swap.
30
30
  *
31
31
  * **Accessibility.** Skeletons are decorative and convey no semantic
32
32
  * meaning to assistive tech, so the element renders `aria-hidden="true"` by
package/dist/skeleton.js CHANGED
@@ -1 +1 @@
1
- export{t as Skeleton}from"./skeleton-DBpI-ko5.js";
1
+ export{t as Skeleton}from"./skeleton-DB0oQyAx.js";
@@ -0,0 +1 @@
1
+ "use client";import{t as e}from"./anchor-DW5_Gb-1.js";import{n as t}from"./cx-CfAFHj5_.js";import{t as n}from"./utils-EM6s2WEU.js";import{jsx as r}from"react/jsx-runtime";const i=({children:i=`Skip to main content`,className:a,"data-slot":o,onClick:s,targetId:c=`main`,...l})=>/* @__PURE__ */ r(e,{...l,"data-slot":n(o,`skip-to-main-link`),href:`#${c}`,onClick:e=>{e.preventDefault(),window.history.replaceState(null,``,`#${c}`),document.getElementById(c)?.focus(),s?.(e)},className:t(`not-focus:sr-only bg-card fixed top-2 left-2 z-max px-4 py-2 shadow-lg`,a),children:i});export{i as t};
@@ -3,8 +3,8 @@
3
3
  *
4
4
  * @see https://mantle.ngrok.com/components/primitives/skip-to-main-link
5
5
  */
6
- import { t as WithDataSlot } from "./data-slot-B-LqAcBB.js";
7
6
  import { ComponentProps } from "react";
7
+ import { t as WithDataSlot } from "./data-slot-BW8KQ9Xo.js";
8
8
  type SkipToMainLinkProps = Omit<ComponentProps<"a">, "href"> & WithDataSlot & {
9
9
  /**
10
10
  * The id of the target element to focus when the link is activated.
@@ -1 +1 @@
1
- import{t as e}from"./anchor-CgcbWEUs.js";import{t}from"./cx-CK7o_rVv.js";import{t as n}from"./data-slot-EM6s2WEU.js";import{c as r}from"react/compiler-runtime";import{jsx as i}from"react/jsx-runtime";const a=a=>{let o=r(21),s,c,l,u,d,f;o[0]===a?(s=o[1],c=o[2],l=o[3],u=o[4],d=o[5],f=o[6]):({children:d,className:s,"data-slot":c,onClick:l,targetId:f,...u}=a,o[0]=a,o[1]=s,o[2]=c,o[3]=l,o[4]=u,o[5]=d,o[6]=f);let p=d===void 0?`Skip to main content`:d,m=f===void 0?`main`:f,h;o[7]===c?h=o[8]:(h=n(c,`skip-to-main-link`),o[7]=c,o[8]=h);let g=`#${m}`,_;o[9]!==l||o[10]!==m?(_=e=>{e.preventDefault(),window.history.replaceState(null,``,`#${m}`),document.getElementById(m)?.focus(),l?.(e)},o[9]=l,o[10]=m,o[11]=_):_=o[11];let v;o[12]===s?v=o[13]:(v=t(`not-focus:sr-only bg-card fixed top-2 left-2 z-max px-4 py-2 shadow-lg`,s),o[12]=s,o[13]=v);let y;return o[14]!==p||o[15]!==u||o[16]!==h||o[17]!==g||o[18]!==_||o[19]!==v?(y=/* @__PURE__ */ i(e,{...u,"data-slot":h,href:g,onClick:_,className:v,children:p}),o[14]=p,o[15]=u,o[16]=h,o[17]=g,o[18]=_,o[19]=v,o[20]=y):y=o[20],y};export{a as SkipToMainLink};
1
+ export{t as SkipToMainLink}from"./skip-to-main-link-BGhAWSqB.js";
@@ -0,0 +1 @@
1
+ "use client";import{createContext as e,use as t,useState as n}from"react";import r from"tiny-invariant";import{t as i}from"./behaviors-CnarRd47.js";import{i as a,n as o,r as s,t as c}from"./behaviors-CcjvGa0d.js";import{t as l}from"./compose-refs-Ce1vWUz0.js";import{t as u}from"./types-D85fCNV3.js";import{t as d}from"./cx-DhYnQ07J.js";import{n as f,t as p}from"./cx-CfAFHj5_.js";import{t as m}from"./utils-EM6s2WEU.js";import{jsx as h,jsxs as g}from"react/jsx-runtime";function _({"data-slot":e,"aria-describedby":t,"aria-errormessage":r,"aria-invalid":p,"aria-label":_,"aria-labelledby":y,children:b,className:w,color:ee=`bg-accent-600`,defaultValue:T,formatValue:E,dir:D,disabled:O=!1,form:k,id:A,inverted:j=!1,max:M=100,min:N=0,minStepsBetweenThumbs:te=1,name:P,onKeyDown:ne,onPointerDown:re,onLostPointerCapture:F,onPointerMove:I,onValueChange:L,onValueCommit:R,orientation:z=`horizontal`,preserveThumbOrder:B=!1,ref:V,step:H=1,showTicks:U=!1,style:W,value:G,...K}){let q=G!==void 0,[J]=n(()=>x(T)??[N]),Y=x(G)??J,[ie]=n(()=>E&&J.map(E)),ae=q?E&&Y.map(E):ie,X=b!=null&&b!==!1,oe=l(V,s),{rootProps:Z,inputProps:se}=o({controlled:q,min:N,max:M,step:H,minStepsBetweenThumbs:te,preserveThumbOrder:B,orientation:z,inverted:j,dir:D,onValueChange:L,onValueCommit:R,formatValue:E}),Q=a(Y,N),$=S({showTicks:U,min:N,max:M,step:H}),ce=P!=null&&Y.length>1?`${P}[]`:P;return/* @__PURE__ */ g(`span`,{"data-slot":m(e,`slider`),"data-orientation":z,"data-disabled":O?``:void 0,dir:D,className:f($>0?X?`group/slider [--slider-thumb-size:--spacing(4.5)] relative flex w-full touch-none items-center select-none data-disabled:opacity-50 before:absolute before:top-1/2 before:left-1/2 before:-translate-1/2 before:size-[max(100%,--spacing(6))] pointer-coarse:before:size-[max(100%,--spacing(11))] data-disabled:before:pointer-events-none data-[orientation=vertical]:h-full data-[orientation=vertical]:min-h-40 data-[orientation=vertical]:w-auto data-[orientation=vertical]:flex-col mb-3 data-[orientation=horizontal]:@container`:`group/slider [--slider-thumb-size:--spacing(4.5)] relative flex w-full touch-none items-center select-none data-disabled:opacity-50 before:absolute before:top-1/2 before:left-1/2 before:-translate-1/2 before:size-[max(100%,--spacing(6))] pointer-coarse:before:size-[max(100%,--spacing(11))] data-disabled:before:pointer-events-none data-[orientation=vertical]:h-full data-[orientation=vertical]:min-h-40 data-[orientation=vertical]:w-auto data-[orientation=vertical]:flex-col mb-3`:X?`group/slider [--slider-thumb-size:--spacing(4.5)] relative flex w-full touch-none items-center select-none data-disabled:opacity-50 before:absolute before:top-1/2 before:left-1/2 before:-translate-1/2 before:size-[max(100%,--spacing(6))] pointer-coarse:before:size-[max(100%,--spacing(11))] data-disabled:before:pointer-events-none data-[orientation=vertical]:h-full data-[orientation=vertical]:min-h-40 data-[orientation=vertical]:w-auto data-[orientation=vertical]:flex-col data-[orientation=horizontal]:@container`:`group/slider [--slider-thumb-size:--spacing(4.5)] relative flex w-full touch-none items-center select-none data-disabled:opacity-50 before:absolute before:top-1/2 before:left-1/2 before:-translate-1/2 before:size-[max(100%,--spacing(6))] pointer-coarse:before:size-[max(100%,--spacing(11))] data-disabled:before:pointer-events-none data-[orientation=vertical]:h-full data-[orientation=vertical]:min-h-40 data-[orientation=vertical]:w-auto data-[orientation=vertical]:flex-col`,w),style:u({"--_min":N,"--_max":M,"--_inv":+!!j,...W}),...K,ref:oe,onKeyDown:i(ne,Z.onKeyDown),onPointerDown:i(re,Z.onPointerDown),onPointerMove:i(I,Z.onPointerMove),onLostPointerCapture:i(F,Z.onLostPointerCapture),children:[/* @__PURE__ */ h(`span`,{"data-slot":`slider-track`,className:`bg-neutral-300 rounded-full relative grow overflow-hidden h-1.5 w-full group-data-[orientation=vertical]/slider:h-full group-data-[orientation=vertical]/slider:w-1.5`,children:/* @__PURE__ */ h(`span`,{"data-slot":`slider-range`,className:d(`absolute h-full select-none group-data-[orientation=vertical]/slider:h-auto group-data-[orientation=vertical]/slider:w-full`,`[--_a:clamp(0,(var(--_start)_-_var(--_min))/(var(--_max)_-_var(--_min)),1)] [--_b:clamp(0,(var(--_end)_-_var(--_min))/(var(--_max)_-_var(--_min)),1)]`,`[--_s:calc(var(--_inv)_*_(1_-_var(--_b))_+_(1_-_var(--_inv))_*_var(--_a))] [--_e:calc(var(--_inv)_*_var(--_a)_+_(1_-_var(--_inv))_*_(1_-_var(--_b)))]`,`group-data-[orientation=horizontal]/slider:inset-s-[calc(var(--_s)*100%)] group-data-[orientation=horizontal]/slider:inset-e-[calc(var(--_e)*100%)]`,`group-data-[orientation=vertical]/slider:bottom-[calc(var(--_s)*100%)] group-data-[orientation=vertical]/slider:top-[calc(var(--_e)*100%)]`,`group-data-track-press/slider:motion-safe:transition-[inset-inline-start,inset-inline-end,top,bottom] group-data-track-press/slider:motion-safe:duration-200 group-data-track-press/slider:motion-safe:ease-out-strong`,ee),style:u(Q.range)})}),Y.map((e,n)=>/* @__PURE__ */ g(`span`,{"data-slot":`slider-thumb`,className:Y.length>1?`bg-static-white border-card size-(--slider-thumb-size) rounded-full border shadow-md hit-area absolute block shrink-0 cursor-pointer transition-[color,box-shadow] select-none [--_f:calc(var(--_inv)_+_(1_-_var(--_inv)_*_2)_*_clamp(0,(var(--_value)_-_var(--_min))/(var(--_max)_-_var(--_min)),1))] group-data-[orientation=horizontal]/slider:inset-s-[calc(var(--_f)*(100%-var(--slider-thumb-size)))] group-data-[orientation=vertical]/slider:bottom-[calc(var(--_f)*(100%-var(--slider-thumb-size)))] group-data-[orientation=horizontal]/slider:after:w-full group-data-[orientation=vertical]/slider:after:h-full has-focus-visible:ring-3 has-focus-visible:ring-accent-500/20 has-focus-visible:outline-hidden group-data-track-press/slider:motion-safe:transition-[color,box-shadow,inset-inline-start,bottom] group-data-track-press/slider:motion-safe:duration-200 group-data-track-press/slider:motion-safe:ease-out-strong group-data-disabled/slider:pointer-events-none group-data-disabled/slider:cursor-default`:`bg-static-white border-card size-(--slider-thumb-size) rounded-full border shadow-md hit-area absolute block shrink-0 cursor-pointer transition-[color,box-shadow] select-none [--_f:calc(var(--_inv)_+_(1_-_var(--_inv)_*_2)_*_clamp(0,(var(--_value)_-_var(--_min))/(var(--_max)_-_var(--_min)),1))] group-data-[orientation=horizontal]/slider:inset-s-[calc(var(--_f)*(100%-var(--slider-thumb-size)))] group-data-[orientation=vertical]/slider:bottom-[calc(var(--_f)*(100%-var(--slider-thumb-size)))] has-focus-visible:ring-3 has-focus-visible:ring-accent-500/20 has-focus-visible:outline-hidden group-data-track-press/slider:motion-safe:transition-[color,box-shadow,inset-inline-start,bottom] group-data-track-press/slider:motion-safe:duration-200 group-data-track-press/slider:motion-safe:ease-out-strong group-data-disabled/slider:pointer-events-none group-data-disabled/slider:cursor-default`,style:u(Q.thumbs[n]??{}),children:[/* @__PURE__ */ h(`input`,{type:`range`,"data-slot":`slider-input`,className:`absolute inset-0 z-1 m-0 size-full cursor-inherit appearance-none opacity-0 group-data-[orientation=vertical]/slider:[writing-mode:vertical-lr]`,"aria-describedby":t,"aria-errormessage":r,"aria-invalid":p,"aria-label":C({ariaLabel:_,index:n,thumbCount:Y.length}),"aria-labelledby":y,"aria-orientation":z,disabled:O,form:k,id:n===0?A:void 0,max:M,min:N,name:ce,step:c(Y[n]??N,{min:N,step:H})?H:`any`,...q?{value:Y[n]}:{defaultValue:Y[n]},"aria-valuetext":ae?.[n],onChange:se.onChange}),X&&/* @__PURE__ */ h(v,{value:n,children:b})]},n)),$>0&&/* @__PURE__ */ h(`div`,{"data-slot":`slider-ticks`,className:`absolute top-full mt-1.5 flex w-full justify-between px-[calc(var(--slider-thumb-size)/2)]`,"aria-hidden":`true`,children:Array.from({length:$},(e,t)=>/* @__PURE__ */ h(`span`,{"data-slot":`slider-tick`,className:`bg-card-border h-1.5 w-px`},t))}),X&&/* @__PURE__ */ h(v,{value:null,children:b})]})}const v=e(void 0);function y({"data-slot":e,className:n,placement:i=`thumb`,ref:a,...o}){let s=t(v),c=l(a,b);return r(s!==void 0,`SliderValue must be rendered inside a Slider.`),i===`thumb`==(s!=null)?/* @__PURE__ */ h(`span`,{"data-slot":m(e,`slider-value`),"data-placement":i,"aria-hidden":`true`,translate:`no`,className:p(`bg-tooltip text-tooltip pointer-events-none absolute z-2 w-max rounded-md px-2 py-1 text-xs font-sans whitespace-nowrap tabular-nums shadow select-none`,`[--_dir:1] rtl:[--_dir:-1]`,`scale-95 opacity-0 motion-safe:transition-[opacity,scale] motion-safe:duration-150 motion-safe:ease-out-strong`,`group-data-dragging/slider:scale-100 group-data-dragging/slider:opacity-100 group-data-dragging/slider:motion-safe:duration-200`,`group-data-track-press/slider:scale-100 group-data-track-press/slider:opacity-100 group-data-track-press/slider:motion-safe:duration-200`,i===`thumb`?[`group-data-[orientation=horizontal]/slider:inset-s-1/2 group-data-[orientation=horizontal]/slider:bottom-full group-data-[orientation=horizontal]/slider:mb-2 group-data-[orientation=horizontal]/slider:origin-bottom`,`group-data-[orientation=horizontal]/slider:[--_c:calc(var(--_f)*(100cqw-var(--slider-thumb-size))+var(--slider-thumb-size)/2)]`,`group-data-[orientation=horizontal]/slider:translate-x-[calc(var(--_dir)_*_clamp(-1_*_var(--_c),-50%,100cqw_-_var(--_c)_-_100%))]`,`group-data-[orientation=vertical]/slider:inset-e-full group-data-[orientation=vertical]/slider:top-1/2 group-data-[orientation=vertical]/slider:me-2 group-data-[orientation=vertical]/slider:-translate-y-1/2 group-data-[orientation=vertical]/slider:origin-right rtl:group-data-[orientation=vertical]/slider:origin-left`]:[`inset-s-1/2 origin-bottom translate-x-[calc(var(--_dir)*-50%)]`,`group-data-[orientation=horizontal]/slider:bottom-[calc(50%+var(--slider-thumb-size)/2+(--spacing(2)))]`,`group-data-[orientation=vertical]/slider:bottom-full group-data-[orientation=vertical]/slider:mb-2`],n),...o,ref:c}):null}function b(e){let t=e?.closest(`[data-slot~='slider']`),n=e?.dataset.placement===`track`?t:e?.closest(`[data-slot='slider-thumb']`);if(e==null||t==null||n==null)return;let r=()=>{let r=[...n===t?t.querySelectorAll(`:scope > [data-slot='slider-thumb']`):[n]].map(e=>e.querySelector(`input`)?.getAttribute(`aria-valuetext`)??e.style.getPropertyValue(`--_value`)).join(` – `);e.textContent!==r&&(e.textContent=r)};r();let i=new MutationObserver(r);return i.observe(n,{attributes:!0,attributeFilter:[`style`,`aria-valuetext`],subtree:!0}),()=>i.disconnect()}function x(e){if(e!=null)return Array.isArray(e)?e:[e]}function S({showTicks:e,min:t,max:n,step:r}){let i=n-t;return!e||!Number.isFinite(i)||!Number.isFinite(r)||r<=0||i<=0?0:Math.floor(i/r)+1}function C({ariaLabel:e,index:t,thumbCount:n}){if(e)return n===1?e:n===2?`${t===0?`Minimum`:`Maximum`} ${e}`:`${e} ${t+1} of ${n}`}export{y as n,_ as t};
package/dist/slider.d.ts CHANGED
@@ -3,16 +3,82 @@
3
3
  *
4
4
  * @see https://mantle.ngrok.com/components/forms/slider
5
5
  */
6
- import { t as WithDataSlot } from "./data-slot-B-LqAcBB.js";
7
- import { ComponentProps } from "react";
8
- import { Root } from "@radix-ui/react-slider";
9
- type SliderBaseProps = Omit<ComponentProps<typeof Root>, "defaultValue" | "value">;
6
+ import { ComponentProps, ReactNode } from "react";
7
+ import { t as WithDataSlot } from "./data-slot-BW8KQ9Xo.js";
8
+ type SliderBaseProps = Omit<ComponentProps<"span">, "defaultValue" | "dir" | "value"> & {
9
+ /**
10
+ * The text direction of the slider. When omitted, the slider follows the
11
+ * `direction` it inherits from the page.
12
+ */
13
+ dir?: "ltr" | "rtl";
14
+ /**
15
+ * When `true`, prevents the user from interacting with the slider. A disabled
16
+ * slider submits no value with its form.
17
+ * @default false
18
+ */
19
+ disabled?: boolean;
20
+ /**
21
+ * The `id` of the form the slider's inputs belong to, when the slider sits
22
+ * outside that form.
23
+ */
24
+ form?: string;
25
+ /**
26
+ * Whether the slider is visually inverted: `max` sits at the start of a
27
+ * horizontal track, or at the top of a vertical track.
28
+ * @default false
29
+ */
30
+ inverted?: boolean;
31
+ /**
32
+ * The maximum value.
33
+ * @default 100
34
+ */
35
+ max?: number;
36
+ /**
37
+ * The minimum value.
38
+ * @default 0
39
+ */
40
+ min?: number;
41
+ /**
42
+ * The fewest steps that must stay between two thumbs.
43
+ * @default 1
44
+ */
45
+ minStepsBetweenThumbs?: number;
46
+ /**
47
+ * The name that the slider's value submits under with its form. A slider with
48
+ * more than one thumb submits one value for each thumb under `name[]`.
49
+ */
50
+ name?: string;
51
+ /**
52
+ * Event handler called when the value changes.
53
+ */
54
+ onValueChange?: (value: number[]) => void;
55
+ /**
56
+ * Event handler called when the value changes at the end of an interaction:
57
+ * once for each key press, and when a drag that changed the value ends.
58
+ */
59
+ onValueCommit?: (value: number[]) => void;
60
+ /**
61
+ * The direction of the track.
62
+ * @default "horizontal"
63
+ */
64
+ orientation?: "horizontal" | "vertical";
65
+ /**
66
+ * Whether a thumb stops at its neighbor instead of passing it.
67
+ * @default false
68
+ */
69
+ preserveThumbOrder?: boolean;
70
+ /**
71
+ * The stepping interval.
72
+ * @default 1
73
+ */
74
+ step?: number;
75
+ };
10
76
  /**
11
77
  * Value props for the {@link Slider} component. Either both `defaultValue` and
12
78
  * `value` must be the same type (both `number` or both `number[]`), or only one
13
79
  * may be set.
14
80
  */
15
- type SliderValueProps = {
81
+ type SliderStateProps = {
16
82
  /**
17
83
  * The value of the slider when initially rendered. Use when you do not need
18
84
  * to control the state of the slider.
@@ -38,7 +104,7 @@ type SliderValueProps = {
38
104
  /**
39
105
  * Props for the {@link Slider} component.
40
106
  */
41
- type SliderProps = SliderBaseProps & SliderValueProps & {
107
+ type SliderProps = SliderBaseProps & SliderStateProps & {
42
108
  /**
43
109
  * The color of the slider range. Accepts any Tailwind `bg-*` class.
44
110
  * @default "bg-accent-600"
@@ -51,18 +117,46 @@ type SliderProps = SliderBaseProps & SliderValueProps & {
51
117
  * @default false
52
118
  */
53
119
  showTicks?: boolean;
120
+ /**
121
+ * The text of a value. It sets `aria-valuetext` on each thumb, and the text
122
+ * of each {@link SliderValue}. When omitted, a value reads as its number.
123
+ * An uncontrolled slider takes a new `formatValue` at its next change.
124
+ *
125
+ * @example
126
+ * ```tsx
127
+ * <Slider aria-label="Price" defaultValue={40} formatValue={(value) => `$${value}`} />
128
+ * ```
129
+ */
130
+ formatValue?: (value: number) => string;
131
+ /**
132
+ * Optional {@link SliderValue} parts, which show the value while a pointer
133
+ * drags a thumb. Pass nothing else.
134
+ */
135
+ children?: ReactNode;
54
136
  } & WithDataSlot;
55
137
  /**
56
138
  * An input where the user selects a value from within a given range.
57
139
  *
58
- * When composing with `Field.Item`, wrap `Slider` in `Field.Control`.
59
- * `Field.Control` flows `aria-invalid`, `aria-describedby`, and
60
- * `aria-errormessage` onto each thumb via `FieldControlContext`. Because
61
- * slider thumbs are ARIA slider widgets rather than native labelable controls,
62
- * pass `aria-label` or `aria-labelledby` to `Slider`; Mantle forwards those
63
- * labels to the rendered thumb(s). `aria-label` derives a distinct name per
64
- * thumb ("Minimum Price", "Maximum Price"). `aria-labelledby` names every
65
- * thumb with the same text, so prefer `aria-label` for a range slider.
140
+ * Each thumb is a native `<input type="range">`, so the server HTML already
141
+ * holds each thumb at its value, and assistive technology reads and sets it
142
+ * with no JavaScript. An uncontrolled slider keeps its values in the DOM and
143
+ * renders nothing while the user drags.
144
+ *
145
+ * `aria-invalid`, `aria-describedby`, and `aria-errormessage` go onto each
146
+ * thumb, and `id` onto the first thumb, so a `<label htmlFor>` focuses it.
147
+ * When composing with `Field.Item`, wrap `Slider` in `Field.Control`, which
148
+ * passes those props. Pass `aria-label` or `aria-labelledby` to `Slider`;
149
+ * Mantle forwards those labels to the rendered thumb(s). `aria-label` derives a
150
+ * distinct name per thumb ("Minimum Price", "Maximum Price"). `aria-labelledby`
151
+ * names every thumb with the same text, so prefer `aria-label` for a range
152
+ * slider.
153
+ *
154
+ * | Data Attribute | Value | Description |
155
+ * | ------------------ | ------------------------------ | ---------------------------------------------- |
156
+ * | `data-orientation` | `"horizontal"` \| `"vertical"` | On the root. Mirrors `orientation`. |
157
+ * | `data-disabled` | present when disabled | On the root. Presence-only. Style with `data-disabled:`. |
158
+ * | `data-track-press` | present during a glide | On the root while a thumb glides after a press on the track. Presence-only. |
159
+ * | `data-dragging` | present during a drag | On the root while a pointer drags a thumb. Presence-only. |
66
160
  *
67
161
  * @useWhen Pick a number, or a range between two numbers, with a thumb that moves along a track.
68
162
  *
@@ -104,5 +198,45 @@ type SliderProps = SliderBaseProps & SliderValueProps & {
104
198
  * />
105
199
  * ```
106
200
  */
107
- declare function Slider({ "data-slot": dataSlot, "aria-describedby": ariaDescribedBy, "aria-errormessage": ariaErrorMessage, "aria-invalid": ariaInvalid, "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, className, color, defaultValue, id, max, min, minStepsBetweenThumbs, name, step, showTicks, value, ...props }: SliderProps): import("react").JSX.Element;
108
- export { Slider, type SliderProps };
201
+ declare function Slider({ "data-slot": dataSlot, "aria-describedby": ariaDescribedBy, "aria-errormessage": ariaErrorMessage, "aria-invalid": ariaInvalid, "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, children, className, color, defaultValue, formatValue, dir, disabled, form, id, inverted, max, min, minStepsBetweenThumbs, name, onKeyDown, onPointerDown, onLostPointerCapture, onPointerMove, onValueChange, onValueCommit, orientation, preserveThumbOrder, ref, step, showTicks, style, value, ...props }: SliderProps): import("react").JSX.Element;
202
+ /**
203
+ * Props for the {@link SliderValue} component.
204
+ */
205
+ type SliderValueProps = Omit<ComponentProps<"span">, "children"> & {
206
+ /**
207
+ * Where the value shows: above each thumb, which it follows, or once above
208
+ * the center of the track, with every value of a range.
209
+ * @default "thumb"
210
+ */
211
+ placement?: "thumb" | "track";
212
+ } & WithDataSlot;
213
+ /**
214
+ * The value of a {@link Slider}, in a small label that shows while a pointer or
215
+ * a finger drags a thumb, and while a thumb glides to a press on the track. It
216
+ * hides at rest and under keyboard focus. Place it as a child of `Slider`.
217
+ *
218
+ * Why not on keyboard focus: a sighted keyboard user sees the thumb move and the
219
+ * focus ring, and a label on each focus covers content as the user tabs through
220
+ * a form. A screen reader reads the value from the thumb, with `formatValue` as
221
+ * `aria-valuetext`, so the label stays out of the accessibility tree.
222
+ *
223
+ * CSS places the label from the thumb's value. With `placement="thumb"`, it
224
+ * stays inside the slider's width at each end. A vertical slider shows it beside
225
+ * each thumb, toward the start of the line, so leave room there.
226
+ *
227
+ * `Slider` renders its children once in each thumb and once above the track, so
228
+ * a `ref` on `SliderValue` reaches the last label that renders.
229
+ *
230
+ * | Data Attribute | Value | Description |
231
+ * | ----------------- | ------------------- | --------------------------------------------------------- |
232
+ * | `data-placement` | `"thumb"` \| `"track"` | Mirrors `placement`. |
233
+ *
234
+ * @example
235
+ * ```tsx
236
+ * <Slider aria-label="Volume" defaultValue={40} formatValue={(value) => `${value}%`}>
237
+ * <SliderValue />
238
+ * </Slider>
239
+ * ```
240
+ */
241
+ declare function SliderValue({ "data-slot": dataSlot, className, placement, ref, ...props }: SliderValueProps): import("react").JSX.Element | null;
242
+ export { Slider, type SliderProps, SliderValue, type SliderValueProps };
package/dist/slider.js CHANGED
@@ -1 +1 @@
1
- import{t as e}from"./cx-CK7o_rVv.js";import{t}from"./data-slot-EM6s2WEU.js";import{t as n}from"./field-Bihblt8U.js";import{c as r}from"react/compiler-runtime";import{useContext as i}from"react";import{jsx as a,jsxs as o}from"react/jsx-runtime";import{Range as s,Root as c,Thumb as l,Track as u}from"@radix-ui/react-slider";function d(d){let g=r(55),_,v,y,b,x,S,C,w,T,E,D,O,k,A,j,M,N,P;g[0]===d?(_=g[1],v=g[2],y=g[3],b=g[4],x=g[5],S=g[6],C=g[7],w=g[8],T=g[9],E=g[10],D=g[11],O=g[12],k=g[13],A=g[14],j=g[15],M=g[16],N=g[17],P=g[18]):({"data-slot":C,"aria-describedby":_,"aria-errormessage":v,"aria-invalid":y,"aria-label":b,"aria-labelledby":x,className:S,color:O,defaultValue:w,id:T,max:k,min:A,minStepsBetweenThumbs:j,name:E,step:M,showTicks:N,value:P,...D}=d,g[0]=d,g[1]=_,g[2]=v,g[3]=y,g[4]=b,g[5]=x,g[6]=S,g[7]=C,g[8]=w,g[9]=T,g[10]=E,g[11]=D,g[12]=O,g[13]=k,g[14]=A,g[15]=j,g[16]=M,g[17]=N,g[18]=P);let F=O===void 0?`bg-accent-600`:O,I=k===void 0?100:k,L=A===void 0?0:A,R=j===void 0?1:j,z=M===void 0?1:M,B=N!==void 0&&N,V=i(n),H;if(g[19]!==_||g[20]!==v||g[21]!==y||g[22]!==b||g[23]!==x||g[24]!==S||g[25]!==F||g[26]!==C||g[27]!==w||g[28]!==V||g[29]!==T||g[30]!==I||g[31]!==L||g[32]!==R||g[33]!==E||g[34]!==D||g[35]!==B||g[36]!==z||g[37]!==P){let n=p(P),r=p(w),i=n??r??[L],d=m({showTicks:B,min:L,max:I,step:z}),O;g[39]===C?O=g[40]:(O=t(C,`slider`),g[39]=C,g[40]=O);let k;g[41]!==_||g[42]!==v||g[43]!==y||g[44]!==V||g[45]!==T?(k=V?{}:{"aria-describedby":_,"aria-errormessage":v,"aria-invalid":y,id:T},g[41]=_,g[42]=v,g[43]=y,g[44]=V,g[45]=T,g[46]=k):k=g[46];let A=d>0&&`mb-3`,j;g[47]!==S||g[48]!==A?(j=e(`[--slider-thumb-size:--spacing(4.5)]`,`data-orientation-vertical:min-h-40 relative flex w-full touch-none items-center select-none data-disabled:opacity-50 data-orientation-vertical:h-full data-orientation-vertical:w-auto data-orientation-vertical:flex-col`,A,S),g[47]=S,g[48]=A,g[49]=j):j=g[49];let M;g[50]===Symbol.for(`react.memo_cache_sentinel`)?(M=e(`bg-neutral-300 rounded-full relative grow overflow-hidden`,`data-orientation-horizontal:h-1.5 data-orientation-horizontal:w-full`,`data-orientation-vertical:w-1.5 data-orientation-vertical:h-full`),g[50]=M):M=g[50];let N;g[51]===F?N=g[52]:(N=e(`absolute select-none data-orientation-horizontal:h-full data-orientation-vertical:w-full`,F),g[51]=F,g[52]=N);let U;g[53]===N?U=g[54]:(U=/* @__PURE__ */ a(u,{"data-slot":`slider-track`,className:M,children:/* @__PURE__ */ a(s,{"data-slot":`slider-range`,className:N})}),g[53]=N,g[54]=U),H=/* @__PURE__ */ o(c,{"data-slot":O,defaultValue:r,value:n,...k,min:L,minStepsBetweenThumbs:R,max:I,name:E,step:z,className:j,...D,children:[U,Array.from({length:i.length},(t,n)=>/* @__PURE__ */ a(l,{"data-slot":`slider-thumb`,"aria-describedby":V?.[`aria-describedby`]??_,"aria-errormessage":V?.[`aria-errormessage`]??v,"aria-invalid":V?.[`aria-invalid`]??y,"aria-label":h({ariaLabel:b,index:n,thumbCount:i.length}),"aria-labelledby":x,id:n===0?V?.id:void 0,className:e(`bg-static-white border-card relative size-(--slider-thumb-size) rounded-full border`,`shadow-md transition-[color,box-shadow]`,`after:absolute after:-inset-2`,`focus-visible:ring-3 focus-visible:ring-accent-500/20 focus-visible:outline-hidden`,`block shrink-0 cursor-pointer select-none`,`data-disabled:pointer-events-none data-disabled:cursor-default`)},n)),d>0&&/* @__PURE__ */ a(`div`,{"data-slot":`slider-ticks`,className:`absolute top-full mt-1.5 flex w-full justify-between px-[calc(var(--slider-thumb-size)/2)]`,"aria-hidden":`true`,children:Array.from({length:d},f)})]}),g[19]=_,g[20]=v,g[21]=y,g[22]=b,g[23]=x,g[24]=S,g[25]=F,g[26]=C,g[27]=w,g[28]=V,g[29]=T,g[30]=I,g[31]=L,g[32]=R,g[33]=E,g[34]=D,g[35]=B,g[36]=z,g[37]=P,g[38]=H}else H=g[38];return H}function f(e,t){return/* @__PURE__ */ a(`span`,{"data-slot":`slider-tick`,className:`bg-card-border h-1.5 w-px`},t)}function p(e){if(e!=null)return Array.isArray(e)?e:[e]}function m({showTicks:e,min:t,max:n,step:r}){let i=n-t;return!e||!Number.isFinite(i)||!Number.isFinite(r)||r<=0||i<=0?0:Math.floor(i/r)+1}function h({ariaLabel:e,index:t,thumbCount:n}){if(e)return n===1?e:n===2?`${t===0?`Minimum`:`Maximum`} ${e}`:`${e} ${t+1} of ${n}`}export{d as Slider};
1
+ export{t as Slider,n as SliderValue}from"./slider-YlBozcPQ.js";
@@ -0,0 +1,19 @@
1
+ import { HTMLAttributes, ReactElement, ReactNode, RefCallback } from "react";
2
+ import "./use-listbox-D4uIonSN.js";
3
+ /** The props a function child spreads on its element: the option's final props and a callback ref. */
4
+ type OptionRenderProps = HTMLAttributes<HTMLElement> & {
5
+ ref: RefCallback<HTMLElement>;
6
+ };
7
+ /** The state a listbox option reports to its function child. */
8
+ type OptionState = {
9
+ /** Whether the option has virtual focus: the pointer or the arrow keys are on it. */
10
+ highlighted: boolean;
11
+ };
12
+ /**
13
+ * A function child of a listbox option. It gets the option's props and state
14
+ * and returns the one element the option renders as. Spread `props` on it.
15
+ */
16
+ type OptionRender = (props: OptionRenderProps, state: OptionState) => ReactElement<{
17
+ children?: ReactNode;
18
+ }>;
19
+ export { OptionRender as t };
@@ -0,0 +1 @@
1
+ "use client";import{s as e}from"./behaviors-Mkc_HjTB.js";import{t}from"./compose-refs-Ce1vWUz0.js";import{n}from"./slot-CBcGhRdV.js";const r=({listbox:r,ref:i,render:a,renderContent:o,...s})=>{let c=e(r.getStore(),e=>e.activeId===s.id),l=t(i,void 0),u=a({...s,ref:l},{highlighted:c});return o==null?u:n(u,o)};export{r as t};
@@ -0,0 +1 @@
1
+ import{Children as e,Fragment as t,cloneElement as n,isValidElement as r}from"react";import{t as i}from"./cx-CfAFHj5_.js";import{t as a}from"./utils-EM6s2WEU.js";const o=(e,t)=>/^on[A-Z]/.test(e)&&typeof t==`function`,s=(e,t)=>{let n=new Set(`${e??``} ${t??``}`.split(/\s+/).filter(Boolean));return n.size>0?[...n].join(` `):void 0},c=(e,t)=>{if(typeof e==`function`){let n=e(t);return typeof n==`function`?n:void 0}e!=null&&(e.current=t)},l=/* @__PURE__ */ new WeakMap,u=(e,t)=>{if(e==null||t==null)return e??t;let n=l.get(e);n??(n=/* @__PURE__ */ new WeakMap,l.set(e,n));let r=n.get(t);if(r!=null)return r;let i=n=>{let r=[c(e,n),c(t,n)];return()=>{for(let[n,i]of r.entries())i==null?c(n===0?e:t,null):i()}};return n.set(t,i),i},d=(e,t)=>(...n)=>{let r=e(...n);return t(...n),r};function f(e,t){return typeof t==`function`?(...n)=>i(e,t(...n)):i(e,t)}function p(e,t){return typeof t==`function`?(...n)=>({...e,...t(...n)}):e==null?t:t==null?e:{...e,...t}}const m=({children:i,className:c,"data-slot":l,ref:m,style:h,...g})=>{let _=r(i)?i:null;if(_==null)return e.only(i);let v={...g};for(let[e,t]of Object.entries(_.props)){let n=v[e];o(e,t)&&o(e,n)?v[e]=d(t,n):/^on[A-Z]/.test(e)&&t==null||(v[e]=t)}let y={className:f(c,_.props.className),style:p(h,_.props.style),"aria-describedby":s(_.props[`aria-describedby`],g[`aria-describedby`]),"data-slot":a(l,_.props[`data-slot`]),ref:_.type===t?void 0:u(m,_.props.ref)};for(let[e,t]of Object.entries(y))t===void 0||t===``?delete v[e]:v[e]=t;return n(_,v)},h=(e,t)=>r(e)?n(e,void 0,t(e.props.children)):e;export{h as n,m as t};
@@ -0,0 +1,50 @@
1
+ import { HTMLAttributes, ReactNode, Ref } from "react";
2
+ import { t as WithStyleProps } from "./with-style-props-CuT30s0W.js";
3
+ import { t as WithDataSlot } from "./data-slot-BW8KQ9Xo.js";
4
+ /**
5
+ * `Slot`'s own `className` and `style` stay plain values. A render prop is only
6
+ * meaningful on the child that knows how to call it, so accepting one here would
7
+ * admit a value nothing ever resolves.
8
+ */
9
+ type Props = Omit<HTMLAttributes<HTMLElement>, "className" | "style"> & WithDataSlot & WithStyleProps & {
10
+ children?: ReactNode;
11
+ ref?: Ref<HTMLElement>;
12
+ };
13
+ /**
14
+ * Merges its props onto its immediate child. This is useful for creating
15
+ * components that can be rendered as different elements. Automatically merges
16
+ * className props using `cx` for proper Tailwind class handling, and
17
+ * concatenates `data-slot` values in DOM order (the composing parent's slot
18
+ * chain first, then the child's own) so `asChild` composition accumulates the
19
+ * whole slot chain instead of one side clobbering the other.
20
+ *
21
+ * A child that resolves its own `className` or `style` from state only it knows
22
+ * (react-router's `NavLink`, whose `className` may be `({ isActive }) => …`) keeps
23
+ * that behavior: the merge composes a function of the same shape, which forwards
24
+ * the child's arguments to the child's function and merges the resolved value with
25
+ * the slot's classes or style. `Slot` never calls it, so it needs to know nothing
26
+ * about the arguments:
27
+ *
28
+ * ```tsx
29
+ * <Sidebar.ItemButton asChild>
30
+ * <NavLink className={({ isActive }) => (isActive ? "font-medium" : undefined)} to="/endpoints">
31
+ * Endpoints
32
+ * </NavLink>
33
+ * </Sidebar.ItemButton>
34
+ * ```
35
+ *
36
+ * A function `children` is forwarded to the child as-is.
37
+ *
38
+ * @useWhen Merge the props of a part onto its one child element, to build an `asChild` prop.
39
+ *
40
+ * @see https://mantle.ngrok.com/components/primitives/slot
41
+ *
42
+ * @example
43
+ * ```tsx
44
+ * <Slot className="custom-class">
45
+ * <a href="/">Home</a>
46
+ * </Slot>
47
+ * ```
48
+ */
49
+ declare const Slot: ({ children, className, "data-slot": dataSlot, ref, style, ...props }: Props) => ReactNode;
50
+ export { Slot as t };
package/dist/slot.d.ts CHANGED
@@ -3,5 +3,5 @@
3
3
  *
4
4
  * @see https://mantle.ngrok.com/components/primitives/slot
5
5
  */
6
- import { t as Slot } from "./slot-D12N_fZJ.js";
6
+ import { t as Slot } from "./slot-tuk2J6bY.js";
7
7
  export { Slot };
package/dist/slot.js CHANGED
@@ -1 +1 @@
1
- export{t as Slot}from"./slot-DdYN1L1C.js";
1
+ export{t as Slot}from"./slot-CBcGhRdV.js";
@@ -5,8 +5,12 @@
5
5
  * dist files for utility class names. This is the supported way to register
6
6
  * mantle's Tailwind sources.
7
7
  *
8
+ * The glob scans only the JavaScript. The `.d.ts`, `agent.json`, `llms.txt`, and
9
+ * migration files hold JSDoc examples, so a scan of them emits CSS that no
10
+ * component renders.
11
+ *
8
12
  * Usage:
9
13
  * @import "@ngrok/mantle/mantle.css";
10
14
  * @import "@ngrok/mantle/source-all.css";
11
15
  */
12
- @source "../dist";
16
+ @source "../dist/*.js";
@@ -0,0 +1 @@
1
+ "use client";import{t as e}from"./CaretDown-MgTrjdYK.js";import{createContext as t,useContext as n,useMemo as r}from"react";import{n as i}from"./cx-CfAFHj5_.js";import{t as a}from"./utils-EM6s2WEU.js";import{t as o}from"./button-DhoE-BbZ.js";import{t as s}from"./button-Bqm7U0OC.js";import{a as c,l,m as u,n as d}from"./dropdown-menu-BuluRn0Z.js";import{t as f}from"./icon-BSGMvJ0W.js";import{jsx as p}from"react/jsx-runtime";const m=t({size:`md`}),h=({"data-slot":e,className:t,children:n,dir:o,open:s,defaultOpen:c,onOpenChange:u,modal:d,size:f=`md`,ref:h,...g})=>{let _=r(()=>({size:f}),[f]);return/* @__PURE__ */ p(l,{dir:o,open:s,defaultOpen:c,onOpenChange:u,modal:d,children:/* @__PURE__ */ p(m.Provider,{value:_,children:/* @__PURE__ */ p(`div`,{"data-slot":a(e,`split-button`),"data-size":f,className:i(`flex flex-row [&>*:first-child]:rounded-r-none [&>*:last-child]:rounded-l-none [&>*:not(:first-child):not(:last-child)]:rounded-none [&>*:not(:first-child)]:-ml-px [&>*:focus]:relative [&>*:focus]:z-10 [&>*:hover]:relative [&>*:hover]:z-10 [&>:active]:scale-100!`,t),ref:h,...g,children:n})})})},g=({"data-slot":e,...t})=>{let{size:r}=n(m);return/* @__PURE__ */ p(o,{appearance:`outlined`,intent:`neutral`,size:r,"data-slot":a(e,`split-button-primary-action`),...t})},_=({"data-slot":t,icon:r,...i})=>{let{size:o}=n(m);return/* @__PURE__ */ p(u,{asChild:!0,className:`group`,"data-slot":a(t,`split-button-menu-trigger`),children:/* @__PURE__ */ p(s,{icon:r??/* @__PURE__ */ p(f,{svg:/* @__PURE__ */ p(e,{weight:`bold`,className:`size-4 group-aria-expanded:-rotate-180 transition-transform duration-200 ease-out-strong motion-reduce:transition-none`})}),appearance:`outlined`,intent:`neutral`,size:o,...i})})},v=({align:e=`end`,"data-slot":t,...n})=>/* @__PURE__ */ p(d,{align:e,"data-slot":a(t,`split-button-menu-content`),...n}),y=({className:e,"data-slot":t,...n})=>/* @__PURE__ */ p(c,{className:i(`gap-2`,e),"data-slot":a(t,`split-button-menu-item`),...n});export{h as a,g as i,y as n,_ as r,v as t};