@servicetitan/anvil2 1.44.2 → 1.45.1

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 (921) hide show
  1. package/CHANGELOG.md +20 -7
  2. package/README.md +0 -8
  3. package/dist/Alert-BNGvfMAV.js +112 -0
  4. package/dist/Alert-BNGvfMAV.js.map +1 -0
  5. package/dist/{Alert-C3WoRkeN.css → Alert.css} +0 -1
  6. package/dist/Alert.js +1 -1
  7. package/dist/{Announcement-ButSjdLn.js → Announcement-CoheCP1i.js} +23 -28
  8. package/dist/Announcement-CoheCP1i.js.map +1 -0
  9. package/dist/Announcement.css +0 -1
  10. package/dist/Announcement.js +1 -1
  11. package/dist/{HammerProvider-vt3DkcCZ-06BeBrPu.js → AnvilProvider-C_qRQnE6.js} +22 -12
  12. package/dist/AnvilProvider-C_qRQnE6.js.map +1 -0
  13. package/dist/AnvilProvider.js +1 -1
  14. package/dist/{Avatar-DREZJN2K.js → Avatar-CyGjhToG.js} +3 -10
  15. package/dist/Avatar-CyGjhToG.js.map +1 -0
  16. package/dist/{Avatar-C7cbRTCt-DCvzmr2C.js → Avatar-D07f9NH_.js} +9 -9
  17. package/dist/Avatar-D07f9NH_.js.map +1 -0
  18. package/dist/{Avatar-C7cbRTCt.css → Avatar.css} +0 -1
  19. package/dist/Avatar.js +2 -1
  20. package/dist/Avatar.js.map +1 -1
  21. package/dist/{Badge-7aZfE-LH.js → Badge-DCA9mfc2.js} +5 -12
  22. package/dist/Badge-DCA9mfc2.js.map +1 -0
  23. package/dist/Badge.css +0 -1
  24. package/dist/Badge.js +1 -1
  25. package/dist/{Breadcrumbs-BMbkH9hL-BUjQksuj.js → Breadcrumbs-C4_PEolS.js} +7 -7
  26. package/dist/Breadcrumbs-C4_PEolS.js.map +1 -0
  27. package/dist/{Breadcrumbs-BMbkH9hL.css → Breadcrumbs.css} +0 -1
  28. package/dist/Breadcrumbs.js +1 -1
  29. package/dist/{Button-BaHFf1AT-BQy-PFB5.js → Button-BxFXQ0-n.js} +31 -16
  30. package/dist/Button-BxFXQ0-n.js.map +1 -0
  31. package/dist/Button.css +59 -46
  32. package/dist/Button.js +1 -1
  33. package/dist/Button.module-pUNSKoVC.js +25 -0
  34. package/dist/Button.module-pUNSKoVC.js.map +1 -0
  35. package/dist/ButtonCompound-BF2Q6gGX.js +64 -0
  36. package/dist/ButtonCompound-BF2Q6gGX.js.map +1 -0
  37. package/dist/ButtonCompound.js +1 -1
  38. package/dist/{ButtonLink-5qlX0uZx-b9H7MGhk.js → ButtonLink-CXv65WVV.js} +35 -17
  39. package/dist/ButtonLink-CXv65WVV.js.map +1 -0
  40. package/dist/ButtonLink.js +1 -1
  41. package/dist/{ButtonToggle-Bm4KRl3o-B1-LbfjY.js → ButtonToggle-pSwg7NvT.js} +26 -5
  42. package/dist/ButtonToggle-pSwg7NvT.js.map +1 -0
  43. package/dist/ButtonToggle.js +1 -1
  44. package/dist/{Calendar-BvftKznl-D4_xp9Rv.js → Calendar-Dq_of5A3.js} +324 -255
  45. package/dist/Calendar-Dq_of5A3.js.map +1 -0
  46. package/dist/{Calendar-BvftKznl.css → Calendar.css} +0 -1
  47. package/dist/Calendar.js +1 -1
  48. package/dist/{Card-ZknG-yim-7W6rYSFV.js → Card-vTYeSkxt.js} +3 -3
  49. package/dist/Card-vTYeSkxt.js.map +1 -0
  50. package/dist/{Card-ZknG-yim.css → Card.css} +0 -1
  51. package/dist/Card.js +1 -1
  52. package/dist/{Checkbox-zg8LVvB6.js → Checkbox-3y2d9mBd.js} +4 -10
  53. package/dist/Checkbox-3y2d9mBd.js.map +1 -0
  54. package/dist/{Checkbox-DyHm7Ntt-DYw5QL3l.js → Checkbox-BiOzGpgJ.js} +9 -11
  55. package/dist/Checkbox-BiOzGpgJ.js.map +1 -0
  56. package/dist/Checkbox.js +2 -1
  57. package/dist/Checkbox.js.map +1 -1
  58. package/dist/{Chip-MbBEXeAm-DmAcwPRJ.js → Chip-Bz-vlQ4D.js} +37 -10
  59. package/dist/Chip-Bz-vlQ4D.js.map +1 -0
  60. package/dist/{Chip-MbBEXeAm.css → Chip.css} +0 -1
  61. package/dist/Chip.js +1 -1
  62. package/dist/Combobox.js +1 -1
  63. package/dist/{DateField-Bqsnpt8S.js → DateField-B2mnasH5.js} +42 -45
  64. package/dist/DateField-B2mnasH5.js.map +1 -0
  65. package/dist/DateField.js +1 -1
  66. package/dist/DateFieldRange-DPbyzuHb.js +557 -0
  67. package/dist/DateFieldRange-DPbyzuHb.js.map +1 -0
  68. package/dist/DateFieldRange.js +1 -1
  69. package/dist/DateFieldSingle-CfAJDcx9.js +450 -0
  70. package/dist/DateFieldSingle-CfAJDcx9.js.map +1 -0
  71. package/dist/DateFieldSingle.js +1 -1
  72. package/dist/DateFieldYearless-ydxcsmRV.js +266 -0
  73. package/dist/DateFieldYearless-ydxcsmRV.js.map +1 -0
  74. package/dist/DateFieldYearless.js +1 -1
  75. package/dist/{DaysOfTheWeek-ImBPjEvl.js → DaysOfTheWeek-BYvE9QK5.js} +9 -28
  76. package/dist/DaysOfTheWeek-BYvE9QK5.js.map +1 -0
  77. package/dist/DaysOfTheWeek.css +0 -1
  78. package/dist/DaysOfTheWeek.js +1 -1
  79. package/dist/{Details-DVg0EOkv.js → Details-CF8DImjw.js} +34 -100
  80. package/dist/Details-CF8DImjw.js.map +1 -0
  81. package/dist/Details.css +0 -1
  82. package/dist/Details.js +1 -1
  83. package/dist/{Dialog-BR6f-XRH.js → Dialog-DpH2Qvbd.js} +71 -166
  84. package/dist/Dialog-DpH2Qvbd.js.map +1 -0
  85. package/dist/Dialog.css +29 -30
  86. package/dist/Dialog.js +1 -1
  87. package/dist/{Divider-B0xGfyWE-f5-ThMiS.js → Divider-DJe8kLf2.js} +3 -3
  88. package/dist/Divider-DJe8kLf2.js.map +1 -0
  89. package/dist/{Divider-B0xGfyWE.css → Divider.css} +0 -1
  90. package/dist/Divider.js +1 -1
  91. package/dist/Dnd.js +1 -1
  92. package/dist/DndSort.css +0 -1
  93. package/dist/DndSort.js +5545 -1
  94. package/dist/DndSort.js.map +1 -1
  95. package/dist/Drawer-DI_k6W2k.js +377 -0
  96. package/dist/Drawer-DI_k6W2k.js.map +1 -0
  97. package/dist/Drawer.css +161 -0
  98. package/dist/Drawer.js +1 -1
  99. package/dist/{floating-ui.react-BFNinq1w.js → DrawerContext-DboTgTmo.js} +958 -908
  100. package/dist/DrawerContext-DboTgTmo.js.map +1 -0
  101. package/dist/{EditCard-B_n1uFkv.js → EditCard-WKzZ2XCz.js} +12 -19
  102. package/dist/EditCard-WKzZ2XCz.js.map +1 -0
  103. package/dist/EditCard.css +0 -1
  104. package/dist/EditCard.js +1 -1
  105. package/dist/FieldLabel-BfnCXung.js +87 -0
  106. package/dist/FieldLabel-BfnCXung.js.map +1 -0
  107. package/dist/FieldLabel.css +60 -0
  108. package/dist/FieldLabel.js +1 -1
  109. package/dist/{FieldMessage-Bobp105T-DYhStLY4.js → FieldMessage-B7uQ8vmr.js} +3 -3
  110. package/dist/FieldMessage-B7uQ8vmr.js.map +1 -0
  111. package/dist/{FieldMessage-Bobp105T.css → FieldMessage.css} +0 -2
  112. package/dist/FieldMessage.js +1 -1
  113. package/dist/{Flex-CiK7uNUu-BfxHG4L0.js → Flex-BdQMekvA.js} +3 -3
  114. package/dist/Flex-BdQMekvA.js.map +1 -0
  115. package/dist/{Flex-CiK7uNUu.css → Flex.css} +0 -1
  116. package/dist/Flex.js +1 -1
  117. package/dist/{Grid-DFAd8mTe.js → Grid-MGUC698u.js} +48 -30
  118. package/dist/Grid-MGUC698u.js.map +1 -0
  119. package/dist/Grid.css +0 -1
  120. package/dist/Grid.js +1 -1
  121. package/dist/{Helper-h7k80qls-DHPFHTvI.js → Helper-BkIDJqgA.js} +4 -4
  122. package/dist/Helper-BkIDJqgA.js.map +1 -0
  123. package/dist/{Helper-h7k80qls.css → Helper.css} +0 -1
  124. package/dist/{Icon-B6HmlQiR-BxQkO3X5.js → Icon-D8SPKeO4.js} +3 -3
  125. package/dist/Icon-D8SPKeO4.js.map +1 -0
  126. package/dist/{Icon-B6HmlQiR.css → Icon.css} +0 -1
  127. package/dist/Icon.js +1 -1
  128. package/dist/{InputMask-BuO8lNAB-DdxdO5Jw.js → InputMask-O_qi1p_3.js} +88 -67
  129. package/dist/InputMask-O_qi1p_3.js.map +1 -0
  130. package/dist/InputMask.js +1 -1
  131. package/dist/Link-eRsLWPaQ.js +103 -0
  132. package/dist/Link-eRsLWPaQ.js.map +1 -0
  133. package/dist/{Link-MiffPrW9.css → Link.css} +0 -1
  134. package/dist/Link.js +1 -1
  135. package/dist/Link.module-Cf17JWod.js +12 -0
  136. package/dist/Link.module-Cf17JWod.js.map +1 -0
  137. package/dist/LinkButton-2lXfrVoU.js +64 -0
  138. package/dist/LinkButton-2lXfrVoU.js.map +1 -0
  139. package/dist/LinkButton.js +1 -75
  140. package/dist/LinkButton.js.map +1 -1
  141. package/dist/{ListView-DVPhWDCM.js → ListView-jR2ZkBB7.js} +151 -234
  142. package/dist/ListView-jR2ZkBB7.js.map +1 -0
  143. package/dist/ListView.css +0 -1
  144. package/dist/ListView.js +1 -1
  145. package/dist/{ListView.module-MVsNF0X0-MVsNF0X0.js → ListView.module-MVsNF0X0.js} +1 -1
  146. package/dist/ListView.module-MVsNF0X0.js.map +1 -0
  147. package/dist/{Listbox-B-WUuj-_-BWWeWtLW.js → Listbox-CUhMbFm2.js} +67 -50
  148. package/dist/Listbox-CUhMbFm2.js.map +1 -0
  149. package/dist/Listbox.css +0 -1
  150. package/dist/Listbox.js +1 -1
  151. package/dist/{Listbox.module-DcBE8Zmo-DcBE8Zmo.js → Listbox.module-DcBE8Zmo.js} +1 -1
  152. package/dist/Listbox.module-DcBE8Zmo.js.map +1 -0
  153. package/dist/{LocalizationContext-UsmB5mnR-BUIYgNp2.js → LocalizationContext-UsmB5mnR.js} +2 -2
  154. package/dist/LocalizationContext-UsmB5mnR.js.map +1 -0
  155. package/dist/{LocalizationProvider-VtRAfGBT-Bo8XuFoE.js → LocalizationProvider-DEZyjW5d.js} +3 -3
  156. package/dist/LocalizationProvider-DEZyjW5d.js.map +1 -0
  157. package/dist/LocalizationProvider.d.ts +0 -4
  158. package/dist/LocalizationProvider.js +2 -2
  159. package/dist/{Menu-TtVJnSrA-yBYichuJ.js → Menu-C8we5CHP.js} +52 -22
  160. package/dist/Menu-C8we5CHP.js.map +1 -0
  161. package/dist/{Menu-TtVJnSrA.css → Menu.css} +0 -2
  162. package/dist/Menu.js +1 -1
  163. package/dist/{NumberField-C9lMsPMD.js → NumberField-1_gRsWT4.js} +158 -175
  164. package/dist/NumberField-1_gRsWT4.js.map +1 -0
  165. package/dist/NumberField.css +7 -8
  166. package/dist/NumberField.js +1 -1
  167. package/dist/{Overflow-CFClqFVC.css → Overflow.css} +0 -2
  168. package/dist/Overflow.js +400 -1
  169. package/dist/Overflow.js.map +1 -1
  170. package/dist/{Page-CGAylFKz.js → Page-CY6QRlvb.js} +14 -14
  171. package/dist/Page-CY6QRlvb.js.map +1 -0
  172. package/dist/Page.js +1 -1
  173. package/dist/{Pagination-DU_qvFRR.js → Pagination-ta8a2cJN.js} +29 -30
  174. package/dist/Pagination-ta8a2cJN.js.map +1 -0
  175. package/dist/Pagination.css +28 -28
  176. package/dist/Pagination.js +1 -1
  177. package/dist/{Popover-CU2cGVD8-Casl3vM1.js → Popover-r26xMIfm.js} +260 -229
  178. package/dist/Popover-r26xMIfm.js.map +1 -0
  179. package/dist/{Popover-CU2cGVD8.css → Popover.css} +0 -2
  180. package/dist/Popover.js +1 -1
  181. package/dist/{PortalProvider-9lXkQ0xY-BKoGegS1.js → PortalProvider-9lXkQ0xY.js} +2 -2
  182. package/dist/PortalProvider-9lXkQ0xY.js.map +1 -0
  183. package/dist/PortalProvider.d.ts +0 -4
  184. package/dist/PortalProvider.js +1 -1
  185. package/dist/ProgressBar-BnXuQ6Bx.js +130 -0
  186. package/dist/ProgressBar-BnXuQ6Bx.js.map +1 -0
  187. package/dist/ProgressBar.css +89 -0
  188. package/dist/ProgressBar.js +1 -1
  189. package/dist/{Radio-DnOuBPi_.js → Radio-CwmRUIzo.js} +4 -10
  190. package/dist/Radio-CwmRUIzo.js.map +1 -0
  191. package/dist/Radio.js +2 -1
  192. package/dist/Radio.js.map +1 -1
  193. package/dist/{Radio-DQ_VQFGZ-SdFBlDnE.js → RadioGroup-BNCWIHOG.js} +84 -105
  194. package/dist/RadioGroup-BNCWIHOG.js.map +1 -0
  195. package/dist/{Radio-DQ_VQFGZ.css → RadioGroup.css} +0 -1
  196. package/dist/{SearchField-BGPqpnVd.js → SearchField-BKXkoWPs.js} +21 -27
  197. package/dist/SearchField-BKXkoWPs.js.map +1 -0
  198. package/dist/SearchField.css +0 -1
  199. package/dist/SearchField.js +1 -1
  200. package/dist/{SegmentedControl-DY1PSYmd.js → SegmentedControl-CsjjV1Dz.js} +32 -80
  201. package/dist/SegmentedControl-CsjjV1Dz.js.map +1 -0
  202. package/dist/SegmentedControl.css +0 -1
  203. package/dist/SegmentedControl.js +1 -1
  204. package/dist/{SelectCard-LSAl_7Lh-BYtfe9PC.js → SelectCard-DOGCG0zr.js} +17 -17
  205. package/dist/SelectCard-DOGCG0zr.js.map +1 -0
  206. package/dist/{SelectCard-LSAl_7Lh.css → SelectCard.css} +0 -1
  207. package/dist/SelectCard.js +1 -1
  208. package/dist/{SelectTrigger-C2w-flvK.js → SelectTrigger-BMo0e-F7.js} +31 -44
  209. package/dist/SelectTrigger-BMo0e-F7.js.map +1 -0
  210. package/dist/SelectTrigger.js +1 -1
  211. package/dist/{SelectTriggerBase-Dj154EN4-BtTvR-Nh.js → SelectTriggerBase-BMMxnXrw.js} +54 -40
  212. package/dist/SelectTriggerBase-BMMxnXrw.js.map +1 -0
  213. package/dist/{SelectTriggerBase-Dj154EN4.css → SelectTriggerBase.css} +68 -54
  214. package/dist/{SideNav-Bh_pVeEw.js → SideNav-CBAzYyML.js} +71 -154
  215. package/dist/SideNav-CBAzYyML.js.map +1 -0
  216. package/dist/SideNav.css +0 -1
  217. package/dist/SideNav.js +1 -1
  218. package/dist/Skeleton.css +0 -1
  219. package/dist/Skeleton.d.ts +0 -4
  220. package/dist/Skeleton.js +190 -1
  221. package/dist/Skeleton.js.map +1 -1
  222. package/dist/{Spinner-DliJVzdW-BQlZEj4V.js → Spinner-wmO8Epw0.js} +2 -2
  223. package/dist/Spinner-wmO8Epw0.js.map +1 -0
  224. package/dist/{Spinner-DliJVzdW.css → Spinner.css} +0 -1
  225. package/dist/Spinner.js +1 -1
  226. package/dist/{SrOnly-BsKDHetF-B93X65F1.js → SrOnly-CTsYSuby.js} +2 -2
  227. package/dist/SrOnly-CTsYSuby.js.map +1 -0
  228. package/dist/{SrOnly-BsKDHetF.css → SrOnly.css} +0 -1
  229. package/dist/SrOnly.js +1 -1
  230. package/dist/{Stepper-BtbDBIzz.js → Stepper-D-fOH9TF.js} +142 -326
  231. package/dist/Stepper-D-fOH9TF.js.map +1 -0
  232. package/dist/Stepper.css +43 -44
  233. package/dist/Stepper.js +1 -1
  234. package/dist/{Switch-DAQFzi-X.js → Switch-C2ddZcr9.js} +22 -28
  235. package/dist/Switch-C2ddZcr9.js.map +1 -0
  236. package/dist/Switch.css +0 -1
  237. package/dist/Switch.js +1 -1
  238. package/dist/{Tab-BSC7e4rM.js → Tab-wNucMTgo.js} +42 -120
  239. package/dist/Tab-wNucMTgo.js.map +1 -0
  240. package/dist/Tab.css +0 -1
  241. package/dist/Tab.js +1 -1
  242. package/dist/{Text-CED_yrId-DsRYZw2-.js → Text-BqvcbXyp.js} +3 -3
  243. package/dist/Text-BqvcbXyp.js.map +1 -0
  244. package/dist/{Text-CED_yrId.css → Text.css} +0 -1
  245. package/dist/Text.js +1 -1
  246. package/dist/TextField-CwgE_JJU.js +13 -0
  247. package/dist/TextField-CwgE_JJU.js.map +1 -0
  248. package/dist/{TextField-DoPP1CQ--UWAOTYiv.js → TextField-DlsZEkS0.js} +29 -12
  249. package/dist/TextField-DlsZEkS0.js.map +1 -0
  250. package/dist/TextField.css +0 -1
  251. package/dist/TextField.js +1 -1
  252. package/dist/{TextField.module-EkKlj66e-EkKlj66e.js → TextField.module-EkKlj66e.js} +1 -1
  253. package/dist/TextField.module-EkKlj66e.js.map +1 -0
  254. package/dist/{Textarea-D2AAZ1L3.js → Textarea-DU-SpoDL.js} +38 -44
  255. package/dist/Textarea-DU-SpoDL.js.map +1 -0
  256. package/dist/Textarea.css +0 -1
  257. package/dist/Textarea.js +1 -1
  258. package/dist/{ThemeProvider-Q3ji6Rpx-DBXlAuQ8.js → ThemeProvider-Be3Pvtpz.js} +6 -8
  259. package/dist/ThemeProvider-Be3Pvtpz.js.map +1 -0
  260. package/dist/{ThemeProvider-Q3ji6Rpx.css → ThemeProvider.css} +0 -1
  261. package/dist/ThemeProvider.d.ts +0 -4
  262. package/dist/ThemeProvider.js +2 -1
  263. package/dist/ThemeProvider.js.map +1 -1
  264. package/dist/ThemeProviderContext-l52GohYT.js +8 -0
  265. package/dist/ThemeProviderContext-l52GohYT.js.map +1 -0
  266. package/dist/{TimeField-tA9uo4lK.js → TimeField-CfhyRfX9.js} +229 -215
  267. package/dist/TimeField-CfhyRfX9.js.map +1 -0
  268. package/dist/TimeField.css +0 -1
  269. package/dist/TimeField.d.ts +4 -0
  270. package/dist/TimeField.js +1 -1
  271. package/dist/Toast.js +2 -1
  272. package/dist/Toast.js.map +1 -1
  273. package/dist/Toaster-BgjT0p8b.js +1124 -0
  274. package/dist/Toaster-BgjT0p8b.js.map +1 -0
  275. package/dist/{toast-BhV_Ask2.js → Toaster-CfC9wod0.js} +5 -7
  276. package/dist/Toaster-CfC9wod0.js.map +1 -0
  277. package/dist/Toaster.css +235 -0
  278. package/dist/{Toolbar-CSWhVSUM.js → Toolbar-DK7tXy_W.js} +163 -279
  279. package/dist/Toolbar-DK7tXy_W.js.map +1 -0
  280. package/dist/Toolbar.css +28 -19
  281. package/dist/Toolbar.js +1 -1
  282. package/dist/Tooltip-BI3Xs75X.js +730 -0
  283. package/dist/Tooltip-BI3Xs75X.js.map +1 -0
  284. package/dist/Tooltip.css +99 -0
  285. package/dist/Tooltip.js +1 -1
  286. package/dist/assets/icons/st/atlas_gradient.svg +1 -0
  287. package/dist/assets/icons/st/atlas_logo.svg +1 -0
  288. package/dist/assets/icons/st/atlas_simple.svg +1 -0
  289. package/dist/assets/icons/st.ts +3 -0
  290. package/dist/{check_circle-BGfigqq-.js → check_circle-Dja-C2lM.js} +2 -4
  291. package/dist/check_circle-Dja-C2lM.js.map +1 -0
  292. package/dist/{childrenToString-Bz9MqbHb-Bz9MqbHb.js → childrenToString-Bz9MqbHb.js} +1 -1
  293. package/dist/childrenToString-Bz9MqbHb.js.map +1 -0
  294. package/dist/components/Alert/Alert.d.ts +26 -8
  295. package/dist/components/Announcement/Announcement.d.ts +26 -8
  296. package/dist/components/Avatar/Avatar.d.ts +2 -48
  297. package/dist/components/Avatar/AvatarGroup.d.ts +39 -0
  298. package/dist/components/Avatar/index.d.ts +1 -0
  299. package/dist/components/Avatar/internal/Avatar.d.ts +58 -0
  300. package/dist/components/Avatar/internal/AvatarBase.d.ts +75 -0
  301. package/dist/components/Badge/Badge.d.ts +31 -8
  302. package/dist/components/Breadcrumbs/Breadcrumbs.d.ts +23 -14
  303. package/dist/components/Breadcrumbs/BreadcrumbsLink.d.ts +23 -0
  304. package/dist/components/Breadcrumbs/index.d.ts +1 -0
  305. package/dist/components/Button/Button.d.ts +43 -9
  306. package/dist/components/ButtonCompound/ButtonCompound.d.ts +20 -7
  307. package/dist/components/ButtonLink/ButtonLink.d.ts +66 -15
  308. package/dist/components/ButtonToggle/ButtonToggle.d.ts +46 -11
  309. package/dist/components/Calendar/Calendar.d.ts +149 -36
  310. package/dist/components/Calendar/CalendarContext.d.ts +153 -0
  311. package/dist/components/Calendar/CalendarMonth.d.ts +9 -0
  312. package/dist/components/Calendar/CalendarMonthButton.d.ts +16 -0
  313. package/dist/components/Calendar/CalendarNextButton.d.ts +11 -0
  314. package/dist/components/Calendar/CalendarNowButton.d.ts +20 -0
  315. package/dist/components/Calendar/CalendarPrevButton.d.ts +11 -0
  316. package/dist/components/Calendar/CalendarYearButton.d.ts +15 -0
  317. package/dist/components/Calendar/index.d.ts +9 -2
  318. package/dist/components/Calendar/internal/CalendarDay.d.ts +21 -0
  319. package/dist/components/Calendar/internal/CalendarMonthSelection.d.ts +25 -0
  320. package/dist/components/Calendar/internal/CalendarWeek.d.ts +28 -0
  321. package/dist/components/Calendar/internal/CalendarYearSelection.d.ts +25 -0
  322. package/dist/components/Calendar/internal/utils.d.ts +12 -0
  323. package/dist/components/Card/Card.d.ts +26 -16
  324. package/dist/components/Checkbox/Checkbox.d.ts +3 -29
  325. package/dist/components/Checkbox/CheckboxGroup.d.ts +53 -0
  326. package/dist/components/Checkbox/index.d.ts +2 -0
  327. package/dist/components/Checkbox/internal/Checkbox.d.ts +133 -0
  328. package/dist/components/Checkbox/types.d.ts +4 -0
  329. package/dist/components/Chip/Chip.d.ts +4 -3
  330. package/dist/components/Chip/internal/Chip.d.ts +108 -0
  331. package/dist/components/Combobox/Combobox.d.ts +11 -283
  332. package/dist/components/Combobox/ComboboxContent.d.ts +59 -0
  333. package/dist/components/Combobox/ComboboxEmpty.d.ts +26 -0
  334. package/dist/components/Combobox/ComboboxItem.d.ts +34 -0
  335. package/dist/components/Combobox/ComboboxList.d.ts +31 -0
  336. package/dist/components/Combobox/ComboboxMockData.d.ts +44 -0
  337. package/dist/components/Combobox/ComboboxSelect.d.ts +59 -0
  338. package/dist/components/Combobox/ComboboxTrigger.d.ts +43 -0
  339. package/dist/components/Combobox/ComboboxTypes.d.ts +374 -0
  340. package/dist/components/Combobox/index.d.ts +10 -3
  341. package/dist/components/Combobox/internal/ComboboxContext.d.ts +8 -0
  342. package/dist/components/Combobox/internal/ComboboxGroupContext.d.ts +8 -0
  343. package/dist/components/Combobox/internal/ComboboxLegacy/ComboboxLegacy.d.ts +131 -0
  344. package/dist/components/Combobox/internal/ComboboxLegacy/ComboboxLegacyContent.d.ts +20 -0
  345. package/dist/components/Combobox/internal/ComboboxLegacy/ComboboxLegacyEmpty.d.ts +5 -0
  346. package/dist/components/Combobox/internal/ComboboxLegacy/ComboboxLegacyItem.d.ts +26 -0
  347. package/dist/components/Combobox/internal/ComboboxLegacy/ComboboxLegacyList.d.ts +5 -0
  348. package/dist/components/Combobox/internal/ComboboxLegacy/ComboboxLegacyMockData.d.ts +37 -0
  349. package/dist/components/Combobox/internal/ComboboxLegacy/ComboboxLegacyTrigger.d.ts +21 -0
  350. package/dist/components/Combobox/internal/ComboboxLegacy/ComboboxLegacyUtils.d.ts +38 -0
  351. package/dist/components/Combobox/internal/ComboboxLegacy/index.d.ts +7 -0
  352. package/dist/components/Combobox/internal/ComboboxMockData.d.ts +44 -0
  353. package/dist/components/Combobox/internal/ComboboxUtils.d.ts +74 -0
  354. package/dist/components/Combobox/internal/useGroups.d.ts +14 -0
  355. package/dist/components/Combobox/useInfiniteCombobox.d.ts +69 -1
  356. package/dist/components/DateField/DateField.d.ts +23 -61
  357. package/dist/components/DateField/internal/DateFieldLegacy/DateFieldLegacy.d.ts +37 -0
  358. package/dist/components/DateField/internal/DateFieldLegacy/index.d.ts +1 -0
  359. package/dist/components/DateField/internal/isoToDateFormat.d.ts +1 -0
  360. package/dist/components/DateField/types.d.ts +47 -0
  361. package/dist/components/DateFieldRange/DateFieldRange.d.ts +57 -6
  362. package/dist/components/DateFieldRange/internal/DateFieldRangeCalendar.d.ts +17 -0
  363. package/dist/components/DateFieldRange/internal/MaskedDateRangeInput.d.ts +41 -0
  364. package/dist/components/DateFieldRange/internal/maskito/dateRangePlaceholderMask.d.ts +18 -0
  365. package/dist/components/DateFieldRange/internal/useDateFieldRangeConversion.d.ts +29 -0
  366. package/dist/components/DateFieldRange/internal/useDateFieldRangeState.d.ts +70 -0
  367. package/dist/components/DateFieldRange/internal/utils.d.ts +17 -0
  368. package/dist/components/DateFieldSingle/DateFieldSingle.d.ts +55 -5
  369. package/dist/components/DateFieldSingle/index.d.ts +1 -0
  370. package/dist/components/DateFieldSingle/internal/DateFieldSingleCalendar.d.ts +15 -0
  371. package/dist/components/DateFieldSingle/internal/MaskedDateInput.d.ts +35 -0
  372. package/dist/components/DateFieldSingle/internal/constants.d.ts +3 -0
  373. package/dist/components/DateFieldSingle/internal/maskito/datePlaceholderMask.d.ts +16 -0
  374. package/dist/components/DateFieldSingle/internal/maskito/makeZeroShortcutPreprocessor.d.ts +10 -0
  375. package/dist/components/DateFieldSingle/internal/useDateFieldOrchestration.d.ts +17 -0
  376. package/dist/components/DateFieldSingle/internal/useDateFieldSingleConversion.d.ts +45 -0
  377. package/dist/components/DateFieldSingle/internal/useDateFieldSingleState.d.ts +49 -0
  378. package/dist/components/DateFieldSingle/internal/utils.d.ts +14 -0
  379. package/dist/components/DateFieldSingle/types.d.ts +2 -0
  380. package/dist/components/DateFieldYearless/DateFieldYearless.d.ts +61 -36
  381. package/dist/components/DateFieldYearless/index.d.ts +1 -0
  382. package/dist/components/DateFieldYearless/internal/MaskedYearlessDateInput.d.ts +35 -0
  383. package/dist/components/DateFieldYearless/internal/maskito/yearlessDatePlaceholderMask.d.ts +16 -0
  384. package/dist/components/DateFieldYearless/internal/utils.d.ts +12 -0
  385. package/dist/components/DateFieldYearless/types.d.ts +7 -0
  386. package/dist/components/DaysOfTheWeek/DaysOfTheWeek.d.ts +117 -20
  387. package/dist/components/Details/Details.d.ts +30 -58
  388. package/dist/components/Details/DetailsContent.d.ts +41 -0
  389. package/dist/components/Details/DetailsSummary.d.ts +24 -0
  390. package/dist/components/Details/index.d.ts +2 -0
  391. package/dist/components/Details/internal/DetailsArrow.d.ts +20 -0
  392. package/dist/components/Details/internal/DetailsContext.d.ts +8 -0
  393. package/dist/components/Dialog/Dialog.d.ts +97 -109
  394. package/dist/components/Dialog/DialogCancelButton.d.ts +21 -0
  395. package/dist/components/Dialog/DialogContent.d.ts +22 -0
  396. package/dist/components/Dialog/DialogFooter.d.ts +33 -0
  397. package/dist/components/Dialog/DialogHeader.d.ts +21 -0
  398. package/dist/components/Dialog/index.d.ts +6 -2
  399. package/dist/components/Dialog/internal/DialogContext.d.ts +8 -0
  400. package/dist/components/Dialog/internal/useDialogContext.d.ts +1 -0
  401. package/dist/components/Divider/Divider.d.ts +34 -7
  402. package/dist/components/Dnd/DndHandle.d.ts +26 -0
  403. package/dist/components/Dnd/DndHandleButton.d.ts +32 -0
  404. package/dist/components/Dnd/DndSortLine.d.ts +39 -0
  405. package/dist/components/Dnd/DndZone.d.ts +55 -0
  406. package/dist/components/Dnd/index.d.ts +7 -1
  407. package/dist/components/DndSort/DndSort.d.ts +40 -0
  408. package/dist/components/DndSort/DndSortCard.d.ts +63 -0
  409. package/dist/components/DndSort/DndSortZone.d.ts +130 -0
  410. package/dist/components/DndSort/index.d.ts +12 -2
  411. package/dist/components/DndSort/internal/DndSortContext.d.ts +21 -0
  412. package/dist/components/DndSort/internal/DndSortItem.d.ts +30 -0
  413. package/dist/components/DndSort/internal/DndSortOverlay.d.ts +5 -0
  414. package/dist/components/DndSort/internal/DndSortZoneContext.d.ts +24 -0
  415. package/dist/components/DndSort/internal/announcements.d.ts +8 -0
  416. package/dist/components/DndSort/internal/collisionDetection.d.ts +3 -0
  417. package/dist/components/DndSort/internal/getNextCoordinates.d.ts +17 -0
  418. package/dist/components/DndSort/internal/test-utils.d.ts +24 -0
  419. package/dist/components/DndSort/internal/utils.d.ts +55 -0
  420. package/dist/components/DndSort/types.d.ts +55 -0
  421. package/dist/components/Drawer/Drawer.d.ts +63 -118
  422. package/dist/components/Drawer/DrawerCancelButton.d.ts +25 -0
  423. package/dist/components/Drawer/DrawerContent.d.ts +26 -0
  424. package/dist/components/Drawer/DrawerFooter.d.ts +37 -0
  425. package/dist/components/Drawer/DrawerHeader.d.ts +23 -0
  426. package/dist/components/Drawer/index.d.ts +6 -2
  427. package/dist/components/Drawer/internal/DrawerContext.d.ts +15 -0
  428. package/dist/components/Drawer/internal/useDrawerContext.d.ts +7 -0
  429. package/dist/components/EditCard/EditCard.d.ts +71 -14
  430. package/dist/components/FieldLabel/FieldLabel.d.ts +62 -4
  431. package/dist/components/FieldLabel/internal/FieldLabelMoreInfoIcon.d.ts +12 -0
  432. package/dist/components/FieldMessage/FieldMessage.d.ts +48 -12
  433. package/dist/components/Flex/Flex.d.ts +46 -61
  434. package/dist/components/Flex/internal/FlexSpecificProps.d.ts +34 -0
  435. package/dist/components/Grid/Grid.d.ts +55 -27
  436. package/dist/components/Grid/index.d.ts +1 -0
  437. package/dist/components/Grid/internal/GridItem.d.ts +27 -0
  438. package/dist/components/Grid/internal/GridSpecificProps.d.ts +28 -0
  439. package/dist/components/Icon/Icon.d.ts +42 -15
  440. package/dist/components/InputMask/InputMask.d.ts +109 -48
  441. package/dist/components/InputMask/internal/constants.d.ts +1 -0
  442. package/dist/components/InputMask/internal/utils.d.ts +41 -0
  443. package/dist/components/Link/Link.d.ts +5 -17
  444. package/dist/components/Link/index.d.ts +1 -0
  445. package/dist/components/Link/internal/Link.d.ts +57 -0
  446. package/dist/components/Link/internal/LinkHeadless.d.ts +24 -0
  447. package/dist/components/Link/useLinkStyles.d.ts +17 -0
  448. package/dist/components/LinkButton/LinkButton.d.ts +5 -31
  449. package/dist/components/ListView/ListView.d.ts +17 -46
  450. package/dist/components/ListView/ListViewOption.d.ts +38 -0
  451. package/dist/components/ListView/ListViewOptionCell.d.ts +12 -0
  452. package/dist/components/ListView/index.d.ts +3 -1
  453. package/dist/components/ListView/internal/ListViewContext.d.ts +28 -0
  454. package/dist/components/ListView/internal/types.d.ts +52 -0
  455. package/dist/components/ListView/internal/utils.d.ts +4 -0
  456. package/dist/components/Listbox/Listbox.d.ts +97 -61
  457. package/dist/components/Listbox/ListboxOption.d.ts +53 -0
  458. package/dist/components/Listbox/ListboxOptionGroup.d.ts +32 -0
  459. package/dist/components/Listbox/index.d.ts +3 -1
  460. package/dist/components/Listbox/internal/ListboxContext.d.ts +38 -0
  461. package/dist/components/Listbox/internal/ListboxOptionGroupContext.d.ts +5 -0
  462. package/dist/components/Listbox/internal/utils.d.ts +4 -0
  463. package/dist/components/Menu/Menu.d.ts +20 -46
  464. package/dist/components/Menu/MenuItem.d.ts +57 -0
  465. package/dist/components/Menu/index.d.ts +2 -0
  466. package/dist/components/Menu/internal/MenuContext.d.ts +15 -0
  467. package/dist/components/Menu/internal/MenuLegacy/MenuLegacy.d.ts +50 -0
  468. package/dist/components/Menu/internal/MenuLegacy/MenuLegacyContext.d.ts +9 -0
  469. package/dist/components/Menu/internal/MenuLegacy/MenuLegacyItem.d.ts +12 -0
  470. package/dist/components/Menu/internal/MenuLegacy/index.d.ts +3 -0
  471. package/dist/components/Menu/internal/MenuNested.d.ts +42 -0
  472. package/dist/components/Menu/types.d.ts +72 -0
  473. package/dist/components/NumberField/NumberField.d.ts +48 -7
  474. package/dist/components/Overflow/Overflow.d.ts +51 -84
  475. package/dist/components/Overflow/OverflowText.d.ts +82 -0
  476. package/dist/components/Overflow/index.d.ts +31 -2
  477. package/dist/components/Page/Page.d.ts +7 -7
  478. package/dist/components/Page/PageFooter.d.ts +1 -1
  479. package/dist/components/Page/PageHeader.d.ts +1 -1
  480. package/dist/components/Pagination/Pagination.d.ts +4 -6
  481. package/dist/components/Pagination/internal/Pagination.d.ts +55 -0
  482. package/dist/components/Pagination/internal/PaginationItem.d.ts +52 -0
  483. package/dist/components/Pagination/internal/PaginationItemsPerPageMenu.d.ts +37 -0
  484. package/dist/components/Pagination/internal/PaginationList.d.ts +9 -0
  485. package/dist/components/Pagination/internal/PaginationOverflowMenu.d.ts +61 -0
  486. package/dist/components/Pagination/internal/PaginationTotalCount.d.ts +6 -0
  487. package/dist/components/Popover/Popover.d.ts +146 -134
  488. package/dist/components/Popover/PopoverButton.d.ts +34 -0
  489. package/dist/components/Popover/PopoverClose.d.ts +33 -0
  490. package/dist/components/Popover/PopoverContent.d.ts +46 -0
  491. package/dist/components/Popover/PopoverTrigger.d.ts +63 -0
  492. package/dist/components/Popover/index.d.ts +4 -0
  493. package/dist/components/Popover/internal/PopoverContext.d.ts +40 -0
  494. package/dist/components/Popover/internal/PopoverLegacy/PopoverLegacy.d.ts +8 -0
  495. package/dist/components/Popover/internal/PopoverLegacy/PopoverLegacyButton.d.ts +3 -0
  496. package/dist/components/Popover/internal/PopoverLegacy/PopoverLegacyClose.d.ts +3 -0
  497. package/dist/components/Popover/internal/PopoverLegacy/PopoverLegacyContent.d.ts +3 -0
  498. package/dist/components/Popover/internal/PopoverLegacy/PopoverLegacyTrigger.d.ts +9 -0
  499. package/dist/components/Popover/internal/PopoverLegacy/index.d.ts +8 -0
  500. package/dist/components/Popover/internal/PopoverLegacy/usePopoverLegacy.d.ts +121 -0
  501. package/dist/components/Popover/internal/PopoverLegacy/usePopoverLegacyContext.d.ts +79 -0
  502. package/dist/components/Popover/internal/compareElements.d.ts +1 -0
  503. package/dist/components/Popover/internal/usePopoverContext.d.ts +50 -0
  504. package/dist/components/ProgressBar/ProgressBar.d.ts +59 -14
  505. package/dist/components/Radio/Radio.d.ts +3 -44
  506. package/dist/components/Radio/RadioGroup.d.ts +61 -0
  507. package/dist/components/Radio/index.d.ts +2 -0
  508. package/dist/components/Radio/internal/Radio.d.ts +145 -0
  509. package/dist/components/Radio/types.d.ts +13 -0
  510. package/dist/components/SearchField/SearchField.d.ts +33 -8
  511. package/dist/components/SegmentedControl/SegmentedControl.d.ts +54 -49
  512. package/dist/components/SegmentedControl/SegmentedControlSegment.d.ts +69 -0
  513. package/dist/components/SegmentedControl/index.d.ts +1 -0
  514. package/dist/components/SegmentedControl/internal/SegmentedControlContext.d.ts +24 -0
  515. package/dist/components/SelectCard/SelectCard.d.ts +45 -16
  516. package/dist/components/SelectCard/SelectCardGroup.d.ts +24 -13
  517. package/dist/components/SelectCard/index.d.ts +1 -2
  518. package/dist/components/SelectCard/internal/SelectCardProvider.d.ts +83 -0
  519. package/dist/components/SelectTrigger/SelectTrigger.d.ts +22 -8
  520. package/dist/components/SelectTrigger/internal/SelectTriggerBase.d.ts +40 -0
  521. package/dist/components/SideNav/SideNav.d.ts +32 -114
  522. package/dist/components/SideNav/SideNavCollapsible.d.ts +73 -0
  523. package/dist/components/SideNav/SideNavGroup.d.ts +37 -0
  524. package/dist/components/SideNav/SideNavLink.d.ts +46 -0
  525. package/dist/components/SideNav/index.d.ts +4 -1
  526. package/dist/components/SideNav/internal/SideNavLink.d.ts +74 -0
  527. package/dist/components/SideNav/internal/utils.d.ts +16 -0
  528. package/dist/components/Skeleton/SkeletonCircle.d.ts +41 -0
  529. package/dist/components/Skeleton/SkeletonPill.d.ts +41 -0
  530. package/dist/components/Skeleton/SkeletonRectangle.d.ts +42 -0
  531. package/dist/components/Skeleton/SkeletonText.d.ts +52 -0
  532. package/dist/components/Skeleton/index.d.ts +16 -2
  533. package/dist/components/Spinner/Spinner.d.ts +11 -6
  534. package/dist/components/SrOnly/SrOnly.d.ts +3 -7
  535. package/dist/components/Stepper/Stepper.d.ts +119 -239
  536. package/dist/components/Stepper/StepperFinalPanel.d.ts +30 -0
  537. package/dist/components/Stepper/StepperList.d.ts +28 -0
  538. package/dist/components/Stepper/StepperNextButton.d.ts +73 -0
  539. package/dist/components/Stepper/StepperPanel.d.ts +52 -0
  540. package/dist/components/Stepper/StepperPrevButton.d.ts +44 -0
  541. package/dist/components/Stepper/StepperStep.d.ts +58 -0
  542. package/dist/components/Stepper/index.d.ts +6 -0
  543. package/dist/components/Stepper/internal/StepperContext.d.ts +15 -0
  544. package/dist/components/Switch/Switch.d.ts +47 -11
  545. package/dist/components/Tab/Tab.d.ts +22 -88
  546. package/dist/components/Tab/TabButton.d.ts +54 -0
  547. package/dist/components/Tab/TabList.d.ts +26 -0
  548. package/dist/components/Tab/TabPanel.d.ts +34 -0
  549. package/dist/components/Tab/index.d.ts +3 -0
  550. package/dist/components/Tab/internal/TabContext.d.ts +15 -0
  551. package/dist/components/Text/Text.d.ts +7 -17
  552. package/dist/components/Text/types.d.ts +93 -0
  553. package/dist/components/TextField/TextField.d.ts +4 -5
  554. package/dist/components/TextField/internal/TextField.d.ts +20 -0
  555. package/dist/components/Textarea/Textarea.d.ts +52 -19
  556. package/dist/components/Textarea/index.d.ts +1 -2
  557. package/dist/components/Textarea/types.d.ts +35 -0
  558. package/dist/components/TimeField/TimeField.d.ts +55 -18
  559. package/dist/components/TimeField/index.d.ts +2 -0
  560. package/dist/components/TimeField/internal/MaskedTimeInput.d.ts +87 -0
  561. package/dist/components/TimeField/internal/constants.d.ts +25 -0
  562. package/dist/components/TimeField/internal/maskito/timePlaceholderMask.d.ts +28 -0
  563. package/dist/components/TimeField/internal/types.d.ts +27 -0
  564. package/dist/components/TimeField/internal/utils/timeFormatting.d.ts +10 -0
  565. package/dist/components/TimeField/internal/utils/timeOptions.d.ts +24 -0
  566. package/dist/components/TimeField/internal/utils/timeParsing.d.ts +43 -0
  567. package/dist/components/TimeField/internal/utils/timeRounding.d.ts +58 -0
  568. package/dist/components/TimeField/internal/utils/timeValidation.d.ts +28 -0
  569. package/dist/components/Toast/Toaster.d.ts +4 -4
  570. package/dist/components/Toast/internal/Toast.d.ts +106 -0
  571. package/dist/components/Toast/internal/ToastProvider.d.ts +90 -0
  572. package/dist/components/Toast/internal/ToastStack.d.ts +81 -0
  573. package/dist/components/Toast/internal/Toaster.d.ts +108 -0
  574. package/dist/components/Toast/internal/ToasterPopover.d.ts +19 -0
  575. package/dist/components/Toast/internal/addOrUpdateToastHeight.d.ts +8 -0
  576. package/dist/components/Toast/internal/constants.d.ts +4 -0
  577. package/dist/components/Toast/internal/types.d.ts +18 -0
  578. package/dist/components/Toast/internal/useCloseToast.d.ts +7 -0
  579. package/dist/components/Toast/internal/useHotkeyFocus.d.ts +25 -0
  580. package/dist/components/Toast/internal/useShowMoreButtonPositionStyles.d.ts +6 -0
  581. package/dist/components/Toast/internal/useToastPositionStyles.d.ts +7 -0
  582. package/dist/components/Toast/internal/useToasts.d.ts +6 -0
  583. package/dist/components/Toast/toast.d.ts +113 -38
  584. package/dist/components/Toolbar/Toolbar.d.ts +99 -141
  585. package/dist/components/Toolbar/ToolbarButton.d.ts +41 -0
  586. package/dist/components/Toolbar/ToolbarButtonLink.d.ts +43 -0
  587. package/dist/components/Toolbar/ToolbarButtonToggle.d.ts +37 -0
  588. package/dist/components/Toolbar/ToolbarSelect.d.ts +108 -0
  589. package/dist/components/Toolbar/index.d.ts +6 -1
  590. package/dist/components/Toolbar/internal/ToolbarItemOverflowContext.d.ts +19 -0
  591. package/dist/components/Toolbar/internal/ToolbarItemWrapper.d.ts +33 -0
  592. package/dist/components/Toolbar/internal/ToolbarOverflowContext.d.ts +35 -0
  593. package/dist/components/Toolbar/internal/ToolbarOverflowMenu.d.ts +29 -0
  594. package/dist/components/Toolbar/internal/utils/accessibility.d.ts +21 -0
  595. package/dist/components/Toolbar/internal/utils/test.d.ts +29 -0
  596. package/dist/components/Toolbar/types.d.ts +48 -0
  597. package/dist/components/Tooltip/Tooltip.d.ts +73 -71
  598. package/dist/components/Tooltip/TooltipContent.d.ts +26 -0
  599. package/dist/components/Tooltip/TooltipTrigger.d.ts +30 -0
  600. package/dist/components/Tooltip/index.d.ts +2 -0
  601. package/dist/components/Tooltip/internal/TooltipContext.d.ts +92 -0
  602. package/dist/components/Tooltip/internal/TooltipLegacy/TooltipLegacy.d.ts +6 -0
  603. package/dist/components/Tooltip/internal/TooltipLegacy/TooltipLegacyContent.d.ts +3 -0
  604. package/dist/components/Tooltip/internal/TooltipLegacy/TooltipLegacyTrigger.d.ts +5 -0
  605. package/dist/components/Tooltip/internal/TooltipLegacy/index.d.ts +6 -0
  606. package/dist/components/Tooltip/internal/TooltipLegacy/useTooltipLegacy.d.ts +70 -0
  607. package/dist/components/Tooltip/internal/TooltipLegacy/useTooltipLegacyContext.d.ts +58 -0
  608. package/dist/components/Tooltip/internal/isNonInteractiveTrigger.d.ts +1 -0
  609. package/dist/components/Tooltip/internal/useTooltipContext.d.ts +47 -0
  610. package/dist/components/index.d.ts +1 -0
  611. package/dist/extends-Bg2s_OKl.js.map +1 -1
  612. package/dist/getActiveElement-BcSyVE7S.js +25 -0
  613. package/dist/getActiveElement-BcSyVE7S.js.map +1 -0
  614. package/dist/getKeyboardFocusableElements-QqcABz0D.js.map +1 -1
  615. package/dist/hooks/index.d.ts +0 -1
  616. package/dist/hooks/useAccessibleColor/index.d.ts +1 -1
  617. package/dist/hooks/useAccessibleColor/useAccessibleColor.d.ts +38 -0
  618. package/dist/hooks/useBreakpoint/index.d.ts +1 -1
  619. package/dist/hooks/useBreakpoint/useBreakpoint.d.ts +49 -0
  620. package/dist/hooks/useMergeRefs/index.d.ts +1 -1
  621. package/dist/hooks/useMergeRefs/useMergeRefs.d.ts +17 -0
  622. package/dist/hooks/usePrefersColorScheme/index.d.ts +1 -1
  623. package/dist/hooks/usePrefersColorScheme/usePrefersColorScheme.d.ts +16 -0
  624. package/dist/hooks/useSwipe/index.d.ts +1 -1
  625. package/dist/hooks/useSwipe/useSwipe.d.ts +32 -0
  626. package/dist/{Checkbox.module-DZ58p15b-BUsQC1lW.js → indeterminate_check_box-Bg24oeHy.js} +8 -8
  627. package/dist/indeterminate_check_box-Bg24oeHy.js.map +1 -0
  628. package/dist/{Checkbox.css → indeterminate_check_box.css} +0 -1
  629. package/dist/{index-CKfiQx8n-4nziUo7G.js → index-CqdP5W00.js} +5 -5
  630. package/dist/index-CqdP5W00.js.map +1 -0
  631. package/dist/{ProgressBar-BRvB-bD4.css → index.css} +0 -641
  632. package/dist/index.d.ts +1 -0
  633. package/dist/{index.esm-dyoPQhi6.js → index.esm-D889iexm.js} +115 -115
  634. package/dist/index.esm-D889iexm.js.map +1 -0
  635. package/dist/index.js +508 -72
  636. package/dist/index.js.map +1 -1
  637. package/dist/{index-CKfiQx8n.css → index2.css} +0 -1
  638. package/dist/info-CYpG6tcI.js +6 -0
  639. package/dist/info-CYpG6tcI.js.map +1 -0
  640. package/dist/internal/components/Helper/Helper.d.ts +18 -0
  641. package/dist/internal/components/Helper/index.d.ts +1 -0
  642. package/dist/internal/components/Label/Label.d.ts +77 -0
  643. package/dist/internal/components/Label/index.d.ts +2 -0
  644. package/dist/internal/components/index.d.ts +2 -0
  645. package/dist/internal/functions/childrenToString.d.ts +25 -0
  646. package/dist/internal/functions/getActiveElement.d.ts +1 -0
  647. package/dist/internal/functions/getInitial.d.ts +16 -0
  648. package/dist/internal/functions/getKeyboardFocusableElements.d.ts +25 -0
  649. package/dist/internal/functions/index.d.ts +9 -0
  650. package/dist/internal/functions/kebabize.d.ts +16 -0
  651. package/dist/internal/functions/mapOrder.d.ts +1 -0
  652. package/dist/internal/functions/safePopover.d.ts +2 -0
  653. package/dist/internal/functions/sizeToToken.d.ts +2 -0
  654. package/dist/internal/functions/supportsPopover.d.ts +1 -0
  655. package/dist/internal/hooks/index.d.ts +17 -0
  656. package/dist/internal/hooks/useDialogScrollLock/index.d.ts +1 -0
  657. package/dist/internal/hooks/useDialogScrollLock/useDialogScrollLock.d.ts +40 -0
  658. package/dist/internal/hooks/useDialogTransitionStates/index.d.ts +1 -0
  659. package/dist/internal/hooks/useDialogTransitionStates/useDialogTransitionStates.d.ts +32 -0
  660. package/dist/internal/hooks/useFocusWithin/index.d.ts +1 -0
  661. package/dist/internal/hooks/useFocusWithin/useFocusWithin.d.ts +33 -0
  662. package/dist/internal/hooks/useIntersectionObserver/index.d.ts +1 -0
  663. package/dist/internal/hooks/useIntersectionObserver/useIntersectionObserver.d.ts +67 -0
  664. package/dist/internal/hooks/useIsScrollable/index.d.ts +1 -0
  665. package/dist/internal/hooks/useIsScrollable/useIsScrollable.d.ts +6 -0
  666. package/dist/internal/hooks/useKeyboardFocusables/index.d.ts +1 -0
  667. package/dist/internal/hooks/useKeyboardFocusables/useKeyboardFocusables.d.ts +54 -0
  668. package/dist/internal/hooks/useLayoutPropsUtil/index.d.ts +1 -0
  669. package/dist/internal/hooks/useLayoutPropsUtil/useLayoutPropsUtil.d.ts +56 -0
  670. package/dist/internal/hooks/useNumberField/index.d.ts +1 -0
  671. package/dist/internal/hooks/useNumberField/internal/useNumberFieldInputMode.d.ts +24 -0
  672. package/dist/internal/hooks/useNumberField/internal/useNumberFieldKeys.d.ts +43 -0
  673. package/dist/internal/hooks/useNumberField/useNumberField.d.ts +118 -0
  674. package/dist/internal/hooks/useOnClickOutside/index.d.ts +1 -0
  675. package/dist/internal/hooks/useOnClickOutside/useOnClickOutside.d.ts +34 -0
  676. package/dist/internal/hooks/useOpenCloseTransitionStates/index.d.ts +1 -0
  677. package/dist/internal/hooks/useOpenCloseTransitionStates/useOpenCloseTransitionStates.d.ts +51 -0
  678. package/dist/internal/hooks/useOptionallyControlledState/index.d.ts +1 -0
  679. package/dist/internal/hooks/useOptionallyControlledState/useOptionallyControlledState.d.ts +59 -0
  680. package/dist/internal/hooks/usePlatform/index.d.ts +1 -0
  681. package/dist/internal/hooks/usePlatform/usePlatform.d.ts +65 -0
  682. package/dist/internal/hooks/usePopoverCloseDelayWorkaround/index.d.ts +1 -0
  683. package/dist/internal/hooks/usePopoverCloseDelayWorkaround/usePopoverCloseDelayWorkaround.d.ts +1 -0
  684. package/dist/internal/hooks/usePopoverSupport/index.d.ts +1 -0
  685. package/dist/internal/hooks/usePopoverSupport/usePopoverSupport.d.ts +1 -0
  686. package/dist/internal/hooks/usePopoverTransitionStates/index.d.ts +1 -0
  687. package/dist/internal/hooks/usePopoverTransitionStates/usePopoverTransitionStates.d.ts +25 -0
  688. package/dist/internal/hooks/usePrevious/index.d.ts +1 -0
  689. package/dist/internal/hooks/usePrevious/usePrevious.d.ts +1 -0
  690. package/dist/internal/hooks/useTypeAhead/index.d.ts +1 -0
  691. package/dist/internal/hooks/useTypeAhead/useTypeAhead.d.ts +15 -0
  692. package/dist/internal/types/index.d.ts +1 -0
  693. package/dist/internal/types/props.d.ts +7 -0
  694. package/dist/internal/utils/index.d.ts +1 -0
  695. package/dist/makeZeroShortcutPreprocessor-CxsiGTRW.js +47 -0
  696. package/dist/makeZeroShortcutPreprocessor-CxsiGTRW.js.map +1 -0
  697. package/dist/providers/AnvilProvider/AnvilProvider.d.ts +29 -6
  698. package/dist/providers/LocalizationProvider/LocalizationContext.d.ts +6 -0
  699. package/dist/providers/LocalizationProvider/LocalizationProvider.d.ts +17 -0
  700. package/dist/providers/LocalizationProvider/LocalizationStoryWrapper.d.ts +6 -0
  701. package/dist/providers/LocalizationProvider/index.d.ts +2 -1
  702. package/dist/providers/LocalizationProvider/useTranslations.d.ts +4 -0
  703. package/dist/providers/PortalProvider/PortalProvider.d.ts +10 -0
  704. package/dist/providers/PortalProvider/index.d.ts +1 -1
  705. package/dist/providers/ThemeProvider/ThemeProvider.d.ts +14 -4
  706. package/dist/providers/ThemeProvider/index.d.ts +7 -1
  707. package/dist/providers/ThemeProvider/internal/ThemeProviderContext.d.ts +6 -0
  708. package/dist/providers/ThemeProvider/useTheme.d.ts +1 -0
  709. package/dist/types/MaxLengthCounterProps.d.ts +8 -0
  710. package/dist/types/ianaZones.d.ts +2 -0
  711. package/dist/types/index.d.ts +4 -1
  712. package/dist/types/locales.d.ts +3 -0
  713. package/dist/types/props.d.ts +66 -0
  714. package/dist/{useAccessibleColor-Dc6B_M-Z-BYKjkGRg.js → useAccessibleColor-BYKjkGRg.js} +1 -1
  715. package/dist/useAccessibleColor-BYKjkGRg.js.map +1 -0
  716. package/dist/useAccessibleColor.js +1 -1
  717. package/dist/{useBreakpoint-7QkBkSeP-Cv5fnZxs.js → useBreakpoint-Cv5fnZxs.js} +1 -1
  718. package/dist/useBreakpoint-Cv5fnZxs.js.map +1 -0
  719. package/dist/useBreakpoint.js +1 -1
  720. package/dist/useDateFieldOrchestration-Cqa7dxtr.js +138 -0
  721. package/dist/useDateFieldOrchestration-Cqa7dxtr.js.map +1 -0
  722. package/dist/useDialogTransitionStates-2NaE_noq.js +64 -0
  723. package/dist/useDialogTransitionStates-2NaE_noq.js.map +1 -0
  724. package/dist/{useFocusWithin-Cxz14Zyz-DEudRcSI.js → useFocusWithin-BhU7hoAD.js} +2 -10
  725. package/dist/useFocusWithin-BhU7hoAD.js.map +1 -0
  726. package/dist/{Combobox-BOpe_NUu.js → useInfiniteCombobox-BN2uGhBh.js} +1791 -1847
  727. package/dist/useInfiniteCombobox-BN2uGhBh.js.map +1 -0
  728. package/dist/{Combobox.css → useInfiniteCombobox.css} +102 -45
  729. package/dist/{useLayoutPropsUtil-DWACCL8v-CZNrcQT-.js → useLayoutPropsUtil-DjD5IMh0.js} +2 -2
  730. package/dist/useLayoutPropsUtil-DjD5IMh0.js.map +1 -0
  731. package/dist/{useMergeRefs-Bde85AWI-Bde85AWI.js → useMergeRefs-Bde85AWI.js} +1 -1
  732. package/dist/useMergeRefs-Bde85AWI.js.map +1 -0
  733. package/dist/useMergeRefs.js +1 -1
  734. package/dist/useOnClickOutside-BHEWMLa9.js +170 -0
  735. package/dist/useOnClickOutside-BHEWMLa9.js.map +1 -0
  736. package/dist/{useOptionallyControlledState-DbDuos5L-DbDuos5L.js → useOptionallyControlledState-DbDuos5L.js} +1 -1
  737. package/dist/useOptionallyControlledState-DbDuos5L.js.map +1 -0
  738. package/dist/{usePopoverCloseDelayWorkaround-BZcjPkvT-BZcjPkvT.js → usePopoverCloseDelayWorkaround-BZcjPkvT.js} +1 -1
  739. package/dist/usePopoverCloseDelayWorkaround-BZcjPkvT.js.map +1 -0
  740. package/dist/{usePopoverSupport-B9Lsqryr-CYJxXiun.js → usePopoverSupport-DIjjfodl.js} +2 -2
  741. package/dist/usePopoverSupport-DIjjfodl.js.map +1 -0
  742. package/dist/{usePrefersColorScheme-_hT7dK7_-_hT7dK7_.js → usePrefersColorScheme-_hT7dK7_.js} +1 -1
  743. package/dist/usePrefersColorScheme-_hT7dK7_.js.map +1 -0
  744. package/dist/usePrefersColorScheme.js +1 -1
  745. package/dist/usePrevious-Bvq-5auG.js +12 -0
  746. package/dist/usePrevious-Bvq-5auG.js.map +1 -0
  747. package/dist/{useSwipe-CULmVQEk-CULmVQEk.js → useSwipe-CULmVQEk.js} +1 -1
  748. package/dist/useSwipe-CULmVQEk.js.map +1 -0
  749. package/dist/useSwipe.js +1 -1
  750. package/dist/useTheme-B4i6a3bM.js +9 -0
  751. package/dist/useTheme-B4i6a3bM.js.map +1 -0
  752. package/package.json +29 -4
  753. package/dist/Alert-C3WoRkeN-D_6Yf63F.js +0 -98
  754. package/dist/Alert-C3WoRkeN-D_6Yf63F.js.map +0 -1
  755. package/dist/Alert-DipY5OlC.js +0 -23
  756. package/dist/Alert-DipY5OlC.js.map +0 -1
  757. package/dist/Announcement-ButSjdLn.js.map +0 -1
  758. package/dist/AnvilProvider-BLYCqIbb.js +0 -16
  759. package/dist/AnvilProvider-BLYCqIbb.js.map +0 -1
  760. package/dist/Avatar-C7cbRTCt-DCvzmr2C.js.map +0 -1
  761. package/dist/Avatar-DREZJN2K.js.map +0 -1
  762. package/dist/Badge-7aZfE-LH.js.map +0 -1
  763. package/dist/Breadcrumbs-BMbkH9hL-BUjQksuj.js.map +0 -1
  764. package/dist/Breadcrumbs-fthw3qaL.js +0 -36
  765. package/dist/Breadcrumbs-fthw3qaL.js.map +0 -1
  766. package/dist/Button-BaHFf1AT-BQy-PFB5.js.map +0 -1
  767. package/dist/Button-DMQKV2sV.js +0 -27
  768. package/dist/Button-DMQKV2sV.js.map +0 -1
  769. package/dist/Button.module-BqTaW8HK-BqTaW8HK.js +0 -25
  770. package/dist/Button.module-BqTaW8HK-BqTaW8HK.js.map +0 -1
  771. package/dist/ButtonCompound-Cs2A5X-Z-Dl3InVab.js +0 -49
  772. package/dist/ButtonCompound-Cs2A5X-Z-Dl3InVab.js.map +0 -1
  773. package/dist/ButtonCompound-DGuF0zzT.js +0 -25
  774. package/dist/ButtonCompound-DGuF0zzT.js.map +0 -1
  775. package/dist/ButtonLink-5qlX0uZx-b9H7MGhk.js.map +0 -1
  776. package/dist/ButtonLink-B0NJuVk5.js +0 -28
  777. package/dist/ButtonLink-B0NJuVk5.js.map +0 -1
  778. package/dist/ButtonToggle-Bm4KRl3o-B1-LbfjY.js.map +0 -1
  779. package/dist/ButtonToggle-CKVyEODc.js +0 -27
  780. package/dist/ButtonToggle-CKVyEODc.js.map +0 -1
  781. package/dist/Calendar-BvftKznl-D4_xp9Rv.js.map +0 -1
  782. package/dist/Calendar-DdOR9T_K.js +0 -130
  783. package/dist/Calendar-DdOR9T_K.js.map +0 -1
  784. package/dist/Card-U2IJPk8B.js +0 -11
  785. package/dist/Card-U2IJPk8B.js.map +0 -1
  786. package/dist/Card-ZknG-yim-7W6rYSFV.js.map +0 -1
  787. package/dist/Checkbox-DyHm7Ntt-DYw5QL3l.js.map +0 -1
  788. package/dist/Checkbox-zg8LVvB6.js.map +0 -1
  789. package/dist/Checkbox.module-DZ58p15b-BUsQC1lW.js.map +0 -1
  790. package/dist/Chip-DXQiqF8k.js +0 -34
  791. package/dist/Chip-DXQiqF8k.js.map +0 -1
  792. package/dist/Chip-MbBEXeAm-DmAcwPRJ.js.map +0 -1
  793. package/dist/Combobox-BOpe_NUu.js.map +0 -1
  794. package/dist/DateField-Bqsnpt8S.js.map +0 -1
  795. package/dist/DateFieldRange-Cax7Kl9A.js +0 -22
  796. package/dist/DateFieldRange-Cax7Kl9A.js.map +0 -1
  797. package/dist/DateFieldSingle-bMX770gU.js +0 -22
  798. package/dist/DateFieldSingle-bMX770gU.js.map +0 -1
  799. package/dist/DateFieldYearless-ClNYTBK_.js +0 -22
  800. package/dist/DateFieldYearless-ClNYTBK_.js.map +0 -1
  801. package/dist/DateFieldYearless-pejtv7-x-DBHpW83U.js +0 -1373
  802. package/dist/DateFieldYearless-pejtv7-x-DBHpW83U.js.map +0 -1
  803. package/dist/DaysOfTheWeek-ImBPjEvl.js.map +0 -1
  804. package/dist/Details-DVg0EOkv.js.map +0 -1
  805. package/dist/Dialog-BR6f-XRH.js.map +0 -1
  806. package/dist/Divider-B0xGfyWE-f5-ThMiS.js.map +0 -1
  807. package/dist/Divider-azRKjITG.js +0 -13
  808. package/dist/Divider-azRKjITG.js.map +0 -1
  809. package/dist/DndSort-Cl0FCNQm.js +0 -5546
  810. package/dist/DndSort-Cl0FCNQm.js.map +0 -1
  811. package/dist/Drawer-0ayAWgAA.js +0 -142
  812. package/dist/Drawer-0ayAWgAA.js.map +0 -1
  813. package/dist/EditCard-B_n1uFkv.js.map +0 -1
  814. package/dist/FieldLabel-DWl5qsRY.js +0 -13
  815. package/dist/FieldLabel-DWl5qsRY.js.map +0 -1
  816. package/dist/FieldMessage-Bobp105T-DYhStLY4.js.map +0 -1
  817. package/dist/FieldMessage-DkJ0K5s-.js +0 -13
  818. package/dist/FieldMessage-DkJ0K5s-.js.map +0 -1
  819. package/dist/Flex-CiK7uNUu-BfxHG4L0.js.map +0 -1
  820. package/dist/Flex-Ln6PmaDl.js +0 -11
  821. package/dist/Flex-Ln6PmaDl.js.map +0 -1
  822. package/dist/Grid-CMcDeSYT.js +0 -33
  823. package/dist/Grid-CMcDeSYT.js.map +0 -1
  824. package/dist/Grid-DFAd8mTe.js.map +0 -1
  825. package/dist/HammerProvider-vt3DkcCZ-06BeBrPu.js.map +0 -1
  826. package/dist/Helper-h7k80qls-DHPFHTvI.js.map +0 -1
  827. package/dist/Icon-B6HmlQiR-BxQkO3X5.js.map +0 -1
  828. package/dist/Icon-BgKqBmlj.js +0 -13
  829. package/dist/Icon-BgKqBmlj.js.map +0 -1
  830. package/dist/InputMask-BOUlnmiF.js +0 -30
  831. package/dist/InputMask-BOUlnmiF.js.map +0 -1
  832. package/dist/InputMask-BuO8lNAB-DdxdO5Jw.js.map +0 -1
  833. package/dist/Link-C4N_cV3i.js +0 -45
  834. package/dist/Link-C4N_cV3i.js.map +0 -1
  835. package/dist/Link-MiffPrW9-Cx1zYWSF.js +0 -67
  836. package/dist/Link-MiffPrW9-Cx1zYWSF.js.map +0 -1
  837. package/dist/ListView-DVPhWDCM.js.map +0 -1
  838. package/dist/ListView.module-MVsNF0X0-MVsNF0X0.js.map +0 -1
  839. package/dist/Listbox-B-WUuj-_-BWWeWtLW.js.map +0 -1
  840. package/dist/Listbox-Di6OS1Fk.js +0 -67
  841. package/dist/Listbox-Di6OS1Fk.js.map +0 -1
  842. package/dist/Listbox.module-DcBE8Zmo-DcBE8Zmo.js.map +0 -1
  843. package/dist/LocalizationContext-UsmB5mnR-BUIYgNp2.js.map +0 -1
  844. package/dist/LocalizationProvider-VtRAfGBT-Bo8XuFoE.js.map +0 -1
  845. package/dist/Menu-DHCOMJx2.js +0 -60
  846. package/dist/Menu-DHCOMJx2.js.map +0 -1
  847. package/dist/Menu-TtVJnSrA-yBYichuJ.js.map +0 -1
  848. package/dist/NumberField-C9lMsPMD.js.map +0 -1
  849. package/dist/Overflow-CFClqFVC-BKqOBCan.js +0 -393
  850. package/dist/Overflow-CFClqFVC-BKqOBCan.js.map +0 -1
  851. package/dist/Overflow-w-3_04fS.js +0 -69
  852. package/dist/Overflow-w-3_04fS.js.map +0 -1
  853. package/dist/Page-CGAylFKz.js.map +0 -1
  854. package/dist/Pagination-DU_qvFRR.js.map +0 -1
  855. package/dist/Popover-BPiqdyu1.js +0 -135
  856. package/dist/Popover-BPiqdyu1.js.map +0 -1
  857. package/dist/Popover-CU2cGVD8-Casl3vM1.js.map +0 -1
  858. package/dist/PortalProvider-9lXkQ0xY-BKoGegS1.js.map +0 -1
  859. package/dist/ProgressBar-BRvB-bD4-DppwBrFg.js +0 -2616
  860. package/dist/ProgressBar-BRvB-bD4-DppwBrFg.js.map +0 -1
  861. package/dist/ProgressBar-lPKNTz6i.js +0 -13
  862. package/dist/ProgressBar-lPKNTz6i.js.map +0 -1
  863. package/dist/Radio-DQ_VQFGZ-SdFBlDnE.js.map +0 -1
  864. package/dist/Radio-DnOuBPi_.js.map +0 -1
  865. package/dist/SearchField-BGPqpnVd.js.map +0 -1
  866. package/dist/SegmentedControl-DY1PSYmd.js.map +0 -1
  867. package/dist/SelectCard-LSAl_7Lh-BYtfe9PC.js.map +0 -1
  868. package/dist/SelectCardGroup-u_QKdeRZ.js +0 -49
  869. package/dist/SelectCardGroup-u_QKdeRZ.js.map +0 -1
  870. package/dist/SelectTrigger-C2w-flvK.js.map +0 -1
  871. package/dist/SelectTrigger.css +0 -16
  872. package/dist/SelectTriggerBase-Dj154EN4-BtTvR-Nh.js.map +0 -1
  873. package/dist/SideNav-Bh_pVeEw.js.map +0 -1
  874. package/dist/Skeleton-COxTdwjO.js +0 -398
  875. package/dist/Skeleton-COxTdwjO.js.map +0 -1
  876. package/dist/Spinner-C1r3COiQ.js +0 -13
  877. package/dist/Spinner-C1r3COiQ.js.map +0 -1
  878. package/dist/Spinner-DliJVzdW-BQlZEj4V.js.map +0 -1
  879. package/dist/SrOnly-BsKDHetF-B93X65F1.js.map +0 -1
  880. package/dist/SrOnly-C_I8eH4C.js +0 -9
  881. package/dist/SrOnly-C_I8eH4C.js.map +0 -1
  882. package/dist/Stepper-BtbDBIzz.js.map +0 -1
  883. package/dist/Switch-DAQFzi-X.js.map +0 -1
  884. package/dist/Tab-BSC7e4rM.js.map +0 -1
  885. package/dist/Text-35Ve4Uq0.js +0 -13
  886. package/dist/Text-35Ve4Uq0.js.map +0 -1
  887. package/dist/Text-CED_yrId-DsRYZw2-.js.map +0 -1
  888. package/dist/TextField-B364hxo8.js +0 -29
  889. package/dist/TextField-B364hxo8.js.map +0 -1
  890. package/dist/TextField-DoPP1CQ--UWAOTYiv.js.map +0 -1
  891. package/dist/TextField.module-EkKlj66e-EkKlj66e.js.map +0 -1
  892. package/dist/Textarea-D2AAZ1L3.js.map +0 -1
  893. package/dist/ThemeProvider-DwJqkbiU.js +0 -7
  894. package/dist/ThemeProvider-DwJqkbiU.js.map +0 -1
  895. package/dist/ThemeProvider-Q3ji6Rpx-DBXlAuQ8.js.map +0 -1
  896. package/dist/TimeField-tA9uo4lK.js.map +0 -1
  897. package/dist/Toolbar-CSWhVSUM.js.map +0 -1
  898. package/dist/Tooltip-C2HQDvYj.js +0 -73
  899. package/dist/Tooltip-C2HQDvYj.js.map +0 -1
  900. package/dist/check_circle-BGfigqq-.js.map +0 -1
  901. package/dist/childrenToString-Bz9MqbHb-Bz9MqbHb.js.map +0 -1
  902. package/dist/components/Skeleton/Skeleton.d.ts +0 -153
  903. package/dist/floating-ui.react-BFNinq1w.js.map +0 -1
  904. package/dist/hooks/useLinkStyles/index.d.ts +0 -1
  905. package/dist/index-CKfiQx8n-4nziUo7G.js.map +0 -1
  906. package/dist/index.esm-dyoPQhi6.js.map +0 -1
  907. package/dist/toast-BhV_Ask2.js.map +0 -1
  908. package/dist/useAccessibleColor-Dc6B_M-Z-BYKjkGRg.js.map +0 -1
  909. package/dist/useBreakpoint-7QkBkSeP-Cv5fnZxs.js.map +0 -1
  910. package/dist/useFocusWithin-Cxz14Zyz-DEudRcSI.js.map +0 -1
  911. package/dist/useLayoutPropsUtil-DWACCL8v-CZNrcQT-.js.map +0 -1
  912. package/dist/useLinkStyles.d.ts +0 -6
  913. package/dist/useLinkStyles.js +0 -2
  914. package/dist/useLinkStyles.js.map +0 -1
  915. package/dist/useMergeRefs-Bde85AWI-Bde85AWI.js.map +0 -1
  916. package/dist/useOptionallyControlledState-DbDuos5L-DbDuos5L.js.map +0 -1
  917. package/dist/usePopoverCloseDelayWorkaround-BZcjPkvT-BZcjPkvT.js.map +0 -1
  918. package/dist/usePopoverSupport-B9Lsqryr-CYJxXiun.js.map +0 -1
  919. package/dist/usePrefersColorScheme-_hT7dK7_-_hT7dK7_.js.map +0 -1
  920. package/dist/useSwipe-CULmVQEk-CULmVQEk.js.map +0 -1
  921. /package/dist/components/SideNav/{SideNavProvider.d.ts → internal/SideNavProvider.d.ts} +0 -0
@@ -1,977 +1,1004 @@
1
1
  import * as React from 'react';
2
- import { useLayoutEffect, useEffect, useRef } from 'react';
2
+ import { useLayoutEffect, useEffect, useRef, createContext } from 'react';
3
3
  import * as ReactDOM from 'react-dom';
4
4
 
5
- function hasWindow() {
6
- return typeof window !== 'undefined';
7
- }
8
- function getNodeName(node) {
9
- if (isNode(node)) {
10
- return (node.nodeName || '').toLowerCase();
11
- }
12
- // Mocked nodes in testing environments may not be instances of Node. By
13
- // returning `#document` an infinite loop won't occur.
14
- // https://github.com/floating-ui/floating-ui/issues/2317
15
- return '#document';
16
- }
17
- function getWindow(node) {
18
- var _node$ownerDocument;
19
- return (node == null || (_node$ownerDocument = node.ownerDocument) == null ? void 0 : _node$ownerDocument.defaultView) || window;
20
- }
21
- function getDocumentElement(node) {
22
- var _ref;
23
- return (_ref = (isNode(node) ? node.ownerDocument : node.document) || window.document) == null ? void 0 : _ref.documentElement;
24
- }
25
- function isNode(value) {
26
- if (!hasWindow()) {
27
- return false;
28
- }
29
- return value instanceof Node || value instanceof getWindow(value).Node;
30
- }
31
- function isElement(value) {
32
- if (!hasWindow()) {
33
- return false;
34
- }
35
- return value instanceof Element || value instanceof getWindow(value).Element;
36
- }
37
- function isHTMLElement(value) {
38
- if (!hasWindow()) {
39
- return false;
40
- }
41
- return value instanceof HTMLElement || value instanceof getWindow(value).HTMLElement;
42
- }
43
- function isShadowRoot(value) {
44
- if (!hasWindow() || typeof ShadowRoot === 'undefined') {
45
- return false;
46
- }
47
- return value instanceof ShadowRoot || value instanceof getWindow(value).ShadowRoot;
48
- }
49
- function isOverflowElement(element) {
50
- const {
51
- overflow,
52
- overflowX,
53
- overflowY,
54
- display
55
- } = getComputedStyle$1(element);
56
- return /auto|scroll|overlay|hidden|clip/.test(overflow + overflowY + overflowX) && !['inline', 'contents'].includes(display);
57
- }
58
- function isTableElement(element) {
59
- return ['table', 'td', 'th'].includes(getNodeName(element));
60
- }
61
- function isTopLayer(element) {
62
- return [':popover-open', ':modal'].some(selector => {
63
- try {
64
- return element.matches(selector);
65
- } catch (e) {
66
- return false;
67
- }
68
- });
69
- }
70
- function isContainingBlock(elementOrCss) {
71
- const webkit = isWebKit();
72
- const css = isElement(elementOrCss) ? getComputedStyle$1(elementOrCss) : elementOrCss;
5
+ /*!
6
+ * tabbable 6.2.0
7
+ * @license MIT, https://github.com/focus-trap/tabbable/blob/master/LICENSE
8
+ */
9
+ // NOTE: separate `:not()` selectors has broader browser support than the newer
10
+ // `:not([inert], [inert] *)` (Feb 2023)
11
+ // CAREFUL: JSDom does not support `:not([inert] *)` as a selector; using it causes
12
+ // the entire query to fail, resulting in no nodes found, which will break a lot
13
+ // of things... so we have to rely on JS to identify nodes inside an inert container
14
+ var candidateSelectors = ['input:not([inert])', 'select:not([inert])', 'textarea:not([inert])', 'a[href]:not([inert])', 'button:not([inert])', '[tabindex]:not(slot):not([inert])', 'audio[controls]:not([inert])', 'video[controls]:not([inert])', '[contenteditable]:not([contenteditable="false"]):not([inert])', 'details>summary:first-of-type:not([inert])', 'details:not([inert])'];
15
+ var candidateSelector = /* #__PURE__ */candidateSelectors.join(',');
16
+ var NoElement = typeof Element === 'undefined';
17
+ var matches = NoElement ? function () {} : Element.prototype.matches || Element.prototype.msMatchesSelector || Element.prototype.webkitMatchesSelector;
18
+ var getRootNode = !NoElement && Element.prototype.getRootNode ? function (element) {
19
+ var _element$getRootNode;
20
+ return element === null || element === void 0 ? void 0 : (_element$getRootNode = element.getRootNode) === null || _element$getRootNode === void 0 ? void 0 : _element$getRootNode.call(element);
21
+ } : function (element) {
22
+ return element === null || element === void 0 ? void 0 : element.ownerDocument;
23
+ };
73
24
 
74
- // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block
75
- // https://drafts.csswg.org/css-transforms-2/#individual-transforms
76
- return ['transform', 'translate', 'scale', 'rotate', 'perspective'].some(value => css[value] ? css[value] !== 'none' : false) || (css.containerType ? css.containerType !== 'normal' : false) || !webkit && (css.backdropFilter ? css.backdropFilter !== 'none' : false) || !webkit && (css.filter ? css.filter !== 'none' : false) || ['transform', 'translate', 'scale', 'rotate', 'perspective', 'filter'].some(value => (css.willChange || '').includes(value)) || ['paint', 'layout', 'strict', 'content'].some(value => (css.contain || '').includes(value));
77
- }
78
- function getContainingBlock(element) {
79
- let currentNode = getParentNode(element);
80
- while (isHTMLElement(currentNode) && !isLastTraversableNode(currentNode)) {
81
- if (isContainingBlock(currentNode)) {
82
- return currentNode;
83
- } else if (isTopLayer(currentNode)) {
84
- return null;
85
- }
86
- currentNode = getParentNode(currentNode);
87
- }
88
- return null;
89
- }
90
- function isWebKit() {
91
- if (typeof CSS === 'undefined' || !CSS.supports) return false;
92
- return CSS.supports('-webkit-backdrop-filter', 'none');
93
- }
94
- function isLastTraversableNode(node) {
95
- return ['html', 'body', '#document'].includes(getNodeName(node));
96
- }
97
- function getComputedStyle$1(element) {
98
- return getWindow(element).getComputedStyle(element);
99
- }
100
- function getNodeScroll(element) {
101
- if (isElement(element)) {
102
- return {
103
- scrollLeft: element.scrollLeft,
104
- scrollTop: element.scrollTop
105
- };
106
- }
107
- return {
108
- scrollLeft: element.scrollX,
109
- scrollTop: element.scrollY
110
- };
111
- }
112
- function getParentNode(node) {
113
- if (getNodeName(node) === 'html') {
114
- return node;
115
- }
116
- const result =
117
- // Step into the shadow DOM of the parent of a slotted node.
118
- node.assignedSlot ||
119
- // DOM Element detected.
120
- node.parentNode ||
121
- // ShadowRoot detected.
122
- isShadowRoot(node) && node.host ||
123
- // Fallback.
124
- getDocumentElement(node);
125
- return isShadowRoot(result) ? result.host : result;
126
- }
127
- function getNearestOverflowAncestor(node) {
128
- const parentNode = getParentNode(node);
129
- if (isLastTraversableNode(parentNode)) {
130
- return node.ownerDocument ? node.ownerDocument.body : node.body;
131
- }
132
- if (isHTMLElement(parentNode) && isOverflowElement(parentNode)) {
133
- return parentNode;
134
- }
135
- return getNearestOverflowAncestor(parentNode);
136
- }
137
- function getOverflowAncestors(node, list, traverseIframes) {
138
- var _node$ownerDocument2;
139
- if (list === void 0) {
140
- list = [];
141
- }
142
- if (traverseIframes === void 0) {
143
- traverseIframes = true;
144
- }
145
- const scrollableAncestor = getNearestOverflowAncestor(node);
146
- const isBody = scrollableAncestor === ((_node$ownerDocument2 = node.ownerDocument) == null ? void 0 : _node$ownerDocument2.body);
147
- const win = getWindow(scrollableAncestor);
148
- if (isBody) {
149
- const frameElement = getFrameElement(win);
150
- return list.concat(win, win.visualViewport || [], isOverflowElement(scrollableAncestor) ? scrollableAncestor : [], frameElement && traverseIframes ? getOverflowAncestors(frameElement) : []);
25
+ /**
26
+ * Determines if a node is inert or in an inert ancestor.
27
+ * @param {Element} [node]
28
+ * @param {boolean} [lookUp] If true and `node` is not inert, looks up at ancestors to
29
+ * see if any of them are inert. If false, only `node` itself is considered.
30
+ * @returns {boolean} True if inert itself or by way of being in an inert ancestor.
31
+ * False if `node` is falsy.
32
+ */
33
+ var isInert = function isInert(node, lookUp) {
34
+ var _node$getAttribute;
35
+ if (lookUp === void 0) {
36
+ lookUp = true;
151
37
  }
152
- return list.concat(scrollableAncestor, getOverflowAncestors(scrollableAncestor, [], traverseIframes));
153
- }
154
- function getFrameElement(win) {
155
- return win.parent && Object.getPrototypeOf(win.parent) ? win.frameElement : null;
156
- }
38
+ // CAREFUL: JSDom does not support inert at all, so we can't use the `HTMLElement.inert`
39
+ // JS API property; we have to check the attribute, which can either be empty or 'true';
40
+ // if it's `null` (not specified) or 'false', it's an active element
41
+ var inertAtt = node === null || node === void 0 ? void 0 : (_node$getAttribute = node.getAttribute) === null || _node$getAttribute === void 0 ? void 0 : _node$getAttribute.call(node, 'inert');
42
+ var inert = inertAtt === '' || inertAtt === 'true';
157
43
 
158
- function activeElement(doc) {
159
- let activeElement = doc.activeElement;
160
- while (((_activeElement = activeElement) == null || (_activeElement = _activeElement.shadowRoot) == null ? void 0 : _activeElement.activeElement) != null) {
161
- var _activeElement;
162
- activeElement = activeElement.shadowRoot.activeElement;
163
- }
164
- return activeElement;
165
- }
166
- function contains(parent, child) {
167
- if (!parent || !child) {
168
- return false;
169
- }
170
- const rootNode = child.getRootNode == null ? void 0 : child.getRootNode();
44
+ // NOTE: this could also be handled with `node.matches('[inert], :is([inert] *)')`
45
+ // if it weren't for `matches()` not being a function on shadow roots; the following
46
+ // code works for any kind of node
47
+ // CAREFUL: JSDom does not appear to support certain selectors like `:not([inert] *)`
48
+ // so it likely would not support `:is([inert] *)` either...
49
+ var result = inert || lookUp && node && isInert(node.parentNode); // recursive
171
50
 
172
- // First, attempt with faster native method
173
- if (parent.contains(child)) {
174
- return true;
175
- }
51
+ return result;
52
+ };
176
53
 
177
- // then fallback to custom implementation with Shadow DOM support
178
- if (rootNode && isShadowRoot(rootNode)) {
179
- let next = child;
180
- while (next) {
181
- if (parent === next) {
182
- return true;
183
- }
184
- // @ts-ignore
185
- next = next.parentNode || next.host;
186
- }
187
- }
54
+ /**
55
+ * Determines if a node's content is editable.
56
+ * @param {Element} [node]
57
+ * @returns True if it's content-editable; false if it's not or `node` is falsy.
58
+ */
59
+ var isContentEditable = function isContentEditable(node) {
60
+ var _node$getAttribute2;
61
+ // CAREFUL: JSDom does not support the `HTMLElement.isContentEditable` API so we have
62
+ // to use the attribute directly to check for this, which can either be empty or 'true';
63
+ // if it's `null` (not specified) or 'false', it's a non-editable element
64
+ var attValue = node === null || node === void 0 ? void 0 : (_node$getAttribute2 = node.getAttribute) === null || _node$getAttribute2 === void 0 ? void 0 : _node$getAttribute2.call(node, 'contenteditable');
65
+ return attValue === '' || attValue === 'true';
66
+ };
188
67
 
189
- // Give up, the result is false
190
- return false;
191
- }
192
- // Avoid Chrome DevTools blue warning.
193
- function getPlatform() {
194
- const uaData = navigator.userAgentData;
195
- if (uaData != null && uaData.platform) {
196
- return uaData.platform;
68
+ /**
69
+ * @param {Element} el container to check in
70
+ * @param {boolean} includeContainer add container to check
71
+ * @param {(node: Element) => boolean} filter filter candidates
72
+ * @returns {Element[]}
73
+ */
74
+ var getCandidates = function getCandidates(el, includeContainer, filter) {
75
+ // even if `includeContainer=false`, we still have to check it for inertness because
76
+ // if it's inert, all its children are inert
77
+ if (isInert(el)) {
78
+ return [];
197
79
  }
198
- return navigator.platform;
199
- }
200
- function getUserAgent() {
201
- const uaData = navigator.userAgentData;
202
- if (uaData && Array.isArray(uaData.brands)) {
203
- return uaData.brands.map(_ref => {
204
- let {
205
- brand,
206
- version
207
- } = _ref;
208
- return brand + "/" + version;
209
- }).join(' ');
80
+ var candidates = Array.prototype.slice.apply(el.querySelectorAll(candidateSelector));
81
+ if (includeContainer && matches.call(el, candidateSelector)) {
82
+ candidates.unshift(el);
210
83
  }
211
- return navigator.userAgent;
212
- }
84
+ candidates = candidates.filter(filter);
85
+ return candidates;
86
+ };
213
87
 
214
- // License: https://github.com/adobe/react-spectrum/blob/b35d5c02fe900badccd0cf1a8f23bb593419f238/packages/@react-aria/utils/src/isVirtualEvent.ts
215
- function isVirtualClick(event) {
216
- // FIXME: Firefox is now emitting a deprecation warning for `mozInputSource`.
217
- // Try to find a workaround for this. `react-aria` source still has the check.
218
- if (event.mozInputSource === 0 && event.isTrusted) {
219
- return true;
220
- }
221
- if (isAndroid() && event.pointerType) {
222
- return event.type === 'click' && event.buttons === 1;
223
- }
224
- return event.detail === 0 && !event.pointerType;
225
- }
226
- function isVirtualPointerEvent(event) {
227
- if (isJSDOM()) return false;
228
- return !isAndroid() && event.width === 0 && event.height === 0 || isAndroid() && event.width === 1 && event.height === 1 && event.pressure === 0 && event.detail === 0 && event.pointerType === 'mouse' ||
229
- // iOS VoiceOver returns 0.333• for width/height.
230
- event.width < 1 && event.height < 1 && event.pressure === 0 && event.detail === 0 && event.pointerType === 'touch';
231
- }
232
- function isSafari() {
233
- // Chrome DevTools does not complain about navigator.vendor
234
- return /apple/i.test(navigator.vendor);
235
- }
236
- function isAndroid() {
237
- const re = /android/i;
238
- return re.test(getPlatform()) || re.test(getUserAgent());
239
- }
240
- function isMac() {
241
- return getPlatform().toLowerCase().startsWith('mac') && !navigator.maxTouchPoints;
242
- }
243
- function isJSDOM() {
244
- return getUserAgent().includes('jsdom/');
245
- }
246
- function isMouseLikePointerType(pointerType, strict) {
247
- // On some Linux machines with Chromium, mouse inputs return a `pointerType`
248
- // of "pen": https://github.com/floating-ui/floating-ui/issues/2015
249
- const values = ['mouse', 'pen'];
250
- if (!strict) {
251
- values.push('', undefined);
252
- }
253
- return values.includes(pointerType);
254
- }
255
- function isReactEvent(event) {
256
- return 'nativeEvent' in event;
257
- }
258
- function isRootElement(element) {
259
- return element.matches('html,body');
260
- }
261
- function getDocument(node) {
262
- return (node == null ? void 0 : node.ownerDocument) || document;
263
- }
264
- function isEventTargetWithin(event, node) {
265
- if (node == null) {
266
- return false;
267
- }
268
- if ('composedPath' in event) {
269
- return event.composedPath().includes(node);
270
- }
88
+ /**
89
+ * @callback GetShadowRoot
90
+ * @param {Element} element to check for shadow root
91
+ * @returns {ShadowRoot|boolean} ShadowRoot if available or boolean indicating if a shadowRoot is attached but not available.
92
+ */
271
93
 
272
- // TS thinks `event` is of type never as it assumes all browsers support composedPath, but browsers without shadow dom don't
273
- const e = event;
274
- return e.target != null && node.contains(e.target);
275
- }
276
- function getTarget(event) {
277
- if ('composedPath' in event) {
278
- return event.composedPath()[0];
279
- }
94
+ /**
95
+ * @callback ShadowRootFilter
96
+ * @param {Element} shadowHostNode the element which contains shadow content
97
+ * @returns {boolean} true if a shadow root could potentially contain valid candidates.
98
+ */
280
99
 
281
- // TS thinks `event` is of type never as it assumes all browsers support
282
- // `composedPath()`, but browsers without shadow DOM don't.
283
- return event.target;
284
- }
285
- const TYPEABLE_SELECTOR = "input:not([type='hidden']):not([disabled])," + "[contenteditable]:not([contenteditable='false']),textarea:not([disabled])";
286
- function isTypeableElement(element) {
287
- return isHTMLElement(element) && element.matches(TYPEABLE_SELECTOR);
288
- }
289
- function stopEvent(event) {
290
- event.preventDefault();
291
- event.stopPropagation();
292
- }
293
- function isTypeableCombobox(element) {
294
- if (!element) return false;
295
- return element.getAttribute('role') === 'combobox' && isTypeableElement(element);
296
- }
100
+ /**
101
+ * @typedef {Object} CandidateScope
102
+ * @property {Element} scopeParent contains inner candidates
103
+ * @property {Element[]} candidates list of candidates found in the scope parent
104
+ */
297
105
 
298
106
  /**
299
- * Custom positioning reference element.
300
- * @see https://floating-ui.com/docs/virtual-elements
107
+ * @typedef {Object} IterativeOptions
108
+ * @property {GetShadowRoot|boolean} getShadowRoot true if shadow support is enabled; falsy if not;
109
+ * if a function, implies shadow support is enabled and either returns the shadow root of an element
110
+ * or a boolean stating if it has an undisclosed shadow root
111
+ * @property {(node: Element) => boolean} filter filter candidates
112
+ * @property {boolean} flatten if true then result will flatten any CandidateScope into the returned list
113
+ * @property {ShadowRootFilter} shadowRootFilter filter shadow roots;
301
114
  */
302
115
 
303
- const min = Math.min;
304
- const max = Math.max;
305
- const round = Math.round;
306
- const floor = Math.floor;
307
- const createCoords = v => ({
308
- x: v,
309
- y: v
310
- });
311
- const oppositeSideMap = {
312
- left: 'right',
313
- right: 'left',
314
- bottom: 'top',
315
- top: 'bottom'
316
- };
317
- const oppositeAlignmentMap = {
318
- start: 'end',
319
- end: 'start'
320
- };
321
- function clamp(start, value, end) {
322
- return max(start, min(value, end));
323
- }
324
- function evaluate(value, param) {
325
- return typeof value === 'function' ? value(param) : value;
326
- }
327
- function getSide(placement) {
328
- return placement.split('-')[0];
329
- }
330
- function getAlignment(placement) {
331
- return placement.split('-')[1];
332
- }
333
- function getOppositeAxis(axis) {
334
- return axis === 'x' ? 'y' : 'x';
335
- }
336
- function getAxisLength(axis) {
337
- return axis === 'y' ? 'height' : 'width';
338
- }
339
- function getSideAxis(placement) {
340
- return ['top', 'bottom'].includes(getSide(placement)) ? 'y' : 'x';
341
- }
342
- function getAlignmentAxis(placement) {
343
- return getOppositeAxis(getSideAxis(placement));
344
- }
345
- function getAlignmentSides(placement, rects, rtl) {
346
- if (rtl === void 0) {
347
- rtl = false;
348
- }
349
- const alignment = getAlignment(placement);
350
- const alignmentAxis = getAlignmentAxis(placement);
351
- const length = getAxisLength(alignmentAxis);
352
- let mainAlignmentSide = alignmentAxis === 'x' ? alignment === (rtl ? 'end' : 'start') ? 'right' : 'left' : alignment === 'start' ? 'bottom' : 'top';
353
- if (rects.reference[length] > rects.floating[length]) {
354
- mainAlignmentSide = getOppositePlacement(mainAlignmentSide);
355
- }
356
- return [mainAlignmentSide, getOppositePlacement(mainAlignmentSide)];
357
- }
358
- function getExpandedPlacements(placement) {
359
- const oppositePlacement = getOppositePlacement(placement);
360
- return [getOppositeAlignmentPlacement(placement), oppositePlacement, getOppositeAlignmentPlacement(oppositePlacement)];
361
- }
362
- function getOppositeAlignmentPlacement(placement) {
363
- return placement.replace(/start|end/g, alignment => oppositeAlignmentMap[alignment]);
364
- }
365
- function getSideList(side, isStart, rtl) {
366
- const lr = ['left', 'right'];
367
- const rl = ['right', 'left'];
368
- const tb = ['top', 'bottom'];
369
- const bt = ['bottom', 'top'];
370
- switch (side) {
371
- case 'top':
372
- case 'bottom':
373
- if (rtl) return isStart ? rl : lr;
374
- return isStart ? lr : rl;
375
- case 'left':
376
- case 'right':
377
- return isStart ? tb : bt;
378
- default:
379
- return [];
380
- }
381
- }
382
- function getOppositeAxisPlacements(placement, flipAlignment, direction, rtl) {
383
- const alignment = getAlignment(placement);
384
- let list = getSideList(getSide(placement), direction === 'start', rtl);
385
- if (alignment) {
386
- list = list.map(side => side + "-" + alignment);
387
- if (flipAlignment) {
388
- list = list.concat(list.map(getOppositeAlignmentPlacement));
116
+ /**
117
+ * @param {Element[]} elements list of element containers to match candidates from
118
+ * @param {boolean} includeContainer add container list to check
119
+ * @param {IterativeOptions} options
120
+ * @returns {Array.<Element|CandidateScope>}
121
+ */
122
+ var getCandidatesIteratively = function getCandidatesIteratively(elements, includeContainer, options) {
123
+ var candidates = [];
124
+ var elementsToCheck = Array.from(elements);
125
+ while (elementsToCheck.length) {
126
+ var element = elementsToCheck.shift();
127
+ if (isInert(element, false)) {
128
+ // no need to look up since we're drilling down
129
+ // anything inside this container will also be inert
130
+ continue;
131
+ }
132
+ if (element.tagName === 'SLOT') {
133
+ // add shadow dom slot scope (slot itself cannot be focusable)
134
+ var assigned = element.assignedElements();
135
+ var content = assigned.length ? assigned : element.children;
136
+ var nestedCandidates = getCandidatesIteratively(content, true, options);
137
+ if (options.flatten) {
138
+ candidates.push.apply(candidates, nestedCandidates);
139
+ } else {
140
+ candidates.push({
141
+ scopeParent: element,
142
+ candidates: nestedCandidates
143
+ });
144
+ }
145
+ } else {
146
+ // check candidate element
147
+ var validCandidate = matches.call(element, candidateSelector);
148
+ if (validCandidate && options.filter(element) && (includeContainer || !elements.includes(element))) {
149
+ candidates.push(element);
150
+ }
151
+
152
+ // iterate over shadow content if possible
153
+ var shadowRoot = element.shadowRoot ||
154
+ // check for an undisclosed shadow
155
+ typeof options.getShadowRoot === 'function' && options.getShadowRoot(element);
156
+
157
+ // no inert look up because we're already drilling down and checking for inertness
158
+ // on the way down, so all containers to this root node should have already been
159
+ // vetted as non-inert
160
+ var validShadowRoot = !isInert(shadowRoot, false) && (!options.shadowRootFilter || options.shadowRootFilter(element));
161
+ if (shadowRoot && validShadowRoot) {
162
+ // add shadow dom scope IIF a shadow root node was given; otherwise, an undisclosed
163
+ // shadow exists, so look at light dom children as fallback BUT create a scope for any
164
+ // child candidates found because they're likely slotted elements (elements that are
165
+ // children of the web component element (which has the shadow), in the light dom, but
166
+ // slotted somewhere _inside_ the undisclosed shadow) -- the scope is created below,
167
+ // _after_ we return from this recursive call
168
+ var _nestedCandidates = getCandidatesIteratively(shadowRoot === true ? element.children : shadowRoot.children, true, options);
169
+ if (options.flatten) {
170
+ candidates.push.apply(candidates, _nestedCandidates);
171
+ } else {
172
+ candidates.push({
173
+ scopeParent: element,
174
+ candidates: _nestedCandidates
175
+ });
176
+ }
177
+ } else {
178
+ // there's not shadow so just dig into the element's (light dom) children
179
+ // __without__ giving the element special scope treatment
180
+ elementsToCheck.unshift.apply(elementsToCheck, element.children);
181
+ }
389
182
  }
390
183
  }
391
- return list;
392
- }
393
- function getOppositePlacement(placement) {
394
- return placement.replace(/left|right|bottom|top/g, side => oppositeSideMap[side]);
395
- }
396
- function expandPaddingObject(padding) {
397
- return {
398
- top: 0,
399
- right: 0,
400
- bottom: 0,
401
- left: 0,
402
- ...padding
403
- };
404
- }
405
- function getPaddingObject(padding) {
406
- return typeof padding !== 'number' ? expandPaddingObject(padding) : {
407
- top: padding,
408
- right: padding,
409
- bottom: padding,
410
- left: padding
411
- };
412
- }
413
- function rectToClientRect(rect) {
414
- const {
415
- x,
416
- y,
417
- width,
418
- height
419
- } = rect;
420
- return {
421
- width,
422
- height,
423
- top: y,
424
- left: x,
425
- right: x + width,
426
- bottom: y + height,
427
- x,
428
- y
429
- };
430
- }
184
+ return candidates;
185
+ };
431
186
 
432
- /*!
433
- * tabbable 6.2.0
434
- * @license MIT, https://github.com/focus-trap/tabbable/blob/master/LICENSE
435
- */
436
- // NOTE: separate `:not()` selectors has broader browser support than the newer
437
- // `:not([inert], [inert] *)` (Feb 2023)
438
- // CAREFUL: JSDom does not support `:not([inert] *)` as a selector; using it causes
439
- // the entire query to fail, resulting in no nodes found, which will break a lot
440
- // of things... so we have to rely on JS to identify nodes inside an inert container
441
- var candidateSelectors = ['input:not([inert])', 'select:not([inert])', 'textarea:not([inert])', 'a[href]:not([inert])', 'button:not([inert])', '[tabindex]:not(slot):not([inert])', 'audio[controls]:not([inert])', 'video[controls]:not([inert])', '[contenteditable]:not([contenteditable="false"]):not([inert])', 'details>summary:first-of-type:not([inert])', 'details:not([inert])'];
442
- var candidateSelector = /* #__PURE__ */candidateSelectors.join(',');
443
- var NoElement = typeof Element === 'undefined';
444
- var matches = NoElement ? function () {} : Element.prototype.matches || Element.prototype.msMatchesSelector || Element.prototype.webkitMatchesSelector;
445
- var getRootNode = !NoElement && Element.prototype.getRootNode ? function (element) {
446
- var _element$getRootNode;
447
- return element === null || element === void 0 ? void 0 : (_element$getRootNode = element.getRootNode) === null || _element$getRootNode === void 0 ? void 0 : _element$getRootNode.call(element);
448
- } : function (element) {
449
- return element === null || element === void 0 ? void 0 : element.ownerDocument;
187
+ /**
188
+ * @private
189
+ * Determines if the node has an explicitly specified `tabindex` attribute.
190
+ * @param {HTMLElement} node
191
+ * @returns {boolean} True if so; false if not.
192
+ */
193
+ var hasTabIndex = function hasTabIndex(node) {
194
+ return !isNaN(parseInt(node.getAttribute('tabindex'), 10));
450
195
  };
451
196
 
452
197
  /**
453
- * Determines if a node is inert or in an inert ancestor.
454
- * @param {Element} [node]
455
- * @param {boolean} [lookUp] If true and `node` is not inert, looks up at ancestors to
456
- * see if any of them are inert. If false, only `node` itself is considered.
457
- * @returns {boolean} True if inert itself or by way of being in an inert ancestor.
458
- * False if `node` is falsy.
198
+ * Determine the tab index of a given node.
199
+ * @param {HTMLElement} node
200
+ * @returns {number} Tab order (negative, 0, or positive number).
201
+ * @throws {Error} If `node` is falsy.
459
202
  */
460
- var isInert = function isInert(node, lookUp) {
461
- var _node$getAttribute;
462
- if (lookUp === void 0) {
463
- lookUp = true;
203
+ var getTabIndex = function getTabIndex(node) {
204
+ if (!node) {
205
+ throw new Error('No node provided');
464
206
  }
465
- // CAREFUL: JSDom does not support inert at all, so we can't use the `HTMLElement.inert`
466
- // JS API property; we have to check the attribute, which can either be empty or 'true';
467
- // if it's `null` (not specified) or 'false', it's an active element
468
- var inertAtt = node === null || node === void 0 ? void 0 : (_node$getAttribute = node.getAttribute) === null || _node$getAttribute === void 0 ? void 0 : _node$getAttribute.call(node, 'inert');
469
- var inert = inertAtt === '' || inertAtt === 'true';
470
-
471
- // NOTE: this could also be handled with `node.matches('[inert], :is([inert] *)')`
472
- // if it weren't for `matches()` not being a function on shadow roots; the following
473
- // code works for any kind of node
474
- // CAREFUL: JSDom does not appear to support certain selectors like `:not([inert] *)`
475
- // so it likely would not support `:is([inert] *)` either...
476
- var result = inert || lookUp && node && isInert(node.parentNode); // recursive
477
-
478
- return result;
207
+ if (node.tabIndex < 0) {
208
+ // in Chrome, <details/>, <audio controls/> and <video controls/> elements get a default
209
+ // `tabIndex` of -1 when the 'tabindex' attribute isn't specified in the DOM,
210
+ // yet they are still part of the regular tab order; in FF, they get a default
211
+ // `tabIndex` of 0; since Chrome still puts those elements in the regular tab
212
+ // order, consider their tab index to be 0.
213
+ // Also browsers do not return `tabIndex` correctly for contentEditable nodes;
214
+ // so if they don't have a tabindex attribute specifically set, assume it's 0.
215
+ if ((/^(AUDIO|VIDEO|DETAILS)$/.test(node.tagName) || isContentEditable(node)) && !hasTabIndex(node)) {
216
+ return 0;
217
+ }
218
+ }
219
+ return node.tabIndex;
479
220
  };
480
221
 
481
222
  /**
482
- * Determines if a node's content is editable.
483
- * @param {Element} [node]
484
- * @returns True if it's content-editable; false if it's not or `node` is falsy.
223
+ * Determine the tab index of a given node __for sort order purposes__.
224
+ * @param {HTMLElement} node
225
+ * @param {boolean} [isScope] True for a custom element with shadow root or slot that, by default,
226
+ * has tabIndex -1, but needs to be sorted by document order in order for its content to be
227
+ * inserted into the correct sort position.
228
+ * @returns {number} Tab order (negative, 0, or positive number).
485
229
  */
486
- var isContentEditable = function isContentEditable(node) {
487
- var _node$getAttribute2;
488
- // CAREFUL: JSDom does not support the `HTMLElement.isContentEditable` API so we have
489
- // to use the attribute directly to check for this, which can either be empty or 'true';
490
- // if it's `null` (not specified) or 'false', it's a non-editable element
491
- var attValue = node === null || node === void 0 ? void 0 : (_node$getAttribute2 = node.getAttribute) === null || _node$getAttribute2 === void 0 ? void 0 : _node$getAttribute2.call(node, 'contenteditable');
492
- return attValue === '' || attValue === 'true';
230
+ var getSortOrderTabIndex = function getSortOrderTabIndex(node, isScope) {
231
+ var tabIndex = getTabIndex(node);
232
+ if (tabIndex < 0 && isScope && !hasTabIndex(node)) {
233
+ return 0;
234
+ }
235
+ return tabIndex;
236
+ };
237
+ var sortOrderedTabbables = function sortOrderedTabbables(a, b) {
238
+ return a.tabIndex === b.tabIndex ? a.documentOrder - b.documentOrder : a.tabIndex - b.tabIndex;
239
+ };
240
+ var isInput = function isInput(node) {
241
+ return node.tagName === 'INPUT';
242
+ };
243
+ var isHiddenInput = function isHiddenInput(node) {
244
+ return isInput(node) && node.type === 'hidden';
245
+ };
246
+ var isDetailsWithSummary = function isDetailsWithSummary(node) {
247
+ var r = node.tagName === 'DETAILS' && Array.prototype.slice.apply(node.children).some(function (child) {
248
+ return child.tagName === 'SUMMARY';
249
+ });
250
+ return r;
251
+ };
252
+ var getCheckedRadio = function getCheckedRadio(nodes, form) {
253
+ for (var i = 0; i < nodes.length; i++) {
254
+ if (nodes[i].checked && nodes[i].form === form) {
255
+ return nodes[i];
256
+ }
257
+ }
258
+ };
259
+ var isTabbableRadio = function isTabbableRadio(node) {
260
+ if (!node.name) {
261
+ return true;
262
+ }
263
+ var radioScope = node.form || getRootNode(node);
264
+ var queryRadios = function queryRadios(name) {
265
+ return radioScope.querySelectorAll('input[type="radio"][name="' + name + '"]');
266
+ };
267
+ var radioSet;
268
+ if (typeof window !== 'undefined' && typeof window.CSS !== 'undefined' && typeof window.CSS.escape === 'function') {
269
+ radioSet = queryRadios(window.CSS.escape(node.name));
270
+ } else {
271
+ try {
272
+ radioSet = queryRadios(node.name);
273
+ } catch (err) {
274
+ // eslint-disable-next-line no-console
275
+ console.error('Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s', err.message);
276
+ return false;
277
+ }
278
+ }
279
+ var checked = getCheckedRadio(radioSet, node.form);
280
+ return !checked || checked === node;
281
+ };
282
+ var isRadio = function isRadio(node) {
283
+ return isInput(node) && node.type === 'radio';
284
+ };
285
+ var isNonTabbableRadio = function isNonTabbableRadio(node) {
286
+ return isRadio(node) && !isTabbableRadio(node);
287
+ };
288
+
289
+ // determines if a node is ultimately attached to the window's document
290
+ var isNodeAttached = function isNodeAttached(node) {
291
+ var _nodeRoot;
292
+ // The root node is the shadow root if the node is in a shadow DOM; some document otherwise
293
+ // (but NOT _the_ document; see second 'If' comment below for more).
294
+ // If rootNode is shadow root, it'll have a host, which is the element to which the shadow
295
+ // is attached, and the one we need to check if it's in the document or not (because the
296
+ // shadow, and all nodes it contains, is never considered in the document since shadows
297
+ // behave like self-contained DOMs; but if the shadow's HOST, which is part of the document,
298
+ // is hidden, or is not in the document itself but is detached, it will affect the shadow's
299
+ // visibility, including all the nodes it contains). The host could be any normal node,
300
+ // or a custom element (i.e. web component). Either way, that's the one that is considered
301
+ // part of the document, not the shadow root, nor any of its children (i.e. the node being
302
+ // tested).
303
+ // To further complicate things, we have to look all the way up until we find a shadow HOST
304
+ // that is attached (or find none) because the node might be in nested shadows...
305
+ // If rootNode is not a shadow root, it won't have a host, and so rootNode should be the
306
+ // document (per the docs) and while it's a Document-type object, that document does not
307
+ // appear to be the same as the node's `ownerDocument` for some reason, so it's safer
308
+ // to ignore the rootNode at this point, and use `node.ownerDocument`. Otherwise,
309
+ // using `rootNode.contains(node)` will _always_ be true we'll get false-positives when
310
+ // node is actually detached.
311
+ // NOTE: If `nodeRootHost` or `node` happens to be the `document` itself (which is possible
312
+ // if a tabbable/focusable node was quickly added to the DOM, focused, and then removed
313
+ // from the DOM as in https://github.com/focus-trap/focus-trap-react/issues/905), then
314
+ // `ownerDocument` will be `null`, hence the optional chaining on it.
315
+ var nodeRoot = node && getRootNode(node);
316
+ var nodeRootHost = (_nodeRoot = nodeRoot) === null || _nodeRoot === void 0 ? void 0 : _nodeRoot.host;
317
+
318
+ // in some cases, a detached node will return itself as the root instead of a document or
319
+ // shadow root object, in which case, we shouldn't try to look further up the host chain
320
+ var attached = false;
321
+ if (nodeRoot && nodeRoot !== node) {
322
+ var _nodeRootHost, _nodeRootHost$ownerDo, _node$ownerDocument;
323
+ attached = !!((_nodeRootHost = nodeRootHost) !== null && _nodeRootHost !== void 0 && (_nodeRootHost$ownerDo = _nodeRootHost.ownerDocument) !== null && _nodeRootHost$ownerDo !== void 0 && _nodeRootHost$ownerDo.contains(nodeRootHost) || node !== null && node !== void 0 && (_node$ownerDocument = node.ownerDocument) !== null && _node$ownerDocument !== void 0 && _node$ownerDocument.contains(node));
324
+ while (!attached && nodeRootHost) {
325
+ var _nodeRoot2, _nodeRootHost2, _nodeRootHost2$ownerD;
326
+ // since it's not attached and we have a root host, the node MUST be in a nested shadow DOM,
327
+ // which means we need to get the host's host and check if that parent host is contained
328
+ // in (i.e. attached to) the document
329
+ nodeRoot = getRootNode(nodeRootHost);
330
+ nodeRootHost = (_nodeRoot2 = nodeRoot) === null || _nodeRoot2 === void 0 ? void 0 : _nodeRoot2.host;
331
+ attached = !!((_nodeRootHost2 = nodeRootHost) !== null && _nodeRootHost2 !== void 0 && (_nodeRootHost2$ownerD = _nodeRootHost2.ownerDocument) !== null && _nodeRootHost2$ownerD !== void 0 && _nodeRootHost2$ownerD.contains(nodeRootHost));
332
+ }
333
+ }
334
+ return attached;
493
335
  };
494
-
495
- /**
496
- * @param {Element} el container to check in
497
- * @param {boolean} includeContainer add container to check
498
- * @param {(node: Element) => boolean} filter filter candidates
499
- * @returns {Element[]}
500
- */
501
- var getCandidates = function getCandidates(el, includeContainer, filter) {
502
- // even if `includeContainer=false`, we still have to check it for inertness because
503
- // if it's inert, all its children are inert
504
- if (isInert(el)) {
505
- return [];
336
+ var isZeroArea = function isZeroArea(node) {
337
+ var _node$getBoundingClie = node.getBoundingClientRect(),
338
+ width = _node$getBoundingClie.width,
339
+ height = _node$getBoundingClie.height;
340
+ return width === 0 && height === 0;
341
+ };
342
+ var isHidden = function isHidden(node, _ref) {
343
+ var displayCheck = _ref.displayCheck,
344
+ getShadowRoot = _ref.getShadowRoot;
345
+ // NOTE: visibility will be `undefined` if node is detached from the document
346
+ // (see notes about this further down), which means we will consider it visible
347
+ // (this is legacy behavior from a very long way back)
348
+ // NOTE: we check this regardless of `displayCheck="none"` because this is a
349
+ // _visibility_ check, not a _display_ check
350
+ if (getComputedStyle(node).visibility === 'hidden') {
351
+ return true;
506
352
  }
507
- var candidates = Array.prototype.slice.apply(el.querySelectorAll(candidateSelector));
508
- if (includeContainer && matches.call(el, candidateSelector)) {
509
- candidates.unshift(el);
353
+ var isDirectSummary = matches.call(node, 'details>summary:first-of-type');
354
+ var nodeUnderDetails = isDirectSummary ? node.parentElement : node;
355
+ if (matches.call(nodeUnderDetails, 'details:not([open]) *')) {
356
+ return true;
510
357
  }
511
- candidates = candidates.filter(filter);
512
- return candidates;
513
- };
514
-
515
- /**
516
- * @callback GetShadowRoot
517
- * @param {Element} element to check for shadow root
518
- * @returns {ShadowRoot|boolean} ShadowRoot if available or boolean indicating if a shadowRoot is attached but not available.
519
- */
520
-
521
- /**
522
- * @callback ShadowRootFilter
523
- * @param {Element} shadowHostNode the element which contains shadow content
524
- * @returns {boolean} true if a shadow root could potentially contain valid candidates.
525
- */
358
+ if (!displayCheck || displayCheck === 'full' || displayCheck === 'legacy-full') {
359
+ if (typeof getShadowRoot === 'function') {
360
+ // figure out if we should consider the node to be in an undisclosed shadow and use the
361
+ // 'non-zero-area' fallback
362
+ var originalNode = node;
363
+ while (node) {
364
+ var parentElement = node.parentElement;
365
+ var rootNode = getRootNode(node);
366
+ if (parentElement && !parentElement.shadowRoot && getShadowRoot(parentElement) === true // check if there's an undisclosed shadow
367
+ ) {
368
+ // node has an undisclosed shadow which means we can only treat it as a black box, so we
369
+ // fall back to a non-zero-area test
370
+ return isZeroArea(node);
371
+ } else if (node.assignedSlot) {
372
+ // iterate up slot
373
+ node = node.assignedSlot;
374
+ } else if (!parentElement && rootNode !== node.ownerDocument) {
375
+ // cross shadow boundary
376
+ node = rootNode.host;
377
+ } else {
378
+ // iterate up normal dom
379
+ node = parentElement;
380
+ }
381
+ }
382
+ node = originalNode;
383
+ }
384
+ // else, `getShadowRoot` might be true, but all that does is enable shadow DOM support
385
+ // (i.e. it does not also presume that all nodes might have undisclosed shadows); or
386
+ // it might be a falsy value, which means shadow DOM support is disabled
526
387
 
527
- /**
528
- * @typedef {Object} CandidateScope
529
- * @property {Element} scopeParent contains inner candidates
530
- * @property {Element[]} candidates list of candidates found in the scope parent
531
- */
388
+ // Since we didn't find it sitting in an undisclosed shadow (or shadows are disabled)
389
+ // now we can just test to see if it would normally be visible or not, provided it's
390
+ // attached to the main document.
391
+ // NOTE: We must consider case where node is inside a shadow DOM and given directly to
392
+ // `isTabbable()` or `isFocusable()` -- regardless of `getShadowRoot` option setting.
532
393
 
533
- /**
534
- * @typedef {Object} IterativeOptions
535
- * @property {GetShadowRoot|boolean} getShadowRoot true if shadow support is enabled; falsy if not;
536
- * if a function, implies shadow support is enabled and either returns the shadow root of an element
537
- * or a boolean stating if it has an undisclosed shadow root
538
- * @property {(node: Element) => boolean} filter filter candidates
539
- * @property {boolean} flatten if true then result will flatten any CandidateScope into the returned list
540
- * @property {ShadowRootFilter} shadowRootFilter filter shadow roots;
541
- */
394
+ if (isNodeAttached(node)) {
395
+ // this works wherever the node is: if there's at least one client rect, it's
396
+ // somehow displayed; it also covers the CSS 'display: contents' case where the
397
+ // node itself is hidden in place of its contents; and there's no need to search
398
+ // up the hierarchy either
399
+ return !node.getClientRects().length;
400
+ }
542
401
 
543
- /**
544
- * @param {Element[]} elements list of element containers to match candidates from
545
- * @param {boolean} includeContainer add container list to check
546
- * @param {IterativeOptions} options
547
- * @returns {Array.<Element|CandidateScope>}
548
- */
549
- var getCandidatesIteratively = function getCandidatesIteratively(elements, includeContainer, options) {
550
- var candidates = [];
551
- var elementsToCheck = Array.from(elements);
552
- while (elementsToCheck.length) {
553
- var element = elementsToCheck.shift();
554
- if (isInert(element, false)) {
555
- // no need to look up since we're drilling down
556
- // anything inside this container will also be inert
557
- continue;
402
+ // Else, the node isn't attached to the document, which means the `getClientRects()`
403
+ // API will __always__ return zero rects (this can happen, for example, if React
404
+ // is used to render nodes onto a detached tree, as confirmed in this thread:
405
+ // https://github.com/facebook/react/issues/9117#issuecomment-284228870)
406
+ //
407
+ // It also means that even window.getComputedStyle(node).display will return `undefined`
408
+ // because styles are only computed for nodes that are in the document.
409
+ //
410
+ // NOTE: THIS HAS BEEN THE CASE FOR YEARS. It is not new, nor is it caused by tabbable
411
+ // somehow. Though it was never stated officially, anyone who has ever used tabbable
412
+ // APIs on nodes in detached containers has actually implicitly used tabbable in what
413
+ // was later (as of v5.2.0 on Apr 9, 2021) called `displayCheck="none"` mode -- essentially
414
+ // considering __everything__ to be visible because of the innability to determine styles.
415
+ //
416
+ // v6.0.0: As of this major release, the default 'full' option __no longer treats detached
417
+ // nodes as visible with the 'none' fallback.__
418
+ if (displayCheck !== 'legacy-full') {
419
+ return true; // hidden
558
420
  }
559
- if (element.tagName === 'SLOT') {
560
- // add shadow dom slot scope (slot itself cannot be focusable)
561
- var assigned = element.assignedElements();
562
- var content = assigned.length ? assigned : element.children;
563
- var nestedCandidates = getCandidatesIteratively(content, true, options);
564
- if (options.flatten) {
565
- candidates.push.apply(candidates, nestedCandidates);
566
- } else {
567
- candidates.push({
568
- scopeParent: element,
569
- candidates: nestedCandidates
570
- });
571
- }
572
- } else {
573
- // check candidate element
574
- var validCandidate = matches.call(element, candidateSelector);
575
- if (validCandidate && options.filter(element) && (includeContainer || !elements.includes(element))) {
576
- candidates.push(element);
577
- }
421
+ // else, fallback to 'none' mode and consider the node visible
422
+ } else if (displayCheck === 'non-zero-area') {
423
+ // NOTE: Even though this tests that the node's client rect is non-zero to determine
424
+ // whether it's displayed, and that a detached node will __always__ have a zero-area
425
+ // client rect, we don't special-case for whether the node is attached or not. In
426
+ // this mode, we do want to consider nodes that have a zero area to be hidden at all
427
+ // times, and that includes attached or not.
428
+ return isZeroArea(node);
429
+ }
578
430
 
579
- // iterate over shadow content if possible
580
- var shadowRoot = element.shadowRoot ||
581
- // check for an undisclosed shadow
582
- typeof options.getShadowRoot === 'function' && options.getShadowRoot(element);
431
+ // visible, as far as we can tell, or per current `displayCheck=none` mode, we assume
432
+ // it's visible
433
+ return false;
434
+ };
583
435
 
584
- // no inert look up because we're already drilling down and checking for inertness
585
- // on the way down, so all containers to this root node should have already been
586
- // vetted as non-inert
587
- var validShadowRoot = !isInert(shadowRoot, false) && (!options.shadowRootFilter || options.shadowRootFilter(element));
588
- if (shadowRoot && validShadowRoot) {
589
- // add shadow dom scope IIF a shadow root node was given; otherwise, an undisclosed
590
- // shadow exists, so look at light dom children as fallback BUT create a scope for any
591
- // child candidates found because they're likely slotted elements (elements that are
592
- // children of the web component element (which has the shadow), in the light dom, but
593
- // slotted somewhere _inside_ the undisclosed shadow) -- the scope is created below,
594
- // _after_ we return from this recursive call
595
- var _nestedCandidates = getCandidatesIteratively(shadowRoot === true ? element.children : shadowRoot.children, true, options);
596
- if (options.flatten) {
597
- candidates.push.apply(candidates, _nestedCandidates);
598
- } else {
599
- candidates.push({
600
- scopeParent: element,
601
- candidates: _nestedCandidates
602
- });
436
+ // form fields (nested) inside a disabled fieldset are not focusable/tabbable
437
+ // unless they are in the _first_ <legend> element of the top-most disabled
438
+ // fieldset
439
+ var isDisabledFromFieldset = function isDisabledFromFieldset(node) {
440
+ if (/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(node.tagName)) {
441
+ var parentNode = node.parentElement;
442
+ // check if `node` is contained in a disabled <fieldset>
443
+ while (parentNode) {
444
+ if (parentNode.tagName === 'FIELDSET' && parentNode.disabled) {
445
+ // look for the first <legend> among the children of the disabled <fieldset>
446
+ for (var i = 0; i < parentNode.children.length; i++) {
447
+ var child = parentNode.children.item(i);
448
+ // when the first <legend> (in document order) is found
449
+ if (child.tagName === 'LEGEND') {
450
+ // if its parent <fieldset> is not nested in another disabled <fieldset>,
451
+ // return whether `node` is a descendant of its first <legend>
452
+ return matches.call(parentNode, 'fieldset[disabled] *') ? true : !child.contains(node);
453
+ }
603
454
  }
604
- } else {
605
- // there's not shadow so just dig into the element's (light dom) children
606
- // __without__ giving the element special scope treatment
607
- elementsToCheck.unshift.apply(elementsToCheck, element.children);
455
+ // the disabled <fieldset> containing `node` has no <legend>
456
+ return true;
608
457
  }
458
+ parentNode = parentNode.parentElement;
609
459
  }
610
460
  }
611
- return candidates;
461
+
462
+ // else, node's tabbable/focusable state should not be affected by a fieldset's
463
+ // enabled/disabled state
464
+ return false;
465
+ };
466
+ var isNodeMatchingSelectorFocusable = function isNodeMatchingSelectorFocusable(options, node) {
467
+ if (node.disabled ||
468
+ // we must do an inert look up to filter out any elements inside an inert ancestor
469
+ // because we're limited in the type of selectors we can use in JSDom (see related
470
+ // note related to `candidateSelectors`)
471
+ isInert(node) || isHiddenInput(node) || isHidden(node, options) ||
472
+ // For a details element with a summary, the summary element gets the focus
473
+ isDetailsWithSummary(node) || isDisabledFromFieldset(node)) {
474
+ return false;
475
+ }
476
+ return true;
477
+ };
478
+ var isNodeMatchingSelectorTabbable = function isNodeMatchingSelectorTabbable(options, node) {
479
+ if (isNonTabbableRadio(node) || getTabIndex(node) < 0 || !isNodeMatchingSelectorFocusable(options, node)) {
480
+ return false;
481
+ }
482
+ return true;
483
+ };
484
+ var isValidShadowRootTabbable = function isValidShadowRootTabbable(shadowHostNode) {
485
+ var tabIndex = parseInt(shadowHostNode.getAttribute('tabindex'), 10);
486
+ if (isNaN(tabIndex) || tabIndex >= 0) {
487
+ return true;
488
+ }
489
+ // If a custom element has an explicit negative tabindex,
490
+ // browsers will not allow tab targeting said element's children.
491
+ return false;
612
492
  };
613
493
 
614
494
  /**
615
- * @private
616
- * Determines if the node has an explicitly specified `tabindex` attribute.
617
- * @param {HTMLElement} node
618
- * @returns {boolean} True if so; false if not.
495
+ * @param {Array.<Element|CandidateScope>} candidates
496
+ * @returns Element[]
619
497
  */
620
- var hasTabIndex = function hasTabIndex(node) {
621
- return !isNaN(parseInt(node.getAttribute('tabindex'), 10));
498
+ var sortByOrder = function sortByOrder(candidates) {
499
+ var regularTabbables = [];
500
+ var orderedTabbables = [];
501
+ candidates.forEach(function (item, i) {
502
+ var isScope = !!item.scopeParent;
503
+ var element = isScope ? item.scopeParent : item;
504
+ var candidateTabindex = getSortOrderTabIndex(element, isScope);
505
+ var elements = isScope ? sortByOrder(item.candidates) : element;
506
+ if (candidateTabindex === 0) {
507
+ isScope ? regularTabbables.push.apply(regularTabbables, elements) : regularTabbables.push(element);
508
+ } else {
509
+ orderedTabbables.push({
510
+ documentOrder: i,
511
+ tabIndex: candidateTabindex,
512
+ item: item,
513
+ isScope: isScope,
514
+ content: elements
515
+ });
516
+ }
517
+ });
518
+ return orderedTabbables.sort(sortOrderedTabbables).reduce(function (acc, sortable) {
519
+ sortable.isScope ? acc.push.apply(acc, sortable.content) : acc.push(sortable.content);
520
+ return acc;
521
+ }, []).concat(regularTabbables);
622
522
  };
623
-
624
- /**
625
- * Determine the tab index of a given node.
626
- * @param {HTMLElement} node
627
- * @returns {number} Tab order (negative, 0, or positive number).
628
- * @throws {Error} If `node` is falsy.
629
- */
630
- var getTabIndex = function getTabIndex(node) {
523
+ var tabbable = function tabbable(container, options) {
524
+ options = options || {};
525
+ var candidates;
526
+ if (options.getShadowRoot) {
527
+ candidates = getCandidatesIteratively([container], options.includeContainer, {
528
+ filter: isNodeMatchingSelectorTabbable.bind(null, options),
529
+ flatten: false,
530
+ getShadowRoot: options.getShadowRoot,
531
+ shadowRootFilter: isValidShadowRootTabbable
532
+ });
533
+ } else {
534
+ candidates = getCandidates(container, options.includeContainer, isNodeMatchingSelectorTabbable.bind(null, options));
535
+ }
536
+ return sortByOrder(candidates);
537
+ };
538
+ var isTabbable = function isTabbable(node, options) {
539
+ options = options || {};
631
540
  if (!node) {
632
541
  throw new Error('No node provided');
633
542
  }
634
- if (node.tabIndex < 0) {
635
- // in Chrome, <details/>, <audio controls/> and <video controls/> elements get a default
636
- // `tabIndex` of -1 when the 'tabindex' attribute isn't specified in the DOM,
637
- // yet they are still part of the regular tab order; in FF, they get a default
638
- // `tabIndex` of 0; since Chrome still puts those elements in the regular tab
639
- // order, consider their tab index to be 0.
640
- // Also browsers do not return `tabIndex` correctly for contentEditable nodes;
641
- // so if they don't have a tabindex attribute specifically set, assume it's 0.
642
- if ((/^(AUDIO|VIDEO|DETAILS)$/.test(node.tagName) || isContentEditable(node)) && !hasTabIndex(node)) {
643
- return 0;
644
- }
543
+ if (matches.call(node, candidateSelector) === false) {
544
+ return false;
645
545
  }
646
- return node.tabIndex;
546
+ return isNodeMatchingSelectorTabbable(options, node);
647
547
  };
648
548
 
649
- /**
650
- * Determine the tab index of a given node __for sort order purposes__.
651
- * @param {HTMLElement} node
652
- * @param {boolean} [isScope] True for a custom element with shadow root or slot that, by default,
653
- * has tabIndex -1, but needs to be sorted by document order in order for its content to be
654
- * inserted into the correct sort position.
655
- * @returns {number} Tab order (negative, 0, or positive number).
656
- */
657
- var getSortOrderTabIndex = function getSortOrderTabIndex(node, isScope) {
658
- var tabIndex = getTabIndex(node);
659
- if (tabIndex < 0 && isScope && !hasTabIndex(node)) {
660
- return 0;
549
+ function supportsPopover() {
550
+ return Object.prototype.hasOwnProperty.call(HTMLElement.prototype, "popover");
551
+ }
552
+
553
+ const safeShowPopover = (element) => {
554
+ try {
555
+ element?.showPopover();
556
+ } catch (e) {
557
+ console.warn(e);
661
558
  }
662
- return tabIndex;
663
- };
664
- var sortOrderedTabbables = function sortOrderedTabbables(a, b) {
665
- return a.tabIndex === b.tabIndex ? a.documentOrder - b.documentOrder : a.tabIndex - b.tabIndex;
666
- };
667
- var isInput = function isInput(node) {
668
- return node.tagName === 'INPUT';
669
- };
670
- var isHiddenInput = function isHiddenInput(node) {
671
- return isInput(node) && node.type === 'hidden';
672
559
  };
673
- var isDetailsWithSummary = function isDetailsWithSummary(node) {
674
- var r = node.tagName === 'DETAILS' && Array.prototype.slice.apply(node.children).some(function (child) {
675
- return child.tagName === 'SUMMARY';
676
- });
677
- return r;
678
- };
679
- var getCheckedRadio = function getCheckedRadio(nodes, form) {
680
- for (var i = 0; i < nodes.length; i++) {
681
- if (nodes[i].checked && nodes[i].form === form) {
682
- return nodes[i];
683
- }
560
+ const safeHidePopover = (element) => {
561
+ try {
562
+ element?.hidePopover();
563
+ } catch (e) {
564
+ console.warn(e);
684
565
  }
685
566
  };
686
- var isTabbableRadio = function isTabbableRadio(node) {
687
- if (!node.name) {
688
- return true;
567
+
568
+ function hasWindow() {
569
+ return typeof window !== 'undefined';
570
+ }
571
+ function getNodeName(node) {
572
+ if (isNode(node)) {
573
+ return (node.nodeName || '').toLowerCase();
689
574
  }
690
- var radioScope = node.form || getRootNode(node);
691
- var queryRadios = function queryRadios(name) {
692
- return radioScope.querySelectorAll('input[type="radio"][name="' + name + '"]');
693
- };
694
- var radioSet;
695
- if (typeof window !== 'undefined' && typeof window.CSS !== 'undefined' && typeof window.CSS.escape === 'function') {
696
- radioSet = queryRadios(window.CSS.escape(node.name));
697
- } else {
575
+ // Mocked nodes in testing environments may not be instances of Node. By
576
+ // returning `#document` an infinite loop won't occur.
577
+ // https://github.com/floating-ui/floating-ui/issues/2317
578
+ return '#document';
579
+ }
580
+ function getWindow(node) {
581
+ var _node$ownerDocument;
582
+ return (node == null || (_node$ownerDocument = node.ownerDocument) == null ? void 0 : _node$ownerDocument.defaultView) || window;
583
+ }
584
+ function getDocumentElement(node) {
585
+ var _ref;
586
+ return (_ref = (isNode(node) ? node.ownerDocument : node.document) || window.document) == null ? void 0 : _ref.documentElement;
587
+ }
588
+ function isNode(value) {
589
+ if (!hasWindow()) {
590
+ return false;
591
+ }
592
+ return value instanceof Node || value instanceof getWindow(value).Node;
593
+ }
594
+ function isElement(value) {
595
+ if (!hasWindow()) {
596
+ return false;
597
+ }
598
+ return value instanceof Element || value instanceof getWindow(value).Element;
599
+ }
600
+ function isHTMLElement(value) {
601
+ if (!hasWindow()) {
602
+ return false;
603
+ }
604
+ return value instanceof HTMLElement || value instanceof getWindow(value).HTMLElement;
605
+ }
606
+ function isShadowRoot(value) {
607
+ if (!hasWindow() || typeof ShadowRoot === 'undefined') {
608
+ return false;
609
+ }
610
+ return value instanceof ShadowRoot || value instanceof getWindow(value).ShadowRoot;
611
+ }
612
+ const invalidOverflowDisplayValues = /*#__PURE__*/new Set(['inline', 'contents']);
613
+ function isOverflowElement(element) {
614
+ const {
615
+ overflow,
616
+ overflowX,
617
+ overflowY,
618
+ display
619
+ } = getComputedStyle$1(element);
620
+ return /auto|scroll|overlay|hidden|clip/.test(overflow + overflowY + overflowX) && !invalidOverflowDisplayValues.has(display);
621
+ }
622
+ const tableElements = /*#__PURE__*/new Set(['table', 'td', 'th']);
623
+ function isTableElement(element) {
624
+ return tableElements.has(getNodeName(element));
625
+ }
626
+ const topLayerSelectors = [':popover-open', ':modal'];
627
+ function isTopLayer(element) {
628
+ return topLayerSelectors.some(selector => {
698
629
  try {
699
- radioSet = queryRadios(node.name);
700
- } catch (err) {
701
- // eslint-disable-next-line no-console
702
- console.error('Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s', err.message);
630
+ return element.matches(selector);
631
+ } catch (_e) {
703
632
  return false;
704
633
  }
634
+ });
635
+ }
636
+ const transformProperties = ['transform', 'translate', 'scale', 'rotate', 'perspective'];
637
+ const willChangeValues = ['transform', 'translate', 'scale', 'rotate', 'perspective', 'filter'];
638
+ const containValues = ['paint', 'layout', 'strict', 'content'];
639
+ function isContainingBlock(elementOrCss) {
640
+ const webkit = isWebKit();
641
+ const css = isElement(elementOrCss) ? getComputedStyle$1(elementOrCss) : elementOrCss;
642
+
643
+ // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block
644
+ // https://drafts.csswg.org/css-transforms-2/#individual-transforms
645
+ return transformProperties.some(value => css[value] ? css[value] !== 'none' : false) || (css.containerType ? css.containerType !== 'normal' : false) || !webkit && (css.backdropFilter ? css.backdropFilter !== 'none' : false) || !webkit && (css.filter ? css.filter !== 'none' : false) || willChangeValues.some(value => (css.willChange || '').includes(value)) || containValues.some(value => (css.contain || '').includes(value));
646
+ }
647
+ function getContainingBlock(element) {
648
+ let currentNode = getParentNode(element);
649
+ while (isHTMLElement(currentNode) && !isLastTraversableNode(currentNode)) {
650
+ if (isContainingBlock(currentNode)) {
651
+ return currentNode;
652
+ } else if (isTopLayer(currentNode)) {
653
+ return null;
654
+ }
655
+ currentNode = getParentNode(currentNode);
656
+ }
657
+ return null;
658
+ }
659
+ function isWebKit() {
660
+ if (typeof CSS === 'undefined' || !CSS.supports) return false;
661
+ return CSS.supports('-webkit-backdrop-filter', 'none');
662
+ }
663
+ const lastTraversableNodeNames = /*#__PURE__*/new Set(['html', 'body', '#document']);
664
+ function isLastTraversableNode(node) {
665
+ return lastTraversableNodeNames.has(getNodeName(node));
666
+ }
667
+ function getComputedStyle$1(element) {
668
+ return getWindow(element).getComputedStyle(element);
669
+ }
670
+ function getNodeScroll(element) {
671
+ if (isElement(element)) {
672
+ return {
673
+ scrollLeft: element.scrollLeft,
674
+ scrollTop: element.scrollTop
675
+ };
676
+ }
677
+ return {
678
+ scrollLeft: element.scrollX,
679
+ scrollTop: element.scrollY
680
+ };
681
+ }
682
+ function getParentNode(node) {
683
+ if (getNodeName(node) === 'html') {
684
+ return node;
685
+ }
686
+ const result =
687
+ // Step into the shadow DOM of the parent of a slotted node.
688
+ node.assignedSlot ||
689
+ // DOM Element detected.
690
+ node.parentNode ||
691
+ // ShadowRoot detected.
692
+ isShadowRoot(node) && node.host ||
693
+ // Fallback.
694
+ getDocumentElement(node);
695
+ return isShadowRoot(result) ? result.host : result;
696
+ }
697
+ function getNearestOverflowAncestor(node) {
698
+ const parentNode = getParentNode(node);
699
+ if (isLastTraversableNode(parentNode)) {
700
+ return node.ownerDocument ? node.ownerDocument.body : node.body;
701
+ }
702
+ if (isHTMLElement(parentNode) && isOverflowElement(parentNode)) {
703
+ return parentNode;
704
+ }
705
+ return getNearestOverflowAncestor(parentNode);
706
+ }
707
+ function getOverflowAncestors(node, list, traverseIframes) {
708
+ var _node$ownerDocument2;
709
+ if (list === void 0) {
710
+ list = [];
711
+ }
712
+ if (traverseIframes === void 0) {
713
+ traverseIframes = true;
714
+ }
715
+ const scrollableAncestor = getNearestOverflowAncestor(node);
716
+ const isBody = scrollableAncestor === ((_node$ownerDocument2 = node.ownerDocument) == null ? void 0 : _node$ownerDocument2.body);
717
+ const win = getWindow(scrollableAncestor);
718
+ if (isBody) {
719
+ const frameElement = getFrameElement(win);
720
+ return list.concat(win, win.visualViewport || [], isOverflowElement(scrollableAncestor) ? scrollableAncestor : [], frameElement && traverseIframes ? getOverflowAncestors(frameElement) : []);
705
721
  }
706
- var checked = getCheckedRadio(radioSet, node.form);
707
- return !checked || checked === node;
708
- };
709
- var isRadio = function isRadio(node) {
710
- return isInput(node) && node.type === 'radio';
711
- };
712
- var isNonTabbableRadio = function isNonTabbableRadio(node) {
713
- return isRadio(node) && !isTabbableRadio(node);
714
- };
715
-
716
- // determines if a node is ultimately attached to the window's document
717
- var isNodeAttached = function isNodeAttached(node) {
718
- var _nodeRoot;
719
- // The root node is the shadow root if the node is in a shadow DOM; some document otherwise
720
- // (but NOT _the_ document; see second 'If' comment below for more).
721
- // If rootNode is shadow root, it'll have a host, which is the element to which the shadow
722
- // is attached, and the one we need to check if it's in the document or not (because the
723
- // shadow, and all nodes it contains, is never considered in the document since shadows
724
- // behave like self-contained DOMs; but if the shadow's HOST, which is part of the document,
725
- // is hidden, or is not in the document itself but is detached, it will affect the shadow's
726
- // visibility, including all the nodes it contains). The host could be any normal node,
727
- // or a custom element (i.e. web component). Either way, that's the one that is considered
728
- // part of the document, not the shadow root, nor any of its children (i.e. the node being
729
- // tested).
730
- // To further complicate things, we have to look all the way up until we find a shadow HOST
731
- // that is attached (or find none) because the node might be in nested shadows...
732
- // If rootNode is not a shadow root, it won't have a host, and so rootNode should be the
733
- // document (per the docs) and while it's a Document-type object, that document does not
734
- // appear to be the same as the node's `ownerDocument` for some reason, so it's safer
735
- // to ignore the rootNode at this point, and use `node.ownerDocument`. Otherwise,
736
- // using `rootNode.contains(node)` will _always_ be true we'll get false-positives when
737
- // node is actually detached.
738
- // NOTE: If `nodeRootHost` or `node` happens to be the `document` itself (which is possible
739
- // if a tabbable/focusable node was quickly added to the DOM, focused, and then removed
740
- // from the DOM as in https://github.com/focus-trap/focus-trap-react/issues/905), then
741
- // `ownerDocument` will be `null`, hence the optional chaining on it.
742
- var nodeRoot = node && getRootNode(node);
743
- var nodeRootHost = (_nodeRoot = nodeRoot) === null || _nodeRoot === void 0 ? void 0 : _nodeRoot.host;
722
+ return list.concat(scrollableAncestor, getOverflowAncestors(scrollableAncestor, [], traverseIframes));
723
+ }
724
+ function getFrameElement(win) {
725
+ return win.parent && Object.getPrototypeOf(win.parent) ? win.frameElement : null;
726
+ }
744
727
 
745
- // in some cases, a detached node will return itself as the root instead of a document or
746
- // shadow root object, in which case, we shouldn't try to look further up the host chain
747
- var attached = false;
748
- if (nodeRoot && nodeRoot !== node) {
749
- var _nodeRootHost, _nodeRootHost$ownerDo, _node$ownerDocument;
750
- attached = !!((_nodeRootHost = nodeRootHost) !== null && _nodeRootHost !== void 0 && (_nodeRootHost$ownerDo = _nodeRootHost.ownerDocument) !== null && _nodeRootHost$ownerDo !== void 0 && _nodeRootHost$ownerDo.contains(nodeRootHost) || node !== null && node !== void 0 && (_node$ownerDocument = node.ownerDocument) !== null && _node$ownerDocument !== void 0 && _node$ownerDocument.contains(node));
751
- while (!attached && nodeRootHost) {
752
- var _nodeRoot2, _nodeRootHost2, _nodeRootHost2$ownerD;
753
- // since it's not attached and we have a root host, the node MUST be in a nested shadow DOM,
754
- // which means we need to get the host's host and check if that parent host is contained
755
- // in (i.e. attached to) the document
756
- nodeRoot = getRootNode(nodeRootHost);
757
- nodeRootHost = (_nodeRoot2 = nodeRoot) === null || _nodeRoot2 === void 0 ? void 0 : _nodeRoot2.host;
758
- attached = !!((_nodeRootHost2 = nodeRootHost) !== null && _nodeRootHost2 !== void 0 && (_nodeRootHost2$ownerD = _nodeRootHost2.ownerDocument) !== null && _nodeRootHost2$ownerD !== void 0 && _nodeRootHost2$ownerD.contains(nodeRootHost));
759
- }
728
+ function activeElement(doc) {
729
+ let activeElement = doc.activeElement;
730
+ while (((_activeElement = activeElement) == null || (_activeElement = _activeElement.shadowRoot) == null ? void 0 : _activeElement.activeElement) != null) {
731
+ var _activeElement;
732
+ activeElement = activeElement.shadowRoot.activeElement;
760
733
  }
761
- return attached;
762
- };
763
- var isZeroArea = function isZeroArea(node) {
764
- var _node$getBoundingClie = node.getBoundingClientRect(),
765
- width = _node$getBoundingClie.width,
766
- height = _node$getBoundingClie.height;
767
- return width === 0 && height === 0;
768
- };
769
- var isHidden = function isHidden(node, _ref) {
770
- var displayCheck = _ref.displayCheck,
771
- getShadowRoot = _ref.getShadowRoot;
772
- // NOTE: visibility will be `undefined` if node is detached from the document
773
- // (see notes about this further down), which means we will consider it visible
774
- // (this is legacy behavior from a very long way back)
775
- // NOTE: we check this regardless of `displayCheck="none"` because this is a
776
- // _visibility_ check, not a _display_ check
777
- if (getComputedStyle(node).visibility === 'hidden') {
778
- return true;
734
+ return activeElement;
735
+ }
736
+ function contains(parent, child) {
737
+ if (!parent || !child) {
738
+ return false;
779
739
  }
780
- var isDirectSummary = matches.call(node, 'details>summary:first-of-type');
781
- var nodeUnderDetails = isDirectSummary ? node.parentElement : node;
782
- if (matches.call(nodeUnderDetails, 'details:not([open]) *')) {
740
+ const rootNode = child.getRootNode == null ? void 0 : child.getRootNode();
741
+
742
+ // First, attempt with faster native method
743
+ if (parent.contains(child)) {
783
744
  return true;
784
745
  }
785
- if (!displayCheck || displayCheck === 'full' || displayCheck === 'legacy-full') {
786
- if (typeof getShadowRoot === 'function') {
787
- // figure out if we should consider the node to be in an undisclosed shadow and use the
788
- // 'non-zero-area' fallback
789
- var originalNode = node;
790
- while (node) {
791
- var parentElement = node.parentElement;
792
- var rootNode = getRootNode(node);
793
- if (parentElement && !parentElement.shadowRoot && getShadowRoot(parentElement) === true // check if there's an undisclosed shadow
794
- ) {
795
- // node has an undisclosed shadow which means we can only treat it as a black box, so we
796
- // fall back to a non-zero-area test
797
- return isZeroArea(node);
798
- } else if (node.assignedSlot) {
799
- // iterate up slot
800
- node = node.assignedSlot;
801
- } else if (!parentElement && rootNode !== node.ownerDocument) {
802
- // cross shadow boundary
803
- node = rootNode.host;
804
- } else {
805
- // iterate up normal dom
806
- node = parentElement;
807
- }
808
- }
809
- node = originalNode;
810
- }
811
- // else, `getShadowRoot` might be true, but all that does is enable shadow DOM support
812
- // (i.e. it does not also presume that all nodes might have undisclosed shadows); or
813
- // it might be a falsy value, which means shadow DOM support is disabled
814
-
815
- // Since we didn't find it sitting in an undisclosed shadow (or shadows are disabled)
816
- // now we can just test to see if it would normally be visible or not, provided it's
817
- // attached to the main document.
818
- // NOTE: We must consider case where node is inside a shadow DOM and given directly to
819
- // `isTabbable()` or `isFocusable()` -- regardless of `getShadowRoot` option setting.
820
-
821
- if (isNodeAttached(node)) {
822
- // this works wherever the node is: if there's at least one client rect, it's
823
- // somehow displayed; it also covers the CSS 'display: contents' case where the
824
- // node itself is hidden in place of its contents; and there's no need to search
825
- // up the hierarchy either
826
- return !node.getClientRects().length;
827
- }
828
746
 
829
- // Else, the node isn't attached to the document, which means the `getClientRects()`
830
- // API will __always__ return zero rects (this can happen, for example, if React
831
- // is used to render nodes onto a detached tree, as confirmed in this thread:
832
- // https://github.com/facebook/react/issues/9117#issuecomment-284228870)
833
- //
834
- // It also means that even window.getComputedStyle(node).display will return `undefined`
835
- // because styles are only computed for nodes that are in the document.
836
- //
837
- // NOTE: THIS HAS BEEN THE CASE FOR YEARS. It is not new, nor is it caused by tabbable
838
- // somehow. Though it was never stated officially, anyone who has ever used tabbable
839
- // APIs on nodes in detached containers has actually implicitly used tabbable in what
840
- // was later (as of v5.2.0 on Apr 9, 2021) called `displayCheck="none"` mode -- essentially
841
- // considering __everything__ to be visible because of the innability to determine styles.
842
- //
843
- // v6.0.0: As of this major release, the default 'full' option __no longer treats detached
844
- // nodes as visible with the 'none' fallback.__
845
- if (displayCheck !== 'legacy-full') {
846
- return true; // hidden
747
+ // then fallback to custom implementation with Shadow DOM support
748
+ if (rootNode && isShadowRoot(rootNode)) {
749
+ let next = child;
750
+ while (next) {
751
+ if (parent === next) {
752
+ return true;
753
+ }
754
+ // @ts-ignore
755
+ next = next.parentNode || next.host;
847
756
  }
848
- // else, fallback to 'none' mode and consider the node visible
849
- } else if (displayCheck === 'non-zero-area') {
850
- // NOTE: Even though this tests that the node's client rect is non-zero to determine
851
- // whether it's displayed, and that a detached node will __always__ have a zero-area
852
- // client rect, we don't special-case for whether the node is attached or not. In
853
- // this mode, we do want to consider nodes that have a zero area to be hidden at all
854
- // times, and that includes attached or not.
855
- return isZeroArea(node);
856
757
  }
857
758
 
858
- // visible, as far as we can tell, or per current `displayCheck=none` mode, we assume
859
- // it's visible
759
+ // Give up, the result is false
860
760
  return false;
861
- };
761
+ }
762
+ // Avoid Chrome DevTools blue warning.
763
+ function getPlatform() {
764
+ const uaData = navigator.userAgentData;
765
+ if (uaData != null && uaData.platform) {
766
+ return uaData.platform;
767
+ }
768
+ return navigator.platform;
769
+ }
770
+ function getUserAgent() {
771
+ const uaData = navigator.userAgentData;
772
+ if (uaData && Array.isArray(uaData.brands)) {
773
+ return uaData.brands.map(_ref => {
774
+ let {
775
+ brand,
776
+ version
777
+ } = _ref;
778
+ return brand + "/" + version;
779
+ }).join(' ');
780
+ }
781
+ return navigator.userAgent;
782
+ }
862
783
 
863
- // form fields (nested) inside a disabled fieldset are not focusable/tabbable
864
- // unless they are in the _first_ <legend> element of the top-most disabled
865
- // fieldset
866
- var isDisabledFromFieldset = function isDisabledFromFieldset(node) {
867
- if (/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(node.tagName)) {
868
- var parentNode = node.parentElement;
869
- // check if `node` is contained in a disabled <fieldset>
870
- while (parentNode) {
871
- if (parentNode.tagName === 'FIELDSET' && parentNode.disabled) {
872
- // look for the first <legend> among the children of the disabled <fieldset>
873
- for (var i = 0; i < parentNode.children.length; i++) {
874
- var child = parentNode.children.item(i);
875
- // when the first <legend> (in document order) is found
876
- if (child.tagName === 'LEGEND') {
877
- // if its parent <fieldset> is not nested in another disabled <fieldset>,
878
- // return whether `node` is a descendant of its first <legend>
879
- return matches.call(parentNode, 'fieldset[disabled] *') ? true : !child.contains(node);
880
- }
881
- }
882
- // the disabled <fieldset> containing `node` has no <legend>
883
- return true;
884
- }
885
- parentNode = parentNode.parentElement;
886
- }
784
+ // License: https://github.com/adobe/react-spectrum/blob/b35d5c02fe900badccd0cf1a8f23bb593419f238/packages/@react-aria/utils/src/isVirtualEvent.ts
785
+ function isVirtualClick(event) {
786
+ // FIXME: Firefox is now emitting a deprecation warning for `mozInputSource`.
787
+ // Try to find a workaround for this. `react-aria` source still has the check.
788
+ if (event.mozInputSource === 0 && event.isTrusted) {
789
+ return true;
790
+ }
791
+ if (isAndroid() && event.pointerType) {
792
+ return event.type === 'click' && event.buttons === 1;
793
+ }
794
+ return event.detail === 0 && !event.pointerType;
795
+ }
796
+ function isVirtualPointerEvent(event) {
797
+ if (isJSDOM()) return false;
798
+ return !isAndroid() && event.width === 0 && event.height === 0 || isAndroid() && event.width === 1 && event.height === 1 && event.pressure === 0 && event.detail === 0 && event.pointerType === 'mouse' ||
799
+ // iOS VoiceOver returns 0.333• for width/height.
800
+ event.width < 1 && event.height < 1 && event.pressure === 0 && event.detail === 0 && event.pointerType === 'touch';
801
+ }
802
+ function isSafari() {
803
+ // Chrome DevTools does not complain about navigator.vendor
804
+ return /apple/i.test(navigator.vendor);
805
+ }
806
+ function isAndroid() {
807
+ const re = /android/i;
808
+ return re.test(getPlatform()) || re.test(getUserAgent());
809
+ }
810
+ function isMac() {
811
+ return getPlatform().toLowerCase().startsWith('mac') && !navigator.maxTouchPoints;
812
+ }
813
+ function isJSDOM() {
814
+ return getUserAgent().includes('jsdom/');
815
+ }
816
+ function isMouseLikePointerType(pointerType, strict) {
817
+ // On some Linux machines with Chromium, mouse inputs return a `pointerType`
818
+ // of "pen": https://github.com/floating-ui/floating-ui/issues/2015
819
+ const values = ['mouse', 'pen'];
820
+ if (!strict) {
821
+ values.push('', undefined);
887
822
  }
888
-
889
- // else, node's tabbable/focusable state should not be affected by a fieldset's
890
- // enabled/disabled state
891
- return false;
892
- };
893
- var isNodeMatchingSelectorFocusable = function isNodeMatchingSelectorFocusable(options, node) {
894
- if (node.disabled ||
895
- // we must do an inert look up to filter out any elements inside an inert ancestor
896
- // because we're limited in the type of selectors we can use in JSDom (see related
897
- // note related to `candidateSelectors`)
898
- isInert(node) || isHiddenInput(node) || isHidden(node, options) ||
899
- // For a details element with a summary, the summary element gets the focus
900
- isDetailsWithSummary(node) || isDisabledFromFieldset(node)) {
823
+ return values.includes(pointerType);
824
+ }
825
+ function isReactEvent(event) {
826
+ return 'nativeEvent' in event;
827
+ }
828
+ function isRootElement(element) {
829
+ return element.matches('html,body');
830
+ }
831
+ function getDocument(node) {
832
+ return (node == null ? void 0 : node.ownerDocument) || document;
833
+ }
834
+ function isEventTargetWithin(event, node) {
835
+ if (node == null) {
901
836
  return false;
902
837
  }
903
- return true;
904
- };
905
- var isNodeMatchingSelectorTabbable = function isNodeMatchingSelectorTabbable(options, node) {
906
- if (isNonTabbableRadio(node) || getTabIndex(node) < 0 || !isNodeMatchingSelectorFocusable(options, node)) {
907
- return false;
838
+ if ('composedPath' in event) {
839
+ return event.composedPath().includes(node);
908
840
  }
909
- return true;
910
- };
911
- var isValidShadowRootTabbable = function isValidShadowRootTabbable(shadowHostNode) {
912
- var tabIndex = parseInt(shadowHostNode.getAttribute('tabindex'), 10);
913
- if (isNaN(tabIndex) || tabIndex >= 0) {
914
- return true;
841
+
842
+ // TS thinks `event` is of type never as it assumes all browsers support composedPath, but browsers without shadow dom don't
843
+ const e = event;
844
+ return e.target != null && node.contains(e.target);
845
+ }
846
+ function getTarget(event) {
847
+ if ('composedPath' in event) {
848
+ return event.composedPath()[0];
915
849
  }
916
- // If a custom element has an explicit negative tabindex,
917
- // browsers will not allow tab targeting said element's children.
918
- return false;
919
- };
850
+
851
+ // TS thinks `event` is of type never as it assumes all browsers support
852
+ // `composedPath()`, but browsers without shadow DOM don't.
853
+ return event.target;
854
+ }
855
+ const TYPEABLE_SELECTOR = "input:not([type='hidden']):not([disabled])," + "[contenteditable]:not([contenteditable='false']),textarea:not([disabled])";
856
+ function isTypeableElement(element) {
857
+ return isHTMLElement(element) && element.matches(TYPEABLE_SELECTOR);
858
+ }
859
+ function stopEvent(event) {
860
+ event.preventDefault();
861
+ event.stopPropagation();
862
+ }
863
+ function isTypeableCombobox(element) {
864
+ if (!element) return false;
865
+ return element.getAttribute('role') === 'combobox' && isTypeableElement(element);
866
+ }
920
867
 
921
868
  /**
922
- * @param {Array.<Element|CandidateScope>} candidates
923
- * @returns Element[]
869
+ * Custom positioning reference element.
870
+ * @see https://floating-ui.com/docs/virtual-elements
924
871
  */
925
- var sortByOrder = function sortByOrder(candidates) {
926
- var regularTabbables = [];
927
- var orderedTabbables = [];
928
- candidates.forEach(function (item, i) {
929
- var isScope = !!item.scopeParent;
930
- var element = isScope ? item.scopeParent : item;
931
- var candidateTabindex = getSortOrderTabIndex(element, isScope);
932
- var elements = isScope ? sortByOrder(item.candidates) : element;
933
- if (candidateTabindex === 0) {
934
- isScope ? regularTabbables.push.apply(regularTabbables, elements) : regularTabbables.push(element);
935
- } else {
936
- orderedTabbables.push({
937
- documentOrder: i,
938
- tabIndex: candidateTabindex,
939
- item: item,
940
- isScope: isScope,
941
- content: elements
942
- });
943
- }
944
- });
945
- return orderedTabbables.sort(sortOrderedTabbables).reduce(function (acc, sortable) {
946
- sortable.isScope ? acc.push.apply(acc, sortable.content) : acc.push(sortable.content);
947
- return acc;
948
- }, []).concat(regularTabbables);
872
+
873
+ const min = Math.min;
874
+ const max = Math.max;
875
+ const round = Math.round;
876
+ const floor = Math.floor;
877
+ const createCoords = v => ({
878
+ x: v,
879
+ y: v
880
+ });
881
+ const oppositeSideMap = {
882
+ left: 'right',
883
+ right: 'left',
884
+ bottom: 'top',
885
+ top: 'bottom'
949
886
  };
950
- var tabbable = function tabbable(container, options) {
951
- options = options || {};
952
- var candidates;
953
- if (options.getShadowRoot) {
954
- candidates = getCandidatesIteratively([container], options.includeContainer, {
955
- filter: isNodeMatchingSelectorTabbable.bind(null, options),
956
- flatten: false,
957
- getShadowRoot: options.getShadowRoot,
958
- shadowRootFilter: isValidShadowRootTabbable
959
- });
960
- } else {
961
- candidates = getCandidates(container, options.includeContainer, isNodeMatchingSelectorTabbable.bind(null, options));
962
- }
963
- return sortByOrder(candidates);
887
+ const oppositeAlignmentMap = {
888
+ start: 'end',
889
+ end: 'start'
964
890
  };
965
- var isTabbable = function isTabbable(node, options) {
966
- options = options || {};
967
- if (!node) {
968
- throw new Error('No node provided');
891
+ function clamp(start, value, end) {
892
+ return max(start, min(value, end));
893
+ }
894
+ function evaluate(value, param) {
895
+ return typeof value === 'function' ? value(param) : value;
896
+ }
897
+ function getSide(placement) {
898
+ return placement.split('-')[0];
899
+ }
900
+ function getAlignment(placement) {
901
+ return placement.split('-')[1];
902
+ }
903
+ function getOppositeAxis(axis) {
904
+ return axis === 'x' ? 'y' : 'x';
905
+ }
906
+ function getAxisLength(axis) {
907
+ return axis === 'y' ? 'height' : 'width';
908
+ }
909
+ const yAxisSides = /*#__PURE__*/new Set(['top', 'bottom']);
910
+ function getSideAxis(placement) {
911
+ return yAxisSides.has(getSide(placement)) ? 'y' : 'x';
912
+ }
913
+ function getAlignmentAxis(placement) {
914
+ return getOppositeAxis(getSideAxis(placement));
915
+ }
916
+ function getAlignmentSides(placement, rects, rtl) {
917
+ if (rtl === void 0) {
918
+ rtl = false;
969
919
  }
970
- if (matches.call(node, candidateSelector) === false) {
971
- return false;
920
+ const alignment = getAlignment(placement);
921
+ const alignmentAxis = getAlignmentAxis(placement);
922
+ const length = getAxisLength(alignmentAxis);
923
+ let mainAlignmentSide = alignmentAxis === 'x' ? alignment === (rtl ? 'end' : 'start') ? 'right' : 'left' : alignment === 'start' ? 'bottom' : 'top';
924
+ if (rects.reference[length] > rects.floating[length]) {
925
+ mainAlignmentSide = getOppositePlacement(mainAlignmentSide);
972
926
  }
973
- return isNodeMatchingSelectorTabbable(options, node);
974
- };
927
+ return [mainAlignmentSide, getOppositePlacement(mainAlignmentSide)];
928
+ }
929
+ function getExpandedPlacements(placement) {
930
+ const oppositePlacement = getOppositePlacement(placement);
931
+ return [getOppositeAlignmentPlacement(placement), oppositePlacement, getOppositeAlignmentPlacement(oppositePlacement)];
932
+ }
933
+ function getOppositeAlignmentPlacement(placement) {
934
+ return placement.replace(/start|end/g, alignment => oppositeAlignmentMap[alignment]);
935
+ }
936
+ const lrPlacement = ['left', 'right'];
937
+ const rlPlacement = ['right', 'left'];
938
+ const tbPlacement = ['top', 'bottom'];
939
+ const btPlacement = ['bottom', 'top'];
940
+ function getSideList(side, isStart, rtl) {
941
+ switch (side) {
942
+ case 'top':
943
+ case 'bottom':
944
+ if (rtl) return isStart ? rlPlacement : lrPlacement;
945
+ return isStart ? lrPlacement : rlPlacement;
946
+ case 'left':
947
+ case 'right':
948
+ return isStart ? tbPlacement : btPlacement;
949
+ default:
950
+ return [];
951
+ }
952
+ }
953
+ function getOppositeAxisPlacements(placement, flipAlignment, direction, rtl) {
954
+ const alignment = getAlignment(placement);
955
+ let list = getSideList(getSide(placement), direction === 'start', rtl);
956
+ if (alignment) {
957
+ list = list.map(side => side + "-" + alignment);
958
+ if (flipAlignment) {
959
+ list = list.concat(list.map(getOppositeAlignmentPlacement));
960
+ }
961
+ }
962
+ return list;
963
+ }
964
+ function getOppositePlacement(placement) {
965
+ return placement.replace(/left|right|bottom|top/g, side => oppositeSideMap[side]);
966
+ }
967
+ function expandPaddingObject(padding) {
968
+ return {
969
+ top: 0,
970
+ right: 0,
971
+ bottom: 0,
972
+ left: 0,
973
+ ...padding
974
+ };
975
+ }
976
+ function getPaddingObject(padding) {
977
+ return typeof padding !== 'number' ? expandPaddingObject(padding) : {
978
+ top: padding,
979
+ right: padding,
980
+ bottom: padding,
981
+ left: padding
982
+ };
983
+ }
984
+ function rectToClientRect(rect) {
985
+ const {
986
+ x,
987
+ y,
988
+ width,
989
+ height
990
+ } = rect;
991
+ return {
992
+ width,
993
+ height,
994
+ top: y,
995
+ left: x,
996
+ right: x + width,
997
+ bottom: y + height,
998
+ x,
999
+ y
1000
+ };
1001
+ }
975
1002
 
976
1003
  function computeCoordsFromPlacement(_ref, placement, rtl) {
977
1004
  let {
@@ -1338,16 +1365,22 @@ const flip$2 = function (options) {
1338
1365
  const nextIndex = (((_middlewareData$flip2 = middlewareData.flip) == null ? void 0 : _middlewareData$flip2.index) || 0) + 1;
1339
1366
  const nextPlacement = placements[nextIndex];
1340
1367
  if (nextPlacement) {
1341
- // Try next placement and re-run the lifecycle.
1342
- return {
1343
- data: {
1344
- index: nextIndex,
1345
- overflows: overflowsData
1346
- },
1347
- reset: {
1348
- placement: nextPlacement
1349
- }
1350
- };
1368
+ const ignoreCrossAxisOverflow = checkCrossAxis === 'alignment' ? initialSideAxis !== getSideAxis(nextPlacement) : false;
1369
+ if (!ignoreCrossAxisOverflow ||
1370
+ // We leave the current main axis only if every placement on that axis
1371
+ // overflows the main axis.
1372
+ overflowsData.every(d => getSideAxis(d.placement) === initialSideAxis ? d.overflows[0] > 0 : true)) {
1373
+ // Try next placement and re-run the lifecycle.
1374
+ return {
1375
+ data: {
1376
+ index: nextIndex,
1377
+ overflows: overflowsData
1378
+ },
1379
+ reset: {
1380
+ placement: nextPlacement
1381
+ }
1382
+ };
1383
+ }
1351
1384
  }
1352
1385
 
1353
1386
  // First, find the candidates that fit on the mainAxis side of overflow,
@@ -1393,6 +1426,8 @@ const flip$2 = function (options) {
1393
1426
  };
1394
1427
  };
1395
1428
 
1429
+ const originSides = /*#__PURE__*/new Set(['left', 'top']);
1430
+
1396
1431
  // For type backwards-compatibility, the `OffsetOptions` type was also
1397
1432
  // Derivable.
1398
1433
 
@@ -1406,7 +1441,7 @@ async function convertValueToCoords(state, options) {
1406
1441
  const side = getSide(placement);
1407
1442
  const alignment = getAlignment(placement);
1408
1443
  const isVertical = getSideAxis(placement) === 'y';
1409
- const mainAxisMulti = ['left', 'top'].includes(side) ? -1 : 1;
1444
+ const mainAxisMulti = originSides.has(side) ? -1 : 1;
1410
1445
  const crossAxisMulti = rtl && isVertical ? -1 : 1;
1411
1446
  const rawValue = evaluate(options, state);
1412
1447
 
@@ -1606,7 +1641,7 @@ const limitShift$2 = function (options) {
1606
1641
  if (checkCrossAxis) {
1607
1642
  var _middlewareData$offse, _middlewareData$offse2;
1608
1643
  const len = mainAxis === 'y' ? 'width' : 'height';
1609
- const isOriginSide = ['top', 'left'].includes(getSide(placement));
1644
+ const isOriginSide = originSides.has(getSide(placement));
1610
1645
  const limitMin = rects.reference[crossAxis] - rects.floating[len] + (isOriginSide ? ((_middlewareData$offse = middlewareData.offset) == null ? void 0 : _middlewareData$offse[crossAxis]) || 0 : 0) + (isOriginSide ? 0 : computedOffset.crossAxis);
1611
1646
  const limitMax = rects.reference[crossAxis] + rects.reference[len] + (isOriginSide ? 0 : ((_middlewareData$offse2 = middlewareData.offset) == null ? void 0 : _middlewareData$offse2[crossAxis]) || 0) - (isOriginSide ? computedOffset.crossAxis : 0);
1612
1647
  if (crossAxisCoord < limitMin) {
@@ -1949,6 +1984,7 @@ function getViewportRect(element, strategy) {
1949
1984
  };
1950
1985
  }
1951
1986
 
1987
+ const absoluteOrFixed = /*#__PURE__*/new Set(['absolute', 'fixed']);
1952
1988
  // Returns the inner client rect, subtracting scrollbars if present.
1953
1989
  function getInnerBoundingClientRect(element, strategy) {
1954
1990
  const clientRect = getBoundingClientRect(element, true, strategy === 'fixed');
@@ -2013,7 +2049,7 @@ function getClippingElementAncestors(element, cache) {
2013
2049
  if (!currentNodeIsContaining && computedStyle.position === 'fixed') {
2014
2050
  currentContainingBlockComputedStyle = null;
2015
2051
  }
2016
- const shouldDropCurrentNode = elementIsFixed ? !currentNodeIsContaining && !currentContainingBlockComputedStyle : !currentNodeIsContaining && computedStyle.position === 'static' && !!currentContainingBlockComputedStyle && ['absolute', 'fixed'].includes(currentContainingBlockComputedStyle.position) || isOverflowElement(currentNode) && !currentNodeIsContaining && hasFixedPositionAncestor(element, currentNode);
2052
+ const shouldDropCurrentNode = elementIsFixed ? !currentNodeIsContaining && !currentContainingBlockComputedStyle : !currentNodeIsContaining && computedStyle.position === 'static' && !!currentContainingBlockComputedStyle && absoluteOrFixed.has(currentContainingBlockComputedStyle.position) || isOverflowElement(currentNode) && !currentNodeIsContaining && hasFixedPositionAncestor(element, currentNode);
2017
2053
  if (shouldDropCurrentNode) {
2018
2054
  // Drop non-containing blocks.
2019
2055
  result = result.filter(ancestor => ancestor !== currentNode);
@@ -2076,6 +2112,12 @@ function getRectRelativeToOffsetParent(element, offsetParent, strategy) {
2076
2112
  scrollTop: 0
2077
2113
  };
2078
2114
  const offsets = createCoords(0);
2115
+
2116
+ // If the <body> scrollbar appears on the left (e.g. RTL systems). Use
2117
+ // Firefox with layout.scrollbar.side = 3 in about:config to test this.
2118
+ function setLeftRTLScrollbarOffset() {
2119
+ offsets.x = getWindowScrollBarX(documentElement);
2120
+ }
2079
2121
  if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {
2080
2122
  if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {
2081
2123
  scroll = getNodeScroll(offsetParent);
@@ -2085,11 +2127,12 @@ function getRectRelativeToOffsetParent(element, offsetParent, strategy) {
2085
2127
  offsets.x = offsetRect.x + offsetParent.clientLeft;
2086
2128
  offsets.y = offsetRect.y + offsetParent.clientTop;
2087
2129
  } else if (documentElement) {
2088
- // If the <body> scrollbar appears on the left (e.g. RTL systems). Use
2089
- // Firefox with layout.scrollbar.side = 3 in about:config to test this.
2090
- offsets.x = getWindowScrollBarX(documentElement);
2130
+ setLeftRTLScrollbarOffset();
2091
2131
  }
2092
2132
  }
2133
+ if (isFixed && !isOffsetParentAnElement && documentElement) {
2134
+ setLeftRTLScrollbarOffset();
2135
+ }
2093
2136
  const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);
2094
2137
  const x = rect.left + scroll.scrollLeft - offsets.x - htmlOffset.x;
2095
2138
  const y = rect.top + scroll.scrollTop - offsets.y - htmlOffset.y;
@@ -2266,7 +2309,7 @@ function observeMove(element, onMove) {
2266
2309
  // Handle <iframe>s
2267
2310
  root: root.ownerDocument
2268
2311
  });
2269
- } catch (e) {
2312
+ } catch (_e) {
2270
2313
  io = new IntersectionObserver(handleObserve, options);
2271
2314
  }
2272
2315
  io.observe(element);
@@ -2421,7 +2464,10 @@ const computePosition = (reference, floating, options) => {
2421
2464
  });
2422
2465
  };
2423
2466
 
2424
- var index$1 = typeof document !== 'undefined' ? useLayoutEffect : useEffect;
2467
+ var isClient = typeof document !== 'undefined';
2468
+
2469
+ var noop = function noop() {};
2470
+ var index$1 = isClient ? useLayoutEffect : noop;
2425
2471
 
2426
2472
  // Fork of `fast-deep-equal` that only does the comparisons we need and compares
2427
2473
  // functions
@@ -6528,5 +6574,9 @@ function safePolygon(options) {
6528
6574
  return fn;
6529
6575
  }
6530
6576
 
6531
- export { FloatingTree as A, tabbable as B, useDelayGroup as C, useDelayGroupContext as D, useFocus as E, FloatingPortal as F, FloatingFocusManager as a, FloatingArrow as b, useFloating as c, shift as d, arrow as e, flip as f, useClick as g, useHover as h, safePolygon as i, useDismiss as j, useRole as k, limitShift as l, useInteractions as m, autoUpdate as n, offset as o, computePosition as p, useListItem as q, useFloatingTree as r, size as s, useFloatingNodeId as t, useMergeRefs as u, useFloatingParentNodeId as v, useListNavigation as w, useTypeahead as x, FloatingNode as y, FloatingList as z };
6532
- //# sourceMappingURL=floating-ui.react-BFNinq1w.js.map
6577
+ const DialogContext = createContext(null);
6578
+
6579
+ const DrawerContext = createContext(null);
6580
+
6581
+ export { autoUpdate as A, computePosition as B, safeShowPopover as C, DialogContext as D, safeHidePopover as E, FloatingTree as F, useDelayGroup as G, FloatingArrow as H, useDelayGroupContext as I, arrow as J, useFocus as K, DrawerContext as a, useListItem as b, useFloatingTree as c, useFloatingParentNodeId as d, useFloatingNodeId as e, useFloating as f, flip as g, shift as h, size as i, useHover as j, safePolygon as k, limitShift as l, useClick as m, useRole as n, offset as o, useDismiss as p, useListNavigation as q, useTypeahead as r, supportsPopover as s, tabbable as t, useMergeRefs as u, useInteractions as v, FloatingNode as w, FloatingList as x, FloatingPortal as y, FloatingFocusManager as z };
6582
+ //# sourceMappingURL=DrawerContext-DboTgTmo.js.map