@dxos/react-ui 0.9.1-main.c7dcc2e112 → 0.9.1-staging.ee54ba693a

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 (239) hide show
  1. package/dist/lib/browser/{chunk-HFJYTGHU.mjs → chunk-CMHHVHX3.mjs} +4 -1
  2. package/dist/lib/browser/chunk-CMHHVHX3.mjs.map +7 -0
  3. package/dist/lib/browser/{chunk-F3PLXTDA.mjs → chunk-GTHV4WYK.mjs} +123 -232
  4. package/dist/lib/browser/chunk-GTHV4WYK.mjs.map +7 -0
  5. package/dist/lib/browser/index.mjs +1069 -976
  6. package/dist/lib/browser/index.mjs.map +4 -4
  7. package/dist/lib/browser/meta.json +1 -1
  8. package/dist/lib/browser/testing/index.mjs +5 -5
  9. package/dist/lib/browser/testing/index.mjs.map +2 -2
  10. package/dist/lib/browser/translations.mjs +1 -1
  11. package/dist/lib/node-esm/{chunk-LLVUYLAM.mjs → chunk-3VSKWNCQ.mjs} +123 -232
  12. package/dist/lib/node-esm/chunk-3VSKWNCQ.mjs.map +7 -0
  13. package/dist/lib/node-esm/{chunk-OJYUPUCY.mjs → chunk-P4KFQGJI.mjs} +4 -1
  14. package/dist/lib/node-esm/chunk-P4KFQGJI.mjs.map +7 -0
  15. package/dist/lib/node-esm/index.mjs +1069 -976
  16. package/dist/lib/node-esm/index.mjs.map +4 -4
  17. package/dist/lib/node-esm/meta.json +1 -1
  18. package/dist/lib/node-esm/testing/index.mjs +5 -5
  19. package/dist/lib/node-esm/testing/index.mjs.map +2 -2
  20. package/dist/lib/node-esm/translations.mjs +1 -1
  21. package/dist/types/src/components/Avatars/Avatar.d.ts +1 -1
  22. package/dist/types/src/components/Avatars/Avatar.d.ts.map +1 -1
  23. package/dist/types/src/components/Breadcrumb/Breadcrumb.d.ts +3 -3
  24. package/dist/types/src/components/Breadcrumb/Breadcrumb.d.ts.map +1 -1
  25. package/dist/types/src/components/Button/Button.d.ts +2 -2
  26. package/dist/types/src/components/Button/Button.d.ts.map +1 -1
  27. package/dist/types/src/components/Button/IconButton.stories.d.ts +3 -0
  28. package/dist/types/src/components/Button/IconButton.stories.d.ts.map +1 -1
  29. package/dist/types/src/components/Button/MicButton.d.ts +24 -0
  30. package/dist/types/src/components/Button/MicButton.d.ts.map +1 -0
  31. package/dist/types/src/components/Button/MicButton.stories.d.ts +57 -0
  32. package/dist/types/src/components/Button/MicButton.stories.d.ts.map +1 -0
  33. package/dist/types/src/components/Button/SystemIconButton.d.ts +15 -2
  34. package/dist/types/src/components/Button/SystemIconButton.d.ts.map +1 -1
  35. package/dist/types/src/components/Button/SystemIconButton.stories.d.ts +51 -0
  36. package/dist/types/src/components/Button/SystemIconButton.stories.d.ts.map +1 -0
  37. package/dist/types/src/components/Button/ToggleGroup.d.ts +2 -2
  38. package/dist/types/src/components/Button/ToggleGroup.d.ts.map +1 -1
  39. package/dist/types/src/components/Button/index.d.ts +1 -0
  40. package/dist/types/src/components/Button/index.d.ts.map +1 -1
  41. package/dist/types/src/components/Calendar/Calendar.d.ts.map +1 -1
  42. package/dist/types/src/components/Calendar/Calendar.theme.d.ts.map +1 -1
  43. package/dist/types/src/components/Card/Card.d.ts +8 -8
  44. package/dist/types/src/components/Card/Card.d.ts.map +1 -1
  45. package/dist/types/src/components/Card/Card.stories.d.ts +2 -2
  46. package/dist/types/src/components/Card/Card.stories.d.ts.map +1 -1
  47. package/dist/types/src/components/Carousel/Carousel.d.ts +29 -6
  48. package/dist/types/src/components/Carousel/Carousel.d.ts.map +1 -1
  49. package/dist/types/src/components/Carousel/Carousel.stories.d.ts +48 -2
  50. package/dist/types/src/components/Carousel/Carousel.stories.d.ts.map +1 -1
  51. package/dist/types/src/components/Column/Column.d.ts +2 -2
  52. package/dist/types/src/components/Column/Column.d.ts.map +1 -1
  53. package/dist/types/src/components/Dialog/AlertDialog.d.ts +2 -2
  54. package/dist/types/src/components/Dialog/AlertDialog.d.ts.map +1 -1
  55. package/dist/types/src/components/Dialog/Dialog.d.ts +1 -1
  56. package/dist/types/src/components/Dialog/Dialog.d.ts.map +1 -1
  57. package/dist/types/src/components/Dialog/Dialog.stories.d.ts +2 -2
  58. package/dist/types/src/components/Dialog/Dialog.stories.d.ts.map +1 -1
  59. package/dist/types/src/components/Icon/Icon.stories.d.ts +5 -0
  60. package/dist/types/src/components/Icon/Icon.stories.d.ts.map +1 -1
  61. package/dist/types/src/components/Input/Input.d.ts +4 -1
  62. package/dist/types/src/components/Input/Input.d.ts.map +1 -1
  63. package/dist/types/src/components/Input/Input.stories.d.ts +3 -3
  64. package/dist/types/src/components/Input/Input.stories.d.ts.map +1 -1
  65. package/dist/types/src/components/Input/Input.theme.d.ts +10 -10
  66. package/dist/types/src/components/Input/Input.theme.d.ts.map +1 -1
  67. package/dist/types/src/components/Input/SegmentedInput.d.ts +8 -8
  68. package/dist/types/src/components/Input/SegmentedInput.d.ts.map +1 -1
  69. package/dist/types/src/components/Input/index.d.ts +0 -1
  70. package/dist/types/src/components/Input/index.d.ts.map +1 -1
  71. package/dist/types/src/components/Main/Main.d.ts +3 -3
  72. package/dist/types/src/components/Main/Main.d.ts.map +1 -1
  73. package/dist/types/src/components/Menu/ContextMenu.d.ts +1 -1
  74. package/dist/types/src/components/Menu/ContextMenu.d.ts.map +1 -1
  75. package/dist/types/src/components/Menu/DropdownMenu.d.ts +2 -2
  76. package/dist/types/src/components/Menu/DropdownMenu.d.ts.map +1 -1
  77. package/dist/types/src/components/Message/Message.d.ts +1 -1
  78. package/dist/types/src/components/Message/Message.d.ts.map +1 -1
  79. package/dist/types/src/components/Message/Message.stories.d.ts +2 -2
  80. package/dist/types/src/components/Message/Message.stories.d.ts.map +1 -1
  81. package/dist/types/src/components/Panel/Panel.d.ts +1 -1
  82. package/dist/types/src/components/Panel/Panel.d.ts.map +1 -1
  83. package/dist/types/src/components/Panel/Panel.theme.d.ts.map +1 -1
  84. package/dist/types/src/components/Popover/Popover.d.ts +2 -2
  85. package/dist/types/src/components/Popover/Popover.d.ts.map +1 -1
  86. package/dist/types/src/components/ScrollArea/ScrollArea.d.ts +2 -0
  87. package/dist/types/src/components/ScrollArea/ScrollArea.d.ts.map +1 -1
  88. package/dist/types/src/components/ScrollArea/ScrollArea.stories.d.ts +1 -0
  89. package/dist/types/src/components/ScrollArea/ScrollArea.stories.d.ts.map +1 -1
  90. package/dist/types/src/components/ScrollContainer/ScrollContainer.d.ts +1 -1
  91. package/dist/types/src/components/ScrollContainer/ScrollContainer.d.ts.map +1 -1
  92. package/dist/types/src/components/ScrollContainer/ScrollContainer.stories.d.ts +2 -2
  93. package/dist/types/src/components/ScrollContainer/ScrollContainer.stories.d.ts.map +1 -1
  94. package/dist/types/src/components/Select/Select.d.ts +1 -1
  95. package/dist/types/src/components/Select/Select.d.ts.map +1 -1
  96. package/dist/types/src/components/Select/Select.stories.d.ts +2 -2
  97. package/dist/types/src/components/Select/Select.stories.d.ts.map +1 -1
  98. package/dist/types/src/components/Separator/Separator.d.ts.map +1 -1
  99. package/dist/types/src/components/Splitter/Splitter.d.ts +30 -16
  100. package/dist/types/src/components/Splitter/Splitter.d.ts.map +1 -1
  101. package/dist/types/src/components/Splitter/Splitter.stories.d.ts +6 -1
  102. package/dist/types/src/components/Splitter/Splitter.stories.d.ts.map +1 -1
  103. package/dist/types/src/components/Splitter/Splitter.theme.d.ts +3 -1
  104. package/dist/types/src/components/Splitter/Splitter.theme.d.ts.map +1 -1
  105. package/dist/types/src/components/Tag/Tag.d.ts +1 -1
  106. package/dist/types/src/components/Tag/Tag.d.ts.map +1 -1
  107. package/dist/types/src/components/Tag/Tag.theme.d.ts +1 -1
  108. package/dist/types/src/components/Tag/Tag.theme.d.ts.map +1 -1
  109. package/dist/types/src/components/Toast/Toast.d.ts +1 -1
  110. package/dist/types/src/components/Toast/Toast.d.ts.map +1 -1
  111. package/dist/types/src/components/Toast/Toast.theme.d.ts.map +1 -1
  112. package/dist/types/src/components/Toolbar/Toolbar.d.ts +1 -1
  113. package/dist/types/src/components/Toolbar/Toolbar.d.ts.map +1 -1
  114. package/dist/types/src/components/Tooltip/Tooltip.d.ts +3 -3
  115. package/dist/types/src/components/Tooltip/Tooltip.d.ts.map +1 -1
  116. package/dist/types/src/components/Tooltip/Tooltip.stories.d.ts +2 -2
  117. package/dist/types/src/components/Tooltip/Tooltip.stories.d.ts.map +1 -1
  118. package/dist/types/src/components/index.d.ts +0 -1
  119. package/dist/types/src/components/index.d.ts.map +1 -1
  120. package/dist/types/src/index.d.ts +1 -1
  121. package/dist/types/src/index.d.ts.map +1 -1
  122. package/dist/types/src/primitives/ThemeProvider/TranslationsProvider.d.ts +1 -8
  123. package/dist/types/src/primitives/ThemeProvider/TranslationsProvider.d.ts.map +1 -1
  124. package/dist/types/src/theme/defaultTheme.d.ts.map +1 -1
  125. package/dist/types/src/theme/index.d.ts +0 -2
  126. package/dist/types/src/theme/index.d.ts.map +1 -1
  127. package/dist/types/src/translations.d.ts +3 -0
  128. package/dist/types/src/translations.d.ts.map +1 -1
  129. package/dist/types/src/util/slots.d.ts +1 -1
  130. package/dist/types/src/util/slots.d.ts.map +1 -1
  131. package/dist/types/tsconfig.tsbuildinfo +1 -1
  132. package/package.json +22 -21
  133. package/src/components/Avatars/Avatar.stories.tsx +2 -2
  134. package/src/components/Avatars/Avatar.theme.ts +1 -1
  135. package/src/components/Avatars/Avatar.tsx +3 -3
  136. package/src/components/Breadcrumb/Breadcrumb.tsx +6 -6
  137. package/src/components/Button/Button.tsx +2 -2
  138. package/src/components/Button/MicButton.stories.tsx +60 -0
  139. package/src/components/Button/MicButton.tsx +117 -0
  140. package/src/components/Button/SystemIconButton.stories.tsx +91 -0
  141. package/src/components/Button/SystemIconButton.tsx +113 -2
  142. package/src/components/Button/ToggleGroup.tsx +2 -2
  143. package/src/components/Button/index.ts +1 -0
  144. package/src/components/Calendar/Calendar.theme.ts +2 -0
  145. package/src/components/Calendar/Calendar.tsx +3 -3
  146. package/src/components/Card/Card.stories.tsx +2 -2
  147. package/src/components/Card/Card.tsx +11 -11
  148. package/src/components/Carousel/Carousel.stories.tsx +42 -18
  149. package/src/components/Carousel/Carousel.tsx +169 -33
  150. package/src/components/Column/Column.tsx +4 -7
  151. package/src/components/Dialog/AlertDialog.stories.tsx +2 -2
  152. package/src/components/Dialog/AlertDialog.tsx +13 -13
  153. package/src/components/Dialog/Dialog.stories.tsx +3 -4
  154. package/src/components/Dialog/Dialog.theme.ts +1 -1
  155. package/src/components/Dialog/Dialog.tsx +12 -12
  156. package/src/components/Icon/Icon.stories.tsx +23 -0
  157. package/src/components/Icon/Icon.theme.ts +1 -1
  158. package/src/components/Input/Input.stories.tsx +13 -5
  159. package/src/components/Input/Input.theme.ts +17 -39
  160. package/src/components/Input/Input.tsx +30 -13
  161. package/src/components/Input/SegmentedInput.tsx +50 -41
  162. package/src/components/Input/index.ts +0 -1
  163. package/src/components/Main/Main.tsx +3 -3
  164. package/src/components/MediaPlayer/MediaPlayer.tsx +4 -4
  165. package/src/components/Menu/ContextMenu.tsx +8 -8
  166. package/src/components/Menu/DropdownMenu.tsx +12 -13
  167. package/src/components/Message/Message.stories.tsx +2 -2
  168. package/src/components/Message/Message.theme.ts +1 -1
  169. package/src/components/Message/Message.tsx +2 -2
  170. package/src/components/Panel/Panel.theme.ts +2 -1
  171. package/src/components/Panel/Panel.tsx +1 -1
  172. package/src/components/Popover/Popover.tsx +9 -9
  173. package/src/components/ScrollArea/ScrollArea.tsx +7 -4
  174. package/src/components/ScrollContainer/ScrollContainer.stories.tsx +2 -2
  175. package/src/components/ScrollContainer/ScrollContainer.tsx +2 -2
  176. package/src/components/Select/Select.stories.tsx +2 -2
  177. package/src/components/Select/Select.theme.ts +1 -1
  178. package/src/components/Select/Select.tsx +14 -14
  179. package/src/components/Separator/Separator.tsx +1 -0
  180. package/src/components/Splitter/Splitter.stories.tsx +84 -20
  181. package/src/components/Splitter/Splitter.theme.ts +20 -3
  182. package/src/components/Splitter/Splitter.tsx +320 -47
  183. package/src/components/Tag/Tag.stories.tsx +1 -1
  184. package/src/components/Tag/Tag.theme.ts +1 -1
  185. package/src/components/Tag/Tag.tsx +3 -5
  186. package/src/components/Toast/Toast.theme.ts +3 -2
  187. package/src/components/Toast/Toast.tsx +5 -5
  188. package/src/components/Toolbar/Toolbar.tsx +10 -10
  189. package/src/components/Tooltip/Tooltip.stories.tsx +2 -2
  190. package/src/components/Tooltip/Tooltip.tsx +3 -3
  191. package/src/components/index.ts +0 -1
  192. package/src/exemplars/tabster.stories.tsx +1 -1
  193. package/src/index.ts +1 -1
  194. package/src/primitives/ThemeProvider/TranslationsProvider.tsx +10 -30
  195. package/src/testing/decorators/withLayout.tsx +4 -4
  196. package/src/theme/defaultTheme.ts +0 -4
  197. package/src/theme/index.ts +0 -2
  198. package/src/translations.ts +8 -0
  199. package/src/util/slots.ts +5 -5
  200. package/dist/lib/browser/chunk-F3PLXTDA.mjs.map +0 -7
  201. package/dist/lib/browser/chunk-HFJYTGHU.mjs.map +0 -7
  202. package/dist/lib/node-esm/chunk-LLVUYLAM.mjs.map +0 -7
  203. package/dist/lib/node-esm/chunk-OJYUPUCY.mjs.map +0 -7
  204. package/dist/types/src/components/Input/constants.d.ts +0 -5
  205. package/dist/types/src/components/Input/constants.d.ts.map +0 -1
  206. package/dist/types/src/components/List/List.d.ts +0 -29
  207. package/dist/types/src/components/List/List.d.ts.map +0 -1
  208. package/dist/types/src/components/List/List.stories.d.ts +0 -16
  209. package/dist/types/src/components/List/List.stories.d.ts.map +0 -1
  210. package/dist/types/src/components/List/List.theme.d.ts +0 -7
  211. package/dist/types/src/components/List/List.theme.d.ts.map +0 -1
  212. package/dist/types/src/components/List/ListDropIndicator.d.ts +0 -13
  213. package/dist/types/src/components/List/ListDropIndicator.d.ts.map +0 -1
  214. package/dist/types/src/components/List/Tree.d.ts +0 -23
  215. package/dist/types/src/components/List/Tree.d.ts.map +0 -1
  216. package/dist/types/src/components/List/Tree.stories.d.ts +0 -15
  217. package/dist/types/src/components/List/Tree.stories.d.ts.map +0 -1
  218. package/dist/types/src/components/List/TreeDropIndicator.d.ts +0 -8
  219. package/dist/types/src/components/List/TreeDropIndicator.d.ts.map +0 -1
  220. package/dist/types/src/components/List/Treegrid.d.ts +0 -33
  221. package/dist/types/src/components/List/Treegrid.d.ts.map +0 -1
  222. package/dist/types/src/components/List/Treegrid.stories.d.ts +0 -12
  223. package/dist/types/src/components/List/Treegrid.stories.d.ts.map +0 -1
  224. package/dist/types/src/components/List/Treegrid.theme.d.ts +0 -7
  225. package/dist/types/src/components/List/Treegrid.theme.d.ts.map +0 -1
  226. package/dist/types/src/components/List/index.d.ts +0 -4
  227. package/dist/types/src/components/List/index.d.ts.map +0 -1
  228. package/src/components/Input/constants.ts +0 -8
  229. package/src/components/List/List.stories.tsx +0 -234
  230. package/src/components/List/List.theme.ts +0 -47
  231. package/src/components/List/List.tsx +0 -171
  232. package/src/components/List/ListDropIndicator.tsx +0 -69
  233. package/src/components/List/Tree.stories.tsx +0 -87
  234. package/src/components/List/Tree.tsx +0 -74
  235. package/src/components/List/TreeDropIndicator.tsx +0 -70
  236. package/src/components/List/Treegrid.stories.tsx +0 -156
  237. package/src/components/List/Treegrid.theme.ts +0 -35
  238. package/src/components/List/Treegrid.tsx +0 -187
  239. package/src/components/List/index.ts +0 -7
@@ -23,10 +23,8 @@ import {
23
23
  iconButtonTheme,
24
24
  iconTheme,
25
25
  initialSafeArea,
26
- inputTextLabel,
27
26
  inputTheme,
28
27
  linkTheme,
29
- listTheme,
30
28
  mainIntrinsicSize,
31
29
  mainPaddingTransitions,
32
30
  mainTheme,
@@ -46,17 +44,16 @@ import {
46
44
  toolbarTheme,
47
45
  tooltipContent,
48
46
  tooltipTheme,
49
- treegridTheme,
50
47
  useElevationContext,
51
48
  useSafeArea,
52
49
  useThemeContext,
53
50
  useTooltipContext,
54
51
  useTranslation,
55
52
  withColumn
56
- } from "./chunk-F3PLXTDA.mjs";
53
+ } from "./chunk-GTHV4WYK.mjs";
57
54
  import {
58
55
  translationKey
59
- } from "./chunk-HFJYTGHU.mjs";
56
+ } from "./chunk-CMHHVHX3.mjs";
60
57
 
61
58
  // src/index.ts
62
59
  import { Trans } from "react-i18next";
@@ -603,15 +600,82 @@ var LabelledIconButton = /* @__PURE__ */ forwardRef9(({ size, icon, iconOnly, sq
603
600
  }));
604
601
  });
605
602
 
603
+ // src/components/Button/MicButton.tsx
604
+ import React12, { forwardRef as forwardRef10, useCallback as useCallback4, useRef as useRef2 } from "react";
605
+ var MicButton = /* @__PURE__ */ forwardRef10(({ classNames, icon = "ph--microphone--regular", mode = "toggle", recording, onToggle, onPressStart, onPressEnd, ...props }, forwardedRef) => {
606
+ const pressedRef = useRef2(false);
607
+ const beginPress = useCallback4(() => {
608
+ if (!pressedRef.current) {
609
+ pressedRef.current = true;
610
+ onPressStart?.();
611
+ }
612
+ }, [
613
+ onPressStart
614
+ ]);
615
+ const endPress = useCallback4(() => {
616
+ if (pressedRef.current) {
617
+ pressedRef.current = false;
618
+ onPressEnd?.();
619
+ }
620
+ }, [
621
+ onPressEnd
622
+ ]);
623
+ const handlePointerDown = useCallback4((event) => {
624
+ event.currentTarget.setPointerCapture(event.pointerId);
625
+ beginPress();
626
+ }, [
627
+ beginPress
628
+ ]);
629
+ const handleKeyDown = useCallback4((event) => {
630
+ if ((event.key === " " || event.key === "Enter") && !event.repeat) {
631
+ event.preventDefault();
632
+ beginPress();
633
+ }
634
+ }, [
635
+ beginPress
636
+ ]);
637
+ const handleKeyUp = useCallback4((event) => {
638
+ if (event.key === " " || event.key === "Enter") {
639
+ event.preventDefault();
640
+ endPress();
641
+ }
642
+ }, [
643
+ endPress
644
+ ]);
645
+ const recordingClassNames = recording ? "bg-error-surface" : void 0;
646
+ const holdHandlers = mode === "hold" ? {
647
+ onPointerDown: handlePointerDown,
648
+ onPointerUp: endPress,
649
+ onPointerCancel: endPress,
650
+ onLostPointerCapture: endPress,
651
+ onKeyDown: handleKeyDown,
652
+ onKeyUp: handleKeyUp,
653
+ // Releasing focus mid-hold (e.g. tabbing away) must still end the press.
654
+ onBlur: endPress
655
+ } : {
656
+ onClick: onToggle
657
+ };
658
+ return /* @__PURE__ */ React12.createElement(IconButton, {
659
+ ...props,
660
+ ...holdHandlers,
661
+ classNames: [
662
+ recordingClassNames,
663
+ classNames
664
+ ],
665
+ icon,
666
+ ref: forwardedRef
667
+ });
668
+ });
669
+
606
670
  // src/components/Button/SystemIconButton.tsx
607
- import React13, { forwardRef as forwardRef11 } from "react";
671
+ import React14, { forwardRef as forwardRef12, useCallback as useCallback5, useRef as useRef3 } from "react";
608
672
  import { useTranslation as useTranslation2 } from "react-i18next";
609
673
  import { translationKey as translationKey2 } from "#translations";
610
674
 
611
675
  // src/components/Button/ToggleIconButton.tsx
612
- import React12, { forwardRef as forwardRef10 } from "react";
676
+ import React13, { forwardRef as forwardRef11 } from "react";
613
677
  import { mx as mx6 } from "@dxos/ui-theme";
614
- var ToggleIconButton = /* @__PURE__ */ forwardRef10(({ active, icon, activeIcon, iconClassNames, ...props }, forwardedRef) => /* @__PURE__ */ React12.createElement(IconButton, {
678
+ var ToggleIconButton = /* @__PURE__ */ forwardRef11(({ active, icon, activeIcon, iconClassNames, ...props }, forwardedRef) => /* @__PURE__ */ React13.createElement(IconButton, {
615
679
  ...props,
616
680
  ref: forwardedRef,
617
681
  icon: active && activeIcon ? activeIcon : icon,
@@ -619,9 +683,9 @@ var ToggleIconButton = /* @__PURE__ */ forwardRef10(({ active, icon, activeIcon,
619
683
  }));
620
684
 
621
685
  // src/components/Button/SystemIconButton.tsx
622
- var StarIconButton = /* @__PURE__ */ forwardRef11(({ label, active, ...props }, forwardedRef) => {
686
+ var StarIconButton = /* @__PURE__ */ forwardRef12(({ label, active, ...props }, forwardedRef) => {
623
687
  const { t } = useTranslation2(translationKey2);
624
- return /* @__PURE__ */ React13.createElement(ToggleIconButton, {
688
+ return /* @__PURE__ */ React14.createElement(ToggleIconButton, {
625
689
  ...props,
626
690
  active,
627
691
  icon: "ph--star--regular",
@@ -631,9 +695,9 @@ var StarIconButton = /* @__PURE__ */ forwardRef11(({ label, active, ...props },
631
695
  });
632
696
  });
633
697
  StarIconButton.displayName = "SystemIconButton.Star";
634
- var BookmarkIconButton = /* @__PURE__ */ forwardRef11(({ label, active, ...props }, forwardedRef) => {
698
+ var BookmarkIconButton = /* @__PURE__ */ forwardRef12(({ label, active, ...props }, forwardedRef) => {
635
699
  const { t } = useTranslation2(translationKey2);
636
- return /* @__PURE__ */ React13.createElement(ToggleIconButton, {
700
+ return /* @__PURE__ */ React14.createElement(ToggleIconButton, {
637
701
  ...props,
638
702
  active,
639
703
  icon: "ph--bookmark-simple--regular",
@@ -643,9 +707,9 @@ var BookmarkIconButton = /* @__PURE__ */ forwardRef11(({ label, active, ...props
643
707
  });
644
708
  });
645
709
  BookmarkIconButton.displayName = "SystemIconButton.Bookmark";
646
- var ExpanderIconButton = /* @__PURE__ */ forwardRef11(({ label, active, ...props }, forwardedRef) => {
710
+ var ExpanderIconButton = /* @__PURE__ */ forwardRef12(({ label, active, ...props }, forwardedRef) => {
647
711
  const { t } = useTranslation2(translationKey2);
648
- return /* @__PURE__ */ React13.createElement(ToggleIconButton, {
712
+ return /* @__PURE__ */ React14.createElement(ToggleIconButton, {
649
713
  ...props,
650
714
  active,
651
715
  icon: "ph--caret-right--regular",
@@ -654,9 +718,9 @@ var ExpanderIconButton = /* @__PURE__ */ forwardRef11(({ label, active, ...props
654
718
  });
655
719
  });
656
720
  ExpanderIconButton.displayName = "SystemIconButton.Expander";
657
- var AddIconButton = /* @__PURE__ */ forwardRef11(({ label, ...props }, forwardedRef) => {
721
+ var AddIconButton = /* @__PURE__ */ forwardRef12(({ label, ...props }, forwardedRef) => {
658
722
  const { t } = useTranslation2(translationKey2);
659
- return /* @__PURE__ */ React13.createElement(IconButton, {
723
+ return /* @__PURE__ */ React14.createElement(IconButton, {
660
724
  ...props,
661
725
  icon: "ph--plus--regular",
662
726
  label: label ?? t("system-button.add.label"),
@@ -664,9 +728,9 @@ var AddIconButton = /* @__PURE__ */ forwardRef11(({ label, ...props }, forwarded
664
728
  });
665
729
  });
666
730
  AddIconButton.displayName = "SystemIconButton.Add";
667
- var DeleteIconButton = /* @__PURE__ */ forwardRef11(({ label, ...props }, forwardedRef) => {
731
+ var DeleteIconButton = /* @__PURE__ */ forwardRef12(({ label, ...props }, forwardedRef) => {
668
732
  const { t } = useTranslation2(translationKey2);
669
- return /* @__PURE__ */ React13.createElement(IconButton, {
733
+ return /* @__PURE__ */ React14.createElement(IconButton, {
670
734
  ...props,
671
735
  icon: "ph--trash--regular",
672
736
  label: label ?? t("system-button.delete.label"),
@@ -674,9 +738,9 @@ var DeleteIconButton = /* @__PURE__ */ forwardRef11(({ label, ...props }, forwar
674
738
  });
675
739
  });
676
740
  DeleteIconButton.displayName = "SystemIconButton.Delete";
677
- var EditIconButton = /* @__PURE__ */ forwardRef11(({ label, ...props }, forwardedRef) => {
741
+ var EditIconButton = /* @__PURE__ */ forwardRef12(({ label, ...props }, forwardedRef) => {
678
742
  const { t } = useTranslation2(translationKey2);
679
- return /* @__PURE__ */ React13.createElement(IconButton, {
743
+ return /* @__PURE__ */ React14.createElement(IconButton, {
680
744
  ...props,
681
745
  icon: "ph--pen--regular",
682
746
  label: label ?? t("system-button.edit.label"),
@@ -684,9 +748,9 @@ var EditIconButton = /* @__PURE__ */ forwardRef11(({ label, ...props }, forwarde
684
748
  });
685
749
  });
686
750
  EditIconButton.displayName = "SystemIconButton.Edit";
687
- var CloseIconButton = /* @__PURE__ */ forwardRef11(({ label, ...props }, forwardedRef) => {
751
+ var CloseIconButton = /* @__PURE__ */ forwardRef12(({ label, ...props }, forwardedRef) => {
688
752
  const { t } = useTranslation2(translationKey2);
689
- return /* @__PURE__ */ React13.createElement(IconButton, {
753
+ return /* @__PURE__ */ React14.createElement(IconButton, {
690
754
  ...props,
691
755
  icon: "ph--x--regular",
692
756
  label: label ?? t("system-button.close.label"),
@@ -694,6 +758,68 @@ var CloseIconButton = /* @__PURE__ */ forwardRef11(({ label, ...props }, forward
694
758
  });
695
759
  });
696
760
  CloseIconButton.displayName = "SystemIconButton.Close";
761
+ var ClipboardIconButton = /* @__PURE__ */ forwardRef12(({ label, onCopy, ...props }, forwardedRef) => {
762
+ const { t } = useTranslation2(translationKey2);
763
+ const handleCopy = useCallback5(() => {
764
+ const text = onCopy();
765
+ if (text) {
766
+ void navigator.clipboard.writeText(text);
767
+ }
768
+ }, [
769
+ onCopy
770
+ ]);
771
+ return /* @__PURE__ */ React14.createElement(IconButton, {
772
+ ...props,
773
+ icon: "ph--clipboard--regular",
774
+ label: label ?? t("system-button.clipboard.label"),
775
+ onClick: handleCopy,
776
+ ref: forwardedRef
777
+ });
778
+ });
779
+ ClipboardIconButton.displayName = "SystemIconButton.Clipboard";
780
+ var UploadIconButton = /* @__PURE__ */ forwardRef12(({ accept, onFileChange, label, ...props }, forwardedRef) => {
781
+ const { t } = useTranslation2(translationKey2);
782
+ const fileInputRef = useRef3(null);
783
+ return /* @__PURE__ */ React14.createElement(React14.Fragment, null, /* @__PURE__ */ React14.createElement("input", {
784
+ className: "sr-only",
785
+ type: "file",
786
+ accept,
787
+ onChange: onFileChange,
788
+ ref: fileInputRef
789
+ }), /* @__PURE__ */ React14.createElement(IconButton, {
790
+ icon: "ph--upload-simple--regular",
791
+ label: label ?? t("system-button.upload.label"),
792
+ ...props,
793
+ onClick: () => fileInputRef.current?.click(),
794
+ ref: forwardedRef
795
+ }));
796
+ });
797
+ UploadIconButton.displayName = "SystemIconButton.Upload";
798
+ var DownloadIconButton = /* @__PURE__ */ forwardRef12(({ filename, onDownload, label, ...props }, forwardedRef) => {
799
+ const { t } = useTranslation2(translationKey2);
800
+ const handleDownload = useCallback5(() => {
801
+ const blob = onDownload();
802
+ if (!blob) {
803
+ return;
804
+ }
805
+ const url = URL.createObjectURL(blob);
806
+ const a = document.createElement("a");
807
+ a.href = url;
808
+ a.download = filename;
809
+ a.click();
810
+ URL.revokeObjectURL(url);
811
+ }, [
812
+ onDownload
813
+ ]);
814
+ return /* @__PURE__ */ React14.createElement(IconButton, {
815
+ icon: "ph--download-simple--regular",
816
+ label: label ?? t("system-button.download.label"),
817
+ ...props,
818
+ onClick: handleDownload,
819
+ ref: forwardedRef
820
+ });
821
+ });
822
+ DownloadIconButton.displayName = "SystemIconButton.Download";
697
823
  var SystemIconButton = {
698
824
  Star: StarIconButton,
699
825
  Bookmark: BookmarkIconButton,
@@ -701,19 +827,22 @@ var SystemIconButton = {
701
827
  Add: AddIconButton,
702
828
  Delete: DeleteIconButton,
703
829
  Edit: EditIconButton,
704
- Close: CloseIconButton
830
+ Close: CloseIconButton,
831
+ Clipboard: ClipboardIconButton,
832
+ Upload: UploadIconButton,
833
+ Download: DownloadIconButton
705
834
  };
706
835
 
707
836
  // src/components/Button/Toggle.tsx
708
837
  import * as TogglePrimitive from "@radix-ui/react-toggle";
709
- import React14, { forwardRef as forwardRef12 } from "react";
710
- var Toggle = /* @__PURE__ */ forwardRef12(({ defaultPressed, pressed, onPressedChange, ...props }, forwardedRef) => {
711
- return /* @__PURE__ */ React14.createElement(TogglePrimitive.Root, {
838
+ import React15, { forwardRef as forwardRef13 } from "react";
839
+ var Toggle = /* @__PURE__ */ forwardRef13(({ defaultPressed, pressed, onPressedChange, ...props }, forwardedRef) => {
840
+ return /* @__PURE__ */ React15.createElement(TogglePrimitive.Root, {
712
841
  defaultPressed,
713
842
  pressed,
714
843
  onPressedChange,
715
844
  asChild: true
716
- }, /* @__PURE__ */ React14.createElement(Button, {
845
+ }, /* @__PURE__ */ React15.createElement(Button, {
717
846
  ...props,
718
847
  ref: forwardedRef
719
848
  }));
@@ -721,22 +850,22 @@ var Toggle = /* @__PURE__ */ forwardRef12(({ defaultPressed, pressed, onPressedC
721
850
 
722
851
  // src/components/Button/ToggleGroup.tsx
723
852
  import * as ToggleGroupPrimitive from "@radix-ui/react-toggle-group";
724
- import React15, { forwardRef as forwardRef13 } from "react";
725
- var ToggleGroup = /* @__PURE__ */ forwardRef13(({ classNames, children, ...props }, forwardedRef) => {
726
- return /* @__PURE__ */ React15.createElement(ToggleGroupPrimitive.Root, {
853
+ import React16, { forwardRef as forwardRef14 } from "react";
854
+ var ToggleGroup = /* @__PURE__ */ forwardRef14(({ classNames, children, ...props }, forwardedRef) => {
855
+ return /* @__PURE__ */ React16.createElement(ToggleGroupPrimitive.Root, {
727
856
  ...props,
728
857
  asChild: true
729
- }, /* @__PURE__ */ React15.createElement(ButtonGroup, {
858
+ }, /* @__PURE__ */ React16.createElement(ButtonGroup, {
730
859
  classNames,
731
860
  children,
732
861
  ref: forwardedRef
733
862
  }));
734
863
  });
735
- var ToggleGroupItem = /* @__PURE__ */ forwardRef13(({ variant, elevation, density, classNames, children, ...props }, forwardedRef) => {
736
- return /* @__PURE__ */ React15.createElement(ToggleGroupPrimitive.Item, {
864
+ var ToggleGroupItem = /* @__PURE__ */ forwardRef14(({ variant, elevation, density, classNames, children, ...props }, forwardedRef) => {
865
+ return /* @__PURE__ */ React16.createElement(ToggleGroupPrimitive.Item, {
737
866
  ...props,
738
867
  asChild: true
739
- }, /* @__PURE__ */ React15.createElement(Button, {
868
+ }, /* @__PURE__ */ React16.createElement(Button, {
740
869
  variant,
741
870
  elevation,
742
871
  density,
@@ -745,11 +874,11 @@ var ToggleGroupItem = /* @__PURE__ */ forwardRef13(({ variant, elevation, densit
745
874
  ref: forwardedRef
746
875
  }));
747
876
  });
748
- var ToggleGroupIconItem = /* @__PURE__ */ forwardRef13(({ variant, label, icon, size, elevation, density, classNames, ...props }, forwardedRef) => {
749
- return /* @__PURE__ */ React15.createElement(ToggleGroupPrimitive.Item, {
877
+ var ToggleGroupIconItem = /* @__PURE__ */ forwardRef14(({ variant, label, icon, size, elevation, density, classNames, ...props }, forwardedRef) => {
878
+ return /* @__PURE__ */ React16.createElement(ToggleGroupPrimitive.Item, {
750
879
  ...props,
751
880
  asChild: true
752
- }, /* @__PURE__ */ React15.createElement(IconButton, {
881
+ }, /* @__PURE__ */ React16.createElement(IconButton, {
753
882
  variant,
754
883
  elevation,
755
884
  density,
@@ -763,7 +892,7 @@ var ToggleGroupIconItem = /* @__PURE__ */ forwardRef13(({ variant, label, icon,
763
892
 
764
893
  // src/components/Calendar/Calendar.tsx
765
894
  import { CalendarDate, parseDate } from "@internationalized/date";
766
- import React16, { forwardRef as forwardRef14 } from "react";
895
+ import React17, { forwardRef as forwardRef15 } from "react";
767
896
  import { Button as RACButton, Calendar as RACCalendar, CalendarCell as RACCalendarCell, CalendarGrid as RACCalendarGrid, CalendarGridBody as RACCalendarGridBody, CalendarGridHeader as RACCalendarGridHeader, CalendarHeaderCell as RACCalendarHeaderCell, Heading as RACHeading, RangeCalendar as RACRangeCalendar } from "react-aria-components";
768
897
  var toCalendarDate = (date) => {
769
898
  if (!date) {
@@ -779,7 +908,7 @@ var fromCalendarDate = (value) => {
779
908
  };
780
909
  var CalendarShell = ({ classNames, className, isDisabled, forwardedRef, children }) => {
781
910
  const { tx } = useThemeContext();
782
- return /* @__PURE__ */ React16.createElement("div", {
911
+ return /* @__PURE__ */ React17.createElement("div", {
783
912
  ref: forwardedRef,
784
913
  className: tx("calendar.root", {}, classNames, className) ?? void 0,
785
914
  "aria-disabled": isDisabled || void 0
@@ -787,38 +916,38 @@ var CalendarShell = ({ classNames, className, isDisabled, forwardedRef, children
787
916
  };
788
917
  var CalendarChrome = () => {
789
918
  const { tx } = useThemeContext();
790
- return /* @__PURE__ */ React16.createElement("header", {
919
+ return /* @__PURE__ */ React17.createElement("header", {
791
920
  className: tx("calendar.nav", {}) ?? void 0
792
- }, /* @__PURE__ */ React16.createElement(RACButton, {
921
+ }, /* @__PURE__ */ React17.createElement(RACButton, {
793
922
  slot: "previous",
794
923
  className: tx("calendar.button_previous", {}) ?? void 0
795
- }, /* @__PURE__ */ React16.createElement(Icon, {
924
+ }, /* @__PURE__ */ React17.createElement(Icon, {
796
925
  size: 4,
797
926
  icon: "ph--caret-left--regular"
798
- })), /* @__PURE__ */ React16.createElement(RACHeading, {
927
+ })), /* @__PURE__ */ React17.createElement(RACHeading, {
799
928
  className: tx("calendar.caption_label", {}) ?? void 0
800
- }), /* @__PURE__ */ React16.createElement(RACButton, {
929
+ }), /* @__PURE__ */ React17.createElement(RACButton, {
801
930
  slot: "next",
802
931
  className: tx("calendar.button_next", {}) ?? void 0
803
- }, /* @__PURE__ */ React16.createElement(Icon, {
932
+ }, /* @__PURE__ */ React17.createElement(Icon, {
804
933
  size: 4,
805
934
  icon: "ph--caret-right--regular"
806
935
  })));
807
936
  };
808
937
  var CalendarGridContent = () => {
809
938
  const { tx } = useThemeContext();
810
- return /* @__PURE__ */ React16.createElement(RACCalendarGrid, {
939
+ return /* @__PURE__ */ React17.createElement(RACCalendarGrid, {
811
940
  className: tx("calendar.month_grid", {}) ?? void 0
812
- }, /* @__PURE__ */ React16.createElement(RACCalendarGridHeader, {
941
+ }, /* @__PURE__ */ React17.createElement(RACCalendarGridHeader, {
813
942
  className: tx("calendar.weekdays", {}) ?? void 0
814
- }, (day) => /* @__PURE__ */ React16.createElement(RACCalendarHeaderCell, {
943
+ }, (day) => /* @__PURE__ */ React17.createElement(RACCalendarHeaderCell, {
815
944
  className: tx("calendar.weekday", {}) ?? void 0
816
- }, day)), /* @__PURE__ */ React16.createElement(RACCalendarGridBody, null, (date) => /* @__PURE__ */ React16.createElement(RACCalendarCell, {
945
+ }, day)), /* @__PURE__ */ React17.createElement(RACCalendarGridBody, null, (date) => /* @__PURE__ */ React17.createElement(RACCalendarCell, {
817
946
  date,
818
947
  className: tx("calendar.day", {}) ?? void 0
819
948
  })));
820
949
  };
821
- var CalendarRoot = /* @__PURE__ */ forwardRef14((props, forwardedRef) => {
950
+ var CalendarRoot = /* @__PURE__ */ forwardRef15((props, forwardedRef) => {
822
951
  const { classNames, className, isDisabled, minValue, maxValue, defaultMonth } = props;
823
952
  const defaultFocused = toCalendarDate(defaultMonth) ?? void 0;
824
953
  if (props.mode === "range") {
@@ -846,12 +975,12 @@ var CalendarRoot = /* @__PURE__ */ forwardRef14((props, forwardedRef) => {
846
975
  }
847
976
  }
848
977
  };
849
- return /* @__PURE__ */ React16.createElement(CalendarShell, {
978
+ return /* @__PURE__ */ React17.createElement(CalendarShell, {
850
979
  classNames,
851
980
  className,
852
981
  isDisabled,
853
982
  forwardedRef
854
- }, /* @__PURE__ */ React16.createElement(RACRangeCalendar, racProps2, /* @__PURE__ */ React16.createElement(CalendarChrome, null), /* @__PURE__ */ React16.createElement(CalendarGridContent, null)));
983
+ }, /* @__PURE__ */ React17.createElement(RACRangeCalendar, racProps2, /* @__PURE__ */ React17.createElement(CalendarChrome, null), /* @__PURE__ */ React17.createElement(CalendarGridContent, null)));
855
984
  }
856
985
  const racProps = {
857
986
  isDisabled,
@@ -861,12 +990,12 @@ var CalendarRoot = /* @__PURE__ */ forwardRef14((props, forwardedRef) => {
861
990
  value: toCalendarDate(props.selected),
862
991
  onChange: (next) => props.onSelect?.(fromCalendarDate(next))
863
992
  };
864
- return /* @__PURE__ */ React16.createElement(CalendarShell, {
993
+ return /* @__PURE__ */ React17.createElement(CalendarShell, {
865
994
  classNames,
866
995
  className,
867
996
  isDisabled,
868
997
  forwardedRef
869
- }, /* @__PURE__ */ React16.createElement(RACCalendar, racProps, /* @__PURE__ */ React16.createElement(CalendarChrome, null), /* @__PURE__ */ React16.createElement(CalendarGridContent, null)));
998
+ }, /* @__PURE__ */ React17.createElement(RACCalendar, racProps, /* @__PURE__ */ React17.createElement(CalendarChrome, null), /* @__PURE__ */ React17.createElement(CalendarGridContent, null)));
870
999
  });
871
1000
  CalendarRoot.displayName = "Calendar.Root";
872
1001
  var Calendar = {
@@ -877,7 +1006,7 @@ var Calendar = {
877
1006
  import { Primitive as Primitive10 } from "@radix-ui/react-primitive";
878
1007
  import { Slot as Slot10 } from "@radix-ui/react-slot";
879
1008
  import DOMPurify from "dompurify";
880
- import React21, { forwardRef as forwardRef17, useId as useId3, useMemo as useMemo5 } from "react";
1009
+ import React22, { forwardRef as forwardRef18, useId as useId3, useMemo as useMemo5 } from "react";
881
1010
  import { useTranslation as useTranslation3 } from "react-i18next";
882
1011
  import { iconSize } from "@dxos/ui-theme";
883
1012
  import { translationKey as translationKey3 } from "#translations";
@@ -885,27 +1014,26 @@ import { translationKey as translationKey3 } from "#translations";
885
1014
  // src/components/Column/Column.tsx
886
1015
  import { Primitive as Primitive7 } from "@radix-ui/react-primitive";
887
1016
  import { Slot as Slot7 } from "@radix-ui/react-slot";
888
- import React17 from "react";
1017
+ import React18 from "react";
889
1018
  var COLUMN_ROOT_NAME = "Column.Root";
890
1019
  var gutterSizes = {
891
- xs: "var(--dx-gutter-xs)",
892
1020
  sm: "var(--dx-gutter-sm)",
893
1021
  md: "var(--dx-gutter-md)",
894
1022
  lg: "var(--dx-gutter-lg)"
895
1023
  };
896
- var ColumnRoot = slottable(({ children, asChild, role, gutter = "md", ...props }, forwardedRef) => {
1024
+ var ColumnRoot = slottable(({ children, asChild, role, gutter = "lg", ...props }, forwardedRef) => {
897
1025
  const { className, ...rest } = composableProps(props);
898
1026
  const Comp = asChild ? Slot7 : Primitive7.div;
899
1027
  const { tx } = useThemeContext();
900
1028
  const gutterSize = gutterSizes[gutter];
901
- return /* @__PURE__ */ React17.createElement(Comp, {
1029
+ return /* @__PURE__ */ React18.createElement(Comp, {
902
1030
  ...rest,
903
1031
  role: role ?? "none",
904
1032
  style: {
905
1033
  ...rest.style,
906
1034
  "--gutter": gutterSize,
907
1035
  "--dx-col": "2 / span 1",
908
- gridTemplateColumns: [
1036
+ "gridTemplateColumns": [
909
1037
  gutterSize,
910
1038
  "minmax(0,1fr)",
911
1039
  gutterSize
@@ -923,7 +1051,7 @@ var ColumnRow = slottable(({ children, asChild, role, ...props }, forwardedRef)
923
1051
  const { className, ...rest } = composableProps(props);
924
1052
  const Comp = asChild ? Slot7 : Primitive7.div;
925
1053
  const { tx } = useThemeContext();
926
- return /* @__PURE__ */ React17.createElement(Comp, {
1054
+ return /* @__PURE__ */ React18.createElement(Comp, {
927
1055
  ...rest,
928
1056
  role: role ?? "none",
929
1057
  className: tx("column.row", {}, className),
@@ -936,7 +1064,7 @@ var ColumnBleed = slottable(({ children, asChild, ...props }, forwardedRef) => {
936
1064
  const { tx } = useThemeContext();
937
1065
  const { className, ...rest } = composableProps(props);
938
1066
  const Comp = asChild ? Slot7 : Primitive7.div;
939
- return /* @__PURE__ */ React17.createElement(Comp, {
1067
+ return /* @__PURE__ */ React18.createElement(Comp, {
940
1068
  ...rest,
941
1069
  className: tx("column.bleed", {}, className),
942
1070
  ref: forwardedRef
@@ -948,7 +1076,7 @@ var ColumnCenter = slottable(({ children, asChild, ...props }, forwardedRef) =>
948
1076
  const { tx } = useThemeContext();
949
1077
  const { className, ...rest } = composableProps(props);
950
1078
  const Comp = asChild ? Slot7 : Primitive7.div;
951
- return /* @__PURE__ */ React17.createElement(Comp, {
1079
+ return /* @__PURE__ */ React18.createElement(Comp, {
952
1080
  ...rest,
953
1081
  className: tx("column.center", {}, className),
954
1082
  ref: forwardedRef
@@ -960,7 +1088,7 @@ var ColumnBlock = slottable(({ children, asChild, end, compact, square, ...props
960
1088
  const { tx } = useThemeContext();
961
1089
  const { className, ...rest } = composableProps(props);
962
1090
  const Comp = asChild ? Slot7 : Primitive7.div;
963
- return /* @__PURE__ */ React17.createElement(Comp, {
1091
+ return /* @__PURE__ */ React18.createElement(Comp, {
964
1092
  ...rest,
965
1093
  "data-slot": end ? "end" : "start",
966
1094
  className: tx("column.block", {
@@ -981,18 +1109,18 @@ var Column = {
981
1109
  };
982
1110
 
983
1111
  // src/components/Image/Image.tsx
984
- import React18, { useCallback as useCallback4, useRef as useRef2, useState as useState3 } from "react";
1112
+ import React19, { useCallback as useCallback6, useRef as useRef4, useState as useState3 } from "react";
985
1113
  import { mx as mx7 } from "@dxos/ui-theme";
986
1114
  var cache = /* @__PURE__ */ new Map();
987
1115
  var Image = ({ classNames, src, alt = "", fit = "contain", crossOrigin, sampleSize = 64, contrast = 0.9 }) => {
988
1116
  const [crossOriginState, setCrossOriginState] = useState3(crossOrigin);
989
1117
  const [dominantColor, setDominantColor] = useState3(void 0);
990
1118
  const [imageLoaded, setImageLoaded] = useState3(false);
991
- const canvasRef = useRef2(null);
1119
+ const canvasRef = useRef4(null);
992
1120
  const handleImageError = () => {
993
1121
  setCrossOriginState(void 0);
994
1122
  };
995
- const handleImageLoad = useCallback4(({ target }) => {
1123
+ const handleImageLoad = useCallback6(({ target }) => {
996
1124
  const rgb = cache.get(src);
997
1125
  if (rgb) {
998
1126
  setDominantColor(rgb);
@@ -1022,7 +1150,7 @@ var Image = ({ classNames, src, alt = "", fit = "contain", crossOrigin, sampleSi
1022
1150
  contrast,
1023
1151
  src
1024
1152
  ]);
1025
- return /* @__PURE__ */ React18.createElement("div", {
1153
+ return /* @__PURE__ */ React19.createElement("div", {
1026
1154
  // `isolate` (`isolation: isolate`) creates a new stacking context so
1027
1155
  // the inner <img>'s `z-10` stays scoped to this wrapper. Without it
1028
1156
  // the z-10 leaks into the parent's stacking context and elevates the
@@ -1033,20 +1161,20 @@ var Image = ({ classNames, src, alt = "", fit = "contain", crossOrigin, sampleSi
1033
1161
  style: {
1034
1162
  backgroundColor: dominantColor
1035
1163
  }
1036
- }, /* @__PURE__ */ React18.createElement("canvas", {
1164
+ }, /* @__PURE__ */ React19.createElement("canvas", {
1037
1165
  ref: canvasRef,
1038
1166
  style: {
1039
1167
  display: "none"
1040
1168
  },
1041
1169
  "aria-hidden": "true"
1042
- }), /* @__PURE__ */ React18.createElement("div", {
1170
+ }), /* @__PURE__ */ React19.createElement("div", {
1043
1171
  className: "absolute inset-0 pointer-events-none",
1044
1172
  style: {
1045
1173
  background: dominantColor ? `radial-gradient(circle at center, transparent 30%, ${dominantColor} 100%)` : void 0,
1046
1174
  transition: "opacity 0.7s ease-in-out",
1047
1175
  opacity: 0.5
1048
1176
  }
1049
- }), /* @__PURE__ */ React18.createElement("img", {
1177
+ }), /* @__PURE__ */ React19.createElement("img", {
1050
1178
  src,
1051
1179
  alt,
1052
1180
  crossOrigin: crossOriginState,
@@ -1145,15 +1273,15 @@ var isTransparent = (pixels, sampleSize, threshold = 0.5) => {
1145
1273
  import * as ContextMenuPrimitive from "@radix-ui/react-context-menu";
1146
1274
  import { Primitive as Primitive8 } from "@radix-ui/react-primitive";
1147
1275
  import { Slot as Slot8 } from "@radix-ui/react-slot";
1148
- import React19, { forwardRef as forwardRef15 } from "react";
1276
+ import React20, { forwardRef as forwardRef16 } from "react";
1149
1277
  var ContextMenuRoot = ContextMenuPrimitive.ContextMenu;
1150
1278
  var ContextMenuTrigger = ContextMenuPrimitive.Trigger;
1151
1279
  var ContextMenuPortal = ContextMenuPrimitive.Portal;
1152
- var ContextMenuContent = /* @__PURE__ */ forwardRef15(({ classNames, children, collisionPadding = 8, ...props }, forwardedRef) => {
1280
+ var ContextMenuContent = /* @__PURE__ */ forwardRef16(({ classNames, children, collisionPadding = 8, ...props }, forwardedRef) => {
1153
1281
  const { tx } = useThemeContext();
1154
1282
  const elevation = useElevationContext();
1155
1283
  const safeCollisionPadding = useSafeCollisionPadding(collisionPadding);
1156
- return /* @__PURE__ */ React19.createElement(ContextMenuPrimitive.Content, {
1284
+ return /* @__PURE__ */ React20.createElement(ContextMenuPrimitive.Content, {
1157
1285
  ...props,
1158
1286
  "data-arrow-keys": "up down",
1159
1287
  collisionPadding: safeCollisionPadding,
@@ -1163,18 +1291,18 @@ var ContextMenuContent = /* @__PURE__ */ forwardRef15(({ classNames, children, c
1163
1291
  ref: forwardedRef
1164
1292
  }, children);
1165
1293
  });
1166
- var ContextMenuViewport = /* @__PURE__ */ forwardRef15(({ classNames, asChild, children, ...props }, forwardedRef) => {
1294
+ var ContextMenuViewport = /* @__PURE__ */ forwardRef16(({ classNames, asChild, children, ...props }, forwardedRef) => {
1167
1295
  const { tx } = useThemeContext();
1168
1296
  const Comp = asChild ? Slot8 : Primitive8.div;
1169
- return /* @__PURE__ */ React19.createElement(Comp, {
1297
+ return /* @__PURE__ */ React20.createElement(Comp, {
1170
1298
  ...props,
1171
1299
  className: tx("menu.viewport", {}, classNames),
1172
1300
  ref: forwardedRef
1173
1301
  }, children);
1174
1302
  });
1175
- var ContextMenuArrow = /* @__PURE__ */ forwardRef15(({ classNames, ...props }, forwardedRef) => {
1303
+ var ContextMenuArrow = /* @__PURE__ */ forwardRef16(({ classNames, ...props }, forwardedRef) => {
1176
1304
  const { tx } = useThemeContext();
1177
- return /* @__PURE__ */ React19.createElement(ContextMenuPrimitive.Arrow, {
1305
+ return /* @__PURE__ */ React20.createElement(ContextMenuPrimitive.Arrow, {
1178
1306
  ...props,
1179
1307
  className: tx("menu.arrow", {}, classNames),
1180
1308
  ref: forwardedRef
@@ -1182,33 +1310,33 @@ var ContextMenuArrow = /* @__PURE__ */ forwardRef15(({ classNames, ...props }, f
1182
1310
  });
1183
1311
  var ContextMenuGroup = ContextMenuPrimitive.Group;
1184
1312
  var ContextMenuItemIndicator = ContextMenuPrimitive.ItemIndicator;
1185
- var ContextMenuItem = /* @__PURE__ */ forwardRef15(({ classNames, ...props }, forwardedRef) => {
1313
+ var ContextMenuItem = /* @__PURE__ */ forwardRef16(({ classNames, ...props }, forwardedRef) => {
1186
1314
  const { tx } = useThemeContext();
1187
- return /* @__PURE__ */ React19.createElement(ContextMenuPrimitive.Item, {
1315
+ return /* @__PURE__ */ React20.createElement(ContextMenuPrimitive.Item, {
1188
1316
  ...props,
1189
1317
  className: tx("menu.item", {}, classNames),
1190
1318
  ref: forwardedRef
1191
1319
  });
1192
1320
  });
1193
- var ContextMenuCheckboxItem = /* @__PURE__ */ forwardRef15(({ classNames, ...props }, forwardedRef) => {
1321
+ var ContextMenuCheckboxItem = /* @__PURE__ */ forwardRef16(({ classNames, ...props }, forwardedRef) => {
1194
1322
  const { tx } = useThemeContext();
1195
- return /* @__PURE__ */ React19.createElement(ContextMenuPrimitive.CheckboxItem, {
1323
+ return /* @__PURE__ */ React20.createElement(ContextMenuPrimitive.CheckboxItem, {
1196
1324
  ...props,
1197
1325
  className: tx("menu.item", {}, classNames),
1198
1326
  ref: forwardedRef
1199
1327
  });
1200
1328
  });
1201
- var ContextMenuSeparator = /* @__PURE__ */ forwardRef15(({ classNames, ...props }, forwardedRef) => {
1329
+ var ContextMenuSeparator = /* @__PURE__ */ forwardRef16(({ classNames, ...props }, forwardedRef) => {
1202
1330
  const { tx } = useThemeContext();
1203
- return /* @__PURE__ */ React19.createElement(ContextMenuPrimitive.Separator, {
1331
+ return /* @__PURE__ */ React20.createElement(ContextMenuPrimitive.Separator, {
1204
1332
  ...props,
1205
1333
  className: tx("menu.separator", {}, classNames),
1206
1334
  ref: forwardedRef
1207
1335
  });
1208
1336
  });
1209
- var ContextMenuGroupLabel = /* @__PURE__ */ forwardRef15(({ classNames, ...props }, forwardedRef) => {
1337
+ var ContextMenuGroupLabel = /* @__PURE__ */ forwardRef16(({ classNames, ...props }, forwardedRef) => {
1210
1338
  const { tx } = useThemeContext();
1211
- return /* @__PURE__ */ React19.createElement(ContextMenuPrimitive.Label, {
1339
+ return /* @__PURE__ */ React20.createElement(ContextMenuPrimitive.Label, {
1212
1340
  ...props,
1213
1341
  className: tx("menu.groupLabel", {}, classNames),
1214
1342
  ref: forwardedRef
@@ -1239,7 +1367,7 @@ import { createMenuScope } from "@radix-ui/react-menu";
1239
1367
  import { Primitive as Primitive9 } from "@radix-ui/react-primitive";
1240
1368
  import { Slot as Slot9 } from "@radix-ui/react-slot";
1241
1369
  import { useControllableState } from "@radix-ui/react-use-controllable-state";
1242
- import React20, { forwardRef as forwardRef16, useCallback as useCallback5, useEffect as useEffect2, useMemo as useMemo4, useRef as useRef3 } from "react";
1370
+ import React21, { forwardRef as forwardRef17, useCallback as useCallback7, useEffect as useEffect2, useMemo as useMemo4, useRef as useRef5 } from "react";
1243
1371
  var DROPDOWN_MENU_NAME = "DropdownMenu";
1244
1372
  var [createDropdownMenuContext, createDropdownMenuScope] = createContextScope(DROPDOWN_MENU_NAME, [
1245
1373
  createMenuScope
@@ -1248,24 +1376,24 @@ var useMenuScope = createMenuScope();
1248
1376
  var [DropdownMenuProvider, useDropdownMenuContext] = createDropdownMenuContext(DROPDOWN_MENU_NAME);
1249
1377
  var DropdownMenuRoot = ({ __scopeDropdownMenu, children, dir, modal = true, open: openProp, defaultOpen, onOpenChange }) => {
1250
1378
  const menuScope = useMenuScope(__scopeDropdownMenu);
1251
- const triggerRef = useRef3(null);
1379
+ const triggerRef = useRef5(null);
1252
1380
  const [open = false, setOpen] = useControllableState({
1253
1381
  prop: openProp,
1254
1382
  defaultProp: defaultOpen,
1255
1383
  onChange: onOpenChange
1256
1384
  });
1257
- return /* @__PURE__ */ React20.createElement(DropdownMenuProvider, {
1385
+ return /* @__PURE__ */ React21.createElement(DropdownMenuProvider, {
1258
1386
  scope: __scopeDropdownMenu,
1259
1387
  triggerId: useId2(),
1260
1388
  triggerRef,
1261
1389
  contentId: useId2(),
1262
1390
  open,
1263
1391
  onOpenChange: setOpen,
1264
- onOpenToggle: useCallback5(() => setOpen((prevOpen) => !prevOpen), [
1392
+ onOpenToggle: useCallback7(() => setOpen((prevOpen) => !prevOpen), [
1265
1393
  setOpen
1266
1394
  ]),
1267
1395
  modal
1268
- }, /* @__PURE__ */ React20.createElement(MenuPrimitive.Root, {
1396
+ }, /* @__PURE__ */ React21.createElement(MenuPrimitive.Root, {
1269
1397
  ...menuScope,
1270
1398
  dir,
1271
1399
  modal,
@@ -1275,14 +1403,14 @@ var DropdownMenuRoot = ({ __scopeDropdownMenu, children, dir, modal = true, open
1275
1403
  };
1276
1404
  DropdownMenuRoot.displayName = DROPDOWN_MENU_NAME;
1277
1405
  var TRIGGER_NAME = "DropdownMenu.Trigger";
1278
- var DropdownMenuTrigger = /* @__PURE__ */ forwardRef16((props, forwardedRef) => {
1406
+ var DropdownMenuTrigger = /* @__PURE__ */ forwardRef17((props, forwardedRef) => {
1279
1407
  const { __scopeDropdownMenu, disabled = false, ...triggerProps } = props;
1280
1408
  const context = useDropdownMenuContext(TRIGGER_NAME, __scopeDropdownMenu);
1281
1409
  const menuScope = useMenuScope(__scopeDropdownMenu);
1282
- return /* @__PURE__ */ React20.createElement(MenuPrimitive.Anchor, {
1410
+ return /* @__PURE__ */ React21.createElement(MenuPrimitive.Anchor, {
1283
1411
  asChild: true,
1284
1412
  ...menuScope
1285
- }, /* @__PURE__ */ React20.createElement(Primitive9.button, {
1413
+ }, /* @__PURE__ */ React21.createElement(Primitive9.button, {
1286
1414
  type: "button",
1287
1415
  id: context.triggerId,
1288
1416
  "aria-haspopup": "menu",
@@ -1336,7 +1464,7 @@ var DropdownMenuVirtualTrigger = (props) => {
1336
1464
  context.triggerRef.current = virtualRef.current;
1337
1465
  }
1338
1466
  });
1339
- return /* @__PURE__ */ React20.createElement(MenuPrimitive.Anchor, {
1467
+ return /* @__PURE__ */ React21.createElement(MenuPrimitive.Anchor, {
1340
1468
  ...menuScope,
1341
1469
  virtualRef
1342
1470
  });
@@ -1346,29 +1474,29 @@ var PORTAL_NAME = "DropdownMenu.Portal";
1346
1474
  var DropdownMenuPortal = (props) => {
1347
1475
  const { __scopeDropdownMenu, ...portalProps } = props;
1348
1476
  const menuScope = useMenuScope(__scopeDropdownMenu);
1349
- return /* @__PURE__ */ React20.createElement(MenuPrimitive.Portal, {
1477
+ return /* @__PURE__ */ React21.createElement(MenuPrimitive.Portal, {
1350
1478
  ...menuScope,
1351
1479
  ...portalProps
1352
1480
  });
1353
1481
  };
1354
1482
  DropdownMenuPortal.displayName = PORTAL_NAME;
1355
- var DropdownMenuViewport = /* @__PURE__ */ forwardRef16(({ classNames, asChild, children, ...props }, forwardedRef) => {
1483
+ var DropdownMenuViewport = /* @__PURE__ */ forwardRef17(({ classNames, asChild, children, ...props }, forwardedRef) => {
1356
1484
  const { tx } = useThemeContext();
1357
1485
  const Comp = asChild ? Slot9 : Primitive9.div;
1358
- return /* @__PURE__ */ React20.createElement(Comp, {
1486
+ return /* @__PURE__ */ React21.createElement(Comp, {
1359
1487
  ...props,
1360
1488
  className: tx("menu.viewport", {}, classNames),
1361
1489
  ref: forwardedRef
1362
1490
  }, children);
1363
1491
  });
1364
1492
  var CONTENT_NAME = "DropdownMenu.Content";
1365
- var DropdownMenuContent = /* @__PURE__ */ forwardRef16((props, forwardedRef) => {
1493
+ var DropdownMenuContent = /* @__PURE__ */ forwardRef17((props, forwardedRef) => {
1366
1494
  const { __scopeDropdownMenu, classNames, collisionPadding = 8, collisionBoundary, ...contentProps } = props;
1367
1495
  const { tx } = useThemeContext();
1368
1496
  const context = useDropdownMenuContext(CONTENT_NAME, __scopeDropdownMenu);
1369
1497
  const elevation = useElevationContext();
1370
1498
  const menuScope = useMenuScope(__scopeDropdownMenu);
1371
- const hasInteractedOutsideRef = useRef3(false);
1499
+ const hasInteractedOutsideRef = useRef5(false);
1372
1500
  const safeCollisionPadding = useSafeCollisionPadding(collisionPadding);
1373
1501
  const computedCollisionBoundary = useMemo4(() => {
1374
1502
  const closestBoundary = context.triggerRef.current?.closest("[data-popover-collision-boundary]");
@@ -1386,7 +1514,7 @@ var DropdownMenuContent = /* @__PURE__ */ forwardRef16((props, forwardedRef) =>
1386
1514
  collisionBoundary,
1387
1515
  context.triggerRef.current
1388
1516
  ]);
1389
- return /* @__PURE__ */ React20.createElement(MenuPrimitive.Content, {
1517
+ return /* @__PURE__ */ React21.createElement(MenuPrimitive.Content, {
1390
1518
  id: context.contentId,
1391
1519
  "aria-labelledby": context.triggerId,
1392
1520
  ...menuScope,
@@ -1428,10 +1556,10 @@ var DropdownMenuContent = /* @__PURE__ */ forwardRef16((props, forwardedRef) =>
1428
1556
  });
1429
1557
  DropdownMenuContent.displayName = CONTENT_NAME;
1430
1558
  var GROUP_NAME = "DropdownMenu.Group";
1431
- var DropdownMenuGroup = /* @__PURE__ */ forwardRef16((props, forwardedRef) => {
1559
+ var DropdownMenuGroup = /* @__PURE__ */ forwardRef17((props, forwardedRef) => {
1432
1560
  const { __scopeDropdownMenu, ...groupProps } = props;
1433
1561
  const menuScope = useMenuScope(__scopeDropdownMenu);
1434
- return /* @__PURE__ */ React20.createElement(MenuPrimitive.Group, {
1562
+ return /* @__PURE__ */ React21.createElement(MenuPrimitive.Group, {
1435
1563
  ...menuScope,
1436
1564
  ...groupProps,
1437
1565
  ref: forwardedRef
@@ -1439,11 +1567,11 @@ var DropdownMenuGroup = /* @__PURE__ */ forwardRef16((props, forwardedRef) => {
1439
1567
  });
1440
1568
  DropdownMenuGroup.displayName = GROUP_NAME;
1441
1569
  var LABEL_NAME = "DropdownMenu.Label";
1442
- var DropdownMenuGroupLabel = /* @__PURE__ */ forwardRef16((props, forwardedRef) => {
1570
+ var DropdownMenuGroupLabel = /* @__PURE__ */ forwardRef17((props, forwardedRef) => {
1443
1571
  const { __scopeDropdownMenu, classNames, ...labelProps } = props;
1444
1572
  const menuScope = useMenuScope(__scopeDropdownMenu);
1445
1573
  const { tx } = useThemeContext();
1446
- return /* @__PURE__ */ React20.createElement(MenuPrimitive.Label, {
1574
+ return /* @__PURE__ */ React21.createElement(MenuPrimitive.Label, {
1447
1575
  ...menuScope,
1448
1576
  ...labelProps,
1449
1577
  className: tx("menu.groupLabel", {}, classNames),
@@ -1452,11 +1580,11 @@ var DropdownMenuGroupLabel = /* @__PURE__ */ forwardRef16((props, forwardedRef)
1452
1580
  });
1453
1581
  DropdownMenuGroupLabel.displayName = LABEL_NAME;
1454
1582
  var ITEM_NAME = "DropdownMenu.Item";
1455
- var DropdownMenuItem = /* @__PURE__ */ forwardRef16((props, forwardedRef) => {
1583
+ var DropdownMenuItem = /* @__PURE__ */ forwardRef17((props, forwardedRef) => {
1456
1584
  const { __scopeDropdownMenu, classNames, ...itemProps } = props;
1457
1585
  const menuScope = useMenuScope(__scopeDropdownMenu);
1458
1586
  const { tx } = useThemeContext();
1459
- return /* @__PURE__ */ React20.createElement(MenuPrimitive.Item, {
1587
+ return /* @__PURE__ */ React21.createElement(MenuPrimitive.Item, {
1460
1588
  ...menuScope,
1461
1589
  ...itemProps,
1462
1590
  className: tx("menu.item", {}, classNames),
@@ -1465,11 +1593,11 @@ var DropdownMenuItem = /* @__PURE__ */ forwardRef16((props, forwardedRef) => {
1465
1593
  });
1466
1594
  DropdownMenuItem.displayName = ITEM_NAME;
1467
1595
  var CHECKBOX_ITEM_NAME = "DropdownMenu.CheckboxItem";
1468
- var DropdownMenuCheckboxItem = /* @__PURE__ */ forwardRef16((props, forwardedRef) => {
1596
+ var DropdownMenuCheckboxItem = /* @__PURE__ */ forwardRef17((props, forwardedRef) => {
1469
1597
  const { __scopeDropdownMenu, classNames, ...checkboxItemProps } = props;
1470
1598
  const menuScope = useMenuScope(__scopeDropdownMenu);
1471
1599
  const { tx } = useThemeContext();
1472
- return /* @__PURE__ */ React20.createElement(MenuPrimitive.CheckboxItem, {
1600
+ return /* @__PURE__ */ React21.createElement(MenuPrimitive.CheckboxItem, {
1473
1601
  ...menuScope,
1474
1602
  ...checkboxItemProps,
1475
1603
  className: tx("menu.item", {}, classNames),
@@ -1478,10 +1606,10 @@ var DropdownMenuCheckboxItem = /* @__PURE__ */ forwardRef16((props, forwardedRef
1478
1606
  });
1479
1607
  DropdownMenuCheckboxItem.displayName = CHECKBOX_ITEM_NAME;
1480
1608
  var RADIO_GROUP_NAME = "DropdownMenu.RadioGroup";
1481
- var DropdownMenuRadioGroup = /* @__PURE__ */ forwardRef16((props, forwardedRef) => {
1609
+ var DropdownMenuRadioGroup = /* @__PURE__ */ forwardRef17((props, forwardedRef) => {
1482
1610
  const { __scopeDropdownMenu, ...radioGroupProps } = props;
1483
1611
  const menuScope = useMenuScope(__scopeDropdownMenu);
1484
- return /* @__PURE__ */ React20.createElement(MenuPrimitive.RadioGroup, {
1612
+ return /* @__PURE__ */ React21.createElement(MenuPrimitive.RadioGroup, {
1485
1613
  ...menuScope,
1486
1614
  ...radioGroupProps,
1487
1615
  ref: forwardedRef
@@ -1489,11 +1617,11 @@ var DropdownMenuRadioGroup = /* @__PURE__ */ forwardRef16((props, forwardedRef)
1489
1617
  });
1490
1618
  DropdownMenuRadioGroup.displayName = RADIO_GROUP_NAME;
1491
1619
  var RADIO_ITEM_NAME = "DropdownMenu.RadioItem";
1492
- var DropdownMenuRadioItem = /* @__PURE__ */ forwardRef16((props, forwardedRef) => {
1620
+ var DropdownMenuRadioItem = /* @__PURE__ */ forwardRef17((props, forwardedRef) => {
1493
1621
  const { __scopeDropdownMenu, classNames, ...itemProps } = props;
1494
1622
  const menuScope = useMenuScope(__scopeDropdownMenu);
1495
1623
  const { tx } = useThemeContext();
1496
- return /* @__PURE__ */ React20.createElement(MenuPrimitive.Item, {
1624
+ return /* @__PURE__ */ React21.createElement(MenuPrimitive.Item, {
1497
1625
  ...menuScope,
1498
1626
  ...itemProps,
1499
1627
  className: tx("menu.item", {}, classNames),
@@ -1502,10 +1630,10 @@ var DropdownMenuRadioItem = /* @__PURE__ */ forwardRef16((props, forwardedRef) =
1502
1630
  });
1503
1631
  DropdownMenuRadioItem.displayName = RADIO_ITEM_NAME;
1504
1632
  var INDICATOR_NAME = "DropdownMenu.ItemIndicator";
1505
- var DropdownMenuItemIndicator = /* @__PURE__ */ forwardRef16((props, forwardedRef) => {
1633
+ var DropdownMenuItemIndicator = /* @__PURE__ */ forwardRef17((props, forwardedRef) => {
1506
1634
  const { __scopeDropdownMenu, ...itemIndicatorProps } = props;
1507
1635
  const menuScope = useMenuScope(__scopeDropdownMenu);
1508
- return /* @__PURE__ */ React20.createElement(MenuPrimitive.ItemIndicator, {
1636
+ return /* @__PURE__ */ React21.createElement(MenuPrimitive.ItemIndicator, {
1509
1637
  ...menuScope,
1510
1638
  ...itemIndicatorProps,
1511
1639
  ref: forwardedRef
@@ -1513,11 +1641,11 @@ var DropdownMenuItemIndicator = /* @__PURE__ */ forwardRef16((props, forwardedRe
1513
1641
  });
1514
1642
  DropdownMenuItemIndicator.displayName = INDICATOR_NAME;
1515
1643
  var SEPARATOR_NAME = "DropdownMenu.Separator";
1516
- var DropdownMenuSeparator = /* @__PURE__ */ forwardRef16((props, forwardedRef) => {
1644
+ var DropdownMenuSeparator = /* @__PURE__ */ forwardRef17((props, forwardedRef) => {
1517
1645
  const { __scopeDropdownMenu, classNames, ...separatorProps } = props;
1518
1646
  const menuScope = useMenuScope(__scopeDropdownMenu);
1519
1647
  const { tx } = useThemeContext();
1520
- return /* @__PURE__ */ React20.createElement(MenuPrimitive.Separator, {
1648
+ return /* @__PURE__ */ React21.createElement(MenuPrimitive.Separator, {
1521
1649
  ...menuScope,
1522
1650
  ...separatorProps,
1523
1651
  className: tx("menu.separator", {}, classNames),
@@ -1526,11 +1654,11 @@ var DropdownMenuSeparator = /* @__PURE__ */ forwardRef16((props, forwardedRef) =
1526
1654
  });
1527
1655
  DropdownMenuSeparator.displayName = SEPARATOR_NAME;
1528
1656
  var ARROW_NAME = "DropdownMenu.Arrow";
1529
- var DropdownMenuArrow = /* @__PURE__ */ forwardRef16((props, forwardedRef) => {
1657
+ var DropdownMenuArrow = /* @__PURE__ */ forwardRef17((props, forwardedRef) => {
1530
1658
  const { __scopeDropdownMenu, classNames, ...arrowProps } = props;
1531
1659
  const menuScope = useMenuScope(__scopeDropdownMenu);
1532
1660
  const { tx } = useThemeContext();
1533
- return /* @__PURE__ */ React20.createElement(MenuPrimitive.Arrow, {
1661
+ return /* @__PURE__ */ React21.createElement(MenuPrimitive.Arrow, {
1534
1662
  ...menuScope,
1535
1663
  ...arrowProps,
1536
1664
  className: tx("menu.arrow", {}, classNames),
@@ -1546,17 +1674,17 @@ var DropdownMenuSub = (props) => {
1546
1674
  defaultProp: defaultOpen,
1547
1675
  onChange: onOpenChange
1548
1676
  });
1549
- return /* @__PURE__ */ React20.createElement(MenuPrimitive.Sub, {
1677
+ return /* @__PURE__ */ React21.createElement(MenuPrimitive.Sub, {
1550
1678
  ...menuScope,
1551
1679
  open,
1552
1680
  onOpenChange: setOpen
1553
1681
  }, children);
1554
1682
  };
1555
1683
  var SUB_TRIGGER_NAME = "DropdownMenu.SubTrigger";
1556
- var DropdownMenuSubTrigger = /* @__PURE__ */ forwardRef16((props, forwardedRef) => {
1684
+ var DropdownMenuSubTrigger = /* @__PURE__ */ forwardRef17((props, forwardedRef) => {
1557
1685
  const { __scopeDropdownMenu, ...subTriggerProps } = props;
1558
1686
  const menuScope = useMenuScope(__scopeDropdownMenu);
1559
- return /* @__PURE__ */ React20.createElement(MenuPrimitive.SubTrigger, {
1687
+ return /* @__PURE__ */ React21.createElement(MenuPrimitive.SubTrigger, {
1560
1688
  ...menuScope,
1561
1689
  ...subTriggerProps,
1562
1690
  ref: forwardedRef
@@ -1564,10 +1692,10 @@ var DropdownMenuSubTrigger = /* @__PURE__ */ forwardRef16((props, forwardedRef)
1564
1692
  });
1565
1693
  DropdownMenuSubTrigger.displayName = SUB_TRIGGER_NAME;
1566
1694
  var SUB_CONTENT_NAME = "DropdownMenu.SubContent";
1567
- var DropdownMenuSubContent = /* @__PURE__ */ forwardRef16((props, forwardedRef) => {
1695
+ var DropdownMenuSubContent = /* @__PURE__ */ forwardRef17((props, forwardedRef) => {
1568
1696
  const { __scopeDropdownMenu, ...subContentProps } = props;
1569
1697
  const menuScope = useMenuScope(__scopeDropdownMenu);
1570
- return /* @__PURE__ */ React20.createElement(MenuPrimitive.SubContent, {
1698
+ return /* @__PURE__ */ React21.createElement(MenuPrimitive.SubContent, {
1571
1699
  ...menuScope,
1572
1700
  ...subContentProps,
1573
1701
  ref: forwardedRef,
@@ -1612,15 +1740,15 @@ var CARD_ROOT_NAME = "Card.Root";
1612
1740
  var CardRoot = composable(({ children, id, role, border = true, fullWidth, density, ...props }, forwardedRef) => {
1613
1741
  const { className, ...rest } = composableProps(props);
1614
1742
  const { tx } = useThemeContext();
1615
- return /* @__PURE__ */ React21.createElement(Column.Root, {
1743
+ return /* @__PURE__ */ React22.createElement(Column.Root, {
1616
1744
  asChild: true,
1617
- gutter: density === "lg" ? "lg" : density === "sm" || density === "xs" ? "sm" : "md",
1745
+ gutter: "lg",
1618
1746
  classNames: tx("card.root", {
1619
1747
  border,
1620
1748
  fullWidth
1621
1749
  }, className),
1622
1750
  role: role ?? "group"
1623
- }, /* @__PURE__ */ React21.createElement("div", {
1751
+ }, /* @__PURE__ */ React22.createElement("div", {
1624
1752
  ...rest,
1625
1753
  ...id && {
1626
1754
  "data-object-id": id
@@ -1634,7 +1762,7 @@ var CardHeader = slottable(({ children, asChild, style, ...props }, forwardedRef
1634
1762
  const { tx } = useThemeContext();
1635
1763
  const { className, ...rest } = composableProps(props);
1636
1764
  const Comp = asChild ? Slot10 : "header";
1637
- return /* @__PURE__ */ React21.createElement(Comp, {
1765
+ return /* @__PURE__ */ React22.createElement(Comp, {
1638
1766
  ...rest,
1639
1767
  style: {
1640
1768
  ...iconSize(5),
@@ -1646,9 +1774,9 @@ var CardHeader = slottable(({ children, asChild, style, ...props }, forwardedRef
1646
1774
  });
1647
1775
  CardHeader.displayName = CARD_HEADER_NAME;
1648
1776
  var CARD_DRAG_HANDLE_NAME = "Card.DragHandle";
1649
- var CardDragHandle = /* @__PURE__ */ forwardRef17(({ testId = "drag-handle", label }, forwardedRef) => {
1777
+ var CardDragHandle = /* @__PURE__ */ forwardRef18(({ testId = "drag-handle", label }, forwardedRef) => {
1650
1778
  const { t } = useTranslation3(translationKey3);
1651
- return /* @__PURE__ */ React21.createElement(CardBlock, null, /* @__PURE__ */ React21.createElement(IconButton, {
1779
+ return /* @__PURE__ */ React22.createElement(CardBlock, null, /* @__PURE__ */ React22.createElement(IconButton, {
1652
1780
  "data-testid": testId,
1653
1781
  tabIndex: -1,
1654
1782
  noTooltip: true,
@@ -1671,11 +1799,11 @@ var CARD_ACTION_LABEL_KEYS = {
1671
1799
  close: "toolbar-close.label",
1672
1800
  delete: "toolbar-delete.label"
1673
1801
  };
1674
- var CardActionIconButton = /* @__PURE__ */ forwardRef17(({ action, onClick, label }, forwardedRef) => {
1802
+ var CardActionIconButton = /* @__PURE__ */ forwardRef18(({ action, onClick, label }, forwardedRef) => {
1675
1803
  const { t } = useTranslation3(translationKey3);
1676
- return /* @__PURE__ */ React21.createElement(CardBlock, {
1804
+ return /* @__PURE__ */ React22.createElement(CardBlock, {
1677
1805
  end: true
1678
- }, /* @__PURE__ */ React21.createElement(IconButton, {
1806
+ }, /* @__PURE__ */ React22.createElement(IconButton, {
1679
1807
  iconOnly: true,
1680
1808
  icon: CARD_ACTION_ICONS[action],
1681
1809
  variant: "ghost",
@@ -1689,31 +1817,31 @@ CardActionIconButton.displayName = CARD_ACTION_ICON_BUTTON_NAME;
1689
1817
  var CARD_MENU_NAME = "Card.Menu";
1690
1818
  function CardMenu({ context, items }) {
1691
1819
  const { t } = useTranslation3(translationKey3);
1692
- return /* @__PURE__ */ React21.createElement(CardBlock, {
1820
+ return /* @__PURE__ */ React22.createElement(CardBlock, {
1693
1821
  end: true
1694
- }, /* @__PURE__ */ React21.createElement(DropdownMenu.Root, null, /* @__PURE__ */ React21.createElement(DropdownMenu.Trigger, {
1822
+ }, /* @__PURE__ */ React22.createElement(DropdownMenu.Root, null, /* @__PURE__ */ React22.createElement(DropdownMenu.Trigger, {
1695
1823
  disabled: !items?.length,
1696
1824
  asChild: true
1697
- }, /* @__PURE__ */ React21.createElement(IconButton, {
1825
+ }, /* @__PURE__ */ React22.createElement(IconButton, {
1698
1826
  iconOnly: true,
1699
1827
  variant: "ghost",
1700
1828
  icon: "ph--dots-three-vertical--regular",
1701
1829
  label: t("toolbar-menu.label")
1702
- })), (items?.length ?? 0) > 0 && /* @__PURE__ */ React21.createElement(DropdownMenu.Portal, null, /* @__PURE__ */ React21.createElement(DropdownMenu.Content, null, /* @__PURE__ */ React21.createElement(DropdownMenu.Viewport, null, items?.map(({ label, onClick: onSelect }, index) => (
1830
+ })), (items?.length ?? 0) > 0 && /* @__PURE__ */ React22.createElement(DropdownMenu.Portal, null, /* @__PURE__ */ React22.createElement(DropdownMenu.Content, null, /* @__PURE__ */ React22.createElement(DropdownMenu.Viewport, null, items?.map(({ label, onClick: onSelect }, index) => (
1703
1831
  // `context` is the generic payload threaded to each handler; the cast is the
1704
1832
  // generic boundary (T may be `void`, so `context` is typed `T | undefined`).
1705
- /* @__PURE__ */ React21.createElement(DropdownMenu.Item, {
1833
+ /* @__PURE__ */ React22.createElement(DropdownMenu.Item, {
1706
1834
  key: index,
1707
1835
  onSelect: () => onSelect(context)
1708
1836
  }, label)
1709
- ))), /* @__PURE__ */ React21.createElement(DropdownMenu.Arrow, null)))));
1837
+ ))), /* @__PURE__ */ React22.createElement(DropdownMenu.Arrow, null)))));
1710
1838
  }
1711
1839
  CardMenu.displayName = CARD_MENU_NAME;
1712
1840
  var CARD_BLOCK_NAME = "Card.Block";
1713
1841
  var CardBlock = composable(({ children, ...props }, forwardedRef) => {
1714
1842
  const { tx } = useThemeContext();
1715
1843
  const { className, ...rest } = composableProps(props);
1716
- return /* @__PURE__ */ React21.createElement(Column.Block, {
1844
+ return /* @__PURE__ */ React22.createElement(Column.Block, {
1717
1845
  ...rest,
1718
1846
  classNames: tx("card.block", {}, className),
1719
1847
  ref: forwardedRef
@@ -1727,7 +1855,7 @@ var CardTitle = slottable(({ children, asChild, ...props }, forwardedRef) => {
1727
1855
  role: "heading"
1728
1856
  });
1729
1857
  const Comp = asChild ? Slot10 : Primitive10.div;
1730
- return /* @__PURE__ */ React21.createElement(Comp, {
1858
+ return /* @__PURE__ */ React22.createElement(Comp, {
1731
1859
  ...rest,
1732
1860
  className: tx("card.title", {}, className),
1733
1861
  ref: forwardedRef
@@ -1739,7 +1867,7 @@ var CardBody = slottable(({ children, asChild, ...props }, forwardedRef) => {
1739
1867
  const { className, ...rest } = composableProps(props);
1740
1868
  const Comp = asChild ? Slot10 : Primitive10.div;
1741
1869
  const { tx } = useThemeContext();
1742
- return /* @__PURE__ */ React21.createElement(Comp, {
1870
+ return /* @__PURE__ */ React22.createElement(Comp, {
1743
1871
  ...rest,
1744
1872
  className: tx("card.body", {}, className),
1745
1873
  ref: forwardedRef
@@ -1752,13 +1880,13 @@ var CardSection = slottable(({ children, asChild, title, role, ...props }, forwa
1752
1880
  const Comp = asChild ? Slot10 : Primitive10.div;
1753
1881
  const { tx } = useThemeContext();
1754
1882
  const titleId = useId3();
1755
- return /* @__PURE__ */ React21.createElement(Comp, {
1883
+ return /* @__PURE__ */ React22.createElement(Comp, {
1756
1884
  ...rest,
1757
1885
  role: role ?? (title ? "group" : "none"),
1758
1886
  "aria-labelledby": title ? titleId : void 0,
1759
1887
  className: tx("card.section", {}, className),
1760
1888
  ref: forwardedRef
1761
- }, title && /* @__PURE__ */ React21.createElement("div", {
1889
+ }, title && /* @__PURE__ */ React22.createElement("div", {
1762
1890
  id: titleId,
1763
1891
  className: tx("card.section-title", {})
1764
1892
  }, title), children);
@@ -1769,7 +1897,7 @@ var CardRow = slottable(({ children, asChild, fullWidth, style, ...props }, forw
1769
1897
  const { tx } = useThemeContext();
1770
1898
  const { className, ...rest } = composableProps(props);
1771
1899
  const Comp = asChild ? Slot10 : Primitive10.div;
1772
- return /* @__PURE__ */ React21.createElement(Comp, {
1900
+ return /* @__PURE__ */ React22.createElement(Comp, {
1773
1901
  ...rest,
1774
1902
  style: {
1775
1903
  ...iconSize(4),
@@ -1787,14 +1915,14 @@ var CardText = slottable(({ children, asChild, role, truncate, variant = "defaul
1787
1915
  const { tx } = useThemeContext();
1788
1916
  const { className, ...rest } = composableProps(props);
1789
1917
  const Comp = asChild ? Slot10 : Primitive10.div;
1790
- return /* @__PURE__ */ React21.createElement(Comp, {
1918
+ return /* @__PURE__ */ React22.createElement(Comp, {
1791
1919
  ...rest,
1792
1920
  role: role ?? "none",
1793
1921
  className: tx("card.text", {
1794
1922
  variant
1795
1923
  }, className),
1796
1924
  ref: forwardedRef
1797
- }, /* @__PURE__ */ React21.createElement("span", {
1925
+ }, /* @__PURE__ */ React22.createElement("span", {
1798
1926
  className: tx("card.text-span", {
1799
1927
  variant,
1800
1928
  truncate
@@ -1808,7 +1936,7 @@ function CardHtml({ html = "", variant = "default", ...props }) {
1808
1936
  const sanitized = useMemo5(() => DOMPurify.sanitize(html), [
1809
1937
  html
1810
1938
  ]);
1811
- return /* @__PURE__ */ React21.createElement("div", {
1939
+ return /* @__PURE__ */ React22.createElement("div", {
1812
1940
  ...props,
1813
1941
  className: tx("card.text", {
1814
1942
  variant
@@ -1825,7 +1953,7 @@ function CardPoster({ classNames, alt, aspect: aspectProp, image, icon, fit = "c
1825
1953
  const { tx } = useThemeContext();
1826
1954
  const aspect = aspectProp === "auto" ? "aspect-auto" : "aspect-video";
1827
1955
  if (image) {
1828
- return /* @__PURE__ */ React21.createElement(Image, {
1956
+ return /* @__PURE__ */ React22.createElement(Image, {
1829
1957
  classNames: [
1830
1958
  tx("card.poster", {}),
1831
1959
  aspect,
@@ -1838,14 +1966,14 @@ function CardPoster({ classNames, alt, aspect: aspectProp, image, icon, fit = "c
1838
1966
  });
1839
1967
  }
1840
1968
  if (icon) {
1841
- return /* @__PURE__ */ React21.createElement("div", {
1969
+ return /* @__PURE__ */ React22.createElement("div", {
1842
1970
  role: "image",
1843
1971
  className: tx("card.poster-icon", {}, [
1844
1972
  aspect,
1845
1973
  classNames
1846
1974
  ]),
1847
1975
  "aria-label": alt
1848
- }, /* @__PURE__ */ React21.createElement(Icon, {
1976
+ }, /* @__PURE__ */ React22.createElement(Icon, {
1849
1977
  icon,
1850
1978
  size: 10
1851
1979
  }));
@@ -1855,18 +1983,18 @@ CardPoster.displayName = CARD_POSTER_NAME;
1855
1983
  var CARD_ACTION_NAME = "Card.Action";
1856
1984
  function CardAction({ icon, actionIcon = "ph--arrow-right--regular", label, onClick }) {
1857
1985
  const { tx } = useThemeContext();
1858
- return /* @__PURE__ */ React21.createElement(Button, {
1986
+ return /* @__PURE__ */ React22.createElement(Button, {
1859
1987
  variant: "ghost",
1860
1988
  classNames: tx("card.action", {}),
1861
1989
  onClick
1862
- }, icon && /* @__PURE__ */ React21.createElement(CardBlock, null, /* @__PURE__ */ React21.createElement(Icon, {
1990
+ }, icon && /* @__PURE__ */ React22.createElement(CardBlock, null, /* @__PURE__ */ React22.createElement(Icon, {
1863
1991
  icon,
1864
1992
  size: 4
1865
- })), /* @__PURE__ */ React21.createElement("span", {
1993
+ })), /* @__PURE__ */ React22.createElement("span", {
1866
1994
  className: tx("card.action-label", {})
1867
- }, label), actionIcon && /* @__PURE__ */ React21.createElement(CardBlock, {
1995
+ }, label), actionIcon && /* @__PURE__ */ React22.createElement(CardBlock, {
1868
1996
  end: true
1869
- }, /* @__PURE__ */ React21.createElement(Icon, {
1997
+ }, /* @__PURE__ */ React22.createElement(Icon, {
1870
1998
  icon: actionIcon,
1871
1999
  size: 4
1872
2000
  })));
@@ -1875,21 +2003,21 @@ CardAction.displayName = CARD_ACTION_NAME;
1875
2003
  var CARD_LINK_NAME = "Card.Link";
1876
2004
  function CardLink({ label, href }) {
1877
2005
  const { tx } = useThemeContext();
1878
- return /* @__PURE__ */ React21.createElement("a", {
2006
+ return /* @__PURE__ */ React22.createElement("a", {
1879
2007
  className: tx("card.link", {}),
1880
2008
  "data-variant": "ghost",
1881
2009
  href,
1882
2010
  target: "_blank",
1883
2011
  rel: "noreferrer"
1884
- }, /* @__PURE__ */ React21.createElement(CardBlock, null, /* @__PURE__ */ React21.createElement(Icon, {
2012
+ }, /* @__PURE__ */ React22.createElement(CardBlock, null, /* @__PURE__ */ React22.createElement(Icon, {
1885
2013
  icon: "ph--link--regular",
1886
2014
  size: 4
1887
- })), /* @__PURE__ */ React21.createElement("span", {
2015
+ })), /* @__PURE__ */ React22.createElement("span", {
1888
2016
  className: tx("card.link-label", {})
1889
- }, label), /* @__PURE__ */ React21.createElement(CardBlock, {
2017
+ }, label), /* @__PURE__ */ React22.createElement(CardBlock, {
1890
2018
  end: true,
1891
2019
  classNames: "invisible group-hover:visible"
1892
- }, /* @__PURE__ */ React21.createElement(Icon, {
2020
+ }, /* @__PURE__ */ React22.createElement(Icon, {
1893
2021
  icon: "ph--arrow-square-out--regular",
1894
2022
  size: 4
1895
2023
  })));
@@ -1920,17 +2048,17 @@ var Card = {
1920
2048
  // src/components/Carousel/Carousel.tsx
1921
2049
  import { useArrowNavigationGroup } from "@fluentui/react-tabster";
1922
2050
  import { createContext as createContext3 } from "@radix-ui/react-context";
1923
- import React23, { useCallback as useCallback6, useEffect as useEffect3, useState as useState5 } from "react";
2051
+ import React24, { Children as Children2, cloneElement, isValidElement as isValidElement2, useCallback as useCallback8, useEffect as useEffect3, useRef as useRef6, useState as useState5 } from "react";
1924
2052
  import { mx as mx9 } from "@dxos/ui-theme";
1925
2053
 
1926
2054
  // src/components/MediaPlayer/MediaPlayer.tsx
1927
- import React22, { useState as useState4 } from "react";
2055
+ import React23, { useState as useState4 } from "react";
1928
2056
  import { mx as mx8 } from "@dxos/ui-theme";
1929
2057
  var FIT_CLASS = {
1930
- cover: "object-cover",
1931
- contain: "object-contain",
1932
- fill: "object-fill",
1933
- none: "object-none",
2058
+ "cover": "object-cover",
2059
+ "contain": "object-contain",
2060
+ "fill": "object-fill",
2061
+ "none": "object-none",
1934
2062
  "scale-down": "object-scale-down"
1935
2063
  };
1936
2064
  var VIDEO_EXTENSIONS = [
@@ -1968,7 +2096,7 @@ var MediaPlayer = ({ classNames, src, kind, controls = true, autoPlay = false, l
1968
2096
  if (isEmbedUrl(src)) {
1969
2097
  const resolved = kind ?? detectMediaKind(src) ?? "video";
1970
2098
  if (resolved === "audio") {
1971
- return /* @__PURE__ */ React22.createElement("audio", {
2099
+ return /* @__PURE__ */ React23.createElement("audio", {
1972
2100
  className: mx8("w-full", classNames),
1973
2101
  src,
1974
2102
  controls,
@@ -1979,7 +2107,7 @@ var MediaPlayer = ({ classNames, src, kind, controls = true, autoPlay = false, l
1979
2107
  "aria-label": alt
1980
2108
  });
1981
2109
  }
1982
- return /* @__PURE__ */ React22.createElement("video", {
2110
+ return /* @__PURE__ */ React23.createElement("video", {
1983
2111
  className: mx8("max-w-full max-h-full aspect-video", fitClass, classNames),
1984
2112
  src,
1985
2113
  controls,
@@ -1991,14 +2119,14 @@ var MediaPlayer = ({ classNames, src, kind, controls = true, autoPlay = false, l
1991
2119
  });
1992
2120
  }
1993
2121
  if (isCloudflareStreamEmbed(src)) {
1994
- return /* @__PURE__ */ React22.createElement(IframePlayer, {
2122
+ return /* @__PURE__ */ React23.createElement(IframePlayer, {
1995
2123
  key: src,
1996
2124
  classNames,
1997
2125
  src,
1998
2126
  alt
1999
2127
  });
2000
2128
  }
2001
- return /* @__PURE__ */ React22.createElement("img", {
2129
+ return /* @__PURE__ */ React23.createElement("img", {
2002
2130
  className: mx8(fitClass, classNames),
2003
2131
  src,
2004
2132
  alt: alt ?? "",
@@ -2010,9 +2138,9 @@ var MediaPlayer = ({ classNames, src, kind, controls = true, autoPlay = false, l
2010
2138
  };
2011
2139
  var IframePlayer = ({ src, alt, classNames }) => {
2012
2140
  const [loaded, setLoaded] = useState4(false);
2013
- return /* @__PURE__ */ React22.createElement("div", {
2141
+ return /* @__PURE__ */ React23.createElement("div", {
2014
2142
  className: mx8("relative bg-baseSurface", classNames)
2015
- }, /* @__PURE__ */ React22.createElement("iframe", {
2143
+ }, /* @__PURE__ */ React23.createElement("iframe", {
2016
2144
  src,
2017
2145
  title: alt ?? "Embedded media",
2018
2146
  loading: "lazy",
@@ -2032,50 +2160,93 @@ var IframePlayer = ({ src, alt, classNames }) => {
2032
2160
  var CAROUSEL_NAME = "Carousel";
2033
2161
  var [CarouselProvider, useCarouselContext] = createContext3(CAROUSEL_NAME);
2034
2162
  var useCarousel = () => useCarouselContext("useCarousel");
2035
- var CarouselRoot = ({ children, count, autorun = false, intervalMs = 5e3, defaultIndex = 0 }) => {
2163
+ var CarouselRoot = ({ children, count, autoAdvance = 0, defaultIndex = 0, transition = "none", continuous = false }) => {
2036
2164
  const [index, setIndexState] = useState5(defaultIndex);
2037
- const [autoAdvance, setAutoAdvance] = useState5(autorun);
2165
+ const [offset, setOffset] = useState5(defaultIndex);
2166
+ const [animate, setAnimate] = useState5(true);
2167
+ const [autoEnabled, setAutoEnabled] = useState5(autoAdvance > 0);
2168
+ const wraps = continuous && transition === "slide" && count > 1;
2169
+ const indexRef = useRef6(index);
2170
+ useEffect3(() => {
2171
+ indexRef.current = index;
2172
+ }, [
2173
+ index
2174
+ ]);
2038
2175
  useEffect3(() => {
2039
2176
  if (index >= count) {
2040
2177
  setIndexState(0);
2178
+ setOffset(0);
2041
2179
  }
2042
2180
  }, [
2043
2181
  count,
2044
2182
  index
2045
2183
  ]);
2184
+ const advance = useCallback8((delta, stopAuto) => {
2185
+ if (stopAuto) {
2186
+ setAutoEnabled(false);
2187
+ }
2188
+ const current = indexRef.current;
2189
+ const nextIndex = (current + delta + count) % count;
2190
+ setAnimate(true);
2191
+ if (wraps && delta === 1 && current === count - 1) {
2192
+ setOffset(count);
2193
+ } else if (wraps && delta === -1 && current === 0) {
2194
+ setOffset(-1);
2195
+ } else {
2196
+ setOffset(nextIndex);
2197
+ }
2198
+ setIndexState(nextIndex);
2199
+ }, [
2200
+ count,
2201
+ wraps
2202
+ ]);
2046
2203
  useEffect3(() => {
2047
- if (!autoAdvance || count <= 1 || intervalMs <= 0) {
2204
+ if (!autoEnabled || count <= 1 || autoAdvance <= 0) {
2048
2205
  return;
2049
2206
  }
2050
- const handle = setInterval(() => setIndexState((i) => (i + 1) % count), intervalMs);
2207
+ const handle = setInterval(() => advance(1, false), autoAdvance);
2051
2208
  return () => clearInterval(handle);
2052
2209
  }, [
2053
- autoAdvance,
2210
+ autoEnabled,
2054
2211
  count,
2055
- intervalMs
2212
+ autoAdvance,
2213
+ advance
2056
2214
  ]);
2057
- const setIndex = useCallback6((next2) => {
2058
- setAutoAdvance(false);
2215
+ const setIndex = useCallback8((next2) => {
2216
+ setAutoEnabled(false);
2217
+ setAnimate(true);
2218
+ setOffset(next2);
2059
2219
  setIndexState(next2);
2060
2220
  }, []);
2061
- const next = useCallback6(() => {
2062
- setAutoAdvance(false);
2063
- setIndexState((i) => (i + 1) % count);
2064
- }, [
2065
- count
2221
+ const next = useCallback8(() => advance(1, true), [
2222
+ advance
2223
+ ]);
2224
+ const prev = useCallback8(() => advance(-1, true), [
2225
+ advance
2066
2226
  ]);
2067
- const prev = useCallback6(() => {
2068
- setAutoAdvance(false);
2069
- setIndexState((i) => (i - 1 + count) % count);
2227
+ const settle = useCallback8(() => {
2228
+ if (offset === count) {
2229
+ setAnimate(false);
2230
+ setOffset(0);
2231
+ } else if (offset === -1) {
2232
+ setAnimate(false);
2233
+ setOffset(count - 1);
2234
+ }
2070
2235
  }, [
2236
+ offset,
2071
2237
  count
2072
2238
  ]);
2073
2239
  if (count === 0) {
2074
2240
  return null;
2075
2241
  }
2076
- return /* @__PURE__ */ React23.createElement(CarouselProvider, {
2242
+ return /* @__PURE__ */ React24.createElement(CarouselProvider, {
2077
2243
  index,
2078
2244
  count,
2245
+ transition,
2246
+ continuous: wraps,
2247
+ offset,
2248
+ animate,
2249
+ settle,
2079
2250
  setIndex,
2080
2251
  next,
2081
2252
  prev
@@ -2088,7 +2259,7 @@ var CarouselContent = composable(({ children, ...props }, forwardedRef) => (
2088
2259
  // its content height. With no parent height constraint, the `1fr` row simply tracks
2089
2260
  // row-1 content — preserving the existing aspect-video behaviour for unbounded use.
2090
2261
  // TODO(burdon): Move to Carousel.theme.ts
2091
- /* @__PURE__ */ React23.createElement("div", {
2262
+ /* @__PURE__ */ React24.createElement("div", {
2092
2263
  ...composableProps(props, {
2093
2264
  classNames: "w-full grid grid-cols-[min-content_1fr_min-content] grid-rows-[minmax(0,1fr)_auto] gap-4 items-center"
2094
2265
  }),
@@ -2098,8 +2269,8 @@ var CarouselContent = composable(({ children, ...props }, forwardedRef) => (
2098
2269
  CarouselContent.displayName = "Carousel.Content";
2099
2270
  var CarouselViewport = ({ children, classNames }) => {
2100
2271
  const { t } = useTranslation(translationKey);
2101
- const { count, next, prev } = useCarousel();
2102
- const handleKeyDown = useCallback6((event) => {
2272
+ const { count, transition, continuous, offset, animate, settle, next, prev } = useCarousel();
2273
+ const handleKeyDown = useCallback8((event) => {
2103
2274
  if (count <= 1) {
2104
2275
  return;
2105
2276
  }
@@ -2115,7 +2286,27 @@ var CarouselViewport = ({ children, classNames }) => {
2115
2286
  next,
2116
2287
  prev
2117
2288
  ]);
2118
- return /* @__PURE__ */ React23.createElement("div", {
2289
+ const slides = Children2.toArray(children);
2290
+ const first = slides[0];
2291
+ const last = slides[slides.length - 1];
2292
+ const trackChildren = continuous && slides.length > 1 ? [
2293
+ /* @__PURE__ */ isValidElement2(last) ? /* @__PURE__ */ cloneElement(last, {
2294
+ key: "clone-last"
2295
+ }) : last,
2296
+ ...slides,
2297
+ /* @__PURE__ */ isValidElement2(first) ? /* @__PURE__ */ cloneElement(first, {
2298
+ key: "clone-first"
2299
+ }) : first
2300
+ ] : slides;
2301
+ const translate = continuous ? -(offset + 1) * 100 : -offset * 100;
2302
+ const handleTransitionEnd = useCallback8((event) => {
2303
+ if (event.target === event.currentTarget && event.propertyName === "transform") {
2304
+ settle();
2305
+ }
2306
+ }, [
2307
+ settle
2308
+ ]);
2309
+ return /* @__PURE__ */ React24.createElement("div", {
2119
2310
  // TODO(burdon): Move to ui-theme.
2120
2311
  className: mx9("relative w-full aspect-video overflow-hidden", "focus:outline-none focus-visible:ring-2 focus-visible:ring-primary-500", classNames),
2121
2312
  tabIndex: 0,
@@ -2123,23 +2314,36 @@ var CarouselViewport = ({ children, classNames }) => {
2123
2314
  "aria-roledescription": "carousel",
2124
2315
  "aria-label": t("carousel-viewport.label"),
2125
2316
  onKeyDown: handleKeyDown
2126
- }, children);
2317
+ }, transition === "slide" ? (
2318
+ // Lay slides side-by-side in a flex track and translate by the active index. Each slide
2319
+ // sizes itself to the viewport via `shrink-0 basis-full` (see `Carousel.Slide`).
2320
+ // `motion-reduce` respects the user's reduced-motion preference; the snap after a wrap also
2321
+ // disables the transition (`animate === false`).
2322
+ /* @__PURE__ */ React24.createElement("div", {
2323
+ className: mx9("flex h-full motion-reduce:transition-none", animate ? "transition-transform duration-300 ease-out" : "transition-none"),
2324
+ style: {
2325
+ transform: `translateX(${translate}%)`
2326
+ },
2327
+ onTransitionEnd: handleTransitionEnd
2328
+ }, trackChildren)
2329
+ ) : children);
2127
2330
  };
2128
2331
  CarouselViewport.displayName = "Carousel.Viewport";
2129
2332
  var CarouselSlide = ({ index, classNames, src, kind, alt, controls, autoPlay, loop, muted, crossOrigin }) => {
2130
- const { index: active } = useCarousel();
2131
- if (active !== index) {
2333
+ const { index: active, transition } = useCarousel();
2334
+ if (transition !== "slide" && active !== index) {
2132
2335
  return null;
2133
2336
  }
2134
- return /* @__PURE__ */ React23.createElement("div", {
2135
- className: mx9("absolute inset-0 w-full h-full bg-baseSurface", classNames)
2136
- }, /* @__PURE__ */ React23.createElement(MediaPlayer, {
2337
+ return /* @__PURE__ */ React24.createElement("div", {
2338
+ className: mx9(transition === "slide" ? "relative shrink-0 basis-full h-full bg-baseSurface" : "absolute inset-0 w-full h-full bg-baseSurface", classNames)
2339
+ }, /* @__PURE__ */ React24.createElement(MediaPlayer, {
2137
2340
  src,
2138
2341
  kind,
2139
2342
  alt,
2140
2343
  classNames: "w-full h-full",
2141
2344
  controls,
2142
- autoPlay,
2345
+ // In `slide` mode every slide is mounted; only auto-play the active one to avoid off-screen playback.
2346
+ autoPlay: autoPlay && active === index,
2143
2347
  loop,
2144
2348
  muted,
2145
2349
  crossOrigin
@@ -2150,9 +2354,9 @@ var CarouselPrevious = ({ classNames }) => {
2150
2354
  const { t } = useTranslation(translationKey);
2151
2355
  const { count, prev } = useCarousel();
2152
2356
  if (count <= 1) {
2153
- return /* @__PURE__ */ React23.createElement("div", null);
2357
+ return /* @__PURE__ */ React24.createElement("div", null);
2154
2358
  }
2155
- return /* @__PURE__ */ React23.createElement(IconButton, {
2359
+ return /* @__PURE__ */ React24.createElement(IconButton, {
2156
2360
  classNames: mx9("self-center", classNames),
2157
2361
  square: true,
2158
2362
  variant: "ghost",
@@ -2167,9 +2371,9 @@ var CarouselNext = ({ classNames }) => {
2167
2371
  const { t } = useTranslation(translationKey);
2168
2372
  const { count, next } = useCarousel();
2169
2373
  if (count <= 1) {
2170
- return /* @__PURE__ */ React23.createElement("div", null);
2374
+ return /* @__PURE__ */ React24.createElement("div", null);
2171
2375
  }
2172
- return /* @__PURE__ */ React23.createElement(IconButton, {
2376
+ return /* @__PURE__ */ React24.createElement(IconButton, {
2173
2377
  classNames: mx9("self-center", classNames),
2174
2378
  square: true,
2175
2379
  variant: "ghost",
@@ -2190,29 +2394,31 @@ var CarouselIndicators = ({ classNames }) => {
2190
2394
  if (count <= 1) {
2191
2395
  return null;
2192
2396
  }
2193
- return /* @__PURE__ */ React23.createElement("div", {
2397
+ return /* @__PURE__ */ React24.createElement("div", {
2194
2398
  className: "col-start-2 overflow-hidden"
2195
- }, /* @__PURE__ */ React23.createElement("div", {
2399
+ }, /* @__PURE__ */ React24.createElement("div", {
2196
2400
  ...arrowNavigationAttrs,
2197
2401
  className: mx9("flex items-center justify-center", classNames),
2198
2402
  role: "tablist",
2199
2403
  "aria-label": t("carousel-indicators.label")
2200
2404
  }, Array.from({
2201
2405
  length: count
2202
- }).map((_, i) => /* @__PURE__ */ React23.createElement(IconButton, {
2406
+ }).map((_, i) => /* @__PURE__ */ React24.createElement(IconButton, {
2203
2407
  key: i,
2204
2408
  role: "tab",
2205
2409
  "aria-selected": i === index,
2206
- classNames: i === index ? "text-primary-500" : "text-description",
2410
+ classNames: mx9(i === index ? "text-primary-500" : "text-description"),
2411
+ variant: "ghost",
2412
+ density: "sm",
2413
+ size: 3,
2414
+ square: true,
2207
2415
  icon: i === index ? "ph--circle--fill" : "ph--circle--regular",
2208
2416
  iconOnly: true,
2209
2417
  label: t("carousel-go-to.label", {
2210
2418
  index: i + 1
2211
2419
  }),
2212
2420
  onClick: () => setIndex(i),
2213
- onFocus: () => setIndex(i),
2214
- size: 3,
2215
- variant: "ghost"
2421
+ onFocus: () => setIndex(i)
2216
2422
  }))));
2217
2423
  };
2218
2424
  CarouselIndicators.displayName = "Carousel.Indicators";
@@ -2224,9 +2430,9 @@ var CarouselCaption = ({ children, classNames }) => {
2224
2430
  }
2225
2431
  return (
2226
2432
  // TODO(burdon): Move to ui-theme.
2227
- /* @__PURE__ */ React23.createElement("div", {
2433
+ /* @__PURE__ */ React24.createElement("div", {
2228
2434
  className: "col-start-2"
2229
- }, /* @__PURE__ */ React23.createElement("p", {
2435
+ }, /* @__PURE__ */ React24.createElement("p", {
2230
2436
  className: mx9("text-center text-description", classNames)
2231
2437
  }, content))
2232
2438
  );
@@ -2244,7 +2450,7 @@ var Carousel = {
2244
2450
  };
2245
2451
 
2246
2452
  // src/components/Clipboard/ClipboardProvider.tsx
2247
- import React24, { createContext as createContext4, useCallback as useCallback7, useContext as useContext3, useState as useState6 } from "react";
2453
+ import React25, { createContext as createContext4, useCallback as useCallback9, useContext as useContext3, useState as useState6 } from "react";
2248
2454
  var ClipboardContext = /* @__PURE__ */ createContext4({
2249
2455
  textValue: "",
2250
2456
  setTextValue: async (_) => {
@@ -2253,11 +2459,11 @@ var ClipboardContext = /* @__PURE__ */ createContext4({
2253
2459
  var useClipboard = () => useContext3(ClipboardContext);
2254
2460
  var ClipboardProvider = ({ children }) => {
2255
2461
  const [textValue, setInternalTextValue] = useState6("");
2256
- const setTextValue = useCallback7(async (nextValue) => {
2462
+ const setTextValue = useCallback9(async (nextValue) => {
2257
2463
  await navigator.clipboard.writeText(nextValue);
2258
2464
  return setInternalTextValue(nextValue);
2259
2465
  }, []);
2260
- return /* @__PURE__ */ React24.createElement(ClipboardContext.Provider, {
2466
+ return /* @__PURE__ */ React25.createElement(ClipboardContext.Provider, {
2261
2467
  value: {
2262
2468
  textValue,
2263
2469
  setTextValue
@@ -2266,14 +2472,14 @@ var ClipboardProvider = ({ children }) => {
2266
2472
  };
2267
2473
 
2268
2474
  // src/components/Clipboard/CopyButton.tsx
2269
- import React25 from "react";
2475
+ import React26 from "react";
2270
2476
  import { mx as mx10, osTranslations } from "@dxos/ui-theme";
2271
2477
  var inactiveLabelStyles = "invisible h-px -mb-px overflow-hidden";
2272
2478
  var CopyButton = ({ classNames, value, size = 5, ...props }) => {
2273
2479
  const { t } = useTranslation(osTranslations);
2274
2480
  const { textValue, setTextValue } = useClipboard();
2275
2481
  const isCopied = textValue === value;
2276
- return /* @__PURE__ */ React25.createElement(Button, {
2482
+ return /* @__PURE__ */ React26.createElement(Button, {
2277
2483
  ...props,
2278
2484
  classNames: [
2279
2485
  "inline-flex flex-col justify-center",
@@ -2281,18 +2487,18 @@ var CopyButton = ({ classNames, value, size = 5, ...props }) => {
2281
2487
  ],
2282
2488
  onClick: () => setTextValue(value),
2283
2489
  "data-testid": "copy-invitation"
2284
- }, /* @__PURE__ */ React25.createElement("div", {
2490
+ }, /* @__PURE__ */ React26.createElement("div", {
2285
2491
  className: mx10("flex gap-1 items-center", isCopied && inactiveLabelStyles)
2286
- }, /* @__PURE__ */ React25.createElement("span", {
2492
+ }, /* @__PURE__ */ React26.createElement("span", {
2287
2493
  className: "px-1"
2288
- }, t("copy.label")), /* @__PURE__ */ React25.createElement(Icon, {
2494
+ }, t("copy.label")), /* @__PURE__ */ React26.createElement(Icon, {
2289
2495
  icon: "ph--copy--regular",
2290
2496
  size
2291
- })), /* @__PURE__ */ React25.createElement("div", {
2497
+ })), /* @__PURE__ */ React26.createElement("div", {
2292
2498
  className: mx10("flex gap-1 items-center", !isCopied && inactiveLabelStyles)
2293
- }, /* @__PURE__ */ React25.createElement("span", {
2499
+ }, /* @__PURE__ */ React26.createElement("span", {
2294
2500
  className: "px-1"
2295
- }, t("copy-success.label")), /* @__PURE__ */ React25.createElement(Icon, {
2501
+ }, t("copy-success.label")), /* @__PURE__ */ React26.createElement(Icon, {
2296
2502
  icon: "ph--check--regular",
2297
2503
  size
2298
2504
  })));
@@ -2303,7 +2509,7 @@ var CopyButtonIconOnly = ({ __scopeTooltip, value, classNames, size, variant, ..
2303
2509
  const isCopied = textValue === value;
2304
2510
  const label = isCopied ? t("copy-success.label") : props.label ?? t("copy.label");
2305
2511
  const { onOpen } = useTooltipContext("CopyButton", __scopeTooltip);
2306
- return /* @__PURE__ */ React25.createElement(IconButton, {
2512
+ return /* @__PURE__ */ React26.createElement(IconButton, {
2307
2513
  iconOnly: true,
2308
2514
  label,
2309
2515
  icon: "ph--copy--regular",
@@ -2328,7 +2534,7 @@ var Clipboard = {
2328
2534
  // src/components/DatePicker/DatePicker.tsx
2329
2535
  import { createContext as createContext5 } from "@radix-ui/react-context";
2330
2536
  import { format as formatDate } from "date-fns";
2331
- import React27, { forwardRef as forwardRef19, useCallback as useCallback9, useState as useState8 } from "react";
2537
+ import React28, { forwardRef as forwardRef20, useCallback as useCallback11, useState as useState8 } from "react";
2332
2538
 
2333
2539
  // src/components/Popover/Popover.tsx
2334
2540
  import { composeEventHandlers as composeEventHandlers2 } from "@radix-ui/primitive";
@@ -2346,7 +2552,7 @@ import { Primitive as Primitive11 } from "@radix-ui/react-primitive";
2346
2552
  import { Slot as Slot11 } from "@radix-ui/react-slot";
2347
2553
  import { useControllableState as useControllableState2 } from "@radix-ui/react-use-controllable-state";
2348
2554
  import { hideOthers } from "aria-hidden";
2349
- import React26, { forwardRef as forwardRef18, useCallback as useCallback8, useEffect as useEffect4, useMemo as useMemo6, useRef as useRef4, useState as useState7 } from "react";
2555
+ import React27, { forwardRef as forwardRef19, useCallback as useCallback10, useEffect as useEffect4, useMemo as useMemo6, useRef as useRef7, useState as useState7 } from "react";
2350
2556
  import { RemoveScroll } from "react-remove-scroll";
2351
2557
  var POPOVER_NAME = "Popover";
2352
2558
  var [createPopoverContext, createPopoverScope] = createContextScope2(POPOVER_NAME, [
@@ -2357,31 +2563,31 @@ var [PopoverProvider, usePopoverContext] = createPopoverContext(POPOVER_NAME);
2357
2563
  var PopoverRoot = (props) => {
2358
2564
  const { __scopePopover, children, open: openProp, defaultOpen, onOpenChange, modal = false } = props;
2359
2565
  const popperScope = usePopperScope(__scopePopover);
2360
- const triggerRef = useRef4(null);
2566
+ const triggerRef = useRef7(null);
2361
2567
  const [hasCustomAnchor, setHasCustomAnchor] = useState7(false);
2362
2568
  const [open = false, setOpen] = useControllableState2({
2363
2569
  prop: openProp,
2364
2570
  defaultProp: defaultOpen,
2365
2571
  onChange: onOpenChange
2366
2572
  });
2367
- return /* @__PURE__ */ React26.createElement(PopperPrimitive.Root, popperScope, /* @__PURE__ */ React26.createElement(PopoverProvider, {
2573
+ return /* @__PURE__ */ React27.createElement(PopperPrimitive.Root, popperScope, /* @__PURE__ */ React27.createElement(PopoverProvider, {
2368
2574
  scope: __scopePopover,
2369
2575
  contentId: useId4(),
2370
2576
  triggerRef,
2371
2577
  open,
2372
2578
  onOpenChange: setOpen,
2373
- onOpenToggle: useCallback8(() => setOpen((prevOpen) => !prevOpen), [
2579
+ onOpenToggle: useCallback10(() => setOpen((prevOpen) => !prevOpen), [
2374
2580
  setOpen
2375
2581
  ]),
2376
2582
  hasCustomAnchor,
2377
- onCustomAnchorAdd: useCallback8(() => setHasCustomAnchor(true), []),
2378
- onCustomAnchorRemove: useCallback8(() => setHasCustomAnchor(false), []),
2583
+ onCustomAnchorAdd: useCallback10(() => setHasCustomAnchor(true), []),
2584
+ onCustomAnchorRemove: useCallback10(() => setHasCustomAnchor(false), []),
2379
2585
  modal
2380
2586
  }, children));
2381
2587
  };
2382
2588
  PopoverRoot.displayName = POPOVER_NAME;
2383
2589
  var ANCHOR_NAME = "Popover.Anchor";
2384
- var PopoverAnchor = /* @__PURE__ */ forwardRef18((props, forwardedRef) => {
2590
+ var PopoverAnchor = /* @__PURE__ */ forwardRef19((props, forwardedRef) => {
2385
2591
  const { __scopePopover, ...anchorProps } = props;
2386
2592
  const context = usePopoverContext(ANCHOR_NAME, __scopePopover);
2387
2593
  const popperScope = usePopperScope(__scopePopover);
@@ -2393,7 +2599,7 @@ var PopoverAnchor = /* @__PURE__ */ forwardRef18((props, forwardedRef) => {
2393
2599
  onCustomAnchorAdd,
2394
2600
  onCustomAnchorRemove
2395
2601
  ]);
2396
- return /* @__PURE__ */ React26.createElement(PopperPrimitive.Anchor, {
2602
+ return /* @__PURE__ */ React27.createElement(PopperPrimitive.Anchor, {
2397
2603
  ...popperScope,
2398
2604
  ...anchorProps,
2399
2605
  ref: forwardedRef
@@ -2401,13 +2607,13 @@ var PopoverAnchor = /* @__PURE__ */ forwardRef18((props, forwardedRef) => {
2401
2607
  });
2402
2608
  PopoverAnchor.displayName = ANCHOR_NAME;
2403
2609
  var TRIGGER_NAME2 = "Popover.Trigger";
2404
- var PopoverTrigger = /* @__PURE__ */ forwardRef18((props, forwardedRef) => {
2610
+ var PopoverTrigger = /* @__PURE__ */ forwardRef19((props, forwardedRef) => {
2405
2611
  const { __scopePopover, asChild, ...triggerProps } = props;
2406
2612
  const context = usePopoverContext(TRIGGER_NAME2, __scopePopover);
2407
2613
  const popperScope = usePopperScope(__scopePopover);
2408
2614
  const composedTriggerRef = useComposedRefs2(forwardedRef, context.triggerRef);
2409
2615
  const Comp = asChild ? Slot11 : Primitive11.button;
2410
- const trigger = /* @__PURE__ */ React26.createElement(Comp, {
2616
+ const trigger = /* @__PURE__ */ React27.createElement(Comp, {
2411
2617
  type: "button",
2412
2618
  "aria-haspopup": "dialog",
2413
2619
  "aria-expanded": context.open,
@@ -2417,7 +2623,7 @@ var PopoverTrigger = /* @__PURE__ */ forwardRef18((props, forwardedRef) => {
2417
2623
  ref: composedTriggerRef,
2418
2624
  onClick: composeEventHandlers2(props.onClick, context.onOpenToggle)
2419
2625
  });
2420
- return context.hasCustomAnchor ? trigger : /* @__PURE__ */ React26.createElement(PopperPrimitive.Anchor, {
2626
+ return context.hasCustomAnchor ? trigger : /* @__PURE__ */ React27.createElement(PopperPrimitive.Anchor, {
2421
2627
  asChild: true,
2422
2628
  ...popperScope
2423
2629
  }, trigger);
@@ -2433,7 +2639,7 @@ var PopoverVirtualTrigger = (props) => {
2433
2639
  context.triggerRef.current = virtualRef.current;
2434
2640
  }
2435
2641
  });
2436
- return /* @__PURE__ */ React26.createElement(PopperPrimitive.Anchor, {
2642
+ return /* @__PURE__ */ React27.createElement(PopperPrimitive.Anchor, {
2437
2643
  ...popperScope,
2438
2644
  virtualRef
2439
2645
  });
@@ -2446,48 +2652,48 @@ var [PortalProvider, usePortalContext] = createPopoverContext(PORTAL_NAME2, {
2446
2652
  var PopoverPortal = (props) => {
2447
2653
  const { __scopePopover, forceMount, children, container } = props;
2448
2654
  const context = usePopoverContext(PORTAL_NAME2, __scopePopover);
2449
- return /* @__PURE__ */ React26.createElement(PortalProvider, {
2655
+ return /* @__PURE__ */ React27.createElement(PortalProvider, {
2450
2656
  scope: __scopePopover,
2451
2657
  forceMount
2452
- }, /* @__PURE__ */ React26.createElement(Presence, {
2658
+ }, /* @__PURE__ */ React27.createElement(Presence, {
2453
2659
  present: forceMount || context.open
2454
- }, /* @__PURE__ */ React26.createElement(PortalPrimitive, {
2660
+ }, /* @__PURE__ */ React27.createElement(PortalPrimitive, {
2455
2661
  asChild: true,
2456
2662
  container
2457
2663
  }, children)));
2458
2664
  };
2459
2665
  PopoverPortal.displayName = PORTAL_NAME2;
2460
2666
  var CONTENT_NAME2 = "Popover.Content";
2461
- var PopoverContent = /* @__PURE__ */ forwardRef18((props, forwardedRef) => {
2667
+ var PopoverContent = /* @__PURE__ */ forwardRef19((props, forwardedRef) => {
2462
2668
  const portalContext = usePortalContext(CONTENT_NAME2, props.__scopePopover);
2463
2669
  const { forceMount = portalContext.forceMount, ...contentProps } = props;
2464
2670
  const context = usePopoverContext(CONTENT_NAME2, props.__scopePopover);
2465
- return /* @__PURE__ */ React26.createElement(Presence, {
2671
+ return /* @__PURE__ */ React27.createElement(Presence, {
2466
2672
  present: forceMount || context.open
2467
- }, context.modal ? /* @__PURE__ */ React26.createElement(PopoverContentModal, {
2673
+ }, context.modal ? /* @__PURE__ */ React27.createElement(PopoverContentModal, {
2468
2674
  ...contentProps,
2469
2675
  ref: forwardedRef
2470
- }) : /* @__PURE__ */ React26.createElement(PopoverContentNonModal, {
2676
+ }) : /* @__PURE__ */ React27.createElement(PopoverContentNonModal, {
2471
2677
  ...contentProps,
2472
2678
  ref: forwardedRef
2473
2679
  }));
2474
2680
  });
2475
2681
  PopoverContent.displayName = CONTENT_NAME2;
2476
- var PopoverContentModal = /* @__PURE__ */ forwardRef18((props, forwardedRef) => {
2682
+ var PopoverContentModal = /* @__PURE__ */ forwardRef19((props, forwardedRef) => {
2477
2683
  const context = usePopoverContext(CONTENT_NAME2, props.__scopePopover);
2478
- const contentRef = useRef4(null);
2684
+ const contentRef = useRef7(null);
2479
2685
  const composedRefs = useComposedRefs2(forwardedRef, contentRef);
2480
- const isRightClickOutsideRef = useRef4(false);
2686
+ const isRightClickOutsideRef = useRef7(false);
2481
2687
  useEffect4(() => {
2482
2688
  const content = contentRef.current;
2483
2689
  if (content) {
2484
2690
  return hideOthers(content);
2485
2691
  }
2486
2692
  }, []);
2487
- return /* @__PURE__ */ React26.createElement(RemoveScroll, {
2693
+ return /* @__PURE__ */ React27.createElement(RemoveScroll, {
2488
2694
  as: Slot11,
2489
2695
  allowPinchZoom: true
2490
- }, /* @__PURE__ */ React26.createElement(PopoverContentImpl, {
2696
+ }, /* @__PURE__ */ React27.createElement(PopoverContentImpl, {
2491
2697
  ...props,
2492
2698
  ref: composedRefs,
2493
2699
  // Make sure we're not trapping once it's been closed (closed !== unmounted when animating out).
@@ -2514,11 +2720,11 @@ var PopoverContentModal = /* @__PURE__ */ forwardRef18((props, forwardedRef) =>
2514
2720
  })
2515
2721
  }));
2516
2722
  });
2517
- var PopoverContentNonModal = /* @__PURE__ */ forwardRef18((props, forwardedRef) => {
2723
+ var PopoverContentNonModal = /* @__PURE__ */ forwardRef19((props, forwardedRef) => {
2518
2724
  const context = usePopoverContext(CONTENT_NAME2, props.__scopePopover);
2519
- const hasInteractedOutsideRef = useRef4(false);
2520
- const hasPointerDownOutsideRef = useRef4(false);
2521
- return /* @__PURE__ */ React26.createElement(PopoverContentImpl, {
2725
+ const hasInteractedOutsideRef = useRef7(false);
2726
+ const hasPointerDownOutsideRef = useRef7(false);
2727
+ return /* @__PURE__ */ React27.createElement(PopoverContentImpl, {
2522
2728
  ...props,
2523
2729
  ref: forwardedRef,
2524
2730
  trapFocus: false,
@@ -2553,7 +2759,7 @@ var PopoverContentNonModal = /* @__PURE__ */ forwardRef18((props, forwardedRef)
2553
2759
  }
2554
2760
  });
2555
2761
  });
2556
- var PopoverContentImpl = /* @__PURE__ */ forwardRef18((props, forwardedRef) => {
2762
+ var PopoverContentImpl = /* @__PURE__ */ forwardRef19((props, forwardedRef) => {
2557
2763
  const { __scopePopover, trapFocus, onOpenAutoFocus, onCloseAutoFocus, disableOutsidePointerEvents, onEscapeKeyDown, onPointerDownOutside, onFocusOutside, onInteractOutside, collisionPadding = 8, collisionBoundary, classNames, ...contentProps } = props;
2558
2764
  const context = usePopoverContext(CONTENT_NAME2, __scopePopover);
2559
2765
  const popperScope = usePopperScope(__scopePopover);
@@ -2577,13 +2783,13 @@ var PopoverContentImpl = /* @__PURE__ */ forwardRef18((props, forwardedRef) => {
2577
2783
  collisionBoundary,
2578
2784
  context.triggerRef.current
2579
2785
  ]);
2580
- return /* @__PURE__ */ React26.createElement(FocusScope, {
2786
+ return /* @__PURE__ */ React27.createElement(FocusScope, {
2581
2787
  asChild: true,
2582
2788
  loop: true,
2583
2789
  trapped: trapFocus,
2584
2790
  onMountAutoFocus: onOpenAutoFocus,
2585
2791
  onUnmountAutoFocus: onCloseAutoFocus
2586
- }, /* @__PURE__ */ React26.createElement(DismissableLayer, {
2792
+ }, /* @__PURE__ */ React27.createElement(DismissableLayer, {
2587
2793
  asChild: true,
2588
2794
  disableOutsidePointerEvents,
2589
2795
  onInteractOutside,
@@ -2591,7 +2797,7 @@ var PopoverContentImpl = /* @__PURE__ */ forwardRef18((props, forwardedRef) => {
2591
2797
  onPointerDownOutside,
2592
2798
  onFocusOutside,
2593
2799
  onDismiss: () => context.onOpenChange(false)
2594
- }, /* @__PURE__ */ React26.createElement(PopperPrimitive.Content, {
2800
+ }, /* @__PURE__ */ React27.createElement(PopperPrimitive.Content, {
2595
2801
  "data-state": getState(context.open),
2596
2802
  role: "dialog",
2597
2803
  id: context.contentId,
@@ -2617,10 +2823,10 @@ var PopoverContentImpl = /* @__PURE__ */ forwardRef18((props, forwardedRef) => {
2617
2823
  })));
2618
2824
  });
2619
2825
  var CLOSE_NAME = "Popover.Close";
2620
- var PopoverClose = /* @__PURE__ */ forwardRef18((props, forwardedRef) => {
2826
+ var PopoverClose = /* @__PURE__ */ forwardRef19((props, forwardedRef) => {
2621
2827
  const { __scopePopover, ...closeProps } = props;
2622
2828
  const context = usePopoverContext(CLOSE_NAME, __scopePopover);
2623
- return /* @__PURE__ */ React26.createElement(Primitive11.button, {
2829
+ return /* @__PURE__ */ React27.createElement(Primitive11.button, {
2624
2830
  type: "button",
2625
2831
  ...closeProps,
2626
2832
  ref: forwardedRef,
@@ -2629,11 +2835,11 @@ var PopoverClose = /* @__PURE__ */ forwardRef18((props, forwardedRef) => {
2629
2835
  });
2630
2836
  PopoverClose.displayName = CLOSE_NAME;
2631
2837
  var ARROW_NAME2 = "Popover.Arrow";
2632
- var PopoverArrow = /* @__PURE__ */ forwardRef18((props, forwardedRef) => {
2838
+ var PopoverArrow = /* @__PURE__ */ forwardRef19((props, forwardedRef) => {
2633
2839
  const { __scopePopover, classNames, ...arrowProps } = props;
2634
2840
  const popperScope = usePopperScope(__scopePopover);
2635
2841
  const { tx } = useThemeContext();
2636
- return /* @__PURE__ */ React26.createElement(PopperPrimitive.Arrow, {
2842
+ return /* @__PURE__ */ React27.createElement(PopperPrimitive.Arrow, {
2637
2843
  ...popperScope,
2638
2844
  ...arrowProps,
2639
2845
  className: tx("popover.arrow", {}, classNames),
@@ -2641,10 +2847,10 @@ var PopoverArrow = /* @__PURE__ */ forwardRef18((props, forwardedRef) => {
2641
2847
  });
2642
2848
  });
2643
2849
  PopoverArrow.displayName = ARROW_NAME2;
2644
- var PopoverViewport = /* @__PURE__ */ forwardRef18(({ classNames, asChild, constrainInline = true, constrainBlock = true, children, ...props }, forwardedRef) => {
2850
+ var PopoverViewport = /* @__PURE__ */ forwardRef19(({ classNames, asChild, constrainInline = true, constrainBlock = true, children, ...props }, forwardedRef) => {
2645
2851
  const { tx } = useThemeContext();
2646
2852
  const Comp = asChild ? Slot11 : Primitive11.div;
2647
- return /* @__PURE__ */ React26.createElement(Comp, {
2853
+ return /* @__PURE__ */ React27.createElement(Comp, {
2648
2854
  ...props,
2649
2855
  className: tx("popover.viewport", {
2650
2856
  constrainInline,
@@ -2673,7 +2879,7 @@ var DatePickerRoot = ({ mode = "single", value, defaultValue, onValueChange, wit
2673
2879
  const [internalOpen, setInternalOpen] = useState8(defaultOpen ?? false);
2674
2880
  const controlled = value !== void 0 || onValueChange !== void 0;
2675
2881
  const resolvedValue = controlled ? value : internalValue;
2676
- const setValue = useCallback9((next) => {
2882
+ const setValue = useCallback11((next) => {
2677
2883
  if (!controlled) {
2678
2884
  setInternalValue(next);
2679
2885
  }
@@ -2683,7 +2889,7 @@ var DatePickerRoot = ({ mode = "single", value, defaultValue, onValueChange, wit
2683
2889
  onValueChange
2684
2890
  ]);
2685
2891
  const resolvedOpen = open ?? internalOpen;
2686
- const handleOpenChange = useCallback9((next) => {
2892
+ const handleOpenChange = useCallback11((next) => {
2687
2893
  if (open === void 0) {
2688
2894
  setInternalOpen(next);
2689
2895
  }
@@ -2692,14 +2898,14 @@ var DatePickerRoot = ({ mode = "single", value, defaultValue, onValueChange, wit
2692
2898
  open,
2693
2899
  onOpenChange
2694
2900
  ]);
2695
- return /* @__PURE__ */ React27.createElement(DatePickerProvider, {
2901
+ return /* @__PURE__ */ React28.createElement(DatePickerProvider, {
2696
2902
  mode,
2697
2903
  value: resolvedValue,
2698
2904
  setValue,
2699
2905
  withTime,
2700
2906
  open: resolvedOpen,
2701
2907
  onOpenChange: handleOpenChange
2702
- }, /* @__PURE__ */ React27.createElement(Popover.Root, {
2908
+ }, /* @__PURE__ */ React28.createElement(Popover.Root, {
2703
2909
  open: resolvedOpen,
2704
2910
  onOpenChange: handleOpenChange
2705
2911
  }, children));
@@ -2720,36 +2926,36 @@ var formatValue = (mode, value, fmt) => {
2720
2926
  }
2721
2927
  }
2722
2928
  };
2723
- var DatePickerTrigger = /* @__PURE__ */ forwardRef19(({ classNames, format: fmt = "PPP", placeholder, icon = true, children, ...props }, forwardedRef) => {
2929
+ var DatePickerTrigger = /* @__PURE__ */ forwardRef20(({ classNames, format: fmt = "PPP", placeholder, icon = true, children, ...props }, forwardedRef) => {
2724
2930
  const { tx } = useThemeContext();
2725
2931
  const { t } = useTranslation(translationKey);
2726
2932
  const { mode, value } = useDatePickerContext("DatePickerTrigger");
2727
2933
  const placeholderText = placeholder ?? t(`date-picker.placeholder.${mode}.label`);
2728
2934
  const label = formatValue(mode, value, fmt) ?? placeholderText;
2729
2935
  const hasValue = label !== placeholderText;
2730
- return /* @__PURE__ */ React27.createElement(Popover.Trigger, {
2936
+ return /* @__PURE__ */ React28.createElement(Popover.Trigger, {
2731
2937
  asChild: true
2732
- }, /* @__PURE__ */ React27.createElement("button", {
2938
+ }, /* @__PURE__ */ React28.createElement("button", {
2733
2939
  ref: forwardedRef,
2734
2940
  type: "button",
2735
2941
  ...props,
2736
2942
  className: tx("datePicker.trigger", {
2737
2943
  hasValue
2738
2944
  }, classNames) ?? void 0
2739
- }, children ?? /* @__PURE__ */ React27.createElement(React27.Fragment, null, icon && /* @__PURE__ */ React27.createElement(Icon, {
2945
+ }, children ?? /* @__PURE__ */ React28.createElement(React28.Fragment, null, icon && /* @__PURE__ */ React28.createElement(Icon, {
2740
2946
  size: 4,
2741
2947
  icon: "ph--calendar--regular"
2742
2948
  }), label)));
2743
2949
  });
2744
2950
  DatePickerTrigger.displayName = "DatePickerTrigger";
2745
- var DatePickerContent = /* @__PURE__ */ forwardRef19(({ classNames, children, ...props }, forwardedRef) => {
2951
+ var DatePickerContent = /* @__PURE__ */ forwardRef20(({ classNames, children, ...props }, forwardedRef) => {
2746
2952
  const { tx } = useThemeContext();
2747
- return /* @__PURE__ */ React27.createElement(Popover.Portal, null, /* @__PURE__ */ React27.createElement(Popover.Content, {
2953
+ return /* @__PURE__ */ React28.createElement(Popover.Portal, null, /* @__PURE__ */ React28.createElement(Popover.Content, {
2748
2954
  ref: forwardedRef,
2749
2955
  align: "start",
2750
2956
  sideOffset: 4,
2751
2957
  ...props
2752
- }, /* @__PURE__ */ React27.createElement("div", {
2958
+ }, /* @__PURE__ */ React28.createElement("div", {
2753
2959
  className: tx("datePicker.content", {}, classNames)
2754
2960
  }, children)));
2755
2961
  });
@@ -2769,7 +2975,7 @@ var DatePickerCalendar = ({ classNames } = {}) => {
2769
2975
  const { mode, value, setValue, withTime, onOpenChange } = useDatePickerContext("DatePickerCalendar");
2770
2976
  if (mode === "single") {
2771
2977
  const date = value;
2772
- return /* @__PURE__ */ React27.createElement(Calendar.Root, {
2978
+ return /* @__PURE__ */ React28.createElement(Calendar.Root, {
2773
2979
  mode: "single",
2774
2980
  classNames,
2775
2981
  selected: date,
@@ -2783,7 +2989,7 @@ var DatePickerCalendar = ({ classNames } = {}) => {
2783
2989
  });
2784
2990
  }
2785
2991
  const range = value;
2786
- return /* @__PURE__ */ React27.createElement(Calendar.Root, {
2992
+ return /* @__PURE__ */ React28.createElement(Calendar.Root, {
2787
2993
  mode: "range",
2788
2994
  classNames,
2789
2995
  selected: range,
@@ -2816,12 +3022,12 @@ import { createContext as createContext6 } from "@radix-ui/react-context";
2816
3022
  import * as DialogPrimitive from "@radix-ui/react-dialog";
2817
3023
  import { Primitive as Primitive12 } from "@radix-ui/react-primitive";
2818
3024
  import { Slot as Slot12 } from "@radix-ui/react-slot";
2819
- import React28, { forwardRef as forwardRef20 } from "react";
3025
+ import React29, { forwardRef as forwardRef21 } from "react";
2820
3026
  import { useTranslation as useTranslation4 } from "react-i18next";
2821
3027
  import { osTranslations as osTranslations2 } from "@dxos/ui-theme";
2822
- var DialogRoot = (props) => /* @__PURE__ */ React28.createElement(ElevationProvider, {
3028
+ var DialogRoot = (props) => /* @__PURE__ */ React29.createElement(ElevationProvider, {
2823
3029
  elevation: "dialog"
2824
- }, /* @__PURE__ */ React28.createElement(DialogPrimitive.Root, {
3030
+ }, /* @__PURE__ */ React29.createElement(DialogPrimitive.Root, {
2825
3031
  // NOTE: Radix warning unless set to undefined.
2826
3032
  // https://www.radix-ui.com/primitives/docs/components/dialog#description
2827
3033
  "aria-describedby": void 0,
@@ -2832,23 +3038,23 @@ var DialogTrigger = DialogPrimitive.Trigger;
2832
3038
  var DialogPortal = DialogPrimitive.Portal;
2833
3039
  var DIALOG_OVERLAY_NAME = "Dialog.Overlay";
2834
3040
  var [OverlayLayoutProvider, useOverlayLayoutContext] = createContext6(DIALOG_OVERLAY_NAME, {});
2835
- var DialogOverlay = /* @__PURE__ */ forwardRef20(({ classNames, children, blockAlign, ...props }, forwardedRef) => {
3041
+ var DialogOverlay = /* @__PURE__ */ forwardRef21(({ classNames, children, blockAlign, ...props }, forwardedRef) => {
2836
3042
  const { tx } = useThemeContext();
2837
- return /* @__PURE__ */ React28.createElement(DialogPrimitive.Overlay, {
3043
+ return /* @__PURE__ */ React29.createElement(DialogPrimitive.Overlay, {
2838
3044
  ...props,
2839
3045
  "data-block-align": blockAlign,
2840
3046
  className: tx("dialog.overlay", {}, classNames),
2841
3047
  ref: forwardedRef
2842
- }, /* @__PURE__ */ React28.createElement(OverlayLayoutProvider, {
3048
+ }, /* @__PURE__ */ React29.createElement(OverlayLayoutProvider, {
2843
3049
  inOverlayLayout: true
2844
3050
  }, children));
2845
3051
  });
2846
3052
  DialogOverlay.displayName = DIALOG_OVERLAY_NAME;
2847
3053
  var DIALOG_CONTENT_NAME = "Dialog.Content";
2848
- var DialogContent = /* @__PURE__ */ forwardRef20(({ classNames, children, size = "md", inOverlayLayout: propsInOverlayLayout, ...props }, forwardedRef) => {
3054
+ var DialogContent = /* @__PURE__ */ forwardRef21(({ classNames, children, size = "sm", inOverlayLayout: propsInOverlayLayout, ...props }, forwardedRef) => {
2849
3055
  const { tx } = useThemeContext();
2850
3056
  const { inOverlayLayout } = useOverlayLayoutContext(DIALOG_CONTENT_NAME);
2851
- return /* @__PURE__ */ React28.createElement(DialogPrimitive.Content, {
3057
+ return /* @__PURE__ */ React29.createElement(DialogPrimitive.Content, {
2852
3058
  ...props,
2853
3059
  // NOTE: Radix warning unless set to undefined.
2854
3060
  // https://www.radix-ui.com/primitives/docs/components/dialog#description
@@ -2858,9 +3064,9 @@ var DialogContent = /* @__PURE__ */ forwardRef20(({ classNames, children, size =
2858
3064
  inOverlayLayout: propsInOverlayLayout || inOverlayLayout
2859
3065
  }, classNames),
2860
3066
  ref: forwardedRef
2861
- }, /* @__PURE__ */ React28.createElement(Column.Root, {
3067
+ }, /* @__PURE__ */ React29.createElement(Column.Root, {
2862
3068
  classNames: "dx-expander",
2863
- gutter: "sm"
3069
+ gutter: "lg"
2864
3070
  }, children));
2865
3071
  });
2866
3072
  DialogContent.displayName = DIALOG_CONTENT_NAME;
@@ -2868,7 +3074,7 @@ var DialogHeader = slottable(({ children, asChild, ...props }, forwardedRef) =>
2868
3074
  const { className, ...rest } = composableProps(props);
2869
3075
  const Comp = asChild ? Slot12 : Primitive12.div;
2870
3076
  const { tx } = useThemeContext();
2871
- return /* @__PURE__ */ React28.createElement(Comp, {
3077
+ return /* @__PURE__ */ React29.createElement(Comp, {
2872
3078
  ...rest,
2873
3079
  className: tx("dialog.header", {}, className),
2874
3080
  ref: forwardedRef
@@ -2884,9 +3090,9 @@ var DIALOG_ACTION_LABEL_KEYS = {
2884
3090
  close: "close-dialog.label",
2885
3091
  delete: "toolbar-delete.label"
2886
3092
  };
2887
- var DialogActionIconButton = /* @__PURE__ */ forwardRef20(({ action, label, ...props }, forwardedRef) => {
3093
+ var DialogActionIconButton = /* @__PURE__ */ forwardRef21(({ action, label, ...props }, forwardedRef) => {
2888
3094
  const { t } = useTranslation4(osTranslations2);
2889
- return /* @__PURE__ */ React28.createElement(IconButton, {
3095
+ return /* @__PURE__ */ React29.createElement(IconButton, {
2890
3096
  ...props,
2891
3097
  label: label ?? t(DIALOG_ACTION_LABEL_KEYS[action]),
2892
3098
  icon: DIALOG_ACTION_ICONS[action],
@@ -2901,16 +3107,16 @@ var DialogBody = slottable(({ children, asChild, ...props }, forwardedRef) => {
2901
3107
  const { className, ...rest } = composableProps(props);
2902
3108
  const Comp = asChild ? Slot12 : Primitive12.div;
2903
3109
  const { tx } = useThemeContext();
2904
- return /* @__PURE__ */ React28.createElement(Comp, {
3110
+ return /* @__PURE__ */ React29.createElement(Comp, {
2905
3111
  ...rest,
2906
3112
  className: tx("dialog.body", {}, className),
2907
3113
  ref: forwardedRef
2908
3114
  }, children);
2909
3115
  });
2910
3116
  DialogBody.displayName = "Dialog.Body";
2911
- var DialogTitle = /* @__PURE__ */ forwardRef20(({ classNames, srOnly, ...props }, forwardedRef) => {
3117
+ var DialogTitle = /* @__PURE__ */ forwardRef21(({ classNames, srOnly, ...props }, forwardedRef) => {
2912
3118
  const { tx } = useThemeContext();
2913
- return /* @__PURE__ */ React28.createElement(DialogPrimitive.Title, {
3119
+ return /* @__PURE__ */ React29.createElement(DialogPrimitive.Title, {
2914
3120
  ...props,
2915
3121
  className: tx("dialog.title", {
2916
3122
  srOnly
@@ -2919,9 +3125,9 @@ var DialogTitle = /* @__PURE__ */ forwardRef20(({ classNames, srOnly, ...props }
2919
3125
  });
2920
3126
  });
2921
3127
  DialogTitle.displayName = "Dialog.Title";
2922
- var DialogDescription = /* @__PURE__ */ forwardRef20(({ classNames, srOnly, ...props }, forwardedRef) => {
3128
+ var DialogDescription = /* @__PURE__ */ forwardRef21(({ classNames, srOnly, ...props }, forwardedRef) => {
2923
3129
  const { tx } = useThemeContext();
2924
- return /* @__PURE__ */ React28.createElement(DialogPrimitive.Description, {
3130
+ return /* @__PURE__ */ React29.createElement(DialogPrimitive.Description, {
2925
3131
  ...props,
2926
3132
  className: tx("dialog.description", {
2927
3133
  srOnly
@@ -2934,7 +3140,7 @@ var DialogActionBar = slottable(({ children, asChild, ...props }, forwardedRef)
2934
3140
  const { className: classNames, ...rest } = composableProps(props);
2935
3141
  const Comp = asChild ? Slot12 : Primitive12.div;
2936
3142
  const { tx } = useThemeContext();
2937
- return /* @__PURE__ */ React28.createElement(Comp, {
3143
+ return /* @__PURE__ */ React29.createElement(Comp, {
2938
3144
  ...rest,
2939
3145
  className: tx("dialog.actionbar", {}, classNames),
2940
3146
  ref: forwardedRef
@@ -2960,10 +3166,10 @@ var Dialog = {
2960
3166
  // src/components/Dialog/AlertDialog.tsx
2961
3167
  import * as AlertDialogPrimitive from "@radix-ui/react-alert-dialog";
2962
3168
  import { createContext as createContext7 } from "@radix-ui/react-context";
2963
- import React29, { forwardRef as forwardRef21 } from "react";
2964
- var AlertDialogRoot = (props) => /* @__PURE__ */ React29.createElement(ElevationProvider, {
3169
+ import React30, { forwardRef as forwardRef22 } from "react";
3170
+ var AlertDialogRoot = (props) => /* @__PURE__ */ React30.createElement(ElevationProvider, {
2965
3171
  elevation: "dialog"
2966
- }, /* @__PURE__ */ React29.createElement(AlertDialogPrimitive.Root, props));
3172
+ }, /* @__PURE__ */ React30.createElement(AlertDialogPrimitive.Root, props));
2967
3173
  var AlertDialogTrigger = AlertDialogPrimitive.Trigger;
2968
3174
  var AlertDialogPortal = AlertDialogPrimitive.Portal;
2969
3175
  var AlertDialogCancel = AlertDialogPrimitive.Cancel;
@@ -2973,37 +3179,37 @@ var ALERT_DIALOG_CONTENT_NAME = "AlertDialog.Content";
2973
3179
  var [OverlayLayoutProvider2, useOverlayLayoutContext2] = createContext7(ALERT_DIALOG_OVERLAY_NAME, {
2974
3180
  inOverlayLayout: false
2975
3181
  });
2976
- var AlertDialogOverlay = /* @__PURE__ */ forwardRef21(({ classNames, children, blockAlign, ...props }, forwardedRef) => {
3182
+ var AlertDialogOverlay = /* @__PURE__ */ forwardRef22(({ classNames, children, blockAlign, ...props }, forwardedRef) => {
2977
3183
  const { tx } = useThemeContext();
2978
- return /* @__PURE__ */ React29.createElement(AlertDialogPrimitive.Overlay, {
3184
+ return /* @__PURE__ */ React30.createElement(AlertDialogPrimitive.Overlay, {
2979
3185
  ...props,
2980
3186
  "data-block-align": blockAlign,
2981
3187
  className: tx("dialog.overlay", {}, classNames),
2982
3188
  ref: forwardedRef
2983
- }, /* @__PURE__ */ React29.createElement(OverlayLayoutProvider2, {
3189
+ }, /* @__PURE__ */ React30.createElement(OverlayLayoutProvider2, {
2984
3190
  inOverlayLayout: true
2985
3191
  }, children));
2986
3192
  });
2987
3193
  AlertDialogOverlay.displayName = ALERT_DIALOG_OVERLAY_NAME;
2988
- var AlertDialogContent = /* @__PURE__ */ forwardRef21(({ classNames, children, size = "md", ...props }, forwardedRef) => {
3194
+ var AlertDialogContent = /* @__PURE__ */ forwardRef22(({ classNames, children, size = "md", ...props }, forwardedRef) => {
2989
3195
  const { tx } = useThemeContext();
2990
3196
  const { inOverlayLayout } = useOverlayLayoutContext2(ALERT_DIALOG_CONTENT_NAME);
2991
- return /* @__PURE__ */ React29.createElement(AlertDialogPrimitive.Content, {
3197
+ return /* @__PURE__ */ React30.createElement(AlertDialogPrimitive.Content, {
2992
3198
  ...props,
2993
3199
  className: tx("dialog.content", {
2994
3200
  inOverlayLayout,
2995
3201
  size
2996
3202
  }, classNames),
2997
3203
  ref: forwardedRef
2998
- }, /* @__PURE__ */ React29.createElement(Column.Root, {
3204
+ }, /* @__PURE__ */ React30.createElement(Column.Root, {
2999
3205
  classNames: "dx-expander",
3000
- gutter: "sm"
3206
+ gutter: "lg"
3001
3207
  }, children));
3002
3208
  });
3003
3209
  AlertDialogContent.displayName = ALERT_DIALOG_CONTENT_NAME;
3004
- var AlertDialogTitle = /* @__PURE__ */ forwardRef21(({ classNames, srOnly, ...props }, forwardedRef) => {
3210
+ var AlertDialogTitle = /* @__PURE__ */ forwardRef22(({ classNames, srOnly, ...props }, forwardedRef) => {
3005
3211
  const { tx } = useThemeContext();
3006
- return /* @__PURE__ */ React29.createElement(AlertDialogPrimitive.Title, {
3212
+ return /* @__PURE__ */ React30.createElement(AlertDialogPrimitive.Title, {
3007
3213
  ...props,
3008
3214
  className: tx("dialog.title", {
3009
3215
  srOnly
@@ -3011,9 +3217,9 @@ var AlertDialogTitle = /* @__PURE__ */ forwardRef21(({ classNames, srOnly, ...pr
3011
3217
  ref: forwardedRef
3012
3218
  });
3013
3219
  });
3014
- var AlertDialogDescription = /* @__PURE__ */ forwardRef21(({ classNames, srOnly, ...props }, forwardedRef) => {
3220
+ var AlertDialogDescription = /* @__PURE__ */ forwardRef22(({ classNames, srOnly, ...props }, forwardedRef) => {
3015
3221
  const { tx } = useThemeContext();
3016
- return /* @__PURE__ */ React29.createElement(AlertDialogPrimitive.Description, {
3222
+ return /* @__PURE__ */ React30.createElement(AlertDialogPrimitive.Description, {
3017
3223
  ...props,
3018
3224
  className: tx("dialog.description", {
3019
3225
  srOnly
@@ -3043,40 +3249,40 @@ var AlertDialog = {
3043
3249
  import { ErrorBoundary } from "@dxos/react-error-boundary";
3044
3250
 
3045
3251
  // src/components/ErrorFallback/ErrorFallback.tsx
3046
- import React30 from "react";
3252
+ import React31 from "react";
3047
3253
  import { safeStringify } from "@dxos/util";
3048
3254
  import { translationKey as translationKey4 } from "#translations";
3049
3255
  var ErrorFallback = ({ children, error, title, data }) => {
3050
3256
  const { t } = useTranslation(translationKey4);
3051
3257
  const isDev = true;
3052
3258
  const message = error instanceof Error ? error.message : String(error);
3053
- return /* @__PURE__ */ React30.createElement("div", {
3259
+ return /* @__PURE__ */ React31.createElement("div", {
3054
3260
  role: "alert",
3055
3261
  "data-testid": "error-boundary-fallback",
3056
3262
  className: "flex flex-col p-4 gap-4 overflow-auto"
3057
- }, /* @__PURE__ */ React30.createElement("h1", {
3263
+ }, /* @__PURE__ */ React31.createElement("h1", {
3058
3264
  className: "text-lg text-info-text"
3059
- }, title ?? "Runtime Error"), /* @__PURE__ */ React30.createElement("p", null, message), isDev && error instanceof Error && /* @__PURE__ */ React30.createElement(Section, {
3265
+ }, title ?? "Runtime Error"), /* @__PURE__ */ React31.createElement("p", null, message), isDev && error instanceof Error && /* @__PURE__ */ React31.createElement(Section, {
3060
3266
  title: "Stack",
3061
3267
  onClick: () => {
3062
3268
  const text = error instanceof Error ? error.stack ?? error.message : String(error);
3063
3269
  void navigator.clipboard.writeText(text);
3064
3270
  }
3065
- }, /* @__PURE__ */ React30.createElement(ErrorStack, {
3271
+ }, /* @__PURE__ */ React31.createElement(ErrorStack, {
3066
3272
  error
3067
- })), data && /* @__PURE__ */ React30.createElement(Section, {
3273
+ })), data && /* @__PURE__ */ React31.createElement(Section, {
3068
3274
  title: "Data",
3069
3275
  onClick: () => {
3070
3276
  void navigator.clipboard.writeText(JSON.stringify(data, void 0, 2));
3071
3277
  }
3072
- }, /* @__PURE__ */ React30.createElement("pre", {
3278
+ }, /* @__PURE__ */ React31.createElement("pre", {
3073
3279
  className: "overflow-x-auto text-xs"
3074
3280
  }, safeStringify(data, void 0, 2))), children);
3075
3281
  };
3076
3282
  var Section = ({ children, title, onClick }) => {
3077
- return /* @__PURE__ */ React30.createElement("div", {
3283
+ return /* @__PURE__ */ React31.createElement("div", {
3078
3284
  className: "flex flex-col gap-1"
3079
- }, onClick && /* @__PURE__ */ React30.createElement("div", null, /* @__PURE__ */ React30.createElement(IconButton, {
3285
+ }, onClick && /* @__PURE__ */ React31.createElement("div", null, /* @__PURE__ */ React31.createElement(IconButton, {
3080
3286
  classNames: "text-xs uppercase",
3081
3287
  label: title ?? "Copy",
3082
3288
  icon: "ph--clipboard-text--regular",
@@ -3118,14 +3324,14 @@ import { useArrowNavigationGroup as useArrowNavigationGroup2, useFocusableGroup,
3118
3324
  import { useComposedRefs as useComposedRefs3 } from "@radix-ui/react-compose-refs";
3119
3325
  import { Primitive as Primitive13 } from "@radix-ui/react-primitive";
3120
3326
  import { Slot as Slot13 } from "@radix-ui/react-slot";
3121
- import React31, { createContext as createContext8, useCallback as useCallback10, useContext as useContext4, useRef as useRef5, useState as useState10 } from "react";
3327
+ import React32, { createContext as createContext8, useCallback as useCallback12, useContext as useContext4, useRef as useRef8, useState as useState10 } from "react";
3122
3328
  var FOCUS_STATE_ATTR = "focus-state";
3123
3329
  var FocusContext = /* @__PURE__ */ createContext8({});
3124
3330
  var useFocus = () => useContext4(FocusContext);
3125
3331
  var Group3 = slottable(({ children, asChild, orientation = "vertical", border = false, ...props }, forwardedRef) => {
3126
3332
  const Comp = asChild ? Slot13 : Primitive13.div;
3127
3333
  const { tx } = useThemeContext();
3128
- const rootRef = useRef5(null);
3334
+ const rootRef = useRef8(null);
3129
3335
  const focusableGroupAttrs = useFocusableGroup({
3130
3336
  tabBehavior: "limited-trap-focus"
3131
3337
  });
@@ -3136,20 +3342,20 @@ var Group3 = slottable(({ children, asChild, orientation = "vertical", border =
3136
3342
  const tabsterAttrs = useMergedTabsterAttributes_unstable(focusableGroupAttrs, arrowNavigationAttrs);
3137
3343
  const [state, setState] = useState10();
3138
3344
  const [groupHasFocus, setGroupHasFocus] = useState10(false);
3139
- const handleFocusIn = useCallback10(() => setGroupHasFocus(true), []);
3140
- const handleFocusOut = useCallback10((event) => {
3345
+ const handleFocusIn = useCallback12(() => setGroupHasFocus(true), []);
3346
+ const handleFocusOut = useCallback12((event) => {
3141
3347
  const related = event.relatedTarget;
3142
3348
  if (!related || !rootRef.current?.contains(related)) {
3143
3349
  setGroupHasFocus(false);
3144
3350
  }
3145
3351
  }, []);
3146
3352
  const { className, ...rest } = composableProps(props);
3147
- return /* @__PURE__ */ React31.createElement(FocusContext.Provider, {
3353
+ return /* @__PURE__ */ React32.createElement(FocusContext.Provider, {
3148
3354
  value: {
3149
3355
  setFocus: setState,
3150
3356
  groupHasFocus
3151
3357
  }
3152
- }, /* @__PURE__ */ React31.createElement(Comp, {
3358
+ }, /* @__PURE__ */ React32.createElement(Comp, {
3153
3359
  ...rest,
3154
3360
  tabIndex: 0,
3155
3361
  className: tx("focus.group", {
@@ -3173,27 +3379,27 @@ var Item4 = slottable(({ children, asChild, current, border = false, onCurrentCh
3173
3379
  }
3174
3380
  });
3175
3381
  const [focused, setFocused] = useState10(false);
3176
- const handleClick = useCallback10((event) => {
3382
+ const handleClick = useCallback12((event) => {
3177
3383
  onCurrentChange?.();
3178
3384
  onClick?.(event);
3179
3385
  }, [
3180
3386
  onCurrentChange,
3181
3387
  onClick
3182
3388
  ]);
3183
- const handleKeyDown = useCallback10((event) => {
3389
+ const handleKeyDown = useCallback12((event) => {
3184
3390
  if (event.key === "Enter") {
3185
3391
  onCurrentChange?.();
3186
3392
  }
3187
3393
  }, [
3188
3394
  onCurrentChange
3189
3395
  ]);
3190
- const handleFocus = useCallback10((event) => {
3396
+ const handleFocus = useCallback12((event) => {
3191
3397
  setFocused(true);
3192
3398
  onFocus?.(event);
3193
3399
  }, [
3194
3400
  onFocus
3195
3401
  ]);
3196
- const handleBlur = useCallback10((event) => {
3402
+ const handleBlur = useCallback12((event) => {
3197
3403
  setFocused(false);
3198
3404
  onBlur?.(event);
3199
3405
  }, [
@@ -3201,7 +3407,7 @@ var Item4 = slottable(({ children, asChild, current, border = false, onCurrentCh
3201
3407
  ]);
3202
3408
  const isCurrent = current ?? focused;
3203
3409
  const { className, ...rest } = composableProps(props);
3204
- return /* @__PURE__ */ React31.createElement(Comp, {
3410
+ return /* @__PURE__ */ React32.createElement(Comp, {
3205
3411
  ...rest,
3206
3412
  tabIndex: 0,
3207
3413
  className: tx("focus.item", {
@@ -3225,16 +3431,15 @@ var Focus = {
3225
3431
  import * as CheckboxPrimitive from "@radix-ui/react-checkbox";
3226
3432
  import { createContext as createContext9 } from "@radix-ui/react-context";
3227
3433
  import { useControllableState as useControllableState4 } from "@radix-ui/react-use-controllable-state";
3228
- import React33, { forwardRef as forwardRef23, useCallback as useCallback12, useEffect as useEffect6, useRef as useRef6, useState as useState12 } from "react";
3434
+ import React34, { forwardRef as forwardRef24, useCallback as useCallback14, useEffect as useEffect6, useRef as useRef9, useState as useState12 } from "react";
3229
3435
  import { useTranslation as useTranslation5 } from "react-i18next";
3230
3436
  import { DescriptionAndValidation as DescriptionAndValidationPrimitive, Description as DescriptionPrimitive, INPUT_NAME as INPUT_NAME2, InputRoot, Label as LabelPrimitive, PinInput as PinInputPrimitive, TextArea as TextAreaPrimitive, TextInput as TextInputPrimitive, Validation as ValidationPrimitive, useInputContext as useInputContext2 } from "@dxos/react-input";
3231
- import { mx as mx11 } from "@dxos/ui-theme";
3232
3437
  import { translationKey as translationKey5 } from "#translations";
3233
3438
 
3234
3439
  // src/components/Input/SegmentedInput.tsx
3235
3440
  import { CalendarDate as CalendarDate2, CalendarDateTime, parseDate as parseDate2, parseDateTime, parseTime } from "@internationalized/date";
3236
3441
  import { useControllableState as useControllableState3 } from "@radix-ui/react-use-controllable-state";
3237
- import React32, { forwardRef as forwardRef22, useCallback as useCallback11, useState as useState11 } from "react";
3442
+ import React33, { forwardRef as forwardRef23, useCallback as useCallback13, useState as useState11 } from "react";
3238
3443
  import { DateField, DateInput, DateSegment, TimeField } from "react-aria-components";
3239
3444
  import { INPUT_NAME, useInputContext } from "@dxos/react-input";
3240
3445
  var tryParse = (parser, value) => {
@@ -3252,27 +3457,28 @@ var formatCalendarDate = (date) => `${pad(date.year, 4)}-${pad(date.month)}-${pa
3252
3457
  var formatCalendarDateTime = (datetime) => `${pad(datetime.year, 4)}-${pad(datetime.month)}-${pad(datetime.day)}T${pad(datetime.hour)}:${pad(datetime.minute)}`;
3253
3458
  var formatTime = (time) => `${pad(time.hour)}:${pad(time.minute)}`;
3254
3459
  var toCalendarDate2 = (date) => new CalendarDate2(date.getFullYear(), date.getMonth() + 1, date.getDate());
3255
- var fieldClass = "inline-flex items-center gap-px font-mono tabular-nums focus-within:bg-attention-surface";
3256
- var segmentClass = "rounded-xs outline-none text-end [caret-color:currentColor]! data-[type=year]:min-w-[4ch] data-[type=month]:min-w-[2ch] data-[type=day]:min-w-[2ch] data-[type=hour]:min-w-[2ch] data-[type=minute]:min-w-[2ch] data-[placeholder]:text-subdued data-[type=literal]:text-subdued data-[focused]:bg-accent-bg data-[focused]:text-accent-fg data-[invalid]:text-rose-500 data-[disabled]:cursor-not-allowed data-[disabled]:opacity-50";
3460
+ var fieldClassNames = "inline-flex flex-nowrap items-center gap-px whitespace-nowrap tabular-nums focus-within:bg-attention-surface";
3461
+ var segmentClassNames = "shrink-0 rounded-xs outline-none text-end [caret-color:currentColor]! data-[type=year]:min-w-[4ch] data-[type=month]:min-w-[1ch] data-[type=day]:min-w-[1ch] data-[type=hour]:min-w-[1ch] data-[type=minute]:min-w-[1ch] data-[placeholder]:text-subdued data-[type=literal]:text-subdued data-[focused]:bg-accent-bg data-[focused]:text-accent-fg data-[invalid]:text-rose-500 data-[disabled]:cursor-not-allowed data-[disabled]:opacity-50";
3462
+ var timeSegmentClassNames = `${segmentClassNames} data-[type=dayPeriod]:text-xs data-[type=dayPeriod]:text-description`;
3257
3463
  var BIDI_FORMAT_RE = /^[‪-‮⁦-⁩]+$/;
3258
- var renderSegment = (segment) => {
3464
+ var renderSegment = (segment, classNames = segmentClassNames) => {
3259
3465
  if (segment.type === "literal") {
3260
3466
  if (BIDI_FORMAT_RE.test(segment.text)) {
3261
- return /* @__PURE__ */ React32.createElement("span", {
3467
+ return /* @__PURE__ */ React33.createElement("span", {
3262
3468
  "aria-hidden": true,
3263
- className: "select-none w-[2ch] first:hidden last:hidden"
3469
+ className: "select-none w-[1ch] first:hidden last:hidden"
3264
3470
  });
3265
3471
  }
3266
3472
  if (segment.text.includes(",")) {
3267
- return /* @__PURE__ */ React32.createElement("span", {
3473
+ return /* @__PURE__ */ React33.createElement("span", {
3268
3474
  "aria-hidden": true,
3269
3475
  className: "select-none"
3270
3476
  }, " ");
3271
3477
  }
3272
3478
  }
3273
- return /* @__PURE__ */ React32.createElement(DateSegment, {
3479
+ return /* @__PURE__ */ React33.createElement(DateSegment, {
3274
3480
  segment,
3275
- className: segmentClass
3481
+ className: classNames
3276
3482
  });
3277
3483
  };
3278
3484
  var useFieldChrome = ({ __inputScope, density: densityProp, elevation: elevationProp }) => {
@@ -3290,9 +3496,9 @@ var useFieldChrome = ({ __inputScope, density: densityProp, elevation: elevation
3290
3496
  errorMessageId
3291
3497
  };
3292
3498
  };
3293
- var PickerWrapper = ({ pickerValue, onPickerChange, withTime, disabled = false, children, calendar }) => {
3499
+ var PickerWrapper = ({ children, pickerValue, withTime, disabled = false, calendar, onPickerChange }) => {
3294
3500
  const [open, setOpen] = useState11(false);
3295
- const openPicker = useCallback11(() => {
3501
+ const openPicker = useCallback13(() => {
3296
3502
  if (!disabled) {
3297
3503
  setOpen(true);
3298
3504
  }
@@ -3300,18 +3506,18 @@ var PickerWrapper = ({ pickerValue, onPickerChange, withTime, disabled = false,
3300
3506
  disabled
3301
3507
  ]);
3302
3508
  useInputTrigger(disabled ? void 0 : openPicker);
3303
- return /* @__PURE__ */ React32.createElement(DatePicker.Root, {
3509
+ return /* @__PURE__ */ React33.createElement(DatePicker.Root, {
3304
3510
  mode: "single",
3305
3511
  withTime,
3306
3512
  value: pickerValue,
3307
3513
  onValueChange: disabled ? void 0 : onPickerChange,
3308
3514
  open,
3309
3515
  onOpenChange: setOpen
3310
- }, /* @__PURE__ */ React32.createElement(Popover.Anchor, {
3516
+ }, /* @__PURE__ */ React33.createElement(Popover.Anchor, {
3311
3517
  asChild: true
3312
- }, children), /* @__PURE__ */ React32.createElement(DatePicker.Content, null, calendar));
3518
+ }, children), /* @__PURE__ */ React33.createElement(DatePicker.Content, null, calendar));
3313
3519
  };
3314
- var SegmentedDate = /* @__PURE__ */ forwardRef22(({ __inputScope, classNames, density: densityProp, elevation: elevationProp, variant, value, defaultValue, onValueChange, disabled, autoFocus, id, "aria-label": ariaLabel }, forwardedRef) => {
3520
+ var SegmentedDate = /* @__PURE__ */ forwardRef23(({ __inputScope, classNames, density: densityProp, elevation: elevationProp, variant, value, defaultValue, onValueChange, disabled, autoFocus, id, "aria-label": ariaLabel }, forwardedRef) => {
3315
3521
  const { tx, density, elevation, validationValence, contextId, descriptionId, errorMessageId } = useFieldChrome({
3316
3522
  __inputScope,
3317
3523
  density: densityProp,
@@ -3324,15 +3530,15 @@ var SegmentedDate = /* @__PURE__ */ forwardRef22(({ __inputScope, classNames, de
3324
3530
  });
3325
3531
  const parsed = tryParse(parseDate2, stringValue);
3326
3532
  const fieldProps = {
3327
- value: parsed,
3328
- onChange: (next) => setStringValue(next ? formatCalendarDate(next) : ""),
3329
- isDisabled: disabled,
3533
+ "value": parsed,
3534
+ "onChange": (next) => setStringValue(next ? formatCalendarDate(next) : ""),
3535
+ "isDisabled": disabled,
3330
3536
  autoFocus,
3331
3537
  "aria-label": ariaLabel ?? "date",
3332
- granularity: "day",
3333
- shouldForceLeadingZeros: true
3538
+ "granularity": "day",
3539
+ "shouldForceLeadingZeros": true
3334
3540
  };
3335
- const field = /* @__PURE__ */ React32.createElement(DateField, fieldProps, /* @__PURE__ */ React32.createElement(DateInput, {
3541
+ const field = /* @__PURE__ */ React33.createElement(DateField, fieldProps, /* @__PURE__ */ React33.createElement(DateInput, {
3336
3542
  ref: forwardedRef,
3337
3543
  ...id ?? contextId ? {
3338
3544
  id: id ?? contextId
@@ -3351,18 +3557,18 @@ var SegmentedDate = /* @__PURE__ */ forwardRef22(({ __inputScope, classNames, de
3351
3557
  density,
3352
3558
  elevation,
3353
3559
  validationValence
3354
- }, fieldClass, classNames)
3560
+ }, fieldClassNames, classNames)
3355
3561
  }, renderSegment));
3356
- return /* @__PURE__ */ React32.createElement(PickerWrapper, {
3562
+ return /* @__PURE__ */ React33.createElement(PickerWrapper, {
3357
3563
  pickerValue: parsed ? new Date(parsed.year, parsed.month - 1, parsed.day) : void 0,
3358
3564
  onPickerChange: (next) => setStringValue(next ? formatCalendarDate(toCalendarDate2(next)) : ""),
3359
3565
  withTime: false,
3360
3566
  disabled,
3361
- calendar: /* @__PURE__ */ React32.createElement(DatePicker.Calendar, null)
3567
+ calendar: /* @__PURE__ */ React33.createElement(DatePicker.Calendar, null)
3362
3568
  }, field);
3363
3569
  });
3364
3570
  SegmentedDate.displayName = "Input.SegmentedDate";
3365
- var SegmentedTime = /* @__PURE__ */ forwardRef22(({ __inputScope, classNames, density: densityProp, elevation: elevationProp, variant, value, defaultValue, onValueChange, disabled, autoFocus, id, hourCycle = 24, "aria-label": ariaLabel }, forwardedRef) => {
3571
+ var SegmentedTime = /* @__PURE__ */ forwardRef23(({ __inputScope, classNames, density: densityProp, elevation: elevationProp, variant, value, defaultValue, onValueChange, disabled, autoFocus, id, hourCycle = 24, "aria-label": ariaLabel }, forwardedRef) => {
3366
3572
  const { tx, density, elevation, validationValence, contextId, descriptionId, errorMessageId } = useFieldChrome({
3367
3573
  __inputScope,
3368
3574
  density: densityProp,
@@ -3375,16 +3581,16 @@ var SegmentedTime = /* @__PURE__ */ forwardRef22(({ __inputScope, classNames, de
3375
3581
  });
3376
3582
  const parsed = tryParse(parseTime, stringValue);
3377
3583
  const fieldProps = {
3378
- value: parsed,
3379
- onChange: (next) => setStringValue(next ? formatTime(next) : ""),
3380
- isDisabled: disabled,
3584
+ "value": parsed,
3585
+ "onChange": (next) => setStringValue(next ? formatTime(next) : ""),
3586
+ "isDisabled": disabled,
3381
3587
  autoFocus,
3382
3588
  "aria-label": ariaLabel ?? "time",
3383
- granularity: "minute",
3589
+ "granularity": "minute",
3384
3590
  hourCycle,
3385
- shouldForceLeadingZeros: true
3591
+ "shouldForceLeadingZeros": true
3386
3592
  };
3387
- return /* @__PURE__ */ React32.createElement(TimeField, fieldProps, /* @__PURE__ */ React32.createElement(DateInput, {
3593
+ return /* @__PURE__ */ React33.createElement(TimeField, fieldProps, /* @__PURE__ */ React33.createElement(DateInput, {
3388
3594
  ref: forwardedRef,
3389
3595
  ...id ?? contextId ? {
3390
3596
  id: id ?? contextId
@@ -3403,11 +3609,11 @@ var SegmentedTime = /* @__PURE__ */ forwardRef22(({ __inputScope, classNames, de
3403
3609
  density,
3404
3610
  elevation,
3405
3611
  validationValence
3406
- }, fieldClass, classNames)
3407
- }, renderSegment));
3612
+ }, fieldClassNames, classNames)
3613
+ }, (segment) => renderSegment(segment, timeSegmentClassNames)));
3408
3614
  });
3409
3615
  SegmentedTime.displayName = "Input.SegmentedTime";
3410
- var SegmentedDateTime = /* @__PURE__ */ forwardRef22(({ __inputScope, classNames, density: densityProp, elevation: elevationProp, variant, value, defaultValue, onValueChange, disabled, autoFocus, id, hourCycle = 24, "aria-label": ariaLabel }, forwardedRef) => {
3616
+ var SegmentedDateTime = /* @__PURE__ */ forwardRef23(({ __inputScope, classNames, density: densityProp, elevation: elevationProp, variant, value, defaultValue, onValueChange, disabled, autoFocus, id, hourCycle = 24, "aria-label": ariaLabel }, forwardedRef) => {
3411
3617
  const { tx, density, elevation, validationValence, contextId, descriptionId, errorMessageId } = useFieldChrome({
3412
3618
  __inputScope,
3413
3619
  density: densityProp,
@@ -3420,16 +3626,16 @@ var SegmentedDateTime = /* @__PURE__ */ forwardRef22(({ __inputScope, classNames
3420
3626
  });
3421
3627
  const parsed = tryParse(parseDateTime, stringValue);
3422
3628
  const fieldProps = {
3423
- value: parsed,
3424
- onChange: (next) => setStringValue(next ? formatCalendarDateTime(next) : ""),
3425
- isDisabled: disabled,
3629
+ "value": parsed,
3630
+ "onChange": (next) => setStringValue(next ? formatCalendarDateTime(next) : ""),
3631
+ "isDisabled": disabled,
3426
3632
  autoFocus,
3427
3633
  "aria-label": ariaLabel ?? "date-time",
3428
- granularity: "minute",
3634
+ "granularity": "minute",
3429
3635
  hourCycle,
3430
- shouldForceLeadingZeros: true
3636
+ "shouldForceLeadingZeros": true
3431
3637
  };
3432
- const field = /* @__PURE__ */ React32.createElement(DateField, fieldProps, /* @__PURE__ */ React32.createElement(DateInput, {
3638
+ const field = /* @__PURE__ */ React33.createElement(DateField, fieldProps, /* @__PURE__ */ React33.createElement(DateInput, {
3433
3639
  ref: forwardedRef,
3434
3640
  ...id ?? contextId ? {
3435
3641
  id: id ?? contextId
@@ -3448,14 +3654,14 @@ var SegmentedDateTime = /* @__PURE__ */ forwardRef22(({ __inputScope, classNames
3448
3654
  density,
3449
3655
  elevation,
3450
3656
  validationValence
3451
- }, fieldClass, classNames)
3657
+ }, fieldClassNames, classNames)
3452
3658
  }, renderSegment));
3453
- return /* @__PURE__ */ React32.createElement(PickerWrapper, {
3659
+ return /* @__PURE__ */ React33.createElement(PickerWrapper, {
3454
3660
  pickerValue: parsed ? new Date(parsed.year, parsed.month - 1, parsed.day, parsed.hour, parsed.minute) : void 0,
3455
3661
  onPickerChange: (next) => setStringValue(next ? formatCalendarDateTime(new CalendarDateTime(next.getFullYear(), next.getMonth() + 1, next.getDate(), next.getHours(), next.getMinutes())) : ""),
3456
3662
  withTime: true,
3457
3663
  disabled,
3458
- calendar: /* @__PURE__ */ React32.createElement(DatePicker.Calendar, null)
3664
+ calendar: /* @__PURE__ */ React33.createElement(DatePicker.Calendar, null)
3459
3665
  }, field);
3460
3666
  });
3461
3667
  SegmentedDateTime.displayName = "Input.SegmentedDateTime";
@@ -3481,9 +3687,9 @@ var useInputTrigger = (handler) => {
3481
3687
  ]);
3482
3688
  };
3483
3689
  var Root8 = (props) => {
3484
- const handlerRef = useRef6(null);
3690
+ const handlerRef = useRef9(null);
3485
3691
  const [hasTrigger, setHasTrigger] = useState12(false);
3486
- const registerTrigger = useCallback12((handler) => {
3692
+ const registerTrigger = useCallback14((handler) => {
3487
3693
  handlerRef.current = handler;
3488
3694
  setHasTrigger(true);
3489
3695
  return () => {
@@ -3493,23 +3699,23 @@ var Root8 = (props) => {
3493
3699
  }
3494
3700
  };
3495
3701
  }, []);
3496
- const trigger = useCallback12(() => {
3702
+ const trigger = useCallback14(() => {
3497
3703
  handlerRef.current?.();
3498
3704
  }, []);
3499
- return /* @__PURE__ */ React33.createElement(InputTriggerProvider, {
3705
+ return /* @__PURE__ */ React34.createElement(InputTriggerProvider, {
3500
3706
  registerTrigger,
3501
3707
  trigger,
3502
3708
  hasTrigger
3503
- }, /* @__PURE__ */ React33.createElement(InputRoot, props));
3709
+ }, /* @__PURE__ */ React34.createElement(InputRoot, props));
3504
3710
  };
3505
3711
  Root8.displayName = "Input.Root";
3506
- var TriggerIcon = /* @__PURE__ */ forwardRef23(({ classNames, icon = "ph--calendar--regular", "aria-label": ariaLabel, label, ...props }, forwardedRef) => {
3712
+ var TriggerIcon = /* @__PURE__ */ forwardRef24(({ classNames, icon = "ph--calendar--regular", "aria-label": ariaLabel, label, ...props }, forwardedRef) => {
3507
3713
  const { t } = useTranslation5(translationKey5);
3508
3714
  const ctx = useInputTriggerContext("Input.TriggerIcon");
3509
3715
  if (!ctx.hasTrigger) {
3510
3716
  return null;
3511
3717
  }
3512
- return /* @__PURE__ */ React33.createElement(IconButton, {
3718
+ return /* @__PURE__ */ React34.createElement(IconButton, {
3513
3719
  ref: forwardedRef,
3514
3720
  variant: "ghost",
3515
3721
  icon,
@@ -3522,9 +3728,9 @@ var TriggerIcon = /* @__PURE__ */ forwardRef23(({ classNames, icon = "ph--calend
3522
3728
  });
3523
3729
  });
3524
3730
  TriggerIcon.displayName = "Input.TriggerIcon";
3525
- var Label3 = /* @__PURE__ */ forwardRef23(({ classNames, children, srOnly, ...props }, forwardedRef) => {
3731
+ var Label3 = /* @__PURE__ */ forwardRef24(({ classNames, children, srOnly, ...props }, forwardedRef) => {
3526
3732
  const { tx } = useThemeContext();
3527
- return /* @__PURE__ */ React33.createElement(LabelPrimitive, {
3733
+ return /* @__PURE__ */ React34.createElement(LabelPrimitive, {
3528
3734
  ...props,
3529
3735
  className: tx("input.label", {
3530
3736
  srOnly
@@ -3533,9 +3739,9 @@ var Label3 = /* @__PURE__ */ forwardRef23(({ classNames, children, srOnly, ...pr
3533
3739
  }, children);
3534
3740
  });
3535
3741
  Label3.displayName = "Input.Label";
3536
- var Description3 = /* @__PURE__ */ forwardRef23(({ classNames, children, srOnly, ...props }, forwardedRef) => {
3742
+ var Description3 = /* @__PURE__ */ forwardRef24(({ classNames, children, srOnly, ...props }, forwardedRef) => {
3537
3743
  const { tx } = useThemeContext();
3538
- return /* @__PURE__ */ React33.createElement(DescriptionPrimitive, {
3744
+ return /* @__PURE__ */ React34.createElement(DescriptionPrimitive, {
3539
3745
  ...props,
3540
3746
  className: tx("input.description", {
3541
3747
  srOnly
@@ -3544,10 +3750,10 @@ var Description3 = /* @__PURE__ */ forwardRef23(({ classNames, children, srOnly,
3544
3750
  }, children);
3545
3751
  });
3546
3752
  Description3.displayName = "Input.Description";
3547
- var Validation = /* @__PURE__ */ forwardRef23(({ __inputScope, classNames, children, srOnly, ...props }, forwardedRef) => {
3753
+ var Validation = /* @__PURE__ */ forwardRef24(({ __inputScope, classNames, children, srOnly, ...props }, forwardedRef) => {
3548
3754
  const { tx } = useThemeContext();
3549
3755
  const { validationValence } = useInputContext2(INPUT_NAME2, __inputScope);
3550
- return /* @__PURE__ */ React33.createElement(ValidationPrimitive, {
3756
+ return /* @__PURE__ */ React34.createElement(ValidationPrimitive, {
3551
3757
  ...props,
3552
3758
  className: tx("input.validation", {
3553
3759
  srOnly,
@@ -3557,9 +3763,9 @@ var Validation = /* @__PURE__ */ forwardRef23(({ __inputScope, classNames, child
3557
3763
  }, children);
3558
3764
  });
3559
3765
  Validation.displayName = "Input.Validation";
3560
- var DescriptionAndValidation = /* @__PURE__ */ forwardRef23(({ classNames, children, srOnly, ...props }, forwardedRef) => {
3766
+ var DescriptionAndValidation = /* @__PURE__ */ forwardRef24(({ classNames, children, srOnly, ...props }, forwardedRef) => {
3561
3767
  const { tx } = useThemeContext();
3562
- return /* @__PURE__ */ React33.createElement(DescriptionAndValidationPrimitive, {
3768
+ return /* @__PURE__ */ React34.createElement(DescriptionAndValidationPrimitive, {
3563
3769
  ...props,
3564
3770
  className: tx("input.descriptionAndValidation", {
3565
3771
  srOnly
@@ -3568,17 +3774,17 @@ var DescriptionAndValidation = /* @__PURE__ */ forwardRef23(({ classNames, child
3568
3774
  }, children);
3569
3775
  });
3570
3776
  DescriptionAndValidation.displayName = "Input.DescriptionAndValidation";
3571
- var PinInput = /* @__PURE__ */ forwardRef23(({ classNames, density: propsDensity, elevation: propsElevation, ...props }, forwardedRef) => {
3777
+ var PinInput = /* @__PURE__ */ forwardRef24(({ classNames, density: propsDensity, elevation: propsElevation, ...props }, forwardedRef) => {
3572
3778
  const { hasIosKeyboard: hasIosKeyboard2 } = useThemeContext();
3573
3779
  const { tx } = useThemeContext();
3574
3780
  const density = useDensityContext(propsDensity);
3575
3781
  const elevation = useElevationContext(propsElevation);
3576
- return /* @__PURE__ */ React33.createElement(PinInputPrimitive, {
3782
+ return /* @__PURE__ */ React34.createElement(PinInputPrimitive, {
3577
3783
  ...props,
3578
3784
  ...props.autoFocus && !hasIosKeyboard2 && {
3579
3785
  autoFocus: true
3580
3786
  },
3581
- className: tx("input.inputWithSegments", {
3787
+ className: tx("input.pin", {
3582
3788
  disabled: props.disabled
3583
3789
  }, classNames) || "",
3584
3790
  segmentClassName: tx("input.segment", {
@@ -3590,13 +3796,13 @@ var PinInput = /* @__PURE__ */ forwardRef23(({ classNames, density: propsDensity
3590
3796
  });
3591
3797
  });
3592
3798
  PinInput.displayName = "Input.PinInput";
3593
- var TextInput = /* @__PURE__ */ forwardRef23(({ __inputScope, classNames, density: densityProp, elevation: elevationProp, variant, noAutoFill, ...props }, forwardedRef) => {
3799
+ var TextInput = /* @__PURE__ */ forwardRef24(({ __inputScope, classNames, density: densityProp, elevation: elevationProp, variant, noAutoFill, ...props }, forwardedRef) => {
3594
3800
  const { hasIosKeyboard: hasIosKeyboard2 } = useThemeContext();
3595
3801
  const { tx } = useThemeContext();
3596
3802
  const density = useDensityContext(densityProp);
3597
3803
  const elevation = useElevationContext(elevationProp);
3598
3804
  const { validationValence } = useInputContext2(INPUT_NAME2, __inputScope);
3599
- return /* @__PURE__ */ React33.createElement(TextInputPrimitive, {
3805
+ return /* @__PURE__ */ React34.createElement(TextInputPrimitive, {
3600
3806
  ...props,
3601
3807
  "data-1p-ignore": noAutoFill,
3602
3808
  className: tx("input.input", {
@@ -3613,13 +3819,13 @@ var TextInput = /* @__PURE__ */ forwardRef23(({ __inputScope, classNames, densit
3613
3819
  });
3614
3820
  });
3615
3821
  TextInput.displayName = "Input.TextInput";
3616
- var TextArea = /* @__PURE__ */ forwardRef23(({ __inputScope, classNames, density: propsDensity, elevation: propsElevation, variant, ...props }, forwardedRef) => {
3822
+ var TextArea = /* @__PURE__ */ forwardRef24(({ __inputScope, classNames, density: propsDensity, elevation: propsElevation, variant, ...props }, forwardedRef) => {
3617
3823
  const { hasIosKeyboard: hasIosKeyboard2 } = useThemeContext();
3618
3824
  const { tx } = useThemeContext();
3619
3825
  const density = useDensityContext(propsDensity);
3620
3826
  const elevation = useElevationContext(propsElevation);
3621
3827
  const { validationValence } = useInputContext2(INPUT_NAME2, __inputScope);
3622
- return /* @__PURE__ */ React33.createElement(TextAreaPrimitive, {
3828
+ return /* @__PURE__ */ React34.createElement(TextAreaPrimitive, {
3623
3829
  ...props,
3624
3830
  className: tx("input.textArea", {
3625
3831
  variant,
@@ -3635,7 +3841,7 @@ var TextArea = /* @__PURE__ */ forwardRef23(({ __inputScope, classNames, density
3635
3841
  });
3636
3842
  });
3637
3843
  TextArea.displayName = "Input.TextArea";
3638
- var Checkbox = /* @__PURE__ */ forwardRef23(({ __inputScope, classNames, checked: propsChecked, defaultChecked: propsDefaultChecked, onCheckedChange: propsOnCheckedChange, size, ...props }, forwardedRef) => {
3844
+ var Checkbox = /* @__PURE__ */ forwardRef24(({ __inputScope, classNames, checked: propsChecked, defaultChecked: propsDefaultChecked, onCheckedChange: propsOnCheckedChange, size, ...props }, forwardedRef) => {
3639
3845
  const [checked, onCheckedChange] = useControllableState4({
3640
3846
  prop: propsChecked,
3641
3847
  defaultProp: propsDefaultChecked,
@@ -3643,7 +3849,7 @@ var Checkbox = /* @__PURE__ */ forwardRef23(({ __inputScope, classNames, checked
3643
3849
  });
3644
3850
  const { id, validationValence, descriptionId, errorMessageId } = useInputContext2(INPUT_NAME2, __inputScope);
3645
3851
  const { tx } = useThemeContext();
3646
- return /* @__PURE__ */ React33.createElement(CheckboxPrimitive.Root, {
3852
+ return /* @__PURE__ */ React34.createElement(CheckboxPrimitive.Root, {
3647
3853
  ...props,
3648
3854
  checked,
3649
3855
  onCheckedChange,
@@ -3653,11 +3859,11 @@ var Checkbox = /* @__PURE__ */ forwardRef23(({ __inputScope, classNames, checked
3653
3859
  "aria-invalid": "true",
3654
3860
  "aria-errormessage": errorMessageId
3655
3861
  },
3656
- className: tx("input.checkbox", {
3862
+ "className": tx("input.checkbox", {
3657
3863
  size
3658
3864
  }, "shrink-0", classNames),
3659
3865
  ref: forwardedRef
3660
- }, /* @__PURE__ */ React33.createElement(Icon, {
3866
+ }, /* @__PURE__ */ React34.createElement(Icon, {
3661
3867
  icon: checked === "indeterminate" ? "ph--minus--regular" : "ph--check--regular",
3662
3868
  classNames: tx("input.checkboxIndicator", {
3663
3869
  size,
@@ -3666,16 +3872,19 @@ var Checkbox = /* @__PURE__ */ forwardRef23(({ __inputScope, classNames, checked
3666
3872
  }));
3667
3873
  });
3668
3874
  Checkbox.displayName = "Input.Checkbox";
3669
- var Switch = /* @__PURE__ */ forwardRef23(({ __inputScope, classNames, checked: propsChecked, defaultChecked: propsDefaultChecked, onCheckedChange: propsOnCheckedChange, ...props }, forwardedRef) => {
3875
+ var Switch = /* @__PURE__ */ forwardRef24(({ __inputScope, classNames, checked: propsChecked, defaultChecked: propsDefaultChecked, onCheckedChange: propsOnCheckedChange, ...props }, forwardedRef) => {
3876
+ const { tx } = useThemeContext();
3670
3877
  const [checked, onCheckedChange] = useControllableState4({
3671
3878
  prop: propsChecked,
3672
3879
  defaultProp: propsDefaultChecked ?? false,
3673
3880
  onChange: propsOnCheckedChange
3674
3881
  });
3675
3882
  const { id, validationValence, descriptionId, errorMessageId } = useInputContext2(INPUT_NAME2, __inputScope);
3676
- return /* @__PURE__ */ React33.createElement("input", {
3883
+ return /* @__PURE__ */ React34.createElement("input", {
3677
3884
  type: "checkbox",
3678
- className: mx11("dx-checkbox--switch dx-focus-ring", classNames),
3885
+ className: tx("input.switch", {
3886
+ disabled: props.disabled
3887
+ }, classNames),
3679
3888
  checked,
3680
3889
  onChange: (event) => {
3681
3890
  onCheckedChange(event.target.checked);
@@ -3691,6 +3900,15 @@ var Switch = /* @__PURE__ */ forwardRef23(({ __inputScope, classNames, checked:
3691
3900
  });
3692
3901
  });
3693
3902
  Switch.displayName = "Input.Switch";
3903
+ var Block = /* @__PURE__ */ forwardRef24(({ children, ...props }, forwardedRef) => {
3904
+ const { tx } = useThemeContext();
3905
+ return /* @__PURE__ */ React34.createElement("div", {
3906
+ ...props,
3907
+ className: tx("input.block"),
3908
+ ref: forwardedRef
3909
+ }, children);
3910
+ });
3911
+ Block.displayName = "Input.Block";
3694
3912
  var Time = SegmentedTime;
3695
3913
  var Date2 = SegmentedDate;
3696
3914
  var DateTime = SegmentedDateTime;
@@ -3705,355 +3923,28 @@ var Input = {
3705
3923
  DateTime,
3706
3924
  Checkbox,
3707
3925
  Switch,
3926
+ Block,
3708
3927
  Label: Label3,
3709
3928
  Description: Description3,
3710
3929
  Validation,
3711
3930
  DescriptionAndValidation
3712
3931
  };
3713
3932
 
3714
- // src/components/List/List.tsx
3715
- import { Primitive as Primitive14 } from "@radix-ui/react-primitive";
3716
- import { Slot as Slot14 } from "@radix-ui/react-slot";
3717
- import React35, { forwardRef as forwardRef24 } from "react";
3718
- import { LIST_ITEM_NAME, LIST_NAME, ListItemCollapsibleContent, List as ListPrimitive, ListItem as ListPrimitiveItem, ListItemHeading as ListPrimitiveItemHeading, ListItemOpenTrigger as ListPrimitiveItemOpenTrigger, useListContext, useListItemContext } from "@dxos/react-list";
3719
-
3720
- // src/components/List/ListDropIndicator.tsx
3721
- import React34 from "react";
3722
- var edgeToOrientationMap = {
3723
- top: "horizontal",
3724
- bottom: "horizontal",
3725
- left: "vertical",
3726
- right: "vertical"
3727
- };
3728
- var orientationStyles = {
3729
- horizontal: "h-(--line-thickness) left-[calc(var(--line-inset)+var(--terminal-radius))] right-(--line-inset) before:left-(--terminal-inset)",
3730
- vertical: "w-(--line-thickness) top-[calc(var(--line-inset)+var(--terminal-radius))] bottom-(--line-inset) before:top-(--terminal-inset)"
3731
- };
3732
- var edgeStyles = {
3733
- top: "top-(--line-offset) before:top-(--offset-terminal)",
3734
- right: "right-(--line-offset) before:right-(--offset-terminal)",
3735
- bottom: "bottom-(--line-offset) before:bottom-(--offset-terminal)",
3736
- left: "left-(--line-offset) before:left-(--offset-terminal)"
3737
- };
3738
- var strokeSize = 2;
3739
- var terminalSize = 8;
3740
- var offsetToAlignTerminalWithLine = (strokeSize - terminalSize) / 2;
3741
- var ListDropIndicator = ({ edge, gap = 0, lineInset = 0, terminalInset = lineInset - terminalSize }) => {
3742
- const orientation = edgeToOrientationMap[edge];
3743
- return /* @__PURE__ */ React34.createElement("div", {
3744
- style: {
3745
- "--line-thickness": `${strokeSize}px`,
3746
- "--line-offset": `calc(-0.5 * (${gap}px + ${strokeSize}px))`,
3747
- "--line-inset": `${lineInset}px`,
3748
- "--terminal-size": `${terminalSize}px`,
3749
- "--terminal-radius": `${terminalSize / 2}px`,
3750
- "--terminal-inset": `${terminalInset}px`,
3751
- "--offset-terminal": `${offsetToAlignTerminalWithLine}px`
3752
- },
3753
- className: `absolute z-10 pointer-events-none bg-accent-bg before:content-[''] before:w-(--terminal-size) before:h-(--terminal-size) box-border before:absolute before:border-[length:--line-thickness] before:border-solid before:border-accent-bg before:rounded-full ${orientationStyles[orientation]} ${edgeStyles[edge]}`
3754
- });
3755
- };
3756
-
3757
- // src/components/List/List.tsx
3758
- var List = composable(({ children, ...props }, forwardedRef) => {
3759
- const { tx } = useThemeContext();
3760
- const density = useDensityContext(props.density);
3761
- const { className, ...rest } = composableProps(props);
3762
- return /* @__PURE__ */ React35.createElement(DensityProvider, {
3763
- density
3764
- }, /* @__PURE__ */ React35.createElement(ListPrimitive, {
3765
- ...rest,
3766
- className: tx("list.root", {}, className),
3767
- ref: forwardedRef
3768
- }, children));
3769
- });
3770
- var ListItemEndcap = /* @__PURE__ */ forwardRef24(({ children, classNames, asChild, ...props }, forwardedRef) => {
3771
- const Comp = asChild ? Slot14 : Primitive14.div;
3772
- const density = useDensityContext();
3773
- const { tx } = useThemeContext();
3774
- return /* @__PURE__ */ React35.createElement(Comp, {
3775
- ...!asChild && {
3776
- role: "none"
3777
- },
3778
- ...props,
3779
- className: tx("list.item.endcap", {
3780
- density
3781
- }, classNames),
3782
- ref: forwardedRef
3783
- }, children);
3784
- });
3785
- var MockListItemOpenTrigger = ({ classNames, ...props }) => {
3786
- const density = useDensityContext();
3787
- const { tx } = useThemeContext();
3788
- return /* @__PURE__ */ React35.createElement("div", {
3789
- ...props,
3790
- className: tx("list.item.openTrigger", {
3791
- density
3792
- }, classNames)
3793
- });
3794
- };
3795
- var ListItemHeading = /* @__PURE__ */ forwardRef24(({ children, classNames, ...props }, forwardedRef) => {
3796
- const { tx } = useThemeContext();
3797
- const density = useDensityContext();
3798
- return /* @__PURE__ */ React35.createElement(ListPrimitiveItemHeading, {
3799
- ...props,
3800
- className: tx("list.item.heading", {
3801
- density
3802
- }, classNames),
3803
- ref: forwardedRef
3804
- }, /* @__PURE__ */ React35.createElement("span", null, children));
3805
- });
3806
- var ListItemOpenTrigger = /* @__PURE__ */ forwardRef24(({ __listItemScope, classNames, children, ...props }, forwardedRef) => {
3807
- const { tx } = useThemeContext();
3808
- const density = useDensityContext();
3809
- const { open } = useListItemContext(LIST_ITEM_NAME, __listItemScope);
3810
- return /* @__PURE__ */ React35.createElement(ListPrimitiveItemOpenTrigger, {
3811
- ...props,
3812
- className: tx("list.item.openTrigger", {
3813
- density
3814
- }, classNames),
3815
- ref: forwardedRef
3816
- }, children || /* @__PURE__ */ React35.createElement(Icon, {
3817
- size: 3,
3818
- icon: open ? "ph--caret-down--bold" : "ph--caret-right--bold",
3819
- classNames: tx("list.item.openTriggerIcon", {})
3820
- }));
3821
- });
3822
- var ListItemRoot = /* @__PURE__ */ forwardRef24(({ classNames, children, ...props }, forwardedRef) => {
3823
- const { tx } = useThemeContext();
3824
- const density = useDensityContext();
3825
- return /* @__PURE__ */ React35.createElement(ListPrimitiveItem, {
3826
- ...props,
3827
- className: tx("list.item.root", {
3828
- density,
3829
- collapsible: props.collapsible
3830
- }, classNames),
3831
- ref: forwardedRef
3832
- }, children);
3833
- });
3834
- var ListItem = {
3835
- Root: ListItemRoot,
3836
- Endcap: ListItemEndcap,
3837
- Heading: ListItemHeading,
3838
- OpenTrigger: ListItemOpenTrigger,
3839
- CollapsibleContent: ListItemCollapsibleContent,
3840
- MockOpenTrigger: MockListItemOpenTrigger,
3841
- DropIndicator: ListDropIndicator
3842
- };
3843
-
3844
- // src/components/List/Tree.tsx
3845
- import React37, { forwardRef as forwardRef25 } from "react";
3846
-
3847
- // src/components/List/TreeDropIndicator.tsx
3848
- import React36 from "react";
3849
- var edgeToOrientationMap2 = {
3850
- "reorder-above": "sibling",
3851
- "reorder-below": "sibling",
3852
- "make-child": "child",
3853
- reparent: "child"
3854
- };
3855
- var orientationStyles2 = {
3856
- // TODO(wittjosiah): Stop using left/right here.
3857
- sibling: "h-(--line-thickness) left-(--horizontal-indent) right-0 bg-accent-bg before:left-(--negative-terminal-size)",
3858
- child: "inset-0 border-[length:var(--line-thickness)] before:invisible"
3859
- };
3860
- var instructionStyles = {
3861
- "reorder-above": "top-(--line-offset) before:top-(--offset-terminal)",
3862
- "reorder-below": "bottom-(--line-offset) before:bottom-(--offset-terminal)",
3863
- "make-child": "border-accent-bg",
3864
- // TODO(wittjosiah): This is not occurring in the current implementation.
3865
- reparent: ""
3866
- };
3867
- var strokeSize2 = 2;
3868
- var terminalSize2 = 8;
3869
- var offsetToAlignTerminalWithLine2 = (strokeSize2 - terminalSize2) / 2;
3870
- var TreeDropIndicator = ({ instruction, gap = 0 }) => {
3871
- const lineOffset = `calc(-0.5 * (${gap}px + ${strokeSize2}px))`;
3872
- const isBlocked = instruction.type === "instruction-blocked";
3873
- const desiredInstruction = isBlocked ? instruction.desired : instruction;
3874
- const orientation = edgeToOrientationMap2[desiredInstruction.type];
3875
- if (isBlocked) {
3876
- return null;
3877
- }
3878
- return /* @__PURE__ */ React36.createElement("div", {
3879
- style: {
3880
- "--line-thickness": `${strokeSize2}px`,
3881
- "--line-offset": `${lineOffset}`,
3882
- "--terminal-size": `${terminalSize2}px`,
3883
- "--terminal-radius": `${terminalSize2 / 2}px`,
3884
- "--negative-terminal-size": `-${terminalSize2}px`,
3885
- "--offset-terminal": `${offsetToAlignTerminalWithLine2}px`,
3886
- "--horizontal-indent": `${desiredInstruction.currentLevel * desiredInstruction.indentPerLevel + 4}px`
3887
- },
3888
- className: `absolute z-10 pointer-events-none before:w-(--terminal-size) before:h-(--terminal-size) box-border before:absolute before:border-[length:--line-thickness] before:border-solid before:border-accent-bg before:rounded-full ${orientationStyles2[orientation]} ${instructionStyles[desiredInstruction.type]}`
3889
- });
3890
- };
3891
-
3892
- // src/components/List/Tree.tsx
3893
- var TreeRoot = /* @__PURE__ */ forwardRef25((props, forwardedRef) => {
3894
- return /* @__PURE__ */ React37.createElement(List, {
3895
- ...props,
3896
- ref: forwardedRef
3897
- });
3898
- });
3899
- var TreeBranch = /* @__PURE__ */ forwardRef25(({ __listScope, ...props }, forwardedRef) => {
3900
- const { headingId } = useListItemContext(LIST_ITEM_NAME, __listScope);
3901
- return /* @__PURE__ */ React37.createElement(List, {
3902
- ...props,
3903
- "aria-labelledby": headingId,
3904
- ref: forwardedRef
3905
- });
3906
- });
3907
- var TreeItemRoot = /* @__PURE__ */ forwardRef25((props, forwardedRef) => {
3908
- return /* @__PURE__ */ React37.createElement(ListItem.Root, {
3909
- role: "treeitem",
3910
- ...props,
3911
- ref: forwardedRef
3912
- });
3913
- });
3914
- var TreeItemHeading = ListItem.Heading;
3915
- var TreeItemOpenTrigger = ListItem.OpenTrigger;
3916
- var MockTreeItemOpenTrigger = ListItem.MockOpenTrigger;
3917
- var TreeItemBody = ListItem.CollapsibleContent;
3918
- var Tree = {
3919
- Root: TreeRoot,
3920
- Branch: TreeBranch
3921
- };
3922
- var TreeItem = {
3923
- Root: TreeItemRoot,
3924
- Heading: TreeItemHeading,
3925
- Body: TreeItemBody,
3926
- OpenTrigger: TreeItemOpenTrigger,
3927
- MockOpenTrigger: MockTreeItemOpenTrigger,
3928
- DropIndicator: TreeDropIndicator
3929
- };
3930
-
3931
- // src/components/List/Treegrid.tsx
3932
- import { useFocusFinders } from "@fluentui/react-tabster";
3933
- import { createContextScope as createContextScope3 } from "@radix-ui/react-context";
3934
- import { Primitive as Primitive15 } from "@radix-ui/react-primitive";
3935
- import { Slot as Slot15 } from "@radix-ui/react-slot";
3936
- import { useControllableState as useControllableState5 } from "@radix-ui/react-use-controllable-state";
3937
- import React38, { forwardRef as forwardRef26, useCallback as useCallback13 } from "react";
3938
- var TREEGRID_ROW_NAME = "Treegrid.Row";
3939
- var [createTreegridRowContext, createTreegridRowScope] = createContextScope3(TREEGRID_ROW_NAME, []);
3940
- var [TreegridRowProvider, useTreegridRowContext] = createTreegridRowContext(TREEGRID_ROW_NAME);
3941
- var TREEGRID_PATH_SEPARATOR = "~";
3942
- var TREEGRID_PARENT_OF_SEPARATOR = " ";
3943
- var TreegridRoot = composable(({ asChild, classNames, children, style, gridTemplateColumns, onKeyDown: onKeyDownProp, ...props }, forwardedRef) => {
3944
- const { tx } = useThemeContext();
3945
- const { className, role: _role, ...rest } = composableProps(props, {
3946
- classNames
3947
- });
3948
- const Comp = asChild ? Slot15 : Primitive15.div;
3949
- const { findFirstFocusable } = useFocusFinders();
3950
- const handleKeyDown = useCallback13((event) => {
3951
- switch (event.key) {
3952
- case "ArrowDown":
3953
- case "ArrowUp": {
3954
- const direction = event.key === "ArrowDown" ? "down" : "up";
3955
- const target = event.target;
3956
- const ancestorWithArrowKeys = target.closest(`[data-arrow-keys*="${direction}"], [data-arrow-keys="all"]`);
3957
- if (!ancestorWithArrowKeys) {
3958
- const currentRow = target.closest('[role="row"]');
3959
- if (currentRow) {
3960
- const treegrid = currentRow.closest('[role="treegrid"]');
3961
- if (treegrid) {
3962
- const rows = Array.from(treegrid.querySelectorAll('[role="row"]'));
3963
- const currentIndex = rows.indexOf(currentRow);
3964
- const nextIndex = direction === "down" ? currentIndex + 1 : currentIndex - 1;
3965
- const targetRow = rows[nextIndex];
3966
- if (targetRow) {
3967
- const firstFocusable = findFirstFocusable(targetRow);
3968
- if (firstFocusable) {
3969
- event.preventDefault();
3970
- firstFocusable.focus();
3971
- }
3972
- }
3973
- }
3974
- }
3975
- }
3976
- break;
3977
- }
3978
- }
3979
- onKeyDownProp?.(event);
3980
- }, [
3981
- findFirstFocusable,
3982
- onKeyDownProp
3983
- ]);
3984
- return /* @__PURE__ */ React38.createElement(Comp, {
3985
- role: "treegrid",
3986
- ...rest,
3987
- className: tx("treegrid.root", {}, className),
3988
- style: {
3989
- ...style,
3990
- gridTemplateColumns
3991
- },
3992
- onKeyDown: handleKeyDown,
3993
- ref: forwardedRef
3994
- }, children);
3995
- });
3996
- var TreegridRow = /* @__PURE__ */ forwardRef26(({ __treegridRowScope, asChild, classNames, children, id, parentOf, open: propsOpen, defaultOpen, onOpenChange: propsOnOpenChange, ...props }, forwardedRef) => {
3997
- const { tx } = useThemeContext();
3998
- const Comp = asChild ? Slot15 : Primitive15.div;
3999
- const pathParts = id.split(TREEGRID_PATH_SEPARATOR);
4000
- const level = pathParts.length - 1;
4001
- const [open, onOpenChange] = useControllableState5({
4002
- prop: propsOpen,
4003
- onChange: propsOnOpenChange,
4004
- defaultProp: defaultOpen
4005
- });
4006
- return /* @__PURE__ */ React38.createElement(TreegridRowProvider, {
4007
- open,
4008
- onOpenChange,
4009
- scope: __treegridRowScope
4010
- }, /* @__PURE__ */ React38.createElement(Comp, {
4011
- role: "row",
4012
- "aria-level": level,
4013
- className: tx("treegrid.row", {
4014
- level
4015
- }, classNames),
4016
- ...parentOf && {
4017
- "aria-expanded": open,
4018
- "aria-owns": parentOf
4019
- },
4020
- ...props,
4021
- id,
4022
- ref: forwardedRef
4023
- }, children));
4024
- });
4025
- var TreegridCell = /* @__PURE__ */ forwardRef26(({ classNames, children, indent, ...props }, forwardedRef) => {
4026
- const { tx } = useThemeContext();
4027
- return /* @__PURE__ */ React38.createElement("div", {
4028
- role: "gridcell",
4029
- className: tx("treegrid.cell", {
4030
- indent
4031
- }, classNames),
4032
- ...props,
4033
- ref: forwardedRef
4034
- }, children);
4035
- });
4036
- var Treegrid = {
4037
- Root: TreegridRoot,
4038
- Row: TreegridRow,
4039
- Cell: TreegridCell
4040
- };
4041
-
4042
3933
  // src/components/Main/Main.tsx
4043
3934
  import { useFocusableGroup as useFocusableGroup2 } from "@fluentui/react-tabster";
4044
3935
  import { createContext as createContext10 } from "@radix-ui/react-context";
4045
3936
  import { DialogContent as DialogContent2, Root as DialogRoot2, DialogTitle as DialogTitle2 } from "@radix-ui/react-dialog";
4046
- import { Primitive as Primitive16 } from "@radix-ui/react-primitive";
4047
- import { Slot as Slot16 } from "@radix-ui/react-slot";
4048
- import { useControllableState as useControllableState6 } from "@radix-ui/react-use-controllable-state";
4049
- import React39, { forwardRef as forwardRef27, useCallback as useCallback15, useEffect as useEffect8, useRef as useRef7, useState as useState14 } from "react";
3937
+ import { Primitive as Primitive14 } from "@radix-ui/react-primitive";
3938
+ import { Slot as Slot14 } from "@radix-ui/react-slot";
3939
+ import { useControllableState as useControllableState5 } from "@radix-ui/react-use-controllable-state";
3940
+ import React35, { forwardRef as forwardRef25, useCallback as useCallback16, useEffect as useEffect8, useRef as useRef10, useState as useState14 } from "react";
4050
3941
  import { addEventListener } from "@dxos/async";
4051
3942
  import { log as log2 } from "@dxos/log";
4052
3943
  import { useForwardedRef, useMediaQuery } from "@dxos/react-hooks";
4053
3944
  import { osTranslations as osTranslations3 } from "@dxos/ui-theme";
4054
3945
 
4055
3946
  // src/components/Main/useSwipeToDismiss.ts
4056
- import { useCallback as useCallback14, useEffect as useEffect7, useState as useState13 } from "react";
3947
+ import { useCallback as useCallback15, useEffect as useEffect7, useState as useState13 } from "react";
4057
3948
  var useSwipeToDismiss = (ref, {
4058
3949
  onDismiss,
4059
3950
  dismissThreshold = 64,
@@ -4064,20 +3955,20 @@ var useSwipeToDismiss = (ref, {
4064
3955
  const $root = ref.current;
4065
3956
  const [motionState, setMotionState] = useState13(0);
4066
3957
  const [gestureStartX, setGestureStartX] = useState13(0);
4067
- const setIdle = useCallback14(() => {
3958
+ const setIdle = useCallback15(() => {
4068
3959
  setMotionState(0);
4069
3960
  $root?.style.removeProperty("inset-inline-start");
4070
3961
  $root?.style.setProperty("transition-duration", "200ms");
4071
3962
  }, [
4072
3963
  $root
4073
3964
  ]);
4074
- const setFollowing = useCallback14(() => {
3965
+ const setFollowing = useCallback15(() => {
4075
3966
  setMotionState(2);
4076
3967
  $root?.style.setProperty("transition-duration", "0ms");
4077
3968
  }, [
4078
3969
  $root
4079
3970
  ]);
4080
- const handlePointerDown = useCallback14(({ screenX }) => {
3971
+ const handlePointerDown = useCallback15(({ screenX }) => {
4081
3972
  if (motionState === 0) {
4082
3973
  setMotionState(1);
4083
3974
  setGestureStartX(screenX);
@@ -4085,7 +3976,7 @@ var useSwipeToDismiss = (ref, {
4085
3976
  }, [
4086
3977
  motionState
4087
3978
  ]);
4088
- const handlePointerMove = useCallback14(({ screenX }) => {
3979
+ const handlePointerMove = useCallback15(({ screenX }) => {
4089
3980
  if ($root) {
4090
3981
  const delta = Math.min(screenX - gestureStartX, 0);
4091
3982
  switch (motionState) {
@@ -4109,7 +4000,7 @@ var useSwipeToDismiss = (ref, {
4109
4000
  motionState,
4110
4001
  gestureStartX
4111
4002
  ]);
4112
- const handlePointerUp = useCallback14(() => {
4003
+ const handlePointerUp = useCallback15(() => {
4113
4004
  setIdle();
4114
4005
  }, [
4115
4006
  setIdle
@@ -4156,7 +4047,7 @@ var handleOpenAutoFocus = (event) => {
4156
4047
  };
4157
4048
  var landmarkAttr = "data-main-landmark";
4158
4049
  var useLandmarkMover = (propsOnKeyDown, landmark) => {
4159
- const handleKeyDown = useCallback15((event) => {
4050
+ const handleKeyDown = useCallback16((event) => {
4160
4051
  const target = event.target;
4161
4052
  if (event.target === event.currentTarget && event.key === "Tab" && target.hasAttribute(landmarkAttr)) {
4162
4053
  event.preventDefault();
@@ -4199,38 +4090,38 @@ var useSidebars = (consumerName) => {
4199
4090
  return {
4200
4091
  navigationSidebarState,
4201
4092
  setNavigationSidebarState,
4202
- toggleNavigationSidebar: useCallback15(() => setNavigationSidebarState(navigationSidebarState === "expanded" ? "closed" : "expanded"), [
4093
+ toggleNavigationSidebar: useCallback16(() => setNavigationSidebarState(navigationSidebarState === "expanded" ? "closed" : "expanded"), [
4203
4094
  navigationSidebarState,
4204
4095
  setNavigationSidebarState
4205
4096
  ]),
4206
- openNavigationSidebar: useCallback15(() => setNavigationSidebarState("expanded"), []),
4207
- collapseNavigationSidebar: useCallback15(() => setNavigationSidebarState("collapsed"), []),
4208
- closeNavigationSidebar: useCallback15(() => setNavigationSidebarState("closed"), []),
4097
+ openNavigationSidebar: useCallback16(() => setNavigationSidebarState("expanded"), []),
4098
+ collapseNavigationSidebar: useCallback16(() => setNavigationSidebarState("collapsed"), []),
4099
+ closeNavigationSidebar: useCallback16(() => setNavigationSidebarState("closed"), []),
4209
4100
  complementarySidebarState,
4210
4101
  setComplementarySidebarState,
4211
- toggleComplementarySidebar: useCallback15(() => setComplementarySidebarState(complementarySidebarState === "expanded" ? "closed" : "expanded"), [
4102
+ toggleComplementarySidebar: useCallback16(() => setComplementarySidebarState(complementarySidebarState === "expanded" ? "closed" : "expanded"), [
4212
4103
  complementarySidebarState,
4213
4104
  setComplementarySidebarState
4214
4105
  ]),
4215
- openComplementarySidebar: useCallback15(() => setComplementarySidebarState("expanded"), []),
4216
- collapseComplementarySidebar: useCallback15(() => setComplementarySidebarState("collapsed"), []),
4217
- closeComplementarySidebar: useCallback15(() => setComplementarySidebarState("closed"), [])
4106
+ openComplementarySidebar: useCallback16(() => setComplementarySidebarState("expanded"), []),
4107
+ collapseComplementarySidebar: useCallback16(() => setComplementarySidebarState("collapsed"), []),
4108
+ closeComplementarySidebar: useCallback16(() => setComplementarySidebarState("closed"), [])
4218
4109
  };
4219
4110
  };
4220
4111
  var MainRoot = ({ navigationSidebarState: propsNavigationSidebarState, defaultNavigationSidebarState = "closed", onNavigationSidebarStateChange, complementarySidebarState: propsComplementarySidebarState, defaultComplementarySidebarState = "closed", onComplementarySidebarStateChange, children, ...props }) => {
4221
4112
  const [isLg] = useMediaQuery("lg");
4222
- const [navigationSidebarState = isLg ? "expanded" : "collapsed", setNavigationSidebarState] = useControllableState6({
4113
+ const [navigationSidebarState = isLg ? "expanded" : "collapsed", setNavigationSidebarState] = useControllableState5({
4223
4114
  prop: propsNavigationSidebarState,
4224
4115
  defaultProp: defaultNavigationSidebarState,
4225
4116
  onChange: onNavigationSidebarStateChange
4226
4117
  });
4227
- const [complementarySidebarState = isLg ? "expanded" : "collapsed", setComplementarySidebarState] = useControllableState6({
4118
+ const [complementarySidebarState = isLg ? "expanded" : "collapsed", setComplementarySidebarState] = useControllableState5({
4228
4119
  prop: propsComplementarySidebarState,
4229
4120
  defaultProp: defaultComplementarySidebarState,
4230
4121
  onChange: onComplementarySidebarStateChange
4231
4122
  });
4232
4123
  const [resizing, setResizing] = useState14(false);
4233
- const resizeInterval = useRef7(null);
4124
+ const resizeInterval = useRef10(null);
4234
4125
  useEffect8(() => addEventListener(window, "resize", () => {
4235
4126
  setResizing(true);
4236
4127
  if (resizeInterval.current) {
@@ -4241,7 +4132,7 @@ var MainRoot = ({ navigationSidebarState: propsNavigationSidebarState, defaultNa
4241
4132
  resizeInterval.current = null;
4242
4133
  }, 3e3);
4243
4134
  }), []);
4244
- return /* @__PURE__ */ React39.createElement(MainProvider, {
4135
+ return /* @__PURE__ */ React35.createElement(MainProvider, {
4245
4136
  ...props,
4246
4137
  navigationSidebarState,
4247
4138
  setNavigationSidebarState,
@@ -4251,11 +4142,11 @@ var MainRoot = ({ navigationSidebarState: propsNavigationSidebarState, defaultNa
4251
4142
  }, children);
4252
4143
  };
4253
4144
  MainRoot.displayName = MAIN_ROOT_NAME;
4254
- var MainOverlay = /* @__PURE__ */ forwardRef27(({ classNames, ...props }, forwardedRef) => {
4145
+ var MainOverlay = /* @__PURE__ */ forwardRef25(({ classNames, ...props }, forwardedRef) => {
4255
4146
  const [isLg] = useMediaQuery("lg");
4256
4147
  const { navigationSidebarState, setNavigationSidebarState, complementarySidebarState, setComplementarySidebarState } = useMainContext(MAIN_OVERLAY_NAME);
4257
4148
  const { tx } = useThemeContext();
4258
- return /* @__PURE__ */ React39.createElement("div", {
4149
+ return /* @__PURE__ */ React35.createElement("div", {
4259
4150
  ...props,
4260
4151
  onClick: () => {
4261
4152
  setNavigationSidebarState("collapsed");
@@ -4272,16 +4163,16 @@ var MainOverlay = /* @__PURE__ */ forwardRef27(({ classNames, ...props }, forwar
4272
4163
  });
4273
4164
  });
4274
4165
  MainOverlay.displayName = MAIN_OVERLAY_NAME;
4275
- var MainSidebar = /* @__PURE__ */ forwardRef27(({ classNames, children, swipeToDismiss, onOpenAutoFocus, state, resizing, onStateChange, side, label, ...props }, forwardedRef) => {
4166
+ var MainSidebar = /* @__PURE__ */ forwardRef25(({ classNames, children, swipeToDismiss, onOpenAutoFocus, state, resizing, onStateChange, side, label, ...props }, forwardedRef) => {
4276
4167
  const [isLg] = useMediaQuery("lg");
4277
4168
  const { tx } = useThemeContext();
4278
4169
  const { t } = useTranslation(osTranslations3);
4279
4170
  const ref = useForwardedRef(forwardedRef);
4280
- const noopRef = useRef7(null);
4171
+ const noopRef = useRef10(null);
4281
4172
  useSwipeToDismiss(swipeToDismiss ? ref : noopRef, {
4282
4173
  onDismiss: () => onStateChange?.("closed")
4283
4174
  });
4284
- const handleKeyDown = useCallback15((event) => {
4175
+ const handleKeyDown = useCallback16((event) => {
4285
4176
  const focusGroupParent = event.target.closest("[data-tabster]");
4286
4177
  if (event.key === "Escape" && focusGroupParent) {
4287
4178
  event.preventDefault();
@@ -4292,14 +4183,14 @@ var MainSidebar = /* @__PURE__ */ forwardRef27(({ classNames, children, swipeToD
4292
4183
  }, [
4293
4184
  props.onKeyDown
4294
4185
  ]);
4295
- const Root13 = isLg ? Primitive16.div : DialogContent2;
4296
- return /* @__PURE__ */ React39.createElement(DialogRoot2, {
4186
+ const Root13 = isLg ? Primitive14.div : DialogContent2;
4187
+ return /* @__PURE__ */ React35.createElement(DialogRoot2, {
4297
4188
  open: state !== "closed",
4298
4189
  "aria-label": toLocalizedString(label, t),
4299
4190
  modal: false
4300
- }, !isLg && /* @__PURE__ */ React39.createElement(DialogTitle2, {
4191
+ }, !isLg && /* @__PURE__ */ React35.createElement(DialogTitle2, {
4301
4192
  className: "sr-only"
4302
- }, toLocalizedString(label, t)), /* @__PURE__ */ React39.createElement(Root13, {
4193
+ }, toLocalizedString(label, t)), /* @__PURE__ */ React35.createElement(Root13, {
4303
4194
  ...!isLg && {
4304
4195
  forceMount: true,
4305
4196
  tabIndex: -1,
@@ -4317,10 +4208,10 @@ var MainSidebar = /* @__PURE__ */ forwardRef27(({ classNames, children, swipeToD
4317
4208
  ref
4318
4209
  }, children));
4319
4210
  });
4320
- var MainNavigationSidebar = /* @__PURE__ */ forwardRef27((props, forwardedRef) => {
4211
+ var MainNavigationSidebar = /* @__PURE__ */ forwardRef25((props, forwardedRef) => {
4321
4212
  const { navigationSidebarState, setNavigationSidebarState, resizing } = useMainContext(NAVIGATION_SIDEBAR_NAME);
4322
4213
  const mover = useLandmarkMover(props.onKeyDown, "0");
4323
- return /* @__PURE__ */ React39.createElement(MainSidebar, {
4214
+ return /* @__PURE__ */ React35.createElement(MainSidebar, {
4324
4215
  ...mover,
4325
4216
  ...props,
4326
4217
  state: navigationSidebarState,
@@ -4331,10 +4222,10 @@ var MainNavigationSidebar = /* @__PURE__ */ forwardRef27((props, forwardedRef) =
4331
4222
  });
4332
4223
  });
4333
4224
  MainNavigationSidebar.displayName = NAVIGATION_SIDEBAR_NAME;
4334
- var MainComplementarySidebar = /* @__PURE__ */ forwardRef27((props, forwardedRef) => {
4225
+ var MainComplementarySidebar = /* @__PURE__ */ forwardRef25((props, forwardedRef) => {
4335
4226
  const { complementarySidebarState, setComplementarySidebarState, resizing } = useMainContext(COMPLEMENTARY_SIDEBAR_NAME);
4336
4227
  const mover = useLandmarkMover(props.onKeyDown, "2");
4337
- return /* @__PURE__ */ React39.createElement(MainSidebar, {
4228
+ return /* @__PURE__ */ React35.createElement(MainSidebar, {
4338
4229
  ...mover,
4339
4230
  ...props,
4340
4231
  state: complementarySidebarState,
@@ -4345,12 +4236,12 @@ var MainComplementarySidebar = /* @__PURE__ */ forwardRef27((props, forwardedRef
4345
4236
  });
4346
4237
  });
4347
4238
  MainComplementarySidebar.displayName = COMPLEMENTARY_SIDEBAR_NAME;
4348
- var MainContent = /* @__PURE__ */ forwardRef27(({ asChild, classNames, bounce, handlesFocus, children, role, ...props }, forwardedRef) => {
4239
+ var MainContent = /* @__PURE__ */ forwardRef25(({ asChild, classNames, bounce, handlesFocus, children, role, ...props }, forwardedRef) => {
4349
4240
  const { navigationSidebarState, complementarySidebarState } = useMainContext(MAIN_NAME);
4350
4241
  const { tx } = useThemeContext();
4351
- const Comp = asChild ? Slot16 : role ? Primitive16.div : "main";
4242
+ const Comp = asChild ? Slot14 : role ? Primitive14.div : "main";
4352
4243
  const mover = useLandmarkMover(props.onKeyDown, "1");
4353
- return /* @__PURE__ */ React39.createElement(Comp, {
4244
+ return /* @__PURE__ */ React35.createElement(Comp, {
4354
4245
  ...handlesFocus && {
4355
4246
  ...mover
4356
4247
  },
@@ -4377,9 +4268,9 @@ var Main = {
4377
4268
 
4378
4269
  // src/components/Message/Message.tsx
4379
4270
  import { createContext as createContext11 } from "@radix-ui/react-context";
4380
- import { Primitive as Primitive17 } from "@radix-ui/react-primitive";
4381
- import { Slot as Slot17 } from "@radix-ui/react-slot";
4382
- import React40, { forwardRef as forwardRef28 } from "react";
4271
+ import { Primitive as Primitive15 } from "@radix-ui/react-primitive";
4272
+ import { Slot as Slot15 } from "@radix-ui/react-slot";
4273
+ import React36, { forwardRef as forwardRef26 } from "react";
4383
4274
  import { useTranslation as useTranslation6 } from "react-i18next";
4384
4275
  import { useId as useId5 } from "@dxos/react-hooks";
4385
4276
  import { translationKey as translationKey6 } from "#translations";
@@ -4419,16 +4310,16 @@ var valenceVars = {
4419
4310
  }
4420
4311
  };
4421
4312
  var [MessageProvider, useMessageContext] = createContext11(MESSAGE_NAME);
4422
- var MessageRoot = /* @__PURE__ */ forwardRef28(({ asChild, valence = "neutral", elevation: propsElevation, classNames, titleId: propsTitleId, descriptionId: propsDescriptionId, children, ...props }, forwardedRef) => {
4313
+ var MessageRoot = /* @__PURE__ */ forwardRef26(({ asChild, valence = "neutral", elevation: propsElevation, classNames, titleId: propsTitleId, descriptionId: propsDescriptionId, children, ...props }, forwardedRef) => {
4423
4314
  const { tx } = useThemeContext();
4424
4315
  const titleId = useId5("message__title", propsTitleId);
4425
4316
  const descriptionId = useId5("message__description", propsDescriptionId);
4426
4317
  const elevation = useElevationContext(propsElevation);
4427
- return /* @__PURE__ */ React40.createElement(MessageProvider, {
4318
+ return /* @__PURE__ */ React36.createElement(MessageProvider, {
4428
4319
  titleId,
4429
4320
  descriptionId,
4430
4321
  valence
4431
- }, /* @__PURE__ */ React40.createElement(Column.Root, {
4322
+ }, /* @__PURE__ */ React36.createElement(Column.Root, {
4432
4323
  asChild,
4433
4324
  role: valence === "neutral" ? "paragraph" : "alert",
4434
4325
  "aria-labelledby": titleId,
@@ -4447,22 +4338,22 @@ var MessageRoot = /* @__PURE__ */ forwardRef28(({ asChild, valence = "neutral",
4447
4338
  });
4448
4339
  MessageRoot.displayName = MESSAGE_NAME;
4449
4340
  var MESSAGE_TITLE_NAME = "Message.Title";
4450
- var MessageTitle = /* @__PURE__ */ forwardRef28(({ classNames, children, icon: iconProp, onClose }, forwardedRef) => {
4341
+ var MessageTitle = /* @__PURE__ */ forwardRef26(({ classNames, children, icon: iconProp, onClose }, forwardedRef) => {
4451
4342
  const { t } = useTranslation6(translationKey6);
4452
4343
  const { tx } = useThemeContext();
4453
4344
  const { titleId, valence } = useMessageContext(MESSAGE_TITLE_NAME);
4454
4345
  const icon = iconProp ?? messageIcons[valence];
4455
- return /* @__PURE__ */ React40.createElement(Column.Row, {
4346
+ return /* @__PURE__ */ React36.createElement(Column.Row, {
4456
4347
  classNames: tx("message.header", {}, classNames),
4457
4348
  ref: forwardedRef
4458
- }, icon && /* @__PURE__ */ React40.createElement(Column.Block, null, /* @__PURE__ */ React40.createElement(Icon, {
4349
+ }, icon && /* @__PURE__ */ React36.createElement(Column.Block, null, /* @__PURE__ */ React36.createElement(Icon, {
4459
4350
  icon
4460
- })), /* @__PURE__ */ React40.createElement("h2", {
4351
+ })), /* @__PURE__ */ React36.createElement("h2", {
4461
4352
  className: tx("message.title", {}, classNames),
4462
4353
  id: titleId
4463
- }, children), onClose && /* @__PURE__ */ React40.createElement(Column.Block, {
4354
+ }, children), onClose && /* @__PURE__ */ React36.createElement(Column.Block, {
4464
4355
  end: true
4465
- }, /* @__PURE__ */ React40.createElement(IconButton, {
4356
+ }, /* @__PURE__ */ React36.createElement(IconButton, {
4466
4357
  variant: "ghost",
4467
4358
  icon: "ph--x--regular",
4468
4359
  iconOnly: true,
@@ -4473,11 +4364,11 @@ var MessageTitle = /* @__PURE__ */ forwardRef28(({ classNames, children, icon: i
4473
4364
  });
4474
4365
  MessageTitle.displayName = MESSAGE_TITLE_NAME;
4475
4366
  var MESSAGE_CONTENT_NAME = "Message.Content";
4476
- var MessageContent = /* @__PURE__ */ forwardRef28(({ asChild, classNames, children, ...props }, forwardedRef) => {
4367
+ var MessageContent = /* @__PURE__ */ forwardRef26(({ asChild, classNames, children, ...props }, forwardedRef) => {
4477
4368
  const { tx } = useThemeContext();
4478
4369
  const { descriptionId } = useMessageContext(MESSAGE_CONTENT_NAME);
4479
- const Comp = asChild ? Slot17 : Primitive17.p;
4480
- return /* @__PURE__ */ React40.createElement(Comp, {
4370
+ const Comp = asChild ? Slot15 : Primitive15.p;
4371
+ return /* @__PURE__ */ React36.createElement(Comp, {
4481
4372
  ...props,
4482
4373
  className: tx("message.content", {}, classNames),
4483
4374
  id: descriptionId,
@@ -4493,16 +4384,16 @@ var Message = {
4493
4384
  var Callout = Message;
4494
4385
 
4495
4386
  // src/components/Panel/Panel.tsx
4496
- import { Primitive as Primitive18 } from "@radix-ui/react-primitive";
4497
- import { Slot as Slot18 } from "@radix-ui/react-slot";
4498
- import React41 from "react";
4387
+ import { Primitive as Primitive16 } from "@radix-ui/react-primitive";
4388
+ import { Slot as Slot16 } from "@radix-ui/react-slot";
4389
+ import React37 from "react";
4499
4390
  var GRID_TEMPLATE_ROWS = "auto 1fr auto";
4500
4391
  var GRID_TEMPLATE_AREAS = '"toolbar" "content" "statusbar"';
4501
4392
  var PanelRoot = slottable(({ children, asChild, role, style, ...props }, forwardedRef) => {
4502
4393
  const { className, ...rest } = composableProps(props);
4503
- const Comp = asChild ? Slot18 : Primitive18.div;
4394
+ const Comp = asChild ? Slot16 : Primitive16.div;
4504
4395
  const { tx } = useThemeContext();
4505
- return /* @__PURE__ */ React41.createElement(Comp, {
4396
+ return /* @__PURE__ */ React37.createElement(Comp, {
4506
4397
  ...rest,
4507
4398
  role: role ?? "none",
4508
4399
  style: {
@@ -4517,9 +4408,9 @@ var PanelRoot = slottable(({ children, asChild, role, style, ...props }, forward
4517
4408
  PanelRoot.displayName = "Panel.Root";
4518
4409
  var PanelToolbar = slottable(({ children, asChild, size, ...props }, forwardedRef) => {
4519
4410
  const { className, ...rest } = composableProps(props);
4520
- const Comp = asChild ? Slot18 : Primitive18.div;
4411
+ const Comp = asChild ? Slot16 : Primitive16.div;
4521
4412
  const { tx } = useThemeContext();
4522
- return /* @__PURE__ */ React41.createElement(Comp, {
4413
+ return /* @__PURE__ */ React37.createElement(Comp, {
4523
4414
  ...rest,
4524
4415
  "data-slot": "toolbar",
4525
4416
  className: tx("panel.toolbar", {
@@ -4531,9 +4422,9 @@ var PanelToolbar = slottable(({ children, asChild, size, ...props }, forwardedRe
4531
4422
  PanelToolbar.displayName = "Panel.Toolbar";
4532
4423
  var PanelContent = slottable(({ children, asChild, ...props }, forwardedRef) => {
4533
4424
  const { className, ...rest } = composableProps(props);
4534
- const Comp = asChild ? Slot18 : Primitive18.div;
4425
+ const Comp = asChild ? Slot16 : Primitive16.div;
4535
4426
  const { tx } = useThemeContext();
4536
- return /* @__PURE__ */ React41.createElement(Comp, {
4427
+ return /* @__PURE__ */ React37.createElement(Comp, {
4537
4428
  ...rest,
4538
4429
  "data-slot": "content",
4539
4430
  className: tx("panel.content", {}, className),
@@ -4543,9 +4434,9 @@ var PanelContent = slottable(({ children, asChild, ...props }, forwardedRef) =>
4543
4434
  PanelContent.displayName = "Panel.Content";
4544
4435
  var PanelStatusbar = slottable(({ children, asChild, size, ...props }, forwardedRef) => {
4545
4436
  const { className, ...rest } = composableProps(props);
4546
- const Comp = asChild ? Slot18 : Primitive18.div;
4437
+ const Comp = asChild ? Slot16 : Primitive16.div;
4547
4438
  const { tx } = useThemeContext();
4548
- return /* @__PURE__ */ React41.createElement(Comp, {
4439
+ return /* @__PURE__ */ React37.createElement(Comp, {
4549
4440
  ...rest,
4550
4441
  "data-slot": "statusbar",
4551
4442
  className: tx("panel.statusbar", {
@@ -4564,9 +4455,9 @@ var Panel = {
4564
4455
 
4565
4456
  // src/components/ScrollArea/ScrollArea.tsx
4566
4457
  import { createContext as createContext12 } from "@radix-ui/react-context";
4567
- import { Primitive as Primitive19 } from "@radix-ui/react-primitive";
4568
- import { Slot as Slot19 } from "@radix-ui/react-slot";
4569
- import React42, { useMemo as useMemo7 } from "react";
4458
+ import { Primitive as Primitive17 } from "@radix-ui/react-primitive";
4459
+ import { Slot as Slot17 } from "@radix-ui/react-slot";
4460
+ import React38, { useMemo as useMemo7 } from "react";
4570
4461
 
4571
4462
  // src/components/ScrollArea/scrollbar.ts
4572
4463
  var scrollbar = {
@@ -4588,13 +4479,14 @@ var scrollbar = {
4588
4479
  var SCROLLAREA_NAME = "ScrollArea";
4589
4480
  var [ScrollAreaProvider, useScrollAreaContext] = createContext12(SCROLLAREA_NAME);
4590
4481
  var SCROLLAREA_ROOT_NAME = "ScrollArea.Root";
4591
- var ScrollAreaRoot = slottable(({ children, asChild, orientation = "vertical", autoHide = true, centered = false, padding = false, thin = false, snap = false, ...props }, forwardedRef) => {
4482
+ var ScrollAreaRoot = slottable(({ children, asChild, orientation = "vertical", autoHide = true, scrollbars = true, centered = false, padding = false, thin = false, snap = false, ...props }, forwardedRef) => {
4592
4483
  const { tx } = useThemeContext();
4593
4484
  const { className, ...rest } = composableProps(props);
4594
- const Comp = asChild ? Slot19 : Primitive19.div;
4485
+ const Comp = asChild ? Slot17 : Primitive17.div;
4595
4486
  const options = useMemo7(() => ({
4596
4487
  orientation,
4597
4488
  autoHide,
4489
+ scrollbars,
4598
4490
  centered,
4599
4491
  padding,
4600
4492
  thin,
@@ -4602,12 +4494,13 @@ var ScrollAreaRoot = slottable(({ children, asChild, orientation = "vertical", a
4602
4494
  }), [
4603
4495
  orientation,
4604
4496
  autoHide,
4497
+ scrollbars,
4605
4498
  centered,
4606
4499
  padding,
4607
4500
  thin,
4608
4501
  snap
4609
4502
  ]);
4610
- return /* @__PURE__ */ React42.createElement(ScrollAreaProvider, options, /* @__PURE__ */ React42.createElement(Comp, {
4503
+ return /* @__PURE__ */ React38.createElement(ScrollAreaProvider, options, /* @__PURE__ */ React38.createElement(Comp, {
4611
4504
  ...rest,
4612
4505
  className: tx("scrollArea.root", options, className),
4613
4506
  ref: forwardedRef
@@ -4621,12 +4514,12 @@ var ScrollAreaViewport = slottable(({ children, asChild, ...props }, forwardedRe
4621
4514
  const density = options.thin ? scrollbar.md : scrollbar.lg;
4622
4515
  const { className, ...rest } = composableProps(props);
4623
4516
  const { style, ...restWithoutStyle } = rest;
4624
- const Comp = asChild ? Slot19 : Primitive19.div;
4625
- return /* @__PURE__ */ React42.createElement(Comp, {
4517
+ const Comp = asChild ? Slot17 : Primitive17.div;
4518
+ return /* @__PURE__ */ React38.createElement(Comp, {
4626
4519
  ...restWithoutStyle,
4627
4520
  style: {
4628
- "--scroll-width": `${density.size}px`,
4629
- "--scroll-padding": `${density.padding}px`,
4521
+ "--scroll-width": options.scrollbars ? `${density.size}px` : "0px",
4522
+ "--scroll-padding": options.scrollbars ? `${density.padding}px` : "0px",
4630
4523
  ...style
4631
4524
  },
4632
4525
  className: tx("scrollArea.viewport", options, className),
@@ -4641,23 +4534,23 @@ var ScrollArea = {
4641
4534
 
4642
4535
  // src/components/ScrollContainer/ScrollContainer.tsx
4643
4536
  import { createContext as createContext13 } from "@radix-ui/react-context";
4644
- import React43, { forwardRef as forwardRef29, useCallback as useCallback16, useEffect as useEffect9, useImperativeHandle, useMemo as useMemo8, useRef as useRef8, useState as useState15 } from "react";
4537
+ import React39, { forwardRef as forwardRef27, useCallback as useCallback17, useEffect as useEffect9, useImperativeHandle, useMemo as useMemo8, useRef as useRef11, useState as useState15 } from "react";
4645
4538
  import { addEventListener as addEventListener2, combine } from "@dxos/async";
4646
4539
  import { invariant } from "@dxos/invariant";
4647
4540
  import { useMergeRefs } from "@dxos/react-hooks";
4648
- import { mx as mx12 } from "@dxos/ui-theme";
4541
+ import { mx as mx11 } from "@dxos/ui-theme";
4649
4542
  var __dxlog_file3 = "/__w/dxos/dxos/packages/ui/react-ui/src/components/ScrollContainer/ScrollContainer.tsx";
4650
4543
  var isBottom = (el) => {
4651
4544
  return !!(el && el.scrollHeight - el.scrollTop === el.clientHeight);
4652
4545
  };
4653
4546
  var [ScrollContainerProvider, useScrollContainerContext] = createContext13("ScrollContainer");
4654
- var ScrollContainerRoot = /* @__PURE__ */ forwardRef29(({ children, pin, behavior: behaviorProp = "smooth" }, forwardedRef) => {
4655
- const scrollerRef = useRef8(null);
4656
- const autoScrollRef = useRef8(false);
4547
+ var ScrollContainerRoot = /* @__PURE__ */ forwardRef27(({ children, pin, behavior: behaviorProp = "smooth" }, forwardedRef) => {
4548
+ const scrollerRef = useRef11(null);
4549
+ const autoScrollRef = useRef11(false);
4657
4550
  const [pinned, setPinned] = useState15(pin);
4658
4551
  const [overflow, setOverflow] = useState15(false);
4659
- const timeoutRef = useRef8(void 0);
4660
- const scrollToBottom = useCallback16((behavior = behaviorProp) => {
4552
+ const timeoutRef = useRef11(void 0);
4553
+ const scrollToBottom = useCallback17((behavior = behaviorProp) => {
4661
4554
  if (scrollerRef.current) {
4662
4555
  if (behavior !== "instant") {
4663
4556
  autoScrollRef.current = true;
@@ -4698,10 +4591,10 @@ var ScrollContainerRoot = /* @__PURE__ */ forwardRef29(({ children, pin, behavio
4698
4591
  useImperativeHandle(forwardedRef, () => controller, [
4699
4592
  controller
4700
4593
  ]);
4701
- const setViewport = useCallback16((el) => {
4594
+ const setViewport = useCallback17((el) => {
4702
4595
  scrollerRef.current = el;
4703
4596
  }, []);
4704
- return /* @__PURE__ */ React43.createElement(ScrollContainerProvider, {
4597
+ return /* @__PURE__ */ React39.createElement(ScrollContainerProvider, {
4705
4598
  pinned,
4706
4599
  overflow,
4707
4600
  controller,
@@ -4712,7 +4605,7 @@ var ScrollContainerRoot = /* @__PURE__ */ forwardRef29(({ children, pin, behavio
4712
4605
  });
4713
4606
  ScrollContainerRoot.displayName = "ScrollContainer.Root";
4714
4607
  var ScrollContainerContent = composable(({ children, thin, padding, centered, ...props }, forwardedRef) => {
4715
- return /* @__PURE__ */ React43.createElement(ScrollArea.Root, {
4608
+ return /* @__PURE__ */ React39.createElement(ScrollArea.Root, {
4716
4609
  ...composableProps(props, {
4717
4610
  classNames: "relative isolate"
4718
4611
  }),
@@ -4725,7 +4618,7 @@ var ScrollContainerContent = composable(({ children, thin, padding, centered, ..
4725
4618
  ScrollContainerContent.displayName = "ScrollContainer.Content";
4726
4619
  var VIEWPORT_NAME = "ScrollContainer.Viewport";
4727
4620
  var ScrollContainerViewport = slottable(({ children, asChild, ...props }, forwardedRef) => {
4728
- const scrollerRef = useRef8(null);
4621
+ const scrollerRef = useRef11(null);
4729
4622
  const mergedRef = useMergeRefs([
4730
4623
  forwardedRef,
4731
4624
  scrollerRef
@@ -4743,11 +4636,11 @@ var ScrollContainerViewport = slottable(({ children, asChild, ...props }, forwar
4743
4636
  setPinned,
4744
4637
  setOverflow
4745
4638
  ]);
4746
- return /* @__PURE__ */ React43.createElement(React43.Fragment, null, /* @__PURE__ */ React43.createElement(ScrollArea.Viewport, {
4639
+ return /* @__PURE__ */ React39.createElement(React39.Fragment, null, /* @__PURE__ */ React39.createElement(ScrollArea.Viewport, {
4747
4640
  asChild,
4748
4641
  ...composableProps(props),
4749
4642
  ref: mergedRef
4750
- }, children), /* @__PURE__ */ React43.createElement(ScrollContainerPinEffect, {
4643
+ }, children), /* @__PURE__ */ React39.createElement(ScrollContainerPinEffect, {
4751
4644
  scrollerRef
4752
4645
  }));
4753
4646
  });
@@ -4792,9 +4685,9 @@ var ScrollContainerPinEffect = ({ scrollerRef }) => {
4792
4685
  var FADE_NAME = "ScrollContainer.Fade";
4793
4686
  function ScrollContainerFade() {
4794
4687
  const { overflow } = useScrollContainerContext(FADE_NAME);
4795
- return /* @__PURE__ */ React43.createElement("div", {
4688
+ return /* @__PURE__ */ React39.createElement("div", {
4796
4689
  "data-visible": overflow,
4797
- className: mx12(
4690
+ className: mx11(
4798
4691
  // NOTE: Gradients may not be visible with dark reader extensions.
4799
4692
  "z-10 absolute top-0 inset-x-0 h-24 w-full",
4800
4693
  'opacity-0 duration-200 transition-opacity data-[visible="true"]:opacity-100',
@@ -4806,9 +4699,9 @@ ScrollContainerFade.displayName = FADE_NAME;
4806
4699
  var SCROLL_DOWN_BUTTON_NAME = "ScrollContainer.ScrollDownButton";
4807
4700
  function ScrollContainerScrollDownButton({ classNames }) {
4808
4701
  const { pinned, controller } = useScrollContainerContext(SCROLL_DOWN_BUTTON_NAME);
4809
- return /* @__PURE__ */ React43.createElement("div", {
4810
- className: mx12("absolute bottom-2 right-4 opacity-100 transition-opacity duration-300", pinned && "opacity-0", classNames)
4811
- }, /* @__PURE__ */ React43.createElement(IconButton, {
4702
+ return /* @__PURE__ */ React39.createElement("div", {
4703
+ className: mx11("absolute bottom-2 right-4 opacity-100 transition-opacity duration-300", pinned && "opacity-0", classNames)
4704
+ }, /* @__PURE__ */ React39.createElement(IconButton, {
4812
4705
  variant: "primary",
4813
4706
  icon: "ph--arrow-down--regular",
4814
4707
  iconOnly: true,
@@ -4828,35 +4721,35 @@ var ScrollContainer = {
4828
4721
 
4829
4722
  // src/components/Select/Select.tsx
4830
4723
  import * as SelectPrimitive from "@radix-ui/react-select";
4831
- import React44, { forwardRef as forwardRef30 } from "react";
4724
+ import React40, { forwardRef as forwardRef28 } from "react";
4832
4725
  var SelectRoot = SelectPrimitive.Root;
4833
4726
  var SelectTrigger = SelectPrimitive.Trigger;
4834
4727
  var SelectValue = SelectPrimitive.Value;
4835
4728
  var SelectIcon = SelectPrimitive.Icon;
4836
4729
  var SelectPortal = SelectPrimitive.Portal;
4837
- var SelectTriggerButton = /* @__PURE__ */ forwardRef30(({ children, placeholder, classNames, ...props }, forwardedRef) => {
4730
+ var SelectTriggerButton = /* @__PURE__ */ forwardRef28(({ children, placeholder, classNames, ...props }, forwardedRef) => {
4838
4731
  const { tx } = useThemeContext();
4839
- return /* @__PURE__ */ React44.createElement(SelectPrimitive.Trigger, {
4732
+ return /* @__PURE__ */ React40.createElement(SelectPrimitive.Trigger, {
4840
4733
  asChild: true,
4841
4734
  ref: forwardedRef
4842
- }, /* @__PURE__ */ React44.createElement(Button, {
4735
+ }, /* @__PURE__ */ React40.createElement(Button, {
4843
4736
  ...props,
4844
4737
  classNames: tx("select.triggerButton", {}, classNames)
4845
- }, /* @__PURE__ */ React44.createElement(SelectPrimitive.Value, {
4738
+ }, /* @__PURE__ */ React40.createElement(SelectPrimitive.Value, {
4846
4739
  placeholder
4847
- }, children), /* @__PURE__ */ React44.createElement(SelectPrimitive.Icon, {
4740
+ }, children), /* @__PURE__ */ React40.createElement(SelectPrimitive.Icon, {
4848
4741
  asChild: true
4849
- }, /* @__PURE__ */ React44.createElement(Icon, {
4742
+ }, /* @__PURE__ */ React40.createElement(Icon, {
4850
4743
  size: 3,
4851
4744
  icon: "ph--caret-down--bold"
4852
4745
  }))));
4853
4746
  });
4854
4747
  SelectTriggerButton.displayName = "Select.TriggerButton";
4855
- var SelectContent = /* @__PURE__ */ forwardRef30(({ classNames, children, collisionPadding = 8, ...props }, forwardedRef) => {
4748
+ var SelectContent = /* @__PURE__ */ forwardRef28(({ classNames, children, collisionPadding = 8, ...props }, forwardedRef) => {
4856
4749
  const { tx } = useThemeContext();
4857
4750
  const elevation = useElevationContext();
4858
4751
  const safeCollisionPadding = useSafeCollisionPadding(collisionPadding);
4859
- return /* @__PURE__ */ React44.createElement(SelectPrimitive.Content, {
4752
+ return /* @__PURE__ */ React40.createElement(SelectPrimitive.Content, {
4860
4753
  ...props,
4861
4754
  "data-arrow-keys": "up down",
4862
4755
  collisionPadding: safeCollisionPadding,
@@ -4868,42 +4761,42 @@ var SelectContent = /* @__PURE__ */ forwardRef30(({ classNames, children, collis
4868
4761
  }, children);
4869
4762
  });
4870
4763
  SelectContent.displayName = "Select.Content";
4871
- var SelectScrollUpButton2 = /* @__PURE__ */ forwardRef30(({ classNames, children, ...props }, forwardedRef) => {
4764
+ var SelectScrollUpButton2 = /* @__PURE__ */ forwardRef28(({ classNames, children, ...props }, forwardedRef) => {
4872
4765
  const { tx } = useThemeContext();
4873
- return /* @__PURE__ */ React44.createElement(SelectPrimitive.SelectScrollUpButton, {
4766
+ return /* @__PURE__ */ React40.createElement(SelectPrimitive.SelectScrollUpButton, {
4874
4767
  ...props,
4875
4768
  className: tx("select.scrollButton", {}, classNames),
4876
4769
  ref: forwardedRef
4877
- }, children ?? /* @__PURE__ */ React44.createElement(Icon, {
4770
+ }, children ?? /* @__PURE__ */ React40.createElement(Icon, {
4878
4771
  size: 3,
4879
4772
  icon: "ph--caret-up--bold"
4880
4773
  }));
4881
4774
  });
4882
4775
  SelectScrollUpButton2.displayName = "Select.ScrollUpButton";
4883
- var SelectScrollDownButton2 = /* @__PURE__ */ forwardRef30(({ classNames, children, ...props }, forwardedRef) => {
4776
+ var SelectScrollDownButton2 = /* @__PURE__ */ forwardRef28(({ classNames, children, ...props }, forwardedRef) => {
4884
4777
  const { tx } = useThemeContext();
4885
- return /* @__PURE__ */ React44.createElement(SelectPrimitive.SelectScrollDownButton, {
4778
+ return /* @__PURE__ */ React40.createElement(SelectPrimitive.SelectScrollDownButton, {
4886
4779
  ...props,
4887
4780
  className: tx("select.scrollButton", {}, classNames),
4888
4781
  ref: forwardedRef
4889
- }, children ?? /* @__PURE__ */ React44.createElement(Icon, {
4782
+ }, children ?? /* @__PURE__ */ React40.createElement(Icon, {
4890
4783
  size: 3,
4891
4784
  icon: "ph--caret-down--bold"
4892
4785
  }));
4893
4786
  });
4894
4787
  SelectScrollDownButton2.displayName = "Select.ScrollDownButton";
4895
- var SelectViewport2 = /* @__PURE__ */ forwardRef30(({ classNames, children, ...props }, forwardedRef) => {
4788
+ var SelectViewport2 = /* @__PURE__ */ forwardRef28(({ classNames, children, ...props }, forwardedRef) => {
4896
4789
  const { tx } = useThemeContext();
4897
- return /* @__PURE__ */ React44.createElement(SelectPrimitive.SelectViewport, {
4790
+ return /* @__PURE__ */ React40.createElement(SelectPrimitive.SelectViewport, {
4898
4791
  ...props,
4899
4792
  className: tx("select.viewport", {}, classNames),
4900
4793
  ref: forwardedRef
4901
4794
  }, children);
4902
4795
  });
4903
4796
  SelectViewport2.displayName = "Select.Viewport";
4904
- var SelectItem = /* @__PURE__ */ forwardRef30(({ classNames, ...props }, forwardedRef) => {
4797
+ var SelectItem = /* @__PURE__ */ forwardRef28(({ classNames, ...props }, forwardedRef) => {
4905
4798
  const { tx } = useThemeContext();
4906
- return /* @__PURE__ */ React44.createElement(SelectPrimitive.Item, {
4799
+ return /* @__PURE__ */ React40.createElement(SelectPrimitive.Item, {
4907
4800
  ...props,
4908
4801
  className: tx("select.item", {}, classNames),
4909
4802
  ref: forwardedRef
@@ -4911,24 +4804,24 @@ var SelectItem = /* @__PURE__ */ forwardRef30(({ classNames, ...props }, forward
4911
4804
  });
4912
4805
  SelectItem.displayName = "Select.Item";
4913
4806
  var SelectItemText = SelectPrimitive.ItemText;
4914
- var SelectItemIndicator = /* @__PURE__ */ forwardRef30(({ classNames, children, ...props }, forwardedRef) => {
4807
+ var SelectItemIndicator = /* @__PURE__ */ forwardRef28(({ classNames, children, ...props }, forwardedRef) => {
4915
4808
  const { tx } = useThemeContext();
4916
- return /* @__PURE__ */ React44.createElement(SelectPrimitive.ItemIndicator, {
4809
+ return /* @__PURE__ */ React40.createElement(SelectPrimitive.ItemIndicator, {
4917
4810
  ...props,
4918
4811
  className: tx("select.itemIndicator", {}, classNames),
4919
4812
  ref: forwardedRef
4920
4813
  }, children);
4921
4814
  });
4922
4815
  SelectItemIndicator.displayName = "Select.ItemIndicator";
4923
- var SelectOption = /* @__PURE__ */ forwardRef30(({ children, classNames, ...props }, forwardedRef) => {
4816
+ var SelectOption = /* @__PURE__ */ forwardRef28(({ children, classNames, ...props }, forwardedRef) => {
4924
4817
  const { tx } = useThemeContext();
4925
- return /* @__PURE__ */ React44.createElement(SelectPrimitive.Item, {
4818
+ return /* @__PURE__ */ React40.createElement(SelectPrimitive.Item, {
4926
4819
  ...props,
4927
4820
  className: tx("select.item", {}, classNames),
4928
4821
  ref: forwardedRef
4929
- }, /* @__PURE__ */ React44.createElement(SelectPrimitive.ItemText, null, children), /* @__PURE__ */ React44.createElement("span", {
4822
+ }, /* @__PURE__ */ React40.createElement(SelectPrimitive.ItemText, null, children), /* @__PURE__ */ React40.createElement("span", {
4930
4823
  className: "grow"
4931
- }), /* @__PURE__ */ React44.createElement(Icon, {
4824
+ }), /* @__PURE__ */ React40.createElement(Icon, {
4932
4825
  size: 3,
4933
4826
  icon: "ph--check--regular"
4934
4827
  }));
@@ -4936,18 +4829,18 @@ var SelectOption = /* @__PURE__ */ forwardRef30(({ children, classNames, ...prop
4936
4829
  SelectOption.displayName = "Select.Option";
4937
4830
  var SelectGroup = SelectPrimitive.Group;
4938
4831
  var SelectLabel = SelectPrimitive.Label;
4939
- var SelectSeparator = /* @__PURE__ */ forwardRef30(({ classNames, ...props }, forwardedRef) => {
4832
+ var SelectSeparator = /* @__PURE__ */ forwardRef28(({ classNames, ...props }, forwardedRef) => {
4940
4833
  const { tx } = useThemeContext();
4941
- return /* @__PURE__ */ React44.createElement(SelectPrimitive.Separator, {
4834
+ return /* @__PURE__ */ React40.createElement(SelectPrimitive.Separator, {
4942
4835
  ...props,
4943
4836
  className: tx("select.separator", {}, classNames),
4944
4837
  ref: forwardedRef
4945
4838
  });
4946
4839
  });
4947
4840
  SelectSeparator.displayName = "Select.Separator";
4948
- var SelectArrow = /* @__PURE__ */ forwardRef30(({ classNames, ...props }, forwardedRef) => {
4841
+ var SelectArrow = /* @__PURE__ */ forwardRef28(({ classNames, ...props }, forwardedRef) => {
4949
4842
  const { tx } = useThemeContext();
4950
- return /* @__PURE__ */ React44.createElement(SelectPrimitive.Arrow, {
4843
+ return /* @__PURE__ */ React40.createElement(SelectPrimitive.Arrow, {
4951
4844
  ...props,
4952
4845
  className: tx("select.arrow", {}, classNames),
4953
4846
  ref: forwardedRef
@@ -4977,10 +4870,10 @@ var Select = {
4977
4870
 
4978
4871
  // src/components/Separator/Separator.tsx
4979
4872
  import * as SeparatorPrimitive from "@radix-ui/react-separator";
4980
- import React45, { forwardRef as forwardRef31 } from "react";
4981
- var Separator4 = /* @__PURE__ */ forwardRef31(({ classNames, orientation = "horizontal", subdued, ...props }, forwardedRef) => {
4873
+ import React41, { forwardRef as forwardRef29 } from "react";
4874
+ var Separator4 = /* @__PURE__ */ forwardRef29(({ classNames, orientation = "horizontal", subdued, ...props }, forwardedRef) => {
4982
4875
  const { tx } = useThemeContext();
4983
- return /* @__PURE__ */ React45.createElement(SeparatorPrimitive.Root, {
4876
+ return /* @__PURE__ */ React41.createElement(SeparatorPrimitive.Root, {
4984
4877
  ...props,
4985
4878
  orientation,
4986
4879
  className: tx("separator.root", {
@@ -4992,10 +4885,10 @@ var Separator4 = /* @__PURE__ */ forwardRef31(({ classNames, orientation = "hori
4992
4885
  });
4993
4886
 
4994
4887
  // src/components/Skeleton/Skeleton.tsx
4995
- import React46, { forwardRef as forwardRef32 } from "react";
4996
- var Skeleton = /* @__PURE__ */ forwardRef32(({ classNames, variant = "default", ...props }, forwardedRef) => {
4888
+ import React42, { forwardRef as forwardRef30 } from "react";
4889
+ var Skeleton = /* @__PURE__ */ forwardRef30(({ classNames, variant = "default", ...props }, forwardedRef) => {
4997
4890
  const { tx } = useThemeContext();
4998
- return /* @__PURE__ */ React46.createElement("div", {
4891
+ return /* @__PURE__ */ React42.createElement("div", {
4999
4892
  ...props,
5000
4893
  className: tx("skeleton.root", {
5001
4894
  variant
@@ -5005,64 +4898,278 @@ var Skeleton = /* @__PURE__ */ forwardRef32(({ classNames, variant = "default",
5005
4898
  });
5006
4899
 
5007
4900
  // src/components/Splitter/Splitter.tsx
5008
- import { createContextScope as createContextScope4 } from "@radix-ui/react-context";
5009
- import { Primitive as Primitive20 } from "@radix-ui/react-primitive";
5010
- import { Slot as Slot20 } from "@radix-ui/react-slot";
5011
- import React47 from "react";
4901
+ import { useComposedRefs as useComposedRefs4 } from "@radix-ui/react-compose-refs";
4902
+ import { createContext as createContext14 } from "@radix-ui/react-context";
4903
+ import { Primitive as Primitive18 } from "@radix-ui/react-primitive";
4904
+ import { Slot as Slot18 } from "@radix-ui/react-slot";
4905
+ import { useControllableState as useControllableState6 } from "@radix-ui/react-use-controllable-state";
4906
+ import React43, { useCallback as useCallback18, useEffect as useEffect10, useRef as useRef12, useState as useState16 } from "react";
5012
4907
  var SPLITTER_NAME = "Splitter";
5013
- var [createSplitterContext, createSplitterScope] = createContextScope4(SPLITTER_NAME);
5014
- var [SplitterProvider, useSplitterContext] = createSplitterContext(SPLITTER_NAME);
4908
+ var [SplitterProvider, useSplitterContext] = createContext14(SPLITTER_NAME);
4909
+ var getRem = () => parseFloat(getComputedStyle(document.documentElement).fontSize) || 16;
4910
+ var clampStyle = (minSize, orientation) => orientation === "horizontal" ? {
4911
+ minInlineSize: `${minSize}rem`,
4912
+ maxInlineSize: `calc(100% - ${minSize}rem)`
4913
+ } : {
4914
+ minBlockSize: `${minSize}rem`,
4915
+ maxBlockSize: `calc(100% - ${minSize}rem)`
4916
+ };
4917
+ var endMinStyle = (minSize, orientation) => orientation === "horizontal" ? {
4918
+ minInlineSize: `${minSize}rem`
4919
+ } : {
4920
+ minBlockSize: `${minSize}rem`
4921
+ };
4922
+ var panelStyle = (position, mode, anchor, size, minSize, orientation) => {
4923
+ if (mode !== "split") {
4924
+ const fills = mode === "start" && position === "start" || mode === "end" && position === "end";
4925
+ return {
4926
+ flexGrow: fills ? 1 : 0,
4927
+ flexShrink: 1,
4928
+ flexBasis: 0
4929
+ };
4930
+ }
4931
+ if (size === void 0) {
4932
+ return {
4933
+ flexGrow: 1,
4934
+ flexShrink: 1,
4935
+ flexBasis: 0,
4936
+ ...endMinStyle(minSize, orientation)
4937
+ };
4938
+ }
4939
+ return position === anchor ? {
4940
+ flexGrow: 0,
4941
+ flexShrink: 1,
4942
+ flexBasis: `${size}rem`,
4943
+ ...clampStyle(minSize, orientation)
4944
+ } : {
4945
+ flexGrow: 1,
4946
+ flexShrink: 1,
4947
+ flexBasis: 0,
4948
+ ...endMinStyle(minSize, orientation)
4949
+ };
4950
+ };
4951
+ var handlePosition = (orientation, anchor, size, minSize) => {
4952
+ if (size === void 0) {
4953
+ return orientation === "horizontal" ? {
4954
+ insetBlock: 0,
4955
+ insetInlineStart: "50%",
4956
+ transform: "translateX(-50%)"
4957
+ } : {
4958
+ insetInline: 0,
4959
+ insetBlockStart: "50%",
4960
+ transform: "translateY(-50%)"
4961
+ };
4962
+ }
4963
+ const offset = `clamp(${minSize}rem, ${size}rem, calc(100% - ${minSize}rem))`;
4964
+ if (orientation === "horizontal") {
4965
+ return anchor === "end" ? {
4966
+ insetBlock: 0,
4967
+ insetInlineEnd: offset,
4968
+ transform: "translateX(50%)"
4969
+ } : {
4970
+ insetBlock: 0,
4971
+ insetInlineStart: offset,
4972
+ transform: "translateX(-50%)"
4973
+ };
4974
+ }
4975
+ return anchor === "end" ? {
4976
+ insetInline: 0,
4977
+ insetBlockEnd: offset,
4978
+ transform: "translateY(50%)"
4979
+ } : {
4980
+ insetInline: 0,
4981
+ insetBlockStart: offset,
4982
+ transform: "translateY(-50%)"
4983
+ };
4984
+ };
5015
4985
  var ROOT_NAME = "Splitter.Root";
5016
- var SplitterRoot = slottable(({ asChild, mode = "top", ratio = 0.5, transition = 250, children, ...props }, forwardedRef) => {
4986
+ var SplitterRoot = slottable(({ asChild, children, orientation = "vertical", mode = "split", anchor = "start", size: sizeProp, defaultSize, onSizeChange, transition = 250, resizable = false, minSize = 0, ...props }, forwardedRef) => {
5017
4987
  const { tx } = useThemeContext();
5018
- const { __scopeSplitter, ...rest } = props;
5019
- const { className, ...restProps } = composableProps(rest);
5020
- const Comp = asChild ? Slot20 : Primitive20.div;
5021
- return /* @__PURE__ */ React47.createElement(SplitterProvider, {
5022
- scope: __scopeSplitter,
4988
+ const rootRef = useRef12(null);
4989
+ const composedRef = useComposedRefs4(forwardedRef, rootRef);
4990
+ const [size, setSize] = useControllableState6({
4991
+ prop: sizeProp,
4992
+ defaultProp: defaultSize,
4993
+ onChange: onSizeChange
4994
+ });
4995
+ const [dragging, setDragging] = useState16(false);
4996
+ const [animating, setAnimating] = useState16(false);
4997
+ const previousMode = useRef12(mode);
4998
+ useEffect10(() => {
4999
+ if (previousMode.current === mode) {
5000
+ return;
5001
+ }
5002
+ previousMode.current = mode;
5003
+ if (transition <= 0) {
5004
+ return;
5005
+ }
5006
+ setAnimating(true);
5007
+ const timer = setTimeout(() => setAnimating(false), transition);
5008
+ return () => clearTimeout(timer);
5009
+ }, [
5023
5010
  mode,
5024
- ratio,
5025
5011
  transition
5026
- }, /* @__PURE__ */ React47.createElement(Comp, {
5027
- ...restProps,
5028
- ref: forwardedRef,
5029
- className: tx("splitter.root", {}, className)
5012
+ ]);
5013
+ const { className, ...rest } = composableProps(props);
5014
+ const Comp = asChild ? Slot18 : Primitive18.div;
5015
+ return /* @__PURE__ */ React43.createElement(SplitterProvider, {
5016
+ orientation,
5017
+ mode,
5018
+ anchor,
5019
+ size,
5020
+ transition,
5021
+ resizable,
5022
+ minSize,
5023
+ animating,
5024
+ dragging,
5025
+ rootRef,
5026
+ setSize,
5027
+ setDragging
5028
+ }, /* @__PURE__ */ React43.createElement(Comp, {
5029
+ ...rest,
5030
+ ref: composedRef,
5031
+ className: tx("splitter.root", {
5032
+ orientation
5033
+ }, className)
5030
5034
  }, children));
5031
5035
  });
5032
5036
  SplitterRoot.displayName = ROOT_NAME;
5033
5037
  var PANEL_NAME = "Splitter.Panel";
5034
- var SplitterPanel = slottable(({ classNames, asChild, children, position, style, ...props }, forwardedRef) => {
5038
+ var SplitterPanel = slottable(({ asChild, children, position, ...props }, forwardedRef) => {
5035
5039
  const { tx } = useThemeContext();
5036
- const { __scopeSplitter, ...rest } = props;
5037
- const Comp = asChild ? Slot20 : Primitive20.div;
5038
- const { mode, ratio = 0.5, transition } = useSplitterContext(PANEL_NAME, __scopeSplitter);
5039
- const { className, ...restProps } = composableProps(rest);
5040
- const isTopPanel = position === "top";
5041
- const topOffset = isTopPanel ? "0%" : mode === "top" ? "100%" : mode === "bottom" ? "0%" : `${ratio * 100}%`;
5042
- const height = isTopPanel ? mode === "top" ? "100%" : mode === "bottom" ? "0%" : `${ratio * 100}%` : mode === "bottom" ? "100%" : mode === "top" ? "0%" : `${(1 - ratio) * 100}%`;
5043
- return /* @__PURE__ */ React47.createElement(Comp, {
5044
- ...restProps,
5040
+ const { orientation, mode, anchor, size, minSize, transition, dragging, animating } = useSplitterContext(PANEL_NAME);
5041
+ const { className, style, ...rest } = composableProps(props);
5042
+ const Comp = asChild ? Slot18 : Primitive18.div;
5043
+ const animate = transition > 0 && animating && !dragging;
5044
+ return /* @__PURE__ */ React43.createElement(Comp, {
5045
+ ...rest,
5045
5046
  ref: forwardedRef,
5046
5047
  className: tx("splitter.panel", {}, className),
5047
5048
  style: {
5048
- top: topOffset,
5049
- height,
5050
- transition: `top ${transition}ms, height ${transition}ms ease-out`,
5049
+ ...panelStyle(position, mode, anchor, size, minSize, orientation),
5050
+ transition: animate ? `flex-grow ${transition}ms ease-out, flex-basis ${transition}ms ease-out` : void 0,
5051
5051
  ...style
5052
5052
  }
5053
5053
  }, children);
5054
5054
  });
5055
5055
  SplitterPanel.displayName = PANEL_NAME;
5056
+ var HANDLE_NAME = "Splitter.Handle";
5057
+ var SplitterHandle = slottable(({ asChild, children, ...props }, forwardedRef) => {
5058
+ const { tx } = useThemeContext();
5059
+ const { orientation, anchor, size, resizable, minSize, rootRef, setSize, setDragging } = useSplitterContext(HANDLE_NAME);
5060
+ const { className, ...rest } = composableProps(props);
5061
+ const Comp = asChild ? Slot18 : Primitive18.div;
5062
+ const extentRem = useCallback18(() => {
5063
+ const rect = rootRef.current?.getBoundingClientRect();
5064
+ if (!rect) {
5065
+ return (size ?? minSize) + minSize;
5066
+ }
5067
+ return (orientation === "horizontal" ? rect.width : rect.height) / getRem();
5068
+ }, [
5069
+ orientation,
5070
+ rootRef,
5071
+ size,
5072
+ minSize
5073
+ ]);
5074
+ const handlePointerDown = useCallback18((event) => {
5075
+ if (event.button !== 0) {
5076
+ return;
5077
+ }
5078
+ event.preventDefault();
5079
+ event.currentTarget.setPointerCapture(event.pointerId);
5080
+ setDragging(true);
5081
+ }, [
5082
+ setDragging
5083
+ ]);
5084
+ const handlePointerMove = useCallback18((event) => {
5085
+ if (!event.currentTarget.hasPointerCapture(event.pointerId)) {
5086
+ return;
5087
+ }
5088
+ const root = rootRef.current;
5089
+ if (!root) {
5090
+ return;
5091
+ }
5092
+ const rect = root.getBoundingClientRect();
5093
+ const rem = getRem();
5094
+ const offset = (orientation === "horizontal" ? event.clientX - rect.left : event.clientY - rect.top) / rem;
5095
+ const extent = (orientation === "horizontal" ? rect.width : rect.height) / rem;
5096
+ const next = anchor === "end" ? extent - offset : offset;
5097
+ setSize(Math.min(Math.max(next, minSize), Math.max(minSize, extent - minSize)));
5098
+ }, [
5099
+ orientation,
5100
+ anchor,
5101
+ minSize,
5102
+ rootRef,
5103
+ setSize
5104
+ ]);
5105
+ const handlePointerUp = useCallback18((event) => {
5106
+ if (event.currentTarget.hasPointerCapture(event.pointerId)) {
5107
+ event.currentTarget.releasePointerCapture(event.pointerId);
5108
+ }
5109
+ setDragging(false);
5110
+ }, [
5111
+ setDragging
5112
+ ]);
5113
+ const handleKeyDown = useCallback18((event) => {
5114
+ const horizontal = orientation === "horizontal";
5115
+ const step = event.shiftKey ? 4 : 1;
5116
+ const base = size ?? extentRem() / 2;
5117
+ let next;
5118
+ if (event.key === (horizontal ? "ArrowRight" : "ArrowDown")) {
5119
+ next = base + step;
5120
+ } else if (event.key === (horizontal ? "ArrowLeft" : "ArrowUp")) {
5121
+ next = base - step;
5122
+ } else if (event.key === "Home") {
5123
+ next = minSize;
5124
+ } else if (event.key === "End") {
5125
+ next = extentRem() - minSize;
5126
+ }
5127
+ if (next === void 0) {
5128
+ return;
5129
+ }
5130
+ event.preventDefault();
5131
+ setSize(Math.min(Math.max(next, minSize), Math.max(minSize, extentRem() - minSize)));
5132
+ }, [
5133
+ orientation,
5134
+ size,
5135
+ minSize,
5136
+ extentRem,
5137
+ setSize
5138
+ ]);
5139
+ if (!resizable) {
5140
+ return null;
5141
+ }
5142
+ return /* @__PURE__ */ React43.createElement(Comp, {
5143
+ ...rest,
5144
+ ref: forwardedRef,
5145
+ role: "separator",
5146
+ tabIndex: 0,
5147
+ "aria-orientation": orientation === "horizontal" ? "vertical" : "horizontal",
5148
+ "aria-valuemin": Math.round(minSize),
5149
+ "aria-valuenow": size !== void 0 ? Math.round(size) : void 0,
5150
+ className: tx("splitter.handle", {
5151
+ orientation
5152
+ }, className),
5153
+ style: handlePosition(orientation, anchor, size, minSize),
5154
+ onPointerDown: handlePointerDown,
5155
+ onPointerMove: handlePointerMove,
5156
+ onPointerUp: handlePointerUp,
5157
+ onPointerCancel: handlePointerUp,
5158
+ onKeyDown: handleKeyDown
5159
+ }, children);
5160
+ });
5161
+ SplitterHandle.displayName = HANDLE_NAME;
5056
5162
  var Splitter = {
5057
5163
  Root: SplitterRoot,
5058
- Panel: SplitterPanel
5164
+ Panel: SplitterPanel,
5165
+ Handle: SplitterHandle
5059
5166
  };
5060
5167
 
5061
5168
  // src/components/Status/Status.tsx
5062
- import React48, { forwardRef as forwardRef33 } from "react";
5063
- var Status = /* @__PURE__ */ forwardRef33(({ classNames, children, progress = 0, indeterminate, variant, ...props }, forwardedRef) => {
5169
+ import React44, { forwardRef as forwardRef31 } from "react";
5170
+ var Status = /* @__PURE__ */ forwardRef31(({ classNames, children, progress = 0, indeterminate, variant, ...props }, forwardedRef) => {
5064
5171
  const { tx } = useThemeContext();
5065
- return /* @__PURE__ */ React48.createElement("span", {
5172
+ return /* @__PURE__ */ React44.createElement("span", {
5066
5173
  role: "status",
5067
5174
  ...props,
5068
5175
  className: tx("status.root", {
@@ -5070,7 +5177,7 @@ var Status = /* @__PURE__ */ forwardRef33(({ classNames, children, progress = 0,
5070
5177
  variant
5071
5178
  }, classNames),
5072
5179
  ref: forwardedRef
5073
- }, /* @__PURE__ */ React48.createElement("span", {
5180
+ }, /* @__PURE__ */ React44.createElement("span", {
5074
5181
  role: "none",
5075
5182
  className: tx("status.bar", {
5076
5183
  indeterminate,
@@ -5085,65 +5192,65 @@ var Status = /* @__PURE__ */ forwardRef33(({ classNames, children, progress = 0,
5085
5192
  });
5086
5193
 
5087
5194
  // src/components/Tag/Tag.tsx
5088
- import { Primitive as Primitive21 } from "@radix-ui/react-primitive";
5089
- import { Slot as Slot21 } from "@radix-ui/react-slot";
5090
- import React49, { forwardRef as forwardRef34 } from "react";
5091
- var Tag = /* @__PURE__ */ forwardRef34(({ asChild, palette = "neutral", classNames, ...props }, forwardedRef) => {
5195
+ import { Primitive as Primitive19 } from "@radix-ui/react-primitive";
5196
+ import { Slot as Slot19 } from "@radix-ui/react-slot";
5197
+ import React45, { forwardRef as forwardRef32 } from "react";
5198
+ var Tag = /* @__PURE__ */ forwardRef32(({ asChild, hue = "neutral", classNames, ...props }, forwardedRef) => {
5092
5199
  const { tx } = useThemeContext();
5093
- const Comp = asChild ? Slot21 : Primitive21.span;
5094
- return /* @__PURE__ */ React49.createElement(Comp, {
5200
+ const Comp = asChild ? Slot19 : Primitive19.span;
5201
+ return /* @__PURE__ */ React45.createElement(Comp, {
5095
5202
  ...props,
5096
5203
  className: tx("tag.root", {
5097
- palette
5204
+ hue
5098
5205
  }, classNames),
5099
- "data-hue": palette,
5206
+ "data-hue": hue,
5100
5207
  ref: forwardedRef
5101
5208
  });
5102
5209
  });
5103
5210
 
5104
5211
  // src/components/Toast/Toast.tsx
5105
5212
  import * as ToastPrimitive from "@radix-ui/react-toast";
5106
- import React50, { forwardRef as forwardRef35 } from "react";
5213
+ import React46, { forwardRef as forwardRef33 } from "react";
5107
5214
  import { useTranslation as useTranslation7 } from "react-i18next";
5108
5215
  import { translationKey as translationKey7 } from "#translations";
5109
5216
  var ToastProvider = ToastPrimitive.Provider;
5110
- var ToastViewport = /* @__PURE__ */ forwardRef35(({ classNames, ...props }, forwardedRef) => {
5217
+ var ToastViewport = /* @__PURE__ */ forwardRef33(({ classNames, ...props }, forwardedRef) => {
5111
5218
  const { tx } = useThemeContext();
5112
- return /* @__PURE__ */ React50.createElement(ToastPrimitive.Viewport, {
5219
+ return /* @__PURE__ */ React46.createElement(ToastPrimitive.Viewport, {
5113
5220
  ...props,
5114
5221
  className: tx("toast.viewport", {}, classNames),
5115
5222
  ref: forwardedRef
5116
5223
  });
5117
5224
  });
5118
5225
  ToastViewport.displayName = "Toast.Viewport";
5119
- var ToastRoot = /* @__PURE__ */ forwardRef35(({ classNames, children, ...props }, forwardedRef) => {
5226
+ var ToastRoot = /* @__PURE__ */ forwardRef33(({ classNames, children, ...props }, forwardedRef) => {
5120
5227
  const { tx } = useThemeContext();
5121
- return /* @__PURE__ */ React50.createElement(ToastPrimitive.Root, {
5228
+ return /* @__PURE__ */ React46.createElement(ToastPrimitive.Root, {
5122
5229
  ...props,
5123
5230
  className: tx("toast.root", {}, classNames),
5124
5231
  ref: forwardedRef
5125
- }, /* @__PURE__ */ React50.createElement(ElevationProvider, {
5232
+ }, /* @__PURE__ */ React46.createElement(ElevationProvider, {
5126
5233
  elevation: "toast"
5127
- }, /* @__PURE__ */ React50.createElement(Column.Root, {
5234
+ }, /* @__PURE__ */ React46.createElement(Column.Root, {
5128
5235
  classNames: tx("toast.grid", {})
5129
5236
  }, children)));
5130
5237
  });
5131
5238
  ToastRoot.displayName = "Toast.Root";
5132
- var ToastTitle = /* @__PURE__ */ forwardRef35(({ classNames, children, icon, onClose, ...props }, forwardedRef) => {
5239
+ var ToastTitle = /* @__PURE__ */ forwardRef33(({ classNames, children, icon, onClose, ...props }, forwardedRef) => {
5133
5240
  const { t } = useTranslation7(translationKey7);
5134
5241
  const { tx } = useThemeContext();
5135
- return /* @__PURE__ */ React50.createElement(Column.Row, {
5242
+ return /* @__PURE__ */ React46.createElement(Column.Row, {
5136
5243
  classNames: tx("toast.header", {})
5137
- }, icon && /* @__PURE__ */ React50.createElement(Column.Block, null, /* @__PURE__ */ React50.createElement(Icon, {
5244
+ }, icon && /* @__PURE__ */ React46.createElement(Column.Block, null, /* @__PURE__ */ React46.createElement(Icon, {
5138
5245
  icon,
5139
5246
  size: 5
5140
- })), /* @__PURE__ */ React50.createElement(ToastPrimitive.Title, {
5247
+ })), /* @__PURE__ */ React46.createElement(ToastPrimitive.Title, {
5141
5248
  ...props,
5142
5249
  className: tx("toast.title", {}, classNames),
5143
5250
  ref: forwardedRef
5144
- }, children), onClose && /* @__PURE__ */ React50.createElement(Column.Block, {
5251
+ }, children), onClose && /* @__PURE__ */ React46.createElement(Column.Block, {
5145
5252
  end: true
5146
- }, /* @__PURE__ */ React50.createElement(IconButton, {
5253
+ }, /* @__PURE__ */ React46.createElement(IconButton, {
5147
5254
  variant: "ghost",
5148
5255
  icon: "ph--x--regular",
5149
5256
  iconOnly: true,
@@ -5152,22 +5259,22 @@ var ToastTitle = /* @__PURE__ */ forwardRef35(({ classNames, children, icon, onC
5152
5259
  })));
5153
5260
  });
5154
5261
  ToastTitle.displayName = "Toast.Title";
5155
- var ToastDescription = /* @__PURE__ */ forwardRef35(({ classNames, children, ...props }, forwardedRef) => {
5262
+ var ToastDescription = /* @__PURE__ */ forwardRef33(({ classNames, children, ...props }, forwardedRef) => {
5156
5263
  const { tx } = useThemeContext();
5157
- return /* @__PURE__ */ React50.createElement(ToastPrimitive.Description, {
5264
+ return /* @__PURE__ */ React46.createElement(ToastPrimitive.Description, {
5158
5265
  ...props,
5159
5266
  className: tx("toast.description", {}, classNames),
5160
5267
  ref: forwardedRef
5161
5268
  }, children);
5162
5269
  });
5163
5270
  ToastDescription.displayName = "Toast.Description";
5164
- var ToastActions = /* @__PURE__ */ forwardRef35(({ classNames, children, ...props }, forwardedRef) => {
5271
+ var ToastActions = /* @__PURE__ */ forwardRef33(({ classNames, children, ...props }, forwardedRef) => {
5165
5272
  const { tx } = useThemeContext();
5166
- return /* @__PURE__ */ React50.createElement(Column.Center, {
5273
+ return /* @__PURE__ */ React46.createElement(Column.Center, {
5167
5274
  classNames: tx("toast.actions", {}, classNames),
5168
5275
  ref: forwardedRef,
5169
5276
  ...props
5170
- }, /* @__PURE__ */ React50.createElement(DensityProvider, {
5277
+ }, /* @__PURE__ */ React46.createElement(DensityProvider, {
5171
5278
  density: "sm"
5172
5279
  }, children));
5173
5280
  });
@@ -5186,16 +5293,16 @@ var Toast = {
5186
5293
  };
5187
5294
 
5188
5295
  // src/components/Toolbar/Toolbar.tsx
5189
- import { Primitive as Primitive22 } from "@radix-ui/react-primitive";
5190
- import { Slot as Slot22 } from "@radix-ui/react-slot";
5296
+ import { Primitive as Primitive20 } from "@radix-ui/react-primitive";
5297
+ import { Slot as Slot20 } from "@radix-ui/react-slot";
5191
5298
  import * as ToolbarPrimitive from "@radix-ui/react-toolbar";
5192
- import React51, { forwardRef as forwardRef36 } from "react";
5299
+ import React47, { forwardRef as forwardRef34 } from "react";
5193
5300
  import { useTranslation as useTranslation8 } from "react-i18next";
5194
5301
  import { translationKey as translationKey8 } from "#translations";
5195
5302
  var ToolbarRoot = composable(({ children, density, disabled, layoutManaged, orientation, ...props }, forwardedRef) => {
5196
5303
  const { className, role, ...rest } = composableProps(props);
5197
5304
  const { tx } = useThemeContext();
5198
- return /* @__PURE__ */ React51.createElement(ToolbarPrimitive.Root, {
5305
+ return /* @__PURE__ */ React47.createElement(ToolbarPrimitive.Root, {
5199
5306
  ...rest,
5200
5307
  ...role !== "none" && {
5201
5308
  role
@@ -5213,56 +5320,56 @@ var ToolbarRoot = composable(({ children, density, disabled, layoutManaged, orie
5213
5320
  ToolbarRoot.displayName = "Toolbar.Root";
5214
5321
  var ToolbarText = slottable(({ children, asChild, ...props }, forwardedRef) => {
5215
5322
  const { className, ...rest } = composableProps(props);
5216
- const Comp = asChild ? Slot22 : Primitive22.div;
5323
+ const Comp = asChild ? Slot20 : Primitive20.div;
5217
5324
  const { tx } = useThemeContext();
5218
- return /* @__PURE__ */ React51.createElement(Comp, {
5325
+ return /* @__PURE__ */ React47.createElement(Comp, {
5219
5326
  ...rest,
5220
5327
  className: tx("toolbar.text", {}, className),
5221
5328
  ref: forwardedRef
5222
5329
  }, children);
5223
5330
  });
5224
5331
  ToolbarText.displayName = "Toolbar.Text";
5225
- var ToolbarButton = /* @__PURE__ */ forwardRef36((props, forwardedRef) => {
5226
- return /* @__PURE__ */ React51.createElement(ToolbarPrimitive.Button, {
5332
+ var ToolbarButton = /* @__PURE__ */ forwardRef34((props, forwardedRef) => {
5333
+ return /* @__PURE__ */ React47.createElement(ToolbarPrimitive.Button, {
5227
5334
  asChild: true
5228
- }, /* @__PURE__ */ React51.createElement(Button, {
5335
+ }, /* @__PURE__ */ React47.createElement(Button, {
5229
5336
  ...props,
5230
5337
  ref: forwardedRef
5231
5338
  }));
5232
5339
  });
5233
5340
  ToolbarButton.displayName = "Toolbar.Button";
5234
- var ToolbarIconButton = /* @__PURE__ */ forwardRef36((props, forwardedRef) => {
5235
- return /* @__PURE__ */ React51.createElement(ToolbarPrimitive.Button, {
5341
+ var ToolbarIconButton = /* @__PURE__ */ forwardRef34((props, forwardedRef) => {
5342
+ return /* @__PURE__ */ React47.createElement(ToolbarPrimitive.Button, {
5236
5343
  asChild: true
5237
- }, /* @__PURE__ */ React51.createElement(IconButton, {
5344
+ }, /* @__PURE__ */ React47.createElement(IconButton, {
5238
5345
  ...props,
5239
5346
  ref: forwardedRef
5240
5347
  }));
5241
5348
  });
5242
5349
  ToolbarIconButton.displayName = "Toolbar.IconButton";
5243
- var ToolbarToggle = /* @__PURE__ */ forwardRef36((props, forwardedRef) => {
5244
- return /* @__PURE__ */ React51.createElement(ToolbarPrimitive.Button, {
5350
+ var ToolbarToggle = /* @__PURE__ */ forwardRef34((props, forwardedRef) => {
5351
+ return /* @__PURE__ */ React47.createElement(ToolbarPrimitive.Button, {
5245
5352
  asChild: true
5246
- }, /* @__PURE__ */ React51.createElement(Toggle, {
5353
+ }, /* @__PURE__ */ React47.createElement(Toggle, {
5247
5354
  ...props,
5248
5355
  ref: forwardedRef
5249
5356
  }));
5250
5357
  });
5251
5358
  ToolbarToggle.displayName = "Toolbar.Toggle";
5252
- var ToolbarLink = /* @__PURE__ */ forwardRef36((props, forwardedRef) => {
5253
- return /* @__PURE__ */ React51.createElement(ToolbarPrimitive.Link, {
5359
+ var ToolbarLink = /* @__PURE__ */ forwardRef34((props, forwardedRef) => {
5360
+ return /* @__PURE__ */ React47.createElement(ToolbarPrimitive.Link, {
5254
5361
  asChild: true
5255
- }, /* @__PURE__ */ React51.createElement(Link, {
5362
+ }, /* @__PURE__ */ React47.createElement(Link, {
5256
5363
  ...props,
5257
5364
  ref: forwardedRef
5258
5365
  }));
5259
5366
  });
5260
5367
  ToolbarLink.displayName = "Toolbar.Link";
5261
- var ToolbarToggleGroup2 = /* @__PURE__ */ forwardRef36(({ classNames, children, elevation, ...props }, forwardedRef) => {
5262
- return /* @__PURE__ */ React51.createElement(ToolbarPrimitive.ToolbarToggleGroup, {
5368
+ var ToolbarToggleGroup2 = /* @__PURE__ */ forwardRef34(({ classNames, children, elevation, ...props }, forwardedRef) => {
5369
+ return /* @__PURE__ */ React47.createElement(ToolbarPrimitive.ToolbarToggleGroup, {
5263
5370
  ...props,
5264
5371
  asChild: true
5265
- }, /* @__PURE__ */ React51.createElement(ButtonGroup, {
5372
+ }, /* @__PURE__ */ React47.createElement(ButtonGroup, {
5266
5373
  classNames,
5267
5374
  children,
5268
5375
  elevation,
@@ -5270,11 +5377,11 @@ var ToolbarToggleGroup2 = /* @__PURE__ */ forwardRef36(({ classNames, children,
5270
5377
  }));
5271
5378
  });
5272
5379
  ToolbarToggleGroup2.displayName = "Toolbar.ToggleGroup";
5273
- var ToolbarToggleGroupItem = /* @__PURE__ */ forwardRef36(({ variant, density, elevation, classNames, children, ...props }, forwardedRef) => {
5274
- return /* @__PURE__ */ React51.createElement(ToolbarPrimitive.ToolbarToggleItem, {
5380
+ var ToolbarToggleGroupItem = /* @__PURE__ */ forwardRef34(({ variant, density, elevation, classNames, children, ...props }, forwardedRef) => {
5381
+ return /* @__PURE__ */ React47.createElement(ToolbarPrimitive.ToolbarToggleItem, {
5275
5382
  ...props,
5276
5383
  asChild: true
5277
- }, /* @__PURE__ */ React51.createElement(Button, {
5384
+ }, /* @__PURE__ */ React47.createElement(Button, {
5278
5385
  variant,
5279
5386
  density,
5280
5387
  elevation,
@@ -5284,11 +5391,11 @@ var ToolbarToggleGroupItem = /* @__PURE__ */ forwardRef36(({ variant, density, e
5284
5391
  }));
5285
5392
  });
5286
5393
  ToolbarToggleGroupItem.displayName = "Toolbar.ToggleGroupItem";
5287
- var ToolbarToggleGroupIconItem = /* @__PURE__ */ forwardRef36(({ variant, density, elevation, classNames, icon, label, iconOnly, iconClassNames, ...props }, forwardedRef) => {
5288
- return /* @__PURE__ */ React51.createElement(ToolbarPrimitive.ToolbarToggleItem, {
5394
+ var ToolbarToggleGroupIconItem = /* @__PURE__ */ forwardRef34(({ variant, density, elevation, classNames, icon, label, iconOnly, iconClassNames, ...props }, forwardedRef) => {
5395
+ return /* @__PURE__ */ React47.createElement(ToolbarPrimitive.ToolbarToggleItem, {
5289
5396
  ...props,
5290
5397
  asChild: true
5291
- }, /* @__PURE__ */ React51.createElement(IconButton, {
5398
+ }, /* @__PURE__ */ React47.createElement(IconButton, {
5292
5399
  variant,
5293
5400
  density,
5294
5401
  elevation,
@@ -5301,22 +5408,22 @@ var ToolbarToggleGroupIconItem = /* @__PURE__ */ forwardRef36(({ variant, densit
5301
5408
  }));
5302
5409
  });
5303
5410
  ToolbarToggleGroupIconItem.displayName = "Toolbar.ToggleGroupIconItem";
5304
- var ToolbarSeparator = /* @__PURE__ */ forwardRef36(({ variant = "gap", ...props }, forwardedRef) => {
5305
- return variant === "line" ? /* @__PURE__ */ React51.createElement(ToolbarPrimitive.Separator, {
5411
+ var ToolbarSeparator = /* @__PURE__ */ forwardRef34(({ variant = "gap", ...props }, forwardedRef) => {
5412
+ return variant === "line" ? /* @__PURE__ */ React47.createElement(ToolbarPrimitive.Separator, {
5306
5413
  asChild: true
5307
- }, /* @__PURE__ */ React51.createElement(Separator4, {
5414
+ }, /* @__PURE__ */ React47.createElement(Separator4, {
5308
5415
  orientation: "vertical",
5309
5416
  ...props,
5310
5417
  ref: forwardedRef
5311
- })) : /* @__PURE__ */ React51.createElement(ToolbarPrimitive.Separator, {
5418
+ })) : /* @__PURE__ */ React47.createElement(ToolbarPrimitive.Separator, {
5312
5419
  className: "grow",
5313
5420
  ref: forwardedRef
5314
5421
  });
5315
5422
  });
5316
5423
  ToolbarSeparator.displayName = "Toolbar.Separator";
5317
- var ToolbarDragHandle = /* @__PURE__ */ forwardRef36(({ testId = "drag-handle", label }, forwardedRef) => {
5424
+ var ToolbarDragHandle = /* @__PURE__ */ forwardRef34(({ testId = "drag-handle", label }, forwardedRef) => {
5318
5425
  const { t } = useTranslation8(translationKey8);
5319
- return /* @__PURE__ */ React51.createElement(ToolbarIconButton, {
5426
+ return /* @__PURE__ */ React47.createElement(ToolbarIconButton, {
5320
5427
  "data-testid": testId,
5321
5428
  tabIndex: -1,
5322
5429
  noTooltip: true,
@@ -5338,9 +5445,9 @@ var TOOLBAR_ACTION_LABEL_KEYS = {
5338
5445
  close: "toolbar-close.label",
5339
5446
  delete: "toolbar-delete.label"
5340
5447
  };
5341
- var ToolbarActionIconButton = /* @__PURE__ */ forwardRef36(({ action, onClick, label }, forwardedRef) => {
5448
+ var ToolbarActionIconButton = /* @__PURE__ */ forwardRef34(({ action, onClick, label }, forwardedRef) => {
5342
5449
  const { t } = useTranslation8(translationKey8);
5343
- return /* @__PURE__ */ React51.createElement(ToolbarIconButton, {
5450
+ return /* @__PURE__ */ React47.createElement(ToolbarIconButton, {
5344
5451
  iconOnly: true,
5345
5452
  icon: TOOLBAR_ACTION_ICONS[action],
5346
5453
  variant: "ghost",
@@ -5353,18 +5460,18 @@ var ToolbarActionIconButton = /* @__PURE__ */ forwardRef36(({ action, onClick, l
5353
5460
  ToolbarActionIconButton.displayName = "Toolbar.ActionIconButton";
5354
5461
  function ToolbarMenu({ context, items }) {
5355
5462
  const { t } = useTranslation8(translationKey8);
5356
- return /* @__PURE__ */ React51.createElement(DropdownMenu.Root, null, /* @__PURE__ */ React51.createElement(DropdownMenu.Trigger, {
5463
+ return /* @__PURE__ */ React47.createElement(DropdownMenu.Root, null, /* @__PURE__ */ React47.createElement(DropdownMenu.Trigger, {
5357
5464
  disabled: !items?.length,
5358
5465
  asChild: true
5359
- }, /* @__PURE__ */ React51.createElement(ToolbarIconButton, {
5466
+ }, /* @__PURE__ */ React47.createElement(ToolbarIconButton, {
5360
5467
  iconOnly: true,
5361
5468
  variant: "ghost",
5362
5469
  icon: "ph--dots-three-vertical--regular",
5363
5470
  label: t("toolbar-menu.label")
5364
- })), (items?.length ?? 0) > 0 && /* @__PURE__ */ React51.createElement(DropdownMenu.Portal, null, /* @__PURE__ */ React51.createElement(DropdownMenu.Content, null, /* @__PURE__ */ React51.createElement(DropdownMenu.Viewport, null, items?.map(({ label, onClick: onSelect }, index) => /* @__PURE__ */ React51.createElement(DropdownMenu.Item, {
5471
+ })), (items?.length ?? 0) > 0 && /* @__PURE__ */ React47.createElement(DropdownMenu.Portal, null, /* @__PURE__ */ React47.createElement(DropdownMenu.Content, null, /* @__PURE__ */ React47.createElement(DropdownMenu.Viewport, null, items?.map(({ label, onClick: onSelect }, index) => /* @__PURE__ */ React47.createElement(DropdownMenu.Item, {
5365
5472
  key: index,
5366
5473
  onSelect: () => onSelect(context)
5367
- }, label))), /* @__PURE__ */ React51.createElement(DropdownMenu.Arrow, null))));
5474
+ }, label))), /* @__PURE__ */ React47.createElement(DropdownMenu.Arrow, null))));
5368
5475
  }
5369
5476
  ToolbarMenu.displayName = "Toolbar.Menu";
5370
5477
  var Toolbar = {
@@ -5415,14 +5522,11 @@ export {
5415
5522
  IconButton,
5416
5523
  Image,
5417
5524
  Input,
5418
- LIST_ITEM_NAME,
5419
- LIST_NAME,
5420
5525
  Link,
5421
- List,
5422
- ListItem,
5423
5526
  Main,
5424
5527
  MediaPlayer,
5425
5528
  Message,
5529
+ MicButton,
5426
5530
  Panel,
5427
5531
  Popover,
5428
5532
  ScrollArea,
@@ -5436,8 +5540,6 @@ export {
5436
5540
  Splitter,
5437
5541
  Status,
5438
5542
  SystemIconButton,
5439
- TREEGRID_PARENT_OF_SEPARATOR,
5440
- TREEGRID_PATH_SEPARATOR,
5441
5543
  Tag,
5442
5544
  TextTooltip,
5443
5545
  ThemeContext,
@@ -5453,9 +5555,6 @@ export {
5453
5555
  Tooltip,
5454
5556
  Trans,
5455
5557
  TranslationsContext,
5456
- Tree,
5457
- TreeItem,
5458
- Treegrid,
5459
5558
  avatarTheme,
5460
5559
  bindTheme,
5461
5560
  breadcrumbTheme,
@@ -5466,7 +5565,6 @@ export {
5466
5565
  composableProps,
5467
5566
  createDropdownMenuScope,
5468
5567
  createPopoverScope,
5469
- createSplitterScope,
5470
5568
  createTooltipScope,
5471
5569
  defaultTheme,
5472
5570
  defaultTx,
@@ -5477,12 +5575,10 @@ export {
5477
5575
  iconButtonTheme,
5478
5576
  iconTheme,
5479
5577
  initialSafeArea,
5480
- inputTextLabel,
5481
5578
  inputTheme,
5482
5579
  isEmbedUrl,
5483
5580
  isLabel,
5484
5581
  linkTheme,
5485
- listTheme,
5486
5582
  mainIntrinsicSize,
5487
5583
  mainPaddingTransitions,
5488
5584
  mainTheme,
@@ -5507,7 +5603,6 @@ export {
5507
5603
  toolbarTheme,
5508
5604
  tooltipContent,
5509
5605
  tooltipTheme,
5510
- treegridTheme,
5511
5606
  useAvatarContext,
5512
5607
  useButtonGroupContext,
5513
5608
  useCarousel,
@@ -5521,8 +5616,6 @@ export {
5521
5616
  useIconHref,
5522
5617
  useInputTrigger,
5523
5618
  useLandmarkMover,
5524
- useListContext,
5525
- useListItemContext,
5526
5619
  useMainContext,
5527
5620
  usePx,
5528
5621
  useSafeArea,