@midas-ds/components 10.3.0 → 10.4.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 (363) hide show
  1. package/AccordionItem-BcsoC78F.cjs +1 -0
  2. package/{AccordionItem-ChHpW8EW.js → AccordionItem-BqsgiVWV.js} +38 -36
  3. package/Breadcrumbs-CfW5IuyE.cjs +1 -0
  4. package/{Breadcrumbs-CwDUNIqF.js → Breadcrumbs-D7eoibWk.js} +77 -65
  5. package/{Button-BoJl6JGM.cjs → Button-BXY5ZhqI.cjs} +1 -1
  6. package/{Button-Csih3v23.js → Button-BZUo7vsZ.js} +1 -1
  7. package/{Button-DjBChs7s.js → Button-CFYdzG0H.js} +24 -23
  8. package/Button-DExMoP5f.cjs +1 -0
  9. package/CHANGELOG.md +28 -0
  10. package/{Card-yrtGzt70.js → Card-BaWSgtSF.js} +3 -3
  11. package/{Card-0G0mj9q5.cjs → Card-Cc1TNPcQ.cjs} +1 -1
  12. package/{CharacterCounter-CHcTDHO-.cjs → CharacterCounter-DSFBv3Rw.cjs} +1 -1
  13. package/{CharacterCounter-BL_nZHya.js → CharacterCounter-cLhqPZlk.js} +4 -4
  14. package/Checkbox-Co3h0hur.cjs +1 -0
  15. package/{Checkbox-5HINZdGu.js → Checkbox-LuUwTZ3W.js} +69 -68
  16. package/CheckboxGroup-CUA8_xSx.js +160 -0
  17. package/CheckboxGroup-DmUOM0xl.cjs +1 -0
  18. package/{Collection-Brgjpkne.js → Collection--62xKPm9.js} +17 -16
  19. package/Collection-BtBX5IMY.cjs +1 -0
  20. package/{ColorSchemeSwitch-BpzQ7g0b.js → ColorSchemeSwitch-Cwono7Ap.js} +51 -35
  21. package/ColorSchemeSwitch-DDXdSzqg.cjs +16 -0
  22. package/ComboBox-BBC7jhnm.cjs +1 -0
  23. package/{ComboBox-CVDyp2a-.js → ComboBox-HLIAbb2q.js} +309 -298
  24. package/{DateField-DeDhiYnW.cjs → DateField-B3VjOSde.cjs} +1 -1
  25. package/{DateField-DhU3q-rG.js → DateField-CnLEi7uX.js} +4 -4
  26. package/DateInputDivider-3BvwXXa9.cjs +1 -0
  27. package/{DateInputDivider-CF4xWsMT.js → DateInputDivider-Bi5N-C0c.js} +90 -86
  28. package/DateRangePicker-BPlZ12r8.cjs +6 -0
  29. package/{DateRangePicker-ziD1_k1W.js → DateRangePicker-CFOoGvut.js} +86 -83
  30. package/Dialog-CSnN6baf.cjs +1 -0
  31. package/{Dialog-D14MbJ7o.js → Dialog-CtVrVuMr.js} +101 -98
  32. package/Dialog-SqciohRY.js +221 -0
  33. package/Dialog-pSSy1zwf.cjs +1 -0
  34. package/DragAndDrop-BoEd260f.cjs +1 -0
  35. package/{DragAndDrop-o3ruz_SR.js → DragAndDrop-DkSTL28C.js} +2 -2
  36. package/{Dropdown-Df58j43I.js → Dropdown-CkBp70BH.js} +2 -2
  37. package/{Dropdown-CJ6My6EI.cjs → Dropdown-DAsVShlt.cjs} +1 -1
  38. package/FieldError-B3YFj-an.js +23 -0
  39. package/FieldError-BbR-29BM.js +28 -0
  40. package/FieldError-MVsU-Mgw.cjs +1 -0
  41. package/FieldError-bRTpchvr.cjs +1 -0
  42. package/{FileUpload-D6qoEAjn.js → FileUpload-B4rv-wke.js} +496 -475
  43. package/{FileUpload-CxCOtyB9.cjs → FileUpload-BwMhyLjG.cjs} +2 -2
  44. package/{FocusScope-CxkURfoc.js → FocusScope-D_hwN_TJ.js} +25 -24
  45. package/FocusScope-vcXLOQiu.cjs +1 -0
  46. package/Group-CpkUzEAs.js +45 -0
  47. package/Group-DOpbdoAi.cjs +1 -0
  48. package/{Heading-mHhCbGjY.cjs → Heading-CKTR4sOz.cjs} +1 -1
  49. package/{Heading-BFtiin0g.js → Heading-NxtGri2i.js} +1 -1
  50. package/{InfoBanner-BLM-TJJ6.js → InfoBanner-CBUoad7A.js} +47 -39
  51. package/InfoBanner-CVry6Y8i.cjs +1 -0
  52. package/{Input-BTzwcf72.js → Input-LnjmFI1x.js} +13 -12
  53. package/Input-MJji5hhq.cjs +1 -0
  54. package/Label-CNmTN1YY.cjs +1 -0
  55. package/Label-TVxwGZ-O.js +78 -0
  56. package/Layout-Dw-oCqxd.cjs +16 -0
  57. package/Layout-amz9BESl.js +498 -0
  58. package/{Link-yNO2-sqx.js → Link-Bn8V3ZI0.js} +8 -7
  59. package/Link-CidjjqHb.cjs +1 -0
  60. package/{Link-B88l_oaE.cjs → Link-D92ftFi2.cjs} +1 -1
  61. package/{Link-DX5BbBnn.js → Link-DegonJfl.js} +1 -1
  62. package/{LinkButton-o6uS1XsR.js → LinkButton-CckYzfJ8.js} +1 -1
  63. package/{LinkButton-CBpGLETx.cjs → LinkButton-DKZ4z6zu.cjs} +1 -1
  64. package/ListBox-BCz5-23H.cjs +1 -0
  65. package/{ListBox-GnVK_Pdq.js → ListBox-C-isJIHL.js} +101 -99
  66. package/{ListBoxButton-D_J3jlP0.js → ListBoxButton-C_krklY0.js} +1 -1
  67. package/{ListBoxButton-DPBrtXyv.cjs → ListBoxButton-DNm3gvcT.cjs} +1 -1
  68. package/{ListBoxSection-C0BGnpB4.js → ListBoxSection-BVR2xtOH.js} +9 -9
  69. package/ListBoxSection-CfQZoURJ.cjs +1 -0
  70. package/{ListKeyboardDelegate-DTg9h4v6.cjs → ListKeyboardDelegate-CPsZ7D83.cjs} +1 -1
  71. package/{ListKeyboardDelegate-DNI8GQtX.js → ListKeyboardDelegate-CY6t6y1t.js} +3 -3
  72. package/LocalizedStringFormatter-C0C54hjf.cjs +1 -0
  73. package/LocalizedStringFormatter-D-4Qyql0.js +77 -0
  74. package/Logo-BpH0HC91.cjs +1 -0
  75. package/{Logo-BIrOEINM.js → Logo-ME4ffCue.js} +34 -26
  76. package/{OverlayArrow-CDLXPTew.js → OverlayArrow-CfhSYL46.js} +57 -56
  77. package/OverlayArrow-DpZ1FqOd.cjs +1 -0
  78. package/{Popover-BGGXeD54.js → Popover-C8VY1YKi.js} +2 -2
  79. package/{Popover-CqNWzPf-.cjs → Popover-CnAsw3wI.cjs} +1 -1
  80. package/{ProgressBar-DMSg-Prr.js → ProgressBar-BNCjpcv8.js} +2 -2
  81. package/{ProgressBar-Jbg28j2a.cjs → ProgressBar-CcbxcWdT.cjs} +1 -1
  82. package/Radio-B2zfEFdq.cjs +1 -0
  83. package/{Radio-Cz29wPXd.js → Radio-CZYibh9r.js} +50 -47
  84. package/{RangeCalendar-RAlAHlNL.js → RangeCalendar-B16b6tJD.js} +304 -293
  85. package/RangeCalendar-C1LFeOVk.cjs +11 -0
  86. package/SSRProvider-40TXmsUG.js +50 -0
  87. package/SSRProvider-Bc-sMhsT.cjs +1 -0
  88. package/SearchField-CML0kjtn.cjs +6 -0
  89. package/{SearchField-IlvZ3Kh6.js → SearchField-giwECmXS.js} +175 -166
  90. package/Select-DKey6CeS.cjs +1 -0
  91. package/Select-mwaAv20X.js +665 -0
  92. package/SelectionManager-D0jYUYcy.cjs +1 -0
  93. package/{SelectionManager-B4ORduja.js → SelectionManager-zsWy3vsd.js} +91 -90
  94. package/{Separator-DECIYLtZ.cjs → Separator-CxF-3jhR.cjs} +1 -1
  95. package/{Separator-Cu9fYKUM.js → Separator-Dn5LYN5I.js} +4 -4
  96. package/Spinner-CbJ6YAz-.js +53 -0
  97. package/Spinner-yHcy8YHC.cjs +6 -0
  98. package/TabList-7VtCiXxX.cjs +1 -0
  99. package/TabList-CthsM5h6.js +435 -0
  100. package/{Table-F4oYBtUM.js → Table-BcQPvJT3.js} +46 -44
  101. package/Table-DkvNp6xm.cjs +16 -0
  102. package/{Tag-Du7GvSv2.js → Tag-Bs8T2Ei7.js} +131 -129
  103. package/Tag-CFWZ2LQW.cjs +1 -0
  104. package/Text-92cPh38G.js +15 -0
  105. package/{Text-B2K-BJKQ.cjs → Text-CfcjRtke.cjs} +1 -1
  106. package/{Text-3MNwRMpI.cjs → Text-DBHWi5gA.cjs} +1 -1
  107. package/{Text-jWWg0B20.js → Text-DlKqpvSa.js} +1 -1
  108. package/TextArea-DBNAVWqL.js +119 -0
  109. package/TextArea-XJDfeXRs.cjs +1 -0
  110. package/TextField-BdK9KEQ5.cjs +1 -0
  111. package/{TextField-C-hTPukq.js → TextField-ByDJkig9.js} +23 -22
  112. package/{Toast-Btg21Xge.js → Toast-DPPvPhrF.js} +75 -68
  113. package/Toast-l1bKo2oA.cjs +1 -0
  114. package/ToggleButtonGroup-DH8IgR4G.cjs +1 -0
  115. package/{ToggleButtonGroup-B5yz1tm2.js → ToggleButtonGroup-HOWNWtQZ.js} +46 -45
  116. package/{Tooltip-CMLs7WMw.js → Tooltip-5mLWn_wO.js} +29 -27
  117. package/Tooltip-pN5W3IK6.cjs +1 -0
  118. package/{VisuallyHidden-ZCYf65q4.js → VisuallyHidden-CYfmTSCD.js} +2 -2
  119. package/VisuallyHidden-Doyzl0F7.cjs +1 -0
  120. package/accordion/index.cjs +1 -1
  121. package/accordion/index.js +1 -1
  122. package/assets/Checkbox.css +1 -1
  123. package/assets/FileUpload.css +1 -1
  124. package/assets/RangeCalendar.css +1 -1
  125. package/assets/SearchField.css +1 -1
  126. package/assets/Spinner.css +1 -1
  127. package/assets/TabList.css +1 -0
  128. package/breadcrumbs/Breadcrumbs.d.ts +11 -7
  129. package/breadcrumbs/index.cjs +1 -1
  130. package/breadcrumbs/index.d.ts +1 -1
  131. package/breadcrumbs/index.js +1 -1
  132. package/button/index.cjs +1 -1
  133. package/button/index.js +1 -1
  134. package/calendar/CalendarGrid.d.ts +1 -0
  135. package/calendar/index.cjs +1 -1
  136. package/calendar/index.js +1 -1
  137. package/card/index.cjs +1 -1
  138. package/card/index.js +1 -1
  139. package/character-counter/index.cjs +1 -1
  140. package/character-counter/index.js +1 -1
  141. package/checkbox/Checkbox.d.ts +3 -1
  142. package/checkbox/index.cjs +1 -1
  143. package/checkbox/index.js +2 -2
  144. package/checkbox/intl/translations.json.d.ts +2 -30
  145. package/checkbox/types.d.ts +3 -1
  146. package/color-scheme-switch/ColorSchemeSwitch.d.ts +1 -0
  147. package/color-scheme-switch/index.cjs +1 -1
  148. package/color-scheme-switch/index.js +1 -1
  149. package/color-scheme-switch/intl/translations.json.d.ts +15 -0
  150. package/combobox/index.cjs +1 -1
  151. package/combobox/index.js +1 -1
  152. package/combobox/intl/translations.json.d.ts +11 -0
  153. package/{context-C81gPYvC.js → context-CGNJ3grH.js} +1 -1
  154. package/context-Df3XbgBG.cjs +1 -0
  155. package/date-field/index.cjs +1 -1
  156. package/date-field/index.js +2 -2
  157. package/date-picker/index.cjs +1 -1
  158. package/date-picker/index.js +1 -1
  159. package/dropdown/index.cjs +1 -1
  160. package/dropdown/index.js +1 -1
  161. package/field-error/index.cjs +1 -1
  162. package/field-error/index.js +1 -1
  163. package/file-upload/FileUpload.d.ts +1 -0
  164. package/file-upload/index.cjs +1 -1
  165. package/file-upload/index.js +1 -1
  166. package/file-upload/intl/translations.json.d.ts +17 -0
  167. package/{getScrollParent-BhFcYrwL.js → getScrollParent-CT_L9LUr.js} +1 -1
  168. package/{getScrollParent-DDJu9WHU.cjs → getScrollParent-CsZ9ciml.cjs} +1 -1
  169. package/heading/index.cjs +1 -1
  170. package/heading/index.js +1 -1
  171. package/index.cjs +1 -1
  172. package/index.js +100 -97
  173. package/info-banner/index.cjs +1 -1
  174. package/info-banner/index.js +1 -1
  175. package/info-banner/intl/translations.json.d.ts +11 -0
  176. package/label/index.cjs +1 -1
  177. package/label/index.js +1 -1
  178. package/label/intl/translations.json.d.ts +11 -0
  179. package/layout/Layout.d.ts +1 -0
  180. package/layout/context/LayoutContext.d.ts +1 -0
  181. package/layout/index.cjs +1 -1
  182. package/layout/index.js +1 -1
  183. package/layout/intl/translations.json.d.ts +23 -0
  184. package/link/index.cjs +1 -1
  185. package/link/index.js +2 -2
  186. package/link-button/index.cjs +1 -1
  187. package/link-button/index.js +2 -2
  188. package/list-box/index.cjs +1 -1
  189. package/list-box/index.js +2 -2
  190. package/logo/index.cjs +1 -1
  191. package/logo/index.js +1 -1
  192. package/logo/intl/translations.json.d.ts +11 -0
  193. package/mergeProps-B5KXZAI3.cjs +1 -0
  194. package/mergeProps-C1U1OIeJ.js +115 -0
  195. package/modal/index.cjs +1 -1
  196. package/modal/index.js +2 -2
  197. package/modal/intl/translations.json.d.ts +11 -0
  198. package/package.json +1 -1
  199. package/popover/index.cjs +1 -1
  200. package/popover/index.js +1 -1
  201. package/progress-bar/index.cjs +1 -1
  202. package/progress-bar/index.js +1 -1
  203. package/radio/Radio.d.ts +1 -4
  204. package/radio/index.cjs +1 -1
  205. package/radio/index.js +1 -1
  206. package/{scrollIntoView-Hwb_aaNf.js → scrollIntoView-BLnsPvFA.js} +1 -1
  207. package/scrollIntoView-joIyo-Jt.cjs +1 -0
  208. package/search-field/index.cjs +1 -1
  209. package/search-field/index.js +1 -1
  210. package/search-field/intl/translations.json.d.ts +11 -0
  211. package/select/index.cjs +1 -1
  212. package/select/index.js +1 -1
  213. package/select/intl/translations.json.d.ts +17 -0
  214. package/spinner/Spinner.d.ts +1 -0
  215. package/spinner/index.cjs +1 -1
  216. package/spinner/index.js +1 -1
  217. package/spinner/intl/translations.json.d.ts +11 -0
  218. package/table/index.cjs +1 -1
  219. package/table/index.js +1 -1
  220. package/tabs/Tab.d.ts +4 -0
  221. package/tabs/TabList.d.ts +3 -0
  222. package/tabs/TabPanel.d.ts +4 -0
  223. package/tabs/Tabs.d.ts +11 -5
  224. package/tabs/index.cjs +1 -1
  225. package/tabs/index.d.ts +3 -0
  226. package/tabs/index.js +5 -2
  227. package/tag/index.cjs +1 -1
  228. package/tag/index.js +1 -1
  229. package/text/index.cjs +1 -1
  230. package/text/index.js +1 -1
  231. package/textfield/index.cjs +1 -1
  232. package/textfield/index.js +1 -1
  233. package/textfield/intl/translations.json.d.ts +0 -72
  234. package/theme/index.cjs +1 -1
  235. package/theme/index.d.ts +5 -0
  236. package/theme/index.js +2 -2
  237. package/theme/tokens.d.ts +5 -0
  238. package/toast/Toast.d.ts +5 -2
  239. package/toast/index.cjs +1 -1
  240. package/toast/index.js +1 -1
  241. package/toggle-button/index.cjs +1 -1
  242. package/toggle-button/index.js +1 -1
  243. package/{tokens-p6pg1Cea.cjs → tokens-BghDnMdO.cjs} +1 -1
  244. package/{tokens-xp-7KMK7.js → tokens-fEwCQXDv.js} +16 -11
  245. package/tooltip/index.cjs +1 -1
  246. package/tooltip/index.js +1 -1
  247. package/{useButton-B8dB9sot.js → useButton-1-Jf-oHj.js} +3 -3
  248. package/useButton-D60q0SQw.cjs +1 -0
  249. package/{useDateFormatter-CnxoJ4jF.cjs → useDateFormatter-BJBt0jk_.cjs} +1 -1
  250. package/{useDateFormatter-EHm4auIg.js → useDateFormatter-BVCkxVdw.js} +2 -2
  251. package/{useEvent-IsD2Awnh.js → useEvent-CigwyJOw.js} +3 -3
  252. package/useEvent-DPxMu-X9.cjs +1 -0
  253. package/{useField-DvpGZkw_.js → useField-BEBXv5Mh.js} +4 -4
  254. package/useField-D1UkzeaI.cjs +1 -0
  255. package/{useFilter-CUq74PQ2.js → useFilter-CousKe2K.js} +1 -1
  256. package/{useFilter-BTgDWHVx.cjs → useFilter-e2oIVF_O.cjs} +1 -1
  257. package/useFocusRing-B-A1OLhU.cjs +1 -0
  258. package/useFocusRing-DOfBqnUN.js +33 -0
  259. package/useFocusWithin-CG8mAt2D.cjs +1 -0
  260. package/useFocusWithin-T1ifEM_s.js +54 -0
  261. package/{useFocusable-C8uh8K4g.js → useFocusable-ChPA2Jc7.js} +20 -18
  262. package/useFocusable-D7I1ujkW.cjs +1 -0
  263. package/useFormValidation-BlFGdPZB.cjs +1 -0
  264. package/{useFormValidation-BIGzfO9h.js → useFormValidation-BzzruZKm.js} +2 -2
  265. package/{useHasTabbableChild-C-1mZUQe.js → useHasTabbableChild-BE81d_ab.js} +2 -2
  266. package/useHasTabbableChild-CoQRpNbC.cjs +1 -0
  267. package/useHighlightSelectionDescription-BfR_vGOe.cjs +1 -0
  268. package/{useHighlightSelectionDescription-CnBDT86u.js → useHighlightSelectionDescription-D73hrkmn.js} +5 -5
  269. package/useHover-BE_XKZKe.cjs +1 -0
  270. package/useHover-DQvJ3Y-W.js +262 -0
  271. package/useLabels-CSU0kbtJ.cjs +1 -0
  272. package/{useLabels-BDwkBYbE.js → useLabels-LrKQiY11.js} +1 -1
  273. package/{useListState-CrZFZffI.js → useListState-CebsX_1d.js} +1 -1
  274. package/{useListState-Bx8u4IFG.cjs → useListState-DymkJGDF.cjs} +1 -1
  275. package/useLocalizedStringFormatter-BO2iZEL0.cjs +1 -0
  276. package/useLocalizedStringFormatter-BiX5BTlb.cjs +1 -0
  277. package/useLocalizedStringFormatter-CL9MUZ8A.js +22 -0
  278. package/useLocalizedStringFormatter-N0AyjzbM.js +25 -0
  279. package/usePress-BooY_CAy.cjs +7 -0
  280. package/{usePress-CNjmDzap.js → usePress-DuR4pVsE.js} +129 -128
  281. package/{useSingleSelectListState-0AGHxvy3.js → useSingleSelectListState-BLXvGjLI.js} +1 -1
  282. package/{useSingleSelectListState-Cl3KV5E1.cjs → useSingleSelectListState-BPhlCU26.cjs} +1 -1
  283. package/{useTextField-Cw-33OP_.js → useTextField-C-sUypsx.js} +8 -8
  284. package/useTextField-DnRrCg5o.cjs +1 -0
  285. package/utils/intl/useLocalizedStringFormatter.d.ts +2 -0
  286. package/utils-CoCR_Fce.js +234 -0
  287. package/utils-DHNZrQmj.cjs +1 -0
  288. package/utils-DJhAJHk_.js +152 -0
  289. package/utils-Dvdohqm9.cjs +1 -0
  290. package/AccordionItem-BGWiWjxA.cjs +0 -1
  291. package/Breadcrumbs-DtjJ1UmU.cjs +0 -1
  292. package/Button-htW9qIsS.cjs +0 -1
  293. package/Checkbox-DqcPg5hz.cjs +0 -1
  294. package/CheckboxGroup-BBrSMuDY.cjs +0 -1
  295. package/CheckboxGroup-CLgixk2p.js +0 -243
  296. package/Collection-BIDsXNhi.cjs +0 -1
  297. package/ColorSchemeSwitch-C-qWuqkU.cjs +0 -16
  298. package/ComboBox-CWJUg9Xx.cjs +0 -1
  299. package/DateInputDivider-ADvOavHw.cjs +0 -1
  300. package/DateRangePicker-BsAHhy99.cjs +0 -6
  301. package/Dialog-B8GTYbvu.cjs +0 -1
  302. package/Dialog-BOrYdX50.cjs +0 -1
  303. package/Dialog-CXNu48AC.js +0 -208
  304. package/DragAndDrop-DNth776R.cjs +0 -1
  305. package/FieldError-CAcjosk_.js +0 -46
  306. package/FieldError-CKBb2-mp.cjs +0 -1
  307. package/FocusScope-5c9SVBcR.cjs +0 -1
  308. package/Group-B6EslsHZ.js +0 -44
  309. package/Group-CgiqQHH1.cjs +0 -1
  310. package/InfoBanner-C2kTIsrB.cjs +0 -1
  311. package/Input-DKSAYvsw.cjs +0 -1
  312. package/Label-7Ybb99CE.cjs +0 -1
  313. package/Label-BwJrdqEE.js +0 -70
  314. package/Layout-1g6bMH62.cjs +0 -16
  315. package/Layout-Ey8flY7E.js +0 -468
  316. package/Link-BQhauBuw.cjs +0 -1
  317. package/ListBox-DP9M4H6R.cjs +0 -1
  318. package/ListBoxSection-BGaigBnG.cjs +0 -1
  319. package/Logo-DT2_2O43.cjs +0 -1
  320. package/OverlayArrow-D75k-EMl.cjs +0 -1
  321. package/Radio-BwqrdhQE.cjs +0 -1
  322. package/RangeCalendar-BehUaydF.cjs +0 -11
  323. package/SearchField-CxMwDeUM.cjs +0 -6
  324. package/Select-2q1iSzAX.cjs +0 -1
  325. package/Select-BVQZtoi9.js +0 -646
  326. package/SelectionManager-CwYux2h3.cjs +0 -1
  327. package/Spinner-D31SXm-U.js +0 -41
  328. package/Spinner-P35rvvsl.cjs +0 -6
  329. package/Table-B40CGLT-.cjs +0 -16
  330. package/Tabs-B4oZJkZG.js +0 -404
  331. package/Tabs-DA2qXhzb.cjs +0 -1
  332. package/Tag-DPAGmcMK.cjs +0 -1
  333. package/Text-BoXuUVVH.js +0 -15
  334. package/TextArea-C7JZ_pQd.cjs +0 -1
  335. package/TextArea-XeBCSyzl.js +0 -191
  336. package/TextField-BgNdhZi_.cjs +0 -1
  337. package/Toast-AbDA1BOs.cjs +0 -1
  338. package/ToggleButtonGroup-BFDoj0P6.cjs +0 -1
  339. package/Tooltip-DeBuBKhS.cjs +0 -1
  340. package/VisuallyHidden-CLWHbz2n.cjs +0 -1
  341. package/assets/Tabs.css +0 -1
  342. package/context-DjwhtgxQ.cjs +0 -1
  343. package/scrollIntoView-C8doLzDd.cjs +0 -1
  344. package/useButton-cpNi-fY4.cjs +0 -1
  345. package/useEvent-DxBxMX2V.cjs +0 -1
  346. package/useField-CXKYU74k.cjs +0 -1
  347. package/useFocusRing-CbImDrwF.cjs +0 -1
  348. package/useFocusRing-XnR3cZjO.js +0 -82
  349. package/useFocusable-NUVSFcRC.cjs +0 -1
  350. package/useFormValidation-ClximP89.cjs +0 -1
  351. package/useHasTabbableChild-DCBTulUQ.cjs +0 -1
  352. package/useHighlightSelectionDescription-CzYucm61.cjs +0 -1
  353. package/useHover-DjIHtjGN.js +0 -490
  354. package/useHover-_mv5J4_q.cjs +0 -1
  355. package/useLabels-BLOfc6Y-.cjs +0 -1
  356. package/useLocalizedStringFormatter-BKoxGZf1.js +0 -96
  357. package/useLocalizedStringFormatter-BsxLt89S.cjs +0 -1
  358. package/useLocalizedStringFormatter-D3JQyjb4.js +0 -21
  359. package/useLocalizedStringFormatter-ioacM-Yt.cjs +0 -1
  360. package/usePress-0AjDbW9R.cjs +0 -7
  361. package/useTextField--czJtyNd.cjs +0 -1
  362. package/utils-BNtZbAib.cjs +0 -1
  363. package/utils-DIMfEPAt.js +0 -308
@@ -0,0 +1,6 @@
1
+ "use strict";require('./assets/Spinner.css');const e=require("react/jsx-runtime"),r=require("./clsx-C11secjj.cjs"),c=require("./createLucideIcon-Cg_wkoIA.cjs"),o=require("./VisuallyHidden-Doyzl0F7.cjs"),d=require("./useLocalizedStringFormatter-BO2iZEL0.cjs");/**
2
+ * @license lucide-react v0.453.0 - ISC
3
+ *
4
+ * This source code is licensed under the ISC license.
5
+ * See the LICENSE file in the root directory of this source tree.
6
+ */const l=c.createLucideIcon("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]),u="_container_3nw95_4",g="_spinner_3nw95_8",p="_dark_3nw95_18",n={container:u,spinner:g,dark:p},_={loadingPleaseWait:"Loading, please wait..."},x={loadingPleaseWait:"Laddar, vänligen vänta..."},L={en:_,sv:x},k=({small:s,isOnColor:t=!1,className:a})=>{const i=d.useLocalizedStringFormatter(L);return e.jsxs("div",{className:r.clsx(n.container,a),role:"status",children:[e.jsx(l,{className:r.clsx(n.spinner,t&&n.dark),size:s?16:32,strokeWidth:s?2:3,absoluteStrokeWidth:!0}),e.jsx(o.$5c3e21d68f1c4674$export$439d29a4e110a164,{children:i.format("loadingPleaseWait")})]})};exports.Spinner=k;
@@ -0,0 +1 @@
1
+ "use strict";require('./assets/TabList.css');const h=require("react/jsx-runtime"),o=require("react"),g=require("./clsx-C11secjj.cjs"),V=require("./useObserveElement-MhzEsCkX.cjs"),A=require("./tokens-BghDnMdO.cjs"),x=require("./Collection-BtBX5IMY.cjs"),$=require("./utils-DHNZrQmj.cjs"),z=require("./Hidden-BxRZGdEW.cjs"),v=require("./mergeProps-B5KXZAI3.cjs"),S=require("./filterDOMProps-BS2lrgFA.cjs"),q=require("./inertValue-B3AFhVG4.cjs"),_=require("./usePress-BooY_CAy.cjs"),B=require("./useFocusable-D7I1ujkW.cjs"),I=require("./SelectionManager-D0jYUYcy.cjs"),L=require("./useLabels-CSU0kbtJ.cjs"),W=require("./useHasTabbableChild-CoQRpNbC.cjs"),U=require("./context-Df3XbgBG.cjs"),T=require("./useFocusRing-B-A1OLhU.cjs"),G=require("./useHover-BE_XKZKe.cjs"),J=require("./useSingleSelectListState-BPhlCU26.cjs");function Q(i){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(i){for(const t in i)if(t!=="default"){const n=Object.getOwnPropertyDescriptor(i,t);Object.defineProperty(e,t,n.get?n:{enumerable:!0,get:()=>i[t]})}}return e.default=i,Object.freeze(e)}const C=Q(o),O=new WeakMap;function D(i,e,t){return i?(typeof e=="string"&&(e=e.replace(/\s+/g,"")),`${O.get(i)}-${t}-${e}`):""}function X(i,e,t){let{key:n,isDisabled:a,shouldSelectOnPressUp:d}=i,{selectionManager:l,selectedKey:c}=e,r=n===c,s=a||e.isDisabled||e.selectionManager.isDisabled(n),{itemProps:u,isPressed:f}=I.$880e95eb8b93ba9a$export$ecf600387e221c37({selectionManager:l,key:n,ref:t,isDisabled:s,shouldSelectOnPressUp:d,linkBehavior:"selection"}),b=D(e,n,"tab"),m=D(e,n,"tabpanel"),{tabIndex:K}=u,p=e.collection.getItem(n),E=S.$65484d02dcb7eb3e$export$457c3d6518dd4c6f(p==null?void 0:p.props,{labelable:!0});delete E.id;let N=_.$ea8dcbcb9ea1b556$export$7e924b3091a3bd18(p==null?void 0:p.props),{focusableProps:H}=B.$f645667febf57a63$export$4c014de7c8940b4c({isDisabled:s},t);return{tabProps:v.$3ef42575df84b30b$export$9d1611c77c2fe928(E,H,N,u,{id:b,"aria-selected":r,"aria-disabled":s||void 0,"aria-controls":r?m:void 0,tabIndex:s?void 0:K,role:"tab"}),isSelected:r,isDisabled:s,isPressed:f}}function Y(i,e,t){let n=W.$83013635b024ae3d$export$eac1895992b9f3d6(t)?void 0:0;var a;const d=D(e,(a=i.id)!==null&&a!==void 0?a:e==null?void 0:e.selectedKey,"tabpanel"),l=L.$313b98861ee5dd6c$export$d6875122194c7b44({...i,id:d,"aria-labelledby":D(e,e==null?void 0:e.selectedKey,"tab")});return{tabPanelProps:v.$3ef42575df84b30b$export$9d1611c77c2fe928(l,{tabIndex:n,role:"tabpanel","aria-describedby":i["aria-describedby"],"aria-details":i["aria-details"]})}}class Z{getKeyLeftOf(e){return this.flipDirection?this.getNextKey(e):this.getPreviousKey(e)}getKeyRightOf(e){return this.flipDirection?this.getPreviousKey(e):this.getNextKey(e)}isDisabled(e){var t,n;return this.disabledKeys.has(e)||!!(!((n=this.collection.getItem(e))===null||n===void 0||(t=n.props)===null||t===void 0)&&t.isDisabled)}getFirstKey(){let e=this.collection.getFirstKey();return e!=null&&this.isDisabled(e)&&(e=this.getNextKey(e)),e}getLastKey(){let e=this.collection.getLastKey();return e!=null&&this.isDisabled(e)&&(e=this.getPreviousKey(e)),e}getKeyAbove(e){return this.tabDirection?null:this.getPreviousKey(e)}getKeyBelow(e){return this.tabDirection?null:this.getNextKey(e)}getNextKey(e){let t=e;do t=this.collection.getKeyAfter(t),t==null&&(t=this.collection.getFirstKey());while(t!=null&&this.isDisabled(t));return t}getPreviousKey(e){let t=e;do t=this.collection.getKeyBefore(t),t==null&&(t=this.collection.getLastKey());while(t!=null&&this.isDisabled(t));return t}constructor(e,t,n,a=new Set){this.collection=e,this.flipDirection=t==="rtl"&&n==="horizontal",this.disabledKeys=a,this.tabDirection=n==="horizontal"}}function ee(i,e,t){let{orientation:n="horizontal",keyboardActivation:a="automatic"}=i,{collection:d,selectionManager:l,disabledKeys:c}=e,{direction:r}=U.$18f2051aff69b9bf$export$43bb16f9c6d9e3f7(),s=o.useMemo(()=>new Z(d,r,n,c),[d,c,n,r]),{collectionProps:u}=I.$ae20dd8cbca75726$export$d6daf82dcd84e87c({ref:t,selectionManager:l,keyboardDelegate:s,selectOnFocus:a==="automatic",disallowEmptySelection:!0,scrollRef:t,linkBehavior:"selection"}),f=v.$bdb11010cef70236$export$f680877a34711e37();O.set(e,f);let b=L.$313b98861ee5dd6c$export$d6875122194c7b44({...i,id:f});return{tabListProps:{...v.$3ef42575df84b30b$export$9d1611c77c2fe928(u,b),role:"tablist","aria-orientation":n,tabIndex:void 0}}}function te(i){var e,t;let n=J.$a0d645289fe9b86b$export$e7f05e985daf4b5f({...i,onSelectionChange:i.onSelectionChange?r=>{var s;r!=null&&((s=i.onSelectionChange)===null||s===void 0||s.call(i,r))}:void 0,suppressTextValueWarning:!0,defaultSelectedKey:(t=(e=i.defaultSelectedKey)!==null&&e!==void 0?e:w(i.collection,i.disabledKeys?new Set(i.disabledKeys):new Set))!==null&&t!==void 0?t:void 0}),{selectionManager:a,collection:d,selectedKey:l}=n,c=o.useRef(l);return o.useEffect(()=>{let r=l;i.selectedKey==null&&(a.isEmpty||r==null||!d.getItem(r))&&(r=w(d,n.disabledKeys),r!=null&&a.setSelectedKeys([r])),(r!=null&&a.focusedKey==null||!a.isFocused&&r!==c.current)&&a.setFocusedKey(r),c.current=r}),{...n,isDisabled:i.isDisabled||!1}}function w(i,e){let t=null;if(i){var n,a,d,l;for(t=i.getFirstKey();t!=null&&(e.has(t)||!((a=i.getItem(t))===null||a===void 0||(n=a.props)===null||n===void 0)&&n.isDisabled)&&t!==i.getLastKey();)t=i.getKeyAfter(t);t!=null&&(e.has(t)||!((l=i.getItem(t))===null||l===void 0||(d=l.props)===null||d===void 0)&&d.isDisabled)&&t===i.getLastKey()&&(t=i.getFirstKey())}return t}const F=o.createContext(null),y=o.createContext(null),M=o.forwardRef(function(e,t){[e,t]=$.$64fa3d84918910a7$export$29f1550f4b0d4415(e,t,F);let{children:n,orientation:a="horizontal"}=e;return n=o.useMemo(()=>typeof n=="function"?n({orientation:a,defaultChildren:null}):n,[n,a]),o.createElement(x.$e1995378a142960e$export$bf788dd355e3a401,{content:n},d=>o.createElement(ie,{props:e,collection:d,tabsRef:t}))});function ie({props:i,tabsRef:e,collection:t}){let{orientation:n="horizontal"}=i,a=te({...i,collection:t,children:void 0}),{focusProps:d,isFocused:l,isFocusVisible:c}=T.$f7dceffc5ad7768b$export$4e328f61c538687f({within:!0}),r=o.useMemo(()=>({orientation:n,isFocusWithin:l,isFocusVisible:c}),[n,l,c]),s=$.$64fa3d84918910a7$export$4d86445c2cf5e3({...i,defaultClassName:"react-aria-Tabs",values:r});return o.createElement("div",{...S.$65484d02dcb7eb3e$export$457c3d6518dd4c6f(i),...d,...s,ref:e,slot:i.slot||void 0,"data-focused":l||void 0,"data-orientation":n,"data-focus-visible":c||void 0,"data-disabled":a.isDisabled||void 0},o.createElement($.$64fa3d84918910a7$export$2881499e37b75b9a,{values:[[F,i],[y,a]]},s.children))}const ne=o.forwardRef(function(e,t){return o.useContext(y)?o.createElement(ae,{props:e,forwardedRef:t}):o.createElement(x.$e1995378a142960e$export$fb8073518f34e6ec,e)});function ae({props:i,forwardedRef:e}){let t=o.useContext(y),{CollectionRoot:n}=o.useContext(x.$7135fc7d473fd974$export$4feb769f8ddf26c5),{orientation:a="horizontal",keyboardActivation:d="automatic"}=$.$64fa3d84918910a7$export$fabf2dc03a41866e(F),l=$.$df56164dff5785e2$export$4338b53315abf666(e),{tabListProps:c}=ee({...i,orientation:a,keyboardActivation:d},t,l),r=$.$64fa3d84918910a7$export$4d86445c2cf5e3({...i,children:null,defaultClassName:"react-aria-TabList",values:{orientation:a,state:t}}),s=S.$65484d02dcb7eb3e$export$457c3d6518dd4c6f(i);return delete s.id,o.createElement("div",{...s,...c,ref:l,...r,"data-orientation":a||void 0},o.createElement(n,{collection:t.collection,persistedKeys:x.$7135fc7d473fd974$export$90e00781bc59d8f9(t.selectionManager.focusedKey)}))}const se=x.$e1995378a142960e$export$18af5c7a9e9b3664("item",(i,e,t)=>{let n=o.useContext(y),a=$.$df56164dff5785e2$export$4338b53315abf666(e),{tabProps:d,isSelected:l,isDisabled:c,isPressed:r}=X({key:t.key,...i},n,a),{focusProps:s,isFocused:u,isFocusVisible:f}=T.$f7dceffc5ad7768b$export$4e328f61c538687f(),{hoverProps:b,isHovered:m}=G.$6179b936705e76d3$export$ae780daf29e6d456({isDisabled:c,onHoverStart:i.onHoverStart,onHoverEnd:i.onHoverEnd,onHoverChange:i.onHoverChange}),K=$.$64fa3d84918910a7$export$4d86445c2cf5e3({...i,id:void 0,children:t.rendered,defaultClassName:"react-aria-Tab",values:{isSelected:l,isDisabled:c,isFocused:u,isFocusVisible:f,isPressed:r,isHovered:m}}),p=t.props.href?"a":"div";return o.createElement(p,{...v.$3ef42575df84b30b$export$9d1611c77c2fe928(d,s,b,K),ref:a,"data-selected":l||void 0,"data-disabled":c||void 0,"data-focused":u||void 0,"data-focus-visible":f||void 0,"data-pressed":r||void 0,"data-hovered":m||void 0},K.children)}),re=z.$f39a9eba43920ace$export$86427a43e3e48ebb(function(e,t){const n=o.useContext(y);let a=$.$df56164dff5785e2$export$4338b53315abf666(t),{tabPanelProps:d}=Y(e,n,a),{focusProps:l,isFocused:c,isFocusVisible:r}=T.$f7dceffc5ad7768b$export$4e328f61c538687f(),s=n.selectedKey===e.id,u=$.$64fa3d84918910a7$export$4d86445c2cf5e3({...e,defaultClassName:"react-aria-TabPanel",values:{isFocused:c,isFocusVisible:r,isInert:q.$cdc5a6778b766db2$export$a9d04c5684123369(!s),state:n}});if(!s&&!e.shouldForceMount)return null;let f=S.$65484d02dcb7eb3e$export$457c3d6518dd4c6f(e);delete f.id;let b=s?v.$3ef42575df84b30b$export$9d1611c77c2fe928(f,d,l,u):u;return o.createElement("div",{...b,ref:a,"data-focused":c||void 0,"data-focus-visible":r||void 0,inert:q.$cdc5a6778b766db2$export$a9d04c5684123369(!s),"data-inert":s?void 0:"true"},o.createElement($.$64fa3d84918910a7$export$2881499e37b75b9a,{values:[[F,null],[y,null]]},o.createElement(x.$7135fc7d473fd974$export$4feb769f8ddf26c5.Provider,{value:x.$7135fc7d473fd974$export$a164736487e3f0ae},u.children)))}),le="_container_iuog5_4",oe="_list_iuog5_8",de="_listItem_iuog5_14",ce="_panel_iuog5_56",P={container:le,list:oe,listItem:de,panel:ce},ue=({tabs:i,label:e,children:t,className:n,...a})=>{const{width:d}=V.useObserveElement(typeof document>"u"?null:document.body,{includePadding:!0}),l=a.orientation||d>=A.windowSizes.sm?"horizontal":"vertical";if(!(i!=null&&i.length))return h.jsx(M,{...a,orientation:l,className:g.clsx(P.container,n),children:t});if(typeof t=="function")return console.error('Only the declarative API supports passing a function to children, replace the "tabs" prop according to the documentation: https://designsystem.migrationsverket.se/components/tabs/ '),null;const c=C.Children.toArray(t);if(c.length!==i.length)return console.error(`The number of children must match the number of tabs. Children: ${c.length} Tabs: ${i.length}`),null;const r=c.reduce((s,u,f)=>{if(C.isValidElement(u)){const b=i[f];b&&(s[b]=C.cloneElement(u,{id:b}))}return s},{});return h.jsxs(M,{...a,orientation:l,className:g.clsx(P.container,n),children:[h.jsx(j,{"aria-label":e,children:i.map(s=>h.jsx(R,{id:s,children:s},s))}),i.map(s=>h.jsx(k,{id:s,children:r[s]},s))]})},R=({className:i,...e})=>h.jsx(se,{...e,className:g.clsx(P.listItem,i)}),k=({className:i,...e})=>h.jsx(re,{className:g.clsx(P.panel,i),...e}),j=({className:i,...e})=>h.jsx(ne,{className:g.clsx(P.list,i),...e});exports.Tab=R;exports.TabList=j;exports.TabPanel=k;exports.Tabs=ue;
@@ -0,0 +1,435 @@
1
+ import { jsx as m, jsxs as B } from "react/jsx-runtime";
2
+ import * as E from "react";
3
+ import u, { useMemo as w, useRef as W, useEffect as j, forwardRef as N, createContext as R, useContext as p } from "react";
4
+ import { c as v } from "./clsx-OuTLNxxd.js";
5
+ import { u as U } from "./useObserveElement-BdI4zgd7.js";
6
+ import { w as q } from "./tokens-fEwCQXDv.js";
7
+ import { $ as G, b as J, d as A, f as Q, c as X, g as Y } from "./Collection--62xKPm9.js";
8
+ import { $ as Z, f as C, a as D, e as V, b as ee } from "./utils-DJhAJHk_.js";
9
+ import { $ as te } from "./Hidden-C9KWUR7b.js";
10
+ import { a as g, c as ie } from "./mergeProps-C1U1OIeJ.js";
11
+ import { $ as F } from "./filterDOMProps-D6KHYVBX.js";
12
+ import { $ as L } from "./inertValue-B7loUihk.js";
13
+ import { c as ae } from "./usePress-DuR4pVsE.js";
14
+ import { $ as ne } from "./useFocusable-ChPA2Jc7.js";
15
+ import { d as oe, e as le } from "./SelectionManager-zsWy3vsd.js";
16
+ import { $ as O } from "./useLabels-LrKQiY11.js";
17
+ import { $ as se } from "./useHasTabbableChild-BE81d_ab.js";
18
+ import { $ as re } from "./context-CGNJ3grH.js";
19
+ import { $ as I } from "./useFocusRing-DOfBqnUN.js";
20
+ import { $ as de } from "./useHover-DQvJ3Y-W.js";
21
+ import { $ as ce } from "./useSingleSelectListState-BLXvGjLI.js";
22
+ import './assets/TabList.css';const H = /* @__PURE__ */ new WeakMap();
23
+ function K(i, e, t) {
24
+ return i ? (typeof e == "string" && (e = e.replace(/\s+/g, "")), `${H.get(i)}-${t}-${e}`) : "";
25
+ }
26
+ function fe(i, e, t) {
27
+ let { key: a, isDisabled: n, shouldSelectOnPressUp: r } = i, { selectionManager: s, selectedKey: d } = e, l = a === d, o = n || e.isDisabled || e.selectionManager.isDisabled(a), { itemProps: c, isPressed: f } = oe({
28
+ selectionManager: s,
29
+ key: a,
30
+ ref: t,
31
+ isDisabled: o,
32
+ shouldSelectOnPressUp: r,
33
+ linkBehavior: "selection"
34
+ }), b = K(e, a, "tab"), P = K(e, a, "tabpanel"), { tabIndex: x } = c, $ = e.collection.getItem(a), T = F($ == null ? void 0 : $.props, {
35
+ labelable: !0
36
+ });
37
+ delete T.id;
38
+ let z = ae($ == null ? void 0 : $.props), { focusableProps: _ } = ne({
39
+ isDisabled: o
40
+ }, t);
41
+ return {
42
+ tabProps: g(T, _, z, c, {
43
+ id: b,
44
+ "aria-selected": l,
45
+ "aria-disabled": o || void 0,
46
+ "aria-controls": l ? P : void 0,
47
+ tabIndex: o ? void 0 : x,
48
+ role: "tab"
49
+ }),
50
+ isSelected: l,
51
+ isDisabled: o,
52
+ isPressed: f
53
+ };
54
+ }
55
+ function ue(i, e, t) {
56
+ let a = se(t) ? void 0 : 0;
57
+ var n;
58
+ const r = K(e, (n = i.id) !== null && n !== void 0 ? n : e == null ? void 0 : e.selectedKey, "tabpanel"), s = O({
59
+ ...i,
60
+ id: r,
61
+ "aria-labelledby": K(e, e == null ? void 0 : e.selectedKey, "tab")
62
+ });
63
+ return {
64
+ tabPanelProps: g(s, {
65
+ tabIndex: a,
66
+ role: "tabpanel",
67
+ "aria-describedby": i["aria-describedby"],
68
+ "aria-details": i["aria-details"]
69
+ })
70
+ };
71
+ }
72
+ class be {
73
+ getKeyLeftOf(e) {
74
+ return this.flipDirection ? this.getNextKey(e) : this.getPreviousKey(e);
75
+ }
76
+ getKeyRightOf(e) {
77
+ return this.flipDirection ? this.getPreviousKey(e) : this.getNextKey(e);
78
+ }
79
+ isDisabled(e) {
80
+ var t, a;
81
+ return this.disabledKeys.has(e) || !!(!((a = this.collection.getItem(e)) === null || a === void 0 || (t = a.props) === null || t === void 0) && t.isDisabled);
82
+ }
83
+ getFirstKey() {
84
+ let e = this.collection.getFirstKey();
85
+ return e != null && this.isDisabled(e) && (e = this.getNextKey(e)), e;
86
+ }
87
+ getLastKey() {
88
+ let e = this.collection.getLastKey();
89
+ return e != null && this.isDisabled(e) && (e = this.getPreviousKey(e)), e;
90
+ }
91
+ getKeyAbove(e) {
92
+ return this.tabDirection ? null : this.getPreviousKey(e);
93
+ }
94
+ getKeyBelow(e) {
95
+ return this.tabDirection ? null : this.getNextKey(e);
96
+ }
97
+ getNextKey(e) {
98
+ let t = e;
99
+ do
100
+ t = this.collection.getKeyAfter(t), t == null && (t = this.collection.getFirstKey());
101
+ while (t != null && this.isDisabled(t));
102
+ return t;
103
+ }
104
+ getPreviousKey(e) {
105
+ let t = e;
106
+ do
107
+ t = this.collection.getKeyBefore(t), t == null && (t = this.collection.getLastKey());
108
+ while (t != null && this.isDisabled(t));
109
+ return t;
110
+ }
111
+ constructor(e, t, a, n = /* @__PURE__ */ new Set()) {
112
+ this.collection = e, this.flipDirection = t === "rtl" && a === "horizontal", this.disabledKeys = n, this.tabDirection = a === "horizontal";
113
+ }
114
+ }
115
+ function $e(i, e, t) {
116
+ let { orientation: a = "horizontal", keyboardActivation: n = "automatic" } = i, { collection: r, selectionManager: s, disabledKeys: d } = e, { direction: l } = re(), o = w(() => new be(r, l, a, d), [
117
+ r,
118
+ d,
119
+ a,
120
+ l
121
+ ]), { collectionProps: c } = le({
122
+ ref: t,
123
+ selectionManager: s,
124
+ keyboardDelegate: o,
125
+ selectOnFocus: n === "automatic",
126
+ disallowEmptySelection: !0,
127
+ scrollRef: t,
128
+ linkBehavior: "selection"
129
+ }), f = ie();
130
+ H.set(e, f);
131
+ let b = O({
132
+ ...i,
133
+ id: f
134
+ });
135
+ return {
136
+ tabListProps: {
137
+ ...g(c, b),
138
+ role: "tablist",
139
+ "aria-orientation": a,
140
+ tabIndex: void 0
141
+ }
142
+ };
143
+ }
144
+ function me(i) {
145
+ var e, t;
146
+ let a = ce({
147
+ ...i,
148
+ onSelectionChange: i.onSelectionChange ? (l) => {
149
+ var o;
150
+ l != null && ((o = i.onSelectionChange) === null || o === void 0 || o.call(i, l));
151
+ } : void 0,
152
+ suppressTextValueWarning: !0,
153
+ defaultSelectedKey: (t = (e = i.defaultSelectedKey) !== null && e !== void 0 ? e : M(i.collection, i.disabledKeys ? new Set(i.disabledKeys) : /* @__PURE__ */ new Set())) !== null && t !== void 0 ? t : void 0
154
+ }), { selectionManager: n, collection: r, selectedKey: s } = a, d = W(s);
155
+ return j(() => {
156
+ let l = s;
157
+ i.selectedKey == null && (n.isEmpty || l == null || !r.getItem(l)) && (l = M(r, a.disabledKeys), l != null && n.setSelectedKeys([
158
+ l
159
+ ])), (l != null && n.focusedKey == null || !n.isFocused && l !== d.current) && n.setFocusedKey(l), d.current = l;
160
+ }), {
161
+ ...a,
162
+ isDisabled: i.isDisabled || !1
163
+ };
164
+ }
165
+ function M(i, e) {
166
+ let t = null;
167
+ if (i) {
168
+ var a, n, r, s;
169
+ for (t = i.getFirstKey(); t != null && (e.has(t) || !((n = i.getItem(t)) === null || n === void 0 || (a = n.props) === null || a === void 0) && a.isDisabled) && t !== i.getLastKey(); ) t = i.getKeyAfter(t);
170
+ t != null && (e.has(t) || !((s = i.getItem(t)) === null || s === void 0 || (r = s.props) === null || r === void 0) && r.isDisabled) && t === i.getLastKey() && (t = i.getFirstKey());
171
+ }
172
+ return t;
173
+ }
174
+ const S = /* @__PURE__ */ R(null), h = /* @__PURE__ */ R(null), k = /* @__PURE__ */ N(function(e, t) {
175
+ [e, t] = Z(e, t, S);
176
+ let { children: a, orientation: n = "horizontal" } = e;
177
+ return a = w(() => typeof a == "function" ? a({
178
+ orientation: n,
179
+ defaultChildren: null
180
+ }) : a, [
181
+ a,
182
+ n
183
+ ]), /* @__PURE__ */ u.createElement(J, {
184
+ content: a
185
+ }, (r) => /* @__PURE__ */ u.createElement(he, {
186
+ props: e,
187
+ collection: r,
188
+ tabsRef: t
189
+ }));
190
+ });
191
+ function he({ props: i, tabsRef: e, collection: t }) {
192
+ let { orientation: a = "horizontal" } = i, n = me({
193
+ ...i,
194
+ collection: t,
195
+ children: void 0
196
+ }), { focusProps: r, isFocused: s, isFocusVisible: d } = I({
197
+ within: !0
198
+ }), l = w(() => ({
199
+ orientation: a,
200
+ isFocusWithin: s,
201
+ isFocusVisible: d
202
+ }), [
203
+ a,
204
+ s,
205
+ d
206
+ ]), o = D({
207
+ ...i,
208
+ defaultClassName: "react-aria-Tabs",
209
+ values: l
210
+ });
211
+ return /* @__PURE__ */ u.createElement("div", {
212
+ ...F(i),
213
+ ...r,
214
+ ...o,
215
+ ref: e,
216
+ slot: i.slot || void 0,
217
+ "data-focused": s || void 0,
218
+ "data-orientation": a,
219
+ "data-focus-visible": d || void 0,
220
+ "data-disabled": n.isDisabled || void 0
221
+ }, /* @__PURE__ */ u.createElement(V, {
222
+ values: [
223
+ [
224
+ S,
225
+ i
226
+ ],
227
+ [
228
+ h,
229
+ n
230
+ ]
231
+ ]
232
+ }, o.children));
233
+ }
234
+ const pe = /* @__PURE__ */ N(function(e, t) {
235
+ return p(h) ? /* @__PURE__ */ u.createElement(ve, {
236
+ props: e,
237
+ forwardedRef: t
238
+ }) : /* @__PURE__ */ u.createElement(X, e);
239
+ });
240
+ function ve({ props: i, forwardedRef: e }) {
241
+ let t = p(h), { CollectionRoot: a } = p(A), { orientation: n = "horizontal", keyboardActivation: r = "automatic" } = ee(S), s = C(e), { tabListProps: d } = $e({
242
+ ...i,
243
+ orientation: n,
244
+ keyboardActivation: r
245
+ }, t, s), l = D({
246
+ ...i,
247
+ children: null,
248
+ defaultClassName: "react-aria-TabList",
249
+ values: {
250
+ orientation: n,
251
+ state: t
252
+ }
253
+ }), o = F(i);
254
+ return delete o.id, /* @__PURE__ */ u.createElement("div", {
255
+ ...o,
256
+ ...d,
257
+ ref: s,
258
+ ...l,
259
+ "data-orientation": n || void 0
260
+ }, /* @__PURE__ */ u.createElement(a, {
261
+ collection: t.collection,
262
+ persistedKeys: Y(t.selectionManager.focusedKey)
263
+ }));
264
+ }
265
+ const ye = /* @__PURE__ */ G("item", (i, e, t) => {
266
+ let a = p(h), n = C(e), { tabProps: r, isSelected: s, isDisabled: d, isPressed: l } = fe({
267
+ key: t.key,
268
+ ...i
269
+ }, a, n), { focusProps: o, isFocused: c, isFocusVisible: f } = I(), { hoverProps: b, isHovered: P } = de({
270
+ isDisabled: d,
271
+ onHoverStart: i.onHoverStart,
272
+ onHoverEnd: i.onHoverEnd,
273
+ onHoverChange: i.onHoverChange
274
+ }), x = D({
275
+ ...i,
276
+ id: void 0,
277
+ children: t.rendered,
278
+ defaultClassName: "react-aria-Tab",
279
+ values: {
280
+ isSelected: s,
281
+ isDisabled: d,
282
+ isFocused: c,
283
+ isFocusVisible: f,
284
+ isPressed: l,
285
+ isHovered: P
286
+ }
287
+ }), $ = t.props.href ? "a" : "div";
288
+ return /* @__PURE__ */ u.createElement($, {
289
+ ...g(r, o, b, x),
290
+ ref: n,
291
+ "data-selected": s || void 0,
292
+ "data-disabled": d || void 0,
293
+ "data-focused": c || void 0,
294
+ "data-focus-visible": f || void 0,
295
+ "data-pressed": l || void 0,
296
+ "data-hovered": P || void 0
297
+ }, x.children);
298
+ }), ge = /* @__PURE__ */ te(function(e, t) {
299
+ const a = p(h);
300
+ let n = C(t), { tabPanelProps: r } = ue(e, a, n), { focusProps: s, isFocused: d, isFocusVisible: l } = I(), o = a.selectedKey === e.id, c = D({
301
+ ...e,
302
+ defaultClassName: "react-aria-TabPanel",
303
+ values: {
304
+ isFocused: d,
305
+ isFocusVisible: l,
306
+ // @ts-ignore - compatibility with React < 19
307
+ isInert: L(!o),
308
+ state: a
309
+ }
310
+ });
311
+ if (!o && !e.shouldForceMount) return null;
312
+ let f = F(e);
313
+ delete f.id;
314
+ let b = o ? g(f, r, s, c) : c;
315
+ return /* @__PURE__ */ u.createElement("div", {
316
+ ...b,
317
+ ref: n,
318
+ "data-focused": d || void 0,
319
+ "data-focus-visible": l || void 0,
320
+ // @ts-ignore
321
+ inert: L(!o),
322
+ "data-inert": o ? void 0 : "true"
323
+ }, /* @__PURE__ */ u.createElement(V, {
324
+ values: [
325
+ [
326
+ S,
327
+ null
328
+ ],
329
+ [
330
+ h,
331
+ null
332
+ ]
333
+ ]
334
+ }, /* @__PURE__ */ u.createElement(A.Provider, {
335
+ value: Q
336
+ }, c.children)));
337
+ }), Pe = "_container_iuog5_4", xe = "_list_iuog5_8", Ke = "_listItem_iuog5_14", De = "_panel_iuog5_56", y = {
338
+ container: Pe,
339
+ list: xe,
340
+ listItem: Ke,
341
+ panel: De
342
+ }, Ge = ({
343
+ tabs: i,
344
+ label: e,
345
+ children: t,
346
+ className: a,
347
+ ...n
348
+ }) => {
349
+ const { width: r } = U(
350
+ typeof document > "u" ? null : document.body,
351
+ { includePadding: !0 }
352
+ ), s = n.orientation || r >= q.sm ? "horizontal" : "vertical";
353
+ if (!(i != null && i.length))
354
+ return /* @__PURE__ */ m(
355
+ k,
356
+ {
357
+ ...n,
358
+ orientation: s,
359
+ className: v(y.container, a),
360
+ children: t
361
+ }
362
+ );
363
+ if (typeof t == "function")
364
+ return console.error(
365
+ 'Only the declarative API supports passing a function to children, replace the "tabs" prop according to the documentation: https://designsystem.migrationsverket.se/components/tabs/ '
366
+ ), null;
367
+ const d = E.Children.toArray(t);
368
+ if (d.length !== i.length)
369
+ return console.error(
370
+ `The number of children must match the number of tabs. Children: ${d.length} Tabs: ${i.length}`
371
+ ), null;
372
+ const l = d.reduce(
373
+ (o, c, f) => {
374
+ if (E.isValidElement(c)) {
375
+ const b = i[f];
376
+ b && (o[b] = E.cloneElement(c, { id: b }));
377
+ }
378
+ return o;
379
+ },
380
+ {}
381
+ );
382
+ return /* @__PURE__ */ B(
383
+ k,
384
+ {
385
+ ...n,
386
+ orientation: s,
387
+ className: v(y.container, a),
388
+ children: [
389
+ /* @__PURE__ */ m(Ee, { "aria-label": e, children: i.map((o) => /* @__PURE__ */ m(
390
+ Fe,
391
+ {
392
+ id: o,
393
+ children: o
394
+ },
395
+ o
396
+ )) }),
397
+ i.map((o) => /* @__PURE__ */ m(
398
+ Se,
399
+ {
400
+ id: o,
401
+ children: l[o]
402
+ },
403
+ o
404
+ ))
405
+ ]
406
+ }
407
+ );
408
+ }, Fe = ({ className: i, ...e }) => /* @__PURE__ */ m(
409
+ ye,
410
+ {
411
+ ...e,
412
+ className: v(y.listItem, i)
413
+ }
414
+ ), Se = ({ className: i, ...e }) => /* @__PURE__ */ m(
415
+ ge,
416
+ {
417
+ className: v(y.panel, i),
418
+ ...e
419
+ }
420
+ ), Ee = ({
421
+ className: i,
422
+ ...e
423
+ }) => /* @__PURE__ */ m(
424
+ pe,
425
+ {
426
+ className: v(y.list, i),
427
+ ...e
428
+ }
429
+ );
430
+ export {
431
+ Ge as T,
432
+ Fe as a,
433
+ Se as b,
434
+ Ee as c
435
+ };