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