@chassis-ui/react 0.4.0 → 0.5.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 +7 -6
  2. package/dist/accordion.d.ts +1 -1
  3. package/dist/accordion.js +1 -1
  4. package/dist/alert.d.ts +1 -1
  5. package/dist/alert.js +1 -1
  6. package/dist/autocomplete.d.ts +1 -1
  7. package/dist/autocomplete.js +1 -1
  8. package/dist/avatar.d.ts +1 -1
  9. package/dist/avatar.js +1 -1
  10. package/dist/badge.d.ts +1 -1
  11. package/dist/badge.js +1 -1
  12. package/dist/breadcrumb.d.ts +1 -1
  13. package/dist/breadcrumb.js +1 -1
  14. package/dist/button-group.d.ts +1 -1
  15. package/dist/button-group.js +1 -1
  16. package/dist/button.d.ts +2 -2
  17. package/dist/button.js +1 -1
  18. package/dist/calendar.d.ts +1 -1
  19. package/dist/calendar.js +1 -1
  20. package/dist/card.d.ts +1 -1
  21. package/dist/card.js +1 -1
  22. package/dist/carousel.d.ts +1 -1
  23. package/dist/carousel.js +1 -1
  24. package/dist/checkbox.d.ts +1 -1
  25. package/dist/checkbox.js +1 -1
  26. package/dist/chip-input.d.ts +1 -1
  27. package/dist/chip-input.js +1 -1
  28. package/dist/chip.d.ts +1 -1
  29. package/dist/chip.js +1 -1
  30. package/dist/chunks/{Button-BuZ_GOHS.d.ts → Button-DblYVwl-.d.ts} +4 -2
  31. package/dist/chunks/Button-ZU-x1uN_.js +2 -0
  32. package/dist/chunks/Button-ZU-x1uN_.js.map +1 -0
  33. package/dist/chunks/Chip-C7QlFCvx.js +2 -0
  34. package/dist/chunks/Chip-C7QlFCvx.js.map +1 -0
  35. package/dist/chunks/CloseButton-BPUI5iGX.js +2 -0
  36. package/dist/chunks/CloseButton-BPUI5iGX.js.map +1 -0
  37. package/dist/chunks/ComboboxListBox-Db0rSM3w.js +2 -0
  38. package/dist/chunks/ComboboxListBox-Db0rSM3w.js.map +1 -0
  39. package/dist/chunks/DateField-4cdcwt0v.js +2 -0
  40. package/dist/chunks/DateField-4cdcwt0v.js.map +1 -0
  41. package/dist/chunks/FormHelp-B1eSoack.js +2 -0
  42. package/dist/chunks/FormHelp-B1eSoack.js.map +1 -0
  43. package/dist/chunks/FormLabel-CpzWYh6U.js +2 -0
  44. package/dist/chunks/FormLabel-CpzWYh6U.js.map +1 -0
  45. package/dist/chunks/{Icon-DLB1f88W.js → Icon-Dk5_q79o.js} +2 -2
  46. package/dist/chunks/Icon-Dk5_q79o.js.map +1 -0
  47. package/dist/chunks/Link-DE8NSAXJ.js +2 -0
  48. package/dist/chunks/Link-DE8NSAXJ.js.map +1 -0
  49. package/dist/chunks/Menu-264aGoBR.js +2 -0
  50. package/dist/chunks/Menu-264aGoBR.js.map +1 -0
  51. package/dist/chunks/{Menu-QeYOzrUL.d.ts → Menu-CCYshRuL.d.ts} +3 -2
  52. package/dist/chunks/MenuToggle-DcPEh55c.js +2 -0
  53. package/dist/chunks/MenuToggle-DcPEh55c.js.map +1 -0
  54. package/dist/chunks/Portal-BTDylxAi.js +2 -0
  55. package/dist/chunks/Portal-BTDylxAi.js.map +1 -0
  56. package/dist/chunks/RangeCalendar-mM3OeTlU.js +2 -0
  57. package/dist/chunks/RangeCalendar-mM3OeTlU.js.map +1 -0
  58. package/dist/chunks/VisuallyHidden-CGv-mBuQ.js +2 -0
  59. package/dist/chunks/VisuallyHidden-CGv-mBuQ.js.map +1 -0
  60. package/dist/chunks/accordion-BZlX2uk8.js +2 -0
  61. package/dist/chunks/accordion-BZlX2uk8.js.map +1 -0
  62. package/dist/chunks/alert-DSLg5MBb.js +2 -0
  63. package/dist/chunks/alert-DSLg5MBb.js.map +1 -0
  64. package/dist/chunks/autocomplete-99usnvgh.js +2 -0
  65. package/dist/chunks/autocomplete-99usnvgh.js.map +1 -0
  66. package/dist/chunks/avatar-BQBbcnk6.js +2 -0
  67. package/dist/chunks/avatar-BQBbcnk6.js.map +1 -0
  68. package/dist/chunks/{badge-D2oztCvs.js → badge-Ths1Qn1a.js} +2 -2
  69. package/dist/chunks/badge-Ths1Qn1a.js.map +1 -0
  70. package/dist/chunks/breadcrumb-BTiQikk-.js +2 -0
  71. package/dist/chunks/breadcrumb-BTiQikk-.js.map +1 -0
  72. package/dist/chunks/breakpoints-CGk8szzR.js.map +1 -1
  73. package/dist/chunks/button-group-CefkGeYL.js +2 -0
  74. package/dist/chunks/button-group-CefkGeYL.js.map +1 -0
  75. package/dist/chunks/card-CEQgHIaL.js +2 -0
  76. package/dist/chunks/card-CEQgHIaL.js.map +1 -0
  77. package/dist/chunks/carousel-DC-UGc6W.js +2 -0
  78. package/dist/chunks/carousel-DC-UGc6W.js.map +1 -0
  79. package/dist/chunks/checkbox-ko6CdtoT.js +2 -0
  80. package/dist/chunks/checkbox-ko6CdtoT.js.map +1 -0
  81. package/dist/chunks/chip-input-CugY8EOc.js +2 -0
  82. package/dist/chunks/chip-input-CugY8EOc.js.map +1 -0
  83. package/dist/chunks/{collapse--Go2Y73B.js → collapse-CBi3RWTf.js} +2 -2
  84. package/dist/chunks/collapse-CBi3RWTf.js.map +1 -0
  85. package/dist/chunks/color-input-C4zMWlvm.js +2 -0
  86. package/dist/chunks/color-input-C4zMWlvm.js.map +1 -0
  87. package/dist/chunks/colorClassNames-YzGWu6qm.js +2 -0
  88. package/dist/chunks/colorClassNames-YzGWu6qm.js.map +1 -0
  89. package/dist/chunks/combobox-BQh3uJWB.js +2 -0
  90. package/dist/chunks/combobox-BQh3uJWB.js.map +1 -0
  91. package/dist/chunks/context-DCg95BgR.js +2 -0
  92. package/dist/chunks/context-DCg95BgR.js.map +1 -0
  93. package/dist/chunks/context-HDVxTNPi.js +2 -0
  94. package/dist/chunks/context-HDVxTNPi.js.map +1 -0
  95. package/dist/chunks/context-menu-8KIuH4cJ.js +2 -0
  96. package/dist/chunks/context-menu-8KIuH4cJ.js.map +1 -0
  97. package/dist/chunks/datagrid-n9vFeXN1.js +2 -0
  98. package/dist/chunks/datagrid-n9vFeXN1.js.map +1 -0
  99. package/dist/chunks/datepicker-DqztYJD6.js +2 -0
  100. package/dist/chunks/datepicker-DqztYJD6.js.map +1 -0
  101. package/dist/chunks/{dialogTransition-i9vw0i2Z.js → dialogTransition-C8fYTsSa.js} +2 -2
  102. package/dist/chunks/dialogTransition-C8fYTsSa.js.map +1 -0
  103. package/dist/chunks/direction-LN6uwsK5.js.map +1 -1
  104. package/dist/chunks/divider-C1-NoKMV.js +2 -0
  105. package/dist/chunks/divider-C1-NoKMV.js.map +1 -0
  106. package/dist/chunks/drawer-CRv9jmbp.js +2 -0
  107. package/dist/chunks/drawer-CRv9jmbp.js.map +1 -0
  108. package/dist/chunks/file-input-D_Gl1h-T.js +2 -0
  109. package/dist/chunks/file-input-D_Gl1h-T.js.map +1 -0
  110. package/dist/chunks/{flex-B52oLCCC.js → flex-C2jV5LyV.js} +2 -2
  111. package/dist/chunks/flex-C2jV5LyV.js.map +1 -0
  112. package/dist/chunks/floating-input-D4gWFfOU.js +2 -0
  113. package/dist/chunks/floating-input-D4gWFfOU.js.map +1 -0
  114. package/dist/chunks/focus-ring-Bs80iIBN.js +2 -0
  115. package/dist/chunks/focus-ring-Bs80iIBN.js.map +1 -0
  116. package/dist/chunks/focusRedirect-CrBl4p_n.js +2 -0
  117. package/dist/chunks/focusRedirect-CrBl4p_n.js.map +1 -0
  118. package/dist/chunks/form-CPS2eNw1.js +2 -0
  119. package/dist/chunks/form-CPS2eNw1.js.map +1 -0
  120. package/dist/chunks/{form-field-CNPGTMiW.js → form-field-Bcx96ezd.js} +2 -2
  121. package/dist/chunks/form-field-Bcx96ezd.js.map +1 -0
  122. package/dist/chunks/grid-CkdPftit.js +2 -0
  123. package/dist/chunks/grid-CkdPftit.js.map +1 -0
  124. package/dist/chunks/icon-CVD3rTr-.js +2 -0
  125. package/dist/chunks/icon-CVD3rTr-.js.map +1 -0
  126. package/dist/chunks/iconSlot-DU_WcSL_.js +2 -0
  127. package/dist/chunks/iconSlot-DU_WcSL_.js.map +1 -0
  128. package/dist/chunks/{index-91YA-jkp.d.ts → index-3JVLrDHv.d.ts} +11 -3
  129. package/dist/chunks/{index-DMbdEm__.d.ts → index-5mW1Y9Lm.d.ts} +7 -4
  130. package/dist/chunks/{index-Cc4SSslb.d.ts → index-5qsV1-cc.d.ts} +3 -3
  131. package/dist/chunks/{index-CYvVmTPR.d.ts → index-6PnrAJmb.d.ts} +4 -4
  132. package/dist/chunks/{index-BA-raEMm.d.ts → index-B5f6haU-.d.ts} +2 -2
  133. package/dist/chunks/{index-4cKG9KWB.d.ts → index-B8OIYfGw.d.ts} +2 -2
  134. package/dist/chunks/{index-CjT_4IZx.d.ts → index-BAvt_oPe.d.ts} +14 -5
  135. package/dist/chunks/{index-DtbUXxjz.d.ts → index-BB8UNxnM.d.ts} +2 -2
  136. package/dist/chunks/{index-aRdgpeRb.d.ts → index-BEAZrhyV.d.ts} +2 -2
  137. package/dist/chunks/{index-BOx8v-oT.d.ts → index-BISMaKaC.d.ts} +14 -2
  138. package/dist/chunks/{index-DtvHH_Mb.d.ts → index-BOroLDDZ.d.ts} +2 -2
  139. package/dist/chunks/{index-C4Dks__B.d.ts → index-BZpHSGlk.d.ts} +2 -2
  140. package/dist/chunks/{index-C9gzVqwX.d.ts → index-BbZzaApz.d.ts} +2 -2
  141. package/dist/chunks/{index-DAoPg59I.d.ts → index-Bca_HQWF.d.ts} +7 -3
  142. package/dist/chunks/{index-B0-8n-Gs.d.ts → index-Bl-_sC4y.d.ts} +12 -4
  143. package/dist/chunks/{index-BSLneLYu.d.ts → index-BxJ6Vrhm.d.ts} +2 -2
  144. package/dist/chunks/{index-CTpwB1yR.d.ts → index-BxrIOrAc.d.ts} +11 -6
  145. package/dist/chunks/{index-DHcztR18.d.ts → index-ByBbC4Jh.d.ts} +3 -3
  146. package/dist/chunks/{index-DHGgezXU.d.ts → index-C-IrFdKe.d.ts} +2 -2
  147. package/dist/chunks/{index-B8uaSJA9.d.ts → index-C0g8NSXY.d.ts} +13 -4
  148. package/dist/chunks/{index-CFnQubsV.d.ts → index-C1RKm3hQ.d.ts} +5 -3
  149. package/dist/chunks/{index-BxROljJI.d.ts → index-C3qqMzs5.d.ts} +2 -2
  150. package/dist/chunks/{index-Dcc_W6Kv.d.ts → index-C6F3DQCd.d.ts} +2 -2
  151. package/dist/chunks/{index-x0vZRyoU.d.ts → index-CEPAXElM.d.ts} +4 -3
  152. package/dist/chunks/{index-DaHQdNul.d.ts → index-COVY45gK.d.ts} +2 -2
  153. package/dist/chunks/{index-DJfga0Ce.d.ts → index-COq1jJ6Y.d.ts} +2 -2
  154. package/dist/chunks/{index-HrKN6s8z.d.ts → index-CSRGr7pU.d.ts} +2 -2
  155. package/dist/chunks/{index-B1kw0jzM.d.ts → index-CTNqEMug.d.ts} +6 -3
  156. package/dist/chunks/{index-6uob77s9.d.ts → index-CW94lG-e.d.ts} +7 -4
  157. package/dist/chunks/{index-Ddd7iWfm.d.ts → index-CY-A60p6.d.ts} +2 -2
  158. package/dist/chunks/{index-lSPcxiii.d.ts → index-CbcFEGCh.d.ts} +5 -3
  159. package/dist/chunks/{index-9rQeMqVI.d.ts → index-Ce0f-bDM.d.ts} +2 -2
  160. package/dist/chunks/{index-Ci7AEgEc.d.ts → index-Cf3gHDjh.d.ts} +2 -2
  161. package/dist/chunks/{index-BVGGIaPX.d.ts → index-Cm3rPbI1.d.ts} +10 -5
  162. package/dist/chunks/{index-DPCwFiJL.d.ts → index-CmljNQ8F.d.ts} +2 -2
  163. package/dist/chunks/{index-DQImhbhy.d.ts → index-Cpifcw5a.d.ts} +2 -2
  164. package/dist/chunks/{index-B_UzbGOa.d.ts → index-Ctf5hLue.d.ts} +3 -3
  165. package/dist/chunks/{index-DM01FX3a.d.ts → index-D0Dhs7YI.d.ts} +18 -6
  166. package/dist/chunks/{index-BAsbRx5n.d.ts → index-D5KJRfMg.d.ts} +2 -2
  167. package/dist/chunks/{index-Bz8MDq0H.d.ts → index-DD6Z5NW-.d.ts} +7 -4
  168. package/dist/chunks/{index-Dfg4Ftb8.d.ts → index-DFKBJxqA.d.ts} +7 -4
  169. package/dist/chunks/{index-BMkbJVHg.d.ts → index-DGGyvlEQ.d.ts} +3 -3
  170. package/dist/chunks/{index-YJ9QdBuq.d.ts → index-DOxVxbb9.d.ts} +6 -5
  171. package/dist/chunks/{index-CxjNw4ss.d.ts → index-DVK16_FU.d.ts} +2 -2
  172. package/dist/chunks/{index-DHOG_rjE.d.ts → index-DVfH_2Ma.d.ts} +7 -4
  173. package/dist/chunks/{index-0jbACjYQ.d.ts → index-DXBkVdWc.d.ts} +2 -2
  174. package/dist/chunks/{index-CsARGAzD.d.ts → index-Davd7Cue.d.ts} +10 -5
  175. package/dist/chunks/{index-Bi8FFadV.d.ts → index-Dc50UjJy.d.ts} +13 -4
  176. package/dist/chunks/{index-BF3OWUVc.d.ts → index-Dci43Xhl.d.ts} +3 -3
  177. package/dist/chunks/{index-B2K-O9kl.d.ts → index-DdFipHYL.d.ts} +5 -4
  178. package/dist/chunks/{index-Du9fBqkT.d.ts → index-DmmLEHVo.d.ts} +2 -2
  179. package/dist/chunks/{index-B5bF1JxF.d.ts → index-DsU3M0oP.d.ts} +3 -3
  180. package/dist/chunks/{index-DP5xugE-.d.ts → index-Es9I0fIS.d.ts} +3 -3
  181. package/dist/chunks/{index-CqZ68Z8R.d.ts → index-HNUhTj5e.d.ts} +25 -6
  182. package/dist/chunks/{index-CCXJXToc.d.ts → index-OnB4_h6x.d.ts} +7 -4
  183. package/dist/chunks/{index-CftERHnE.d.ts → index-QeI-KSng.d.ts} +3 -2
  184. package/dist/chunks/{index-BLS1jhSJ.d.ts → index-RyE80_VH.d.ts} +2 -2
  185. package/dist/chunks/{index-CIwzgZJi.d.ts → index-UjmJQRaG.d.ts} +2 -2
  186. package/dist/chunks/{index-B19ZH3fm.d.ts → index-YzIZhXZ1.d.ts} +2 -2
  187. package/dist/chunks/{index-CHQR8x8_.d.ts → index-Z_5ArZpE.d.ts} +4 -2
  188. package/dist/chunks/{index-BNf0jIIL.d.ts → index-doVyX-4i.d.ts} +7 -4
  189. package/dist/chunks/{index-NGgDkhyn.d.ts → index-mLtlx-d9.d.ts} +6 -3
  190. package/dist/chunks/{index-g74gO0pc.d.ts → index-sT0Hnr_n.d.ts} +12 -10
  191. package/dist/chunks/{index-Bkj17NEQ.d.ts → index-t3k_T3Dv.d.ts} +2 -2
  192. package/dist/chunks/{index-BfEJYF4c.d.ts → index-yVsGuikp.d.ts} +2 -2
  193. package/dist/chunks/input-adorn-DV9tuWXh.js +2 -0
  194. package/dist/chunks/input-adorn-DV9tuWXh.js.map +1 -0
  195. package/dist/chunks/input-group-YB_zoKud.js +2 -0
  196. package/dist/chunks/input-group-YB_zoKud.js.map +1 -0
  197. package/dist/chunks/insideEvents-CWcNrMu7.js +2 -0
  198. package/dist/chunks/insideEvents-CWcNrMu7.js.map +1 -0
  199. package/dist/chunks/lazyElement-tfMG21pZ.js.map +1 -1
  200. package/dist/chunks/list-BPBZR66Y.js +2 -0
  201. package/dist/chunks/list-BPBZR66Y.js.map +1 -0
  202. package/dist/chunks/menu-DEu-Nbv8.js +2 -0
  203. package/dist/chunks/menu-DEu-Nbv8.js.map +1 -0
  204. package/dist/chunks/modal-CHvsDTyl.js +2 -0
  205. package/dist/chunks/modal-CHvsDTyl.js.map +1 -0
  206. package/dist/chunks/nav-B4U_Hqs7.js +2 -0
  207. package/dist/chunks/nav-B4U_Hqs7.js.map +1 -0
  208. package/dist/chunks/nav-overflow-DpX_lRYf.js +2 -0
  209. package/dist/chunks/nav-overflow-DpX_lRYf.js.map +1 -0
  210. package/dist/chunks/navOverflow-C_QJmkPM.js +2 -0
  211. package/dist/chunks/navOverflow-C_QJmkPM.js.map +1 -0
  212. package/dist/chunks/{navVariant-DeGTk9B7.js → navVariant-D4wiKS8I.js} +2 -2
  213. package/dist/chunks/navVariant-D4wiKS8I.js.map +1 -0
  214. package/dist/chunks/navbar-C7dO0YRs.js +2 -0
  215. package/dist/chunks/navbar-C7dO0YRs.js.map +1 -0
  216. package/dist/chunks/notification-oIrUtDhl.js +2 -0
  217. package/dist/chunks/notification-oIrUtDhl.js.map +1 -0
  218. package/dist/chunks/number-field-ChPTSBwI.js +2 -0
  219. package/dist/chunks/number-field-ChPTSBwI.js.map +1 -0
  220. package/dist/chunks/otp-input-DUtCMg8P.js +2 -0
  221. package/dist/chunks/otp-input-DUtCMg8P.js.map +1 -0
  222. package/dist/chunks/{overlayPlacement-BtS90IVf.js → overlayPlacement-Q6bcbXA5.js} +2 -2
  223. package/dist/chunks/overlayPlacement-Q6bcbXA5.js.map +1 -0
  224. package/dist/chunks/overlayStack-BXtTGCRm.js +2 -0
  225. package/dist/chunks/overlayStack-BXtTGCRm.js.map +1 -0
  226. package/dist/chunks/pagination-Dvz8lccd.js +2 -0
  227. package/dist/chunks/pagination-Dvz8lccd.js.map +1 -0
  228. package/dist/chunks/{password-strength-DDK8pHRq.js → password-strength-Qg5GHBmu.js} +2 -2
  229. package/dist/chunks/password-strength-Qg5GHBmu.js.map +1 -0
  230. package/dist/chunks/placeholder-SPoVRkKE.js +2 -0
  231. package/dist/chunks/placeholder-SPoVRkKE.js.map +1 -0
  232. package/dist/chunks/polymorphic-CZIFszAy.js +2 -0
  233. package/dist/chunks/polymorphic-CZIFszAy.js.map +1 -0
  234. package/dist/chunks/popover-C_32yD9W.js +2 -0
  235. package/dist/chunks/popover-C_32yD9W.js.map +1 -0
  236. package/dist/chunks/progress-CiSJDNwx.js +2 -0
  237. package/dist/chunks/progress-CiSJDNwx.js.map +1 -0
  238. package/dist/chunks/radio-C42F_5OD.js +2 -0
  239. package/dist/chunks/radio-C42F_5OD.js.map +1 -0
  240. package/dist/chunks/range-input-DeZq_9S7.js +2 -0
  241. package/dist/chunks/range-input-DeZq_9S7.js.map +1 -0
  242. package/dist/chunks/renderFormCheck-DvpfK_I4.js +2 -0
  243. package/dist/chunks/renderFormCheck-DvpfK_I4.js.map +1 -0
  244. package/dist/chunks/renderFormField-_6WswnEX.js +2 -0
  245. package/dist/chunks/renderFormField-_6WswnEX.js.map +1 -0
  246. package/dist/chunks/renderMenuItemContent-DNdj-Ukz.js +2 -0
  247. package/dist/chunks/renderMenuItemContent-DNdj-Ukz.js.map +1 -0
  248. package/dist/chunks/scrollspy-BEZEVyIw.js +2 -0
  249. package/dist/chunks/scrollspy-BEZEVyIw.js.map +1 -0
  250. package/dist/chunks/scrollspy-D_lPjb92.js.map +1 -1
  251. package/dist/chunks/search-field-OFsb3t4L.js +2 -0
  252. package/dist/chunks/search-field-OFsb3t4L.js.map +1 -0
  253. package/dist/chunks/select-DwyL6aqY.js +2 -0
  254. package/dist/chunks/select-DwyL6aqY.js.map +1 -0
  255. package/dist/chunks/skeleton-B2blJGWj.js +2 -0
  256. package/dist/chunks/skeleton-B2blJGWj.js.map +1 -0
  257. package/dist/chunks/slot-BQVx1Eew.js +2 -0
  258. package/dist/chunks/slot-BQVx1Eew.js.map +1 -0
  259. package/dist/chunks/spacingClassName-DVhk8m3P.js.map +1 -1
  260. package/dist/chunks/spinner-D8lQCW4u.js +2 -0
  261. package/dist/chunks/spinner-D8lQCW4u.js.map +1 -0
  262. package/dist/chunks/stack-DtzW54UK.js +2 -0
  263. package/dist/chunks/stack-DtzW54UK.js.map +1 -0
  264. package/dist/chunks/static-table-C7ZtFQ66.js +2 -0
  265. package/dist/chunks/static-table-C7ZtFQ66.js.map +1 -0
  266. package/dist/chunks/stepper-tSA84huJ.js +2 -0
  267. package/dist/chunks/stepper-tSA84huJ.js.map +1 -0
  268. package/dist/chunks/switch-cp3IZg3L.js +2 -0
  269. package/dist/chunks/switch-cp3IZg3L.js.map +1 -0
  270. package/dist/chunks/table-CBTg5Yuq.js +2 -0
  271. package/dist/chunks/table-CBTg5Yuq.js.map +1 -0
  272. package/dist/chunks/tableClassName-jRfRDXA3.js +2 -0
  273. package/dist/chunks/tableClassName-jRfRDXA3.js.map +1 -0
  274. package/dist/chunks/tabs-DMFSLjnV.js +2 -0
  275. package/dist/chunks/tabs-DMFSLjnV.js.map +1 -0
  276. package/dist/chunks/text-input-CR73x-8D.js +2 -0
  277. package/dist/chunks/text-input-CR73x-8D.js.map +1 -0
  278. package/dist/chunks/textarea-C-1cMyH4.js +2 -0
  279. package/dist/chunks/textarea-C-1cMyH4.js.map +1 -0
  280. package/dist/chunks/time-field-CbCfOQZz.js +2 -0
  281. package/dist/chunks/time-field-CbCfOQZz.js.map +1 -0
  282. package/dist/chunks/toast-Dd0J2e1z.js +2 -0
  283. package/dist/chunks/toast-Dd0J2e1z.js.map +1 -0
  284. package/dist/chunks/tooltip-CmKeQwYw.js +2 -0
  285. package/dist/chunks/tooltip-CmKeQwYw.js.map +1 -0
  286. package/dist/chunks/tree-DNj_EfUl.js +2 -0
  287. package/dist/chunks/tree-DNj_EfUl.js.map +1 -0
  288. package/dist/chunks/unhandledProps-9Kdj7WVf.js.map +1 -1
  289. package/dist/chunks/{useButtonSemantics-CILM_lhi.js → useButtonSemantics-B1SbGaDO.js} +2 -2
  290. package/dist/chunks/useButtonSemantics-B1SbGaDO.js.map +1 -0
  291. package/dist/chunks/useControllableState-CPUJxfKW.js.map +1 -1
  292. package/dist/chunks/useDialogElement-BfygWBPZ.js +2 -0
  293. package/dist/chunks/useDialogElement-BfygWBPZ.js.map +1 -0
  294. package/dist/chunks/useDialogTitle-DiB4YDGI.js +2 -0
  295. package/dist/chunks/useDialogTitle-DiB4YDGI.js.map +1 -0
  296. package/dist/chunks/useDisabledAnchorGuard-CH6df46a.js +2 -0
  297. package/dist/chunks/useDisabledAnchorGuard-CH6df46a.js.map +1 -0
  298. package/dist/chunks/useFloatingOverlay-BuiI_CCn.js +2 -0
  299. package/dist/chunks/useFloatingOverlay-BuiI_CCn.js.map +1 -0
  300. package/dist/chunks/useForkedRef-WoqMqsWE.js +2 -0
  301. package/dist/chunks/useForkedRef-WoqMqsWE.js.map +1 -0
  302. package/dist/chunks/useFormField-DH2tlc3e.js +2 -0
  303. package/dist/chunks/useFormField-DH2tlc3e.js.map +1 -0
  304. package/dist/chunks/useHeldBack-eeTfpa_t.js +2 -0
  305. package/dist/chunks/useHeldBack-eeTfpa_t.js.map +1 -0
  306. package/dist/chunks/useHydrated-Dud4JEwp.js +2 -0
  307. package/dist/chunks/useHydrated-Dud4JEwp.js.map +1 -0
  308. package/dist/chunks/useIsomorphicLayoutEffect-BbqRwuqn.js.map +1 -1
  309. package/dist/chunks/{useOpenStateProps-DykUbnPJ.js → useOpenStateProps-BhjSQ3f6.js} +2 -2
  310. package/dist/chunks/useOpenStateProps-BhjSQ3f6.js.map +1 -0
  311. package/dist/chunks/useOverlayMaxHeight-8mQL2Q6d.js +2 -0
  312. package/dist/chunks/useOverlayMaxHeight-8mQL2Q6d.js.map +1 -0
  313. package/dist/chunks/useRequiredValueInput-gYN8I-LY.js +2 -0
  314. package/dist/chunks/useRequiredValueInput-gYN8I-LY.js.map +1 -0
  315. package/dist/chunks/useToastRegionQueue-CuAMxAIA.js +2 -0
  316. package/dist/chunks/useToastRegionQueue-CuAMxAIA.js.map +1 -0
  317. package/dist/chunks/{useTransitionState-e5ToY7eX.js → useTransitionState-sQUQey74.js} +2 -2
  318. package/dist/chunks/useTransitionState-sQUQey74.js.map +1 -0
  319. package/dist/chunks/validationClassName-gRGs4KBm.js.map +1 -1
  320. package/dist/chunks/{visibleState-B_i1zHu2.js → visibleState-CWyQak65.js} +2 -2
  321. package/dist/chunks/visibleState-CWyQak65.js.map +1 -0
  322. package/dist/close-button.d.ts +1 -1
  323. package/dist/close-button.js +1 -1
  324. package/dist/collapse.d.ts +1 -1
  325. package/dist/collapse.js +1 -1
  326. package/dist/color-input.d.ts +1 -1
  327. package/dist/color-input.js +1 -1
  328. package/dist/combobox.d.ts +1 -1
  329. package/dist/combobox.js +1 -1
  330. package/dist/context-menu.d.ts +1 -1
  331. package/dist/context-menu.js +1 -1
  332. package/dist/datagrid.d.ts +1 -1
  333. package/dist/datagrid.js +1 -1
  334. package/dist/datepicker.d.ts +1 -1
  335. package/dist/datepicker.js +1 -1
  336. package/dist/divider.d.ts +1 -1
  337. package/dist/divider.js +1 -1
  338. package/dist/drawer.d.ts +1 -1
  339. package/dist/drawer.js +1 -1
  340. package/dist/file-input.d.ts +1 -1
  341. package/dist/file-input.js +1 -1
  342. package/dist/flex.d.ts +1 -1
  343. package/dist/flex.js +1 -1
  344. package/dist/floating-input.d.ts +1 -1
  345. package/dist/floating-input.js +1 -1
  346. package/dist/form-field.d.ts +1 -1
  347. package/dist/form-field.js +1 -1
  348. package/dist/form.d.ts +1 -1
  349. package/dist/form.js +1 -1
  350. package/dist/grid.d.ts +1 -1
  351. package/dist/grid.js +1 -1
  352. package/dist/icon.d.ts +1 -1
  353. package/dist/icon.js +1 -1
  354. package/dist/index.d.ts +68 -68
  355. package/dist/index.js +1 -1
  356. package/dist/input-adorn.d.ts +1 -1
  357. package/dist/input-adorn.js +1 -1
  358. package/dist/input-group.d.ts +1 -1
  359. package/dist/input-group.js +1 -1
  360. package/dist/link.d.ts +1 -1
  361. package/dist/link.js +1 -1
  362. package/dist/list.d.ts +1 -1
  363. package/dist/list.js +1 -1
  364. package/dist/menu.d.ts +2 -2
  365. package/dist/menu.js +1 -1
  366. package/dist/modal.d.ts +1 -1
  367. package/dist/modal.js +1 -1
  368. package/dist/nav-overflow.d.ts +1 -1
  369. package/dist/nav-overflow.js +1 -1
  370. package/dist/nav.d.ts +1 -1
  371. package/dist/nav.js +1 -1
  372. package/dist/navbar.d.ts +1 -1
  373. package/dist/navbar.js +1 -1
  374. package/dist/notification.d.ts +1 -1
  375. package/dist/notification.js +1 -1
  376. package/dist/number-field.d.ts +1 -1
  377. package/dist/number-field.js +1 -1
  378. package/dist/otp-input.d.ts +1 -1
  379. package/dist/otp-input.js +1 -1
  380. package/dist/pagination.d.ts +1 -1
  381. package/dist/pagination.js +1 -1
  382. package/dist/password-strength.d.ts +1 -1
  383. package/dist/password-strength.js +1 -1
  384. package/dist/placeholder.d.ts +1 -1
  385. package/dist/placeholder.js +1 -1
  386. package/dist/popover.d.ts +1 -1
  387. package/dist/popover.js +1 -1
  388. package/dist/portal.d.ts +1 -1
  389. package/dist/portal.js +1 -1
  390. package/dist/progress.d.ts +1 -1
  391. package/dist/progress.js +1 -1
  392. package/dist/radio.d.ts +1 -1
  393. package/dist/radio.js +1 -1
  394. package/dist/range-input.d.ts +1 -1
  395. package/dist/range-input.js +1 -1
  396. package/dist/scrollspy.d.ts +1 -1
  397. package/dist/scrollspy.js +1 -1
  398. package/dist/search-field.d.ts +1 -1
  399. package/dist/search-field.js +1 -1
  400. package/dist/select.d.ts +1 -1
  401. package/dist/select.js +1 -1
  402. package/dist/skeleton.d.ts +1 -1
  403. package/dist/skeleton.js +1 -1
  404. package/dist/spinner.d.ts +1 -1
  405. package/dist/spinner.js +1 -1
  406. package/dist/stack.d.ts +1 -1
  407. package/dist/stack.js +1 -1
  408. package/dist/static-table.js +1 -1
  409. package/dist/stepper.d.ts +1 -1
  410. package/dist/stepper.js +1 -1
  411. package/dist/style.css +1 -1
  412. package/dist/switch.d.ts +1 -1
  413. package/dist/switch.js +1 -1
  414. package/dist/table.d.ts +1 -1
  415. package/dist/table.js +1 -1
  416. package/dist/tabs.d.ts +1 -1
  417. package/dist/tabs.js +1 -1
  418. package/dist/text-input.d.ts +1 -1
  419. package/dist/text-input.js +1 -1
  420. package/dist/textarea.d.ts +1 -1
  421. package/dist/textarea.js +1 -1
  422. package/dist/time-field.d.ts +1 -1
  423. package/dist/time-field.js +1 -1
  424. package/dist/toast.d.ts +1 -1
  425. package/dist/toast.js +1 -1
  426. package/dist/tooltip.d.ts +1 -1
  427. package/dist/tooltip.js +1 -1
  428. package/dist/tree.d.ts +1 -1
  429. package/dist/tree.js +1 -1
  430. package/dist/visually-hidden.d.ts +1 -1
  431. package/dist/visually-hidden.js +1 -1
  432. package/package.json +29 -28
  433. package/dist/chunks/Button-BoymWE-L.js +0 -2
  434. package/dist/chunks/Button-BoymWE-L.js.map +0 -1
  435. package/dist/chunks/Chip-DCaWaBqo.js +0 -2
  436. package/dist/chunks/Chip-DCaWaBqo.js.map +0 -1
  437. package/dist/chunks/CloseButton-DPgQztE0.js +0 -2
  438. package/dist/chunks/CloseButton-DPgQztE0.js.map +0 -1
  439. package/dist/chunks/ComboboxListBox-Cm3L1ULl.js +0 -2
  440. package/dist/chunks/ComboboxListBox-Cm3L1ULl.js.map +0 -1
  441. package/dist/chunks/DateSegment-2agXAd0f.js +0 -2
  442. package/dist/chunks/DateSegment-2agXAd0f.js.map +0 -1
  443. package/dist/chunks/FormHelp-AE6_iSLJ.js +0 -2
  444. package/dist/chunks/FormHelp-AE6_iSLJ.js.map +0 -1
  445. package/dist/chunks/FormLabel-CYcQiFUI.js +0 -2
  446. package/dist/chunks/FormLabel-CYcQiFUI.js.map +0 -1
  447. package/dist/chunks/Icon-DLB1f88W.js.map +0 -1
  448. package/dist/chunks/Link-CZsWCnQb.js +0 -2
  449. package/dist/chunks/Link-CZsWCnQb.js.map +0 -1
  450. package/dist/chunks/Menu-CSBg2Zmc.js +0 -2
  451. package/dist/chunks/Menu-CSBg2Zmc.js.map +0 -1
  452. package/dist/chunks/MenuToggle-BdQtF7FV.js +0 -2
  453. package/dist/chunks/MenuToggle-BdQtF7FV.js.map +0 -1
  454. package/dist/chunks/Portal-CgeR1WXV.js +0 -2
  455. package/dist/chunks/Portal-CgeR1WXV.js.map +0 -1
  456. package/dist/chunks/RangeCalendar-BJl-j4W2.js +0 -2
  457. package/dist/chunks/RangeCalendar-BJl-j4W2.js.map +0 -1
  458. package/dist/chunks/VisuallyHidden-C2dM7HhC.js +0 -2
  459. package/dist/chunks/VisuallyHidden-C2dM7HhC.js.map +0 -1
  460. package/dist/chunks/accordion-B8UWyvQB.js +0 -2
  461. package/dist/chunks/accordion-B8UWyvQB.js.map +0 -1
  462. package/dist/chunks/alert-BXI-_qlt.js +0 -2
  463. package/dist/chunks/alert-BXI-_qlt.js.map +0 -1
  464. package/dist/chunks/autocomplete-Baf9VSHN.js +0 -2
  465. package/dist/chunks/autocomplete-Baf9VSHN.js.map +0 -1
  466. package/dist/chunks/avatar-S3dGy6Qc.js +0 -2
  467. package/dist/chunks/avatar-S3dGy6Qc.js.map +0 -1
  468. package/dist/chunks/badge-D2oztCvs.js.map +0 -1
  469. package/dist/chunks/breadcrumb-s6J9itez.js +0 -2
  470. package/dist/chunks/breadcrumb-s6J9itez.js.map +0 -1
  471. package/dist/chunks/button-group-BGppPrIv.js +0 -2
  472. package/dist/chunks/button-group-BGppPrIv.js.map +0 -1
  473. package/dist/chunks/card-CobeDpf1.js +0 -2
  474. package/dist/chunks/card-CobeDpf1.js.map +0 -1
  475. package/dist/chunks/carousel-fTVPqnSV.js +0 -2
  476. package/dist/chunks/carousel-fTVPqnSV.js.map +0 -1
  477. package/dist/chunks/checkbox-ZyQn5Ku5.js +0 -2
  478. package/dist/chunks/checkbox-ZyQn5Ku5.js.map +0 -1
  479. package/dist/chunks/chip-input-BpVDRERg.js +0 -2
  480. package/dist/chunks/chip-input-BpVDRERg.js.map +0 -1
  481. package/dist/chunks/collapse--Go2Y73B.js.map +0 -1
  482. package/dist/chunks/color-input-Bwl5ef5B.js +0 -2
  483. package/dist/chunks/color-input-Bwl5ef5B.js.map +0 -1
  484. package/dist/chunks/combobox-Bp1tIaiW.js +0 -2
  485. package/dist/chunks/combobox-Bp1tIaiW.js.map +0 -1
  486. package/dist/chunks/context-menu-B4a0tS-h.js +0 -2
  487. package/dist/chunks/context-menu-B4a0tS-h.js.map +0 -1
  488. package/dist/chunks/datagrid-CH3Cy-q7.js +0 -3
  489. package/dist/chunks/datagrid-CH3Cy-q7.js.map +0 -1
  490. package/dist/chunks/datepicker-bOiM_zhJ.js +0 -2
  491. package/dist/chunks/datepicker-bOiM_zhJ.js.map +0 -1
  492. package/dist/chunks/dialogTransition-i9vw0i2Z.js.map +0 -1
  493. package/dist/chunks/divider-CjbF4OfA.js +0 -2
  494. package/dist/chunks/divider-CjbF4OfA.js.map +0 -1
  495. package/dist/chunks/drawer-C7Tz4XU_.js +0 -2
  496. package/dist/chunks/drawer-C7Tz4XU_.js.map +0 -1
  497. package/dist/chunks/file-input-CDM6qrmV.js +0 -2
  498. package/dist/chunks/file-input-CDM6qrmV.js.map +0 -1
  499. package/dist/chunks/flex-B52oLCCC.js.map +0 -1
  500. package/dist/chunks/floating-input-DmSZZc27.js +0 -2
  501. package/dist/chunks/floating-input-DmSZZc27.js.map +0 -1
  502. package/dist/chunks/focus-ring-SR_LwaN7.js +0 -2
  503. package/dist/chunks/focus-ring-SR_LwaN7.js.map +0 -1
  504. package/dist/chunks/focusRedirect-BrvK3U_o.js +0 -2
  505. package/dist/chunks/focusRedirect-BrvK3U_o.js.map +0 -1
  506. package/dist/chunks/form-GpdAyWWi.js +0 -2
  507. package/dist/chunks/form-GpdAyWWi.js.map +0 -1
  508. package/dist/chunks/form-field-CNPGTMiW.js.map +0 -1
  509. package/dist/chunks/grid-C7tO-ppc.js +0 -2
  510. package/dist/chunks/grid-C7tO-ppc.js.map +0 -1
  511. package/dist/chunks/icon-BQsT6YtE.js +0 -2
  512. package/dist/chunks/icon-BQsT6YtE.js.map +0 -1
  513. package/dist/chunks/iconSlot-BNu2MrFI.js +0 -2
  514. package/dist/chunks/iconSlot-BNu2MrFI.js.map +0 -1
  515. package/dist/chunks/input-adorn-DwdX-jxA.js +0 -2
  516. package/dist/chunks/input-adorn-DwdX-jxA.js.map +0 -1
  517. package/dist/chunks/input-group-Cuiuf4Dl.js +0 -2
  518. package/dist/chunks/input-group-Cuiuf4Dl.js.map +0 -1
  519. package/dist/chunks/list-BQCkwWjF.js +0 -2
  520. package/dist/chunks/list-BQCkwWjF.js.map +0 -1
  521. package/dist/chunks/menu-98EAD9nj.js +0 -2
  522. package/dist/chunks/menu-98EAD9nj.js.map +0 -1
  523. package/dist/chunks/modal-bgDR29Jh.js +0 -2
  524. package/dist/chunks/modal-bgDR29Jh.js.map +0 -1
  525. package/dist/chunks/nav-TiZuTHC6.js +0 -2
  526. package/dist/chunks/nav-TiZuTHC6.js.map +0 -1
  527. package/dist/chunks/nav-overflow-Ay5mM5Gc.js +0 -2
  528. package/dist/chunks/nav-overflow-Ay5mM5Gc.js.map +0 -1
  529. package/dist/chunks/navOverflow-B5krZe6D.js +0 -2
  530. package/dist/chunks/navOverflow-B5krZe6D.js.map +0 -1
  531. package/dist/chunks/navVariant-DeGTk9B7.js.map +0 -1
  532. package/dist/chunks/navbar-DxIwt0sc.js +0 -2
  533. package/dist/chunks/navbar-DxIwt0sc.js.map +0 -1
  534. package/dist/chunks/notification-Dbci5Ka3.js +0 -2
  535. package/dist/chunks/notification-Dbci5Ka3.js.map +0 -1
  536. package/dist/chunks/number-field-IBIX2IWH.js +0 -2
  537. package/dist/chunks/number-field-IBIX2IWH.js.map +0 -1
  538. package/dist/chunks/otp-input-ws393uPB.js +0 -2
  539. package/dist/chunks/otp-input-ws393uPB.js.map +0 -1
  540. package/dist/chunks/overlayPlacement-BtS90IVf.js.map +0 -1
  541. package/dist/chunks/pagination-BkOquk-x.js +0 -2
  542. package/dist/chunks/pagination-BkOquk-x.js.map +0 -1
  543. package/dist/chunks/password-strength-DDK8pHRq.js.map +0 -1
  544. package/dist/chunks/placeholder-BCr83sUn.js +0 -2
  545. package/dist/chunks/placeholder-BCr83sUn.js.map +0 -1
  546. package/dist/chunks/polymorphic-BhGNZQja.js +0 -2
  547. package/dist/chunks/polymorphic-BhGNZQja.js.map +0 -1
  548. package/dist/chunks/popover-Bdg8D4sm.js +0 -2
  549. package/dist/chunks/popover-Bdg8D4sm.js.map +0 -1
  550. package/dist/chunks/progress-zWkTltor.js +0 -2
  551. package/dist/chunks/progress-zWkTltor.js.map +0 -1
  552. package/dist/chunks/radio-B6gJdtoN.js +0 -2
  553. package/dist/chunks/radio-B6gJdtoN.js.map +0 -1
  554. package/dist/chunks/range-input-CT_8TKL7.js +0 -2
  555. package/dist/chunks/range-input-CT_8TKL7.js.map +0 -1
  556. package/dist/chunks/renderFormCheck-DN_-V62U.js +0 -2
  557. package/dist/chunks/renderFormCheck-DN_-V62U.js.map +0 -1
  558. package/dist/chunks/renderFormField-Brkw1yA6.js +0 -2
  559. package/dist/chunks/renderFormField-Brkw1yA6.js.map +0 -1
  560. package/dist/chunks/renderMenuItemContent-DUezZrpj.js +0 -2
  561. package/dist/chunks/renderMenuItemContent-DUezZrpj.js.map +0 -1
  562. package/dist/chunks/scrollspy-C2HmrnZ4.js +0 -2
  563. package/dist/chunks/scrollspy-C2HmrnZ4.js.map +0 -1
  564. package/dist/chunks/search-field--nDoCI_E.js +0 -2
  565. package/dist/chunks/search-field--nDoCI_E.js.map +0 -1
  566. package/dist/chunks/select-BwJIfv9f.js +0 -2
  567. package/dist/chunks/select-BwJIfv9f.js.map +0 -1
  568. package/dist/chunks/skeleton-CmZBLJwp.js +0 -2
  569. package/dist/chunks/skeleton-CmZBLJwp.js.map +0 -1
  570. package/dist/chunks/slot-CNhFZdHF.js +0 -2
  571. package/dist/chunks/slot-CNhFZdHF.js.map +0 -1
  572. package/dist/chunks/spinner-DblhvrHL.js +0 -2
  573. package/dist/chunks/spinner-DblhvrHL.js.map +0 -1
  574. package/dist/chunks/stack-DK5F53VT.js +0 -2
  575. package/dist/chunks/stack-DK5F53VT.js.map +0 -1
  576. package/dist/chunks/static-table-D0M4oc_t.js +0 -2
  577. package/dist/chunks/static-table-D0M4oc_t.js.map +0 -1
  578. package/dist/chunks/stepper-CVXMJ2yg.js +0 -2
  579. package/dist/chunks/stepper-CVXMJ2yg.js.map +0 -1
  580. package/dist/chunks/switch-C6s3LxEv.js +0 -2
  581. package/dist/chunks/switch-C6s3LxEv.js.map +0 -1
  582. package/dist/chunks/table-Cy6uEuEP.js +0 -2
  583. package/dist/chunks/table-Cy6uEuEP.js.map +0 -1
  584. package/dist/chunks/tableClassName-CZA2Bse8.js +0 -2
  585. package/dist/chunks/tableClassName-CZA2Bse8.js.map +0 -1
  586. package/dist/chunks/tabs-91T7-8qq.js +0 -2
  587. package/dist/chunks/tabs-91T7-8qq.js.map +0 -1
  588. package/dist/chunks/text-input-B4pTv6SU.js +0 -2
  589. package/dist/chunks/text-input-B4pTv6SU.js.map +0 -1
  590. package/dist/chunks/textarea-1A1nABQE.js +0 -2
  591. package/dist/chunks/textarea-1A1nABQE.js.map +0 -1
  592. package/dist/chunks/time-field-B3MA7ED_.js +0 -2
  593. package/dist/chunks/time-field-B3MA7ED_.js.map +0 -1
  594. package/dist/chunks/toast-CGHl3-oU.js +0 -2
  595. package/dist/chunks/toast-CGHl3-oU.js.map +0 -1
  596. package/dist/chunks/tooltip-Bc-u6nIW.js +0 -2
  597. package/dist/chunks/tooltip-Bc-u6nIW.js.map +0 -1
  598. package/dist/chunks/tree-Cql1veeZ.js +0 -2
  599. package/dist/chunks/tree-Cql1veeZ.js.map +0 -1
  600. package/dist/chunks/useButtonSemantics-CILM_lhi.js.map +0 -1
  601. package/dist/chunks/useDialogElement-CgOnJAzu.js +0 -2
  602. package/dist/chunks/useDialogElement-CgOnJAzu.js.map +0 -1
  603. package/dist/chunks/useDisabledAnchorGuard-Cz58UCXy.js +0 -2
  604. package/dist/chunks/useDisabledAnchorGuard-Cz58UCXy.js.map +0 -1
  605. package/dist/chunks/useFloatingOverlay-DLIvwx-8.js +0 -2
  606. package/dist/chunks/useFloatingOverlay-DLIvwx-8.js.map +0 -1
  607. package/dist/chunks/useForkedRef-DVEfT-KI.js +0 -2
  608. package/dist/chunks/useForkedRef-DVEfT-KI.js.map +0 -1
  609. package/dist/chunks/useFormField-BOqmBTC4.js +0 -2
  610. package/dist/chunks/useFormField-BOqmBTC4.js.map +0 -1
  611. package/dist/chunks/useOpenStateProps-DykUbnPJ.js.map +0 -1
  612. package/dist/chunks/useToastRegionQueue-CIV5SdiE.js +0 -2
  613. package/dist/chunks/useToastRegionQueue-CIV5SdiE.js.map +0 -1
  614. package/dist/chunks/useTransitionState-e5ToY7eX.js.map +0 -1
  615. package/dist/chunks/visibleState-B_i1zHu2.js.map +0 -1
package/README.md CHANGED
@@ -1,7 +1,7 @@
1
1
  <p align="center">
2
2
  <a href="https://chassis-ui.com/react">
3
3
  <img
4
- src="https://chassis-ui.com/static/images/site-logo.svg"
4
+ src="https://chassis-ui.com/static/images/logo/chassis-logo-brand.svg"
5
5
  alt="Chassis UI Logo"
6
6
  width="300"
7
7
  />
@@ -30,7 +30,7 @@ The components render `@chassis-ui/css`'s markup and class names, so install bot
30
30
  npm install @chassis-ui/react @chassis-ui/css
31
31
  ```
32
32
 
33
- `@chassis-ui/css` is a peer dependency, pinned to one 0.x minor (`>=0.7.0 <0.8.0` today): before
33
+ `@chassis-ui/css` is a peer dependency, pinned to one 0.x minor (`>=0.10.0 <0.11.0` today): before
34
34
  1.0 a minor release of it can rename the tokens the components rely on.
35
35
 
36
36
  ## Stylesheets
@@ -42,9 +42,10 @@ import '@chassis-ui/css/dist/css/chassis.min.css'
42
42
  import '@chassis-ui/react/style.css'
43
43
  ```
44
44
 
45
- `@chassis-ui/react/style.css` covers the few pieces with no `@chassis-ui/css` equivalent:
46
- `Calendar`, `RangeCalendar`, `DatePicker`, `DateRangePicker`, and `Table`'s sort and selection UI.
47
- Without it those pieces render unstyled; everything else is styled by `@chassis-ui/css` alone.
45
+ `@chassis-ui/react/style.css` covers the pieces with no `@chassis-ui/css` equivalent: the
46
+ calendars and date pickers, `TimeField`, `NumberField`, `SearchField`, `DataGrid`, `Tree`,
47
+ `Notification`'s fade, `Divider`'s label, `Table`'s sort and selection UI and `Progress`'s
48
+ indeterminate bar. Without it those pieces render unstyled; everything else is styled by `@chassis-ui/css` alone.
48
49
 
49
50
  ## Usage
50
51
 
@@ -92,7 +93,7 @@ examples.
92
93
  ## Peer dependencies
93
94
 
94
95
  - `react` and `react-dom`: `^19.0.0`
95
- - `@chassis-ui/css`: `>=0.7.0 <0.8.0`
96
+ - `@chassis-ui/css`: `>=0.11.0 <0.12.0`
96
97
 
97
98
  ## Browser support
98
99
 
@@ -1,2 +1,2 @@
1
- import { a as AccordionBody, c as AccordionItemDef, i as AccordionHeaderProps, l as AccordionProps, n as AccordionItemProps, o as AccordionBodyProps, r as AccordionHeader, s as Accordion, t as AccordionItem } from "./chunks/index-Dcc_W6Kv.js";
1
+ import { a as AccordionBody, c as AccordionItemDef, i as AccordionHeaderProps, l as AccordionProps, n as AccordionItemProps, o as AccordionBodyProps, r as AccordionHeader, s as Accordion, t as AccordionItem } from "./chunks/index-C6F3DQCd.js";
2
2
  export { Accordion, AccordionBody, type AccordionBodyProps, AccordionHeader, type AccordionHeaderProps, AccordionItem, type AccordionItemDef, type AccordionItemProps, type AccordionProps };
package/dist/accordion.js CHANGED
@@ -1 +1 @@
1
- "use client";import{i as e,n as t,r as n,t as r}from"./chunks/accordion-B8UWyvQB.js";export{r as Accordion,e as AccordionBody,n as AccordionHeader,t as AccordionItem};
1
+ "use client";export{t as Accordion,i as AccordionBody,r as AccordionHeader,n as AccordionItem}from"./chunks/accordion-BZlX2uk8.js";
package/dist/alert.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- import { a as AlertIcon, c as AlertFooterProps, d as AlertCancel, f as AlertCancelProps, g as AlertProps, h as Alert, i as AlertTextProps, l as AlertCode, m as AlertBodyProps, n as AlertTitleProps, o as AlertIconProps, p as AlertBody, r as AlertText, s as AlertFooter, t as AlertTitle, u as AlertCodeProps } from "./chunks/index-DHcztR18.js";
1
+ import { a as AlertIcon, c as AlertFooterProps, d as AlertCancel, f as AlertCancelProps, g as AlertProps, h as Alert, i as AlertTextProps, l as AlertCode, m as AlertBodyProps, n as AlertTitleProps, o as AlertIconProps, p as AlertBody, r as AlertText, s as AlertFooter, t as AlertTitle, u as AlertCodeProps } from "./chunks/index-ByBbC4Jh.js";
2
2
  export { Alert, AlertBody, type AlertBodyProps, AlertCancel, type AlertCancelProps, AlertCode, type AlertCodeProps, AlertFooter, type AlertFooterProps, AlertIcon, type AlertIconProps, type AlertProps, AlertText, type AlertTextProps, AlertTitle, type AlertTitleProps };
package/dist/alert.js CHANGED
@@ -1 +1 @@
1
- "use client";import{a as e,c as t,i as n,n as r,o as i,r as a,s as o,t as s}from"./chunks/alert-BXI-_qlt.js";export{t as Alert,o as AlertBody,i as AlertCancel,e as AlertCode,n as AlertFooter,a as AlertIcon,r as AlertText,s as AlertTitle};
1
+ "use client";export{c as Alert,s as AlertBody,o as AlertCancel,a as AlertCode,i as AlertFooter,r as AlertIcon,n as AlertText,t as AlertTitle}from"./chunks/alert-DSLg5MBb.js";
@@ -1,2 +1,2 @@
1
- import { a as Autocomplete, i as AutocompleteGroupProps, n as AutocompleteItemProps, o as AutocompleteProps, r as AutocompleteGroup, t as AutocompleteItem } from "./chunks/index-91YA-jkp.js";
1
+ import { a as Autocomplete, i as AutocompleteGroupProps, n as AutocompleteItemProps, o as AutocompleteProps, r as AutocompleteGroup, t as AutocompleteItem } from "./chunks/index-3JVLrDHv.js";
2
2
  export { Autocomplete, AutocompleteGroup, type AutocompleteGroupProps, AutocompleteItem, type AutocompleteItemProps, type AutocompleteProps };
@@ -1 +1 @@
1
- "use client";import{n as e,r as t,t as n}from"./chunks/autocomplete-Baf9VSHN.js";export{n as Autocomplete,t as AutocompleteGroup,e as AutocompleteItem};
1
+ "use client";export{t as Autocomplete,r as AutocompleteGroup,n as AutocompleteItem}from"./chunks/autocomplete-99usnvgh.js";
package/dist/avatar.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- import { a as AvatarImageProps, i as AvatarImage, n as AvatarStackItemDef, o as Avatar, r as AvatarStackProps, s as AvatarProps, t as AvatarStack } from "./chunks/index-B19ZH3fm.js";
1
+ import { a as AvatarImageProps, i as AvatarImage, n as AvatarStackItemDef, o as Avatar, r as AvatarStackProps, s as AvatarProps, t as AvatarStack } from "./chunks/index-YzIZhXZ1.js";
2
2
  export { Avatar, AvatarImage, type AvatarImageProps, type AvatarProps, AvatarStack, type AvatarStackItemDef, type AvatarStackProps };
package/dist/avatar.js CHANGED
@@ -1 +1 @@
1
- "use client";import{n as e,r as t,t as n}from"./chunks/avatar-S3dGy6Qc.js";export{e as Avatar,t as AvatarImage,n as AvatarStack};
1
+ "use client";export{n as Avatar,r as AvatarImage,t as AvatarStack}from"./chunks/avatar-BQBbcnk6.js";
package/dist/badge.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- import { n as BadgeProps, t as Badge } from "./chunks/index-aRdgpeRb.js";
1
+ import { n as BadgeProps, t as Badge } from "./chunks/index-BEAZrhyV.js";
2
2
  export { Badge, type BadgeProps };
package/dist/badge.js CHANGED
@@ -1 +1 @@
1
- "use client";import{t as e}from"./chunks/badge-D2oztCvs.js";export{e as Badge};
1
+ "use client";export{t as Badge}from"./chunks/badge-Ths1Qn1a.js";
@@ -1,2 +1,2 @@
1
- import { a as BreadcrumbProps, i as BreadcrumbItemDef, n as BreadcrumbItemProps, r as Breadcrumb, t as BreadcrumbItem } from "./chunks/index-DtbUXxjz.js";
1
+ import { a as BreadcrumbProps, i as BreadcrumbItemDef, n as BreadcrumbItemProps, r as Breadcrumb, t as BreadcrumbItem } from "./chunks/index-BB8UNxnM.js";
2
2
  export { Breadcrumb, BreadcrumbItem, type BreadcrumbItemDef, type BreadcrumbItemProps, type BreadcrumbProps };
@@ -1 +1 @@
1
- "use client";import{n as e,t}from"./chunks/breadcrumb-s6J9itez.js";export{t as Breadcrumb,e as BreadcrumbItem};
1
+ "use client";export{t as Breadcrumb,n as BreadcrumbItem}from"./chunks/breadcrumb-BTiQikk-.js";
@@ -1,2 +1,2 @@
1
- import { i as ButtonGroupProps, n as ButtonToolbarProps, r as ButtonGroup, t as ButtonToolbar } from "./chunks/index-BAsbRx5n.js";
1
+ import { i as ButtonGroupProps, n as ButtonToolbarProps, r as ButtonGroup, t as ButtonToolbar } from "./chunks/index-D5KJRfMg.js";
2
2
  export { ButtonGroup, type ButtonGroupProps, ButtonToolbar, type ButtonToolbarProps };
@@ -1 +1 @@
1
- "use client";import{n as e,t}from"./chunks/button-group-BGppPrIv.js";export{e as ButtonGroup,t as ButtonToolbar};
1
+ "use client";export{n as ButtonGroup,t as ButtonToolbar}from"./chunks/button-group-CefkGeYL.js";
package/dist/button.d.ts CHANGED
@@ -1,3 +1,3 @@
1
- import "./chunks/focus-ring-SR_LwaN7.js";
2
- import { n as ButtonProps, t as Button } from "./chunks/Button-BuZ_GOHS.js";
1
+ import "./chunks/focus-ring-Bs80iIBN.js";
2
+ import { n as ButtonProps, t as Button } from "./chunks/Button-DblYVwl-.js";
3
3
  export { Button, type ButtonProps };
package/dist/button.js CHANGED
@@ -1 +1 @@
1
- "use client";import"./chunks/focus-ring-SR_LwaN7.js";import{t as e}from"./chunks/Button-BoymWE-L.js";export{e as Button};
1
+ "use client";import"./chunks/focus-ring-Bs80iIBN.js";export{t as Button}from"./chunks/Button-ZU-x1uN_.js";
@@ -1,3 +1,3 @@
1
1
  import { n as CalendarLabels, t as DateRangePreset } from "./chunks/dateRangePresets-R1FtA1zp.js";
2
- import { a as CalendarProps, i as CalendarMultipleProps, n as RangeCalendarProps, o as CalendarSingleProps, r as Calendar, t as RangeCalendar } from "./chunks/index-BNf0jIIL.js";
2
+ import { a as CalendarProps, i as CalendarMultipleProps, n as RangeCalendarProps, o as CalendarSingleProps, r as Calendar, t as RangeCalendar } from "./chunks/index-doVyX-4i.js";
3
3
  export { Calendar, type CalendarLabels, type CalendarMultipleProps, type CalendarProps, type CalendarSingleProps, type DateRangePreset, RangeCalendar, type RangeCalendarProps };
package/dist/calendar.js CHANGED
@@ -1 +1 @@
1
- "use client";import"./chunks/focus-ring-SR_LwaN7.js";import{n as e,t}from"./chunks/RangeCalendar-BJl-j4W2.js";export{e as Calendar,t as RangeCalendar};
1
+ "use client";import"./chunks/focus-ring-Bs80iIBN.js";export{n as Calendar,t as RangeCalendar}from"./chunks/RangeCalendar-mM3OeTlU.js";
package/dist/card.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- import { S as CardProps, _ as CardFooter, a as CardSubtitle, b as CardBodyProps, c as CardLinkProps, d as CardImage, f as CardImageProps, g as CardGroupProps, h as CardGroup, i as CardTextProps, l as CardImageOverlay, m as CardHeaderProps, n as CardTitleProps, o as CardSubtitleProps, p as CardHeader, r as CardText, s as CardLink, t as CardTitle, u as CardImageOverlayProps, v as CardFooterProps, x as Card, y as CardBody } from "./chunks/index-NGgDkhyn.js";
1
+ import { S as CardProps, _ as CardFooter, a as CardSubtitle, b as CardBodyProps, c as CardLinkProps, d as CardImage, f as CardImageProps, g as CardGroupProps, h as CardGroup, i as CardTextProps, l as CardImageOverlay, m as CardHeaderProps, n as CardTitleProps, o as CardSubtitleProps, p as CardHeader, r as CardText, s as CardLink, t as CardTitle, u as CardImageOverlayProps, v as CardFooterProps, x as Card, y as CardBody } from "./chunks/index-mLtlx-d9.js";
2
2
  export { Card, CardBody, type CardBodyProps, CardFooter, type CardFooterProps, CardGroup, type CardGroupProps, CardHeader, type CardHeaderProps, CardImage, CardImageOverlay, type CardImageOverlayProps, type CardImageProps, CardLink, type CardLinkProps, type CardProps, CardSubtitle, type CardSubtitleProps, CardText, type CardTextProps, CardTitle, type CardTitleProps };
package/dist/card.js CHANGED
@@ -1 +1 @@
1
- "use client";import{a as e,c as t,d as n,i as r,l as i,n as a,o,r as s,s as c,t as l,u}from"./chunks/card-CobeDpf1.js";export{e as Card,n as CardBody,u as CardFooter,r as CardGroup,s as CardHeader,i as CardImage,a as CardImageOverlay,l as CardLink,t as CardSubtitle,c as CardText,o as CardTitle};
1
+ "use client";export{a as Card,d as CardBody,u as CardFooter,i as CardGroup,r as CardHeader,l as CardImage,n as CardImageOverlay,t as CardLink,c as CardSubtitle,s as CardText,o as CardTitle}from"./chunks/card-CEQgHIaL.js";
@@ -1,2 +1,2 @@
1
- import { _ as CarouselSlideDetail, a as CarouselItem, c as CarouselInnerProps, d as CarouselControlPrev, f as CarouselControlPrevProps, g as CarouselProps, h as Carousel, i as CarouselOverlayProps, l as CarouselIndicators, m as CarouselControlNextProps, n as CarouselPlayPauseProps, o as CarouselItemProps, p as CarouselControlNext, r as CarouselOverlay, s as CarouselInner, t as CarouselPlayPause, u as CarouselIndicatorsProps, v as CarouselTransition, y as CarouselEnds } from "./chunks/index-CTpwB1yR.js";
1
+ import { _ as CarouselSlideDetail, a as CarouselItem, c as CarouselInnerProps, d as CarouselControlPrev, f as CarouselControlPrevProps, g as CarouselProps, h as Carousel, i as CarouselOverlayProps, l as CarouselIndicators, m as CarouselControlNextProps, n as CarouselPlayPauseProps, o as CarouselItemProps, p as CarouselControlNext, r as CarouselOverlay, s as CarouselInner, t as CarouselPlayPause, u as CarouselIndicatorsProps, v as CarouselTransition, y as CarouselEnds } from "./chunks/index-BxrIOrAc.js";
2
2
  export { Carousel, CarouselControlNext, type CarouselControlNextProps, CarouselControlPrev, type CarouselControlPrevProps, type CarouselEnds, CarouselIndicators, type CarouselIndicatorsProps, CarouselInner, type CarouselInnerProps, CarouselItem, type CarouselItemProps, CarouselOverlay, type CarouselOverlayProps, CarouselPlayPause, type CarouselPlayPauseProps, type CarouselProps, type CarouselSlideDetail, type CarouselTransition };
package/dist/carousel.js CHANGED
@@ -1 +1 @@
1
- "use client";import{a as e,c as t,i as n,n as r,o as i,r as a,s as o,t as s}from"./chunks/carousel-fTVPqnSV.js";export{i as Carousel,e as CarouselControlNext,n as CarouselControlPrev,a as CarouselIndicators,o as CarouselInner,t as CarouselItem,r as CarouselOverlay,s as CarouselPlayPause};
1
+ "use client";export{o as Carousel,a as CarouselControlNext,i as CarouselControlPrev,r as CarouselIndicators,s as CarouselInner,c as CarouselItem,n as CarouselOverlay,t as CarouselPlayPause}from"./chunks/carousel-DC-UGc6W.js";
@@ -1,3 +1,3 @@
1
1
  import { t as ButtonObject } from "./chunks/renderFormCheck-nKgpa_a3.js";
2
- import { i as CheckboxProps, n as CheckboxGroupProps, r as Checkbox, t as CheckboxGroup } from "./chunks/index-DM01FX3a.js";
2
+ import { i as CheckboxProps, n as CheckboxGroupProps, r as Checkbox, t as CheckboxGroup } from "./chunks/index-D0Dhs7YI.js";
3
3
  export { type ButtonObject, Checkbox, CheckboxGroup, type CheckboxGroupProps, type CheckboxProps };
package/dist/checkbox.js CHANGED
@@ -1 +1 @@
1
- "use client";import{n as e,t}from"./chunks/checkbox-ZyQn5Ku5.js";export{e as Checkbox,t as CheckboxGroup};
1
+ "use client";export{n as Checkbox,t as CheckboxGroup}from"./chunks/checkbox-ko6CdtoT.js";
@@ -1,2 +1,2 @@
1
- import { n as ChipInputProps, t as ChipInput } from "./chunks/index-B8uaSJA9.js";
1
+ import { n as ChipInputProps, t as ChipInput } from "./chunks/index-C0g8NSXY.js";
2
2
  export { ChipInput, type ChipInputProps };
@@ -1 +1 @@
1
- "use client";import{t as e}from"./chunks/chip-input-BpVDRERg.js";export{e as ChipInput};
1
+ "use client";export{t as ChipInput}from"./chunks/chip-input-CugY8EOc.js";
package/dist/chip.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- import { n as ChipProps, t as Chip } from "./chunks/index-B1kw0jzM.js";
1
+ import { n as ChipProps, t as Chip } from "./chunks/index-CTNqEMug.js";
2
2
  export { Chip, type ChipProps };
package/dist/chip.js CHANGED
@@ -1 +1 @@
1
- "use client";import"./chunks/focus-ring-SR_LwaN7.js";import{t as e}from"./chunks/Chip-DCaWaBqo.js";export{e as Chip};
1
+ "use client";import"./chunks/focus-ring-Bs80iIBN.js";export{t as Chip}from"./chunks/Chip-C7QlFCvx.js";
@@ -31,7 +31,9 @@ type ButtonOwnProps<C extends ElementType> = {
31
31
  /**
32
32
  * Marks the button as pressed for toggle-style usage (e.g. a formatting toolbar button).
33
33
  * Applies the `.active` class and sets `aria-pressed` so assistive technology announces
34
- * "button, pressed" rather than treating the button as a navigation link.
34
+ * "button, pressed" rather than treating the button as a navigation link. A link (`href`, or
35
+ * an `<a>` as `component` or the `asChild` element) has no pressed state to announce: it gets
36
+ * the class alone, unless you give it `role="button"`.
35
37
  */
36
38
  pressed?: boolean;
37
39
  /**
@@ -63,4 +65,4 @@ type ButtonComponent = (<C extends ElementType = 'button'>(props: ButtonProps<C>
63
65
  declare const Button: ButtonComponent;
64
66
  //#endregion
65
67
  export { ButtonProps as n, Button as t };
66
- //# sourceMappingURL=Button-BuZ_GOHS.d.ts.map
68
+ //# sourceMappingURL=Button-DblYVwl-.d.ts.map
@@ -0,0 +1,2 @@
1
+ import{f as e,m as t,v as n}from"./slot-BQVx1Eew.js";import{t as r}from"./polymorphic-CZIFszAy.js";import{t as i}from"./useButtonSemantics-B1SbGaDO.js";import{t as a}from"./useDisabledAnchorGuard-CH6df46a.js";import o from"react";import s from"classnames";import{mergeProps as c}from"react-aria";function l({children:r,className:l,color:u=`primary`,component:d,disabled:f,href:p,onClick:m,pressed:h,shape:g,size:_,type:v,variant:y,...b},x){let S=v??`button`,C=t(d,p,`button`),w=n(C,p,b),T=w===`anchor`,E=e(w,p,`Button`),D=w===`component`,O=s(`button`,u,{outline:y===`outline`,smooth:y===`smooth`,link:y===`link`,active:h,disabled:w!==`button`&&f},_,g,l),k=a(T,f,m),{buttonProps:A,forkedRef:j}=i(x,{disabled:f,onClick:m}),M={className:O,onClick:k},N={"aria-pressed":h};if(w===`button`){let e=C;return/* @__PURE__ */ o.createElement(e,{...b,...M,...N,type:S,disabled:f,ref:x},r)}if(w===`input`){let e=C;return/* @__PURE__ */ o.createElement(e,{...b,...M,...N,type:S,disabled:f,ref:x})}if(T){let e=C;return/* @__PURE__ */ o.createElement(e,{...b,...M,...b.role===`button`&&N,...E,...f&&{"aria-disabled":!0,tabIndex:-1},ref:x},r)}return/* @__PURE__ */ o.createElement(C,{...D?{disabled:f,onClick:m,...v!==void 0&&{type:v},...b}:c(b,A),className:O,...N,...E,ref:D?x:j},r)}const u=r(l,`Button`);export{u as t};
2
+ //# sourceMappingURL=Button-ZU-x1uN_.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Button-ZU-x1uN_.js","names":["hrefProps","linkElement","resolveLinkKind","createPolymorphicComponent","useButtonSemantics","useDisabledAnchorGuard","React","classNames","ButtonRender","typeProp","rest","type","Component","component","href","kind","isAnchor","linkProps","isComponentReference","_className","color","variant","pressed","disabled","size","shape","className","handleClick","onClick","ref","sharedProps","pressedProps","NativeButton","children","NativeInput","Anchor","mergeProps","buttonProps","forkedRef","Button"],"sources":["../../src/components/button/Button.tsx"],"sourcesContent":["import React, {\n ElementType,\n ForwardRefRenderFunction,\n MouseEventHandler,\n ReactElement,\n Ref\n} from 'react'\nimport classNames from 'classnames'\nimport { mergeProps } from 'react-aria'\n\nimport { ContextColor, ContextStyle, Shapes } from '../../types'\nimport { useButtonSemantics, useDisabledAnchorGuard } from '../../hooks'\nimport { hrefProps, linkElement, resolveLinkKind } from '../../utils/elementKind'\nimport {\n createPolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef,\n PolymorphicRefWithFallback\n} from '../../utils/polymorphic'\n\ntype ButtonOwnProps<C extends ElementType> = {\n /**\n * A string of all className you want applied to the base component.\n */\n className?: string\n /**\n * Sets the color of the component to one of Chassis context colors.\n */\n color?: ContextColor\n /**\n * Component used for the root node. Either a string to use a HTML element or a component.\n */\n component?: C\n /**\n * Toggle the disabled state for the component.\n */\n disabled?: boolean\n /**\n * The href attribute specifies the URL of the page the link goes to.\n */\n href?: string\n /**\n * Fires on click. Typed for every element `component` can actually render (`button`, `a`,\n * `input`, or a custom component), rather than narrowed to `HTMLButtonElement` alone.\n */\n onClick?: MouseEventHandler<HTMLButtonElement | HTMLAnchorElement | HTMLInputElement>\n /**\n * Marks the button as pressed for toggle-style usage (e.g. a formatting toolbar button).\n * Applies the `.active` class and sets `aria-pressed` so assistive technology announces\n * \"button, pressed\" rather than treating the button as a navigation link. A link (`href`, or\n * an `<a>` as `component` or the `asChild` element) has no pressed state to announce: it gets\n * the class alone, unless you give it `role=\"button\"`.\n */\n pressed?: boolean\n /**\n * Select the shape of the component.\n */\n shape?: Shapes\n /**\n * Size the component sm or lg.\n */\n size?: 'sm' | 'lg'\n /**\n * Specifies the type of button. Always specify the type attribute for the `<button>` element.\n * Different browsers may use different default types for the `<button>` element.\n */\n type?: 'button' | 'submit' | 'reset'\n /**\n * Set the button style variant. Same as `ContextStyle`, but `solid` (the unmodified default\n * look) doesn't apply as a class, and `link` — button-specific, not a context color — makes\n * the button look and behave like a hyperlink while keeping its `color`.\n */\n variant?: Exclude<ContextStyle, 'solid'> | 'link'\n}\n\nexport type ButtonProps<C extends ElementType = 'button'> = PolymorphicComponentProps<\n C,\n ButtonOwnProps<C>\n>\n\ntype ButtonComponent = (<C extends ElementType = 'button'>(\n props: ButtonProps<C> & {\n ref?: PolymorphicRefWithFallback<C, HTMLButtonElement | HTMLAnchorElement>\n }\n) => ReactElement | null) & { displayName?: string }\n\nfunction ButtonRender<C extends ElementType = 'button'>(\n {\n children,\n className,\n color = 'primary',\n component,\n disabled,\n href,\n onClick,\n pressed,\n shape,\n size,\n type: typeProp,\n variant,\n ...rest\n }: ButtonProps<C>,\n ref: PolymorphicRef<C>\n) {\n const type = typeProp ?? 'button'\n // `href` makes it an `<a>`, unless `component` or `asChild` chose the element (see\n // `linkElement`).\n const Component = linkElement(component, href, 'button')\n // The kind rather than the tag, counting a router link with `href` or `to` as an anchor: under `asChild`, `Component` is a `Slot` standing in for the\n // caller's element, and a slotted `<a>` needs what `component=\"a\"` gets.\n const kind = resolveLinkKind(Component, href, rest)\n const isAnchor = kind === 'anchor'\n const linkProps = hrefProps(kind, href, 'Button')\n\n // A component reference without a link target (a router link with `href` or `to` is an anchor,\n // see `resolveLinkKind`) has its own visual identity and is trusted to\n // handle its own keyboard/role semantics, same as `CloseButton`'s `isComponentReference` escape\n // hatch — synthesizing `role=\"button\"` and Enter/Space handling on top of it would stamp the\n // wrong ARIA role onto whatever it actually renders (e.g. an `<a>`) and can double-fire a click\n // (native anchor Enter→click, plus the synthesized keydown→click). Only a bare, non-native HTML\n // tag string (e.g. `'div'`) still needs `useButtonSemantics`'s synthesis.\n const isComponentReference = kind === 'component'\n\n const _className = classNames(\n 'button',\n color,\n {\n outline: variant === 'outline',\n smooth: variant === 'smooth',\n link: variant === 'link',\n active: pressed,\n disabled: kind !== 'button' && disabled\n },\n size,\n shape,\n className\n )\n\n // `<a>` has no real `disabled` attribute, so a disabled link button still fires click\n // (and still navigates) unless it's blocked here. Native `button`/`input` already stop\n // clicks on their own once the `disabled` attribute below is set.\n const handleClick = useDisabledAnchorGuard<\n HTMLButtonElement | HTMLAnchorElement | HTMLInputElement\n >(isAnchor, disabled, onClick)\n\n // Native `button`/`a`/`input` elements get keyboard activation, focus and disabled\n // handling for free from the browser. A custom `component` doesn't, so useButtonSemantics\n // fills in role, tabIndex and Enter/Space activation for it, matching native button behavior.\n // `ref` is cast for the same reason as the branches below — it's declared for whatever `C`\n // was passed, but this path (a non-native `component`) only ever populates it with a\n // button/anchor-shaped instance.\n const { buttonProps, forkedRef } = useButtonSemantics<HTMLButtonElement | HTMLAnchorElement>(\n ref as Ref<HTMLButtonElement | HTMLAnchorElement>,\n { disabled, onClick }\n )\n\n // Rendered as three separate branches (rather than one `<Component>` tag driven by a\n // `'button' | 'a' | 'input'`-typed variable) because a union-typed tag makes JSX\n // intersect all three elements' prop types — `onClick`/`ref` would then need to satisfy\n // `button`, `a` *and* `input` simultaneously, which `handleClick`/`ref`'s real, narrower\n // types can't. Each branch renders `Component` typed as its tag: that is the tag itself, or\n // the `Slot` holding the caller's element of that kind. `ref` is cast per branch since it's\n // declared for the generic `C`, not the specific element each branch actually renders (true by\n // construction — each branch's ref only ever populates with a matching instance). The props\n // common to all three (className/onClick) are factored out here so a future addition only\n // needs to change one place, not three.\n const sharedProps = {\n className: _className,\n onClick: handleClick\n }\n // `aria-pressed` is a state of the button role, which a `<button>`, a button `<input>` and an\n // element given button semantics below have. A link doesn't take it (axe's `aria-allowed-attr`),\n // so an anchor gets it only when the caller made it a button.\n const pressedProps = { 'aria-pressed': pressed }\n\n if (kind === 'button') {\n const NativeButton = Component as 'button'\n return (\n <NativeButton\n {...(rest as Record<string, unknown>)}\n {...sharedProps}\n {...pressedProps}\n type={type}\n disabled={disabled}\n ref={ref as Ref<HTMLButtonElement>}\n >\n {children}\n </NativeButton>\n )\n }\n\n if (kind === 'input') {\n const NativeInput = Component as 'input'\n return (\n // `rest` is cast because it's typed generically, whose event handlers don't structurally\n // match `<input>`'s own `onChange` (value-change semantics) — `component=\"input\"` is a\n // fixed set of documented attributes (`type`, `value`, `disabled`, ...), not a\n // general-purpose input, so this is a safe, deliberate escape.\n <NativeInput\n {...(rest as Record<string, unknown>)}\n {...sharedProps}\n {...pressedProps}\n type={type}\n disabled={disabled}\n ref={ref as Ref<HTMLInputElement>}\n />\n )\n }\n\n if (isAnchor) {\n const Anchor = Component as 'a'\n return (\n // `rest` is cast for the same reason as the `input` branch above — it's typed generically,\n // whose DOM event handlers are parameterized for whatever `C` was passed, which don't\n // structurally match `<a>`'s own `HTMLAnchorElement` ones (e.g. `onCopy`), even though both\n // accept a real DOM event at runtime.\n <Anchor\n {...(rest as Record<string, unknown>)}\n {...sharedProps}\n {...((rest as { role?: string }).role === 'button' && pressedProps)}\n {...linkProps}\n {...(disabled && { 'aria-disabled': true, tabIndex: -1 })}\n ref={ref as Ref<HTMLAnchorElement>}\n >\n {children}\n </Anchor>\n )\n }\n\n return (\n <Component\n {...(isComponentReference\n ? // A `type` given reaches the component too: it was taken here and dropped. The\n // default `'button'` doesn't, as nothing says the component renders a button.\n ({\n disabled,\n onClick,\n ...(typeProp !== undefined && { type: typeProp }),\n ...rest\n } as Record<string, unknown>)\n : (mergeProps(rest, buttonProps) as Record<string, unknown>))}\n className={_className}\n {...pressedProps}\n {...linkProps}\n ref={isComponentReference ? ref : forkedRef}\n >\n {children}\n </Component>\n )\n}\n\nexport const Button = createPolymorphicComponent<ButtonComponent>(\n ButtonRender as ForwardRefRenderFunction<Element, ButtonProps<ElementType>>,\n 'Button'\n)\n"],"mappings":"A,wSAsFA,SAASQ,EACP,CACE,WACA,YACA,QAAQ,UACR,YACA,WACA,OACA,UACA,UACA,QACA,OACA,KAAMC,EACN,UACA,GAAGC,GAEL,EACA,CACA,IAAMC,EAAOF,GAAY,SAGnBG,EAAYX,EAAYY,EAAWC,EAAM,QAAQ,EAGjDC,EAAOb,EAAgBU,EAAWE,EAAMJ,CAAI,EAC5CM,EAAWD,IAAS,SACpBE,EAAYjB,EAAUe,EAAMD,EAAM,QAAQ,EAS1CI,EAAuBH,IAAS,YAEhCI,EAAaZ,EACjB,SACAa,EACA,CACE,QAASC,IAAY,UACrB,OAAQA,IAAY,SACpB,KAAMA,IAAY,OAClB,OAAQC,EACR,SAAUP,IAAS,UAAYQ,CACjC,EACAC,EACAC,EACAC,CACF,EAKMC,EAActB,EAElBW,EAAUO,EAAUK,CAAO,EAQvB,CAAE,cAAa,aAAcxB,EACjCyB,EACA,CAAE,WAAU,SAAQ,CACtB,EAYMC,EAAc,CAClB,UAAWX,EACX,QAASQ,CACX,EAIMI,EAAe,CAAE,eAAgBT,CAAQ,EAE/C,GAAIP,IAAS,SAAU,CACrB,IAAMiB,EAAepB,EACrB,MACE,kBAAA,cAACoB,EAAD,CACE,GAAKtB,EACL,GAAIoB,EACJ,GAAIC,EACE,OACI,WACL,KAGO,EADXE,CACW,CAElB,CAEA,GAAIlB,IAAS,QAAS,CACpB,IAAMmB,EAActB,EACpB,MAKE,kBAAA,cAACsB,EAAD,CACE,GAAKxB,EACL,GAAIoB,EACJ,GAAIC,EACE,OACI,WACL,KACN,CAAA,CAEL,CAEA,GAAIf,EAAU,CACZ,IAAMmB,EAASvB,EACf,MAKE,kBAAA,cAACuB,EAAD,CACE,GAAKzB,EACL,GAAIoB,EACJ,GAAMpB,EAA2B,OAAS,UAAYqB,EACtD,GAAId,EACJ,GAAKM,GAAY,CAAE,gBAAiB,GAAM,SAAU,EAAG,EAClD,KAGC,EADLU,CACK,CAEZ,CAEA,MACE,kBAAA,cAACrB,EAAD,CACE,GAAKM,EAGA,CACC,WACA,UACA,GAAIT,IAAa,IAAA,IAAa,CAAE,KAAMA,CAAS,EAC/C,GAAGC,CACL,EACC0B,EAAW1B,EAAM2B,CAAW,EACjC,UAAWlB,EACX,GAAIY,EACJ,GAAId,EACJ,IAAKC,EAAuBW,EAAMS,CAGzB,EADRL,CACQ,CAEf,CAEA,MAAaM,EAASpC,EACpBK,EACA,QACF,E"}
@@ -0,0 +1,2 @@
1
+ import{f as e,m as t,v as n}from"./slot-BQVx1Eew.js";import{t as r}from"./polymorphic-CZIFszAy.js";import{t as i}from"./useButtonSemantics-B1SbGaDO.js";import{t as a}from"./useDisabledAnchorGuard-CH6df46a.js";import o from"react";import s from"classnames";import{mergeProps as c}from"react-aria";function l({children:r,className:l,color:u,component:d,disabled:f,href:p,onClick:m,pressed:h,size:g,type:_=`button`,variant:v,...y},b){let x=t(d,p,`span`),S=n(x,p,y),C=e(S,p,`Chip`),w=S===`button`,T=S===`anchor`,E=s(`chip`,u,g,{outline:v===`outline`,smooth:v===`smooth`,active:h,disabled:!w&&f},l),D=a(!w,f,m),O=y.role!==void 0,k=!w&&!T&&!!m&&!O,{buttonProps:A,forkedRef:j}=i(b,{disabled:f,onClick:m});if(w){let e=x;return/* @__PURE__ */ o.createElement(e,{...y,"aria-pressed":h,className:E,disabled:f,onClick:D,ref:b,type:_},r)}if(T){let e=x;return/* @__PURE__ */ o.createElement(e,{...y,"aria-pressed":y.role===`button`?h:void 0,className:E,...C,onClick:D,...f&&{"aria-disabled":!0,tabIndex:-1},ref:b},r)}let M=k||y.role===`button`;return/* @__PURE__ */ o.createElement(x,{...c(y,k?A:{}),"aria-pressed":M?h:void 0,className:E,...!k&&{onClick:D},...f&&{"aria-disabled":!0},...C,ref:k?j:b},r)}const u=r(l,`Chip`);export{u as t};
2
+ //# sourceMappingURL=Chip-C7QlFCvx.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Chip-C7QlFCvx.js","names":["hrefProps","linkElement","resolveLinkKind","createPolymorphicComponent","useButtonSemantics","useDisabledAnchorGuard","React","classNames","ChipRender","rest","Component","component","href","kind","linkProps","isButton","isAnchor","_className","color","size","variant","pressed","disabled","className","handleClick","onClick","hasExplicitRole","needsButtonSemantics","ref","NativeButton","children","Anchor","hasButtonRole","mergeProps","buttonProps","forkedRef","Chip"],"sources":["../../src/components/chip/Chip.tsx"],"sourcesContent":["import React, {\n ElementType,\n ForwardRefRenderFunction,\n MouseEventHandler,\n ReactElement,\n Ref\n} from 'react'\nimport classNames from 'classnames'\nimport { mergeProps } from 'react-aria'\n\nimport { ContextColor, ContextStyle } from '../../types'\nimport { useButtonSemantics, useDisabledAnchorGuard } from '../../hooks'\nimport { hrefProps, linkElement, resolveLinkKind } from '../../utils/elementKind'\nimport {\n createPolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef,\n PolymorphicRefWithFallback\n} from '../../utils/polymorphic'\n\ntype ChipOwnProps<C extends ElementType> = {\n /**\n * A string of all className you want applied to the component.\n */\n className?: string\n /**\n * Sets the color of the component to one of Chassis context colors.\n */\n color?: ContextColor\n /**\n * Component used for the root node. Either a string to use a HTML element or a component.\n * Defaults to `span`, or `a` when `href` is set.\n */\n component?: C\n /**\n * Toggle the disabled state for the component. Applied as the native `disabled` attribute when\n * `component` is `button`, or the `.disabled` class for every other element (a bare `<span>`/\n * `<a>` has no real `disabled` attribute).\n */\n disabled?: boolean\n /**\n * Renders the chip as a link to this URL. Defaults `component` to `a`.\n */\n href?: string\n /**\n * Fires on click. Typed for every element `component` can actually render, rather than\n * narrowed to whichever element `C` happens to be.\n */\n onClick?: MouseEventHandler<HTMLElement>\n /**\n * Marks the chip as pressed for toggle-style usage (e.g. a filter chip). Applies the `.active`\n * class and sets `aria-pressed` so assistive technology announces the toggle state. A chip\n * with no `onClick` or `component=\"button\"` is not a button and gets the class alone: a static\n * chip, and a link (`href`, or an `<a>` as `component` or the `asChild` element), which has no\n * pressed state to announce unless you give it `role=\"button\"`.\n */\n pressed?: boolean\n /**\n * Size the component sm or lg.\n */\n size?: 'sm' | 'lg'\n /**\n * Specifies the type of button. Only applies when `component` is `button`. Different browsers\n * may use different default types for the `<button>` element, so always specify it explicitly.\n */\n type?: 'button' | 'submit' | 'reset'\n /**\n * Set the chip style variant. `solid`/`basic` render the default look with no extra class.\n */\n variant?: ContextStyle\n}\n\nexport type ChipProps<C extends ElementType = 'span'> = PolymorphicComponentProps<\n C,\n ChipOwnProps<C>\n>\n\ntype ChipComponent = (<C extends ElementType = 'span'>(\n props: ChipProps<C> & { ref?: PolymorphicRefWithFallback<C, HTMLSpanElement | HTMLAnchorElement> }\n) => ReactElement | null) & { displayName?: string }\n\nfunction ChipRender<C extends ElementType = 'span'>(\n {\n children,\n className,\n color,\n component,\n disabled,\n href,\n onClick,\n pressed,\n size,\n type = 'button',\n variant,\n ...rest\n }: ChipProps<C>,\n ref: PolymorphicRef<C>\n) {\n // `href` makes it an `<a>`, unless `component` or `asChild` chose the element (see\n // `linkElement`).\n const Component = linkElement(component, href, 'span')\n // The kind rather than the tag, counting a router link with `href` or `to` as an anchor: under `asChild`, `Component` is a `Slot` standing in for the\n // caller's element, and a slotted `<a>` needs what `component=\"a\"` gets.\n const kind = resolveLinkKind(Component, href, rest)\n const linkProps = hrefProps(kind, href, 'Chip')\n const isButton = kind === 'button'\n const isAnchor = kind === 'anchor'\n\n const _className = classNames(\n 'chip',\n color,\n size,\n {\n outline: variant === 'outline',\n smooth: variant === 'smooth',\n active: pressed,\n disabled: !isButton && disabled\n },\n className\n )\n\n // `<a>`/`<span>`/`<div>` have no real `disabled` attribute, so a disabled non-button chip\n // still fires click (and an anchor still navigates) unless it's blocked here, same guard\n // `Button`/`CloseButton` apply.\n const handleClick = useDisabledAnchorGuard<HTMLElement>(!isButton, disabled, onClick)\n\n // A default (non-`button`/`a`) chip — the documented `pressed`/filter-chip use case — gets a\n // raw `onClick` with no keyboard semantics otherwise, the same gap `Link` fills via\n // `useButtonSemantics`. Skipped when the caller already supplied their own `role` via `rest`\n // (e.g. `ChipList`'s `role=\"row\"` grid semantics) — that caller is trusted to handle its own\n // keyboard interaction, same as `CloseButton`'s `isComponentReference` escape hatch.\n const hasExplicitRole = (rest as Record<string, unknown>).role !== undefined\n const needsButtonSemantics = !isButton && !isAnchor && !!onClick && !hasExplicitRole\n const { buttonProps, forkedRef } = useButtonSemantics<HTMLElement>(ref as Ref<HTMLElement>, {\n disabled,\n onClick\n })\n\n if (isButton) {\n const NativeButton = Component as 'button'\n return (\n <NativeButton\n {...(rest as Record<string, unknown>)}\n aria-pressed={pressed}\n className={_className}\n disabled={disabled}\n onClick={handleClick as MouseEventHandler<HTMLButtonElement>}\n ref={ref as Ref<HTMLButtonElement>}\n type={type}\n >\n {children}\n </NativeButton>\n )\n }\n\n if (isAnchor) {\n const Anchor = Component as 'a'\n return (\n // `aria-pressed` is a state of the button role, which a link doesn't have (axe's\n // `aria-allowed-attr`): an anchor gets it only when the caller made it a button, as\n // `Button` does. `.active` still shows it.\n <Anchor\n {...(rest as Record<string, unknown>)}\n aria-pressed={(rest as { role?: string }).role === 'button' ? pressed : undefined}\n className={_className}\n {...linkProps}\n onClick={handleClick as MouseEventHandler<HTMLAnchorElement>}\n {...(disabled && { 'aria-disabled': true, tabIndex: -1 })}\n ref={ref as Ref<HTMLAnchorElement>}\n >\n {children}\n </Anchor>\n )\n }\n\n // `aria-pressed` belongs to the button role alone: on a static chip, a span with no role, it is\n // an attribute the element can't take (axe's `aria-allowed-attr`). `.active` still shows it.\n const hasButtonRole = needsButtonSemantics || (rest as Record<string, unknown>).role === 'button'\n\n return (\n <Component\n {...(mergeProps(rest, needsButtonSemantics ? buttonProps : {}) as Record<string, unknown>)}\n aria-pressed={hasButtonRole ? pressed : undefined}\n className={_className}\n {...(!needsButtonSemantics && { onClick: handleClick })}\n {...(disabled && { 'aria-disabled': true })}\n {...linkProps}\n ref={needsButtonSemantics ? forkedRef : ref}\n >\n {children}\n </Component>\n )\n}\n\nexport const Chip = createPolymorphicComponent<ChipComponent>(\n ChipRender as ForwardRefRenderFunction<Element, ChipProps<ElementType>>,\n 'Chip'\n)\n"],"mappings":"A,wSAiFA,SAASQ,EACP,CACE,WACA,YACA,QACA,YACA,WACA,OACA,UACA,UACA,OACA,OAAO,SACP,UACA,GAAGC,GAEL,EACA,CAGA,IAAMC,EAAYT,EAAYU,EAAWC,EAAM,MAAM,EAG/CC,EAAOX,EAAgBQ,EAAWE,EAAMH,CAAI,EAC5CK,EAAYd,EAAUa,EAAMD,EAAM,MAAM,EACxCG,EAAWF,IAAS,SACpBG,EAAWH,IAAS,SAEpBI,EAAaV,EACjB,OACAW,EACAC,EACA,CACE,QAASC,IAAY,UACrB,OAAQA,IAAY,SACpB,OAAQC,EACR,SAAU,CAACN,GAAYO,CACzB,EACAC,CACF,EAKMC,EAAcnB,EAAoC,CAACU,EAAUO,EAAUG,CAAO,EAO9EC,EAAmBjB,EAAiC,OAAS,IAAA,GAC7DkB,EAAuB,CAACZ,GAAY,CAACC,GAAY,CAAC,CAACS,GAAW,CAACC,EAC/D,CAAE,cAAa,aAActB,EAAgCwB,EAAyB,CAC1F,WACA,SACF,CAAC,EAED,GAAIb,EAAU,CACZ,IAAMc,EAAenB,EACrB,MACE,kBAAA,cAACmB,EAAD,CACE,GAAKpB,EACL,eAAcY,EACd,UAAWJ,EACD,WACV,QAASO,EACJ,MACC,MAGM,EADXM,CACW,CAElB,CAEA,GAAId,EAAU,CACZ,IAAMe,EAASrB,EACf,MAIE,kBAAA,cAACqB,EAAD,CACE,GAAKtB,EACL,eAAeA,EAA2B,OAAS,SAAWY,EAAU,IAAA,GACxE,UAAWJ,EACX,GAAIH,EACJ,QAASU,EACT,GAAKF,GAAY,CAAE,gBAAiB,GAAM,SAAU,EAAG,EAClD,KAGC,EADLQ,CACK,CAEZ,CAIA,IAAME,EAAgBL,GAAyBlB,EAAiC,OAAS,SAEzF,MACE,kBAAA,cAACC,EAAD,CACE,GAAKuB,EAAWxB,EAAMkB,EAAuBO,EAAc,CAAC,CAAC,EAC7D,eAAcF,EAAgBX,EAAU,IAAA,GACxC,UAAWJ,EACX,GAAK,CAACU,GAAwB,CAAE,QAASH,CAAY,EACrD,GAAKF,GAAY,CAAE,gBAAiB,EAAK,EACzC,GAAIR,EACJ,IAAKa,EAAuBQ,EAAYP,CAG/B,EADRE,CACQ,CAEf,CAEA,MAAaM,EAAOjC,EAClBK,EACA,MACF,E"}
@@ -0,0 +1,2 @@
1
+ import{f as e,m as t,v as n}from"./slot-BQVx1Eew.js";import{t as r}from"./polymorphic-CZIFszAy.js";import{t as i}from"./useButtonSemantics-B1SbGaDO.js";import{t as a}from"./useDisabledAnchorGuard-CH6df46a.js";import o from"react";import s from"classnames";import{mergeProps as c}from"react-aria";function l({children:r,className:l,color:u,component:d,disabled:f,href:p,label:m,onClick:h,size:g,type:_,variant:v,...y},b){let x=_??`button`,S=t(d,p,`button`),C=n(S,p,y),w=e(C,p,`CloseButton`),T=C===`component`,E=T?l:s(`close-button`,{context:u||v,disabled:C!==`button`&&f},u,v,g,l),D=m??(r==null?`Close`:void 0),O=a(C===`anchor`,f,h),{buttonProps:k,forkedRef:A}=i(b,{disabled:f,onClick:h});if(C===`button`){let e=S;return/* @__PURE__ */ o.createElement(e,{className:E,"aria-label":D,...y,type:x,disabled:f,onClick:O,ref:b},r)}if(C===`anchor`){let e=S;return/* @__PURE__ */ o.createElement(e,{className:E,"aria-label":D,...y,...w,onClick:O,...f&&{"aria-disabled":!0,tabIndex:-1},ref:b},r)}let j=S;return/* @__PURE__ */ o.createElement(j,{className:E,"aria-label":D,...T?{color:u,size:g,variant:v,disabled:f,onClick:h,..._!==void 0&&{type:_},...y}:c(y,k),...w,ref:T?b:A},r)}const u=r(l,`CloseButton`);export{u as t};
2
+ //# sourceMappingURL=CloseButton-BPUI5iGX.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CloseButton-BPUI5iGX.js","names":["hrefProps","linkElement","resolveLinkKind","createPolymorphicComponent","useButtonSemantics","useDisabledAnchorGuard","React","classNames","CloseButtonRender","typeProp","rest","type","component_","component","href","kind","linkProps","isComponentReference","_className","className","color","variant","disabled","size","_label","label","children","handleClick","onClick","ref","NativeButton","Anchor","Component","mergeProps","buttonProps","forkedRef","CloseButton"],"sources":["../../src/components/close-button/CloseButton.tsx"],"sourcesContent":["import React, {\n ElementType,\n ForwardRefRenderFunction,\n MouseEventHandler,\n ReactElement,\n Ref\n} from 'react'\nimport classNames from 'classnames'\nimport { mergeProps } from 'react-aria'\n\nimport { ContextColor, ContextStyle } from '../../types'\nimport { useButtonSemantics, useDisabledAnchorGuard } from '../../hooks'\nimport { hrefProps, linkElement, resolveLinkKind } from '../../utils/elementKind'\nimport {\n createPolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef,\n PolymorphicRefWithFallback\n} from '../../utils/polymorphic'\n\ntype CloseButtonOwnProps<C extends ElementType> = {\n /**\n * A string of all className you want applied to the base component.\n */\n className?: string\n /**\n * Sets the color of the component to one of Chassis context colors. Applies the\n * `context` class alongside it, so the icon picks up that color without needing\n * an ancestor `.context` wrapper.\n */\n color?: ContextColor\n /**\n * Component used for the root node. Either a string to use a HTML element or a component.\n * A custom HTML tag (e.g. `'span'`) gets button semantics — role, focus, Enter/Space\n * activation — filled in automatically. A component is trusted to handle its own semantics,\n * so pass one that's already interactive (e.g. `Button`).\n */\n component?: C\n /**\n * Toggle the disabled state for the component.\n */\n disabled?: boolean\n /**\n * The href attribute specifies the URL of the page the link goes to. Renders an `<a>` in place\n * of the `<button>`, unless `component` or `asChild` chose the element.\n */\n href?: string\n /**\n * The accessible label announced by assistive technology. Override this to\n * localize the button for non-English contexts.\n */\n label?: string\n /**\n * Fires on click. Typed for every element `component` can actually render (`button` or `a`\n * natively, plus whatever a custom `component` renders), rather than narrowed to\n * `HTMLButtonElement` alone.\n */\n onClick?: MouseEventHandler<HTMLButtonElement | HTMLAnchorElement>\n /**\n * Size the component sm or lg.\n */\n size?: 'sm' | 'lg'\n /**\n * Specifies the type of button. Always specify the type attribute for the `<button>` element.\n * Different browsers may use different default types for the `<button>` element.\n */\n type?: 'button' | 'submit' | 'reset'\n /**\n * Set the close button's context style variant. Applies the `context` class\n * alongside it, same as `color`.\n */\n variant?: ContextStyle\n}\n\nexport type CloseButtonProps<C extends ElementType = 'button'> = PolymorphicComponentProps<\n C,\n CloseButtonOwnProps<C>\n>\n\ntype CloseButtonComponent = (<C extends ElementType = 'button'>(\n props: CloseButtonProps<C> & {\n ref?: PolymorphicRefWithFallback<C, HTMLButtonElement | HTMLAnchorElement>\n }\n) => ReactElement | null) & { displayName?: string }\n\nfunction CloseButtonRender<C extends ElementType = 'button'>(\n {\n children,\n className,\n color,\n component,\n disabled,\n href,\n label,\n onClick,\n size,\n type: typeProp,\n variant,\n ...rest\n }: CloseButtonProps<C>,\n ref: PolymorphicRef<C>\n) {\n const type = typeProp ?? 'button'\n // `href` makes it an `<a>`, unless `component` or `asChild` chose the element (see\n // `linkElement`). It used to be dropped unless `component=\"a\"` was passed as well.\n const component_ = linkElement(component, href, 'button')\n // The kind rather than the tag, counting a router link with `href` or `to` as an anchor: under `asChild`, `component_` is a `Slot` standing in for the\n // caller's element, and a slotted `<a>` needs what `component=\"a\"` gets.\n const kind = resolveLinkKind(component_, href, rest)\n const linkProps = hrefProps(kind, href, 'CloseButton')\n\n // A component reference (e.g. `Button`) has its own visual identity and its own\n // `color`/`size`/`variant` semantics — CloseButton's icon styling (the `close-button`\n // class and its context/color/variant/size classes) would just conflict with it, and\n // would also swallow those props before the component ever saw them. So a component\n // reference gets none of CloseButton's own styling; `color`/`size`/`variant` pass\n // through untouched, same as `className`, letting the component interpret them itself.\n const isComponentReference = kind === 'component'\n\n // Only a bare, non-`button` HTML tag needs the `.disabled` class applied by hand — a real\n // `<button>` gets native `:disabled` styling for free (chassis-css matches both selectors,\n // `&:disabled, &.disabled`), and a component reference isn't styled by CloseButton at all\n // (see `isComponentReference` above).\n const _className = isComponentReference\n ? className\n : classNames(\n 'close-button',\n { context: color || variant, disabled: kind !== 'button' && disabled },\n color,\n variant,\n size,\n className\n )\n\n // The default icon-only close button has no visible text, so it needs the 'Close' fallback\n // as its accessible name. Once `children` renders visible content (e.g. custom text passed\n // through `component`), let that content be the accessible name instead — forcing the\n // fallback label here would silently override it (a Label-in-Name accessibility failure).\n // An explicit `label` always wins either way, same as an explicit `aria-label` always did.\n const _label = label ?? (children == null ? 'Close' : undefined)\n\n // `<a>` has no real `disabled` attribute, so a disabled link close-button still fires\n // click (and still navigates) unless it's blocked here, same guard `Button` applies.\n const handleClick = useDisabledAnchorGuard<HTMLButtonElement | HTMLAnchorElement>(\n kind === 'anchor',\n disabled,\n onClick\n )\n\n const { buttonProps, forkedRef } = useButtonSemantics<HTMLButtonElement | HTMLAnchorElement>(\n ref as Ref<HTMLButtonElement | HTMLAnchorElement>,\n { disabled, onClick }\n )\n\n // Rendered as explicit branches, same as `Button`, rather than one `<Component>` tag\n // driven by a `'button' | 'a' | ElementType`-typed variable — a union-typed tag would\n // make JSX intersect all of `button`/`a`/custom prop types at once. Each branch renders\n // `component_` typed as its tag: the tag itself, or the `Slot` holding an element of that kind.\n // `aria-label={_label}` comes before `...rest` in every branch below so that an explicit\n // `aria-label` (not destructured above, so it lands in `rest`) overrides the computed\n // fallback via JSX's last-attribute-wins rule, rather than the other way around.\n if (kind === 'button') {\n const NativeButton = component_ as 'button'\n return (\n <NativeButton\n className={_className}\n aria-label={_label}\n {...(rest as Record<string, unknown>)}\n type={type}\n disabled={disabled}\n onClick={handleClick}\n ref={ref as Ref<HTMLButtonElement>}\n >\n {children}\n </NativeButton>\n )\n }\n\n if (kind === 'anchor') {\n const Anchor = component_ as 'a'\n return (\n <Anchor\n className={_className}\n aria-label={_label}\n {...(rest as Record<string, unknown>)}\n {...linkProps}\n onClick={handleClick}\n {...(disabled && { 'aria-disabled': true, tabIndex: -1 })}\n ref={ref as Ref<HTMLAnchorElement>}\n >\n {children}\n </Anchor>\n )\n }\n\n const Component = component_ as ElementType\n\n // Only a bare, non-`button`/`a` HTML tag (e.g. `'span'`) reaches here needing synthesized\n // button semantics — a component reference is trusted to already be interactive, so it\n // skips `buttonProps` (double keyboard activation) and instead gets `color`/`size`/`variant`\n // passed through untouched, per the comment on `isComponentReference` above.\n return (\n <Component\n className={_className}\n aria-label={_label}\n {...(isComponentReference\n ? // A `type` given reaches the component too, as `Button` passes it: it was taken here\n // and dropped. The default `'button'` doesn't, as nothing says the component renders\n // a button.\n ({\n color,\n size,\n variant,\n disabled,\n onClick,\n ...(typeProp !== undefined && { type: typeProp }),\n ...rest\n } as Record<string, unknown>)\n : (mergeProps(rest, buttonProps) as Record<string, unknown>))}\n {...linkProps}\n ref={isComponentReference ? ref : forkedRef}\n >\n {children}\n </Component>\n )\n}\n\nexport const CloseButton = createPolymorphicComponent<CloseButtonComponent>(\n CloseButtonRender as ForwardRefRenderFunction<Element, CloseButtonProps<ElementType>>,\n 'CloseButton'\n)\n"],"mappings":"A,wSAqFA,SAASQ,EACP,CACE,WACA,YACA,QACA,YACA,WACA,OACA,QACA,UACA,OACA,KAAMC,EACN,UACA,GAAGC,GAEL,EACA,CACA,IAAMC,EAAOF,GAAY,SAGnBG,EAAaX,EAAYY,EAAWC,EAAM,QAAQ,EAGlDC,EAAOb,EAAgBU,EAAYE,EAAMJ,CAAI,EAC7CM,EAAYhB,EAAUe,EAAMD,EAAM,aAAa,EAQ/CG,EAAuBF,IAAS,YAMhCG,EAAaD,EACfE,EACAZ,EACE,eACA,CAAE,QAASa,GAASC,EAAS,SAAUN,IAAS,UAAYO,CAAS,EACrEF,EACAC,EACAE,EACAJ,CACF,EAOEK,EAASC,IAAUC,GAAY,KAAO,QAAU,IAAA,IAIhDC,EAActB,EAClBU,IAAS,SACTO,EACAM,CACF,EAEM,CAAE,cAAa,aAAcxB,EACjCyB,EACA,CAAE,WAAU,SAAQ,CACtB,EASA,GAAId,IAAS,SAAU,CACrB,IAAMe,EAAelB,EACrB,MACE,kBAAA,cAACkB,EAAD,CACE,UAAWZ,EACX,aAAYM,EACZ,GAAKd,EACC,OACI,WACV,QAASiB,EACJ,KAGO,EADXD,CACW,CAElB,CAEA,GAAIX,IAAS,SAAU,CACrB,IAAMgB,EAASnB,EACf,MACE,kBAAA,cAACmB,EAAD,CACE,UAAWb,EACX,aAAYM,EACZ,GAAKd,EACL,GAAIM,EACJ,QAASW,EACT,GAAKL,GAAY,CAAE,gBAAiB,GAAM,SAAU,EAAG,EAClD,KAGC,EADLI,CACK,CAEZ,CAEA,IAAMM,EAAYpB,EAMlB,MACE,kBAAA,cAACoB,EAAD,CACE,UAAWd,EACX,aAAYM,EACZ,GAAKP,EAIA,CACC,QACA,OACA,UACA,WACA,UACA,GAAIR,IAAa,IAAA,IAAa,CAAE,KAAMA,CAAS,EAC/C,GAAGC,CACL,EACCuB,EAAWvB,EAAMwB,CAAW,EACjC,GAAIlB,EACJ,IAAKC,EAAuBY,EAAMM,CAGzB,EADRT,CACQ,CAEf,CAEA,MAAaU,EAAcjC,EACzBK,EACA,aACF,E"}
@@ -0,0 +1,2 @@
1
+ import{t as e}from"./lazyElement-tfMG21pZ.js";import{t}from"./iconSlot-DU_WcSL_.js";import{t as n}from"./renderMenuItemContent-DNdj-Ukz.js";import r,{useRef as i}from"react";import a from"classnames";import{useListBox as o,useOption as s}from"react-aria";import{Item as c,Section as l}from"react-stately";const u=e=>null;u.displayName=`ComboboxItem`;const d=e=>e.entryType===`group`,f=(t,{Group:n,Item:i})=>{let a=[];return r.Children.forEach(t,(t,o)=>{if(e(t,n)){let n=t.props,s=[];r.Children.forEach(n.children,t=>{e(t,i)&&s.push(t)}),a.push({entryType:`group`,key:`group-${o}`,label:n.label,items:s})}else e(t,i)&&a.push(t)}),a},p=e=>{let t=[],n=null;return e.forEach(e=>{if(e.type===`divider`)return;if(e.type===`header`){n={entryType:`group`,key:e.id,label:e.label,items:[]},t.push(n);return}let i=/* @__PURE__ */ r.createElement(u,{key:e.id,id:e.id,disabled:e.disabled,icon:e.icon,description:e.description,textValue:e.textValue},e.label);n?n.items.push(i):t.push(i)}),t},m=e=>e.reduce((e,t)=>{let n=d(t)?t.items:[t];return e.concat(n.filter(e=>e.props.disabled).map(e=>e.props.id))},[]),h=e=>/* @__PURE__ */ r.createElement(c,{key:e.props.id,textValue:e.props.textValue??(typeof e.props.children==`string`?e.props.children:void 0)},n({icon:e.props.icon,label:e.props.children,description:e.props.description})),g=e=>d(e)?/* @__PURE__ */ r.createElement(l,{key:e.key,title:e.label,items:e.items},h):h(e),_={"--cx-icon-color":`var(--cx-item-hover-icon-color)`,"--cx-item-fg-color":`var(--cx-item-hover-fg-color)`,"--cx-item-bg-color":`var(--cx-item-hover-bg-color)`},v=e=>e?_:void 0,y=({listBoxProps:e,listBoxRef:t,state:n})=>{let{listBoxProps:i}=o(e,n,t);return/* @__PURE__ */ r.createElement(`div`,{...i,ref:t},[...n.collection].map(e=>e.type===`section`?/* @__PURE__ */ r.createElement(b,{key:e.key,node:e,state:n}):/* @__PURE__ */ r.createElement(x,{key:e.key,item:e,state:n})))},b=({node:e,state:t})=>{let n=[...t.collection.getChildren(e.key)];return n.length===0?null:/* @__PURE__ */ r.createElement(r.Fragment,null,/* @__PURE__ */ r.createElement(`div`,{className:`menu-header`,role:`presentation`},e.rendered),n.map(e=>/* @__PURE__ */ r.createElement(x,{key:e.key,item:e,state:t})))},x=({item:e,state:n})=>{let o=i(null),{optionProps:c,isSelected:l,isDisabled:u,isFocused:d}=s({key:e.key},n,o);return/* @__PURE__ */ r.createElement(`div`,{className:a(`menu-item`,{selected:l,disabled:u}),style:v(d),...c,ref:o},e.rendered,l&&/* @__PURE__ */ r.createElement(t,{icon:`check`,className:`menu-item-check`}))};export{m as a,g as i,f as n,u as o,p as r,y as t};
2
+ //# sourceMappingURL=ComboboxListBox-Db0rSM3w.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ComboboxListBox-Db0rSM3w.js","names":["isElementOfType","renderMenuItemContent","React","classNames","ComboboxItem","isComboboxGroupEntry","entry","buildEntriesFromChildren","ItemComponent","entries","children","child","Group","groupProps","items","groupChild","index","buildEntriesFromItemsDef","currentGroup","defs","def","item","getDisabledKeys","keys","renderComboboxCollectionItem","Item","comboboxCollectionChildren","Section","virtualFocusStyle","getVirtualFocusStyle","isFocused","ComboboxListBox","domListBoxProps","useListBox","listBoxProps","state","listBoxRef","node","ComboboxSection","ComboboxOption","childNodes","ref","useRef","useOption","isSelected","isDisabled","optionProps","IconSlot"],"sources":["../../src/components/combobox/ComboboxItem.tsx","../../src/components/combobox/comboboxCollection.tsx","../../src/utils/virtualFocusStyle.ts","../../src/components/combobox/ComboboxListBox.tsx"],"sourcesContent":["import { ReactNode } from 'react'\nimport { Key } from 'react-stately'\n\nexport interface ComboboxItemProps {\n /**\n * Content of the option. Used as the filter/typeahead text when `textValue` isn't set — pass\n * `textValue` explicitly whenever `children` isn't a plain string (e.g. it wraps an icon or\n * other rich markup), since it can't otherwise be derived from rich content.\n */\n children: ReactNode\n /**\n * Secondary line of text rendered below `children` (`.menu-item-description`).\n */\n description?: ReactNode\n /**\n * Prevents the option from being selected, focused, or otherwise interacted with.\n */\n disabled?: boolean\n /**\n * Icon rendered at the option's leading edge (`.menu-item-icon`).\n */\n icon?: ReactNode\n /**\n * Identifies this option. Submitted as the value when this option is selected.\n */\n id: Key\n /**\n * Text used for filtering and typeahead. Required when `children` isn't a plain string —\n * falls back to `children` itself when omitted and `children` is a string.\n */\n textValue?: string\n}\n\n// `ComboboxItem` is never actually mounted — like `Tab`, it's read as data by `Combobox`,\n// which builds react-aria's listbox collection from each item's `id` and `children`. This keeps\n// the public authoring shape as plain composed JSX:\n//\n// <Combobox aria-label=\"Fruit\">\n// <ComboboxItem id=\"apple\">Apple</ComboboxItem>\n// <ComboboxItem id=\"banana\">Banana</ComboboxItem>\n// </Combobox>\nexport const ComboboxItem = (_props: ComboboxItemProps): null => null\n\nComboboxItem.displayName = 'ComboboxItem'\n","import React, { ComponentType, ReactElement, ReactNode } from 'react'\nimport { Item, Key, Section } from 'react-stately'\n\nimport { ComboboxGroupProps } from './ComboboxGroup'\nimport { ComboboxItem, ComboboxItemProps } from './ComboboxItem'\nimport { MenuItemsDef } from '../menu/MenuItemDef'\nimport { isElementOfType } from '../../utils/lazyElement'\nimport { renderMenuItemContent } from '../menu/renderMenuItemContent'\n\n// Shared between Combobox.tsx/ComboboxListBox.tsx (which build/render this collection) and\n// Autocomplete.tsx (which reuses the same entry shape — see the comment on\n// `buildEntriesFromChildren` below). Lives in `utils/` rather than `components/combobox/` because\n// it crosses that folder boundary; kept in its own file to also avoid a circular import between\n// Combobox.tsx and ComboboxListBox.tsx.\n\nexport type ComboboxItemElement = ReactElement<ComboboxItemProps>\n\nexport interface ComboboxGroupEntry {\n entryType: 'group'\n key: Key\n label: ReactNode\n items: ComboboxItemElement[]\n}\n\nexport type ComboboxEntry = ComboboxItemElement | ComboboxGroupEntry\n\n// `useComboBoxState`/`useComboBox`'s own `SelectionMode` ('single' | 'multiple') isn't\n// re-exported from react-stately's public entry point (only `ComboBoxState` etc. are) — this is\n// a structurally-identical stand-in so `ComboboxListBox` can stay generic over it without a\n// fragile deep import.\nexport type ComboboxSelectionMode = 'single' | 'multiple'\n\nexport const isComboboxGroupEntry = (entry: ComboboxEntry): entry is ComboboxGroupEntry =>\n (entry as ComboboxGroupEntry).entryType === 'group'\n\n// `Autocomplete`'s own `AutocompleteItem`/`AutocompleteGroup` are structurally identical to\n// `ComboboxItem`/`ComboboxGroup` (see AutocompleteItem.tsx/AutocompleteGroup.tsx — kept as\n// separate named types only so `Autocomplete`'s public API doesn't leak `Combobox`'s own prop\n// type), but they're different *runtime* component identities, which is what\n// `buildEntriesFromChildren` below needs to check consumer-authored `children` against. Passing\n// the pair in lets one implementation serve both families instead of two near-duplicate copies.\nexport interface ComboboxCollectionComponents {\n Group: ComponentType<ComboboxGroupProps>\n Item: ComponentType<ComboboxItemProps>\n}\n\n// Splits `children` into a flat, ordered list of entries — bare `Item` elements and\n// `Group`-wrapped clusters of them — mirroring how `useComboBoxState`'s dynamic collection needs\n// top-level nodes: some rendered as a plain `<Item>`, some as a `<Section>` wrapping several\n// `<Item>`s (see `comboboxCollectionChildren` below).\nexport const buildEntriesFromChildren = (\n children: ReactNode,\n { Group, Item: ItemComponent }: ComboboxCollectionComponents\n): ComboboxEntry[] => {\n const entries: ComboboxEntry[] = []\n // `isElementOfType` rather than `child.type === Group`: written in a Server Component, the\n // children's types are lazy wrappers (see `./lazyElement`).\n React.Children.forEach(children, (child, index) => {\n if (isElementOfType<ComboboxGroupProps>(child, Group)) {\n const groupProps = child.props\n const items: ComboboxItemElement[] = []\n React.Children.forEach(groupProps.children, (groupChild) => {\n if (isElementOfType<ComboboxItemProps>(groupChild, ItemComponent)) items.push(groupChild)\n })\n entries.push({ entryType: 'group', key: `group-${index}`, label: groupProps.label, items })\n return\n }\n if (isElementOfType<ComboboxItemProps>(child, ItemComponent)) entries.push(child)\n })\n return entries\n}\n\n// Same shape as `buildEntriesFromChildren`, from a flat `MenuItemsDef` instead. A `'header'`\n// entry opens a new group that all following items join until the next header (or the end of\n// the array) — matching how chassis-css itself renders grouped items (flat siblings, no\n// wrapping element per group). `'divider'` entries aren't meaningful for a listbox/option\n// collection and are skipped.\n//\n// Always builds a bare `ComboboxItem` internally regardless of which family (`Combobox` or\n// `Autocomplete`) called it: unlike `buildEntriesFromChildren`, nothing downstream re-checks\n// these elements' runtime type (they're read only via `.props.*`, never matched against a\n// component reference again), so there's no need to thread `ComboboxCollectionComponents`\n// through here too. `def.href`/`def.onClick` are intentionally not read — see the doc comments on\n// `MenuItemDef` itself for why: they're `Menu`-only fields on this shared type.\nexport const buildEntriesFromItemsDef = (defs: MenuItemsDef): ComboboxEntry[] => {\n const entries: ComboboxEntry[] = []\n let currentGroup: ComboboxGroupEntry | null = null\n\n defs.forEach((def) => {\n if (def.type === 'divider') return\n if (def.type === 'header') {\n currentGroup = { entryType: 'group', key: def.id, label: def.label, items: [] }\n entries.push(currentGroup)\n return\n }\n const item = (\n <ComboboxItem\n key={def.id}\n id={def.id}\n disabled={def.disabled}\n icon={def.icon}\n description={def.description}\n textValue={def.textValue}\n >\n {def.label}\n </ComboboxItem>\n )\n if (currentGroup) currentGroup.items.push(item)\n else entries.push(item)\n })\n\n return entries\n}\n\nexport const getDisabledKeys = (entries: ComboboxEntry[]): Key[] =>\n entries.reduce<Key[]>((keys, entry) => {\n const items = isComboboxGroupEntry(entry) ? entry.items : [entry]\n return keys.concat(items.filter((item) => item.props.disabled).map((item) => item.props.id))\n }, [])\n\n// Builds the react-stately `Item` node `useComboBoxState`'s collection actually renders from one\n// entry's props — identical for `Combobox` and `Autocomplete` regardless of which authoring\n// component (`ComboboxItem`/`AutocompleteItem`) produced it, since both share the same prop shape.\nexport const renderComboboxCollectionItem = (item: ComboboxItemElement) => (\n <Item\n key={item.props.id}\n textValue={\n item.props.textValue ??\n (typeof item.props.children === 'string' ? item.props.children : undefined)\n }\n >\n {renderMenuItemContent({\n icon: item.props.icon,\n label: item.props.children,\n description: item.props.description\n })}\n </Item>\n)\n\n// `useComboBoxState`'s own `children` render prop, given one `ComboboxEntry` — a plain `Item` for\n// a bare entry, a `Section` wrapping its items for a group. Identical for `Combobox` and\n// `Autocomplete`'s state setup.\nexport const comboboxCollectionChildren = (entry: ComboboxEntry) =>\n isComboboxGroupEntry(entry) ? (\n <Section key={entry.key} title={entry.label} items={entry.items}>\n {renderComboboxCollectionItem}\n </Section>\n ) : (\n renderComboboxCollectionItem(entry)\n )\n","import { CSSProperties } from 'react'\n\n// Options in a virtually-focused listbox (react-aria's combobox/listbox patterns) never receive\n// real DOM focus — focus stays on the trigger (a text input or button) while the highlighted\n// option is tracked virtually, so `:hover`/`:focus-visible` can't style it. To indicate the\n// highlight without touching chassis-css, we reuse its own hover color tokens (already defined\n// on the ancestor `.menu`, prefixed `--cx-` by chassis-css's build) as inline overrides instead\n// of relying on `.active`, which chassis-css reserves for the pressed/`:active` look.\nexport const virtualFocusStyle: CSSProperties = {\n '--cx-icon-color': 'var(--cx-item-hover-icon-color)',\n '--cx-item-fg-color': 'var(--cx-item-hover-fg-color)',\n '--cx-item-bg-color': 'var(--cx-item-hover-bg-color)'\n} as CSSProperties\n\nexport const getVirtualFocusStyle = (isFocused: boolean): CSSProperties | undefined =>\n isFocused ? virtualFocusStyle : undefined\n","import React, { RefObject, useRef } from 'react'\nimport classNames from 'classnames'\nimport { AriaListBoxOptions, useListBox, useOption } from 'react-aria'\nimport { ComboBoxState, Node } from 'react-stately'\n\nimport { getVirtualFocusStyle } from '../../utils/virtualFocusStyle'\nimport { ComboboxEntry, ComboboxSelectionMode } from './comboboxCollection'\nimport { IconSlot } from '../icon/iconSlot'\n\ninterface ComboboxListBoxProps<M extends ComboboxSelectionMode = 'single'> {\n listBoxProps: AriaListBoxOptions<ComboboxEntry>\n listBoxRef: RefObject<HTMLElement | null>\n state: ComboBoxState<ComboboxEntry, M>\n}\n\n// Generic over `M` (single- vs multi-select) purely so both `Combobox` (always single) and\n// `Autocomplete` (either) can pass their own `ComboBoxState` here without a cast — nothing in\n// this file's rendering logic actually depends on which mode is active.\nexport const ComboboxListBox = <M extends ComboboxSelectionMode = 'single'>({\n listBoxProps,\n listBoxRef,\n state\n}: ComboboxListBoxProps<M>) => {\n const { listBoxProps: domListBoxProps } = useListBox(listBoxProps, state, listBoxRef)\n\n return (\n <div {...domListBoxProps} ref={listBoxRef as RefObject<HTMLDivElement>}>\n {[...state.collection].map((node) =>\n node.type === 'section' ? (\n <ComboboxSection key={node.key} node={node} state={state} />\n ) : (\n <ComboboxOption key={node.key} item={node} state={state} />\n )\n )}\n </div>\n )\n}\n\ninterface ComboboxSectionProps<M extends ComboboxSelectionMode = 'single'> {\n node: Node<ComboboxEntry>\n state: ComboBoxState<ComboboxEntry, M>\n}\n\n// Chassis-css groups are `.menu-header` siblings interleaved with `.menu-item`s, no wrapping\n// element — plain, static markup, so there's no need for react-aria's `useListBoxSection`.\n// `useComboBoxState`'s filtering hides child items whose text doesn't match, but doesn't drop an\n// emptied-out section node itself, so a fully-filtered-out group's header is skipped by hand here\n// rather than left to render on its own.\nconst ComboboxSection = <M extends ComboboxSelectionMode = 'single'>({\n node,\n state\n}: ComboboxSectionProps<M>) => {\n const childNodes = [...state.collection.getChildren!(node.key)]\n if (childNodes.length === 0) return null\n\n return (\n <>\n <div className=\"menu-header\" role=\"presentation\">\n {node.rendered}\n </div>\n {childNodes.map((child) => (\n <ComboboxOption key={child.key} item={child} state={state} />\n ))}\n </>\n )\n}\n\ninterface ComboboxOptionProps<M extends ComboboxSelectionMode = 'single'> {\n item: Node<ComboboxEntry>\n state: ComboBoxState<ComboboxEntry, M>\n}\n\nconst ComboboxOption = <M extends ComboboxSelectionMode = 'single'>({\n item,\n state\n}: ComboboxOptionProps<M>) => {\n const ref = useRef<HTMLDivElement>(null)\n const { optionProps, isSelected, isDisabled, isFocused } = useOption(\n { key: item.key },\n state,\n ref\n )\n\n return (\n <div\n className={classNames('menu-item', {\n selected: isSelected,\n disabled: isDisabled\n })}\n style={getVirtualFocusStyle(isFocused)}\n {...optionProps}\n ref={ref}\n >\n {item.rendered}\n {isSelected && <IconSlot icon=\"check\" className=\"menu-item-check\" />}\n </div>\n )\n}\n"],"mappings":"A,iTAyCA,MAAaI,EAAgB,GAAoC,KAEjE,EAAa,YAAc,eCX3B,MAAaC,EAAwB,GAClCC,EAA6B,YAAc,QAiBjCC,GACX,EACA,CAAE,QAAO,KAAMC,KACK,CACpB,IAAMC,EAA2B,CAAC,EAelC,OAZAP,EAAM,SAAS,QAAQQ,GAAW,EAAO,IAAU,CACjD,GAAIV,EAAoCW,EAAOC,CAAK,EAAG,CACrD,IAAMC,EAAaF,EAAM,MACnBG,EAA+B,CAAC,EACtCZ,EAAM,SAAS,QAAQW,EAAW,SAAW,GAAe,CACtDb,EAAmCe,EAAYP,CAAa,GAAGM,EAAM,KAAKC,CAAU,CAC1F,CAAC,EACDN,EAAQ,KAAK,CAAE,UAAW,QAAS,IAAK,SAASO,IAAS,MAAOH,EAAW,MAAO,OAAM,CAAC,CAE5F,MACIb,EAAmCW,EAAOH,CAAa,GAAGC,EAAQ,KAAKE,CAAK,CAClF,CAAC,EACMF,CACT,EAcaQ,EAA4B,GAAwC,CAC/E,IAAMR,EAA2B,CAAC,EAC9BS,EAA0C,KAyB9C,OAvBAC,EAAK,QAAS,GAAQ,CACpB,GAAIC,EAAI,OAAS,UAAW,OAC5B,GAAIA,EAAI,OAAS,SAAU,CACzB,EAAe,CAAE,UAAW,QAAS,IAAKA,EAAI,GAAI,MAAOA,EAAI,MAAO,MAAO,CAAC,CAAE,EAC9EX,EAAQ,KAAKS,CAAY,EACzB,MACF,CACA,IAAMG,EACJ,kBAAA,cAACjB,EAAD,CACE,IAAKgB,EAAI,GACT,GAAIA,EAAI,GACR,SAAUA,EAAI,SACd,KAAMA,EAAI,KACV,YAAaA,EAAI,YACjB,UAAWA,EAAI,SAGH,EADXA,EAAI,KACO,EAEZF,EAAcA,EAAa,MAAM,KAAKG,CAAI,EACzCZ,EAAQ,KAAKY,CAAI,CACxB,CAAC,EAEMZ,CACT,EAEaa,EAAmB,GAC9Bb,EAAQ,QAAe,EAAM,IAAU,CACrC,IAAMK,EAAQT,EAAqBC,CAAK,EAAIA,EAAM,MAAQ,CAACA,CAAK,EAChE,OAAOiB,EAAK,OAAOT,EAAM,OAAQ,GAASO,EAAK,MAAM,QAAQ,CAAC,CAAC,IAAK,GAASA,EAAK,MAAM,EAAE,CAAC,CAC7F,EAAG,CAAC,CAAC,EAKMG,EAAgC,GAC3C,kBAAA,cAACC,EAAD,CACE,IAAKJ,EAAK,MAAM,GAChB,UACEA,EAAK,MAAM,YACV,OAAOA,EAAK,MAAM,UAAa,SAAWA,EAAK,MAAM,SAAW,IAAA,GAQ/D,EALHpB,EAAsB,CACrB,KAAMoB,EAAK,MAAM,KACjB,MAAOA,EAAK,MAAM,SAClB,YAAaA,EAAK,MAAM,WAC1B,CAAC,CACG,EAMKK,EAA8B,GACzCrB,EAAqBC,CAAK,EACxB,kBAAA,cAACqB,EAAD,CAAS,IAAKrB,EAAM,IAAK,MAAOA,EAAM,MAAO,MAAOA,EAAM,KAEjD,EADNkB,CACM,EAETA,EAA6BlB,CAAK,EC5IzBsB,EAAmC,CAC9C,kBAAmB,kCACnB,qBAAsB,gCACtB,qBAAsB,+BACxB,EAEaC,EAAwB,GACnCC,EAAYF,EAAoB,IAAA,GCGrBG,GAA+D,CAC1E,eACA,aACA,WAC6B,CAC7B,GAAM,CAAE,aAAcC,GAAoBC,EAAWC,EAAcC,EAAOC,CAAU,EAEpF,MACE,kBAAA,cAAC,MAAD,CAAK,GAAIJ,EAAiB,IAAKI,CAQ1B,EAPF,CAAC,GAAGD,EAAM,UAAU,CAAC,CAAC,IAAK,GAC1BE,EAAK,OAAS,UACZ,kBAAA,cAACC,EAAD,CAAiB,IAAKD,EAAK,IAAW,OAAa,OAAQ,CAAA,EAE3D,kBAAA,cAACE,EAAD,CAAgB,IAAKF,EAAK,IAAK,KAAMA,EAAa,OAAQ,CAAA,CAE9D,CACG,CAET,EAYMC,GAA+D,CACnE,OACA,WAC6B,CAC7B,IAAME,EAAa,CAAC,GAAGL,EAAM,WAAW,YAAaE,EAAK,GAAG,CAAC,EAG9D,OAFIG,EAAW,SAAW,EAAU,KAGlC,kBAAA,cAAAtC,EAAA,SAAA,KACE,kBAAA,cAAC,MAAD,CAAK,UAAU,cAAc,KAAK,cAE7B,EADFmC,EAAK,QACH,EACJG,EAAW,IAAK,GACf,kBAAA,cAACD,EAAD,CAAgB,IAAK5B,EAAM,IAAK,KAAMA,EAAc,OAAQ,CAAA,CAC7D,CACD,CAEN,EAOM4B,GAA8D,CAClE,OACA,WAC4B,CAC5B,IAAME,EAAMC,EAAuB,IAAI,EACjC,CAAE,cAAa,aAAY,aAAY,aAAcC,EACzD,CAAE,IAAKtB,EAAK,GAAI,EAChBc,EACAM,CACF,EAEA,MACE,kBAAA,cAAC,MAAD,CACE,UAAWtC,EAAW,YAAa,CACjC,SAAUyC,EACV,SAAUC,CACZ,CAAC,EACD,MAAOhB,EAAqBC,CAAS,EACrC,GAAIgB,EACC,KAIF,EAFFzB,EAAK,SACLuB,GAAc,kBAAA,cAACG,EAAD,CAAU,KAAK,QAAQ,UAAU,iBAAmB,CAAA,CAChE,CAET,E"}
@@ -0,0 +1,2 @@
1
+ import{c as e,u as t}from"./slot-BQVx1Eew.js";import n,{useRef as r}from"react";import i from"classnames";import{useDateField as a,useDateSegment as o,useLocale as s}from"react-aria";import{useDateFieldState as c}from"react-stately";import{createCalendar as l}from"@internationalized/date";const u=/^[\s\u2066-\u2069]+$/,d=/* @__PURE__ */ new Set([`era`,`year`,`month`,`day`]),f=(e,t)=>{let n=e.slice(0,t).reverse().find(e=>e.type!==`literal`),r=e.slice(t+1).find(e=>e.type!==`literal`);return!!(n&&r)&&d.has(n.type)!==d.has(r.type)},p=({fieldLabelledBy:a,segment:s,slots:c,state:l})=>{let d=r(null),{segmentProps:p}=o(s,l,d),m=s.type===`literal`&&(u.test(s.text)||f(l.segments,l.segments.indexOf(s)));return/* @__PURE__ */ n.createElement(`span`,{...t(p,...c),"aria-labelledby":p[`aria-labelledby`]&&e(p.id,a),className:m?void 0:i(`datepicker-segment`,{placeholder:s.isPlaceholder}),contentEditable:p.contentEditable||void 0,ref:d},s.text)},m=e=>e?.querySelector(`[role="spinbutton"]`)?.focus(),h=({fieldProps:e,fieldRef:i})=>{let{locale:o}=s(),u=c({...e,createCalendar:l,locale:o}),d=r(null),f=i??d,{descriptionProps:m,errorMessageProps:h,fieldProps:g}=a(e,u,f);return/* @__PURE__ */ n.createElement(`div`,{...t(g,m,h),className:`datepicker-field`,ref:f},u.segments.map((t,r)=>/* @__PURE__ */ n.createElement(p,{fieldLabelledBy:e[`aria-labelledby`],key:r,segment:t,slots:[m,h],state:u})))};export{m as n,p as r,h as t};
2
+ //# sourceMappingURL=DateField-4cdcwt0v.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DateField-4cdcwt0v.js","names":["joinIds","withoutSlotIds","React","classNames","BLANK_LITERAL","DATE_PARTS","separatesDateAndTime","before","segments","index","segment","after","DateSegment","ref","useRef","useDateSegment","state","plain","segmentProps","slots","fieldLabelledBy","focusFirstSegment","root","DateField","useLocale","useDateFieldState","fieldProps","ownRef","fieldRef","domFieldProps","useDateField","descriptionProps","errorMessageProps"],"sources":["../../src/components/datepicker/DateSegment.tsx","../../src/components/datepicker/DateField.tsx"],"sourcesContent":["import React, { useRef } from 'react'\nimport classNames from 'classnames'\nimport { useDateSegment } from 'react-aria'\nimport { DateFieldState, DateSegment as DateSegmentType } from 'react-stately'\n\nimport './DateSegment.scss'\nimport { joinIds, withoutSlotIds } from '../../utils/idRefs'\n\n// One editable part of a date or time field (a month, an hour, a day period), for `DateField`\n// and `TimeField` alike. A `TimeFieldState` is a `DateFieldState`.\n// A literal of spaces or bidi isolation marks (U+2066-U+2069) only.\nconst BLANK_LITERAL = /^[\\s\\u2066-\\u2069]+$/\nconst DATE_PARTS = new Set(['era', 'year', 'month', 'day'])\n\n// Whether a literal stands between a field's date and its time (en-US \", \"), found by the\n// editable parts on either side of it.\nconst separatesDateAndTime = (segments: DateSegmentType[], index: number) => {\n const before = segments\n .slice(0, index)\n .reverse()\n .find((segment) => segment.type !== 'literal')\n const after = segments.slice(index + 1).find((segment) => segment.type !== 'literal')\n return Boolean(before && after) && DATE_PARTS.has(before!.type) !== DATE_PARTS.has(after!.type)\n}\n\nexport interface DateSegmentProps {\n fieldLabelledBy?: string\n segment: DateSegmentType\n slots: { id?: string }[]\n state: DateFieldState\n}\n\nexport const DateSegment = ({ fieldLabelledBy, segment, slots, state }: DateSegmentProps) => {\n const ref = useRef<HTMLDivElement>(null)\n const { segmentProps } = useDateSegment(segment, state, ref)\n const plain =\n segment.type === 'literal' &&\n (BLANK_LITERAL.test(segment.text) ||\n separatesDateAndTime(state.segments, state.segments.indexOf(segment)))\n\n return (\n <span\n {...withoutSlotIds(segmentProps, ...slots)}\n // react-aria labels a segment by an id of its own, which it merges into the segment's `id`\n // only after hydration, and by the field's label. The server's HTML referred to the first,\n // an id no element had.\n aria-labelledby={segmentProps['aria-labelledby'] && joinIds(segmentProps.id, fieldLabelledBy)}\n // A time's literal segments include bidi isolation marks around it, which show nothing, the\n // space before AM/PM, and the \", \" between a date and its time. As `.datepicker-segment`s,\n // their padding set the time off from the edge and widened the space, or put one before the\n // comma: they render as plain text. A date's own literals (\"/\", ko-KR's \". \") keep it.\n className={\n plain ? undefined : classNames('datepicker-segment', { placeholder: segment.isPlaceholder })\n }\n // A segment that can't be edited leaves `contenteditable` out rather than writing `false`:\n // react-aria marks it `aria-readonly`, which HTML allows only on an element that isn't\n // `contenteditable` at all.\n contentEditable={segmentProps.contentEditable || undefined}\n ref={ref}\n >\n {segment.text}\n </span>\n )\n}\n","import React, { RefObject, useRef } from 'react'\nimport { AriaDateFieldProps, DateValue, useDateField, useLocale } from 'react-aria'\nimport { useDateFieldState } from 'react-stately'\nimport { createCalendar } from '@internationalized/date'\n\nimport { withoutSlotIds } from '../../utils/idRefs'\nimport { DateSegment } from './DateSegment'\n\ninterface DateFieldProps {\n fieldProps: AriaDateFieldProps<DateValue>\n /**\n * A ref to the field's element, for a picker that focuses one field of two.\n */\n fieldRef?: RefObject<HTMLDivElement | null>\n}\n\n// Where a required picker puts focus once it has held its form back: the first segment under\n// `root`, a picker's group or one of its fields.\nexport const focusFirstSegment = (root: HTMLElement | null) =>\n root?.querySelector<HTMLElement>('[role=\"spinbutton\"]')?.focus()\n\n// Builds its own segment state from the `fieldProps` `DatePicker` hands down — mirrors react\n// aria's own documented composition (the top-level `useDatePickerState`/`useDatePicker` pair\n// manages the *selected value*; the field's individually-editable segments are a separate piece\n// of state derived from `locale`/`createCalendar`, owned here).\nexport const DateField = ({ fieldProps, fieldRef }: DateFieldProps) => {\n const { locale } = useLocale()\n const state = useDateFieldState({\n ...fieldProps,\n createCalendar,\n locale\n })\n\n const ownRef = useRef<HTMLDivElement>(null)\n const ref = fieldRef ?? ownRef\n const {\n descriptionProps,\n errorMessageProps,\n fieldProps: domFieldProps\n } = useDateField(fieldProps, state, ref)\n\n return (\n <div\n {...withoutSlotIds(domFieldProps, descriptionProps, errorMessageProps)}\n className=\"datepicker-field\"\n ref={ref}\n >\n {state.segments.map((segment, index) => (\n <DateSegment\n fieldLabelledBy={fieldProps['aria-labelledby']}\n // eslint-disable-next-line react/no-array-index-key\n key={index}\n segment={segment}\n slots={[descriptionProps, errorMessageProps]}\n state={state}\n />\n ))}\n </div>\n )\n}\n"],"mappings":"A,kSAWA,MAAMI,EAAgB,uBAChBC,kBAAa,IAAI,IAAI,CAAC,MAAO,OAAQ,QAAS,KAAK,CAAC,EAIpDC,GAAwB,EAA6B,IAAkB,CAC3E,IAAMC,EAASC,EACZ,MAAM,EAAGC,CAAK,CAAC,CACf,QAAQ,CAAC,CACT,KAAM,GAAYC,EAAQ,OAAS,SAAS,EACzCC,EAAQH,EAAS,MAAMC,EAAQ,CAAC,CAAC,CAAC,KAAM,GAAYC,EAAQ,OAAS,SAAS,EACpF,MAAO,GAAQH,GAAUI,IAAUN,EAAW,IAAIE,EAAQ,IAAI,IAAMF,EAAW,IAAIM,EAAO,IAAI,CAChG,EASaC,GAAe,CAAE,kBAAiB,UAAS,QAAO,WAA8B,CAC3F,IAAMC,EAAMC,EAAuB,IAAI,EACjC,CAAE,gBAAiBC,EAAeL,EAASM,EAAOH,CAAG,EACrDI,EACJP,EAAQ,OAAS,YAChBN,EAAc,KAAKM,EAAQ,IAAI,GAC9BJ,EAAqBU,EAAM,SAAUA,EAAM,SAAS,QAAQN,CAAO,CAAC,GAExE,MACE,kBAAA,cAAC,OAAD,CACE,GAAIT,EAAeiB,EAAc,GAAGC,CAAK,EAIzC,kBAAiBD,EAAa,oBAAsBlB,EAAQkB,EAAa,GAAIE,CAAe,EAK5F,UACEH,EAAQ,IAAA,GAAYd,EAAW,qBAAsB,CAAE,YAAaO,EAAQ,aAAc,CAAC,EAK7F,gBAAiBQ,EAAa,iBAAmB,IAAA,GAC5C,KAGD,EADHR,EAAQ,IACL,CAEV,EC7CaW,EAAqB,GAChCC,GAAM,cAA2B,qBAAqB,CAAC,EAAE,MAAM,EAMpDC,GAAa,CAAE,aAAY,cAA+B,CACrE,GAAM,CAAE,UAAWC,EAAU,EACvBR,EAAQS,EAAkB,CAC9B,GAAGC,EACH,iBACA,QACF,CAAC,EAEKC,EAASb,EAAuB,IAAI,EACpCD,EAAMe,GAAYD,EAClB,CACJ,mBACA,oBACA,WAAYE,GACVC,EAAaJ,EAAYV,EAAOH,CAAG,EAEvC,MACE,kBAAA,cAAC,MAAD,CACE,GAAIZ,EAAe4B,EAAeE,EAAkBC,CAAiB,EACrE,UAAU,mBACL,KAYF,EAVFhB,EAAM,SAAS,KAAK,EAAS,IAC5B,kBAAA,cAACJ,EAAD,CACE,gBAAiBc,EAAW,mBAE5B,IAAKjB,EACI,UACT,MAAO,CAACsB,EAAkBC,CAAiB,EACpC,OACR,CAAA,CACF,CACE,CAET,E"}
@@ -0,0 +1,2 @@
1
+ import{t as e}from"./polymorphic-CZIFszAy.js";import t from"react";import n from"classnames";function r({children:e,className:r,component:i,invalid:a,tooltip:o,valid:s,...c},l){let u=i??`div`,d=n({[`invalid-${o?`tooltip`:`feedback`}`]:a,[`valid-${o?`tooltip`:`feedback`}`]:s},r);return/* @__PURE__ */ t.createElement(u,{className:d,...c,ref:l},e)}const i=e(r,`FormFeedback`);function a({children:e,className:r,component:i,...a},o){let s=i??`div`,c=n(`form-help`,r);return/* @__PURE__ */ t.createElement(s,{className:c,...a,ref:o},e)}const o=e(a,`FormHelp`);export{i as n,o as t};
2
+ //# sourceMappingURL=FormHelp-B1eSoack.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"FormHelp-B1eSoack.js","names":["createPolymorphicComponent","React","classNames","FormFeedbackRender","rest","Component","component","_className","tooltip","invalid","valid","className","children","FormFeedback","FormHelpRender","FormHelp"],"sources":["../../src/components/form/FormFeedback.tsx","../../src/components/form/FormHelp.tsx"],"sourcesContent":["import React, { ElementType, ForwardRefRenderFunction, ReactElement } from 'react'\nimport classNames from 'classnames'\n\nimport {\n createPolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef\n} from '../../utils/polymorphic'\n\ntype FormFeedbackOwnProps<C extends ElementType> = {\n /**\n * A string of all className you want applied to the component.\n */\n className?: string\n /**\n * Component used for the root node. Either a string to use a HTML element or a component.\n */\n component?: C\n /**\n * Set component validation state to invalid.\n */\n invalid?: boolean\n /**\n * If your form layout allows it, you can display validation feedback in a styled tooltip.\n */\n tooltip?: boolean\n /**\n * Set component validation state to valid.\n */\n valid?: boolean\n}\n\nexport type FormFeedbackProps<C extends ElementType = 'div'> = PolymorphicComponentProps<\n C,\n FormFeedbackOwnProps<C>\n>\n\ntype FormFeedbackComponent = (<C extends ElementType = 'div'>(\n props: FormFeedbackProps<C> & { ref?: PolymorphicRef<C> }\n) => ReactElement | null) & { displayName?: string }\n\nfunction FormFeedbackRender<C extends ElementType = 'div'>(\n { children, className, component, invalid, tooltip, valid, ...rest }: FormFeedbackProps<C>,\n ref: PolymorphicRef<C>\n) {\n const Component = component ?? 'div'\n const _className = classNames(\n {\n [`invalid-${tooltip ? 'tooltip' : 'feedback'}`]: invalid,\n [`valid-${tooltip ? 'tooltip' : 'feedback'}`]: valid\n },\n className\n )\n return (\n <Component className={_className} {...rest} ref={ref}>\n {children}\n </Component>\n )\n}\n\nexport const FormFeedback = createPolymorphicComponent<FormFeedbackComponent>(\n FormFeedbackRender as ForwardRefRenderFunction<Element, FormFeedbackProps<ElementType>>,\n 'FormFeedback'\n)\n","import React, { ElementType, ForwardRefRenderFunction, ReactElement } from 'react'\nimport classNames from 'classnames'\n\nimport {\n createPolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef\n} from '../../utils/polymorphic'\n\ntype FormHelpOwnProps<C extends ElementType> = {\n /**\n * A string of all className you want applied to the component.\n */\n className?: string\n /**\n * Component used for the root node. Either a string to use a HTML element or a component.\n */\n component?: C\n}\n\nexport type FormHelpProps<C extends ElementType = 'div'> = PolymorphicComponentProps<\n C,\n FormHelpOwnProps<C>\n>\n\ntype FormHelpComponent = (<C extends ElementType = 'div'>(\n props: FormHelpProps<C> & { ref?: PolymorphicRef<C> }\n) => ReactElement | null) & { displayName?: string }\n\nfunction FormHelpRender<C extends ElementType = 'div'>(\n { children, className, component, ...rest }: FormHelpProps<C>,\n ref: PolymorphicRef<C>\n) {\n const Component = component ?? 'div'\n const _className = classNames('form-help', className)\n return (\n <Component className={_className} {...rest} ref={ref}>\n {children}\n </Component>\n )\n}\n\nexport const FormHelp = createPolymorphicComponent<FormHelpComponent>(\n FormHelpRender as ForwardRefRenderFunction<Element, FormHelpProps<ElementType>>,\n 'FormHelp'\n)\n"],"mappings":"A,6FAyCA,SAASG,EACP,CAAE,WAAU,YAAW,YAAW,UAAS,UAAS,QAAO,GAAGC,GAC9D,EACA,CACA,IAAMC,EAAYC,GAAa,MACzBC,EAAaL,EACjB,EACG,WAAWM,EAAU,UAAY,cAAeC,GAChD,SAASD,EAAU,UAAY,cAAeE,CACjD,EACAC,CACF,EACA,MACE,kBAAA,cAACN,EAAD,CAAW,UAAWE,EAAY,GAAIH,EAAW,KAEtC,EADRQ,CACQ,CAEf,CAEA,MAAaC,EAAeb,EAC1BG,EACA,cACF,EClCA,SAASW,EACP,CAAE,WAAU,YAAW,YAAW,GAAGV,GACrC,EACA,CACA,IAAMC,EAAYC,GAAa,MACzBC,EAAaL,EAAW,YAAaS,CAAS,EACpD,MACE,kBAAA,cAACN,EAAD,CAAW,UAAWE,EAAY,GAAIH,EAAW,KAEtC,EADRQ,CACQ,CAEf,CAEA,MAAaG,EAAWf,EACtBc,EACA,UACF,E"}
@@ -0,0 +1,2 @@
1
+ import e,{forwardRef as t}from"react";import n from"classnames";const r=t(({children:t,className:r,customClassName:i,...a},o)=>{let s=i||n(`form-label`,r);return/* @__PURE__ */ e.createElement(`label`,{className:s,...a,ref:o},t)});r.displayName=`FormLabel`;export{r as t};
2
+ //# sourceMappingURL=FormLabel-CpzWYh6U.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"FormLabel-CpzWYh6U.js","names":["React","classNames","FormLabel","forwardRef","rest","_className","customClassName","className","children"],"sources":["../../src/components/form/FormLabel.tsx"],"sourcesContent":["import React, { forwardRef, LabelHTMLAttributes } from 'react'\nimport classNames from 'classnames'\n\nexport interface FormLabelProps extends LabelHTMLAttributes<HTMLLabelElement> {\n /**\n * A string of all className you want applied to the component.\n */\n className?: string\n /**\n * A string of all className you want to be applied to the component, and override standard className value.\n */\n customClassName?: string\n}\n\nexport const FormLabel = forwardRef<HTMLLabelElement, FormLabelProps>(\n ({ children, className, customClassName, ...rest }, ref) => {\n const _className = customClassName ? customClassName : classNames('form-label', className)\n return (\n <label className={_className} {...rest} ref={ref}>\n {children}\n </label>\n )\n }\n)\n\nFormLabel.displayName = 'FormLabel'\n"],"mappings":"A,gEAcA,MAAaE,EAAYC,GACtB,CAAE,WAAU,YAAW,kBAAiB,GAAGC,GAAQ,IAAQ,CAC1D,IAAMC,EAAaC,GAAoCL,EAAW,aAAcM,CAAS,EACzF,MACE,kBAAA,cAAC,QAAD,CAAO,UAAWF,EAAY,GAAID,EAAW,KAEtC,EADJI,CACI,CAEX,CACF,EAEA,EAAU,YAAc,Y"}
@@ -1,2 +1,2 @@
1
- import e,{createContext as t,forwardRef as n,useContext as r}from"react";import i from"classnames";const a={check:`check-solid`,previous:`chevron-left-outline`,next:`chevron-right-outline`,menu:`bars-outline`,more:`ellipsis-h-solid`,play:`play-solid`,pause:`pause-solid`,increment:`chevron-up-outline`,decrement:`chevron-down-outline`,search:`search-outline`,clear:`xmark-outline`,expand:`chevron-right-outline`},o=t({}),s=()=>r(o),c=n((t,n)=>{let r=s(),{name:a,className:o,font:c=r.font??!1,size:l,sprite:u=r.sprite??``,style:d,title:f,...p}=t,m=l==null?d:{"--cx-icon-size":typeof l==`number`?`${l}px`:l,...d},h=i(`icon`,{[`${r.fontPrefix??`cx-`}${a}`]:c},r.className,o);return c?e.createElement(`span`,{className:h,role:f?`img`:void 0,"aria-hidden":!f||void 0,"aria-label":f,style:m,ref:n,...p}):e.createElement(`svg`,{className:h,width:l??24,height:l??24,role:f?`img`:void 0,"aria-hidden":!f||void 0,style:m,ref:n,...p},f&&e.createElement(`title`,null,f),e.createElement(`use`,{href:`${u}#${a}`}))});c.displayName=`Icon`;export{o as i,s as n,a as r,c as t};
2
- //# sourceMappingURL=Icon-DLB1f88W.js.map
1
+ import e,{createContext as t,forwardRef as n,useContext as r}from"react";import i from"classnames";const a={check:`check-solid`,previous:`chevron-left-outline`,next:`chevron-right-outline`,menu:`bars-outline`,more:`ellipsis-h-solid`,play:`play-solid`,pause:`pause-solid`,increment:`chevron-up-outline`,decrement:`chevron-down-outline`,search:`search-outline`,clear:`xmark-outline`,expand:`chevron-right-outline`},o=t({}),s=()=>r(o),c=n((t,n)=>{let r=s(),{name:a,className:o,font:c=r.font??!1,size:l,sprite:u=r.sprite??``,style:d,title:f,...p}=t,m=l==null?d:{"--cx-icon-size":typeof l==`number`?`${l}px`:l,...d},h=i(`icon`,{[`${r.fontPrefix??`cx-`}${a}`]:c},r.className,o);return c?/* @__PURE__ */ e.createElement(`span`,{className:h,role:f?`img`:void 0,"aria-hidden":!f||void 0,"aria-label":f,style:m,ref:n,...p}):/* @__PURE__ */ e.createElement(`svg`,{className:h,width:l??24,height:l??24,role:f?`img`:void 0,"aria-hidden":!f||void 0,style:m,ref:n,...p},f&&/* @__PURE__ */ e.createElement(`title`,null,f),/* @__PURE__ */ e.createElement(`use`,{href:`${u}#${a}`}))});c.displayName=`Icon`;export{o as i,s as n,a as r,c as t};
2
+ //# sourceMappingURL=Icon-Dk5_q79o.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Icon-Dk5_q79o.js","names":["React","classNames","DEFAULT_ICONS","IconContext","createContext","useIconConfig","useContext","Icon","forwardRef","config","rest","props","sizeStyle","size","style","_className","name","font","className","title","sprite"],"sources":["../../src/utils/iconConfig.ts","../../src/hooks/useIconConfig.ts","../../src/components/icon/Icon.tsx"],"sourcesContent":["import { ComponentType, createContext, ReactElement } from 'react'\n\n/**\n * The icons this library's own components draw, by purpose rather than by icon name — so a\n * consumer can map each one onto any icon set (see `IconProvider`'s `icons`).\n */\nexport type IconKey =\n | 'check'\n | 'previous'\n | 'next'\n | 'menu'\n | 'more'\n | 'play'\n | 'pause'\n | 'increment'\n | 'decrement'\n | 'search'\n | 'clear'\n | 'expand'\n\n/**\n * An icon given to `IconProvider`'s `icons` or to a component's icon prop: a string is an icon\n * name, rendered by `IconProvider`'s `component` (or the built-in `Icon`); an element is rendered\n * as-is, with the component's own class names merged onto it.\n */\nexport type IconValue = string | ReactElement\n\n/**\n * Props `IconProvider`'s `component` receives for every icon name it's asked to render.\n */\nexport interface IconComponentProps {\n /**\n * The icon name — an `IconValue` string, or `IconProvider`'s default for that icon.\n */\n name: string\n /**\n * The class names the rendering component needs on the icon (e.g. `menu-item-check`,\n * `directional-icon`) for chassis-css to position and flip it.\n */\n className?: string\n [prop: string]: unknown\n}\n\nexport interface IconConfig {\n /**\n * Class names added to every `Icon`, alongside its own `icon` class.\n */\n className?: string\n /**\n * Replaces the built-in `Icon` for every icon this library's components render by name — the\n * strings in `icons` and their defaults, and a string `icon` on `Toast`/`Notification`. A\n * component reference can't be passed from a React Server Component, so set this in a\n * `'use client'` module.\n */\n component?: ComponentType<IconComponentProps>\n /**\n * Render `Icon` as an icon-font glyph instead of an SVG sprite reference, unless an `Icon` sets\n * `font` itself. Needs the icon font's stylesheet loaded.\n */\n font?: boolean\n /**\n * Class-name prefix of the icon font's glyphs: an icon named `check-solid` renders as\n * `{fontPrefix}check-solid`.\n *\n * @default 'cx-'\n */\n fontPrefix?: string\n /**\n * The icon to render for each of the library's own icons, by purpose. Unset ones keep their\n * defaults (`check-solid`, `chevron-left-outline`, `chevron-right-outline`, `bars-outline`,\n * `ellipsis-h-solid`, `play-solid`, `pause-solid`, `chevron-up-outline`, `chevron-down-outline`,\n * `search-outline`, `xmark-outline`, `chevron-right-outline`).\n */\n icons?: Partial<Record<IconKey, IconValue>>\n /**\n * URL of the SVG sprite `Icon` references, e.g. `/static/icons/chassis-icons.svg`. Leave empty\n * (the default) when the sprite is embedded in the page, so icons render as `href=\"#name\"`.\n * Browsers don't load an external sprite from another origin.\n *\n * @default ''\n */\n sprite?: string\n}\n\n// The chassis-icons names this library used before its icons became configurable. Both\n// previous/next consumers (Pagination, Carousel) now share the outline chevrons — Pagination used\n// the solid ones.\nexport const DEFAULT_ICONS: Record<IconKey, string> = {\n check: 'check-solid',\n previous: 'chevron-left-outline',\n next: 'chevron-right-outline',\n menu: 'bars-outline',\n more: 'ellipsis-h-solid',\n play: 'play-solid',\n pause: 'pause-solid',\n increment: 'chevron-up-outline',\n decrement: 'chevron-down-outline',\n search: 'search-outline',\n clear: 'xmark-outline',\n expand: 'chevron-right-outline'\n}\n\nexport const DEFAULT_FONT_PREFIX = 'cx-'\n\n// Lives in `utils/` rather than `components/icon/` because it's read outside that folder too —\n// by `IconSlot` (`./iconSlot.tsx`), which every icon-drawing component renders through.\nexport const IconContext = createContext<IconConfig>({})\n","import { useContext } from 'react'\n\nimport { IconConfig, IconContext } from '../utils/iconConfig'\n\n// The nearest `IconProvider`'s settings, merged with every provider above it; empty outside one.\nexport const useIconConfig = (): IconConfig => useContext(IconContext)\n","import React, { CSSProperties, forwardRef, HTMLAttributes, SVGAttributes } from 'react'\nimport classNames from 'classnames'\n\nimport { useIconConfig } from '../../hooks/useIconConfig'\nimport { DEFAULT_FONT_PREFIX } from '../../utils/iconConfig'\n\ninterface IconOwnProps {\n /**\n * Icon name, e.g. `folder-tree`. Matches an id in the SVG sprite, or a `cx-{name}` font glyph\n * class in `font` mode (see `IconProvider`'s `fontPrefix`).\n */\n name: string\n /**\n * A string of all className you want applied to the component.\n */\n className?: string\n /**\n * Icon size: a number of pixels, or any CSS length (`'1.25rem'`, `'1em'`). Sets chassis-css's\n * `--cx-icon-size` on the icon, so it applies in `font` mode too. Leave unset to keep the size\n * chassis-css gives icons in context (inside a button, an input, a navbar toggler, ...).\n */\n size?: number | string\n /**\n * Accessible name. When set, the icon is exposed to assistive tech instead of hidden.\n */\n title?: string\n /**\n * URL of the SVG sprite file. Defaults to `IconProvider`'s `sprite`, or to none — a sprite\n * embedded in the page, referenced as `#name`. Ignored in `font` mode.\n */\n sprite?: string\n}\n\nexport type IconProps =\n | (IconOwnProps & { font: true } & Omit<HTMLAttributes<HTMLSpanElement>, keyof IconOwnProps>)\n | (IconOwnProps & { font?: false } & Omit<SVGAttributes<SVGSVGElement>, keyof IconOwnProps>)\n\n// An SVG's `width`/`height` attributes lose to chassis-css's `.icon { width: var(--cx-icon-size) }`\n// — `size` used to set only those, so `size={48}` rendered at the stylesheet's 24px whenever\n// chassis-css was loaded. The custom property is what actually sizes an icon; the attributes stay\n// as the fallback for a page without chassis-css, where an unsized `<svg>` would render 300×150.\nconst FALLBACK_SIZE = 24\n\nexport const Icon = forwardRef<HTMLSpanElement | SVGSVGElement, IconProps>((props, ref) => {\n const config = useIconConfig()\n const {\n name,\n className,\n font = config.font ?? false,\n size,\n sprite = config.sprite ?? '',\n style,\n title,\n ...rest\n } = props as IconOwnProps & { font?: boolean; style?: CSSProperties }\n\n const sizeStyle =\n size == null\n ? style\n : ({\n '--cx-icon-size': typeof size === 'number' ? `${size}px` : size,\n ...style\n } as CSSProperties)\n const _className = classNames(\n 'icon',\n { [`${config.fontPrefix ?? DEFAULT_FONT_PREFIX}${name}`]: font },\n config.className,\n className\n )\n\n if (font) {\n return (\n <span\n className={_className}\n // A plain `<span>`'s implicit \"generic\" role doesn't support naming, so `aria-label`\n // alone is dropped by browsers/assistive tech - `role=\"img\"` (matching the SVG path's\n // own implicit role) is what actually makes the accessible name stick.\n role={title ? 'img' : undefined}\n aria-hidden={title ? undefined : true}\n aria-label={title}\n style={sizeStyle}\n ref={ref as React.Ref<HTMLSpanElement>}\n {...(rest as HTMLAttributes<HTMLSpanElement>)}\n />\n )\n }\n\n return (\n <svg\n className={_className}\n width={size ?? FALLBACK_SIZE}\n height={size ?? FALLBACK_SIZE}\n role={title ? 'img' : undefined}\n aria-hidden={title ? undefined : true}\n style={sizeStyle}\n ref={ref as React.Ref<SVGSVGElement>}\n {...(rest as SVGAttributes<SVGSVGElement>)}\n >\n {title && <title>{title}</title>}\n <use href={`${sprite}#${name}`} />\n </svg>\n )\n})\n\nIcon.displayName = 'Icon'\n"],"mappings":"A,mGAuFA,MAAaE,EAAyC,CACpD,MAAO,cACP,SAAU,uBACV,KAAM,wBACN,KAAM,eACN,KAAM,mBACN,KAAM,aACN,MAAO,cACP,UAAW,qBACX,UAAW,uBACX,OAAQ,iBACR,MAAO,gBACP,OAAQ,uBACV,EAMaC,EAAcC,EAA0B,CAAC,CAAC,ECrG1CC,MAAkCC,EAAWH,CAAW,ECsCxDI,EAAOC,GAAwD,EAAO,IAAQ,CACzF,IAAMC,EAASJ,EAAc,EACvB,CACJ,OACA,YACA,OAAOI,EAAO,MAAQ,GACtB,OACA,SAASA,EAAO,QAAU,GAC1B,QACA,QACA,GAAGC,GACDC,EAEEC,EACJC,GAAQ,KACJC,EACC,CACC,iBAAkB,OAAOD,GAAS,SAAW,GAAGA,EAAK,IAAMA,EAC3D,GAAGC,CACL,EACAC,EAAad,EACjB,OACA,EAAG,GAAGQ,EAAO,YAAA,QAAoCO,KAASC,CAAK,EAC/DR,EAAO,UACPS,CACF,EAmBA,OAjBID,EAEA,kBAAA,cAAC,OAAD,CACE,UAAWF,EAIX,KAAMI,EAAQ,MAAQ,IAAA,GACtB,cAAa,IAAQ,IAAA,GACrB,aAAYA,EACZ,MAAOP,EACF,MACL,GAAKF,CACN,CAAA,EAKH,kBAAA,cAAC,MAAD,CACE,UAAWK,EACX,MAAOF,GAAQ,GACf,OAAQA,GAAQ,GAChB,KAAMM,EAAQ,MAAQ,IAAA,GACtB,cAAa,IAAQ,IAAA,GACrB,MAAOP,EACF,MACL,GAAKF,CAIF,EAFFS,GAAS,kBAAA,cAAC,QAAA,KAAOA,CAAa,EAC/B,kBAAA,cAAC,MAAD,CAAK,KAAM,GAAGC,EAAO,GAAGJ,GAAS,CAAA,CAC9B,CAET,CAAC,EAED,EAAK,YAAc,O"}
@@ -0,0 +1,2 @@
1
+ import{f as e,m as t,p as n,v as r}from"./slot-BQVx1Eew.js";import{t as i}from"./useForkedRef-WoqMqsWE.js";import{t as a}from"./polymorphic-CZIFszAy.js";import{t as o}from"./useButtonSemantics-B1SbGaDO.js";import{t as s}from"./useDisabledAnchorGuard-CH6df46a.js";import{r as c}from"./colorClassNames-YzGWu6qm.js";import{n as l}from"./scrollspy-D_lPjb92.js";import u from"react";import d from"classnames";import{mergeProps as f}from"react-aria";function p({children:a,active:p,className:m,color:h,component:g,disabled:_,href:v,iconLink:y,onClick:b,reset:x,stretched:S,type:C=`button`,...w},T){let E=t(g,v,`a`),D=r(E,v,w),O=n(D),k=D===`component`,A=l(_),j=A.onClick,M=s(D===`anchor`,_,j?e=>{b?.(e),j(e)}:b),N=!O&&!k&&!!b,{buttonProps:P,forkedRef:F}=o(T,{disabled:_,onClick:b}),I=N?F:T,L=i(I,A.ref),R=p||!!A.mark,z=w[`aria-current`]??(p?`page`:A.mark===`current`?`true`:void 0),B=d(h&&c[h],{"icon-link":y,"fg-reset":x,"stretched-link":S},{active:R,disabled:_},m);return/* @__PURE__ */ u.createElement(E,{...f(w,N?P:{}),className:B,...e(D,v,`Link`),...z&&{"aria-current":z},...D===`anchor`&&_&&{"aria-disabled":!0,tabIndex:-1},...!N&&{onClick:M},...D===`button`&&{disabled:_,type:C},ref:A.ref?L:I},a)}const m=a(p,`Link`);export{m as t};
2
+ //# sourceMappingURL=Link-DE8NSAXJ.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Link-DE8NSAXJ.js","names":["hrefProps","linkElement","isInteractiveKind","resolveLinkKind","useForkedRef","createPolymorphicComponent","useButtonSemantics","useDisabledAnchorGuard","LINK_COLOR_CLASS_NAMES","useScrollspyLink","React","classNames","LinkRender","rest","Component","component","href","kind","isInteractive","isComponentReference","spy","disabled","spyClick","handleClick","onClick","event","needsButtonSemantics","ref","ownRef","forkedRef","spyRef","isActive","active","ariaCurrent","_className","color","iconLink","reset","stretched","className","mergeProps","buttonProps","children","Link"],"sources":["../../src/components/link/Link.tsx"],"sourcesContent":["import React, {\n AriaAttributes,\n ElementType,\n ForwardRefRenderFunction,\n MouseEventHandler,\n ReactElement,\n Ref\n} from 'react'\nimport classNames from 'classnames'\nimport { mergeProps } from 'react-aria'\n\nimport { ContextColor } from '../../types'\nimport { LINK_COLOR_CLASS_NAMES } from '../../utils/colorClassNames'\nimport { useButtonSemantics, useDisabledAnchorGuard, useForkedRef } from '../../hooks'\nimport { hrefProps, isInteractiveKind, linkElement, resolveLinkKind } from '../../utils/elementKind'\nimport {\n createPolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef\n} from '../../utils/polymorphic'\nimport { useScrollspyLink } from '../../utils/scrollspy'\n\ntype LinkOwnProps<C extends ElementType> = {\n /**\n * Toggle the active state for the component.\n */\n active?: boolean\n /**\n * A string of all className you want applied to the component.\n */\n className?: string\n /**\n * Sets the link color to one of Chassis context colors, including its interactive\n * (`:hover`/`:focus`/`:active`/`:visited`) states.\n */\n color?: ContextColor\n /**\n * Component used for the root node. Either a string to use a HTML element or a component.\n */\n component?: C\n /**\n * Toggle the disabled state for the component.\n */\n disabled?: boolean\n /**\n * The href attribute specifies the URL of the page the link goes to. Reaches an `<a>` or a\n * component reference (a router link); dropped, with a warning in development, when\n * `component` is another element. Declared explicitly here — rather than left to flow through\n * generically from whatever `C` is — so consumers that wrap `Link` (`MenuItem`, `ListItem`,\n * `NavLink`) can read it with a concrete type regardless of `component`.\n */\n href?: string\n /**\n * Fires on click.\n */\n onClick?: MouseEventHandler<HTMLElement>\n /**\n * Aligns a leading or trailing icon with the link text using flexbox, with a gap between\n * them and an offset underline. Icons need to be passed as `children` alongside the text.\n * Named `iconLink` rather than `icon` to avoid colliding with components (e.g. `MenuItem`)\n * that already have their own, differently-typed `icon` prop for the icon content itself.\n */\n iconLink?: boolean\n /**\n * Removes the foreground color override, so the link inherits its color from the nearest\n * ancestor instead of the default link color.\n */\n reset?: boolean\n /**\n * Expands the link's click target to fill its positioned ancestor (the nearest ancestor with\n * a `position` other than `static`).\n */\n stretched?: boolean\n /**\n * Specifies the type of button. Only applies when `component=\"button\"`. Different browsers may\n * use different default types for the `<button>` element, so always specify it explicitly.\n */\n type?: 'button' | 'submit' | 'reset'\n}\n\nexport type LinkProps<C extends ElementType = 'a'> = PolymorphicComponentProps<C, LinkOwnProps<C>>\n\ntype LinkComponent = (<C extends ElementType = 'a'>(\n props: LinkProps<C> & { ref?: PolymorphicRef<C> }\n) => ReactElement | null) & { displayName?: string }\n\nfunction LinkRender<C extends ElementType = 'a'>(\n {\n children,\n active,\n className,\n color,\n component,\n disabled,\n href,\n iconLink,\n onClick,\n reset,\n stretched,\n type = 'button',\n ...rest\n }: LinkProps<C>,\n ref: PolymorphicRef<C>\n) {\n const Component = linkElement(component, href, 'a')\n // The kind rather than the tag, counting a router link with `href` or `to` as an anchor: under `asChild`, `Component` is a `Slot` standing in for the\n // caller's element, and a slotted `<a>` needs what `component=\"a\"` gets.\n const kind = resolveLinkKind(Component, href, rest)\n\n const isInteractive = isInteractiveKind(kind)\n // A component reference without a link target (a router link with `href` or `to` is an anchor,\n // see `resolveLinkKind`) has its own visual identity and is trusted to\n // handle its own keyboard/role semantics, same as `CloseButton`'s `isComponentReference` escape\n // hatch — synthesizing `role=\"button\"` and Enter/Space handling on top of it would stamp the\n // wrong ARIA role onto whatever it actually renders (e.g. an `<a>`) and can double-fire a click\n // (native anchor Enter→click, plus the synthesized keydown→click).\n const isComponentReference = kind === 'component'\n // Inside a `Scrollspy`, the link registers its element, is marked when its section is the one\n // being read, and scrolls to it smoothly when the `Scrollspy` is set to (`src/utils/scrollspy.ts`).\n const spy = useScrollspyLink(disabled)\n const spyClick = spy.onClick\n const clickHandler: MouseEventHandler<HTMLElement> | undefined = spyClick\n ? (event) => {\n onClick?.(event)\n spyClick(event)\n }\n : onClick\n // `<a>` has no real `disabled` attribute, so a disabled anchor link still fires click (and\n // still navigates) unless it's blocked here, same guard `Button`/`CloseButton` apply. A real\n // `<button>` already stops clicks on its own once the `disabled` attribute below is set.\n const handleClick = useDisabledAnchorGuard<HTMLElement>(kind === 'anchor', disabled, clickHandler)\n\n // A `component` that isn't a native interactive element gets a raw onClick with no\n // keyboard semantics otherwise — mouse-only, unlike `Button`/`CloseButton`, which\n // synthesize this via `useButtonSemantics` for exactly this \"arbitrary component\" case. A\n // component reference is excluded (see `isComponentReference` above).\n const needsButtonSemantics = !isInteractive && !isComponentReference && !!onClick\n const { buttonProps, forkedRef } = useButtonSemantics<HTMLElement>(ref as Ref<HTMLElement>, {\n disabled,\n onClick\n })\n const ownRef = needsButtonSemantics ? forkedRef : ref\n const spyRef = useForkedRef(ownRef as Ref<HTMLElement>, spy.ref)\n // A link to the section being read is `active` and `aria-current=\"true\"`: the current place in\n // the page, not the current page. A link it belongs under, such as its menu's toggle, only\n // looks active. An `active` given as a prop wins, and an `aria-current` given as one wins over\n // both: a step of a process is `\"step\"`, not the current page.\n const isActive = active || !!spy.mark\n const ownAriaCurrent = (rest as AriaAttributes)['aria-current']\n const ariaCurrent =\n ownAriaCurrent ?? (active ? 'page' : spy.mark === 'current' ? 'true' : undefined)\n\n const _className = classNames(\n color && LINK_COLOR_CLASS_NAMES[color],\n { 'icon-link': iconLink, 'fg-reset': reset, 'stretched-link': stretched },\n { active: isActive, disabled },\n className\n )\n\n return (\n <Component\n {...(mergeProps(rest, needsButtonSemantics ? buttonProps : {}) as Record<string, unknown>)}\n className={_className}\n {...hrefProps(kind, href, 'Link')}\n {...(ariaCurrent && { 'aria-current': ariaCurrent })}\n {...(kind === 'anchor' && disabled && { 'aria-disabled': true, tabIndex: -1 })}\n {...(!needsButtonSemantics && { onClick: handleClick })}\n {...(kind === 'button' && { disabled, type })}\n ref={spy.ref ? spyRef : ownRef}\n >\n {children}\n </Component>\n )\n}\n\nexport const Link = createPolymorphicComponent<LinkComponent>(\n LinkRender as ForwardRefRenderFunction<Element, LinkProps<ElementType>>,\n 'Link'\n)\n"],"mappings":"A,4bAsFA,SAASY,EACP,CACE,WACA,SACA,YACA,QACA,YACA,WACA,OACA,WACA,UACA,QACA,YACA,OAAO,SACP,GAAGC,GAEL,EACA,CACA,IAAMC,EAAYb,EAAYc,EAAWC,EAAM,GAAG,EAG5CC,EAAOd,EAAgBW,EAAWE,EAAMH,CAAI,EAE5CK,EAAgBhB,EAAkBe,CAAI,EAOtCE,EAAuBF,IAAS,YAGhCG,EAAMX,EAAiBY,CAAQ,EAC/BC,EAAWF,EAAI,QAUfG,EAAchB,EAAoCU,IAAS,SAAUI,EATVC,EAC5D,GAAU,CACTE,IAAUC,CAAK,EACfH,EAASG,CAAK,CAChB,EACAD,CAI6F,EAM3FE,EAAuB,CAACR,GAAiB,CAACC,GAAwB,CAAC,CAACK,EACpE,CAAE,cAAa,aAAclB,EAAgCqB,EAAyB,CAC1F,WACA,SACF,CAAC,EACKC,EAASF,EAAuBG,EAAYF,EAC5CG,EAAS1B,EAAawB,EAA4BR,EAAI,GAAG,EAKzDW,EAAWC,GAAU,CAAC,CAACZ,EAAI,KAE3Ba,EADkBpB,EAAwB,kBAE3BmB,EAAS,OAASZ,EAAI,OAAS,UAAY,OAAS,IAAA,IAEnEc,EAAavB,EACjBwB,GAAS3B,EAAuB2B,GAChC,CAAE,YAAaC,EAAU,WAAYC,EAAO,iBAAkBC,CAAU,EACxE,CAAE,OAAQP,EAAU,UAAS,EAC7BQ,CACF,EAEA,MACE,kBAAA,cAACzB,EAAD,CACE,GAAK0B,EAAW3B,EAAMa,EAAuBe,EAAc,CAAC,CAAC,EAC7D,UAAWP,EACX,GAAIlC,EAAUiB,EAAMD,EAAM,MAAM,EAChC,GAAKiB,GAAe,CAAE,eAAgBA,CAAY,EAClD,GAAKhB,IAAS,UAAYI,GAAY,CAAE,gBAAiB,GAAM,SAAU,EAAG,EAC5E,GAAK,CAACK,GAAwB,CAAE,QAASH,CAAY,EACrD,GAAKN,IAAS,UAAY,CAAE,WAAU,MAAK,EAC3C,IAAKG,EAAI,IAAMU,EAASF,CAGf,EADRc,CACQ,CAEf,CAEA,MAAaC,EAAOtC,EAClBO,EACA,MACF,E"}
@@ -0,0 +1,2 @@
1
+ import{t as e}from"./useForkedRef-WoqMqsWE.js";import{t}from"./polymorphic-CZIFszAy.js";import{t as n}from"./useIsomorphicLayoutEffect-BbqRwuqn.js";import{t as r}from"./dialogTransition-C8fYTsSa.js";import{n as i}from"./overlayStack-BXtTGCRm.js";import{r as a}from"./useFloatingOverlay-BuiI_CCn.js";import{t as o}from"./useOpenStateProps-BhjSQ3f6.js";import{t as s}from"./useOverlayMaxHeight-8mQL2Q6d.js";import{i as c,r as l}from"./overlayPlacement-Q6bcbXA5.js";import{n as ee}from"./insideEvents-CWcNrMu7.js";import{t as te}from"./navOverflow-C_QJmkPM.js";import u,{Fragment as d,createContext as f,useEffect as p,useMemo as ne,useRef as m}from"react";import re from"classnames";import{useMenuTrigger as ie,useOverlayPosition as h}from"react-aria";import{useMenuTriggerState as g}from"react-stately";const _=()=>void 0,v=f({autoClose:!0,close:_,focusStrategy:null,hide:_,menuId:``,menuStyle:{},menuTriggerProps:{},overlayRef:{current:null},placementAttr:`bottom-start`,reference:`toggle`,registerOverlay:_,show:_,targetRef:{current:null},toggle:_,toggleNodeRef:{current:null},triggerId:``,visible:!1}),y=/* @__PURE__ */ new WeakSet,b=/* @__PURE__ */ new Set;function x({children:t,autoClose:f=!0,className:_,component:x,container:S,defaultVisible:C,offset:w=[0,2],onHide:ae,onHidden:T,onShow:oe,onShown:E,onVisibleChange:D,placement:O=`bottom-start`,reference:k=`toggle`,visible:A,...se},ce){let j=x??d,M=m(null),le=e(ce,M),N=m(null),P=m(null),F=m(null),I=m(/* @__PURE__ */ new Map),L=(e,t)=>{t?I.current.set(e,t):I.current.delete(e)},R=g(o({defaultVisible:C,onVisibleChange:D,visible:A},`Menu`)),{menuTriggerProps:z,menuProps:B}=ie({},R,N);n(()=>{k===`parent`&&(P.current=M.current)},[k]);let V=m(!1);p(()=>{let e=F.current,t=!V.current;if(V.current=!0,!t){if(R.isOpen){if(oe?.(),!e){E?.();return}return r(e,()=>E?.(),!0)}if(ae?.(),!e)T?.();else return r(e,()=>T?.(),!0)}},[R.isOpen]);let{overlayProps:H,placement:U,updatePosition:ue}=h({targetRef:P,overlayRef:F,placement:c(O),offset:w[1],crossOffset:w[0],containerPadding:8,isOpen:R.isOpen,onClose:null});s(F,R.isOpen);let{menuStyle:W,placementAttr:G}=l(H.style,O,U),K=m(!0);K.current=A===void 0||!!D;let q=m(!1);q.current=A!==void 0;let J=m(!1),de=e=>R.open(e),Y=()=>{J.current=!1,R.close()},X=e=>R.toggle(e),Z=()=>{R.close(),q.current?J.current=K.current:N.current?.focus()};p(()=>{!R.isOpen&&J.current&&N.current?.focus(),J.current=!1},[R.isOpen]);let Q=a({close:Y,isOpen:R.isOpen,triggerRef:N});n(()=>{R.isOpen&&ue()},[Q]),p(()=>{if(!R.isOpen||f===!1)return;let e=/* @__PURE__ */ new WeakSet,t=t=>{if(t instanceof KeyboardEvent&&t.key!==`Tab`||e.has(t))return;e.add(t);let n=t.target,r=N.current,i=F.current;if(r?.contains(n))return;let a=!!i?.contains(n)||Array.from(I.current.values()).some(e=>e.contains(n));if(!a&&ee(t,F)||a&&y.has(t)||f===`inside`&&!a||f===`outside`&&a||a&&(t instanceof KeyboardEvent&&t.key===`Tab`||/input|select|option|textarea|form/i.test(n.tagName??``)))return;let o=document.activeElement,s=!o||o===document.body||!!i?.contains(o)||Array.from(I.current.values()).some(e=>e.contains(o));a&&s?Z():Y()},n=window.setTimeout(()=>{window.addEventListener(`click`,t),window.addEventListener(`keyup`,t),b.add(t)});return()=>{window.clearTimeout(n),window.removeEventListener(`click`,t),window.removeEventListener(`keyup`,t),b.delete(t)}},[R.isOpen,f]),p(()=>{if(R.isOpen)return i({nodes:()=>[F.current,N.current],onEscape:Z})},[R.isOpen]);let fe=ne(()=>({autoClose:f,close:Z,container:S===!0?Q??!0:S,focusStrategy:R.focusStrategy,hide:Y,menuId:B.id??``,menuStyle:W,menuTriggerProps:z,overlayRef:F,placementAttr:G,portalContainer:Q,reference:k,registerOverlay:L,show:de,targetRef:P,toggle:X,toggleNodeRef:N,triggerId:z.id??``,visible:R.isOpen}),[f,S,R.focusStrategy,B.id,W,z,G,Q,k,R.isOpen]),$=/* @__PURE__ */ u.createElement(te,null,t);return/* @__PURE__ */ u.createElement(v.Provider,{value:fe},j===d?$:/* @__PURE__ */ u.createElement(j,{className:re(_,{show:R.isOpen}),...se,ref:le},$))}const S=t(x,`Menu`);export{b as i,v as n,y as r,S as t};
2
+ //# sourceMappingURL=Menu-264aGoBR.js.map