@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
@@ -1 +1 @@
1
- import{t as e}from"./use-prefers-reduced-motion-CU6mWmOe.js";import{t}from"./cx-CK7o_rVv.js";import{t as n}from"./data-slot-EM6s2WEU.js";import{t as r}from"./button-Cu9e3SM7.js";import{t as i}from"./button-BWGUuWnu.js";import{t as a}from"./icons-CDLz5lpI.js";import{n as o}from"./sandboxed-on-click-C7pPu-2M.js";import{t as s}from"./table-CFHiDBW8.js";import{c}from"react/compiler-runtime";import{Fragment as l,createContext as u,useContext as d,useEffect as f,useRef as p,useState as m}from"react";import h from"tiny-invariant";import{Fragment as g,jsx as _,jsxs as v}from"react/jsx-runtime";import{Subscribe as y,callMemoOrStaticFn as b,flexRender as x}from"@tanstack/react-table";import{MinusIcon as S}from"@phosphor-icons/react/Minus";import{PlusIcon as C}from"@phosphor-icons/react/Plus";import{column_getIsSorted as w,row_getIsExpanded as T,row_getVisibleCells as E,table_getVisibleLeafColumns as D}from"@tanstack/react-table/static-functions";export*from"@tanstack/react-table";const O=[`unsorted`,`asc`,`desc`],k=[`unsorted`,`desc`,`asc`];function A(e,t){return j(t===`alphanumeric`?O:k,e)??`unsorted`}function j(e,t,n){if(e.length===0)return n;let r=e.findIndex(e=>e===t);if(r===-1)return n;let i=(r+1)%e.length;return e.at(i)??n}function M(e){if(typeof e==`object`&&e&&`width`in e)return e.width===`fit`?`fit`:void 0}const N=u(null);function P(){return d(N)?.table.options}function F(){let e=d(N);return h(e,`useDataTableContext should only be used within a DataTable child component`),e}const I=u(null),L=/* @__PURE__ */ new Set;function R(e){return[...e.querySelectorAll(`:scope > tr`)]}function ee(e){let[,t=`0px`]=getComputedStyle(e).translate.split(` `);return e.offsetTop+(Number.parseFloat(t)||0)}function te(e,t,n){let r=/* @__PURE__ */ new Map,i=0,a=0;for(let o of R(e)){o.hasAttribute(`data-closing`)?a+=o.offsetHeight:(i+=a,a=0);let e=-i,s=t.get(o),c=s==null||Math.abs(s-o.offsetTop-e)<.5?e:s-o.offsetTop;r.set(o,o.offsetTop+e);let l=n.get(o);if(c!==e||(l?.to??0)!==e){if(n.delete(o),c!==e||e!==0){let t=o.animate([{translate:`0 ${c}px`},{translate:`0 ${e}px`}],{duration:c===e?0:200,easing:`cubic-bezier(0.23, 1, 0.32, 1)`,fill:e===0?`none`:`forwards`});n.set(o,{animation:t,to:e})}l?.animation.cancel()}}return r}function ne(){let t=c(14),[n,r]=m(L),i;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(i=/* @__PURE__ */ new Map,t[0]=i):i=t[0];let a=p(i),o;t[1]===Symbol.for(`react.memo_cache_sentinel`)?(o=/* @__PURE__ */ new Map,t[1]=o):o=t[1];let s=p(o),l;t[2]===Symbol.for(`react.memo_cache_sentinel`)?(l=/* @__PURE__ */ new WeakMap,t[2]=l):l=t[2];let u=p(l),d,h;t[3]===Symbol.for(`react.memo_cache_sentinel`)?(d=()=>{let e=a.current,t=s.current;return()=>{for(let{timer:t}of e.values())clearTimeout(t);for(let{observer:e}of t.values())e.disconnect()}},h=[],t[3]=d,t[4]=h):(d=t[3],h=t[4]),f(d,h);let g;t[5]===Symbol.for(`react.memo_cache_sentinel`)?(g=e=>{r(t=>{if(!t.has(e))return t;let n=new Set(t);return n.delete(e),n})},t[5]=g):g=t[5];let _=g,v;t[6]===Symbol.for(`react.memo_cache_sentinel`)?(v=e=>{let t=s.current.get(e);if(t!=null&&t.before==null){for(let t of a.current.values())if(t.body===e)return;t.observer.disconnect(),s.current.delete(e)}},t[6]=v):v=t[6];let y=v,b;t[7]===Symbol.for(`react.memo_cache_sentinel`)?(b=(e,t)=>{let n=s.current.get(e),r=t.filter(t=>t.type===`childList`?t.target===e:t.target.parentNode===e);if(n==null||r.length===0)return;let i=n.awaiting==null?null:a.current.get(n.awaiting);for(let e of r){let{target:t}=e;i!=null&&e.type===`attributes`&&t instanceof Element&&t.hasAttribute(`data-closing`)&&i.rows.add(t)}i!=null&&i.rows.size>0&&(n.awaiting=null);for(let[t,n]of a.current)n.body===e&&n.rows.size>0&&![...n.rows].some(ie)&&(clearTimeout(n.timer),a.current.delete(t),_(t));let o=n.before??n.rest;n.before=null,n.rest=te(e,o,u.current),y(e)},t[7]=b):b=t[7];let x=b,S;t[8]===Symbol.for(`react.memo_cache_sentinel`)?(S=e=>{let t=s.current.get(e);if(t==null){let n=new MutationObserver(t=>x(e,t));n.observe(e,{attributeFilter:[`data-closing`],childList:!0,subtree:!0}),t={observer:n,before:null,rest:/* @__PURE__ */ new Map,awaiting:null},s.current.set(e,t)}if(t.before==null){let n=new Map(R(e).map(re));t.before=n;let r=t;requestAnimationFrame(()=>{r.before===n&&(r.before=null,y(e))})}return t},t[8]=S):S=t[8];let C=S,w;t[9]===Symbol.for(`react.memo_cache_sentinel`)?(w=(t,n)=>{t!=null&&!e()&&C(t),n()},t[9]=w):w=t[9];let T=w,E;t[10]===Symbol.for(`react.memo_cache_sentinel`)?(E=e=>{let t=a.current.get(e);t!=null&&(clearTimeout(t.timer),a.current.delete(e),C(t.body)),_(e)},t[10]=E):E=t[10];let D=E,O;t[11]===Symbol.for(`react.memo_cache_sentinel`)?(O=(t,n,i)=>{n==null||e()?i():(D(t),C(n).awaiting=t,a.current.set(t,{body:n,rows:/* @__PURE__ */ new Set,timer:setTimeout(()=>{a.current.delete(t),C(n),_(t),i()},200)}),r(e=>new Set(e).add(t)))},t[11]=O):O=t[11];let k=O,A;return t[12]===n?A=t[13]:(A={closingRowIds:n,startExpand:T,startCollapse:k,cancelCollapse:D},t[12]=n,t[13]=A),A}function re(e){return[e,ee(e)]}function ie(e){return e.isConnected}function ae(e){let t=c(21),r,i,a,o;t[0]===e?(r=t[1],i=t[2],a=t[3],o=t[4]):({"data-slot":i,children:r,table:o,...a}=e,t[0]=e,t[1]=r,t[2]=i,t[3]=a,t[4]=o);let l;t[5]===o?l=t[6]:(l={table:o},t[5]=o,t[6]=l);let u=l,d=ne(),f;t[7]===i?f=t[8]:(f=n(i,`data-table`),t[7]=i,t[8]=f);let p;t[9]===r?p=t[10]:(p=/* @__PURE__ */ _(s.Element,{children:r}),t[9]=r,t[10]=p);let m;t[11]!==a||t[12]!==f||t[13]!==p?(m=/* @__PURE__ */ _(s.Root,{"data-slot":f,...a,children:p}),t[11]=a,t[12]=f,t[13]=p,t[14]=m):m=t[14];let h;t[15]!==d||t[16]!==m?(h=/* @__PURE__ */ _(I.Provider,{value:d,children:m}),t[15]=d,t[16]=m,t[17]=h):h=t[17];let g;return t[18]!==u||t[19]!==h?(g=/* @__PURE__ */ _(N.Provider,{value:u,children:h}),t[18]=u,t[19]=h,t[20]=g):g=t[20],g}function oe(e){let i=c(33),a,o,s,l,u,d,f,p,m,h,g,v;i[0]===e?(a=i[1],o=i[2],s=i[3],l=i[4],u=i[5],d=i[6],f=i[7],p=i[8],m=i[9],h=i[10],g=i[11],v=i[12]):({"data-slot":l,appearance:m,children:a,className:o,column:s,disableSorting:h,iconPlacement:g,intent:v,sortingMode:p,sortIcon:d,onClick:u,...f}=e,i[0]=e,i[1]=a,i[2]=o,i[3]=s,i[4]=l,i[5]=u,i[6]=d,i[7]=f,i[8]=p,i[9]=m,i[10]=h,i[11]=g,i[12]=v);let b=m===void 0?`ghost`:m,x=h!==void 0&&h,S=g===void 0?`end`:g,C=v===void 0?`neutral`:v,w;i[13]!==b||i[14]!==a||i[15]!==o||i[16]!==s||i[17]!==l||i[18]!==x||i[19]!==S||i[20]!==C||i[21]!==u||i[22]!==d||i[23]!==f||i[24]!==p?(w=()=>{let e=s.getIsSorted(),i=!x&&s.getCanSort(),c=i&&typeof e==`string`?e:`unsorted`;if(!i)return/* @__PURE__ */ _(`span`,{"data-slot":n(l,`data-table-header-sort-button`),"data-sort-direction":`unsorted`,className:t(`flex w-full items-center justify-start`,b===`ghost`&&C===`neutral`&&`text-muted`,o),...f,children:a});let m=d?.(c)??/* @__PURE__ */ _(ye,{mode:p,direction:c});return/* @__PURE__ */ _(r,{appearance:b,"data-slot":n(l,`data-table-header-sort-button`),className:t(`flex justify-start w-full h-full rounded-none not-disabled:active:scale-none`,b===`ghost`&&C===`neutral`&&`text-muted`,o),"data-sort-direction":c,"data-table-header-action":!0,icon:m,iconPlacement:S,onClick:e=>{u?.(e),e.defaultPrevented||p!==void 0&&be(s,p)},intent:C,type:`button`,...f,children:a})},i[13]=b,i[14]=a,i[15]=o,i[16]=s,i[17]=l,i[18]=x,i[19]=S,i[20]=C,i[21]=u,i[22]=d,i[23]=f,i[24]=p,i[25]=w):w=i[25];let T=w,E=P(),D;i[26]!==s||i[27]!==E?(D=()=>({sorted:s.getIsSorted(),options:E}),i[26]=s,i[27]=E,i[28]=D):D=i[28];let O;return i[29]!==s.table.store||i[30]!==T||i[31]!==D?(O=/* @__PURE__ */ _(y,{source:s.table.store,selector:D,children:T}),i[29]=s.table.store,i[30]=T,i[31]=D,i[32]=O):O=i[32],O}const z=`w-px whitespace-nowrap`;function B(e){if(e==null)return;let t=b(e,`getIsSorted`,w);if(t===`asc`)return`ascending`;if(t===`desc`)return`descending`}function V(e){let r=c(21),i,a,o,l,u;r[0]===e?(i=r[1],a=r[2],o=r[3],l=r[4],u=r[5]):({"data-slot":l,children:i,className:a,column:o,...u}=e,r[0]=e,r[1]=i,r[2]=a,r[3]=o,r[4]=l,r[5]=u);let d;r[6]!==i||r[7]!==a||r[8]!==o||r[9]!==l||r[10]!==u?(d=()=>{let e=M(o?.columnDef.meta);return/* @__PURE__ */ _(s.Header,{"aria-sort":B(o),"data-column-width":e,"data-slot":n(l,`data-table-header`),className:t(`has-data-table-header-action:px-0`,e===`fit`&&z,a),...u,children:i})},r[6]=i,r[7]=a,r[8]=o,r[9]=l,r[10]=u,r[11]=d):d=r[11];let f=d,p=P();if(o==null){let e;return r[12]===f?e=r[13]:(e=f(),r[12]=f,r[13]=e),e}let m;r[14]!==o||r[15]!==p?(m=()=>({ariaSort:B(o),options:p}),r[14]=o,r[15]=p,r[16]=m):m=r[16];let h;return r[17]!==o.table.store||r[18]!==f||r[19]!==m?(h=/* @__PURE__ */ _(y,{source:o.table.store,selector:m,children:f}),r[17]=o.table.store,r[18]=f,r[19]=m,r[20]=h):h=r[20],h}function H(e){let r=c(17),i,a,o,l;r[0]===e?(i=r[1],a=r[2],o=r[3],l=r[4]):({"data-slot":o,className:i,column:a,...l}=e,r[0]=e,r[1]=i,r[2]=a,r[3]=o,r[4]=l);let u=a?.columnDef.meta,d;r[5]===u?d=r[6]:(d=M(u),r[5]=u,r[6]=d);let f=d,p;r[7]===o?p=r[8]:(p=n(o,`data-table-cell`),r[7]=o,r[8]=p);let m=f===`fit`&&z,h;r[9]!==i||r[10]!==m?(h=t(m,i),r[9]=i,r[10]=m,r[11]=h):h=r[11];let g;return r[12]!==l||r[13]!==p||r[14]!==h||r[15]!==f?(g=/* @__PURE__ */ _(s.Cell,{"data-column-width":f,"data-slot":p,className:h,...l}),r[12]=l,r[13]=p,r[14]=h,r[15]=f,r[16]=g):g=r[16],g}const U=e=>{let t=c(8),r,i;t[0]===e?(r=t[1],i=t[2]):({"data-slot":r,...i}=e,t[0]=e,t[1]=r,t[2]=i);let a;t[3]===r?a=t[4]:(a=n(r,`data-table-body`),t[3]=r,t[4]=a);let o;return t[5]!==i||t[6]!==a?(o=/* @__PURE__ */ _(s.Body,{"data-slot":a,...i}),t[5]=i,t[6]=a,t[7]=o):o=t[7],o};function W(e){let t=c(11),r,i;t[0]===e?(r=t[1],i=t[2]):({"data-slot":r,...i}=e,t[0]=e,t[1]=r,t[2]=i);let{table:a}=F(),o;t[3]===r?o=t[4]:(o=n(r,`data-table-head`),t[3]=r,t[4]=o);let l;t[5]===a?l=t[6]:(l=a.getHeaderGroups().map(G),t[5]=a,t[6]=l);let u;return t[7]!==i||t[8]!==o||t[9]!==l?(u=/* @__PURE__ */ _(s.Head,{"data-slot":o,...i,children:l}),t[7]=i,t[8]=o,t[9]=l,t[10]=u):u=t[10],u}function G(e){return/* @__PURE__ */ _(s.Row,{children:e.headers.map(K)},e.id)}function K(e){return/* @__PURE__ */ _(l,{children:e.isPlaceholder?/* @__PURE__ */ _(s.Header,{}):x(e.column.columnDef.header,e.getContext())},e.id)}const q=t(`starting:-translate-y-1 starting:opacity-0`,`motion-safe:transition-[opacity,translate] motion-safe:duration-200 motion-safe:ease-out-strong`,`data-closing:pointer-events-none data-closing:opacity-0 motion-safe:data-closing:duration-150`);function J(e,t){return t.size===0||e.depth===0?!1:e.getParentRows().some(e=>t.has(e.id))}const Y=u(!1);function se(e){if(e.button!==0||e.metaKey||e.ctrlKey||e.shiftKey||e.altKey)return!1;let t=e.currentTarget.ownerDocument.getSelection();return t==null||t.isCollapsed?!0:!e.currentTarget.contains(t.anchorNode)}function ce(e){let r=c(21),i,a,o,l,u,f;r[0]===e?(i=r[1],a=r[2],o=r[3],l=r[4],u=r[5],f=r[6]):({"data-slot":a,className:i,onClick:o,renderExpanded:u,row:f,...l}=e,r[0]=e,r[1]=i,r[2]=a,r[3]=o,r[4]=l,r[5]=u,r[6]=f);let p=d(I)?.closingRowIds??L,m;r[7]!==i||r[8]!==p||r[9]!==a||r[10]!==o||r[11]!==l||r[12]!==u||r[13]!==f?(m=()=>{let e=J(f,p),r=b(f,`getIsExpanded`,T),c=b(f,`getVisibleCells`,E),d=/* @__PURE__ */ _(s.Row,{"data-slot":n(a,`data-table-row`),"data-expanded":r||void 0,"data-closing":e||void 0,inert:e||void 0,"data-clickable":o==null?void 0:``,className:t(f.depth>0&&q,o!=null&&`cursor-pointer`,i),onClick:o&&(e=>{se(e)&&o(e)}),...l,children:/* @__PURE__ */ _(Y.Provider,{value:u!=null,children:c.map(le)})});return u==null?d:/* @__PURE__ */ v(g,{children:[d,r&&/* @__PURE__ */ _($,{row:f,children:u(f)})]})},r[7]=i,r[8]=p,r[9]=a,r[10]=o,r[11]=l,r[12]=u,r[13]=f,r[14]=m):m=r[14];let h=m,x=P(),S;r[15]===x?S=r[16]:(S=e=>({state:e,options:x}),r[15]=x,r[16]=S);let C;return r[17]!==h||r[18]!==f.table.store||r[19]!==S?(C=/* @__PURE__ */ _(y,{source:f.table.store,selector:S,children:h}),r[17]=h,r[18]=f.table.store,r[19]=S,r[20]=C):C=r[20],C}function le(e){return/* @__PURE__ */ _(l,{children:x(e.column.columnDef.cell,e.getContext())},e.id)}function ue(e){let t=c(15),r,i,a;t[0]===e?(r=t[1],i=t[2],a=t[3]):({"data-slot":i,children:r,...a}=e,t[0]=e,t[1]=r,t[2]=i,t[3]=a);let{table:o}=F(),l;t[4]===o?l=t[5]:(l=b(o,`getVisibleLeafColumns`,D),t[4]=o,t[5]=l);let u=l.length,d;t[6]===i?d=t[7]:(d=n(i,`data-table-empty-row`),t[6]=i,t[7]=d);let f;t[8]!==r||t[9]!==u?(f=/* @__PURE__ */ _(s.Cell,{colSpan:u,children:r}),t[8]=r,t[9]=u,t[10]=f):f=t[10];let p;return t[11]!==a||t[12]!==d||t[13]!==f?(p=/* @__PURE__ */ _(s.Row,{"data-slot":d,...a,children:f}),t[11]=a,t[12]=d,t[13]=f,t[14]=p):p=t[14],p}function X(){let e=c(1),n;return e[0]===Symbol.for(`react.memo_cache_sentinel`)?(n=/* @__PURE__ */ _(`span`,{"aria-hidden":!0,className:t(`pointer-events-none absolute -inset-y-px -left-1.5 w-1.5`,`opacity-0 transition-opacity group-data-sticky-active/table:opacity-100`,`shadow-[1px_0_0_0_var(--border-color-card-muted)]`,`bg-linear-to-l to-transparent`,`from-[color-mix(in_oklab,var(--shadow-color)_var(--shadow-second-opacity),transparent)]`)}),e[0]=n):n=e[0],n}function de(e){let r=c(21),i,a,l,u,d;r[0]===e?(i=r[1],a=r[2],l=r[3],u=r[4],d=r[5]):({"data-slot":l,children:i,className:a,onClick:u,...d}=e,r[0]=e,r[1]=i,r[2]=a,r[3]=l,r[4]=u,r[5]=d);let f;r[6]===u?f=r[7]:(f=o({allowClickEventDefault:!0,onClick:u}),r[6]=u,r[7]=f);let{onClick:p}=f,m;r[8]===l?m=r[9]:(m=n(l,`data-table-action-cell`),r[8]=l,r[9]=m);let h;r[10]===a?h=r[11]:(h=t(`sticky z-10 right-0 text-end align-middle bg-inherit p-2`,a),r[10]=a,r[11]=h);let g;r[12]===Symbol.for(`react.memo_cache_sentinel`)?(g=/* @__PURE__ */ _(X,{}),r[12]=g):g=r[12];let y;r[13]===i?y=r[14]:(y=/* @__PURE__ */ _(`span`,{"data-slot":`data-table-action-cell-label`,className:`contents`,children:i}),r[13]=i,r[14]=y);let b;return r[15]!==d||r[16]!==p||r[17]!==m||r[18]!==h||r[19]!==y?(b=/* @__PURE__ */ v(s.Cell,{"data-mantle-table-sticky-right":!0,"data-slot":m,className:h,onClick:p,...d,children:[g,y]}),r[15]=d,r[16]=p,r[17]=m,r[18]=h,r[19]=y,r[20]=b):b=r[20],b}function fe(e){let r=c(27),i,a,o,l;r[0]===e?(i=r[1],a=r[2],o=r[3],l=r[4]):({"data-slot":o,children:i,className:a,...l}=e,r[0]=e,r[1]=i,r[2]=a,r[3]=o,r[4]=l);let{table:u}=F(),d;r[5]===u?d=r[6]:(d=u.getRowModel(),r[5]=u,r[6]=d);let f=d.rows.length>0,p;r[7]===f?p=r[8]:(p=f?{"data-mantle-table-sticky-right":!0}:{},r[7]=f,r[8]=p);let m;r[9]===o?m=r[10]:(m=n(o,`data-table-action-header`),r[9]=o,r[10]=m);let h=f&&`sticky z-10 right-0 bg-inherit`,g;r[11]!==a||r[12]!==h?(g=t(h,a),r[11]=a,r[12]=h,r[13]=g):g=r[13];let y;r[14]===i?y=r[15]:(y=i??/* @__PURE__ */ _(`span`,{className:`sr-only`,children:`Actions`}),r[14]=i,r[15]=y);let b;r[16]===y?b=r[17]:(b=/* @__PURE__ */ _(`span`,{"data-slot":`data-table-action-header-label`,className:`contents`,children:y}),r[16]=y,r[17]=b);let x;r[18]===f?x=r[19]:(x=f&&/* @__PURE__ */ _(X,{}),r[18]=f,r[19]=x);let S;return r[20]!==l||r[21]!==p||r[22]!==m||r[23]!==g||r[24]!==b||r[25]!==x?(S=/* @__PURE__ */ v(s.Header,{...p,"data-slot":m,className:g,...l,children:[b,x]}),r[20]=l,r[21]=p,r[22]=m,r[23]=g,r[24]=b,r[25]=x,r[26]=S):S=r[26],S}function pe(e){return e!=null&&`nodeType`in e}function me(e){let r=c(20),i,a,o,l,u;r[0]===e?(i=r[1],a=r[2],o=r[3],l=r[4],u=r[5]):({"data-slot":o,children:i,className:a,onClick:l,...u}=e,r[0]=e,r[1]=i,r[2]=a,r[3]=o,r[4]=l,r[5]=u);let d=p(!1),f;r[6]===o?f=r[7]:(f=n(o,`data-table-control-cell`),r[6]=o,r[7]=f);let m;r[8]===a?m=r[9]:(m=t(`w-9 px-0 align-top has-[button:enabled,input:enabled]:cursor-pointer`,a),r[8]=a,r[9]=m);let h;r[10]===l?h=r[11]:(h=e=>{if(d.current){e.stopPropagation();return}l?.(e);let t=e.currentTarget.querySelector(`button:not(:disabled), input:not(:disabled)`);t!=null&&(e.stopPropagation(),!e.defaultPrevented&&pe(e.target)&&!t.contains(e.target)&&(t.focus({preventScroll:!0}),d.current=!0,t.click(),d.current=!1))},r[10]=l,r[11]=h);let g;r[12]===i?g=r[13]:(g=/* @__PURE__ */ _(`span`,{"data-slot":`data-table-control-cell-label`,className:`flex h-lh items-center justify-center`,children:i}),r[12]=i,r[13]=g);let v;return r[14]!==u||r[15]!==f||r[16]!==m||r[17]!==h||r[18]!==g?(v=/* @__PURE__ */ _(s.Cell,{"data-slot":f,className:m,onClick:h,...u,children:g}),r[14]=u,r[15]=f,r[16]=m,r[17]=h,r[18]=g,r[19]=v):v=r[19],v}function Z(e){return`data-table-expanded-row-${encodeURIComponent(e.id)}`}function Q(e){let r=c(16),i,a,o,l;r[0]===e?(i=r[1],a=r[2],o=r[3],l=r[4]):({"data-slot":o,children:i,className:a,...l}=e,r[0]=e,r[1]=i,r[2]=a,r[3]=o,r[4]=l);let u;r[5]===o?u=r[6]:(u=n(o,`data-table-expand-header`),r[5]=o,r[6]=u);let d;r[7]===a?d=r[8]:(d=t(`w-9 px-0 text-center`,a),r[7]=a,r[8]=d);let f;r[9]===i?f=r[10]:(f=i??/* @__PURE__ */ _(`span`,{className:`sr-only`,children:`Row details`}),r[9]=i,r[10]=f);let p;return r[11]!==l||r[12]!==u||r[13]!==d||r[14]!==f?(p=/* @__PURE__ */ _(s.Header,{"data-slot":u,className:d,...l,children:f}),r[11]=l,r[12]=u,r[13]=d,r[14]=f,r[15]=p):p=r[15],p}const he=/* @__PURE__ */ _(C,{weight:`bold`,className:`size-3.5`}),ge=/* @__PURE__ */ _(S,{weight:`bold`,className:`size-3.5`});function _e(e){let r=c(21),a,o,s,l,u,f,p,m,h,g,v;r[0]===e?(a=r[1],o=r[2],s=r[3],l=r[4],u=r[5],f=r[6],p=r[7],m=r[8],h=r[9],g=r[10],v=r[11]):({"data-slot":o,appearance:p,className:a,collapseIcon:m,expandIcon:h,intent:g,label:s,onClick:l,row:f,size:v,...u}=e,r[0]=e,r[1]=a,r[2]=o,r[3]=s,r[4]=l,r[5]=u,r[6]=f,r[7]=p,r[8]=m,r[9]=h,r[10]=g,r[11]=v);let b=p===void 0?`ghost`:p,x=m===void 0?ge:m,S=h===void 0?he:h,C=g===void 0?`neutral`:g,w=v===void 0?`sm`:v,T=()=>{if(!f.getCanExpand())return null;let e=f.getIsExpanded()&&!k,r=f.getToggleExpandedHandler(),c=f.subRows.length>0,d=D||!c;return/* @__PURE__ */ _(i,{type:`button`,"data-slot":n(o,`data-table-row-expand-button`),appearance:b,intent:C,size:w,className:t(`rounded`,a),"aria-expanded":e,"aria-controls":e&&d?Z(f):void 0,icon:e?x:S,label:c?`${e?`Collapse`:`Expand`} ${s}`:`${e?`Hide`:`Show`} details for ${s}`,onClick:t=>{if(t.stopPropagation(),l?.(t),t.defaultPrevented)return;let n=t.currentTarget.closest(`tbody`);O==null?r():k?O.cancelCollapse(f.id):e?O.startCollapse(f.id,n,()=>f.toggleExpanded(!1)):O.startExpand(n,r)},...u})},E=P(),D=d(Y),O=d(I),k=O?.closingRowIds.has(f.id)??!1,A;r[12]!==D||r[13]!==k||r[14]!==E||r[15]!==f?(A=()=>({isExpanded:f.getIsExpanded(),hasDetailPanel:D,isClosing:k,options:E}),r[12]=D,r[13]=k,r[14]=E,r[15]=f,r[16]=A):A=r[16];let j;return r[17]!==T||r[18]!==f.table.store||r[19]!==A?(j=/* @__PURE__ */ _(y,{source:f.table.store,selector:A,children:T}),r[17]=T,r[18]=f.table.store,r[19]=A,r[20]=j):j=r[20],j}function $(e){let r=c(29),i,a,o,l,u,f;r[0]===e?(i=r[1],a=r[2],o=r[3],l=r[4],u=r[5],f=r[6]):({"data-slot":l,children:i,className:a,colSpan:o,row:f,...u}=e,r[0]=e,r[1]=i,r[2]=a,r[3]=o,r[4]=l,r[5]=u,r[6]=f);let p;r[7]===f?p=r[8]:(p=()=>b(f,`getVisibleCells`,E).length,r[7]=f,r[8]=p);let m=p,h=d(I)?.closingRowIds??L,g;r[9]!==h||r[10]!==f?(g=h.has(f.id)||J(f,h),r[9]=h,r[10]=f,r[11]=g):g=r[11];let v=g,x;r[12]!==i||r[13]!==a||r[14]!==l||r[15]!==v||r[16]!==u||r[17]!==f?(x=e=>{let{numberOfColumns:r}=e;return/* @__PURE__ */ _(s.Row,{"data-slot":n(l,`data-table-expanded-row`),"data-expanded-content":!0,"data-closing":v||void 0,inert:v||void 0,className:t(`[&>td]:border-t-0`,q,a),...u,children:/* @__PURE__ */ _(s.Cell,{id:Z(f),colSpan:r,className:`bg-card font-sans text-body`,children:i})})},r[12]=i,r[13]=a,r[14]=l,r[15]=v,r[16]=u,r[17]=f,r[18]=x):x=r[18];let S=x,C=P();if(o!=null){let e;return r[19]!==o||r[20]!==S?(e=S({numberOfColumns:o}),r[19]=o,r[20]=S,r[21]=e):e=r[21],e}let w;r[22]!==m||r[23]!==C?(w=()=>({numberOfColumns:m(),options:C}),r[22]=m,r[23]=C,r[24]=w):w=r[24];let T;return r[25]!==S||r[26]!==f.table.store||r[27]!==w?(T=/* @__PURE__ */ _(y,{source:f.table.store,selector:w,children:S}),r[25]=S,r[26]=f.table.store,r[27]=w,r[28]=T):T=r[28],T}const ve={Root:ae,ActionCell:de,ActionHeader:fe,Cell:H,Body:U,EmptyRow:ue,Head:W,Header:V,HeaderSortButton:oe,Row:ce,ExpandHeader:Q,ControlCell:me,RowExpandButton:_e,ExpandedRow:$};function ye(e){let t=c(10),n,r,i;if(t[0]===e?(n=t[1],r=t[2],i=t[3]):({direction:n,mode:r,...i}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i),n===`unsorted`||!r||!n){let e;return t[4]===i?e=t[5]:(e=/* @__PURE__ */ _(`svg`,{"aria-hidden":!0,...i}),t[4]=i,t[5]=e),e}let o;return t[6]!==n||t[7]!==r||t[8]!==i?(o=/* @__PURE__ */ _(a,{mode:r,direction:n,...i}),t[6]=n,t[7]=r,t[8]=i,t[9]=o):o=t[9],o}function be(e,t){if(!e.getCanSort())return;let n=e.getIsSorted();switch(A(typeof n==`string`?n:`unsorted`,t)){case`unsorted`:e.clearSorting();return;case`asc`:e.toggleSorting(!1);return;case`desc`:e.toggleSorting(!0);return;default:return}}export{ve as DataTable,Z as expandedRowId};
1
+ import*as e from"./data-table-parts.js";import{t}from"./data-table-Cw9dUo1w.js";export*from"@tanstack/react-table";export{e as DataTable,t as expandedRowId};
@@ -0,0 +1,110 @@
1
+ import { n as WithAsChild } from "./as-child-DFxX3U2i.js";
2
+ import { ComponentProps } from "react";
3
+ import "./index-CCkilmv8.js";
4
+ import { t as WithDataSlot } from "./data-slot-BW8KQ9Xo.js";
5
+ /**
6
+ * Props for `DescriptionList.Root`.
7
+ */
8
+ type DescriptionListProps = ComponentProps<"dl"> & WithAsChild & WithDataSlot;
9
+ /**
10
+ * A semantically correct description list built on the HTML `<dl>` element.
11
+ * Renders a list of label/value pairs with alternating row backgrounds,
12
+ * commonly used in detail views to display metadata about a resource.
13
+ * The value column has a `0` minimum width, so a value that truncates or
14
+ * wraps stays inside the row instead of widening the list.
15
+ *
16
+ * | Data Attribute | Value | Description |
17
+ * | --- | --- | --- |
18
+ * | `data-slot` | `"description-list"` | The `<dl>`. A consumer `data-slot` joins in front of it. |
19
+ *
20
+ * @see https://mantle.ngrok.com/components/data-display/description-list#descriptionlistroot
21
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dl
22
+ *
23
+ * @example
24
+ * ```tsx
25
+ * <DescriptionList.Root>
26
+ * <DescriptionList.Item>
27
+ * <DescriptionList.Label>Name</DescriptionList.Label>
28
+ * <DescriptionList.Value>my-api-key</DescriptionList.Value>
29
+ * </DescriptionList.Item>
30
+ * </DescriptionList.Root>
31
+ * ```
32
+ */
33
+ declare const Root: ({ asChild, className, children, "data-slot": dataSlot, ref, ...rest }: DescriptionListProps) => import("react").JSX.Element;
34
+ /**
35
+ * Props for `DescriptionList.Item`.
36
+ */
37
+ type DescriptionListItemProps = ComponentProps<"div"> & WithAsChild & WithDataSlot;
38
+ /**
39
+ * A wrapper that groups a `DescriptionList.Label` and `DescriptionList.Value`
40
+ * pair. Renders as a `<div>` inside the `<dl>` with a subgrid layout that
41
+ * inherits column tracks from the root.
42
+ *
43
+ * | Data Attribute | Value | Description |
44
+ * | --- | --- | --- |
45
+ * | `data-slot` | `"description-list-item"` | The row wrapper. |
46
+ *
47
+ * @see https://mantle.ngrok.com/components/data-display/description-list#descriptionlistitem
48
+ *
49
+ * @example
50
+ * ```tsx
51
+ * <DescriptionList.Root>
52
+ * <DescriptionList.Item>
53
+ * <DescriptionList.Label>Name</DescriptionList.Label>
54
+ * <DescriptionList.Value>my-api-key</DescriptionList.Value>
55
+ * </DescriptionList.Item>
56
+ * </DescriptionList.Root>
57
+ * ```
58
+ */
59
+ declare const Item: ({ "data-slot": dataSlot, asChild, className, children, ref, ...rest }: DescriptionListItemProps) => import("react").JSX.Element;
60
+ /**
61
+ * Props for `DescriptionList.Label`.
62
+ */
63
+ type DescriptionListLabelProps = ComponentProps<"dt"> & WithAsChild & WithDataSlot;
64
+ /**
65
+ * The label for a description list item. Renders as a `<dt>` element.
66
+ *
67
+ * | Data Attribute | Value | Description |
68
+ * | --- | --- | --- |
69
+ * | `data-slot` | `"description-list-label"` | The `<dt>`. |
70
+ *
71
+ * @see https://mantle.ngrok.com/components/data-display/description-list#descriptionlistlabel
72
+ *
73
+ * @example
74
+ * ```tsx
75
+ * <DescriptionList.Root>
76
+ * <DescriptionList.Item>
77
+ * <DescriptionList.Label>Name</DescriptionList.Label>
78
+ * <DescriptionList.Value>my-api-key</DescriptionList.Value>
79
+ * </DescriptionList.Item>
80
+ * </DescriptionList.Root>
81
+ * ```
82
+ */
83
+ declare const Label: ({ "data-slot": dataSlot, asChild, className, children, ref, ...rest }: DescriptionListLabelProps) => import("react").JSX.Element;
84
+ /**
85
+ * Props for `DescriptionList.Value`.
86
+ */
87
+ type DescriptionListValueProps = ComponentProps<"dd"> & WithAsChild & WithDataSlot;
88
+ /**
89
+ * The value for a description list item. Renders as a `<dd>` element.
90
+ * Compose any content inside: the component is intentionally "dumb" and
91
+ * imposes no layout on its children.
92
+ *
93
+ * | Data Attribute | Value | Description |
94
+ * | --- | --- | --- |
95
+ * | `data-slot` | `"description-list-value"` | The `<dd>`. |
96
+ *
97
+ * @see https://mantle.ngrok.com/components/data-display/description-list#descriptionlistvalue
98
+ *
99
+ * @example
100
+ * ```tsx
101
+ * <DescriptionList.Root>
102
+ * <DescriptionList.Item>
103
+ * <DescriptionList.Label>Name</DescriptionList.Label>
104
+ * <DescriptionList.Value>my-api-key</DescriptionList.Value>
105
+ * </DescriptionList.Item>
106
+ * </DescriptionList.Root>
107
+ * ```
108
+ */
109
+ declare const Value: ({ "data-slot": dataSlot, asChild, className, children, ref, ...rest }: DescriptionListValueProps) => import("react").JSX.Element;
110
+ export { Item as a, Value as c, DescriptionListValueProps as i, DescriptionListLabelProps as n, Label as o, DescriptionListProps as r, Root as s, DescriptionListItemProps as t };
@@ -0,0 +1,6 @@
1
+ /**
2
+ * The parts of the `DescriptionList` namespace. `index.ts` imports them as one module
3
+ * namespace, so a bundler keeps only the parts a consumer reads.
4
+ */
5
+ import { a as Item, c as Value, o as Label, s as Root } from "./description-list-CjcKOOnr.js";
6
+ export { Item, Label, Root, Value };
@@ -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=({asChild:i=!1,className:a,children:o,"data-slot":s,ref:c,...l})=>/* @__PURE__ */ r(i?n:`dl`,{ref:c,"data-slot":t(s,`description-list`),className:e(`relative scrollbar overflow-x-auto overscroll-x-none rounded-lg border border-card grid grid-cols-[auto_minmax(0,1fr)] gap-x-4 [&>*:nth-child(odd)]:bg-neutral-500/5 p-1`,a),...l,children:o}),a=({"data-slot":i,asChild:a=!1,className:o,children:s,ref:c,...l})=>/* @__PURE__ */ r(a?n:`div`,{ref:c,"data-slot":t(i,`description-list-item`),className:e(`rounded-sm col-span-full grid grid-cols-subgrid items-center`,o),...l,children:s}),o=({"data-slot":i,asChild:a=!1,className:o,children:s,ref:c,...l})=>/* @__PURE__ */ r(a?n:`dt`,{ref:c,"data-slot":t(i,`description-list-label`),className:e(`text-muted text-sm font-sans font-medium min-w-36 p-2`,o),...l,children:s}),s=({"data-slot":i,asChild:a=!1,className:o,children:s,ref:c,...l})=>/* @__PURE__ */ r(a?n:`dd`,{ref:c,"data-slot":t(i,`description-list-value`),className:e(`text-body font-mono text-mono py-2 px-3`,o),...l,children:s});export{a as Item,o as Label,i as Root,s as Value};
@@ -3,115 +3,8 @@
3
3
  *
4
4
  * @see https://mantle.ngrok.com/components/data-display/description-list
5
5
  */
6
- import { n as WithAsChild } from "./as-child-DFxX3U2i.js";
7
- import "./index-KJ06KK6t.js";
8
- import { t as WithDataSlot } from "./data-slot-B-LqAcBB.js";
9
- import { ComponentProps } from "react";
10
- /**
11
- * Props for `DescriptionList.Root`.
12
- */
13
- type DescriptionListProps = ComponentProps<"dl"> & WithAsChild & WithDataSlot;
14
- /**
15
- * A semantically correct description list built on the HTML `<dl>` element.
16
- * Renders a list of label/value pairs with alternating row backgrounds,
17
- * commonly used in detail views to display metadata about a resource.
18
- * The value column has a `0` minimum width, so a value that truncates or
19
- * wraps stays inside the row instead of widening the list.
20
- *
21
- * | Data Attribute | Value | Description |
22
- * | --- | --- | --- |
23
- * | `data-slot` | `"description-list"` | The `<dl>`. A consumer `data-slot` joins in front of it. |
24
- *
25
- * @see https://mantle.ngrok.com/components/data-display/description-list#descriptionlistroot
26
- * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dl
27
- *
28
- * @example
29
- * ```tsx
30
- * <DescriptionList.Root>
31
- * <DescriptionList.Item>
32
- * <DescriptionList.Label>Name</DescriptionList.Label>
33
- * <DescriptionList.Value>my-api-key</DescriptionList.Value>
34
- * </DescriptionList.Item>
35
- * </DescriptionList.Root>
36
- * ```
37
- */
38
- declare const Root: ({ asChild, className, children, "data-slot": dataSlot, ref, ...rest }: DescriptionListProps) => import("react").JSX.Element;
39
- /**
40
- * Props for `DescriptionList.Item`.
41
- */
42
- type DescriptionListItemProps = ComponentProps<"div"> & WithAsChild & WithDataSlot;
43
- /**
44
- * A wrapper that groups a `DescriptionList.Label` and `DescriptionList.Value`
45
- * pair. Renders as a `<div>` inside the `<dl>` with a subgrid layout that
46
- * inherits column tracks from the root.
47
- *
48
- * | Data Attribute | Value | Description |
49
- * | --- | --- | --- |
50
- * | `data-slot` | `"description-list-item"` | The row wrapper. |
51
- *
52
- * @see https://mantle.ngrok.com/components/data-display/description-list#descriptionlistitem
53
- *
54
- * @example
55
- * ```tsx
56
- * <DescriptionList.Root>
57
- * <DescriptionList.Item>
58
- * <DescriptionList.Label>Name</DescriptionList.Label>
59
- * <DescriptionList.Value>my-api-key</DescriptionList.Value>
60
- * </DescriptionList.Item>
61
- * </DescriptionList.Root>
62
- * ```
63
- */
64
- declare const Item: ({ "data-slot": dataSlot, asChild, className, children, ref, ...rest }: DescriptionListItemProps) => import("react").JSX.Element;
65
- /**
66
- * Props for `DescriptionList.Label`.
67
- */
68
- type DescriptionListLabelProps = ComponentProps<"dt"> & WithAsChild & WithDataSlot;
69
- /**
70
- * The label for a description list item. Renders as a `<dt>` element.
71
- *
72
- * | Data Attribute | Value | Description |
73
- * | --- | --- | --- |
74
- * | `data-slot` | `"description-list-label"` | The `<dt>`. |
75
- *
76
- * @see https://mantle.ngrok.com/components/data-display/description-list#descriptionlistlabel
77
- *
78
- * @example
79
- * ```tsx
80
- * <DescriptionList.Root>
81
- * <DescriptionList.Item>
82
- * <DescriptionList.Label>Name</DescriptionList.Label>
83
- * <DescriptionList.Value>my-api-key</DescriptionList.Value>
84
- * </DescriptionList.Item>
85
- * </DescriptionList.Root>
86
- * ```
87
- */
88
- declare const Label: ({ "data-slot": dataSlot, asChild, className, children, ref, ...rest }: DescriptionListLabelProps) => import("react").JSX.Element;
89
- /**
90
- * Props for `DescriptionList.Value`.
91
- */
92
- type DescriptionListValueProps = ComponentProps<"dd"> & WithAsChild & WithDataSlot;
93
- /**
94
- * The value for a description list item. Renders as a `<dd>` element.
95
- * Compose any content inside: the component is intentionally "dumb" and
96
- * imposes no layout on its children.
97
- *
98
- * | Data Attribute | Value | Description |
99
- * | --- | --- | --- |
100
- * | `data-slot` | `"description-list-value"` | The `<dd>`. |
101
- *
102
- * @see https://mantle.ngrok.com/components/data-display/description-list#descriptionlistvalue
103
- *
104
- * @example
105
- * ```tsx
106
- * <DescriptionList.Root>
107
- * <DescriptionList.Item>
108
- * <DescriptionList.Label>Name</DescriptionList.Label>
109
- * <DescriptionList.Value>my-api-key</DescriptionList.Value>
110
- * </DescriptionList.Item>
111
- * </DescriptionList.Root>
112
- * ```
113
- */
114
- declare const Value: ({ "data-slot": dataSlot, asChild, className, children, ref, ...rest }: DescriptionListValueProps) => import("react").JSX.Element;
6
+ import * as DescriptionListParts from "./description-list-parts.js";
7
+ import { i as DescriptionListValueProps, n as DescriptionListLabelProps, r as DescriptionListProps, t as DescriptionListItemProps } from "./description-list-CjcKOOnr.js";
115
8
  /**
116
9
  * A semantically correct description list built on the HTML `<dl>` element.
117
10
  * Renders a list of label/value pairs with alternating row backgrounds,
@@ -155,78 +48,5 @@ declare const Value: ({ "data-slot": dataSlot, asChild, className, children, ref
155
48
  * </DescriptionList.Root>
156
49
  * ```
157
50
  */
158
- declare const DescriptionList: {
159
- /**
160
- * A semantically correct description list built on the HTML `<dl>` element.
161
- * Renders a list of label/value pairs with alternating row backgrounds,
162
- * commonly used in detail views to display metadata about a resource.
163
- * The value column has a `0` minimum width, so a value that truncates or
164
- * wraps stays inside the row instead of widening the list.
165
- *
166
- * @see https://mantle.ngrok.com/components/data-display/description-list#descriptionlistroot
167
- *
168
- * @example
169
- * ```tsx
170
- * <DescriptionList.Root>
171
- * <DescriptionList.Item>
172
- * <DescriptionList.Label>Name</DescriptionList.Label>
173
- * <DescriptionList.Value>my-api-key</DescriptionList.Value>
174
- * </DescriptionList.Item>
175
- * </DescriptionList.Root>
176
- * ```
177
- */
178
- readonly Root: typeof Root;
179
- /**
180
- * A wrapper that groups a `DescriptionList.Label` and `DescriptionList.Value`
181
- * pair. Renders as a `<div>` inside the `<dl>` with a subgrid layout that
182
- * inherits column tracks from the root.
183
- *
184
- * @see https://mantle.ngrok.com/components/data-display/description-list#descriptionlistitem
185
- *
186
- * @example
187
- * ```tsx
188
- * <DescriptionList.Root>
189
- * <DescriptionList.Item>
190
- * <DescriptionList.Label>Name</DescriptionList.Label>
191
- * <DescriptionList.Value>my-api-key</DescriptionList.Value>
192
- * </DescriptionList.Item>
193
- * </DescriptionList.Root>
194
- * ```
195
- */
196
- readonly Item: typeof Item;
197
- /**
198
- * The label for a description list item. Renders as a `<dt>` element.
199
- *
200
- * @see https://mantle.ngrok.com/components/data-display/description-list#descriptionlistlabel
201
- *
202
- * @example
203
- * ```tsx
204
- * <DescriptionList.Root>
205
- * <DescriptionList.Item>
206
- * <DescriptionList.Label>Name</DescriptionList.Label>
207
- * <DescriptionList.Value>my-api-key</DescriptionList.Value>
208
- * </DescriptionList.Item>
209
- * </DescriptionList.Root>
210
- * ```
211
- */
212
- readonly Label: typeof Label;
213
- /**
214
- * The value for a description list item. Renders as a `<dd>` element.
215
- * Compose any content inside: the component is intentionally "dumb" and
216
- * imposes no layout on its children.
217
- *
218
- * @see https://mantle.ngrok.com/components/data-display/description-list#descriptionlistvalue
219
- *
220
- * @example
221
- * ```tsx
222
- * <DescriptionList.Root>
223
- * <DescriptionList.Item>
224
- * <DescriptionList.Label>Name</DescriptionList.Label>
225
- * <DescriptionList.Value>my-api-key</DescriptionList.Value>
226
- * </DescriptionList.Item>
227
- * </DescriptionList.Root>
228
- * ```
229
- */
230
- readonly Value: typeof Value;
231
- };
51
+ declare const DescriptionList: typeof DescriptionListParts;
232
52
  export { DescriptionList, type DescriptionListItemProps, type DescriptionListLabelProps, type DescriptionListProps, type DescriptionListValueProps };
@@ -1 +1 @@
1
- import{t as e}from"./cx-CK7o_rVv.js";import{t}from"./data-slot-EM6s2WEU.js";import{t as n}from"./slot-DdYN1L1C.js";import{c as r}from"react/compiler-runtime";import{jsx as i}from"react/jsx-runtime";const a={Root:a=>{let o=r(18),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]):({asChild:f,className:c,children:s,"data-slot":l,ref:u,...d}=a,o[0]=a,o[1]=s,o[2]=c,o[3]=l,o[4]=u,o[5]=d,o[6]=f);let p=f!==void 0&&f?n:`dl`,m;o[7]===l?m=o[8]:(m=t(l,`description-list`),o[7]=l,o[8]=m);let h;o[9]===c?h=o[10]:(h=e(`relative scrollbar overflow-x-auto overscroll-x-none rounded-lg border border-card grid grid-cols-[auto_minmax(0,1fr)] gap-x-4 [&>*:nth-child(odd)]:bg-neutral-500/5 p-1`,c),o[9]=c,o[10]=h);let g;return o[11]!==p||o[12]!==s||o[13]!==u||o[14]!==d||o[15]!==m||o[16]!==h?(g=/* @__PURE__ */ i(p,{ref:u,"data-slot":m,className:h,...d,children:s}),o[11]=p,o[12]=s,o[13]=u,o[14]=d,o[15]=m,o[16]=h,o[17]=g):g=o[17],g},Item:a=>{let o=r(18),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]):({"data-slot":l,asChild:f,className:c,children:s,ref:u,...d}=a,o[0]=a,o[1]=s,o[2]=c,o[3]=l,o[4]=u,o[5]=d,o[6]=f);let p=f!==void 0&&f?n:`div`,m;o[7]===l?m=o[8]:(m=t(l,`description-list-item`),o[7]=l,o[8]=m);let h;o[9]===c?h=o[10]:(h=e(`rounded-sm col-span-full grid grid-cols-subgrid items-center`,c),o[9]=c,o[10]=h);let g;return o[11]!==p||o[12]!==s||o[13]!==u||o[14]!==d||o[15]!==m||o[16]!==h?(g=/* @__PURE__ */ i(p,{ref:u,"data-slot":m,className:h,...d,children:s}),o[11]=p,o[12]=s,o[13]=u,o[14]=d,o[15]=m,o[16]=h,o[17]=g):g=o[17],g},Label:a=>{let o=r(18),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]):({"data-slot":l,asChild:f,className:c,children:s,ref:u,...d}=a,o[0]=a,o[1]=s,o[2]=c,o[3]=l,o[4]=u,o[5]=d,o[6]=f);let p=f!==void 0&&f?n:`dt`,m;o[7]===l?m=o[8]:(m=t(l,`description-list-label`),o[7]=l,o[8]=m);let h;o[9]===c?h=o[10]:(h=e(`text-muted text-sm font-sans font-medium min-w-36 p-2`,c),o[9]=c,o[10]=h);let g;return o[11]!==p||o[12]!==s||o[13]!==u||o[14]!==d||o[15]!==m||o[16]!==h?(g=/* @__PURE__ */ i(p,{ref:u,"data-slot":m,className:h,...d,children:s}),o[11]=p,o[12]=s,o[13]=u,o[14]=d,o[15]=m,o[16]=h,o[17]=g):g=o[17],g},Value:a=>{let o=r(18),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]):({"data-slot":l,asChild:f,className:c,children:s,ref:u,...d}=a,o[0]=a,o[1]=s,o[2]=c,o[3]=l,o[4]=u,o[5]=d,o[6]=f);let p=f!==void 0&&f?n:`dd`,m;o[7]===l?m=o[8]:(m=t(l,`description-list-value`),o[7]=l,o[8]=m);let h;o[9]===c?h=o[10]:(h=e(`text-body font-mono text-mono py-2 px-3`,c),o[9]=c,o[10]=h);let g;return o[11]!==p||o[12]!==s||o[13]!==u||o[14]!==d||o[15]!==m||o[16]!==h?(g=/* @__PURE__ */ i(p,{ref:u,"data-slot":m,className:h,...d,children:s}),o[11]=p,o[12]=s,o[13]=u,o[14]=d,o[15]=m,o[16]=h,o[17]=g):g=o[17],g}};export{a as DescriptionList};
1
+ export*as DescriptionList from"./description-list-parts.js";
@@ -0,0 +1 @@
1
+ "use client";import{createContext as e,useContext as t,useEffect as n,useId as r,useLayoutEffect as i,useMemo as a,useRef as o,useState as s}from"react";import{createPortal as c}from"react-dom";import l from"tiny-invariant";import{t as u}from"./hooks-C9b-2wGy.js";import{t as d}from"./hooks-BeLOGKwE.js";import{t as f}from"./compose-refs-Ce1vWUz0.js";import{t as ee}from"./cx-CfAFHj5_.js";import{i as p,o as m,r as h,t as g}from"./layer-container-DDOZJ0fn.js";import{t as _}from"./slot-CBcGhRdV.js";import{t as te}from"./toast-BJZ__22c.js";import{n as ne}from"./overlay-prompt-BIzMQvx7.js";import{t as re}from"./dialog-fXMCxM9W.js";import{jsx as v,jsxs as ie}from"react/jsx-runtime";const ae=()=>e(null);function y(e,n){let r=t(e);return l(r!=null,`The dialog part \`${n}\` must be rendered inside its \`Root\`.`),r}const b=[],oe=/* @__PURE__ */ new WeakSet,x=/* @__PURE__ */ new WeakSet;let S=/* @__PURE__ */ new Set;const C=/* @__PURE__ */ new WeakSet;let w;function se(e){if(C.has(e))return;C.add(e);let t={capture:!0,passive:!0};e.addEventListener(`pointerdown`,()=>w=!0,t),e.addEventListener(`keydown`,()=>w=!1,t)}function ce(e,t,n){let r=new Event(t,{cancelable:!0});return n==null?r:e==null?(n(r),r):(e.addEventListener(t,n,{once:!0}),e.dispatchEvent(r),r)}function T({dialog:e,open:t}){if(e.hasAttribute(`data-open`)!==t){let n=e.querySelector(`[data-mantle-modal-content]`);for(let r of[e,n])r?.toggleAttribute(`data-open`,t),r?.toggleAttribute(`data-closing`,!t);for(let n of e.ownerDocument.querySelectorAll(`[aria-controls="${e.id}"]`))n.setAttribute(`aria-expanded`,String(t))}let n=b.indexOf(e);t&&n===-1?b.push(e):!t&&n!==-1&&b.splice(n,1);let r=b.findLast(e=>!x.has(e))??null;ne(r);let i=/* @__PURE__ */ new Set;for(let e of b){let t=e.querySelector(`[data-mantle-modal-content]`);r!=null&&e!==r&&!r.contains(e)&&t instanceof HTMLElement&&!t.contains(r)&&(S.has(t)||!t.inert)&&i.add(t)}for(let e of S)e.inert=i.has(e);for(let e of i)e.inert=!0;S=i}const E=/* @__PURE__ */ new Set;function D({dialog:e,lock:t}){let n=e.ownerDocument.documentElement;if(t){if(E.size===0){let t=(e.ownerDocument.defaultView?.innerWidth??0)-n.clientWidth;n.style.setProperty(`--mantle-scrollbar-width`,`${Math.max(t,0)}px`),n.setAttribute(`data-mantle-scroll-lock`,``)}E.add(e)}else E.delete(e)&&E.size===0&&n.removeAttribute(`data-mantle-scroll-lock`)}function O({dialog:e,modal:t=!0,open:n}){typeof e.showModal!=`function`&&(e.show=e.showModal=()=>e.setAttribute(`open`,``),e.close=()=>{e.removeAttribute(`open`),e.dispatchEvent(new Event(`close`))}),n===e.open?n&&!e.hasAttribute(`data-open`)&&T({dialog:e,open:n}):n&&N(e)||(t?x.delete(e):x.add(e),T({dialog:e,open:n}),n?t?(D({dialog:e,lock:!0}),e.showModal()):e.show():(k(e),e.close()))}function k(e){for(let t of[...e.querySelectorAll(`dialog[open]`)].toReversed())t instanceof HTMLDialogElement&&(T({dialog:t,open:!1}),t.close())}function A(e,t){if(!e.open){t?.();return}T({dialog:e,open:!1});let n=e.querySelector(`[data-mantle-modal-content]`),r=(e.getAnimations?.({subtree:!0})??[]).filter(({effect:t})=>t instanceof KeyframeEffect&&(t.target===e||t.target===n)&&t.getTiming().iterations!==1/0),i=()=>{e.hasAttribute(`data-open`)||(e.open&&(k(e),e.close()),e.removeAttribute(`data-closing`),n?.removeAttribute(`data-closing`),t?.())};r.length===0?i():(async()=>{await Promise.allSettled(r.map(e=>e.finished)),i()})()}function j({dialog:e,open:t,root:n}){n.controlled?t!==n.open&&n.setOpen(t):e instanceof HTMLDialogElement&&oe.has(e)?t?O({dialog:e,modal:n.modal,open:t}):A(e):t!==n.open&&n.setOpen(t)}function M(e,t){return e.controlled||t===`show-modal`&&!e.modal?{}:{command:t,commandfor:e.contentId}}function N(e){for(let t=e.parentElement?.closest(`dialog:not([open])`);t instanceof HTMLElement;t=t.parentElement?.closest(`dialog:not([open])`))if(t.style.display!==`contents`)return!0;return!1}function le(e){return e instanceof HTMLButtonElement&&e.type===`button`&&Reflect.get(e,`commandForElement`)instanceof HTMLDialogElement}function ue(e){let t=new CustomEvent(`dismissableLayer.pointerDownOutside`,{cancelable:!0,detail:{originalEvent:e}});return e.target?.dispatchEvent(t),t}function de(e){let t=h();t!=null&&(e.preventDefault(),setTimeout(()=>t.focus()))}const fe=({children:e,defaultOpen:t=!1,modal:n=!0,onOpenChange:i,open:o,scope:c})=>{let l=r(),d=r(),[f,ee]=s(t),p=o!==void 0,m=u(e=>i?.(e)),h=u(e=>{p||ee(e),i?.(e)}),g=o??f,_=a(()=>({contentId:l,titleId:d,controlled:p,open:g,defaultOpen:t,modal:n,setOpen:h,reportOpen:m}),[l,d,p,g,t,n,h,m]);return/* @__PURE__ */ v(c,{value:_,children:e})};function P({onClick:e,open:t,root:n}){return r=>{e?.(r);let i=r.currentTarget;if(!r.defaultPrevented&&!le(i)){let e=i.ownerDocument.getElementById(n.contentId),r=e instanceof HTMLDialogElement&&e.open&&e.hasAttribute(`data-open`);j({dialog:e,open:t&&!r,root:n})}}}const F=({asChild:e,onClick:t,ref:n,scope:r,...i})=>{let a=y(r,`Trigger`),o=e?_:`button`,s=P({onClick:t,open:!0,root:a}),c=f(n,e=>{let t=e?.ownerDocument.getElementById(a.contentId);e!=null&&t!=null&&e.setAttribute(`aria-expanded`,String(t.hasAttribute(`data-open`)))});return e&&i.children==null?null:/* @__PURE__ */ v(o,{ref:c,type:`button`,"aria-controls":a.contentId,"aria-expanded":`false`,"aria-haspopup":`dialog`,...M(a,`show-modal`),...i,onClick:s})},pe=({asChild:e,onClick:t,scope:n,...r})=>{let i=y(n,`Close`),a=e?_:`button`,o=P({onClick:t,open:!1,root:i});return/* @__PURE__ */ v(a,{type:`button`,...M(i,`close`),...r,onClick:o})},me={display:`contents`},I=({"aria-describedby":e,"aria-label":t,"aria-labelledby":r,children:a,forceMount:l,inline:_=!1,layer:ne=!0,onCloseAutoFocus:ae,onEscapeKeyDown:S,onInteractOutside:C,onOpenAutoFocus:E,onPointerDownOutside:k,positionerClassName:M,positionerSlot:le,ref:fe,role:P,scope:F,...pe})=>{let I=y(F,`Content`),L=l===!0,R=o(null),z=o(null),B=o(null),he=f(fe,z),V=o(!1),ge=o(!1),[_e,ve]=s(!1),[ye,be]=s(I.open);ye!==I.open&&(be(I.open),ve(!I.open));let xe=L||I.open||_e,Se=m(),Ce=d(),H=Se??(Ce?document.body:null),U=L&&!I.controlled?void 0:I.open,W=u(()=>j({dialog:R.current,open:!1,root:I})),we=u(e=>{S?.(e),e.defaultPrevented||W()}),G=u(e=>{let t=R.current;t!=null&&re(t,e.target)?e.preventDefault():I.modal||de(e),we(e),e.preventDefault()}),K=u(e=>{let t=ue(e);return e.target instanceof Node&&R.current?.contains(e.target)||te(t),k?.(t),C?.(t),!t.defaultPrevented}),q=o(null),Te=o(!1),J=u(e=>{let t=e.ownerDocument.activeElement;t!==e&&e.contains(t)&&z.current?.contains(t)===!1&&e.focus({preventScroll:!0});let n=e.ownerDocument.activeElement;if(n instanceof HTMLElement){let e=n.matches(`:focus-visible`);(e?(w??!Te.current)&&!n.matches(`:read-write`):w===!1)&&(n.blur(),n.focus({focusVisible:!e,preventScroll:!0}))}if(E==null)return;let r=e.ownerDocument.activeElement;r!==e&&e.focus({preventScroll:!0}),!ce(z.current,`openAutoFocus`,E).defaultPrevented&&e.ownerDocument.activeElement===e&&r instanceof HTMLElement&&r.focus({preventScroll:!0})}),Y=o(!1),Ee=u(e=>{q.current=e.ownerDocument.activeElement,Te.current=q.current?.matches(`:focus-visible`)===!0,O({dialog:e,modal:I.modal,open:!0}),R.current===e?J(e):Y.current=!0}),De=u(()=>U===!0||U===void 0&&V.current),X=u(e=>{N(e)?queueMicrotask(()=>{R.current===e&&De()&&!e.open&&(N(e)?I.setOpen(!1):Ee(e))}):Ee(e)}),Oe=u(e=>{let t=e?.parentElement;t instanceof HTMLDialogElement&&U===!0&&!t.open&&X(t)}),Z=o(null),ke=u(e=>{let t=z.current;if(_||t==null||Z.current!=null)return;let n=p({container:e,content:t,escape:G});function r(){e.removeEventListener(`close`,i),Z.current=null,n()}function i(){e.open||r()}Z.current=r,e.addEventListener(`close`,i)}),Ae=u((e,t=!1)=>{let{ownerDocument:n}=e,{body:r}=n,i=t?r:n.activeElement,a=!x.has(e);if(a&&i instanceof HTMLElement&&i!==r&&i.blur(),ce(B.current,`closeAutoFocus`,ae).defaultPrevented||n.activeElement!==r)return;let o=n.querySelector(`[aria-controls="${e.id}"]`);for(let e of[a?i:null,q.current,o])if(e instanceof HTMLElement&&e!==r&&e.isConnected&&(e.focus(),n.activeElement===e))return}),Q=u(e=>{let{open:t}=e;T({dialog:e,open:t}),D({dialog:e,lock:t&&!x.has(e)}),t&&ke(e),t!==V.current&&(V.current=t,t?U===void 0&&J(e):queueMicrotask(()=>Ae(e)),t!==U&&(U===void 0?I.reportOpen(t):I.setOpen(t)))}),je=u(e=>{let t=e.currentTarget,n=Reflect.get(e,`command`);if(!(t instanceof HTMLDialogElement)||n!==`show-modal`&&n!==`close`&&n!==`request-close`)return;let r=n===`show-modal`;r&&N(t)?e.preventDefault():(e.preventDefault(),j({dialog:t,open:r,root:I}))}),Me=u(e=>{if(R.current=e,e==null)return;B.current=z.current,L&&oe.add(e);let t=new MutationObserver(()=>Q(e));return t.observe(e,{attributeFilter:[`open`]}),e.addEventListener(`command`,je),V.current=!1,Q(e),Y.current&&(Y.current=!1,J(e)),L&&!I.controlled&&I.defaultOpen&&!e.open&&(V.current=!0,X(e)),U===!0&&!e.open&&X(e),()=>{t.takeRecords().length>0&&Q(e),t.disconnect(),e.removeEventListener(`command`,je),T({dialog:e,open:!1}),D({dialog:e,lock:!1}),Z.current?.(),e.open&&queueMicrotask(()=>{e.isConnected||R.current!=null&&R.current!==e||Ae(e,!0)})}});i(()=>{let e=R.current;e!=null&&U!==void 0&&(U?e.open?T({dialog:e,open:!0}):X(e):A(e,L?void 0:()=>ve(!1)))},[U,L,X]),n(()=>(se(document),()=>Z.current?.()),[]);let Ne=I.open||U===void 0;if(n(()=>{let e=R.current;if(e==null||!Ne||_||!L&&H==null)return;let{ownerDocument:t}=e,n=t=>{t.key===`Escape`&&!t.defaultPrevented&&b.at(-1)===e&&G(t)},r=t=>{let{target:n}=t;!I.modal&&e.open&&b.at(-1)===e&&n instanceof Element&&!e.contains(n)&&n.closest(`[aria-controls="${e.id}"]`)==null&&h()?.closest(`body > *`)?.contains(n)!==!0&&K(t)&&W()},i=0,a=new MutationObserver(()=>{clearTimeout(i),i=window.setTimeout(()=>{e.open&&e.hasAttribute(`data-open`)&&!x.has(e)&&b.at(-1)===e&&t.activeElement===t.body&&e.focus({preventScroll:!0})})});return a.observe(e,{childList:!0,subtree:!0}),t.addEventListener(`keydown`,n),t.addEventListener(`pointerdown`,r,{capture:!0}),()=>{clearTimeout(i),a.disconnect(),t.removeEventListener(`keydown`,n),t.removeEventListener(`pointerdown`,r,{capture:!0})}},[I.modal,Ne,_,L,H,G,K,W]),!xe||!L&&H==null)return null;let $=/* @__PURE__ */ ie(`dialog`,{ref:Me,id:I.contentId,..._?{role:`generic`,style:me}:{role:P,tabIndex:-1,"aria-describedby":e,"aria-label":t,"aria-labelledby":r??(t==null?I.titleId:void 0)},className:ee(`group/native-dialog m-0 h-auto max-h-none w-auto max-w-none overflow-visible overscroll-none bg-transparent p-0 text-inherit outline-hidden [&[open]:not(:modal)]:pointer-events-none [&[open]:not(:modal)>*]:pointer-events-auto backdrop:bg-overlay backdrop:backdrop-blur-xs data-open:backdrop:animate-in data-open:backdrop:fade-in-0 data-closing:backdrop:animate-out data-closing:backdrop:fade-out-0 backdrop:duration-200 data-closing:backdrop:duration-150 motion-reduce:backdrop:animate-none!`,M),"data-overlay":``,"data-slot":le,onCancel:e=>{e.target===e.currentTarget&&(e.preventDefault(),W())},onSubmit:e=>{let{currentTarget:t,nativeEvent:n,target:r}=e;!e.defaultPrevented&&n instanceof SubmitEvent&&r instanceof HTMLFormElement&&r.closest(`dialog`)===t&&(n.submitter?.getAttribute(`formmethod`)?.toLowerCase()??r.method)===`dialog`&&(e.preventDefault(),W())},onPointerDown:e=>{ge.current=I.modal&&e.target===e.currentTarget&&K(e.nativeEvent)},onClick:e=>{ge.current&&e.target===e.currentTarget&&W()},children:[!L&&/* @__PURE__ */ v(`template`,{ref:Oe}),/* @__PURE__ */ v(g,{active:ne&&!_,modal:I.modal,className:`contents`,children:/* @__PURE__ */ v(`div`,{ref:he,"data-mantle-modal-content":_?void 0:``,...pe,children:a})})]});return L||H==null?$:c($,H)},L=({asChild:e,scope:t,...n})=>{let r=y(t,`Title`);return/* @__PURE__ */ v(e?_:`h2`,{id:r.titleId,...n})},R=({asChild:e,id:t,ref:n,scope:i,...a})=>{y(i,`Description`);let o=r(),s=t??o,c=f(n,e=>{let t=e?.closest(`dialog`);if(!(t==null||t.hasAttribute(`aria-describedby`)))return t.setAttribute(`aria-describedby`,s),()=>t.removeAttribute(`aria-describedby`)});return/* @__PURE__ */ v(e?_:`div`,{id:s,ref:c,...a})},z=({children:e})=>e,B=e=>null;export{z as a,F as c,O as d,B as i,A as l,I as n,fe as o,R as r,L as s,pe as t,ae as u};
@@ -0,0 +1,166 @@
1
+ import { ComponentProps, Context, ReactNode } from "react";
2
+ import { n as WithAsChild } from "./as-child-DFxX3U2i.js";
3
+ /**
4
+ * The behavior that `Dialog`, `AlertDialog`, and `Sheet` share: a `<dialog>`
5
+ * that the browser opens as a modal, makes the page inert behind, closes on
6
+ * Escape, paints in the top layer, and returns focus from.
7
+ * The parts here carry no look; each component composes its own presentation
8
+ * onto them.
9
+ *
10
+ * By default, `Content` mounts its children when the dialog opens and
11
+ * unmounts them after the exit animation, like a Radix dialog. With
12
+ * `forceMount`, the `<dialog>` and its children stay mounted and the server
13
+ * renders them: an uncontrolled tap then opens the dialog with DOM calls and
14
+ * no React render, even before hydration.
15
+ */
16
+ /** What every part reads from its `Root`. */
17
+ type RootState = {
18
+ /** The `id` of the `<dialog>`, which each trigger names in `aria-controls`. */
19
+ contentId: string;
20
+ /** The `id` of the title, which the `<dialog>` names in `aria-labelledby`. */
21
+ titleId: string;
22
+ /** Whether the owner sets `open`. */
23
+ controlled: boolean;
24
+ /** The open state that React holds: the `open` prop, else the uncontrolled state. */
25
+ open: boolean;
26
+ defaultOpen: boolean;
27
+ /** Whether the dialog opens as a modal. */
28
+ modal: boolean;
29
+ /** Asks for a new open state: sets the uncontrolled state, and tells the owner. */
30
+ setOpen: (open: boolean) => void;
31
+ /** Tells the owner of a change that the DOM already made. */
32
+ reportOpen: (open: boolean) => void;
33
+ };
34
+ /**
35
+ * The context that ties the parts of one component family to its `Root`. Each
36
+ * family makes its own with `createScope`, so a `Dialog.Trigger` inside a
37
+ * `Sheet.Content` binds to the enclosing `Dialog.Root`, not to the sheet.
38
+ */
39
+ type Scope = Context<RootState | null>;
40
+ /** What every part takes: the `Scope` of its family. */
41
+ type ScopeProps = {
42
+ scope: Scope;
43
+ };
44
+ /**
45
+ * The event that `onPointerDownOutside` and `onInteractOutside` get, as in
46
+ * Radix: a cancelable event at the pressed element, with the pointer event.
47
+ * Call `preventDefault()` to keep the dialog open.
48
+ */
49
+ type PointerDownOutsideEvent = CustomEvent<{
50
+ originalEvent: PointerEvent;
51
+ }>;
52
+ type RootProps = ScopeProps & {
53
+ children?: ReactNode;
54
+ /**
55
+ * Whether the dialog opens on mount, when `open` is not set.
56
+ *
57
+ * @default false
58
+ */
59
+ defaultOpen?: boolean;
60
+ /**
61
+ * Whether the dialog is modal: the page behind it is inert, and it paints in
62
+ * the top layer. Set `false` for a dialog that holds a flow whose frame a
63
+ * third-party script puts on `<body>`, such as a 3-D Secure challenge or a
64
+ * captcha: a modal dialog would make that frame inert and cover it.
65
+ *
66
+ * @default true
67
+ */
68
+ modal?: boolean;
69
+ /** Runs when the dialog opens or closes, with the new state. */
70
+ onOpenChange?: (open: boolean) => void;
71
+ /** The controlled open state. Pair it with `onOpenChange`. */
72
+ open?: boolean;
73
+ };
74
+ type ButtonProps = ComponentProps<"button"> & WithAsChild & ScopeProps;
75
+ /** A button that opens the dialog. */
76
+ declare const Trigger: ({ asChild, onClick, ref, scope, ...props }: ButtonProps) => import("react").JSX.Element | null;
77
+ /** A button that closes the dialog. */
78
+ declare const Close: ({ asChild, onClick, scope, ...props }: ButtonProps) => import("react").JSX.Element;
79
+ type ContentProps = ComponentProps<"div"> & ScopeProps & {
80
+ /**
81
+ * Whether the `<dialog>` and its children stay mounted while closed. The
82
+ * server renders them, and an uncontrolled tap opens the dialog with no
83
+ * React render, even before hydration. The page pays the HTML and the
84
+ * hydration of the content up front.
85
+ *
86
+ * @default false
87
+ */
88
+ forceMount?: true;
89
+ /**
90
+ * Whether the closed `<dialog>` shows its panel in the page, as
91
+ * `Sidebar.Nav` does above its breakpoint. An inline `<dialog>` has no
92
+ * box (`display: contents`), and it is neither a dialog nor a layer: it
93
+ * takes `role="generic"` and no name or description, and the floats
94
+ * inside portal as if it were not there. Needs `forceMount`.
95
+ *
96
+ * @default false
97
+ */
98
+ inline?: boolean;
99
+ /**
100
+ * Whether the floats inside portal into the `<dialog>`. Pass `false`
101
+ * while a `<dialog>` that stays mounted is closed, so a float that a
102
+ * shortcut opens there portals to the body and shows.
103
+ *
104
+ * @default true
105
+ */
106
+ layer?: boolean;
107
+ /**
108
+ * Runs after the dialog opens and the browser moves focus into it. Call
109
+ * `event.preventDefault()` and focus an element of your choice; with no
110
+ * focus move, the `<dialog>` takes focus.
111
+ */
112
+ onOpenAutoFocus?: (event: Event) => void;
113
+ /**
114
+ * Runs after the dialog closes and the browser returns focus to the
115
+ * element that opened it. Focus another element here to send focus there.
116
+ */
117
+ onCloseAutoFocus?: (event: Event) => void;
118
+ /** Runs on Escape. Call `event.preventDefault()` to keep the dialog open. */
119
+ onEscapeKeyDown?: (event: KeyboardEvent) => void;
120
+ /**
121
+ * Runs on a press outside the panel: on the backdrop, or, for a non-modal
122
+ * dialog, anywhere outside it. Call `event.preventDefault()` to keep the
123
+ * dialog open.
124
+ */
125
+ onPointerDownOutside?: (event: PointerDownOutsideEvent) => void;
126
+ /** Runs on the same presses as `onPointerDownOutside`, after it. */
127
+ onInteractOutside?: (event: PointerDownOutsideEvent) => void;
128
+ /** The classes of the `<dialog>`, which positions the panel. */
129
+ positionerClassName: string;
130
+ /** The `data-slot` of the `<dialog>`. */
131
+ positionerSlot: string;
132
+ /**
133
+ * The role of the `<dialog>`, such as `"alertdialog"` for a dialog that
134
+ * asks for an explicit response.
135
+ *
136
+ * @default "dialog"
137
+ */
138
+ role?: ComponentProps<"dialog">["role"];
139
+ };
140
+ /**
141
+ * The panel of the dialog, inside a `<dialog>` (`positionerSlot`) that is the
142
+ * layer container: a float composed inside portals into it and paints in the
143
+ * top layer with it. Style the panel with `data-open:` and
144
+ * `data-closing:`; the exit plays before the `<dialog>` closes.
145
+ */
146
+ declare const Content: ({ "aria-describedby": ariaDescribedBy, "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, children, forceMount, inline, layer, onCloseAutoFocus, onEscapeKeyDown, onInteractOutside, onOpenAutoFocus, onPointerDownOutside, positionerClassName, positionerSlot, ref, role, scope, ...props }: ContentProps) => import("react").JSX.Element | null;
147
+ /** The accessible name of the dialog. */
148
+ declare const Title: ({ asChild, scope, ...props }: Omit<ComponentProps<"h2">, "id"> & WithAsChild & ScopeProps) => import("react").JSX.Element;
149
+ /**
150
+ * The accessible description of the dialog. While it is mounted, the
151
+ * `<dialog>` names it in `aria-describedby`.
152
+ */
153
+ declare const Description: ({ asChild, id, ref, scope, ...props }: ComponentProps<"div"> & WithAsChild & ScopeProps) => import("react").JSX.Element;
154
+ /** Renders its children: a `<dialog>` paints in the top layer, so it needs no portal. */
155
+ declare const Portal: ({ children }: {
156
+ children?: ReactNode;
157
+ /** Accepted for compatibility; the `<dialog>` needs no container. */
158
+ container?: Element | DocumentFragment | null;
159
+ /** Accepted for compatibility; `Content` takes `forceMount`. */
160
+ forceMount?: true;
161
+ }) => ReactNode;
162
+ /** Renders nothing: `Content` styles the `<dialog>`'s `::backdrop` instead. */
163
+ declare const Overlay: (_props: ComponentProps<"div"> & {
164
+ forceMount?: true;
165
+ }) => null;
166
+ export { Portal as a, Trigger as c, Overlay as i, Content as n, RootProps as o, Description as r, Title as s, Close as t };
@@ -0,0 +1 @@
1
+ "use client";import{t as e}from"./compose-refs-Ce1vWUz0.js";import{t}from"./alert-DO00UiQe.js";import{jsx as n}from"react/jsx-runtime";const r=e=>e.nodeType===Node.ELEMENT_NODE,i=e=>{if(e==null||typeof ResizeObserver>`u`)return;let n=()=>{let n=(e.scrollHeight>e.clientHeight||e.scrollWidth>e.clientWidth)&&t(e).length===0;n&&!e.hasAttribute(`tabindex`)?e.setAttribute(`tabindex`,`0`):!n&&e.hasAttribute(`tabindex`)&&!e.matches(`:focus`)&&e.removeAttribute(`tabindex`)},i=new ResizeObserver(n);i.observe(e);for(let t of e.children)i.observe(t);let a=new MutationObserver(t=>{for(let n of t)if(n.target===e){for(let e of n.removedNodes)r(e)&&i.unobserve(e);for(let e of n.addedNodes)r(e)&&i.observe(e)}n()});return a.observe(e,{characterData:!0,childList:!0,subtree:!0,attributeFilter:[`disabled`,`hidden`,`href`,`inert`,`tabindex`]}),e.addEventListener(`focusout`,n),n(),()=>{e.removeEventListener(`focusout`,n),a.disconnect(),i.disconnect()}},a=({ref:t,...r})=>{let a=e(t,r.tabIndex==null?i:null);return/* @__PURE__ */ n(`div`,{ref:a,...r})};export{a as t};