twenty-ui 2.43.0 → 2.45.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 (299) hide show
  1. package/README.md +86 -65
  2. package/dist/{AllIcons-Z8o0B2fy.js → AllIcons-CFMhMGzh.js} +1 -1
  3. package/dist/{AllIcons-D_4JeQkX.cjs → AllIcons-Cz8pObev.cjs} +1 -1
  4. package/dist/Avatar-C0FtFpJC.js +68 -0
  5. package/dist/Avatar-CkI8b3nh.cjs +1 -0
  6. package/dist/ListItem-B2HOeN2h.cjs +1 -0
  7. package/dist/ListItem-D8BQRK1W.js +97 -0
  8. package/dist/ListItem.module-Dxd8jOJP.js +35 -0
  9. package/dist/ListItem.module-RqrfwrFg.cjs +1 -0
  10. package/dist/{Loader-X1LymYkw.js → Loader-BLkXvZli.js} +1 -1
  11. package/dist/{Loader-Z6_7AA-x.cjs → Loader-CMXdrX1d.cjs} +1 -1
  12. package/dist/MenuSeparator-Ct3cQtJ2.cjs +1 -0
  13. package/dist/MenuSeparator-CyUYx1nk.js +68 -0
  14. package/dist/OverflowingTextWithTooltip-CNpmkBvJ.js +198 -0
  15. package/dist/OverflowingTextWithTooltip-tsJWb_Ie.cjs +1 -0
  16. package/dist/ProgressBar-21MXyySH.js +108 -0
  17. package/dist/ProgressBar-CyqeRyzA.cjs +1 -0
  18. package/dist/{ResizeHandle-DN1bRxQb.js → ResizeHandle-CGYGfOVF.js} +5 -5
  19. package/dist/{ResizeHandle-cll01qBQ.cjs → ResizeHandle-CI-VTVOi.cjs} +1 -1
  20. package/dist/Shortcut-CRCVbA2m.js +71 -0
  21. package/dist/Shortcut-CuBFak3I.cjs +1 -0
  22. package/dist/Switch-BQp0t6JZ.js +129 -0
  23. package/dist/Switch-CFCj3OQZ.cjs +1 -0
  24. package/dist/TabsTabContent-DZUNi_iE.cjs +1 -0
  25. package/dist/TabsTabContent-s6J5bZ3R.js +39 -0
  26. package/dist/TextDirectionContext-pwtyVyKv.cjs +1 -0
  27. package/dist/TextDirectionContext-zzaQWZg6.js +5 -0
  28. package/dist/components/__stories__/reading-direction/DirectionalLayoutExample.d.ts +3 -0
  29. package/dist/components/__stories__/reading-direction/DirectionalMenusExample.d.ts +4 -0
  30. package/dist/components/code-editor/CodeEditor/{utils → internal/utils}/getBaseCodeEditorTheme.d.ts +1 -1
  31. package/dist/components/code-editor/index.d.ts +0 -2
  32. package/dist/components/code-editor.cjs +1 -1
  33. package/dist/components/code-editor.mjs +37 -37
  34. package/dist/components/data-display/MetricRow/MetricRow.d.ts +2 -0
  35. package/dist/components/data-display/MetricRow/types/MetricRowProps.d.ts +11 -0
  36. package/dist/components/feedback/Callout/Callout.d.ts +1 -1
  37. package/dist/components/feedback/Callout/types/CalloutProps.d.ts +1 -0
  38. package/dist/components/feedback/InlineBanner/InlineBanner.d.ts +2 -18
  39. package/dist/components/feedback/InlineBanner/internal/InlineBannerButton.d.ts +5 -0
  40. package/dist/components/feedback/InlineBanner/types/InlineBannerButtonProps.d.ts +7 -0
  41. package/dist/components/feedback/InlineBanner/types/InlineBannerProps.d.ts +12 -0
  42. package/dist/components/feedback/Toast/Toast.d.ts +1 -1
  43. package/dist/components/feedback/Toast/internal/components/ToastProgress.d.ts +9 -0
  44. package/dist/components/feedback/Toast/{hooks → internal/hooks}/useEnqueueToast.d.ts +1 -1
  45. package/dist/components/feedback/Toast/{types → internal/types}/ToastEntry.d.ts +1 -1
  46. package/dist/components/feedback/Toast/types/ToastProps.d.ts +1 -1
  47. package/dist/components/feedback/Toaster/internal/ToasterItem.d.ts +1 -1
  48. package/dist/components/feedback/Toaster/internal/ToasterItemExitEffect.d.ts +1 -1
  49. package/dist/components/index.d.ts +10 -21
  50. package/dist/components/input/IconButton/types/IconButtonProps.d.ts +1 -1
  51. package/dist/components/input/ImageInput/ImageInput.d.ts +2 -0
  52. package/dist/components/input/ImageInput/__stories__/ImageInputPreviewChangesExample.d.ts +2 -0
  53. package/dist/components/input/ImageInput/__stories__/imageInputPreviewUrl.d.ts +1 -0
  54. package/dist/components/input/ImageInput/internal/ImageInputPreview.d.ts +5 -0
  55. package/dist/components/input/ImageInput/types/ImageInputProps.d.ts +15 -0
  56. package/dist/components/input/SearchInput/SearchInput.d.ts +1 -1
  57. package/dist/components/input/SearchInput/__stories__/SearchInputExample.d.ts +2 -0
  58. package/dist/components/input/SearchInput/types/SearchInputProps.d.ts +2 -10
  59. package/dist/components/layout/OverflowingList/OverflowingList.d.ts +2 -0
  60. package/dist/components/layout/OverflowingList/__stories__/OVERFLOWING_LIST_STORY_ITEMS.d.ts +1 -0
  61. package/dist/components/layout/OverflowingList/__stories__/OverflowingListControlledFocusExample.d.ts +1 -0
  62. package/dist/components/layout/OverflowingList/__stories__/OverflowingListMutableTag.d.ts +1 -0
  63. package/dist/components/layout/OverflowingList/__stories__/OverflowingListResizeExample.d.ts +1 -0
  64. package/dist/components/layout/OverflowingList/__stories__/expectOverflowingListPopupGeometry.d.ts +4 -0
  65. package/dist/components/layout/OverflowingList/internal/OverflowingListItem.d.ts +9 -0
  66. package/dist/components/layout/OverflowingList/internal/getVisibleItemCount.d.ts +6 -0
  67. package/dist/components/layout/OverflowingList/internal/measureItemWidths.d.ts +5 -0
  68. package/dist/components/layout/OverflowingList/internal/useFocusedElementUnmountRef.d.ts +1 -0
  69. package/dist/components/layout/OverflowingList/internal/useOverflowingListLayout.d.ts +12 -0
  70. package/dist/components/layout/OverflowingList/types/OverflowingListProps.d.ts +7 -0
  71. package/dist/components/navigation/Dropdown/Dropdown.d.ts +6 -6
  72. package/dist/components/navigation/Dropdown/__stories__/DropdownContextMenuExample.d.ts +1 -0
  73. package/dist/components/navigation/Dropdown/__stories__/createStoryState.d.ts +4 -0
  74. package/dist/components/navigation/Dropdown/__stories__/dropdownStoryA11yParameters.d.ts +8 -0
  75. package/dist/components/navigation/Dropdown/hooks/useDropdownPage.d.ts +6 -0
  76. package/dist/components/navigation/Dropdown/internal/DropdownActionItem.d.ts +1 -1
  77. package/dist/components/navigation/Dropdown/internal/DropdownContent.d.ts +1 -1
  78. package/dist/components/navigation/Dropdown/internal/DropdownContextValue.d.ts +5 -1
  79. package/dist/components/navigation/Dropdown/internal/DropdownOptionItem.d.ts +1 -1
  80. package/dist/components/navigation/Dropdown/internal/DropdownRoot.d.ts +1 -1
  81. package/dist/components/navigation/Dropdown/internal/DropdownSubmenuTrigger.d.ts +1 -1
  82. package/dist/components/navigation/Dropdown/internal/DropdownTitle.d.ts +1 -1
  83. package/dist/components/navigation/Dropdown/internal/DropdownTrigger.d.ts +1 -1
  84. package/dist/components/navigation/Dropdown/internal/getDropdownDismissTarget.d.ts +1 -0
  85. package/dist/components/navigation/Dropdown/internal/isDropdownDismissPrevented.d.ts +5 -0
  86. package/dist/components/navigation/Dropdown/internal/useRegisterDropdownLabelElement.d.ts +1 -0
  87. package/dist/components/navigation/Dropdown/internal/useRegisteredElementId.d.ts +1 -0
  88. package/dist/components/navigation/Dropdown/types/DropdownActionItemProps.d.ts +1 -1
  89. package/dist/components/navigation/Dropdown/types/DropdownDismissEvent.d.ts +4 -0
  90. package/dist/components/navigation/Dropdown/types/DropdownOptionItemProps.d.ts +1 -1
  91. package/dist/components/navigation/Dropdown/types/DropdownRootProps.d.ts +3 -0
  92. package/dist/components/navigation/Dropdown/types/DropdownSubmenuProps.d.ts +1 -1
  93. package/dist/components/navigation/MenuItem/MenuItem.d.ts +1 -1
  94. package/dist/components/navigation/MenuItem/types/MenuItemProps.d.ts +3 -2
  95. package/dist/components/navigation/TabButton/types/TabButtonProps.d.ts +1 -1
  96. package/dist/components-BizDepCM.cjs +1 -0
  97. package/dist/components-CC-3jXEq.js +2144 -0
  98. package/dist/components.cjs +1 -1
  99. package/dist/components.mjs +33 -44
  100. package/dist/data-display-BgweQocz.cjs +1 -0
  101. package/dist/data-display-Dn_nzrc8.js +190 -0
  102. package/dist/getSafeUrl-BuX_E2_8.cjs +1 -0
  103. package/dist/getSafeUrl-DXwcx-N0.js +27 -0
  104. package/dist/icon/components/TablerIcons.d.ts +1 -1
  105. package/dist/icon/hooks/useIcons.d.ts +1 -1
  106. package/dist/icon/index.d.ts +1 -1
  107. package/dist/{icon-Bd81r48z.js → icon-B7aZ6RxF.js} +123 -122
  108. package/dist/{icon-iD9IXJmn.cjs → icon-DK8OPi-m.cjs} +1 -1
  109. package/dist/icon.cjs +1 -1
  110. package/dist/icon.mjs +227 -226
  111. package/dist/index.cjs +1 -1
  112. package/dist/index.mjs +630 -641
  113. package/dist/input-C50264Jb.js +407 -0
  114. package/dist/input-CRiX4eQH.cjs +1 -0
  115. package/dist/isRenderableSlot-DT_depzM.js +6 -0
  116. package/dist/isRenderableSlot-Guryb6Nf.cjs +1 -0
  117. package/dist/layout-BEC7fKLU.js +34 -0
  118. package/dist/layout-DniJJ8Mx.cjs +1 -0
  119. package/dist/navigation-B9YTBTaa.cjs +1 -0
  120. package/dist/navigation-CQUyRKgk.js +122 -0
  121. package/dist/primitives/data-display/Avatar/Avatar.d.ts +1 -1
  122. package/dist/primitives/data-display/Avatar/types/AvatarProps.d.ts +1 -0
  123. package/dist/primitives/data-display/Pill/Pill.d.ts +3 -1
  124. package/dist/primitives/data-display.cjs +1 -1
  125. package/dist/primitives/data-display.mjs +7 -8
  126. package/dist/primitives/feedback/ProgressBar/ProgressBar.d.ts +2 -12
  127. package/dist/primitives/feedback/ProgressBar/types/ProgressBarProps.d.ts +14 -0
  128. package/dist/primitives/feedback/ProgressRing/ProgressRing.d.ts +2 -0
  129. package/dist/primitives/feedback/ProgressRing/types/ProgressRingProps.d.ts +6 -0
  130. package/dist/primitives/feedback/index.d.ts +3 -2
  131. package/dist/primitives/feedback.cjs +1 -1
  132. package/dist/primitives/feedback.mjs +6 -7
  133. package/dist/primitives/input/Button/Button.d.ts +1 -1
  134. package/dist/primitives/input/Button/types/ButtonProps.d.ts +3 -3
  135. package/dist/primitives/input/Button/types/ButtonVariant.d.ts +1 -1
  136. package/dist/primitives/input/NumberStepper/NumberStepper.d.ts +2 -0
  137. package/dist/primitives/input/NumberStepper/__stories__/ControlledNumberStepperExample.d.ts +2 -0
  138. package/dist/primitives/input/NumberStepper/__stories__/NumberStepperFieldExample.d.ts +2 -0
  139. package/dist/primitives/input/NumberStepper/__stories__/NumberStepperFormExample.d.ts +4 -0
  140. package/dist/primitives/input/NumberStepper/internal/constants/NumberStepperFormat.d.ts +1 -0
  141. package/dist/primitives/input/NumberStepper/internal/utils/isBlurRoundingOfCurrentValue.d.ts +8 -0
  142. package/dist/primitives/input/NumberStepper/types/NumberStepperProps.d.ts +7 -0
  143. package/dist/primitives/input/Radio/Radio.d.ts +1 -1
  144. package/dist/primitives/input/Radio/types/RadioProps.d.ts +1 -0
  145. package/dist/primitives/input/index.d.ts +2 -1
  146. package/dist/primitives/input.cjs +1 -1
  147. package/dist/primitives/input.mjs +15 -14
  148. package/dist/primitives/layout/{AnimatedExpandableContainer/AnimatedExpandableContainer.d.ts → Collapsible/Collapsible.d.ts} +2 -5
  149. package/dist/primitives/layout/TextDirectionProvider/TextDirectionProvider.d.ts +2 -1
  150. package/dist/primitives/layout/TextDirectionProvider/internal/TextDirection.d.ts +1 -0
  151. package/dist/primitives/layout/TextDirectionProvider/internal/TextDirectionContext.d.ts +2 -0
  152. package/dist/primitives/layout/TextDirectionProvider/internal/useProvidedTextDirection.d.ts +1 -0
  153. package/dist/primitives/layout/index.d.ts +4 -6
  154. package/dist/primitives/layout.cjs +1 -1
  155. package/dist/primitives/layout.mjs +6 -6
  156. package/dist/primitives/navigation/Breadcrumb/Breadcrumb.d.ts +2 -0
  157. package/dist/primitives/navigation/Breadcrumb/internal/BreadcrumbItemContent.d.ts +6 -0
  158. package/dist/primitives/navigation/Breadcrumb/types/BreadcrumbItem.d.ts +2 -0
  159. package/dist/primitives/navigation/Breadcrumb/types/BreadcrumbProps.d.ts +5 -0
  160. package/dist/primitives/navigation/ListItem/ListItem.d.ts +1 -1
  161. package/dist/primitives/navigation/ListItem/types/ListItemProps.d.ts +3 -1
  162. package/dist/primitives/navigation/index.d.ts +3 -4
  163. package/dist/primitives/navigation.cjs +1 -1
  164. package/dist/primitives/navigation.mjs +5 -8
  165. package/dist/primitives/surfaces/Dialog/types/DialogSize.d.ts +1 -1
  166. package/dist/primitives/surfaces/Menu/internal/getMenuListItemProps.d.ts +4 -1
  167. package/dist/primitives/surfaces/Menu/types/MenuItemSlotProps.d.ts +1 -1
  168. package/dist/primitives/surfaces/Popover/Popover.d.ts +1 -1
  169. package/dist/primitives/surfaces/Popover/internal/PopoverPopup.d.ts +1 -1
  170. package/dist/primitives/surfaces/Popover/types/PopoverPopupProps.d.ts +5 -0
  171. package/dist/primitives/surfaces/Tooltip/Tooltip.d.ts +1 -1
  172. package/dist/primitives/surfaces/Tooltip/internal/TooltipPopup.d.ts +1 -1
  173. package/dist/primitives/surfaces/Tooltip/types/TooltipPopupProps.d.ts +1 -0
  174. package/dist/primitives/surfaces.cjs +1 -1
  175. package/dist/primitives/surfaces.mjs +3 -3
  176. package/dist/{utilities/utils → primitives/typography/OverflowingTextWithTooltip/internal/LinkifiedText}/linkifyText.d.ts +2 -1
  177. package/dist/primitives/typography/Shortcut/Shortcut.d.ts +2 -0
  178. package/dist/primitives/typography/Shortcut/formatShortcut.d.ts +2 -0
  179. package/dist/primitives/typography/Shortcut/internal/getShortcutPresentation.d.ts +8 -0
  180. package/dist/primitives/typography/Shortcut/types/ShortcutDefinition.d.ts +1 -0
  181. package/dist/primitives/typography/Shortcut/types/ShortcutFormatOptions.d.ts +7 -0
  182. package/dist/primitives/typography/Shortcut/types/ShortcutProps.d.ts +6 -0
  183. package/dist/primitives/typography/index.d.ts +5 -0
  184. package/dist/primitives/typography.cjs +1 -1
  185. package/dist/primitives/typography.mjs +8 -4
  186. package/dist/primitives.cjs +1 -1
  187. package/dist/primitives.mjs +62 -62
  188. package/dist/style.css +1 -1
  189. package/dist/surfaces-C9ZUjKxU.js +264 -0
  190. package/dist/surfaces-Davk4uBw.cjs +1 -0
  191. package/dist/testing.cjs +1 -1
  192. package/dist/testing.mjs +1 -1
  193. package/dist/theme/constants/MainColorNames.d.ts +1 -1
  194. package/dist/theme/constants/ThemeCommon.d.ts +3 -0
  195. package/dist/theme/constants/ThemeLight.d.ts +4 -0
  196. package/dist/theme/getNextThemeColor.d.ts +1 -1
  197. package/dist/theme/themeCssVariables.d.ts +4 -0
  198. package/dist/theme/themeTypes.d.ts +4 -0
  199. package/dist/{theme-DBro6iwF.js → theme-CjHovJAZ.js} +30 -20
  200. package/dist/theme-DumxXtpW.cjs +1 -0
  201. package/dist/theme-dark.css +2 -0
  202. package/dist/theme-light.css +2 -0
  203. package/dist/theme.cjs +1 -1
  204. package/dist/theme.mjs +1 -1
  205. package/dist/typography-D3fk3hSo.cjs +1 -0
  206. package/dist/typography-DUJWRilJ.js +5 -0
  207. package/dist/useIsMobile-CAIiLC-3.js +37 -0
  208. package/dist/useIsMobile-UXHqqYXb.cjs +1 -0
  209. package/dist/useProvidedTextDirection-B7ovnsdr.cjs +1 -0
  210. package/dist/useProvidedTextDirection-P1dtjUtE.js +9 -0
  211. package/dist/utilities/device/getUserDevice.d.ts +1 -1
  212. package/dist/utilities/index.d.ts +0 -4
  213. package/dist/utilities-CJKPcDM4.js +28 -0
  214. package/dist/utilities-CdR__WZM.cjs +1 -0
  215. package/dist/utilities.cjs +1 -1
  216. package/dist/utilities.mjs +14 -15
  217. package/package.json +2 -2
  218. package/CHANGELOG.md +0 -24
  219. package/dist/Avatar-BSHgTxt-.js +0 -67
  220. package/dist/Avatar-DTNH6Ku7.cjs +0 -1
  221. package/dist/Input-CFXY05bj.cjs +0 -1
  222. package/dist/Input-DHfmRBq5.js +0 -116
  223. package/dist/ListItem-2dHkY1NB.cjs +0 -1
  224. package/dist/ListItem-D6DvFIbl.js +0 -109
  225. package/dist/ListItem.module-CveFbY4M.cjs +0 -1
  226. package/dist/ListItem.module-DtIGiTDL.js +0 -38
  227. package/dist/MenuSeparator-DJOspG7J.cjs +0 -1
  228. package/dist/MenuSeparator-dNx4JE6C.js +0 -66
  229. package/dist/OverflowingTextWithTooltip-CqEkoH6t.js +0 -179
  230. package/dist/OverflowingTextWithTooltip-bn6EwWeq.cjs +0 -1
  231. package/dist/Pill-BJ3K8Mdc.cjs +0 -1
  232. package/dist/Pill-DaFEFIOT.js +0 -9
  233. package/dist/ProgressBar-DwJQXHwg.cjs +0 -1
  234. package/dist/ProgressBar-RWLNIkzm.js +0 -55
  235. package/dist/TabsTabContent-BseLV1Wk.cjs +0 -1
  236. package/dist/TabsTabContent-_NCTxoP6.js +0 -40
  237. package/dist/components/data-display/JsonTree/internal/JsonListItem.d.ts +0 -4
  238. package/dist/components/feedback/Info/Info.d.ts +0 -2
  239. package/dist/components/feedback/Info/types/InfoAccent.d.ts +0 -1
  240. package/dist/components/feedback/Info/types/InfoProps.d.ts +0 -11
  241. package/dist/components/input/CardPicker/CardPicker.d.ts +0 -2
  242. package/dist/components/input/CardPicker/types/CardPickerProps.d.ts +0 -2
  243. package/dist/components/input/ColorSchemePicker/ColorSchemePicker.d.ts +0 -2
  244. package/dist/components/input/ColorSchemePicker/internal/Checkmark/Checkmark.d.ts +0 -5
  245. package/dist/components/input/ColorSchemePicker/internal/ColorSchemeCard/ColorSchemeCard.d.ts +0 -11
  246. package/dist/components/input/ColorSchemePicker/types/ColorSchemePickerProps.d.ts +0 -9
  247. package/dist/components/navigation/NavigationBar/NavigationBar.d.ts +0 -13
  248. package/dist/components/navigation/NavigationBar/internal/NavigationBarItem/NavigationBarItem.d.ts +0 -9
  249. package/dist/components/navigation/RoundedLink/RoundedLink.d.ts +0 -8
  250. package/dist/components-BYWo2sUE.cjs +0 -1
  251. package/dist/components-C96xU59U.js +0 -1996
  252. package/dist/data-display-BQ9g9oSc.cjs +0 -1
  253. package/dist/data-display-z9gKjkPS.js +0 -184
  254. package/dist/feedback-BvpEL2-w.js +0 -25
  255. package/dist/feedback-CH2UC0Fv.cjs +0 -1
  256. package/dist/input-C8IiOA9Q.js +0 -335
  257. package/dist/input-NBD4DP8j.cjs +0 -1
  258. package/dist/layout-BgAfeZsL.cjs +0 -1
  259. package/dist/layout-D-XbKoLM.js +0 -30
  260. package/dist/linkifyText-BHQ4_CzQ.cjs +0 -1
  261. package/dist/linkifyText-BINRNP9w.js +0 -45
  262. package/dist/mergeClassNames-BHKm1BNi.js +0 -6
  263. package/dist/mergeClassNames-BbJtXN2t.cjs +0 -1
  264. package/dist/navigation-BqZBteC2.cjs +0 -1
  265. package/dist/navigation-CLMgaqS8.js +0 -91
  266. package/dist/primitives/feedback/CircularProgressBar/CircularProgressBar.d.ts +0 -7
  267. package/dist/primitives/input/Button/internal/ButtonHotKeys.d.ts +0 -5
  268. package/dist/primitives/input/Button/internal/ButtonSoon.d.ts +0 -5
  269. package/dist/primitives/input/types/ColorScheme.d.ts +0 -1
  270. package/dist/primitives/layout/AnimatedExpandableContainer/types/AnimationMode.d.ts +0 -1
  271. package/dist/primitives/layout/AnimatedExpandableContainer/types/AnimationSize.d.ts +0 -1
  272. package/dist/primitives/navigation/ClickToActionLink/ClickToActionLink.d.ts +0 -6
  273. package/dist/primitives/navigation/Link/constants/Cal.d.ts +0 -1
  274. package/dist/primitives/navigation/Link/constants/GithubLink.d.ts +0 -1
  275. package/dist/primitives/navigation/Link/constants/TwentyPricingLink.d.ts +0 -1
  276. package/dist/primitives/navigation/ListItem/internal/MenuItemHotKeys/MenuItemHotKeys.d.ts +0 -6
  277. package/dist/primitives/navigation/Tabs/internal/isRenderableSlot.d.ts +0 -2
  278. package/dist/surfaces-DX8oX1ou.js +0 -254
  279. package/dist/surfaces-uuLwsFxg.cjs +0 -1
  280. package/dist/theme-DNG4OSBd.cjs +0 -1
  281. package/dist/utilities/device/getOsShortcutSeparator.d.ts +0 -1
  282. package/dist/utilities/types/ClickOutsideAttributes.d.ts +0 -4
  283. package/dist/utilities-BlvbRryv.cjs +0 -1
  284. package/dist/utilities-C5Tt2HLT.js +0 -56
  285. /package/dist/components/code-editor/CodeEditor/{constants → internal/constants}/BaseCodeEditorThemeId.d.ts +0 -0
  286. /package/dist/components/feedback/Toast/{constants → internal/constants}/DefaultToastLimit.d.ts +0 -0
  287. /package/dist/components/feedback/Toast/{contexts → internal/contexts}/ToastContext.d.ts +0 -0
  288. /package/dist/components/feedback/Toast/{hooks → internal/hooks}/useCloseToast.d.ts +0 -0
  289. /package/dist/components/feedback/Toast/{hooks → internal/hooks}/useToastContext.d.ts +0 -0
  290. /package/dist/components/feedback/Toast/{hooks → internal/hooks}/useToastEntries.d.ts +0 -0
  291. /package/dist/components/feedback/Toast/{stores → internal/stores}/createToastStore.d.ts +0 -0
  292. /package/dist/components/feedback/Toast/{types → internal/types}/ToastStoreState.d.ts +0 -0
  293. /package/dist/components/feedback/Toast/{utils → internal/utils}/completeToastExit.d.ts +0 -0
  294. /package/dist/components/feedback/Toast/{utils → internal/utils}/dismissToasts.d.ts +0 -0
  295. /package/dist/components/feedback/Toast/{utils → internal/utils}/isToastVisible.d.ts +0 -0
  296. /package/dist/primitives/layout/{AnimatedExpandableContainer → Collapsible}/types/AnimationDimension.d.ts +0 -0
  297. /package/dist/primitives/layout/{AnimatedExpandableContainer → Collapsible}/types/AnimationDurationObject.d.ts +0 -0
  298. /package/dist/primitives/layout/{AnimatedExpandableContainer → Collapsible}/types/AnimationDurations.d.ts +0 -0
  299. /package/dist/{primitives/navigation/ListItem → utilities}/internal/isRenderableSlot.d.ts +0 -0
@@ -0,0 +1,2144 @@
1
+ import { As as jt, Bt as pt, Cn as Ht, Ei as Vt, En as Gt, Hc as Jt, Mo as Kt, Nn as Ut, Tn as Yt, Uo as Xt, Xc as Qt, Yi as qe, ca as Zt, mc as er, nr as tr, nt as De, pl as Se, qc as rr, wa as ft, wn as nr } from "./icon-B7aZ6RxF.js";
2
+ import { t as u } from "./isDefined-fMi6eQ4r.js";
3
+ import { a as ee, h as or, r as H, t as ar } from "./theme-CjHovJAZ.js";
4
+ import { n as sr, t as ir } from "./handleClickableElementKeyDown-CJ_JsX2K.js";
5
+ import { t as cr } from "./isRenderableSlot-DT_depzM.js";
6
+ import { n as lr, r as dr, t as ur } from "./ProgressBar-21MXyySH.js";
7
+ import { o as mr } from "./utilities-CJKPcDM4.js";
8
+ import { t as vr } from "./Shortcut-CRCVbA2m.js";
9
+ import { a as j, n as _r, o as pr, r as ht, t as fr } from "./Switch-BQp0t6JZ.js";
10
+ import { n as te, t as hr } from "./useProvidedTextDirection-P1dtjUtE.js";
11
+ import { n as gt, r as bt, t as Ce } from "./OverflowingTextWithTooltip-CNpmkBvJ.js";
12
+ import { t as gr } from "./HorizontalSeparator-JwV0dB5W.js";
13
+ import { t as Ae } from "./ListItem-D8BQRK1W.js";
14
+ import { a as ie, n as br, r as Ir, t as Cr } from "./MenuSeparator-CyUYx1nk.js";
15
+ import { t as yr } from "./Heading-DvxTKEaL.js";
16
+ import { t as wr } from "./Avatar-C0FtFpJC.js";
17
+ import { n as Tr, t as Nr } from "./TabsTabContent-s6J5bZ3R.js";
18
+ import { clsx as g } from "clsx";
19
+ import { Fragment as J, jsx as n, jsxs as h } from "react/jsx-runtime";
20
+ import { isArray as kr, isBoolean as Sr, isFunction as Ar, isNonEmptyArray as xr, isNonEmptyString as z, isNumber as Lr, isPositiveInteger as Er, isString as ce } from "@sniptt/guards";
21
+ import { Collapsible as Ze } from "@base-ui/react/collapsible";
22
+ import { createContext as je, forwardRef as He, useCallback as le, useContext as ye, useEffect as Dr, useId as re, useLayoutEffect as me, useMemo as Mr, useRef as X, useState as M } from "react";
23
+ import { useRender as de } from "@base-ui/react/use-render";
24
+ import { Button as It } from "@base-ui/react/button";
25
+ import { Store as Pr, useStore as Rr } from "@base-ui/utils/store";
26
+ import { createPortal as Or } from "react-dom";
27
+ import { useMergedRefs as ve } from "@base-ui/utils/useMergedRefs";
28
+ import { Popover as Ct } from "@base-ui/react/popover";
29
+ import { useDirection as yt } from "@base-ui/react/direction-provider";
30
+ var Br = "_container_5cu4g_1", zr = "_itemContainer_5cu4g_6", Fr = "_overflowCountContainer_5cu4g_22", qr = "_overflowCount_5cu4g_22", ue = {
31
+ container: Br,
32
+ itemContainer: zr,
33
+ overflowCountContainer: Fr,
34
+ overflowCount: qr
35
+ }, $r = 4, Ci = ({ avatars: e, className: t, maxVisible: r = $r, overflowAvatar: o, overflowCount: a = 0, overflowShape: s = "square", overlap: i = "right", overlapOffset: c = "3px" }) => {
36
+ const l = e.slice(0, r), d = !o && a > 0;
37
+ if (!l.length && !o && !d) return null;
38
+ const m = { "--avatar-group-overlap-offset": c };
39
+ return /* @__PURE__ */ h("div", {
40
+ className: g(ue.container, t),
41
+ children: [
42
+ l.map((v, _) => /* @__PURE__ */ n("div", {
43
+ className: ue.itemContainer,
44
+ "data-overlap": i,
45
+ style: m,
46
+ children: v
47
+ }, _)),
48
+ o && /* @__PURE__ */ n("div", {
49
+ className: ue.itemContainer,
50
+ "data-overlap": i,
51
+ style: m,
52
+ children: o
53
+ }),
54
+ d && /* @__PURE__ */ n("div", {
55
+ className: g(ue.itemContainer, ue.overflowCountContainer),
56
+ "data-overlap": i,
57
+ style: m,
58
+ children: /* @__PURE__ */ h("div", {
59
+ className: ue.overflowCount,
60
+ "data-shape": s,
61
+ children: ["+", a]
62
+ })
63
+ })
64
+ ]
65
+ });
66
+ }, Wr = "_container_stu26_1", jr = "_commandContain_stu26_12", Hr = "_buttonContainer_stu26_16", Vr = "_lineStartSpan_stu26_20", Gr = "_lineSpan_stu26_24", fe = {
67
+ container: Wr,
68
+ commandContain: jr,
69
+ buttonContainer: Hr,
70
+ lineStartSpan: Vr,
71
+ lineSpan: Gr
72
+ }, yi = ({ commands: e, button: t }) => /* @__PURE__ */ h("div", {
73
+ className: fe.container,
74
+ children: [/* @__PURE__ */ n("div", {
75
+ className: fe.commandContain,
76
+ children: /* @__PURE__ */ n(J, { children: e.map((r, o) => /* @__PURE__ */ h("div", { children: [/* @__PURE__ */ n("span", {
77
+ className: fe.lineStartSpan,
78
+ children: "> "
79
+ }), /* @__PURE__ */ n("span", {
80
+ className: fe.lineSpan,
81
+ children: r
82
+ })] }, o)) })
83
+ }), t && /* @__PURE__ */ n("div", {
84
+ className: fe.buttonContainer,
85
+ children: t
86
+ })]
87
+ }), Jr = "_list_1i4lv_1", Kr = "_nested_1i4lv_8", et = {
88
+ list: Jr,
89
+ nested: Kr
90
+ }, Ur = ({ depth: e, className: t, children: r }) => /* @__PURE__ */ n("ul", {
91
+ className: g(et.list, e > 0 && et.nested, t),
92
+ children: r
93
+ }), wt = je(void 0), _e = () => {
94
+ const e = ye(wt);
95
+ if (!u(e)) throw new Error("useJsonTreeContextOrThrow must be used within a JsonTreeContextProvider");
96
+ return e;
97
+ }, Yr = "_button_1e3ij_1", Xr = "_red_1e3ij_17", Qr = "_chevron_1e3ij_22", Me = {
98
+ button: Yr,
99
+ red: Xr,
100
+ chevron: Qr
101
+ }, Zr = ({ isOpen: e, onClick: t, variant: r }) => {
102
+ const o = H(), { arrowButtonCollapsedLabel: a, arrowButtonExpandedLabel: s } = _e(), i = r === "blue" ? ee.color.blue : r === "red" ? ee.font.color.danger : ee.font.color.secondary;
103
+ return /* @__PURE__ */ h("button", {
104
+ className: g(Me.button, r === "red" && Me.red),
105
+ onClick: t,
106
+ children: [/* @__PURE__ */ n(sr, { children: e ? s : a }), /* @__PURE__ */ n("div", {
107
+ className: Me.chevron,
108
+ "data-open": e || void 0,
109
+ children: /* @__PURE__ */ n(nr, {
110
+ size: o.icon.size.md,
111
+ color: i
112
+ })
113
+ })]
114
+ });
115
+ }, en = ({ label: e, value: t, depth: r, keyPath: o, highlighting: a }) => {
116
+ const { emptyArrayLabel: s } = _e();
117
+ return /* @__PURE__ */ n(Ve, {
118
+ elements: [...t.entries()].map(([i, c]) => ({
119
+ id: i,
120
+ label: String(i),
121
+ value: c
122
+ })),
123
+ renderElementsCount: (i) => `[${i}]`,
124
+ label: e,
125
+ Icon: pt,
126
+ depth: r,
127
+ emptyElementsText: s,
128
+ keyPath: o,
129
+ highlighting: a
130
+ });
131
+ }, tn = ({ label: e, value: t, depth: r, keyPath: o, highlighting: a }) => {
132
+ const { emptyObjectLabel: s } = _e();
133
+ return /* @__PURE__ */ n(Ve, {
134
+ elements: Object.entries(t).map(([i, c]) => ({
135
+ id: i,
136
+ label: i,
137
+ value: c
138
+ })),
139
+ renderElementsCount: (i) => `{${i}}`,
140
+ label: e,
141
+ Icon: tr,
142
+ depth: r,
143
+ emptyElementsText: s,
144
+ keyPath: o,
145
+ highlighting: a
146
+ });
147
+ }, rn = "_labelContainer_1pq94_1", nn = "_blue_1pq94_23", on = "_red_1pq94_29", Pe = {
148
+ labelContainer: rn,
149
+ blue: nn,
150
+ red: on
151
+ }, Tt = ({ label: e, Icon: t, highlighting: r }) => {
152
+ const o = H();
153
+ return /* @__PURE__ */ h("span", {
154
+ className: g(Pe.labelContainer, r === "blue" && Pe.blue, r === "red" && Pe.red),
155
+ children: [/* @__PURE__ */ n(t, {
156
+ size: o.icon.size.md,
157
+ color: r === "blue" ? o.color.blue : r === "red" ? o.font.color.danger : o.font.color.tertiary
158
+ }), /* @__PURE__ */ n("span", { children: e })]
159
+ });
160
+ }, an = "_text_1ot24_1", sn = "_blue_1ot24_10", cn = "_red_1ot24_14", ln = "_button_1ot24_18", Te = {
161
+ text: an,
162
+ blue: sn,
163
+ red: cn,
164
+ button: ln
165
+ }, dn = ({ valueAsString: e, highlighting: t }) => {
166
+ const { onNodeValueClick: r } = _e(), o = u(r), a = () => {
167
+ r?.(e);
168
+ }, s = g(Te.text, t === "blue" && Te.blue, t === "red" && Te.red);
169
+ return o ? /* @__PURE__ */ n("button", {
170
+ className: g(s, Te.button),
171
+ type: "button",
172
+ onClick: a,
173
+ children: e
174
+ }) : /* @__PURE__ */ n("span", {
175
+ className: s,
176
+ children: e
177
+ });
178
+ }, un = "_listItem_1i7if_1", mn = { listItem: un }, be = (e) => /* @__PURE__ */ h("li", {
179
+ className: mn.listItem,
180
+ children: [e.label && /* @__PURE__ */ n(Tt, {
181
+ label: e.label,
182
+ Icon: e.Icon,
183
+ highlighting: e.highlighting
184
+ }), /* @__PURE__ */ n(dn, {
185
+ valueAsString: e.valueAsString,
186
+ highlighting: e.highlighting
187
+ })]
188
+ }), vn = (e) => kr(e), Nt = ({ label: e, value: t, depth: r, keyPath: o }) => {
189
+ const { getNodeHighlighting: a, emptyStringLabel: s } = _e(), i = a?.(o);
190
+ return u(t) ? ce(t) ? /* @__PURE__ */ n(be, {
191
+ label: e,
192
+ valueAsString: z(t) ? t : s,
193
+ Icon: rr,
194
+ highlighting: i
195
+ }) : Lr(t) ? /* @__PURE__ */ n(be, {
196
+ label: e,
197
+ valueAsString: String(t),
198
+ Icon: Kt,
199
+ highlighting: i
200
+ }) : Sr(t) ? /* @__PURE__ */ n(be, {
201
+ label: e,
202
+ valueAsString: String(t),
203
+ Icon: Ht,
204
+ highlighting: i
205
+ }) : vn(t) ? /* @__PURE__ */ n(en, {
206
+ label: e,
207
+ value: t,
208
+ depth: r,
209
+ keyPath: o,
210
+ highlighting: i
211
+ }) : /* @__PURE__ */ n(tn, {
212
+ label: e,
213
+ value: t,
214
+ depth: r,
215
+ keyPath: o,
216
+ highlighting: i
217
+ }) : /* @__PURE__ */ n(be, {
218
+ label: e,
219
+ valueAsString: "null",
220
+ Icon: Ut,
221
+ highlighting: i
222
+ });
223
+ }, _n = "_container_d0cqx_1", pn = "_labelContainer_d0cqx_6", fn = "_elementsCount_d0cqx_12", hn = "_elementsCountRed_d0cqx_16", gn = "_panel_d0cqx_20", bn = "_list_d0cqx_30", In = "_nested_d0cqx_37", Q = {
224
+ container: _n,
225
+ labelContainer: pn,
226
+ elementsCount: fn,
227
+ elementsCountRed: hn,
228
+ panel: gn,
229
+ list: bn,
230
+ nested: In
231
+ }, Ve = ({ label: e, Icon: t, elements: r, renderElementsCount: o, emptyElementsText: a, depth: s, keyPath: i, highlighting: c }) => {
232
+ const { shouldExpandNodeInitially: l } = _e(), d = !u(e), [m, v] = M(l({
233
+ keyPath: i,
234
+ depth: s
235
+ })), _ = /* @__PURE__ */ n("ul", {
236
+ className: g(Q.list, s > 0 && Q.nested),
237
+ children: r.length === 0 ? /* @__PURE__ */ n(be, {
238
+ valueAsString: a,
239
+ highlighting: void 0
240
+ }) : r.map(({ id: b, label: p, value: k }) => {
241
+ const C = z(i) ? `${i}.${b}` : String(b);
242
+ return /* @__PURE__ */ n(Nt, {
243
+ label: p,
244
+ value: k,
245
+ depth: s + 1,
246
+ keyPath: C
247
+ }, b);
248
+ })
249
+ }), f = () => {
250
+ v(!m);
251
+ };
252
+ return d ? /* @__PURE__ */ n("li", {
253
+ className: Q.container,
254
+ children: _
255
+ }) : /* @__PURE__ */ h(Ze.Root, {
256
+ className: Q.container,
257
+ open: m,
258
+ render: /* @__PURE__ */ n("li", {}),
259
+ children: [/* @__PURE__ */ h("div", {
260
+ className: Q.labelContainer,
261
+ children: [
262
+ /* @__PURE__ */ n(Zr, {
263
+ isOpen: m,
264
+ onClick: f,
265
+ variant: c === "partial-blue" ? "blue" : c === "red" ? c : void 0
266
+ }),
267
+ /* @__PURE__ */ n(Tt, {
268
+ label: e,
269
+ Icon: t,
270
+ highlighting: c === "red" ? c : void 0
271
+ }),
272
+ o && /* @__PURE__ */ n("span", {
273
+ className: g(Q.elementsCount, c === "red" && Q.elementsCountRed),
274
+ children: o(r.length)
275
+ })
276
+ ]
277
+ }), /* @__PURE__ */ n(Ze.Panel, {
278
+ className: Q.panel,
279
+ children: _
280
+ })]
281
+ });
282
+ }, Cn = ({ value: e, children: t }) => /* @__PURE__ */ n(wt.Provider, {
283
+ value: e,
284
+ children: t
285
+ }), yn = ({ depth: e }) => e <= 1, wi = ({ value: e, entries: t, shouldExpandNodeInitially: r = yn, ...o }) => /* @__PURE__ */ n(Cn, {
286
+ value: {
287
+ ...o,
288
+ shouldExpandNodeInitially: r
289
+ },
290
+ children: /* @__PURE__ */ n(Ur, {
291
+ depth: 0,
292
+ children: u(t) ? /* @__PURE__ */ n(Ve, {
293
+ elements: t,
294
+ Icon: pt,
295
+ depth: 0,
296
+ keyPath: "",
297
+ emptyElementsText: o.emptyObjectLabel
298
+ }) : /* @__PURE__ */ n(Nt, {
299
+ value: e ?? null,
300
+ depth: 0,
301
+ keyPath: ""
302
+ })
303
+ })
304
+ }), wn = "_row_1rw90_1", Tn = "_label_1rw90_11", tt = {
305
+ row: wn,
306
+ label: Tn
307
+ }, Ti = ({ children: e, startIcon: t, value: r, progress: o, progressColor: a, progressValueText: s, render: i, ref: c, className: l, ...d }) => {
308
+ const m = re();
309
+ return de({
310
+ render: i,
311
+ ref: c,
312
+ props: {
313
+ ...d,
314
+ className: g(tt.row, l),
315
+ children: /* @__PURE__ */ h(J, { children: [/* @__PURE__ */ h("div", {
316
+ className: tt.label,
317
+ children: [u(t) && /* @__PURE__ */ n(t, {
318
+ size: 14,
319
+ "aria-hidden": !0
320
+ }), /* @__PURE__ */ n("span", {
321
+ id: m,
322
+ children: e
323
+ })]
324
+ }), u(o) ? /* @__PURE__ */ n(dr, {
325
+ value: o,
326
+ size: "sm",
327
+ barColor: a,
328
+ "aria-labelledby": m,
329
+ "aria-valuetext": s ?? (ce(r) ? r : void 0),
330
+ children: r
331
+ }) : /* @__PURE__ */ n("span", { children: r })] })
332
+ }
333
+ });
334
+ }, Nn = "_notificationCounter_1lalu_1", kn = "_primary_1lalu_13", Sn = "_secondary_1lalu_18", rt = {
335
+ notificationCounter: Nn,
336
+ primary: kn,
337
+ secondary: Sn
338
+ }, Ni = ({ count: e, variant: t = "primary", className: r }) => /* @__PURE__ */ n("div", {
339
+ className: g(rt.notificationCounter, rt[t], r),
340
+ children: e
341
+ }), An = "_root_j2xk4_1", xn = { root: An }, Ln = ({ $backgroundColor: e, $borderColor: t, $dimension: r, className: o, style: a, ...s }) => /* @__PURE__ */ n("div", {
342
+ ...s,
343
+ className: g(xn.root, o),
344
+ style: {
345
+ "--tinted-icon-tile-background-color": e,
346
+ "--tinted-icon-tile-border": t ? `1px solid ${t}` : void 0,
347
+ "--tinted-icon-tile-dimension": r,
348
+ ...a
349
+ }
350
+ }), Re = {
351
+ background: 4,
352
+ border: 6,
353
+ icon: 10
354
+ }, Oe = (e, t) => ee.color[`${e}${t}`] ?? ee.tag.text[e], En = (e) => {
355
+ const t = mr(e);
356
+ return {
357
+ backgroundColor: Oe(t, Re.background),
358
+ iconColor: Oe(t, Re.icon),
359
+ borderColor: Oe(t, Re.border)
360
+ };
361
+ }, kt = ({ Icon: e, color: t = or, size: r, stroke: o }) => {
362
+ const a = H(), s = En(t), i = r ?? a.icon.size.md, c = o ?? a.icon.stroke.md, l = u(r) ? `${r}px` : void 0;
363
+ return /* @__PURE__ */ n(Ln, {
364
+ $backgroundColor: s.backgroundColor,
365
+ $dimension: l,
366
+ children: /* @__PURE__ */ n(e, {
367
+ size: i,
368
+ stroke: c,
369
+ color: s.iconColor
370
+ })
371
+ });
372
+ }, Dn = "_container_101hq_1", Mn = "_containerFullWidth_101hq_14", Pn = "_containerInfo_101hq_18", Rn = "_containerWarning_101hq_23", On = "_containerSuccess_101hq_28", Bn = "_containerError_101hq_33", zn = "_containerNeutral_101hq_38", Fn = "_header_101hq_43", qn = "_iconContainer_101hq_52", $n = "_iconContainerInfo_101hq_61", Wn = "_iconContainerWarning_101hq_65", jn = "_iconContainerSuccess_101hq_69", Hn = "_iconContainerError_101hq_73", Vn = "_iconContainerNeutral_101hq_77", Gn = "_title_101hq_81", Jn = "_descriptionWrapper_101hq_93", Kn = "_descriptionWrapperWithAction_101hq_101", Un = "_description_101hq_93", Yn = "_footer_101hq_114", Xn = "_closeButton_101hq_121", O = {
373
+ container: Dn,
374
+ containerFullWidth: Mn,
375
+ containerInfo: Pn,
376
+ containerWarning: Rn,
377
+ containerSuccess: On,
378
+ containerError: Bn,
379
+ containerNeutral: zn,
380
+ header: Fn,
381
+ iconContainer: qn,
382
+ iconContainerInfo: $n,
383
+ iconContainerWarning: Wn,
384
+ iconContainerSuccess: jn,
385
+ iconContainerError: Hn,
386
+ iconContainerNeutral: Vn,
387
+ title: Gn,
388
+ descriptionWrapper: Jn,
389
+ descriptionWrapperWithAction: Kn,
390
+ description: Un,
391
+ footer: Yn,
392
+ closeButton: Xn
393
+ }, Qn = {
394
+ info: O.containerInfo,
395
+ warning: O.containerWarning,
396
+ error: O.containerError,
397
+ neutral: O.containerNeutral,
398
+ success: O.containerSuccess
399
+ }, Zn = {
400
+ info: O.iconContainerInfo,
401
+ warning: O.iconContainerWarning,
402
+ error: O.iconContainerError,
403
+ neutral: O.iconContainerNeutral,
404
+ success: O.iconContainerSuccess
405
+ }, ki = ({ variant: e, title: t, description: r, fullWidth: o = !1, Icon: a = Zt, action: s, isClosable: i = !1, closeLabel: c = "Close", onClose: l }) => {
406
+ const [d, m] = M(!0), v = () => {
407
+ i && (m(!1), l?.());
408
+ };
409
+ return d ? /* @__PURE__ */ h("div", {
410
+ className: g(O.container, Qn[e], o && O.containerFullWidth),
411
+ children: [
412
+ /* @__PURE__ */ h("div", {
413
+ className: O.header,
414
+ children: [
415
+ /* @__PURE__ */ n("div", {
416
+ className: g(O.iconContainer, Zn[e]),
417
+ children: /* @__PURE__ */ n(a, { size: 16 })
418
+ }),
419
+ /* @__PURE__ */ n("div", {
420
+ className: O.title,
421
+ children: t
422
+ }),
423
+ i && /* @__PURE__ */ n(j, {
424
+ startIcon: /* @__PURE__ */ n(Se, {}),
425
+ className: O.closeButton,
426
+ variant: "ghost",
427
+ size: "sm",
428
+ "aria-label": c,
429
+ onClick: v
430
+ })
431
+ ]
432
+ }),
433
+ z(r) && /* @__PURE__ */ n("div", {
434
+ className: g(O.descriptionWrapper, u(s) && O.descriptionWrapperWithAction),
435
+ children: /* @__PURE__ */ n("div", {
436
+ className: O.description,
437
+ children: r
438
+ })
439
+ }),
440
+ u(s) && /* @__PURE__ */ n("div", {
441
+ className: O.footer,
442
+ children: /* @__PURE__ */ n(j, {
443
+ type: "button",
444
+ onClick: s.onClick,
445
+ size: "sm",
446
+ variant: "ghost",
447
+ style: { fontWeight: "var(--t-font-weight-regular)" },
448
+ children: s.label
449
+ })
450
+ })
451
+ ]
452
+ }) : null;
453
+ }, eo = "_banner_1w4g2_1", to = "_embedded_1w4g2_6", ro = "_bannerContent_1w4g2_10", no = "_bannerText_1w4g2_21", oo = "_compact_1w4g2_26", ao = "_compactBlue_1w4g2_43", so = "_compactDanger_1w4g2_48", ae = {
454
+ banner: eo,
455
+ embedded: to,
456
+ bannerContent: ro,
457
+ bannerText: no,
458
+ compact: oo,
459
+ compactBlue: ao,
460
+ compactDanger: so
461
+ }, io = ({ color: e, title: t, Icon: r, hidden: o, onClick: a, href: s, render: i, target: c, rel: l, download: d, disabled: m, "aria-label": v }) => o ? null : /* @__PURE__ */ n(j, {
462
+ onClick: a,
463
+ href: s,
464
+ render: i,
465
+ target: c,
466
+ rel: l,
467
+ download: d,
468
+ disabled: m,
469
+ "aria-label": v,
470
+ size: "sm",
471
+ startIcon: u(r) ? /* @__PURE__ */ n(r, {}) : void 0,
472
+ variant: "outline",
473
+ color: e === "danger" ? "danger" : "accent",
474
+ children: t
475
+ }), Si = ({ color: e = "blue", message: t, variant: r = "standard", embedded: o = !1, button: a, LeftIcon: s = ft, className: i }) => {
476
+ const c = H(), l = r === "compact";
477
+ return /* @__PURE__ */ h(lr, {
478
+ className: g(ae.banner, l && ae.compact, l && (e === "danger" ? ae.compactDanger : ae.compactBlue), o && ae.embedded, i),
479
+ color: e,
480
+ variant: "secondary",
481
+ children: [/* @__PURE__ */ h("div", {
482
+ className: ae.bannerContent,
483
+ children: [/* @__PURE__ */ n(s, { size: c.icon.size.md }), /* @__PURE__ */ n("div", {
484
+ className: ae.bannerText,
485
+ children: l ? t : /* @__PURE__ */ n(Ce, {
486
+ isFocusable: !0,
487
+ text: /* @__PURE__ */ n(J, { children: t }),
488
+ tooltipContent: t
489
+ })
490
+ })]
491
+ }), u(a) && /* @__PURE__ */ n(io, {
492
+ ...a,
493
+ color: e
494
+ })]
495
+ });
496
+ }, xe = (e) => e.status === "visible", St = ({ store: e, toastsToClose: t, nextToasts: r = e.state.toasts }) => {
497
+ const o = r.map((s) => t.includes(s) ? {
498
+ ...s,
499
+ status: "closing"
500
+ } : s), a = e.state.mountedToasterCount > 0;
501
+ e.set("toasts", a ? o : o.filter(xe));
502
+ for (const s of t) s.notification.onClose?.();
503
+ }, At = je(void 0), we = () => {
504
+ const e = ye(At);
505
+ if (!u(e)) throw new Error("Toast components must be used within a ToastProvider.");
506
+ return e;
507
+ }, xt = () => {
508
+ const e = we();
509
+ return { closeToast: (r) => {
510
+ const o = e.state.toasts.filter((a) => xe(a) && (!u(r) || a.notification.id === r));
511
+ xr(o) && St({
512
+ store: e,
513
+ toastsToClose: o
514
+ });
515
+ } };
516
+ }, nt = 0, co = () => {
517
+ const e = we();
518
+ return { enqueueToast: Mr(() => {
519
+ function t(r) {
520
+ if (!u(r)) return;
521
+ const { dedupeKey: o, ...a } = r, { toasts: s, limit: i } = e.state, c = s.filter(xe), l = u(o) ? c.find((v) => v.dedupeKey === o) : void 0;
522
+ if (u(l)) return l.notification.id;
523
+ nt += 1;
524
+ const d = `toast-${nt}`, m = Math.max(0, c.length - i + 1);
525
+ return St({
526
+ store: e,
527
+ toastsToClose: c.slice(0, m),
528
+ nextToasts: [...s, {
529
+ notification: {
530
+ ...a,
531
+ id: d
532
+ },
533
+ dedupeKey: o,
534
+ status: "visible"
535
+ }]
536
+ }), d;
537
+ }
538
+ return t;
539
+ }, [e]) };
540
+ }, Ai = () => {
541
+ const { closeToast: e } = xt(), { enqueueToast: t } = co();
542
+ return {
543
+ enqueueToast: t,
544
+ closeToast: e
545
+ };
546
+ }, lo = "_root_181ka_1", uo = "_progress_181ka_19", mo = "_header_181ka_30", vo = "_message_181ka_40", _o = "_icon_181ka_45", po = "_actions_181ka_50", fo = "_description_181ka_56", ho = "_footer_181ka_65", go = "_footerAction_181ka_69", bo = "_closeButton_181ka_76", U = {
547
+ root: lo,
548
+ progress: uo,
549
+ header: mo,
550
+ message: vo,
551
+ icon: _o,
552
+ actions: po,
553
+ description: fo,
554
+ footer: ho,
555
+ footerAction: go,
556
+ closeButton: bo
557
+ }, Io = "_countdown_1njr8_1", Co = "_toastCountdown_1njr8_1", yo = {
558
+ countdown: Io,
559
+ toastCountdown: Co
560
+ }, wo = ({ progress: e, duration: t, isPaused: r, barColor: o, onClose: a }) => u(e) ? /* @__PURE__ */ n(ur, {
561
+ value: e,
562
+ barColor: o
563
+ }) : /* @__PURE__ */ n("div", {
564
+ className: yo.countdown,
565
+ "data-paused": r || void 0,
566
+ onAnimationEnd: a,
567
+ style: {
568
+ "--toast-countdown-color": o,
569
+ "--toast-countdown-duration": `${t}ms`
570
+ }
571
+ }), To = {
572
+ default: De,
573
+ error: De,
574
+ success: er,
575
+ info: ft,
576
+ warning: De
577
+ }, No = ({ children: e, description: t, icon: r, iconLabel: o, action: a, progress: s, duration: i = 6e3, onCancel: c, onClose: l, cancelLabel: d = "Cancel", closeLabel: m = "Close", variant: v = "default", role: _ = "status", className: f, onMouseEnter: b, onMouseLeave: p, onFocus: k, onBlur: C, render: I, ref: w, ...T }) => {
578
+ const y = H(), [L, D] = M(!1), [N, S] = M(!1), R = To[v];
579
+ return de({
580
+ render: I,
581
+ ref: w,
582
+ props: {
583
+ role: _,
584
+ "aria-live": _ === "alert" ? "assertive" : "polite",
585
+ ...T,
586
+ className: g(U.root, f),
587
+ onMouseEnter: (A) => {
588
+ D(!0), b?.(A);
589
+ },
590
+ onMouseLeave: (A) => {
591
+ D(!1), p?.(A);
592
+ },
593
+ onFocus: (A) => {
594
+ S(!0), k?.(A);
595
+ },
596
+ onBlur: (A) => {
597
+ A.currentTarget.contains(A.relatedTarget) || S(!1), C?.(A);
598
+ },
599
+ children: /* @__PURE__ */ h(J, { children: [
600
+ /* @__PURE__ */ n("div", {
601
+ className: U.progress,
602
+ "aria-hidden": !0,
603
+ children: /* @__PURE__ */ n(wo, {
604
+ barColor: y.snackBar[v].backgroundColor,
605
+ progress: s,
606
+ duration: i,
607
+ isPaused: L || N,
608
+ onClose: l
609
+ })
610
+ }),
611
+ /* @__PURE__ */ h("div", {
612
+ className: U.header,
613
+ children: [
614
+ /* @__PURE__ */ n("div", {
615
+ className: U.icon,
616
+ children: r ?? /* @__PURE__ */ n(R, {
617
+ "aria-label": o,
618
+ "aria-hidden": !u(o),
619
+ color: y.snackBar[v].color,
620
+ size: y.icon.size.md
621
+ })
622
+ }),
623
+ /* @__PURE__ */ n("div", {
624
+ className: U.message,
625
+ children: e
626
+ }),
627
+ /* @__PURE__ */ h("div", {
628
+ className: U.actions,
629
+ children: [u(c) && /* @__PURE__ */ n(j, {
630
+ onClick: c,
631
+ size: "sm",
632
+ variant: "ghost",
633
+ style: { fontWeight: "var(--t-font-weight-regular)" },
634
+ children: d
635
+ }), u(l) && /* @__PURE__ */ n(j, {
636
+ title: m,
637
+ "aria-label": m,
638
+ startIcon: /* @__PURE__ */ n(Se, {}),
639
+ className: U.closeButton,
640
+ variant: "ghost",
641
+ size: "sm",
642
+ onClick: l
643
+ })]
644
+ })
645
+ ]
646
+ }),
647
+ u(t) && /* @__PURE__ */ n("div", {
648
+ className: U.description,
649
+ children: t
650
+ }),
651
+ u(a) && /* @__PURE__ */ h("div", {
652
+ className: U.footer,
653
+ children: [/* @__PURE__ */ n(gr, { noMargin: !0 }), /* @__PURE__ */ n("div", {
654
+ className: U.footerAction,
655
+ children: a
656
+ })]
657
+ })
658
+ ] })
659
+ }
660
+ });
661
+ }, ko = (e = 3) => {
662
+ if (!Er(e)) throw new Error("Toast limit must be a positive integer.");
663
+ return new Pr({
664
+ toasts: [],
665
+ limit: e,
666
+ mountedToasterCount: 0
667
+ });
668
+ }, xi = ({ children: e, limit: t = 3 }) => {
669
+ const [r] = M(() => ko(t));
670
+ return /* @__PURE__ */ n(At.Provider, {
671
+ value: r,
672
+ children: e
673
+ });
674
+ }, So = "_root_1q2cc_1", Ao = "_item_1q2cc_20", xo = "_itemContent_1q2cc_47", $e = {
675
+ root: So,
676
+ item: Ao,
677
+ itemContent: xo
678
+ }, Lo = () => Rr(we(), (e) => e.toasts), ot = ({ store: e, toast: t }) => {
679
+ const { toasts: r } = e.state;
680
+ t.status === "closing" && r.includes(t) && e.set("toasts", r.filter((o) => o !== t));
681
+ }, Eo = ({ elementRef: e, toastEntry: t }) => {
682
+ const r = we();
683
+ return me(() => {
684
+ if (t.status === "visible") return;
685
+ const o = e.current?.getAnimations?.() ?? [];
686
+ if (o.length === 0) {
687
+ ot({
688
+ store: r,
689
+ toast: t
690
+ });
691
+ return;
692
+ }
693
+ let a = !1;
694
+ return Promise.allSettled(o.map((s) => s.finished)).then(() => {
695
+ a || ot({
696
+ store: r,
697
+ toast: t
698
+ });
699
+ }), () => {
700
+ a = !0;
701
+ };
702
+ }, [
703
+ e,
704
+ t,
705
+ r
706
+ ]), /* @__PURE__ */ n(J, {});
707
+ }, Do = ({ toastEntry: e, getToastProps: t, onClose: r }) => {
708
+ const { notification: o, status: a } = e, { id: s, ...i } = o, c = X(null);
709
+ return /* @__PURE__ */ h(J, { children: [/* @__PURE__ */ n("div", {
710
+ ref: c,
711
+ className: $e.item,
712
+ "data-exiting": a === "closing" || void 0,
713
+ inert: a === "closing",
714
+ children: /* @__PURE__ */ n("div", {
715
+ className: $e.itemContent,
716
+ children: /* @__PURE__ */ n(No, {
717
+ ...i,
718
+ ...t?.(o),
719
+ id: s,
720
+ onClose: () => r(s)
721
+ })
722
+ })
723
+ }), /* @__PURE__ */ n(Eo, {
724
+ elementRef: c,
725
+ toastEntry: e
726
+ })] });
727
+ }, Mo = ({ getToastProps: e }) => {
728
+ const t = Lo(), { closeToast: r } = xt();
729
+ return t.map((o) => /* @__PURE__ */ n(Do, {
730
+ toastEntry: o,
731
+ getToastProps: e,
732
+ onClose: r
733
+ }, o.notification.id));
734
+ }, Po = () => {
735
+ const e = we();
736
+ return me(() => (e.set("mountedToasterCount", e.state.mountedToasterCount + 1), () => {
737
+ e.set("mountedToasterCount", e.state.mountedToasterCount - 1), !(e.state.mountedToasterCount > 0) && e.set("toasts", e.state.toasts.filter(xe));
738
+ }), [e]), null;
739
+ }, Li = ({ container: e, getToastProps: t, className: r, render: o, ref: a, ...s }) => {
740
+ const i = ar(), c = hr(), l = e === void 0 ? i ?? (typeof document > "u" ? null : document.body) : e, d = de({
741
+ render: o,
742
+ ref: a,
743
+ props: {
744
+ role: "region",
745
+ dir: c,
746
+ "aria-label": "Notifications",
747
+ ...s,
748
+ className: g($e.root, r),
749
+ children: /* @__PURE__ */ h(J, { children: [/* @__PURE__ */ n(Po, {}), /* @__PURE__ */ n(Mo, { getToastProps: t })] })
750
+ }
751
+ });
752
+ return u(l) ? Or(d, l) : null;
753
+ }, Ro = "_button_1qwl0_1", Oo = "_tooltipAnchor_1qwl0_29", Bo = "_icon_1qwl0_33", Be = {
754
+ button: Ro,
755
+ tooltipAnchor: Oo,
756
+ icon: Bo
757
+ }, zo = ({ children: e, size: t = "md", shape: r = "square", className: o, tooltip: a, tooltipPlace: s = "bottom", tooltipDelay: i = 1e3, tooltipOffset: c = 5, disabled: l, loading: d, ...m }) => {
758
+ const v = ye(pr)?.size ?? t, _ = z(a), f = l || d, b = /* @__PURE__ */ n(j, {
759
+ ...m,
760
+ size: t === "xs" ? "sm" : t,
761
+ "data-icon-size": v,
762
+ "data-shape": r,
763
+ disabled: l,
764
+ loading: d,
765
+ startIcon: /* @__PURE__ */ n("span", {
766
+ className: Be.icon,
767
+ children: e
768
+ }),
769
+ className: te(Be.button, o)
770
+ });
771
+ return _ ? /* @__PURE__ */ n(bt, {
772
+ content: a,
773
+ delay: i,
774
+ side: s,
775
+ sideOffset: c,
776
+ children: f ? /* @__PURE__ */ n("span", {
777
+ className: Be.tooltipAnchor,
778
+ children: b
779
+ }) : b
780
+ }) : b;
781
+ }, Fo = "_root_u3myi_1", qo = "_preview_u3myi_6", $o = "_image_u3myi_35", Wo = "_fileInput_u3myi_48", jo = "_content_u3myi_58", Ho = "_actions_u3myi_67", Vo = "_helperText_u3myi_73", Go = "_errorMessage_u3myi_78", Z = {
782
+ root: Fo,
783
+ preview: qo,
784
+ image: $o,
785
+ fileInput: Wo,
786
+ content: jo,
787
+ actions: Ho,
788
+ helperText: Vo,
789
+ errorMessage: Go
790
+ }, Jo = ({ src: e }) => {
791
+ const t = H(), [r, o] = M(!1);
792
+ return !z(e) || r ? /* @__PURE__ */ n(Xt, {
793
+ size: t.icon.size.lg,
794
+ "aria-hidden": !0
795
+ }) : /* @__PURE__ */ n("img", {
796
+ className: Z.image,
797
+ src: e,
798
+ alt: "",
799
+ onError: () => o(!0)
800
+ });
801
+ }, Ei = ({ src: e, onUpload: t, onRemove: r, onAbort: o, disabled: a = !1, isUploading: s = !1, helperText: i, errorMessage: c, uploadLabel: l = "Upload", removeLabel: d = "Remove", abortLabel: m = "Abort", accept: v = "image/*", className: _, render: f, ref: b, ...p }) => {
802
+ const k = X(null), C = re(), I = `${C}-helper`, w = `${C}-error`, T = z(e), y = z(i), L = z(c), D = a || !u(t), N = a || !T || !u(r), S = D || s, R = N || s, A = s && u(o), F = [y && I, L && w].filter(z).join(" ") || void 0, E = () => {
803
+ S || k.current?.click();
804
+ }, P = (B) => {
805
+ const $ = B.currentTarget.files?.[0];
806
+ B.currentTarget.value = "", !(S || !u($)) && t?.($);
807
+ };
808
+ return de({
809
+ render: f,
810
+ ref: b,
811
+ props: {
812
+ ...p,
813
+ className: g(Z.root, _),
814
+ "aria-busy": s || p["aria-busy"],
815
+ children: /* @__PURE__ */ h(J, { children: [/* @__PURE__ */ n("button", {
816
+ className: Z.preview,
817
+ type: "button",
818
+ disabled: D,
819
+ "aria-disabled": s || void 0,
820
+ "aria-label": l,
821
+ "aria-describedby": F,
822
+ onClick: E,
823
+ children: /* @__PURE__ */ n(Jo, { src: e }, e)
824
+ }), /* @__PURE__ */ h("div", {
825
+ className: Z.content,
826
+ children: [
827
+ /* @__PURE__ */ h("div", {
828
+ className: Z.actions,
829
+ children: [
830
+ /* @__PURE__ */ n("input", {
831
+ ref: k,
832
+ className: Z.fileInput,
833
+ type: "file",
834
+ accept: v,
835
+ disabled: S,
836
+ hidden: !0,
837
+ onChange: P
838
+ }),
839
+ A ? /* @__PURE__ */ n(j, {
840
+ type: "button",
841
+ startIcon: /* @__PURE__ */ n(Se, {}),
842
+ onClick: o,
843
+ disabled: a,
844
+ variant: "outline",
845
+ children: m
846
+ }) : /* @__PURE__ */ n(j, {
847
+ type: "button",
848
+ startIcon: /* @__PURE__ */ n(Qt, {}),
849
+ onClick: E,
850
+ disabled: S,
851
+ focusableWhenDisabled: s && !D,
852
+ "aria-describedby": F,
853
+ variant: "outline",
854
+ children: l
855
+ }),
856
+ /* @__PURE__ */ n(j, {
857
+ type: "button",
858
+ startIcon: /* @__PURE__ */ n(Jt, {}),
859
+ onClick: r,
860
+ disabled: R,
861
+ focusableWhenDisabled: s && !N,
862
+ variant: "outline",
863
+ children: d
864
+ })
865
+ ]
866
+ }),
867
+ y && /* @__PURE__ */ n("span", {
868
+ className: Z.helperText,
869
+ id: I,
870
+ children: i
871
+ }),
872
+ L && /* @__PURE__ */ n("span", {
873
+ className: Z.errorMessage,
874
+ id: w,
875
+ role: "alert",
876
+ children: c
877
+ })
878
+ ]
879
+ })] })
880
+ }
881
+ });
882
+ }, Ko = "_button_k3e4y_1", Uo = { button: Ko }, Di = ({ className: e, emphasis: t = "standard", size: r = "sm", variant: o = "ghost", ...a }) => /* @__PURE__ */ n(j, {
883
+ ...a,
884
+ size: r,
885
+ variant: o,
886
+ "data-emphasis": t,
887
+ className: te(Uo.button, e)
888
+ }), Yo = "_button_prhtf_1", Xo = { button: Yo }, Qo = ({ className: e, emphasis: t = "standard", size: r = "sm", variant: o = "ghost", ...a }) => /* @__PURE__ */ n(zo, {
889
+ ...a,
890
+ size: r,
891
+ variant: o,
892
+ "data-emphasis": t,
893
+ className: te(Xo.button, e)
894
+ }), Zo = "_button_1fwx7_1", ea = { button: Zo }, Mi = ({ className: e, elevated: t = !0, variant: r = "solid", ...o }) => /* @__PURE__ */ n(j, {
895
+ ...o,
896
+ elevated: t,
897
+ variant: r,
898
+ className: te(ea.button, e)
899
+ }), ta = "_wrapper_fz4xu_1", ra = "_filterButton_fz4xu_8", na = "_inputGroup_fz4xu_17", oa = "_searchIcon_fz4xu_23", Ne = {
900
+ wrapper: ta,
901
+ filterButton: ra,
902
+ inputGroup: na,
903
+ searchIcon: oa
904
+ }, Pi = ({ placeholder: e, filterDropdown: t, size: r = "md", id: o, filterButtonAriaLabel: a = "Filter", "aria-label": s, "aria-labelledby": i, ...c }) => {
905
+ const l = H(), d = re(), m = o ?? d, v = /* @__PURE__ */ n(j, {
906
+ variant: "outline",
907
+ size: r,
908
+ "aria-label": a,
909
+ startIcon: /* @__PURE__ */ n(Vt, { size: l.icon.size.md }),
910
+ className: Ne.filterButton
911
+ });
912
+ return /* @__PURE__ */ h("div", {
913
+ className: Ne.wrapper,
914
+ children: [/* @__PURE__ */ n(_r, {
915
+ className: Ne.inputGroup,
916
+ size: r,
917
+ startElement: /* @__PURE__ */ n(jt, {
918
+ className: Ne.searchIcon,
919
+ size: l.icon.size.md,
920
+ "aria-hidden": !0
921
+ }),
922
+ children: /* @__PURE__ */ n(ht, {
923
+ ...c,
924
+ id: m,
925
+ placeholder: e,
926
+ "aria-label": z(i) ? void 0 : s ?? e,
927
+ "aria-labelledby": i
928
+ })
929
+ }), t?.(v)]
930
+ });
931
+ }, Ri = ({ children: e, startIcon: t, description: r, focused: o = !1, checked: a, defaultChecked: s, onCheckedChange: i, disabled: c = !1, readOnly: l = !1, size: d = "sm", name: m, value: v, required: _, className: f, style: b, ref: p, ...k }) => {
932
+ const C = re(), I = `${C}-label`, w = `${C}-description`, T = cr(r);
933
+ return /* @__PURE__ */ n(Ae, {
934
+ className: f,
935
+ style: b,
936
+ startIcon: t,
937
+ focused: o,
938
+ disabled: c,
939
+ description: T && /* @__PURE__ */ n("span", {
940
+ id: w,
941
+ children: r
942
+ }),
943
+ render: (y) => /* @__PURE__ */ n("label", {
944
+ ...k,
945
+ ...y,
946
+ htmlFor: C,
947
+ ref: p
948
+ }),
949
+ endIcon: /* @__PURE__ */ n(fr, {
950
+ id: C,
951
+ "aria-labelledby": I,
952
+ "aria-describedby": T ? w : void 0,
953
+ checked: a,
954
+ defaultChecked: s,
955
+ onCheckedChange: i,
956
+ disabled: c,
957
+ readOnly: l,
958
+ size: d,
959
+ name: m,
960
+ value: v,
961
+ required: _
962
+ }),
963
+ children: /* @__PURE__ */ n("span", {
964
+ id: I,
965
+ children: e
966
+ })
967
+ });
968
+ }, aa = "_container_gwbng_1", sa = "_layer_gwbng_8", ia = "_visible_gwbng_22", ca = "_hidden_gwbng_27", se = {
969
+ container: aa,
970
+ layer: sa,
971
+ visible: ia,
972
+ hidden: ca
973
+ }, Oi = ({ isActive: e, ActiveIcon: t, InactiveIcon: r, size: o }) => {
974
+ const a = H(), s = o ?? a.icon.size.sm;
975
+ return /* @__PURE__ */ h("div", {
976
+ className: se.container,
977
+ style: { "--animated-icon-crossfade-size": `${s}px` },
978
+ children: [/* @__PURE__ */ n("div", {
979
+ className: g(se.layer, e ? se.hidden : se.visible),
980
+ children: /* @__PURE__ */ n(r, { size: s })
981
+ }), /* @__PURE__ */ n("div", {
982
+ className: g(se.layer, e ? se.visible : se.hidden),
983
+ children: /* @__PURE__ */ n(t, { size: s })
984
+ })]
985
+ });
986
+ }, la = "_root_1yq9n_1", da = "_items_1yq9n_11", ua = "_item_1yq9n_11", ma = "_trigger_1yq9n_45", va = "_popup_1yq9n_72", Ie = {
987
+ root: la,
988
+ items: da,
989
+ item: ua,
990
+ trigger: ma,
991
+ popup: va
992
+ }, Lt = (e) => le((t) => {
993
+ if (u(t))
994
+ return () => {
995
+ t.contains(t.ownerDocument.activeElement) && e();
996
+ };
997
+ }, [e]), _a = ({ children: e, isHidden: t, isLastVisible: r, onFocusedItemUnmount: o }) => /* @__PURE__ */ n("div", {
998
+ ref: Lt(o),
999
+ className: Ie.item,
1000
+ "data-hidden": t || void 0,
1001
+ "data-last-visible": r || void 0,
1002
+ "aria-hidden": t || void 0,
1003
+ inert: t,
1004
+ children: e
1005
+ }), at = ({ itemWidths: e, availableWidth: t, gap: r, includePartialItem: o }) => {
1006
+ let a = 0, s = 0;
1007
+ for (const i of e) {
1008
+ const c = a + i + (s > 0 ? r : 0);
1009
+ if (s !== 0 && c > t) {
1010
+ const l = a + r < t;
1011
+ return o && l ? s + 1 : s;
1012
+ }
1013
+ a = c, s += 1;
1014
+ }
1015
+ return s;
1016
+ }, pa = ({ items: e, itemElements: t, supportsSynchronousLayout: r }) => {
1017
+ if (!r) return t.map((a) => a.scrollWidth);
1018
+ e.setAttribute("data-measuring", "");
1019
+ const o = t.map((a) => a.clientWidth);
1020
+ return e.removeAttribute("data-measuring"), o;
1021
+ }, fa = 100, ha = ({ itemCount: e, inlineItemCount: t, reserveCountSpace: r, isMeasurementEnabled: o }) => {
1022
+ const a = X(null), s = X(null), i = X(null), c = X(void 0), l = X({
1023
+ itemCount: e,
1024
+ reserveCountSpace: r
1025
+ }), [d, m] = M(t), [v, _] = M(e > t);
1026
+ return me(() => {
1027
+ l.current = {
1028
+ itemCount: e,
1029
+ reserveCountSpace: r
1030
+ }, c.current?.();
1031
+ }, [
1032
+ e,
1033
+ t,
1034
+ r
1035
+ ]), me(() => {
1036
+ const f = a.current, b = s.current;
1037
+ if (!o || !u(f) || !u(b)) return;
1038
+ const p = u(globalThis.ResizeObserver), k = /* @__PURE__ */ new Set(), C = () => {
1039
+ const T = Array.from(b.children), y = /* @__PURE__ */ new Set([f, ...T]);
1040
+ u(i.current) && y.add(i.current);
1041
+ for (const P of k) y.has(P) || (I?.unobserve(P), k.delete(P));
1042
+ for (const P of y) k.has(P) || (I?.observe(P), k.add(P));
1043
+ const L = l.current, D = pa({
1044
+ items: b,
1045
+ itemElements: T,
1046
+ supportsSynchronousLayout: p
1047
+ }), N = parseFloat(getComputedStyle(b).columnGap) || 0, S = f.clientWidth, R = at({
1048
+ itemWidths: D,
1049
+ availableWidth: S,
1050
+ gap: N,
1051
+ includePartialItem: !1
1052
+ }), A = L.itemCount > R, F = i.current?.offsetWidth ?? 0, E = L.reserveCountSpace && A ? Math.max(0, S - F - N) : S;
1053
+ _(A), m(at({
1054
+ itemWidths: D,
1055
+ availableWidth: E,
1056
+ gap: N,
1057
+ includePartialItem: !L.reserveCountSpace
1058
+ }));
1059
+ }, I = p ? new ResizeObserver(C) : void 0;
1060
+ c.current = C, C();
1061
+ const w = new MutationObserver(C);
1062
+ if (w.observe(b, {
1063
+ attributes: !0,
1064
+ attributeFilter: [
1065
+ "class",
1066
+ "style",
1067
+ "hidden"
1068
+ ],
1069
+ characterData: !0,
1070
+ childList: !0,
1071
+ subtree: !0
1072
+ }), w.observe(f, { childList: !0 }), !u(I)) {
1073
+ const T = setInterval(C, fa);
1074
+ return window.addEventListener("resize", C), () => {
1075
+ c.current = void 0, clearInterval(T), w.disconnect(), window.removeEventListener("resize", C);
1076
+ };
1077
+ }
1078
+ return () => {
1079
+ c.current = void 0, w.disconnect(), I.disconnect();
1080
+ };
1081
+ }, [o]), {
1082
+ containerRef: a,
1083
+ itemsRef: s,
1084
+ triggerRef: i,
1085
+ visibleItemCount: d,
1086
+ hasOverflow: v
1087
+ };
1088
+ }, he = (e) => e.stopPropagation(), st = {
1089
+ onClick: he,
1090
+ onMouseDown: he,
1091
+ onPointerDown: he,
1092
+ onKeyDown: he,
1093
+ onKeyUp: he
1094
+ }, Bi = ({ children: e, showOverflowCount: t, maxInlineCount: r, overflowLabel: o = "Show all items", className: a, onMouseEnter: s, onMouseLeave: i, onFocusCapture: c, onBlurCapture: l, ref: d, ...m }) => {
1095
+ const [v, _] = M(!1), [f, b] = M(!1), [p, k] = M(!1), [C, I] = M(), w = t ?? C ?? (v || f || p), T = u(r) && Number.isFinite(r) ? Math.min(e.length, Math.max(0, Math.floor(r))) : e.length, { containerRef: y, itemsRef: L, triggerRef: D, visibleItemCount: N, hasOverflow: S } = ha({
1096
+ itemCount: e.length,
1097
+ inlineItemCount: T,
1098
+ reserveCountSpace: w,
1099
+ isMeasurementEnabled: t !== !1 || p
1100
+ }), R = le(() => {
1101
+ b(!1), I(void 0);
1102
+ }, []), A = Lt(R), F = ve(y, d), E = ve(D, A), P = t === !1 ? T : N, B = e.length - N, $ = S && (p || t !== !1);
1103
+ return p && !$ && k(!1), /* @__PURE__ */ n(ie.Root, {
1104
+ open: p && $,
1105
+ onOpenChange: k,
1106
+ children: /* @__PURE__ */ h("div", {
1107
+ ...m,
1108
+ ref: F,
1109
+ className: g(Ie.root, a),
1110
+ onMouseEnter: (x) => {
1111
+ _(!0), s?.(x);
1112
+ },
1113
+ onMouseLeave: (x) => {
1114
+ _(!1), i?.(x);
1115
+ },
1116
+ onFocusCapture: (x) => {
1117
+ b(!0), L.current?.contains(x.target) && I((oe) => oe ?? w), c?.(x);
1118
+ },
1119
+ onBlurCapture: (x) => {
1120
+ b(x.currentTarget.contains(x.relatedTarget)), L.current?.contains(x.relatedTarget) || I(void 0), l?.(x);
1121
+ },
1122
+ children: [
1123
+ /* @__PURE__ */ n("div", {
1124
+ ref: L,
1125
+ className: Ie.items,
1126
+ children: e.slice(0, T).map((x, oe) => /* @__PURE__ */ n(_a, {
1127
+ isHidden: oe >= P,
1128
+ isLastVisible: t !== !1 && oe === P - 1,
1129
+ onFocusedItemUnmount: R,
1130
+ children: x
1131
+ }, x.key ?? oe))
1132
+ }),
1133
+ $ && /* @__PURE__ */ h(ie.Trigger, {
1134
+ ref: E,
1135
+ type: "button",
1136
+ className: Ie.trigger,
1137
+ "data-visible": w || void 0,
1138
+ "aria-label": `+${B} ${o}`,
1139
+ ...st,
1140
+ children: ["+", B]
1141
+ }),
1142
+ /* @__PURE__ */ n(ie.Popup, {
1143
+ anchor: y,
1144
+ align: "start",
1145
+ sideOffset: -9,
1146
+ alignOffset: -7,
1147
+ "aria-label": o,
1148
+ className: Ie.popup,
1149
+ "data-overflowing-list-popup": "",
1150
+ ...st,
1151
+ children: e
1152
+ })
1153
+ ]
1154
+ })
1155
+ });
1156
+ }, ga = "_header_1r38k_1", ba = "_titleRow_1r38k_8", Ia = "_title_1r38k_8", Ca = "_adornment_1r38k_21", ya = "_description_1r38k_27", ge = {
1157
+ header: ga,
1158
+ titleRow: ba,
1159
+ title: Ia,
1160
+ adornment: Ca,
1161
+ description: ya
1162
+ }, wa = ({ title: e, description: t, adornment: r, level: o = 2, size: a = "md", color: s = "primary", descriptionLineClamp: i = 5, render: c, ref: l, className: d, ...m }) => {
1163
+ const v = re(), _ = ce(t) ? z(t) : u(t) && t !== !1;
1164
+ return de({
1165
+ render: c,
1166
+ ref: l,
1167
+ props: {
1168
+ ...m,
1169
+ className: g(ge.header, d),
1170
+ children: /* @__PURE__ */ h(J, { children: [/* @__PURE__ */ h("div", {
1171
+ className: ge.titleRow,
1172
+ children: [/* @__PURE__ */ n(yr, {
1173
+ level: o,
1174
+ size: a,
1175
+ color: s,
1176
+ className: ge.title,
1177
+ "aria-describedby": _ ? v : void 0,
1178
+ children: e
1179
+ }), u(r) && /* @__PURE__ */ n("div", {
1180
+ className: ge.adornment,
1181
+ children: r
1182
+ })]
1183
+ }), _ && /* @__PURE__ */ n("div", {
1184
+ id: v,
1185
+ className: ge.description,
1186
+ children: ce(t) ? /* @__PURE__ */ n(Ce, {
1187
+ text: t,
1188
+ displayedMaxRows: i,
1189
+ isTooltipMultiline: !0,
1190
+ isFocusable: !0
1191
+ }) : t
1192
+ })] })
1193
+ }
1194
+ });
1195
+ }, Ta = "_root_ztxxm_1", Na = "_fullWidth_ztxxm_20", it = {
1196
+ root: Ta,
1197
+ fullWidth: Na
1198
+ }, ka = ({ align: e = "left", color: t = "primary", fullWidth: r = !0, className: o, render: a, ref: s, ...i }) => de({
1199
+ render: a,
1200
+ ref: s,
1201
+ props: {
1202
+ ...i,
1203
+ "data-align": e,
1204
+ "data-color": t,
1205
+ className: g(it.root, r && it.fullWidth, o)
1206
+ }
1207
+ }), zi = {
1208
+ Root: ka,
1209
+ Header: wa
1210
+ }, Ge = (e) => e.getAttribute("aria-label") ?? e.textContent ?? "", Le = (e) => Array.from(e.querySelectorAll("[data-dropdown-item]")).filter((t) => t.getAttribute("aria-disabled") !== "true" && !t.hasAttribute("disabled") && t.closest("[data-dropdown-content]") === e), ke = je(void 0), V = () => {
1211
+ const e = ye(ke);
1212
+ if (!u(e)) throw new Error("Dropdown components must be inside Dropdown.Root");
1213
+ return e;
1214
+ }, Je = ({ id: e, isSubmenuTrigger: t = !1 }) => {
1215
+ const r = V(), o = t ? r.parentType : r.type, a = t ? r.parentActiveItemId : r.activeItemId, s = t ? r.setParentActiveItemId : r.setActiveItemId;
1216
+ return {
1217
+ tabIndex: o === "menu" && a !== e ? -1 : 0,
1218
+ activate: () => s?.(e)
1219
+ };
1220
+ }, Et = ({ color: e, startIcon: t, endIcon: r, description: o, descriptionPlacement: a, shortcut: s, shortcutJoinLabel: i, hasSubmenu: c, children: l, render: d, disabled: m = !1, nativeButton: v = !u(d), closeOnClick: _ = !0, onClick: f, onFocus: b, page: p, id: k, ...C }) => {
1221
+ const { type: I, closeTree: w, goToPage: T } = V(), y = re(), L = k ?? y, D = Je({ id: L });
1222
+ return /* @__PURE__ */ n(It, {
1223
+ ...C,
1224
+ id: L,
1225
+ disabled: m,
1226
+ nativeButton: v,
1227
+ role: C.role ?? (I === "menu" ? "menuitem" : void 0),
1228
+ tabIndex: D.tabIndex,
1229
+ onFocus: (N) => {
1230
+ D.activate(), b?.(N);
1231
+ },
1232
+ "data-dropdown-item": "",
1233
+ "data-dropdown-page": p,
1234
+ onClick: (N) => {
1235
+ if (f?.(N), !N.defaultPrevented) {
1236
+ if (u(p)) {
1237
+ const S = N.currentTarget.closest("[data-dropdown-content]");
1238
+ if (!u(S)) return;
1239
+ T({
1240
+ id: p,
1241
+ trigger: {
1242
+ id: k,
1243
+ index: Le(S).indexOf(N.currentTarget),
1244
+ page: p,
1245
+ label: Ge(N.currentTarget)
1246
+ }
1247
+ });
1248
+ return;
1249
+ }
1250
+ _ && w();
1251
+ }
1252
+ },
1253
+ render: (N) => /* @__PURE__ */ n(Ae, {
1254
+ ...N,
1255
+ render: d ?? /* @__PURE__ */ n("button", { type: "button" }),
1256
+ disabled: m,
1257
+ color: e,
1258
+ startIcon: t,
1259
+ endIcon: r,
1260
+ description: o,
1261
+ descriptionPlacement: a,
1262
+ shortcut: s,
1263
+ shortcutJoinLabel: i,
1264
+ hasSubmenu: c ?? u(p),
1265
+ children: l
1266
+ })
1267
+ });
1268
+ }, Sa = "_content_rrrph_1", Aa = "_page_rrrph_12", xa = "_section_rrrph_16", La = "_separator_rrrph_28", Ea = "_back_rrrph_36", Da = "_backIcon_rrrph_48", Ma = "_searchContainer_rrrph_52", Pa = "_search_rrrph_52", Ra = "_status_rrrph_69", Oa = "_header_rrrph_75", Ba = "_title_rrrph_88", G = {
1269
+ content: Sa,
1270
+ page: Aa,
1271
+ section: xa,
1272
+ separator: La,
1273
+ back: Ea,
1274
+ backIcon: Da,
1275
+ searchContainer: Ma,
1276
+ search: Pa,
1277
+ status: Ra,
1278
+ header: Oa,
1279
+ title: Ba
1280
+ }, za = ({ children: e = "Back", className: t, onClick: r, ...o }) => {
1281
+ const { goBack: a, canGoBack: s } = V();
1282
+ return /* @__PURE__ */ n(Et, {
1283
+ ...o,
1284
+ className: g(G.back, t),
1285
+ "data-dropdown-back": "",
1286
+ disabled: o.disabled || !s,
1287
+ startIcon: /* @__PURE__ */ n(Yt, { className: G.backIcon }),
1288
+ closeOnClick: !1,
1289
+ onClick: (i) => {
1290
+ r?.(i), !i.defaultPrevented && a();
1291
+ },
1292
+ children: e
1293
+ });
1294
+ }, Fa = ({ render: e, children: t, "aria-label": r, ...o }) => /* @__PURE__ */ n(Ct.Close, {
1295
+ ...o,
1296
+ "aria-label": r,
1297
+ render: e ?? /* @__PURE__ */ n(Qo, {
1298
+ size: "sm",
1299
+ "aria-label": r,
1300
+ children: t ?? /* @__PURE__ */ n(Se, {})
1301
+ }),
1302
+ children: u(e) ? t : void 0
1303
+ }), Ke = ({ content: e, target: t, edge: r = "first", type: o }) => {
1304
+ const a = u(t?.id) ? e.ownerDocument.getElementById(t.id) : null;
1305
+ if (u(a) && e.contains(a)) return a;
1306
+ const s = Le(e), i = u(t) ? s.filter((f) => f.dataset.dropdownPage === t.page) : [], [c] = i;
1307
+ if (i.length === 1 && u(c)) return c;
1308
+ const l = z(t?.label) ? i.filter((f) => Ge(f) === t?.label) : [], [d] = l;
1309
+ if (l.length === 1 && u(d)) return d;
1310
+ const m = u(t) ? s[t.index] : void 0;
1311
+ if (u(m)) return m;
1312
+ const v = e.querySelector('input:not(:disabled):not([type="hidden"]),button:not(:disabled),textarea:not(:disabled),select:not(:disabled),a[href],[tabindex="0"]');
1313
+ if ((Array.from(e.querySelectorAll("[data-dropdown-page-type]")).find((f) => f.closest("[data-dropdown-content]") === e)?.dataset.dropdownPageType ?? o ?? e.dataset.type) === "panel") return v ?? e;
1314
+ const _ = e.querySelector("[data-dropdown-search]:not(:disabled)");
1315
+ return u(_) ? _ : r === "last" ? s[s.length - 1] ?? v ?? e : s.find((f) => !f.hasAttribute("data-dropdown-back")) ?? s[0] ?? v ?? e;
1316
+ }, qa = ({ contentRef: e }) => {
1317
+ const { open: t, pageId: r, pageFocusRequest: o, setPageFocusRequest: a } = V();
1318
+ return me(() => {
1319
+ u(o) && (a(void 0), !(!t || o.pageId !== r || !u(e.current)) && Ke({
1320
+ content: e.current,
1321
+ target: o.target
1322
+ }).focus());
1323
+ }, [
1324
+ e,
1325
+ t,
1326
+ r,
1327
+ o,
1328
+ a
1329
+ ]), null;
1330
+ }, Dt = (e) => {
1331
+ if (e.dataset.type === "panel") return;
1332
+ const t = e.querySelector("[data-dropdown-search]:not(:disabled)");
1333
+ if (!(!u(t) || !z(t.value.trim())))
1334
+ return Le(e).find((r) => r.hasAttribute("data-dropdown-option-item"));
1335
+ }, $a = ({ content: e }) => {
1336
+ const { setSearchTargetId: t } = V();
1337
+ return me(() => {
1338
+ if (!u(e)) return;
1339
+ const r = () => t(Dt(e)?.id);
1340
+ r();
1341
+ const o = new MutationObserver(r);
1342
+ return o.observe(e, {
1343
+ childList: !0,
1344
+ subtree: !0,
1345
+ attributes: !0,
1346
+ attributeFilter: ["disabled", "aria-disabled"]
1347
+ }), e.addEventListener("input", r), () => {
1348
+ o.disconnect(), e.removeEventListener("input", r), t(void 0);
1349
+ };
1350
+ }, [e, t]), null;
1351
+ }, Wa = (e) => (e.ctrlKey || e.metaKey) && !e.defaultPrevented, ja = (e) => Array.from(e.ownerDocument.querySelectorAll("[data-dropdown-item][aria-controls]")).find((t) => t.getAttribute("aria-controls") === e.id), Ha = ({ key: e, items: t, currentIndex: r, search: o, isSearch: a }) => {
1352
+ const s = t.length - 1;
1353
+ if (e === "ArrowDown") return t[r === s ? 0 : r + 1];
1354
+ if (e === "ArrowUp" && r === 0 && u(o)) return o;
1355
+ if (e === "ArrowUp") return t[r <= 0 ? s : r - 1];
1356
+ if (!a && e === "Home") return t[0];
1357
+ if (!a && e === "End") return t[s];
1358
+ }, Va = 500, Ga = ({ type: e, isSubmenu: t, setOpen: r }) => {
1359
+ const o = yt(), [a, s] = M({
1360
+ text: "",
1361
+ timestamp: 0
1362
+ });
1363
+ return (i) => {
1364
+ if (i.defaultPrevented) return;
1365
+ const c = i.currentTarget, l = i.target;
1366
+ if (!(l instanceof HTMLElement) || l.closest("[data-dropdown-content]") !== c) return;
1367
+ const d = l.matches('input,textarea,select,[contenteditable="true"]'), m = o === "rtl" ? "ArrowRight" : "ArrowLeft";
1368
+ if (t && (i.key === "Escape" || !d && i.key === m)) {
1369
+ i.preventDefault(), i.stopPropagation(), ja(c)?.focus(), r(!1);
1370
+ return;
1371
+ }
1372
+ if (e === "panel") return;
1373
+ const v = c.querySelector("[data-dropdown-search]:not(:disabled)"), _ = l === v;
1374
+ if (d && !_) return;
1375
+ const f = Le(c).filter((y) => !u(v) || !y.hasAttribute("data-dropdown-back")), b = _ && i.key === "Enter" && !i.nativeEvent.isComposing ? Dt(c) : void 0;
1376
+ if (u(b)) {
1377
+ i.preventDefault(), b.click();
1378
+ return;
1379
+ }
1380
+ const p = f.indexOf(l), k = Ha({
1381
+ key: i.key,
1382
+ items: f,
1383
+ currentIndex: p,
1384
+ search: v,
1385
+ isSearch: _
1386
+ });
1387
+ if (u(k)) {
1388
+ i.preventDefault(), k.focus();
1389
+ return;
1390
+ }
1391
+ if (d || i.key.length !== 1 || i.key === " " || i.altKey || i.ctrlKey || i.metaKey) return;
1392
+ const C = Date.now(), I = C - a.timestamp > Va ? i.key : a.text + i.key;
1393
+ s({
1394
+ text: I,
1395
+ timestamp: C
1396
+ });
1397
+ const w = ([...I].every((y) => y === I[0]) ? i.key : I).toLocaleLowerCase(), T = [...f.slice(p + 1), ...f.slice(0, p + 1)].find((y) => Ge(y).trim().toLocaleLowerCase().startsWith(w));
1398
+ u(T) && (i.preventDefault(), T.focus());
1399
+ };
1400
+ }, Ja = ({ side: e, align: t = "start", sideOffset: r = 0, alignOffset: o, anchor: a, container: s, keepMounted: i, width: c = 200, className: l, style: d, children: m, initialFocus: v, onKeyDown: _, onClick: f, onMouseDown: b, onPointerDown: p, "aria-label": k, "aria-labelledby": C, ref: I, ...w }) => {
1401
+ const { type: T, isSubmenu: y, setOpen: L, initialFocusEdge: D, focusOnOpen: N, triggerId: S, titleId: R } = V(), A = X(null), [F, E] = M(null), P = ve(A, I, E), B = Ga({
1402
+ type: T,
1403
+ isSubmenu: y,
1404
+ setOpen: L
1405
+ }), $ = u(k) ? void 0 : R ?? S;
1406
+ return /* @__PURE__ */ h(J, { children: [
1407
+ /* @__PURE__ */ n(ie.Popup, {
1408
+ ...w,
1409
+ ref: P,
1410
+ side: e ?? (y ? "inline-end" : "bottom"),
1411
+ align: t,
1412
+ sideOffset: r,
1413
+ alignOffset: o,
1414
+ anchor: a,
1415
+ container: s,
1416
+ keepMounted: i,
1417
+ role: T === "menu" ? "menu" : "dialog",
1418
+ "aria-label": k,
1419
+ "aria-labelledby": C ?? $,
1420
+ "data-dropdown-content": "",
1421
+ "data-type": T,
1422
+ className: te(G.content, l),
1423
+ style: (x) => ({
1424
+ width: c,
1425
+ ...Ar(d) ? d(x) : d
1426
+ }),
1427
+ initialFocus: v ?? (() => N ? u(A.current) ? Ke({
1428
+ content: A.current,
1429
+ edge: D,
1430
+ type: T
1431
+ }) : !0 : !1),
1432
+ onKeyDown: (x) => {
1433
+ _?.(x), B(x), Wa(x) || x.stopPropagation();
1434
+ },
1435
+ onClick: (x) => {
1436
+ x.stopPropagation(), f?.(x);
1437
+ },
1438
+ onMouseDown: (x) => {
1439
+ x.stopPropagation(), b?.(x);
1440
+ },
1441
+ onPointerDown: (x) => {
1442
+ x.stopPropagation(), p?.(x);
1443
+ },
1444
+ children: m
1445
+ }),
1446
+ /* @__PURE__ */ n(qa, { contentRef: A }),
1447
+ /* @__PURE__ */ n($a, { content: F })
1448
+ ] });
1449
+ }, Ka = ({ className: e, ...t }) => /* @__PURE__ */ n(gt, {
1450
+ ...t,
1451
+ role: "status",
1452
+ "aria-live": "polite",
1453
+ className: g(G.status, e)
1454
+ }), Ua = ({ render: e, ref: t, className: r, ...o }) => de({
1455
+ render: e,
1456
+ ref: t,
1457
+ props: {
1458
+ ...o,
1459
+ className: g(G.header, r)
1460
+ }
1461
+ }), Ya = ({ className: e, ...t }) => /* @__PURE__ */ n(gt, {
1462
+ ...t,
1463
+ role: "status",
1464
+ "aria-live": "polite",
1465
+ "aria-busy": "true",
1466
+ className: g(G.status, e)
1467
+ }), Xa = ({ selected: e, indicator: t, onSelect: r, closeOnSelect: o, color: a, startIcon: s, endIcon: i, description: c, descriptionPlacement: l, shortcut: d, shortcutJoinLabel: m, hasSubmenu: v, children: _, render: f, disabled: b = !1, nativeButton: p = !u(f), onClick: k, onFocus: C, id: I, ...w }) => {
1468
+ const { type: T, multiple: y, closeTree: L, searchTargetId: D } = V(), N = T === "menu", S = u(e), R = S ? y ? "menuitemcheckbox" : "menuitemradio" : "menuitem", A = y ? "checkbox" : "check", F = re(), E = I ?? F, P = Je({ id: E });
1469
+ return /* @__PURE__ */ n(It, {
1470
+ ...w,
1471
+ id: E,
1472
+ disabled: b,
1473
+ nativeButton: p,
1474
+ role: N ? R : void 0,
1475
+ "aria-checked": N && S ? e : void 0,
1476
+ "aria-pressed": !N && S ? e : void 0,
1477
+ tabIndex: P.tabIndex,
1478
+ onFocus: (B) => {
1479
+ P.activate(), C?.(B);
1480
+ },
1481
+ "data-dropdown-item": "",
1482
+ "data-dropdown-option-item": "",
1483
+ onClick: (B) => {
1484
+ k?.(B), !B.defaultPrevented && (r?.(), (o ?? !y) && L());
1485
+ },
1486
+ render: (B) => /* @__PURE__ */ n(Ae, {
1487
+ ...B,
1488
+ render: f ?? /* @__PURE__ */ n("button", { type: "button" }),
1489
+ disabled: b,
1490
+ selected: e,
1491
+ focused: D === E,
1492
+ indicator: t ?? (S ? A : "none"),
1493
+ color: a,
1494
+ startIcon: s,
1495
+ endIcon: i,
1496
+ description: c,
1497
+ descriptionPlacement: l,
1498
+ shortcut: d,
1499
+ shortcutJoinLabel: m,
1500
+ hasSubmenu: v,
1501
+ children: _
1502
+ })
1503
+ });
1504
+ }, Qa = ({ id: e, type: t, children: r }) => {
1505
+ const o = V(), { registerPage: a } = o, s = le((i) => {
1506
+ u(i) && a({
1507
+ id: e,
1508
+ type: t
1509
+ });
1510
+ }, [
1511
+ e,
1512
+ t,
1513
+ a
1514
+ ]);
1515
+ return o.pageId !== e ? null : /* @__PURE__ */ n(ke.Provider, {
1516
+ value: {
1517
+ ...o,
1518
+ type: t ?? o.rootType
1519
+ },
1520
+ children: /* @__PURE__ */ n("div", {
1521
+ ref: s,
1522
+ className: G.page,
1523
+ "data-dropdown-page-type": t ?? o.rootType,
1524
+ children: r
1525
+ })
1526
+ });
1527
+ }, Za = ({ open: e, registerOpenNestedRoot: t }) => (Dr(() => {
1528
+ if (e)
1529
+ return t?.();
1530
+ }, [e, t]), null), es = (e) => e instanceof FocusEvent ? e.type === "focusout" && e.relatedTarget instanceof Element ? e.relatedTarget : null : e.target instanceof Element ? e.target : null, ct = ({ onDismiss: e, event: t }) => {
1531
+ if (!u(e)) return !1;
1532
+ let r = !1;
1533
+ return e({
1534
+ target: es(t),
1535
+ preventDefault: () => {
1536
+ r = !0;
1537
+ }
1538
+ }), r;
1539
+ }, ts = [
1540
+ "mousedown",
1541
+ "touchend",
1542
+ "focusout"
1543
+ ], Mt = ["pointerdown", "keydown"], rs = [
1544
+ ...Mt,
1545
+ "keyup",
1546
+ "mousedown"
1547
+ ], lt = (e) => {
1548
+ e.preventDefault(), e.stopPropagation();
1549
+ }, ns = (e) => {
1550
+ if (e.type === "click") {
1551
+ lt(e);
1552
+ return;
1553
+ }
1554
+ if (!ts.includes(e.type)) return;
1555
+ const t = e.target instanceof Node ? e.target.ownerDocument ?? document : document, r = t.defaultView ?? t, o = new AbortController(), a = () => o.abort(), s = {
1556
+ capture: !0,
1557
+ signal: o.signal
1558
+ }, i = e.type === "focusout" ? rs : Mt;
1559
+ r.addEventListener("click", (c) => {
1560
+ lt(c), a();
1561
+ }, s);
1562
+ for (const c of i) r.addEventListener(c, a, s);
1563
+ }, dt = () => {
1564
+ const [e, t] = M();
1565
+ return [e, le((r) => (t(r), () => t((o) => o === r ? void 0 : o)), [])];
1566
+ }, Pt = ({ children: e, type: t, open: r, defaultOpen: o = !1, onOpenChange: a, onEscapeKeyDown: s, onInteractOutside: i, multiple: c = !1, defaultPage: l = "root", isSubmenu: d = !1 }) => {
1567
+ const m = ye(ke), v = X(0), _ = le(() => (v.current += 1, () => {
1568
+ v.current -= 1;
1569
+ }), []), [f, b] = M(o), p = r ?? f, [k, C] = M(p), [I, w] = M([{ id: l }]), [T, y] = M(), [L, D] = M(), N = I[I.length - 1]?.id, [S, R] = M(), [A, F] = M("first"), [E, P] = M(!0), [B, $] = M(), [x, oe] = dt(), [Ot, Bt] = dt();
1570
+ k !== p && (C(p), p || (w([{ id: l }]), y(void 0), R(void 0), F("first"), P(!0), $(void 0)));
1571
+ const Ee = (W) => {
1572
+ u(r) || b(W), a?.(W);
1573
+ }, zt = () => {
1574
+ Ee(!1), d && m?.closeTree();
1575
+ }, Ft = ({ id: W, trigger: q }) => {
1576
+ R({ pageId: W }), w((K) => [...K, {
1577
+ id: W,
1578
+ trigger: q
1579
+ }]);
1580
+ }, qt = () => {
1581
+ const W = I[I.length - 2];
1582
+ if (!u(W)) return;
1583
+ const q = I[I.length - 1]?.trigger;
1584
+ R({
1585
+ pageId: W.id,
1586
+ target: q
1587
+ }), w((K) => K.slice(0, -1));
1588
+ }, $t = le(({ id: W, type: q }) => {
1589
+ if (!p) return;
1590
+ const K = q ?? t;
1591
+ y((pe) => pe?.id === W && pe.type === K ? pe : {
1592
+ id: W,
1593
+ type: K
1594
+ });
1595
+ }, [p, t]);
1596
+ return /* @__PURE__ */ n(ie.Root, {
1597
+ open: p,
1598
+ onOpenChange: (W, q) => {
1599
+ const K = q.reason === "outside-press" || q.reason === "focus-out";
1600
+ if (K && v.current > 0) {
1601
+ q.cancel();
1602
+ return;
1603
+ }
1604
+ const pe = q.reason === "escape-key" && ct({
1605
+ onDismiss: s,
1606
+ event: q.event
1607
+ }), Wt = K && ct({
1608
+ onDismiss: i,
1609
+ event: q.event
1610
+ });
1611
+ if (pe || Wt) {
1612
+ q.cancel();
1613
+ return;
1614
+ }
1615
+ K && ns(q.event), P(q.reason !== "trigger-hover"), Ee(W);
1616
+ },
1617
+ children: /* @__PURE__ */ h(ke.Provider, {
1618
+ value: {
1619
+ type: u(T) && T.id === N ? T.type : t,
1620
+ rootType: t,
1621
+ open: p,
1622
+ multiple: c,
1623
+ isSubmenu: d,
1624
+ parentType: m?.type,
1625
+ activeItemId: L,
1626
+ parentActiveItemId: m?.activeItemId,
1627
+ setActiveItemId: D,
1628
+ setParentActiveItemId: m?.setActiveItemId,
1629
+ pageId: N,
1630
+ pageFocusRequest: S,
1631
+ setPageFocusRequest: R,
1632
+ canGoBack: I.length > 1,
1633
+ initialFocusEdge: A,
1634
+ setInitialFocusEdge: F,
1635
+ focusOnOpen: E,
1636
+ setFocusOnOpen: P,
1637
+ setOpen: Ee,
1638
+ closeTree: zt,
1639
+ goToPage: Ft,
1640
+ goBack: qt,
1641
+ registerPage: $t,
1642
+ registerOpenNestedRoot: _,
1643
+ searchTargetId: B,
1644
+ setSearchTargetId: $,
1645
+ triggerId: x,
1646
+ registerTrigger: oe,
1647
+ titleId: Ot,
1648
+ registerTitle: Bt
1649
+ },
1650
+ children: [/* @__PURE__ */ n(Za, {
1651
+ open: p,
1652
+ registerOpenNestedRoot: d ? void 0 : m?.registerOpenNestedRoot
1653
+ }), e]
1654
+ })
1655
+ });
1656
+ }, os = ({ onValueChange: e, className: t, ...r }) => {
1657
+ const { searchTargetId: o } = V();
1658
+ return /* @__PURE__ */ n("div", {
1659
+ className: G.searchContainer,
1660
+ children: /* @__PURE__ */ n(ht, {
1661
+ type: "search",
1662
+ autoComplete: "off",
1663
+ "aria-activedescendant": o,
1664
+ ...r,
1665
+ "data-dropdown-search": "",
1666
+ className: te(G.search, t),
1667
+ onValueChange: (a) => e?.(a)
1668
+ })
1669
+ });
1670
+ }, as = ({ label: e, scrollable: t, className: r, children: o, ...a }) => /* @__PURE__ */ h(Ir, {
1671
+ ...a,
1672
+ "data-scrollable": t || void 0,
1673
+ className: g(G.section, r),
1674
+ children: [u(e) && /* @__PURE__ */ n(br, { children: e }), o]
1675
+ }), ss = ({ className: e, ...t }) => /* @__PURE__ */ n(Cr, {
1676
+ ...t,
1677
+ role: "separator",
1678
+ "data-dropdown-separator": "",
1679
+ className: g(G.separator, e)
1680
+ }), is = ({ type: e = "menu", ...t }) => /* @__PURE__ */ n(Pt, {
1681
+ ...t,
1682
+ type: e,
1683
+ isSubmenu: !0
1684
+ }), Ue = (e) => le((t) => {
1685
+ if (!(!u(t) || !z(t.id)))
1686
+ return e(t.id);
1687
+ }, [e]), cs = ({ color: e, startIcon: t, endIcon: r, description: o, descriptionPlacement: a, shortcut: s, shortcutJoinLabel: i, hasSubmenu: c = !0, children: l, render: d, disabled: m = !1, nativeButton: v = !u(d), openOnHover: _ = !0, onKeyDown: f, onFocus: b, id: p, ref: k, ...C }) => {
1688
+ const I = yt(), { type: w, parentType: T, open: y, setOpen: L, setFocusOnOpen: D, registerTrigger: N } = V(), S = re(), R = p ?? S, A = Je({
1689
+ id: R,
1690
+ isSubmenuTrigger: !0
1691
+ }), F = ve(k, Ue(N));
1692
+ return /* @__PURE__ */ n(ie.Trigger, {
1693
+ ...C,
1694
+ ref: F,
1695
+ id: R,
1696
+ disabled: m,
1697
+ nativeButton: v,
1698
+ openOnHover: _,
1699
+ role: T === "menu" ? "menuitem" : void 0,
1700
+ "aria-haspopup": w === "menu" ? "menu" : "dialog",
1701
+ tabIndex: A.tabIndex,
1702
+ onFocus: (E) => {
1703
+ A.activate(), b?.(E);
1704
+ },
1705
+ "data-dropdown-item": "",
1706
+ onKeyDown: (E) => {
1707
+ if (f?.(E), E.defaultPrevented || m) return;
1708
+ const P = I === "rtl" ? "ArrowLeft" : "ArrowRight";
1709
+ if (E.key === P) {
1710
+ E.preventDefault(), E.stopPropagation(), D(!0);
1711
+ const B = E.currentTarget.getAttribute("aria-controls"), $ = u(B) ? E.currentTarget.ownerDocument.getElementById(B) : null;
1712
+ if (y && u($)) {
1713
+ Ke({
1714
+ content: $,
1715
+ type: w
1716
+ }).focus();
1717
+ return;
1718
+ }
1719
+ L(!0);
1720
+ }
1721
+ },
1722
+ render: (E) => /* @__PURE__ */ n(Ae, {
1723
+ ...E,
1724
+ render: d ?? /* @__PURE__ */ n("button", { type: "button" }),
1725
+ disabled: m,
1726
+ color: e,
1727
+ startIcon: t,
1728
+ endIcon: r,
1729
+ description: o,
1730
+ descriptionPlacement: a,
1731
+ shortcut: s,
1732
+ shortcutJoinLabel: i,
1733
+ hasSubmenu: c,
1734
+ children: l
1735
+ })
1736
+ });
1737
+ }, ls = ({ className: e, render: t, ref: r, ...o }) => {
1738
+ const { registerTitle: a } = V(), s = ve(r, Ue(a));
1739
+ return /* @__PURE__ */ n(Ct.Title, {
1740
+ ...o,
1741
+ ref: s,
1742
+ render: t ?? /* @__PURE__ */ n("div", {}),
1743
+ className: te(G.title, e)
1744
+ });
1745
+ }, ds = ({ onKeyDown: e, onClick: t, ref: r, ...o }) => {
1746
+ const { type: a, setOpen: s, setInitialFocusEdge: i, setFocusOnOpen: c, registerTrigger: l } = V(), d = ve(r, Ue(l));
1747
+ return /* @__PURE__ */ n(ie.Trigger, {
1748
+ ...o,
1749
+ ref: d,
1750
+ "aria-haspopup": a === "menu" ? "menu" : "dialog",
1751
+ onClick: (m) => {
1752
+ m.stopPropagation(), m.preventDefault(), t?.(m);
1753
+ },
1754
+ onKeyDown: (m) => {
1755
+ e?.(m), !(m.defaultPrevented || o.disabled || a === "panel") && (m.key !== "ArrowDown" && m.key !== "ArrowUp" || (m.preventDefault(), c(!0), i(m.key === "ArrowUp" ? "last" : "first"), s(!0)));
1756
+ }
1757
+ });
1758
+ }, us = Pt, Fi = {
1759
+ Root: us,
1760
+ Trigger: ds,
1761
+ Content: Ja,
1762
+ ActionItem: Et,
1763
+ OptionItem: Xa,
1764
+ Search: os,
1765
+ Header: Ua,
1766
+ Title: ls,
1767
+ Close: Fa,
1768
+ Page: Qa,
1769
+ Back: za,
1770
+ Submenu: is,
1771
+ SubmenuTrigger: cs,
1772
+ Section: as,
1773
+ Separator: ss,
1774
+ Loading: Ya,
1775
+ Empty: Ka
1776
+ }, qi = () => {
1777
+ const { pageId: e, goToPage: t, goBack: r, canGoBack: o } = V();
1778
+ return {
1779
+ page: e,
1780
+ goToPage: (a) => t({ id: a }),
1781
+ goBack: r,
1782
+ canGoBack: o
1783
+ };
1784
+ }, $i = {
1785
+ gray: "Gray",
1786
+ tomato: "Tomato",
1787
+ red: "Red",
1788
+ ruby: "Ruby",
1789
+ crimson: "Crimson",
1790
+ pink: "Pink",
1791
+ plum: "Plum",
1792
+ purple: "Purple",
1793
+ violet: "Violet",
1794
+ iris: "Iris",
1795
+ cyan: "Cyan",
1796
+ turquoise: "Turquoise",
1797
+ sky: "Sky",
1798
+ blue: "Blue",
1799
+ jade: "Jade",
1800
+ green: "Green",
1801
+ grass: "Grass",
1802
+ mint: "Mint",
1803
+ lime: "Lime",
1804
+ bronze: "Bronze",
1805
+ gold: "Gold",
1806
+ brown: "Brown",
1807
+ orange: "Orange",
1808
+ amber: "Amber",
1809
+ yellow: "Yellow"
1810
+ }, ms = "_iconContainer_1ivx0_1", vs = "_withBackground_1ivx0_9", ut = {
1811
+ iconContainer: ms,
1812
+ withBackground: vs
1813
+ }, Ye = ({ children: e, className: t, hasBackground: r = !0 }) => /* @__PURE__ */ n("div", {
1814
+ className: g(ut.iconContainer, r && ut.withBackground, t),
1815
+ children: e
1816
+ }), _s = ({ Icon: e, iconThemeColor: t, withContainer: r = !1, withContainerBackground: o = !0 }) => {
1817
+ const a = H();
1818
+ if (!e) return null;
1819
+ if (u(t)) return /* @__PURE__ */ n(kt, {
1820
+ Icon: e,
1821
+ color: t,
1822
+ size: a.icon.size.md,
1823
+ stroke: a.icon.stroke.sm
1824
+ });
1825
+ const s = /* @__PURE__ */ n(e, {
1826
+ size: a.icon.size.md,
1827
+ stroke: a.icon.stroke.sm
1828
+ });
1829
+ return r ? /* @__PURE__ */ n(Ye, {
1830
+ hasBackground: o,
1831
+ children: s
1832
+ }) : s;
1833
+ }, ps = "_iconSwapContainer_g9ywp_1", fs = "_defaultIcon_g9ywp_8", hs = "_hoverIcon_g9ywp_13", ze = {
1834
+ iconSwapContainer: ps,
1835
+ defaultIcon: fs,
1836
+ hoverIcon: hs
1837
+ }, gs = ({ LeftIcon: e, iconThemeColor: t, withIconContainer: r = !1, gripIconColor: o }) => {
1838
+ const a = H();
1839
+ if (!e) return null;
1840
+ const s = /* @__PURE__ */ h("div", {
1841
+ className: ze.iconSwapContainer,
1842
+ children: [/* @__PURE__ */ n("div", {
1843
+ className: g(ze.defaultIcon, "grip-swap-default-icon"),
1844
+ children: u(t) ? /* @__PURE__ */ n(kt, {
1845
+ Icon: e,
1846
+ color: t,
1847
+ size: a.icon.size.md,
1848
+ stroke: a.icon.stroke.sm
1849
+ }) : /* @__PURE__ */ n(e, {
1850
+ size: a.icon.size.md,
1851
+ stroke: a.icon.stroke.sm
1852
+ })
1853
+ }), /* @__PURE__ */ n("div", {
1854
+ className: g(ze.hoverIcon, "grip-swap-hover-icon"),
1855
+ children: /* @__PURE__ */ n(qe, {
1856
+ size: a.icon.size.md,
1857
+ stroke: a.icon.stroke.sm,
1858
+ color: o
1859
+ })
1860
+ })]
1861
+ });
1862
+ return r && !u(t) ? /* @__PURE__ */ n(Ye, { children: s }) : s;
1863
+ }, bs = "_menuItemBase_1jkew_1", Is = "_hoverableMenuItemBase_1jkew_54", Cs = "_menuItemLabel_1jkew_136", ys = "_menuItemLabelLight_1jkew_145", ws = "_noIconFiller_1jkew_155", Ts = "_menuItemLeftContent_1jkew_159", Ns = "_menuItemRightContent_1jkew_172", ks = "_draggableItem_1jkew_183", Ss = "_menuItemIconCheckContainer_1jkew_189", As = "_menuItemContextualText_1jkew_196", xs = "_rightMenuItemContextualText_1jkew_206", Y = {
1864
+ menuItemBase: bs,
1865
+ hoverableMenuItemBase: Is,
1866
+ menuItemLabel: Cs,
1867
+ menuItemLabelLight: ys,
1868
+ noIconFiller: ws,
1869
+ menuItemLeftContent: Ts,
1870
+ menuItemRightContent: Ns,
1871
+ draggableItem: ks,
1872
+ menuItemIconCheckContainer: Ss,
1873
+ menuItemContextualText: As,
1874
+ rightMenuItemContextualText: xs
1875
+ }, Ls = He(({ accent: e, isKeySelected: t, isHoverBackgroundDisabled: r, hovered: o, disabled: a, focused: s, className: i, children: c, ...l }, d) => /* @__PURE__ */ n("div", {
1876
+ ref: d,
1877
+ className: g(Y.menuItemBase, i),
1878
+ "data-accent": e,
1879
+ "data-key-selected": t || void 0,
1880
+ "data-hover-background-disabled": r || void 0,
1881
+ "data-disabled": a || void 0,
1882
+ "data-focused": s || void 0,
1883
+ ...l,
1884
+ children: c
1885
+ }));
1886
+ Ls.displayName = "StyledMenuItemBase";
1887
+ var ne = (e, t) => {
1888
+ const r = He(({ className: o, children: a, ...s }, i) => /* @__PURE__ */ n("div", {
1889
+ ref: i,
1890
+ className: g(e, o),
1891
+ ...s,
1892
+ children: a
1893
+ }));
1894
+ return r.displayName = t, r;
1895
+ }, Es = ne(Y.menuItemLabel, "StyledMenuItemLabel"), Wi = ne(Y.menuItemLabelLight, "StyledMenuItemLabelLight"), ji = ne(Y.noIconFiller, "StyledNoIconFiller"), Rt = ne(Y.menuItemLeftContent, "StyledMenuItemLeftContent"), We = ne(Y.menuItemRightContent, "StyledMenuItemRightContent"), mt = ne(Y.draggableItem, "StyledDraggableItem"), Xe = He(({ accent: e, isKeySelected: t, isHoverBackgroundDisabled: r, hovered: o, disabled: a, focused: s, isIconDisplayedOnHoverOnly: i, cursor: c, className: l, children: d, ...m }, v) => /* @__PURE__ */ n("div", {
1896
+ ref: v,
1897
+ className: g(Y.hoverableMenuItemBase, l),
1898
+ "data-accent": e,
1899
+ "data-key-selected": t || void 0,
1900
+ "data-hover-background-disabled": r || void 0,
1901
+ "data-disabled": a || void 0,
1902
+ "data-focused": s || void 0,
1903
+ "data-icon-displayed-on-hover-only": i || void 0,
1904
+ "data-cursor": c,
1905
+ ...m,
1906
+ children: d
1907
+ }));
1908
+ Xe.displayName = "StyledHoverableMenuItemBase";
1909
+ var Ds = ne(Y.menuItemContextualText, "StyledMenuItemContextualText"), Ms = ne(Y.rightMenuItemContextualText, "StyledRightMenuItemContextualText"), Ps = "_mainText_d0zu3_1", Rs = "_menuItemLabelRight_d0zu3_9", vt = {
1910
+ mainText: Ps,
1911
+ menuItemLabelRight: Rs
1912
+ }, Qe = ({ className: e, LeftComponent: t, LeftIcon: r, iconThemeColor: o, withIconContainer: a = !1, withIconContainerBackground: s = !0, text: i, contextualText: c, contextualTextPosition: l = "left", gripMode: d = "never", disabled: m = !1 }) => {
1913
+ const v = H(), _ = a ? ee.font.color.tertiary : m ? ee.font.color.extraLight : ee.font.color.light;
1914
+ return /* @__PURE__ */ h(Rt, {
1915
+ className: e,
1916
+ children: [
1917
+ d === "always" && (a ? /* @__PURE__ */ n(Ye, {
1918
+ hasBackground: s,
1919
+ children: /* @__PURE__ */ n(mt, { children: /* @__PURE__ */ n(qe, {
1920
+ size: v.icon.size.md,
1921
+ stroke: v.icon.stroke.sm,
1922
+ color: _
1923
+ }) })
1924
+ }) : /* @__PURE__ */ n(mt, { children: /* @__PURE__ */ n(qe, {
1925
+ size: v.icon.size.md,
1926
+ stroke: v.icon.stroke.sm,
1927
+ color: _
1928
+ }) })),
1929
+ d === "onHover" ? /* @__PURE__ */ n(gs, {
1930
+ LeftIcon: r,
1931
+ iconThemeColor: o,
1932
+ withIconContainer: a,
1933
+ gripIconColor: _
1934
+ }) : /* @__PURE__ */ n(_s, {
1935
+ Icon: r,
1936
+ iconThemeColor: o,
1937
+ withContainer: a,
1938
+ withContainerBackground: s
1939
+ }),
1940
+ t,
1941
+ /* @__PURE__ */ h(Es, { children: [ce(i) ? /* @__PURE__ */ n("div", {
1942
+ className: vt.mainText,
1943
+ children: /* @__PURE__ */ n(Ce, { text: i })
1944
+ }) : i, l === "left" && /* @__PURE__ */ n(J, { children: ce(c) ? z(c) && /* @__PURE__ */ n(Ds, { children: /* @__PURE__ */ n(Ce, {
1945
+ text: `· ${c}`,
1946
+ tooltipContent: c
1947
+ }) }) : c })] }),
1948
+ l === "right" && /* @__PURE__ */ n("div", {
1949
+ className: vt.menuItemLabelRight,
1950
+ children: /* @__PURE__ */ n(Ms, { children: ce(c) ? /* @__PURE__ */ n(Ce, { text: c }) : c })
1951
+ })
1952
+ ]
1953
+ });
1954
+ }, Os = "_subMenuIcon_j232v_1", Bs = "_subMenuIconOpened_j232v_9", _t = {
1955
+ subMenuIcon: Os,
1956
+ subMenuIconOpened: Bs
1957
+ }, zs = ({ accent: e = "default", className: t, withIconContainer: r = !1, withIconContainerBackground: o = !0, iconButtons: a, isIconDisplayedOnHoverOnly: s = !0, LeftIcon: i, iconThemeColor: c, LeftComponent: l, RightIcon: d, RightComponent: m, onClick: v, onMouseEnter: _, onMouseLeave: f, testId: b, text: p, contextualTextPosition: k = "left", contextualText: C, hasSubMenu: I = !1, disabled: w = !1, focused: T = !1, selected: y = !1, shortcut: L, shortcutJoinLabel: D, isSubMenuOpened: N = !1 }) => {
1958
+ const S = H();
1959
+ return /* @__PURE__ */ h(Xe, {
1960
+ "data-testid": b ?? void 0,
1961
+ onClick: w ? void 0 : (A) => {
1962
+ v && (A.preventDefault(), A.stopPropagation(), v?.(A));
1963
+ },
1964
+ disabled: w,
1965
+ className: t,
1966
+ accent: e,
1967
+ isIconDisplayedOnHoverOnly: s,
1968
+ onMouseEnter: _,
1969
+ onMouseLeave: f,
1970
+ focused: T || y,
1971
+ children: [/* @__PURE__ */ n(Qe, {
1972
+ LeftIcon: i ?? void 0,
1973
+ iconThemeColor: c,
1974
+ LeftComponent: l,
1975
+ withIconContainer: r,
1976
+ withIconContainerBackground: o,
1977
+ text: p,
1978
+ contextualText: C,
1979
+ contextualTextPosition: k,
1980
+ disabled: w
1981
+ }), /* @__PURE__ */ h(We, { children: [
1982
+ a && /* @__PURE__ */ n(We, {
1983
+ className: "hoverable-buttons",
1984
+ children: a
1985
+ }),
1986
+ u(L) && /* @__PURE__ */ n(vr, {
1987
+ shortcut: L,
1988
+ sequenceJoinLabel: D
1989
+ }),
1990
+ d && /* @__PURE__ */ n(d, {
1991
+ size: S.icon.size.md,
1992
+ stroke: S.icon.stroke.sm
1993
+ }),
1994
+ m,
1995
+ I && /* @__PURE__ */ n("div", {
1996
+ className: g(_t.subMenuIcon, N && _t.subMenuIconOpened),
1997
+ style: { visibility: w ? "hidden" : "visible" },
1998
+ children: /* @__PURE__ */ n(Gt, {
1999
+ size: S.icon.size.sm,
2000
+ color: S.font.color.light
2001
+ })
2002
+ })
2003
+ ] })]
2004
+ });
2005
+ }, Hi = ({ accent: e = "default", className: t, iconButtons: r, isIconDisplayedOnHoverOnly: o = !0, isTooltipOpen: a, onClick: s, onMouseEnter: i, onMouseLeave: c, testId: l, avatar: d, hasSubMenu: m = !1, text: v, contextualText: _ }) => /* @__PURE__ */ n(zs, {
2006
+ accent: e,
2007
+ className: t,
2008
+ iconButtons: r,
2009
+ isIconDisplayedOnHoverOnly: o,
2010
+ isTooltipOpen: a,
2011
+ LeftComponent: u(d) ? /* @__PURE__ */ n(wr, {
2012
+ name: d.name,
2013
+ src: d.src,
2014
+ colorSeed: d.colorSeed,
2015
+ size: d.size,
2016
+ shape: d.shape
2017
+ }) : void 0,
2018
+ onClick: s,
2019
+ onMouseEnter: i,
2020
+ onMouseLeave: c,
2021
+ testId: l,
2022
+ text: v,
2023
+ contextualText: _,
2024
+ hasSubMenu: m
2025
+ }), Vi = ({ LeftIcon: e, withIconContainer: t = !1, accent: r = "default", iconButtons: o, onClick: a, text: s, contextualText: i, isDragDisabled: c = !1, className: l, isIconDisplayedOnHoverOnly: d = !0, gripMode: m = "never" }) => /* @__PURE__ */ h(Xe, {
2026
+ onClick: a,
2027
+ accent: r,
2028
+ className: l,
2029
+ isIconDisplayedOnHoverOnly: d,
2030
+ cursor: m !== "never" ? c ? "default" : "drag" : "default",
2031
+ children: [/* @__PURE__ */ n(Qe, {
2032
+ LeftIcon: e,
2033
+ text: s,
2034
+ contextualText: i,
2035
+ withIconContainer: t,
2036
+ disabled: c,
2037
+ gripMode: m
2038
+ }), o && /* @__PURE__ */ n(We, {
2039
+ className: "hoverable-buttons",
2040
+ children: o
2041
+ })]
2042
+ }), Fs = "_suggestionMenuItem_1qyjt_1", qs = { suggestionMenuItem: Fs }, Gi = ({ LeftIcon: e, withIconContainer: t = !1, text: r, contextualText: o = void 0, contextualTextPosition: a = "left", className: s, selected: i, onClick: c }) => {
2043
+ const l = (d) => {
2044
+ c && (d.preventDefault(), d.stopPropagation(), c?.(d));
2045
+ };
2046
+ return /* @__PURE__ */ n("li", {
2047
+ className: g(qs.suggestionMenuItem, s),
2048
+ "data-selected": i || void 0,
2049
+ role: u(c) ? "button" : void 0,
2050
+ tabIndex: u(c) ? 0 : void 0,
2051
+ onClick: l,
2052
+ onKeyDown: ir,
2053
+ children: /* @__PURE__ */ n(Rt, { children: /* @__PURE__ */ n(Qe, {
2054
+ LeftIcon: e ?? void 0,
2055
+ text: r,
2056
+ contextualText: o,
2057
+ contextualTextPosition: a,
2058
+ withIconContainer: t
2059
+ }) })
2060
+ });
2061
+ }, $s = "_menuPicker_o8ra4_1", Ws = "_iconContainer_o8ra4_41", js = "_label_o8ra4_50", Fe = {
2062
+ menuPicker: $s,
2063
+ iconContainer: Ws,
2064
+ label: js
2065
+ }, Ji = ({ id: e, icon: t, label: r, selected: o = !1, disabled: a = !1, showLabel: s = !0, onClick: i, className: c, testId: l, tooltipContent: d, tooltipDelay: m = 0, tooltipOffset: v = 5 }) => {
2066
+ const _ = H();
2067
+ return /* @__PURE__ */ n(bt, {
2068
+ content: d,
2069
+ disabled: !z(d),
2070
+ sideOffset: v,
2071
+ side: "bottom",
2072
+ positionMethod: "fixed",
2073
+ delay: m,
2074
+ children: /* @__PURE__ */ h("button", {
2075
+ id: e,
2076
+ disabled: a,
2077
+ onClick: i,
2078
+ className: g(Fe.menuPicker, c),
2079
+ "data-testid": l,
2080
+ "data-selected": o ? "" : void 0,
2081
+ "aria-pressed": o,
2082
+ "aria-disabled": a,
2083
+ "aria-label": r,
2084
+ children: [/* @__PURE__ */ n("div", {
2085
+ className: Fe.iconContainer,
2086
+ children: /* @__PURE__ */ n(t, {
2087
+ size: _.icon.size.md,
2088
+ stroke: _.icon.stroke.sm
2089
+ })
2090
+ }), u(r) && s && /* @__PURE__ */ n("div", {
2091
+ className: Fe.label,
2092
+ "data-selected": o ? "" : void 0,
2093
+ "data-disabled": a ? "" : void 0,
2094
+ children: r
2095
+ })]
2096
+ })
2097
+ });
2098
+ }, Hs = "_button_quwcq_1", Vs = { button: Hs }, Ki = ({ active: e = !1, className: t, children: r, startIcon: o, endIcon: a, badge: s, size: i = "sm", ...c }) => /* @__PURE__ */ n(j, {
2099
+ ...c,
2100
+ variant: "ghost",
2101
+ size: i,
2102
+ "data-active": e || void 0,
2103
+ className: te(g(Tr.tab, Vs.button), t),
2104
+ children: /* @__PURE__ */ n(Nr, {
2105
+ startIcon: o,
2106
+ endIcon: a,
2107
+ badge: s,
2108
+ children: r
2109
+ })
2110
+ });
2111
+ export {
2112
+ wi as A,
2113
+ Ai as C,
2114
+ En as D,
2115
+ kt as E,
2116
+ Ci as M,
2117
+ Ni as O,
2118
+ No as S,
2119
+ ki as T,
2120
+ Di as _,
2121
+ Hi as a,
2122
+ Li as b,
2123
+ qi as c,
2124
+ Bi as d,
2125
+ Oi as f,
2126
+ Qo as g,
2127
+ Mi as h,
2128
+ Vi as i,
2129
+ yi as j,
2130
+ Ti as k,
2131
+ Fi as l,
2132
+ Pi as m,
2133
+ Ji as n,
2134
+ zs as o,
2135
+ Ri as p,
2136
+ Gi as r,
2137
+ $i as s,
2138
+ Ki as t,
2139
+ zi as u,
2140
+ Ei as v,
2141
+ Si as w,
2142
+ xi as x,
2143
+ zo as y
2144
+ };