twenty-ui 2.48.0 → 2.50.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (286) hide show
  1. package/CHANGELOG.md +18 -0
  2. package/README.md +27 -2
  3. package/dist/Button-CU8BS-Yd.js +75 -0
  4. package/dist/Button-iVyxlrwO.cjs +1 -0
  5. package/dist/Dropdown-ChTVyesF.js +1018 -0
  6. package/dist/Dropdown-DlItz8Gh.cjs +1 -0
  7. package/dist/Heading-CHvEXL6n.cjs +1 -0
  8. package/dist/{Heading-pXllCJCO.js → Heading-Nj5BlPqB.js} +3 -3
  9. package/dist/{ListItem-CHTR-GLd.cjs → ListItem-C6Xl00m1.cjs} +1 -1
  10. package/dist/{ListItem-CjnrSbka.js → ListItem-C84ANa76.js} +2 -2
  11. package/dist/{OverflowingTextWithTooltip-Z2daM0_x.cjs → OverflowingTextWithTooltip-BQmpPObX.cjs} +1 -1
  12. package/dist/{OverflowingTextWithTooltip-BmUROIah.js → OverflowingTextWithTooltip-BtB9cGdJ.js} +20 -21
  13. package/dist/ProgressBar-CzGs7cuE.cjs +1 -0
  14. package/dist/ProgressBar-D4tKQ7OA.js +84 -0
  15. package/dist/{Radio-DMI1B7o5.js → Radio-BwBZ4e8g.js} +29 -29
  16. package/dist/{Radio-xmHgGHQO.cjs → Radio-sIYxZnR_.cjs} +1 -1
  17. package/dist/ResizeHandle-B1MuHTNA.cjs +1 -0
  18. package/dist/{ResizeHandle-C1kQ3MYR.js → ResizeHandle-B30OYZxS.js} +56 -55
  19. package/dist/Shortcut-Bp9iDdQg.js +73 -0
  20. package/dist/Shortcut-N8TELGPI.cjs +1 -0
  21. package/dist/TabsTabContent-6rkARU9F.cjs +1 -0
  22. package/dist/TabsTabContent-DPkLTBi2.js +39 -0
  23. package/dist/Tooltip-6uS8_wdA.js +132 -0
  24. package/dist/Tooltip-DL3sfbuw.cjs +1 -0
  25. package/dist/components/__stories__/reading-direction/DirectionalLayoutExample.d.ts +3 -1
  26. package/dist/components/code-editor.cjs +1 -1
  27. package/dist/components/code-editor.mjs +52 -51
  28. package/dist/components/data-display.cjs +1 -1
  29. package/dist/components/data-display.mjs +6 -7
  30. package/dist/components/feedback/InlineBanner/InlineBanner.d.ts +2 -2
  31. package/dist/components/feedback/InlineBanner/internal/InlineBannerComponent.d.ts +1 -1
  32. package/dist/components/feedback/InlineBanner/types/InlineBannerProps.d.ts +1 -0
  33. package/dist/components/feedback.cjs +1 -1
  34. package/dist/components/feedback.mjs +1 -1
  35. package/dist/components/input/CountrySelect/CountrySelect.d.ts +5 -2
  36. package/dist/components/input/CountrySelect/__stories__/CountrySelectPartsExample.d.ts +11 -0
  37. package/dist/components/input/CountrySelect/internal/CountrySelectComponent.d.ts +2 -0
  38. package/dist/components/input/CountrySelect/internal/CountrySelectContext.d.ts +2 -0
  39. package/dist/components/input/CountrySelect/internal/CountrySelectContextValue.d.ts +11 -0
  40. package/dist/components/input/CountrySelect/internal/CountrySelectDropdown.d.ts +4 -0
  41. package/dist/components/input/CountrySelect/internal/CountrySelectOptions.d.ts +2 -11
  42. package/dist/components/input/CountrySelect/internal/CountrySelectOptionsContent.d.ts +2 -0
  43. package/dist/components/input/CountrySelect/internal/CountrySelectRoot.d.ts +2 -0
  44. package/dist/components/input/CountrySelect/internal/CountrySelectTrigger.d.ts +2 -0
  45. package/dist/components/input/CountrySelect/internal/NO_COUNTRY_SELECTION_VALUE.d.ts +1 -0
  46. package/dist/components/input/CountrySelect/internal/PreparedCountryChoice.d.ts +5 -0
  47. package/dist/components/input/CountrySelect/internal/getCountrySelectionValue.d.ts +1 -0
  48. package/dist/components/input/CountrySelect/internal/useCountrySelectContextOrThrow.d.ts +1 -0
  49. package/dist/components/input/CountrySelect/types/CountryChoice.d.ts +1 -0
  50. package/dist/components/input/CountrySelect/types/CountrySelectOptionsProps.d.ts +10 -0
  51. package/dist/components/input/CountrySelect/types/CountrySelectOptionsState.d.ts +4 -0
  52. package/dist/components/input/CountrySelect/types/CountrySelectProps.d.ts +7 -13
  53. package/dist/components/input/CountrySelect/types/CountrySelectRootProps.d.ts +12 -0
  54. package/dist/components/input/CountrySelect/types/CountrySelectTriggerProps.d.ts +6 -0
  55. package/dist/components/input/CurrencyPicker/CurrencyPicker.d.ts +4 -3
  56. package/dist/components/input/CurrencyPicker/__stories__/CurrencyPickerChangingDefaultExample.d.ts +5 -0
  57. package/dist/components/input/CurrencyPicker/__stories__/CurrencyPickerControlledExample.d.ts +5 -0
  58. package/dist/components/input/CurrencyPicker/__stories__/CurrencyPickerControlledSearchExample.d.ts +5 -0
  59. package/dist/components/input/CurrencyPicker/__stories__/CurrencyPickerExample.d.ts +3 -4
  60. package/dist/components/input/CurrencyPicker/__stories__/CurrencyPickerListLabelExample.d.ts +1 -0
  61. package/dist/components/input/CurrencyPicker/__stories__/CurrencyPickerRootStateExample.d.ts +1 -0
  62. package/dist/components/input/CurrencyPicker/internal/CurrencyPickerContext.d.ts +11 -0
  63. package/dist/components/input/CurrencyPicker/internal/CurrencyPickerOptions.d.ts +1 -1
  64. package/dist/components/input/CurrencyPicker/internal/CurrencyPickerRoot.d.ts +2 -0
  65. package/dist/components/input/CurrencyPicker/internal/CurrencyPickerShorthand.d.ts +2 -0
  66. package/dist/components/input/CurrencyPicker/internal/CurrencyPickerTrigger.d.ts +1 -1
  67. package/dist/components/input/CurrencyPicker/internal/PreparedCurrencyPickerOption.d.ts +7 -0
  68. package/dist/components/input/CurrencyPicker/internal/getCurrencyPickerSearchText.d.ts +2 -0
  69. package/dist/components/input/CurrencyPicker/internal/useCurrencyPickerContextOrThrow.d.ts +7 -0
  70. package/dist/components/input/CurrencyPicker/types/CurrencyPickerChangeEventDetails.d.ts +2 -0
  71. package/dist/components/input/CurrencyPicker/types/CurrencyPickerOption.d.ts +1 -0
  72. package/dist/components/input/CurrencyPicker/types/CurrencyPickerOptionsProps.d.ts +6 -5
  73. package/dist/components/input/CurrencyPicker/types/CurrencyPickerProps.d.ts +10 -0
  74. package/dist/components/input/CurrencyPicker/types/CurrencyPickerRootProps.d.ts +17 -0
  75. package/dist/components/input/CurrencyPicker/types/CurrencyPickerState.d.ts +6 -0
  76. package/dist/components/input/CurrencyPicker/types/CurrencyPickerTriggerProps.d.ts +3 -2
  77. package/dist/components/input/IconButton/__stories__/IconButtonExample.d.ts +7 -0
  78. package/dist/components/input/PhoneCountryPicker/PhoneCountryPicker.d.ts +5 -3
  79. package/dist/components/input/PhoneCountryPicker/__stories__/PhoneCountryPickerExample.d.ts +7 -3
  80. package/dist/components/input/PhoneCountryPicker/__stories__/testDisabledPhoneCountryPicker.d.ts +5 -0
  81. package/dist/components/input/PhoneCountryPicker/__stories__/testPhoneCountryCallingCodeDirection.d.ts +3 -0
  82. package/dist/components/input/PhoneCountryPicker/__stories__/testPhoneCountryNullSelection.d.ts +5 -0
  83. package/dist/components/input/PhoneCountryPicker/__stories__/testPhoneCountrySelection.d.ts +5 -0
  84. package/dist/components/input/PhoneCountryPicker/internal/PhoneCountryPickerContext.d.ts +9 -0
  85. package/dist/components/input/PhoneCountryPicker/internal/PhoneCountryPickerOptions.d.ts +1 -1
  86. package/dist/components/input/PhoneCountryPicker/internal/PhoneCountryPickerRoot.d.ts +2 -0
  87. package/dist/components/input/PhoneCountryPicker/internal/PhoneCountryPickerTrigger.d.ts +1 -1
  88. package/dist/components/input/PhoneCountryPicker/internal/PreparedPhoneCountryOption.d.ts +5 -0
  89. package/dist/components/input/PhoneCountryPicker/internal/getPhoneCountryOptionTooltipLabel.d.ts +2 -0
  90. package/dist/components/input/PhoneCountryPicker/internal/matchesPhoneCountrySearch.d.ts +6 -0
  91. package/dist/components/input/PhoneCountryPicker/internal/usePhoneCountryPickerContextOrThrow.d.ts +7 -0
  92. package/dist/components/input/PhoneCountryPicker/types/PhoneCountryOption.d.ts +1 -0
  93. package/dist/components/input/PhoneCountryPicker/types/PhoneCountryPickerOptionsProps.d.ts +4 -5
  94. package/dist/components/input/PhoneCountryPicker/types/PhoneCountryPickerProps.d.ts +10 -0
  95. package/dist/components/input/PhoneCountryPicker/types/PhoneCountryPickerRootProps.d.ts +12 -0
  96. package/dist/components/input/PhoneCountryPicker/types/PhoneCountryPickerTriggerProps.d.ts +1 -3
  97. package/dist/components/input/SegmentedControl/types/SegmentedControlProps.d.ts +1 -1
  98. package/dist/components/input/index.d.ts +10 -0
  99. package/dist/components/input.cjs +1 -1
  100. package/dist/components/input.mjs +13 -13
  101. package/dist/components/layout/OverflowingList/internal/measureItemWidths.d.ts +1 -2
  102. package/dist/components/layout/OverflowingList/internal/measureOverflowingListLayout.d.ts +1 -2
  103. package/dist/components/layout.cjs +1 -1
  104. package/dist/components/layout.mjs +1 -1
  105. package/dist/components/navigation/Dropdown/Dropdown.d.ts +3 -2
  106. package/dist/components/navigation/Dropdown/__stories__/DropdownIconGridExample.d.ts +3 -0
  107. package/dist/components/navigation/Dropdown/__stories__/DropdownSelectionGroupsExample.d.ts +1 -0
  108. package/dist/components/navigation/Dropdown/internal/DropdownContextValue.d.ts +6 -1
  109. package/dist/components/navigation/Dropdown/internal/DropdownOptionItem.d.ts +1 -1
  110. package/dist/components/navigation/Dropdown/internal/DropdownOptionItemOwner.d.ts +7 -0
  111. package/dist/components/navigation/Dropdown/internal/DropdownSearch.d.ts +1 -1
  112. package/dist/components/navigation/Dropdown/internal/DropdownSearchEffect.d.ts +8 -0
  113. package/dist/components/navigation/Dropdown/internal/DropdownSelectionContext.d.ts +2 -0
  114. package/dist/components/navigation/Dropdown/internal/DropdownSelectionContextValue.d.ts +9 -0
  115. package/dist/components/navigation/Dropdown/internal/DropdownSelectionGroup.d.ts +2 -0
  116. package/dist/components/navigation/Dropdown/internal/DropdownSelectionGroupEffect.d.ts +11 -0
  117. package/dist/components/navigation/Dropdown/internal/createDropdownSelectionEventDetails.d.ts +5 -0
  118. package/dist/components/navigation/Dropdown/internal/dropdownItemActivation.d.ts +11 -0
  119. package/dist/components/navigation/Dropdown/internal/getDropdownItemExplicitId.d.ts +2 -2
  120. package/dist/components/navigation/Dropdown/internal/getDropdownOptionItemRole.d.ts +9 -0
  121. package/dist/components/navigation/Dropdown/internal/getDropdownSelectionGroupState.d.ts +6 -0
  122. package/dist/components/navigation/Dropdown/internal/getTrailingFocusGuard.d.ts +1 -0
  123. package/dist/components/navigation/Dropdown/internal/isDropdownOptionItemSelected.d.ts +6 -0
  124. package/dist/components/navigation/Dropdown/internal/useDropdownSelections.d.ts +12 -0
  125. package/dist/components/navigation/Dropdown/types/DropdownOptionItemProps.d.ts +7 -2
  126. package/dist/components/navigation/Dropdown/types/DropdownOptionItemSelectEventDetails.d.ts +2 -0
  127. package/dist/components/navigation/Dropdown/types/DropdownOptionItemState.d.ts +5 -0
  128. package/dist/components/navigation/Dropdown/types/DropdownSelectionGroupChangeEventDetails.d.ts +7 -0
  129. package/dist/components/navigation/Dropdown/types/DropdownSelectionGroupProps.d.ts +21 -0
  130. package/dist/components/navigation/Dropdown/types/DropdownSelectionGroupState.d.ts +7 -0
  131. package/dist/components/navigation/index.d.ts +5 -11
  132. package/dist/components/navigation.cjs +1 -1
  133. package/dist/components/navigation.mjs +6 -11
  134. package/dist/components/settings.cjs +1 -1
  135. package/dist/components/settings.mjs +1 -1
  136. package/dist/components.cjs +1 -1
  137. package/dist/components.mjs +37 -43
  138. package/dist/data-display-C-eoJ5En.js +378 -0
  139. package/dist/data-display-CM1yXpnE.cjs +2 -0
  140. package/dist/data-display-CXw-mxeS.js +252 -0
  141. package/dist/data-display-DdES9XqZ.cjs +1 -0
  142. package/dist/doNotTranslate-BSVT8Xyd.js +4 -0
  143. package/dist/doNotTranslate-CHE7WmRS.cjs +1 -0
  144. package/dist/feedback-4HKPcMRs.js +666 -0
  145. package/dist/feedback-BSOWDBI0.js +38 -0
  146. package/dist/feedback-DBRXDPSP.cjs +1 -0
  147. package/dist/feedback-DspXawf9.cjs +1 -0
  148. package/dist/index.cjs +1 -1
  149. package/dist/index.mjs +625 -631
  150. package/dist/input-CWWp7cqL.cjs +1 -0
  151. package/dist/input-CvZ_uB_9.cjs +1 -0
  152. package/dist/input-Qn5_aFYU.js +785 -0
  153. package/dist/input-k5cMhFI_.js +428 -0
  154. package/dist/layout-DDqeMgFv.js +439 -0
  155. package/dist/layout-iSfGrMrH.cjs +1 -0
  156. package/dist/navigation-7Y6gHFlj.cjs +1 -0
  157. package/dist/navigation-BY8X2w04.js +132 -0
  158. package/dist/navigation-BcXCiLE1.js +86 -0
  159. package/dist/navigation-ByYN6NgX.cjs +1 -0
  160. package/dist/normalizeSearchText-DLmPiBUZ.js +19 -0
  161. package/dist/normalizeSearchText-Do0MELpQ.cjs +1 -0
  162. package/dist/preventDismissingClickActivation-BEBrL9aB.cjs +1 -0
  163. package/dist/preventDismissingClickActivation-BQFMKRey.js +29 -0
  164. package/dist/primitives/accessibility.cjs +1 -1
  165. package/dist/primitives/accessibility.mjs +1 -1
  166. package/dist/primitives/data-display/Avatar/constants/AvatarPropertiesBySize.d.ts +4 -0
  167. package/dist/primitives/data-display/Avatar/types/AvatarSize.d.ts +1 -1
  168. package/dist/primitives/data-display/Badge/types/BadgeColor.d.ts +1 -1
  169. package/dist/primitives/data-display/Chip/types/ChipVariant.d.ts +1 -1
  170. package/dist/primitives/data-display.cjs +1 -1
  171. package/dist/primitives/data-display.mjs +7 -8
  172. package/dist/primitives/feedback/Banner/Banner.d.ts +1 -1
  173. package/dist/primitives/feedback/Banner/internal/BannerAction.d.ts +1 -1
  174. package/dist/primitives/feedback.cjs +1 -1
  175. package/dist/primitives/feedback.mjs +2 -2
  176. package/dist/primitives/input/Autocomplete/Autocomplete.d.ts +1 -1
  177. package/dist/primitives/input/Autocomplete/internal/AutocompleteInput.d.ts +1 -1
  178. package/dist/primitives/input/Autocomplete/types/AutocompleteInputProps.d.ts +8 -1
  179. package/dist/primitives/input/Button/types/ButtonColor.d.ts +1 -1
  180. package/dist/primitives/input/Radio/__stories__/RadioCardContent.d.ts +8 -0
  181. package/dist/primitives/input/RadioGroup/RadioGroup.d.ts +1 -1
  182. package/dist/primitives/input/RadioGroup/types/RadioGroupProps.d.ts +3 -1
  183. package/dist/primitives/input.cjs +1 -1
  184. package/dist/primitives/input.mjs +3 -3
  185. package/dist/primitives/layout/ResizeHandle/__stories__/ResizableNotesExample.d.ts +2 -0
  186. package/dist/primitives/layout.cjs +1 -1
  187. package/dist/primitives/layout.mjs +1 -1
  188. package/dist/primitives/navigation/Tabs/types/TabsSize.d.ts +1 -1
  189. package/dist/primitives/navigation.cjs +1 -1
  190. package/dist/primitives/navigation.mjs +2 -2
  191. package/dist/primitives/surfaces/Card/Card.d.ts +1 -1
  192. package/dist/primitives/surfaces/Card/internal/CardRoot.d.ts +1 -1
  193. package/dist/primitives/surfaces/Card/types/CardRootProps.d.ts +0 -1
  194. package/dist/primitives/surfaces/Tooltip/Tooltip.d.ts +1 -0
  195. package/dist/primitives/surfaces/Tooltip/__stories__/findTooltip.d.ts +1 -0
  196. package/dist/primitives/surfaces/Tooltip/internal/TooltipBody.d.ts +2 -8
  197. package/dist/primitives/surfaces/Tooltip/types/TooltipBodyProps.d.ts +6 -0
  198. package/dist/primitives/surfaces/index.d.ts +1 -0
  199. package/dist/primitives/surfaces.cjs +1 -1
  200. package/dist/primitives/surfaces.mjs +2 -2
  201. package/dist/primitives/typography/Heading/types/HeadingProps.d.ts +1 -1
  202. package/dist/primitives/typography.cjs +1 -1
  203. package/dist/primitives/typography.mjs +4 -4
  204. package/dist/primitives.cjs +1 -1
  205. package/dist/primitives.mjs +46 -47
  206. package/dist/{settings-BAYsnlZJ.cjs → settings-DT5bEO6A.cjs} +1 -1
  207. package/dist/{settings-BjEZiHXE.js → settings-XGSJtobU.js} +1 -1
  208. package/dist/style.css +1 -1
  209. package/dist/surfaces-q8voTXEJ.cjs +1 -0
  210. package/dist/{surfaces-BLsR5ka0.js → surfaces-vhSZBmbz.js} +77 -78
  211. package/dist/testing/GroupedCatalog.d.ts +14 -0
  212. package/dist/testing/index.d.ts +2 -0
  213. package/dist/testing/utils/waitForStorybookFontsLoaded.d.ts +1 -0
  214. package/dist/testing.cjs +1 -1
  215. package/dist/testing.mjs +102 -62
  216. package/dist/{typography-fOTFr0jS.js → typography-BPdXzW2T.js} +2 -2
  217. package/dist/{typography-B5QEuPaL.cjs → typography-CWtuNruY.cjs} +1 -1
  218. package/dist/useIsMobile-Byp9AIq-.cjs +1 -0
  219. package/dist/useIsMobile-D1ImfQnE.js +38 -0
  220. package/dist/utilities/internal/doNotTranslate.d.ts +1 -0
  221. package/dist/utilities-BKCMZyqZ.js +53 -0
  222. package/dist/utilities-xZh8D2gd.cjs +1 -0
  223. package/dist/utilities.cjs +1 -1
  224. package/dist/utilities.mjs +11 -10
  225. package/package.json +3 -3
  226. package/dist/Avatar-CQhIEazb.cjs +0 -1
  227. package/dist/Avatar-D-QA0RE5.js +0 -72
  228. package/dist/Button-D5enZ0Qz.js +0 -72
  229. package/dist/Button-Dbi5P05r.cjs +0 -1
  230. package/dist/Dropdown-BKjAaZS0.cjs +0 -1
  231. package/dist/Dropdown-C2hXrjvD.js +0 -820
  232. package/dist/Heading-CTRYClCO.cjs +0 -1
  233. package/dist/ProgressBar-BvT1dyFo.js +0 -84
  234. package/dist/ProgressBar-DfFz0fFB.cjs +0 -1
  235. package/dist/ResizeHandle-DI4LHIQm.cjs +0 -1
  236. package/dist/Shortcut-BvWUZ3pb.js +0 -72
  237. package/dist/Shortcut-CgrdLv_L.cjs +0 -1
  238. package/dist/TabsTabContent-Co27Y2TU.cjs +0 -1
  239. package/dist/TabsTabContent-DVcObDp6.js +0 -39
  240. package/dist/TintedIconTile-4BGa8g8n.js +0 -40
  241. package/dist/TintedIconTile-CU2hCerq.cjs +0 -1
  242. package/dist/Tooltip-Bg9Uk01p.cjs +0 -1
  243. package/dist/Tooltip-cLCgtFBF.js +0 -124
  244. package/dist/components/navigation/MenuItem/MenuItem.d.ts +0 -2
  245. package/dist/components/navigation/MenuItem/parts/MenuItemIcon.d.ts +0 -9
  246. package/dist/components/navigation/MenuItem/parts/MenuItemIconBoxContainer.d.ts +0 -7
  247. package/dist/components/navigation/MenuItem/parts/MenuItemIconWithGripSwap.d.ts +0 -8
  248. package/dist/components/navigation/MenuItem/parts/MenuItemLeftContent.d.ts +0 -19
  249. package/dist/components/navigation/MenuItem/parts/StyledMenuItemBase.d.ts +0 -25
  250. package/dist/components/navigation/MenuItem/types/MenuItemDraggableGripMode.d.ts +0 -1
  251. package/dist/components/navigation/MenuItem/types/MenuItemProps.d.ts +0 -33
  252. package/dist/components/navigation/MenuItemAvatar/MenuItemAvatar.d.ts +0 -2
  253. package/dist/components/navigation/MenuItemAvatar/types/MenuItemAvatarProps.d.ts +0 -18
  254. package/dist/components/navigation/MenuItemDraggable/MenuItemDraggable.d.ts +0 -2
  255. package/dist/components/navigation/MenuItemDraggable/types/MenuItemDraggableProps.d.ts +0 -20
  256. package/dist/components/navigation/MenuItemSuggestion/MenuItemSuggestion.d.ts +0 -2
  257. package/dist/components/navigation/MenuItemSuggestion/types/MenuItemSuggestionProps.d.ts +0 -12
  258. package/dist/components/navigation/MenuPicker/MenuPicker.d.ts +0 -2
  259. package/dist/components/navigation/MenuPicker/types/MenuPickerProps.d.ts +0 -15
  260. package/dist/data-display-0QO_WDSs.js +0 -183
  261. package/dist/data-display-CPmTJAWJ.cjs +0 -1
  262. package/dist/data-display-DjhAHvj1.cjs +0 -2
  263. package/dist/data-display-KyZbLLy-.js +0 -344
  264. package/dist/feedback-CM6fatE8.js +0 -664
  265. package/dist/feedback-DA-AU5z5.js +0 -38
  266. package/dist/feedback-DNLERYY9.cjs +0 -1
  267. package/dist/feedback-ybO4n69s.cjs +0 -1
  268. package/dist/input-3D2lXywH.cjs +0 -1
  269. package/dist/input-CJDYNwoO.cjs +0 -1
  270. package/dist/input-DRpDiMRi.js +0 -421
  271. package/dist/input-TM3nUdu6.js +0 -554
  272. package/dist/layout-BszCDxAO.js +0 -441
  273. package/dist/layout-VaIq7Sjr.cjs +0 -1
  274. package/dist/navigation-B1SRvzKK.js +0 -403
  275. package/dist/navigation-CYAs2LnR.js +0 -131
  276. package/dist/navigation-CthkGHJ8.cjs +0 -1
  277. package/dist/navigation-DrOV5E67.cjs +0 -1
  278. package/dist/preventDismissingClickActivation-CzWqpjiX.js +0 -44
  279. package/dist/preventDismissingClickActivation-DZxTSLV3.cjs +0 -1
  280. package/dist/surfaces-0rL5DoHt.cjs +0 -1
  281. package/dist/useIsMobile-DxOPI2_E.cjs +0 -1
  282. package/dist/useIsMobile-nrufFzMb.js +0 -37
  283. package/dist/utilities-BeLfNQ0Q.cjs +0 -1
  284. package/dist/utilities-CEi9I09B.js +0 -52
  285. /package/dist/{handleClickableElementKeyDown-C8Uz61XJ.js → accessibility-C8Uz61XJ.js} +0 -0
  286. /package/dist/{handleClickableElementKeyDown-CByqtBhO.cjs → accessibility-CByqtBhO.cjs} +0 -0
@@ -0,0 +1,666 @@
1
+ import { t as d } from "./isDefined-fMi6eQ4r.js";
2
+ import { Ta as Z, gl as ee, hc as _e, la as he, nt as M } from "./icon-CUE-QGQK.js";
3
+ import { t as I } from "./doNotTranslate-BSVT8Xyd.js";
4
+ import { a as Te, r as ge, t as Ce } from "./theme-B2EaXhye.js";
5
+ import { t as be } from "./mergeClassNames-ClFMR1v0.js";
6
+ import { t as z } from "./Button-CU8BS-Yd.js";
7
+ import { n as te, r as we, t as xe } from "./ProgressBar-D4tKQ7OA.js";
8
+ import { t as y } from "./isRenderableSlot-DT_depzM.js";
9
+ import { t as ye } from "./useProvidedTextDirection-Dk8LBQeF.js";
10
+ import { t as Ae } from "./OverflowingTextWithTooltip-BtB9cGdJ.js";
11
+ import { t as Ne } from "./Separator-0LzwPfOn.js";
12
+ import { useRender as D } from "@base-ui/react/use-render";
13
+ import { isNonEmptyArray as $, isPositiveInteger as Ee, isString as Pe, isUndefined as Ie } from "@sniptt/guards";
14
+ import { clsx as k } from "clsx";
15
+ import { createContext as oe, useCallback as Re, useContext as j, useEffect as Se, useLayoutEffect as R, useMemo as ke, useRef as We, useState as P, useSyncExternalStore as Oe } from "react";
16
+ import { Fragment as S, jsx as c, jsxs as g } from "react/jsx-runtime";
17
+ import { Store as ze, useStore as qe } from "@base-ui/utils/store";
18
+ import { createPortal as Be } from "react-dom";
19
+ var Me = "_action_3r2bm_1", Fe = { action: Me }, De = ({ className: e, ...t }) => /* @__PURE__ */ c(z, {
20
+ ...t,
21
+ size: "sm",
22
+ variant: "ghost",
23
+ className: be(Fe.action, e)
24
+ }), $e = "_container_1ix4w_1", je = "_containerFullWidth_1ix4w_40", Ue = "_header_1ix4w_44", Le = "_iconContainer_1ix4w_53", Ke = "_title_1ix4w_63", He = "_descriptionWrapper_1ix4w_75", Ve = "_descriptionWrapperWithIcon_1ix4w_82", Xe = "_descriptionWrapperWithAction_1ix4w_86", Ge = "_description_1ix4w_75", Je = "_footer_1ix4w_99", Qe = "_closeButton_1ix4w_106", T = {
25
+ container: $e,
26
+ containerFullWidth: je,
27
+ header: Ue,
28
+ iconContainer: Le,
29
+ title: Ke,
30
+ descriptionWrapper: He,
31
+ descriptionWrapperWithIcon: Ve,
32
+ descriptionWrapperWithAction: Xe,
33
+ description: Ge,
34
+ footer: Je,
35
+ closeButton: Qe
36
+ }, Ye = ({ status: e = "info", variant: t = "soft", color: o = we[e], title: s, description: r, fullWidth: a = !1, icon: n = /* @__PURE__ */ c(he, {
37
+ size: Te.icon.size.md,
38
+ "aria-hidden": "true"
39
+ }), action: v, closeLabel: f = I("Close"), onDismiss: m, className: _, render: h, ref: u, ...l }) => {
40
+ const i = y(n), p = y(v);
41
+ return D({
42
+ render: h,
43
+ ref: u,
44
+ state: {
45
+ status: e,
46
+ variant: t,
47
+ color: o
48
+ },
49
+ props: {
50
+ ...l,
51
+ className: k(T.container, a && T.containerFullWidth, _),
52
+ children: /* @__PURE__ */ g(S, { children: [
53
+ /* @__PURE__ */ g("div", {
54
+ className: T.header,
55
+ children: [
56
+ i && /* @__PURE__ */ c("div", {
57
+ className: T.iconContainer,
58
+ children: n
59
+ }),
60
+ /* @__PURE__ */ c("div", {
61
+ className: T.title,
62
+ children: s
63
+ }),
64
+ d(m) && /* @__PURE__ */ c(z, {
65
+ type: "button",
66
+ startIcon: /* @__PURE__ */ c(ee, { "aria-hidden": "true" }),
67
+ className: T.closeButton,
68
+ variant: "ghost",
69
+ size: "sm",
70
+ "aria-label": f,
71
+ onClick: () => m()
72
+ })
73
+ ]
74
+ }),
75
+ y(r) && /* @__PURE__ */ c("div", {
76
+ className: k(T.descriptionWrapper, i && T.descriptionWrapperWithIcon, p && T.descriptionWrapperWithAction),
77
+ children: /* @__PURE__ */ c("div", {
78
+ className: T.description,
79
+ children: r
80
+ })
81
+ }),
82
+ p && /* @__PURE__ */ c("div", {
83
+ className: T.footer,
84
+ children: v
85
+ })
86
+ ] })
87
+ }
88
+ });
89
+ }, co = Object.assign(Ye, { Action: De }), Ze = "_banner_qbpcz_1", et = "_embedded_qbpcz_6", tt = "_bannerContent_qbpcz_10", ot = "_icon_qbpcz_18", st = "_bannerText_qbpcz_28", rt = "_compact_qbpcz_33", nt = "_fullWidth_qbpcz_58", E = {
90
+ banner: Ze,
91
+ embedded: et,
92
+ bannerContent: tt,
93
+ icon: ot,
94
+ bannerText: st,
95
+ compact: rt,
96
+ fullWidth: nt
97
+ }, it = ({ children: e, layout: t = "standard", variant: o = "soft", embedded: s = !1, fullWidth: r = !1, icon: a = /* @__PURE__ */ c(Z, { "aria-hidden": "true" }), className: n, ...v }) => {
98
+ const f = t === "compact", m = !f && Pe(e);
99
+ return /* @__PURE__ */ c(te, {
100
+ ...v,
101
+ className: k(E.banner, f && E.compact, s && E.embedded, r && E.fullWidth, n),
102
+ variant: o,
103
+ "data-layout": t,
104
+ children: /* @__PURE__ */ g("div", {
105
+ className: E.bannerContent,
106
+ children: [y(a) && /* @__PURE__ */ c("span", {
107
+ className: E.icon,
108
+ children: a
109
+ }), /* @__PURE__ */ c("div", {
110
+ className: E.bannerText,
111
+ children: m ? /* @__PURE__ */ c(Ae, {
112
+ isFocusable: !0,
113
+ text: /* @__PURE__ */ c(S, { children: e }),
114
+ tooltipContent: e
115
+ }) : e
116
+ })]
117
+ })
118
+ });
119
+ }, lo = Object.assign(it, { Action: te.Action }), A = (e) => e.status === "visible", q = ({ store: e, toastsToClose: t, nextToasts: o = e.state.toasts }) => {
120
+ const s = t.filter((n) => A(n) && e.state.toasts.includes(n)), r = o.map((n) => s.includes(n) ? {
121
+ ...n,
122
+ status: "closing"
123
+ } : n), a = e.state.mountedToasterCount > 0;
124
+ e.set("toasts", a ? r : r.filter(A));
125
+ for (const n of s) n.notification.onClose?.();
126
+ }, se = oe(void 0), N = () => {
127
+ const e = j(se);
128
+ if (!d(e)) throw new Error(I("Toast components must be used within a ToastProvider."));
129
+ return e;
130
+ }, re = () => {
131
+ const e = N();
132
+ return { closeToast: (o) => {
133
+ if (!e.lifecycle.isActive()) return;
134
+ const s = e.state.toasts.filter((r) => A(r) && (!d(o) || r.notification.id === o));
135
+ $(s) && q({
136
+ store: e,
137
+ toastsToClose: s
138
+ });
139
+ } };
140
+ }, Q = 0, Y = () => (Q += 1, `toast-${Q}`), at = () => {
141
+ const e = N();
142
+ return { enqueueToast: ke(() => {
143
+ function t(o) {
144
+ if (!d(o)) return;
145
+ if (!e.lifecycle.isActive()) return Y();
146
+ const { dedupeKey: s, ...r } = o, { toasts: a, limit: n } = e.state, v = a.filter(A), f = d(s) ? v.find((h) => h.dedupeKey === s) : void 0;
147
+ if (d(f)) return f.notification.id;
148
+ const m = Y(), _ = Math.max(0, v.length - n + 1);
149
+ return q({
150
+ store: e,
151
+ toastsToClose: v.slice(0, _),
152
+ nextToasts: [...a, {
153
+ notification: {
154
+ ...r,
155
+ id: m
156
+ },
157
+ dedupeKey: s,
158
+ status: "visible"
159
+ }]
160
+ }), m;
161
+ }
162
+ return t;
163
+ }, [e]) };
164
+ }, ct = ({ store: e, id: t, ...o }) => {
165
+ if (!e.lifecycle.isActive()) return;
166
+ const s = e.state.toasts.find((n) => n.notification.id === t && A(n)), r = Object.keys(o);
167
+ if (!d(s) || !$(r)) return;
168
+ const a = r.includes("duration") || d(s.notification.progress) && r.includes("progress") && !d(o.progress);
169
+ e.set("toasts", e.state.toasts.map((n) => n === s ? {
170
+ ...n,
171
+ notification: {
172
+ ...n.notification,
173
+ ...o,
174
+ id: t
175
+ },
176
+ ...a ? { durationRevision: (n.durationRevision ?? 0) + 1 } : {}
177
+ } : n));
178
+ }, lt = () => {
179
+ const e = N();
180
+ return { updateToast: Re((t) => ct({
181
+ store: e,
182
+ ...t
183
+ }), [e]) };
184
+ }, uo = () => {
185
+ const { closeToast: e } = re(), { enqueueToast: t } = at(), { updateToast: o } = lt();
186
+ return {
187
+ enqueueToast: t,
188
+ closeToast: e,
189
+ updateToast: o
190
+ };
191
+ }, dt = "_root_181ka_1", ut = "_progress_181ka_19", vt = "_header_181ka_30", ft = "_message_181ka_40", mt = "_icon_181ka_45", pt = "_actions_181ka_50", _t = "_description_181ka_56", ht = "_footer_181ka_65", Tt = "_footerAction_181ka_69", gt = "_closeButton_181ka_76", b = {
192
+ root: dt,
193
+ progress: ut,
194
+ header: vt,
195
+ message: ft,
196
+ icon: mt,
197
+ actions: pt,
198
+ description: _t,
199
+ footer: ht,
200
+ footerAction: Tt,
201
+ closeButton: gt
202
+ }, U = oe({
203
+ durationRevision: 0,
204
+ isActive: !0
205
+ }), Ct = ({ clock: e, onClockChange: t, duration: o, progress: s, isPaused: r, onClose: a }) => {
206
+ const { durationRevision: n, isActive: v, lifecycle: f, id: m, rendererKey: _, timingOverrides: h } = j(U), u = d(f) && d(m) && d(_), l = u ? void 0 : e, i = d(s), p = d(h) && Object.prototype.propertyIsEnumerable.call(h, "duration"), x = d(h) && Object.prototype.propertyIsEnumerable.call(h, "progress");
207
+ return R(() => {
208
+ if (u) {
209
+ t(f.updateRenderer({
210
+ id: m,
211
+ key: _,
212
+ configuration: {
213
+ duration: p ? o : void 0,
214
+ isProgress: x ? i : void 0,
215
+ isPaused: r
216
+ }
217
+ }));
218
+ return;
219
+ }
220
+ l?.update({
221
+ duration: o,
222
+ durationRevision: n,
223
+ isPaused: r,
224
+ isProgress: i,
225
+ isActive: v,
226
+ onClose: a
227
+ });
228
+ }, [
229
+ l,
230
+ t,
231
+ u,
232
+ o,
233
+ n,
234
+ r,
235
+ i,
236
+ v,
237
+ a,
238
+ f,
239
+ m,
240
+ _,
241
+ p,
242
+ x
243
+ ]), R(() => () => {
244
+ if (u) {
245
+ f.removeRenderer({
246
+ id: m,
247
+ key: _
248
+ });
249
+ return;
250
+ }
251
+ l?.stop();
252
+ }, [
253
+ l,
254
+ f,
255
+ m,
256
+ _,
257
+ u
258
+ ]), null;
259
+ }, bt = ({ element: e, isFocused: t, onFocusChange: o }) => (R(() => {
260
+ if (!t || !d(e)) return;
261
+ const s = () => {
262
+ e.contains(e.ownerDocument.activeElement) || o(!1);
263
+ };
264
+ s();
265
+ const r = new MutationObserver(s);
266
+ return r.observe(e, {
267
+ childList: !0,
268
+ subtree: !0
269
+ }), () => r.disconnect();
270
+ }, [
271
+ e,
272
+ t,
273
+ o
274
+ ]), null), ne = 6e3, ie = (e) => Number.isFinite(e) && e > 0, wt = "_countdown_1vuo8_1", xt = "_toastCountdown_1vuo8_1", yt = {
275
+ countdown: wt,
276
+ toastCountdown: xt
277
+ }, At = ({ progress: e, duration: t, remainingDuration: o, revision: s, isPaused: r, barColor: a }) => d(e) ? /* @__PURE__ */ c(xe, {
278
+ value: e,
279
+ barColor: a
280
+ }) : ie(t) ? /* @__PURE__ */ c("div", {
281
+ className: yt.countdown,
282
+ "data-paused": r || void 0,
283
+ style: {
284
+ "--toast-countdown-color": a,
285
+ "--toast-countdown-width": `${o / t * 100}%`,
286
+ "--toast-countdown-duration": `${o}ms`
287
+ }
288
+ }, s) : null, Nt = 2 ** 31 - 1, Et = ({ onChange: e }) => {
289
+ let t, o = 0, s, r, a = 0, n = 0, v = !1;
290
+ const f = () => {
291
+ n += 1, d(s) && (o = Math.max(0, o - (performance.now() - s)), s = void 0), clearTimeout(r), r = void 0;
292
+ }, m = () => {
293
+ d(t) && (a += 1, e({
294
+ duration: t.duration,
295
+ remainingDuration: o,
296
+ revision: a,
297
+ isPaused: t.isPaused || !t.isActive
298
+ }));
299
+ }, _ = () => {
300
+ v || (f(), v = !0, o = 0, m(), t?.onClose?.());
301
+ }, h = () => d(t) && t.isActive && !t.isPaused && !t.isProgress && ie(t.duration) && !v, u = () => {
302
+ if (!h()) return;
303
+ s = performance.now();
304
+ const i = n;
305
+ r = setTimeout(() => {
306
+ if (i === n) {
307
+ if (f(), o > 0) {
308
+ u();
309
+ return;
310
+ }
311
+ _();
312
+ }
313
+ }, Math.min(o, Nt));
314
+ };
315
+ return {
316
+ update: (i) => {
317
+ const p = !d(t) || i.duration !== t.duration || i.durationRevision !== t.durationRevision || t.isProgress && !i.isProgress, x = p || i.isProgress !== t?.isProgress || i.isPaused !== t?.isPaused || i.isActive !== t?.isActive, C = !d(s) && h();
318
+ if (!x && !C) {
319
+ t = i;
320
+ return;
321
+ }
322
+ f(), t = i, !v && (p && (o = Math.max(0, i.duration)), m(), u());
323
+ },
324
+ close: _,
325
+ stop: f
326
+ };
327
+ }, ae = ({ duration: e, isPaused: t }) => {
328
+ let o = {
329
+ duration: e,
330
+ remainingDuration: e,
331
+ revision: 0,
332
+ isPaused: t
333
+ };
334
+ const s = /* @__PURE__ */ new Set();
335
+ return {
336
+ ...Et({ onChange: (r) => {
337
+ o = r;
338
+ for (const a of s) a();
339
+ } }),
340
+ getSnapshot: () => o,
341
+ subscribe: (r) => (s.add(r), () => {
342
+ s.delete(r);
343
+ })
344
+ };
345
+ }, Pt = ({ duration: e, isPaused: t }) => {
346
+ const { lifecycle: o, id: s, rendererKey: r } = j(U), [a, n] = P(() => (d(o) && d(s) && d(r) ? o.getCountdown(s) : void 0) ?? ae({
347
+ duration: e,
348
+ isPaused: t
349
+ }));
350
+ return {
351
+ countdown: Oe(a.subscribe, a.getSnapshot, a.getSnapshot),
352
+ clock: a,
353
+ setClock: n
354
+ };
355
+ }, It = {
356
+ neutral: M,
357
+ error: M,
358
+ success: _e,
359
+ info: Z,
360
+ warning: M
361
+ }, Rt = ({ children: e, description: t, icon: o, iconLabel: s, action: r, progress: a, duration: n = ne, onCancel: v, onClose: f, cancelLabel: m = I("Cancel"), closeLabel: _ = I("Close"), status: h = "neutral", role: u = "status", className: l, onMouseEnter: i, onMouseLeave: p, onFocus: x, onBlur: C, render: W, ref: le, ...de }) => {
362
+ const L = ge(), [ue, K] = P(!1), [H, B] = P(!1), [ve, fe] = P(null), V = ue || H, { countdown: O, clock: X, setClock: me } = Pt({
363
+ duration: n,
364
+ isPaused: V
365
+ }), pe = It[h], G = L.snackBar[h === "neutral" ? "default" : h], J = Ie(o) ? /* @__PURE__ */ c(pe, {
366
+ "aria-label": s,
367
+ "aria-hidden": !d(s),
368
+ color: G.color,
369
+ size: L.icon.size.md
370
+ }) : o;
371
+ return /* @__PURE__ */ g(S, { children: [
372
+ D({
373
+ render: W,
374
+ ref: [le ?? null, fe],
375
+ props: {
376
+ role: u,
377
+ "aria-live": u === "alert" ? "assertive" : "polite",
378
+ ...de,
379
+ className: k(b.root, l),
380
+ onMouseEnter: (w) => {
381
+ K(!0), i?.(w);
382
+ },
383
+ onMouseLeave: (w) => {
384
+ K(!1), p?.(w);
385
+ },
386
+ onFocus: (w) => {
387
+ B(!0), x?.(w);
388
+ },
389
+ onBlur: (w) => {
390
+ w.currentTarget.contains(w.relatedTarget) || B(!1), C?.(w);
391
+ },
392
+ children: /* @__PURE__ */ g(S, { children: [
393
+ /* @__PURE__ */ c("div", {
394
+ className: b.progress,
395
+ "aria-hidden": !0,
396
+ children: /* @__PURE__ */ c(At, {
397
+ barColor: G.backgroundColor,
398
+ progress: a,
399
+ duration: O.duration,
400
+ remainingDuration: O.remainingDuration,
401
+ revision: O.revision,
402
+ isPaused: O.isPaused
403
+ })
404
+ }),
405
+ /* @__PURE__ */ g("div", {
406
+ className: b.header,
407
+ children: [
408
+ y(J) && /* @__PURE__ */ c("div", {
409
+ className: b.icon,
410
+ children: J
411
+ }),
412
+ /* @__PURE__ */ c("div", {
413
+ className: b.message,
414
+ children: e
415
+ }),
416
+ /* @__PURE__ */ g("div", {
417
+ className: b.actions,
418
+ children: [d(v) && y(m) && /* @__PURE__ */ c(z, {
419
+ onClick: v,
420
+ size: "sm",
421
+ variant: "ghost",
422
+ style: { fontWeight: "var(--t-font-weight-regular)" },
423
+ children: m
424
+ }), d(f) && /* @__PURE__ */ c(z, {
425
+ title: _,
426
+ "aria-label": _,
427
+ startIcon: /* @__PURE__ */ c(ee, {}),
428
+ className: b.closeButton,
429
+ variant: "ghost",
430
+ size: "sm",
431
+ onClick: X.close
432
+ })]
433
+ })
434
+ ]
435
+ }),
436
+ y(t) && /* @__PURE__ */ c("div", {
437
+ className: b.description,
438
+ children: t
439
+ }),
440
+ y(r) && /* @__PURE__ */ g("div", {
441
+ className: b.footer,
442
+ children: [/* @__PURE__ */ c(Ne, {}), /* @__PURE__ */ c("div", {
443
+ className: b.footerAction,
444
+ children: r
445
+ })]
446
+ })
447
+ ] })
448
+ }
449
+ }),
450
+ /* @__PURE__ */ c(bt, {
451
+ element: ve,
452
+ isFocused: H,
453
+ onFocusChange: B
454
+ }),
455
+ /* @__PURE__ */ c(Ct, {
456
+ clock: X,
457
+ onClockChange: me,
458
+ duration: n,
459
+ progress: a,
460
+ isPaused: V,
461
+ onClose: f
462
+ })
463
+ ] });
464
+ }, ce = (e) => {
465
+ if (!Ee(e)) throw new Error(I("Toast limit must be a positive integer."));
466
+ }, St = ({ store: e, limit: t }) => {
467
+ if (ce(t), e.state.limit === t) return;
468
+ e.set("limit", t);
469
+ const o = e.state.toasts.filter(A), s = Math.max(0, o.length - t);
470
+ s !== 0 && q({
471
+ store: e,
472
+ toastsToClose: o.slice(0, s)
473
+ });
474
+ }, kt = ({ limit: e }) => {
475
+ const t = N();
476
+ return Se(() => t.lifecycle.mount(), [t]), R(() => St({
477
+ store: t,
478
+ limit: e
479
+ }), [t, e]), null;
480
+ }, Wt = ({ store: e, toast: t }) => {
481
+ const { toasts: o } = e.state;
482
+ t.status === "closing" && o.includes(t) && e.set("toasts", o.filter((s) => s !== t));
483
+ }, Ot = (e) => {
484
+ const t = /* @__PURE__ */ new Map();
485
+ let o = !1, s = !1, r = 0;
486
+ const a = (u) => {
487
+ const l = t.get(u);
488
+ if (d(l)) return l;
489
+ const i = {
490
+ countdown: ae({
491
+ duration: ne,
492
+ isPaused: !0
493
+ }),
494
+ renderers: /* @__PURE__ */ new Map()
495
+ };
496
+ return t.set(u, i), i;
497
+ }, n = (u) => {
498
+ if (!o) return;
499
+ const l = t.get(u);
500
+ if (!d(l?.pendingExits) || l.pendingExits.size > 0) return;
501
+ const i = e.state.toasts.find((p) => p.notification.id === u);
502
+ d(i) && Wt({
503
+ store: e,
504
+ toast: i
505
+ });
506
+ }, v = () => {
507
+ for (const [u, l] of t) {
508
+ const i = e.state.toasts.find((C) => C.notification.id === u);
509
+ if (!d(i)) {
510
+ l.countdown.stop(), t.delete(u);
511
+ continue;
512
+ }
513
+ const p = l.renderers.values().next().value ?? l.lastRenderer;
514
+ l.lastRenderer = p;
515
+ const x = !o || l.renderers.size === 0 || [...l.renderers.values()].some((C) => C.isPaused);
516
+ l.countdown.update({
517
+ duration: p?.duration ?? i.notification.duration ?? 6e3,
518
+ durationRevision: i.durationRevision ?? 0,
519
+ isProgress: p?.isProgress ?? d(i.notification.progress),
520
+ isPaused: x,
521
+ isActive: i.status === "visible",
522
+ onClose: () => {
523
+ const C = e.state.toasts.find((W) => W.notification.id === u && A(W));
524
+ !o || !d(C) || q({
525
+ store: e,
526
+ toastsToClose: [C]
527
+ });
528
+ }
529
+ }), i.status !== "visible" && (l.pendingExits ??= new Set(l.renderers.keys()), n(u));
530
+ }
531
+ };
532
+ return {
533
+ mount: () => {
534
+ o = !0, s = !1, r += 1;
535
+ const u = e.subscribe(v);
536
+ return v(), () => {
537
+ o = !1, u();
538
+ for (const i of t.values()) i.countdown.stop();
539
+ const l = ++r;
540
+ queueMicrotask(() => {
541
+ o || r !== l || (s = !0, t.clear(), e.set("toasts", []));
542
+ });
543
+ };
544
+ },
545
+ isActive: () => !s,
546
+ getCountdown: (u) => t.get(u)?.countdown,
547
+ updateRenderer: ({ id: u, key: l, configuration: i }) => {
548
+ const p = a(u);
549
+ return p.renderers.has(l) || (p.countdown.stop(), p.pendingExits?.add(l)), p.renderers.set(l, i), v(), p.countdown;
550
+ },
551
+ removeRenderer: ({ id: u, key: l }) => {
552
+ const i = t.get(u);
553
+ d(i) && (i.renderers.delete(l), i.pendingExits?.delete(l), v());
554
+ },
555
+ finishExit: ({ id: u, key: l }) => {
556
+ t.get(u)?.pendingExits?.delete(l), n(u);
557
+ }
558
+ };
559
+ }, zt = (e = 3) => {
560
+ ce(e);
561
+ const t = new ze({
562
+ toasts: [],
563
+ limit: e,
564
+ mountedToasterCount: 0
565
+ });
566
+ return Object.assign(t, { lifecycle: Ot(t) });
567
+ }, vo = ({ children: e, limit: t = 3 }) => {
568
+ const [o] = P(() => zt(t));
569
+ return /* @__PURE__ */ g(se.Provider, {
570
+ value: o,
571
+ children: [e, /* @__PURE__ */ c(kt, { limit: t })]
572
+ });
573
+ }, qt = "_root_1q2cc_1", Bt = "_item_1q2cc_20", Mt = "_itemContent_1q2cc_47", F = {
574
+ root: qt,
575
+ item: Bt,
576
+ itemContent: Mt
577
+ }, Ft = () => qe(N(), (e) => e.toasts), Dt = ({ elementRef: e, toastEntry: t, rendererKey: o }) => {
578
+ const s = N();
579
+ return R(() => {
580
+ if (t.status === "visible") return;
581
+ const r = () => s.lifecycle.finishExit({
582
+ id: t.notification.id,
583
+ key: o
584
+ }), a = e.current?.getAnimations?.() ?? [];
585
+ if (!$(a)) {
586
+ r();
587
+ return;
588
+ }
589
+ let n = !1;
590
+ return Promise.allSettled(a.map((v) => v.finished)).then(() => {
591
+ n || r();
592
+ }), () => {
593
+ n = !0;
594
+ };
595
+ }, [
596
+ e,
597
+ t,
598
+ s,
599
+ o
600
+ ]), null;
601
+ }, $t = ({ toastEntry: e, getToastProps: t, onClose: o }) => {
602
+ const { notification: s, status: r, durationRevision: a = 0 } = e, { id: n, ...v } = s, f = N(), m = t?.(s), [_] = P(() => /* @__PURE__ */ Symbol()), h = We(null);
603
+ return /* @__PURE__ */ g(S, { children: [/* @__PURE__ */ c("div", {
604
+ ref: h,
605
+ className: F.item,
606
+ "data-exiting": r === "closing" || void 0,
607
+ inert: r === "closing",
608
+ children: /* @__PURE__ */ c("div", {
609
+ className: F.itemContent,
610
+ children: /* @__PURE__ */ c(U.Provider, {
611
+ value: {
612
+ durationRevision: a,
613
+ isActive: r === "visible",
614
+ lifecycle: f.lifecycle,
615
+ id: n,
616
+ rendererKey: _,
617
+ timingOverrides: m
618
+ },
619
+ children: /* @__PURE__ */ c(Rt, {
620
+ ...v,
621
+ ...m,
622
+ id: n,
623
+ onClose: () => o(n)
624
+ })
625
+ })
626
+ })
627
+ }), /* @__PURE__ */ c(Dt, {
628
+ elementRef: h,
629
+ toastEntry: e,
630
+ rendererKey: _
631
+ })] });
632
+ }, jt = ({ getToastProps: e }) => {
633
+ const t = Ft(), { closeToast: o } = re();
634
+ return t.map((s) => /* @__PURE__ */ c($t, {
635
+ toastEntry: s,
636
+ getToastProps: e,
637
+ onClose: o
638
+ }, s.notification.id));
639
+ }, Ut = () => {
640
+ const e = N();
641
+ return R(() => (e.set("mountedToasterCount", e.state.mountedToasterCount + 1), () => {
642
+ e.set("mountedToasterCount", e.state.mountedToasterCount - 1), !(e.state.mountedToasterCount > 0) && e.set("toasts", e.state.toasts.filter(A));
643
+ }), [e]), null;
644
+ }, fo = ({ container: e, getToastProps: t, className: o, render: s, ref: r, ...a }) => {
645
+ const n = Ce(), v = ye(), f = e === void 0 ? n ?? (typeof document > "u" ? null : document.body) : e, m = D({
646
+ render: s,
647
+ ref: r,
648
+ props: {
649
+ role: "region",
650
+ dir: v,
651
+ "aria-label": I("Notifications"),
652
+ ...a,
653
+ className: k(F.root, o),
654
+ children: /* @__PURE__ */ g(S, { children: [/* @__PURE__ */ c(Ut, {}), /* @__PURE__ */ c(jt, { getToastProps: t })] })
655
+ }
656
+ });
657
+ return d(f) ? Be(m, f) : null;
658
+ };
659
+ export {
660
+ lo as a,
661
+ uo as i,
662
+ vo as n,
663
+ co as o,
664
+ Rt as r,
665
+ fo as t
666
+ };
@@ -0,0 +1,38 @@
1
+ import { useRender as k } from "@base-ui/react/use-render";
2
+ import { clsx as v } from "clsx";
3
+ var f = {
4
+ xs: 13,
5
+ s: 16,
6
+ m: 24,
7
+ l: 32,
8
+ xl: 40
9
+ }, u = "_root_17v1i_1", c = "_skeletonShimmer_17v1i_1", h = {
10
+ root: u,
11
+ skeletonShimmer: c
12
+ }, g = ({ width: r, height: a, borderRadius: t, baseColor: e, highlightColor: l, animated: n = !0, layout: o = "block", className: i, style: s, render: d, ref: m, ..._ }) => k({
13
+ defaultTagName: "span",
14
+ render: d,
15
+ ref: m,
16
+ props: {
17
+ "aria-hidden": !0,
18
+ ..._,
19
+ "data-skeleton": "",
20
+ "data-animated": n || void 0,
21
+ "data-layout": o,
22
+ className: v(h.root, i),
23
+ style: {
24
+ width: r,
25
+ height: a,
26
+ borderRadius: t,
27
+ backgroundColor: e,
28
+ "--skeleton-base-color": e,
29
+ "--skeleton-highlight-color": l,
30
+ ...s
31
+ },
32
+ children: o === "inline" ? "‌" : void 0
33
+ }
34
+ });
35
+ export {
36
+ f as n,
37
+ g as t
38
+ };
@@ -0,0 +1 @@
1
+ let c=require("@base-ui/react/use-render"),m=require("clsx");var S={xs:13,s:16,m:24,l:32,xl:40},k="_root_17v1i_1",v="_skeletonShimmer_17v1i_1",E={root:k,skeletonShimmer:v},b=({width:t,height:n,borderRadius:o,baseColor:e,highlightColor:a,animated:l=!0,layout:r="block",className:i,style:u,render:d,ref:s,..._})=>(0,c.useRender)({defaultTagName:"span",render:d,ref:s,props:{"aria-hidden":!0,..._,"data-skeleton":"","data-animated":l||void 0,"data-layout":r,className:(0,m.clsx)(E.root,i),style:{width:t,height:n,borderRadius:o,backgroundColor:e,"--skeleton-base-color":e,"--skeleton-highlight-color":a,...u},children:r==="inline"?"‌":void 0}});Object.defineProperty(exports,"SKELETON_HEIGHT_SIZES",{enumerable:!0,get:function(){return S}});Object.defineProperty(exports,"Skeleton",{enumerable:!0,get:function(){return b}});