@noya-app/noya-designsystem 0.1.58 → 0.1.59

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.
package/dist/index.mjs CHANGED
@@ -219,7 +219,7 @@ import { useEffect as useEffect2, useState as useState5 } from "react";
219
219
  import { useEffect as useEffect3, useRef as useRef4 } from "react";
220
220
 
221
221
  // ../noya-react-utils/src/hooks/useIsomorphicLayoutEffect.ts
222
- import { useEffect as useEffect4, useLayoutEffect } from "react";
222
+ import * as React5 from "react";
223
223
 
224
224
  // ../noya-react-utils/src/hooks/useLateReference.ts
225
225
  import { useCallback as useCallback5, useLayoutEffect as useLayoutEffect2, useRef as useRef5 } from "react";
@@ -396,7 +396,7 @@ var ClientStorage = class {
396
396
  var clientStorage = new ClientStorage();
397
397
 
398
398
  // src/components/ActionMenu.tsx
399
- import React27, { useMemo as useMemo12 } from "react";
399
+ import React28, { useMemo as useMemo12 } from "react";
400
400
 
401
401
  // src/theme/index.ts
402
402
  import tailwindConfig from "@noya-app/noya-tailwind-config";
@@ -437,21 +437,21 @@ var INPUT_HEIGHT = 27;
437
437
  // src/components/DropdownMenu.tsx
438
438
  import { useKeyboardShortcuts } from "@noya-app/noya-keymap";
439
439
  import * as RadixDropdownMenu from "@radix-ui/react-dropdown-menu";
440
- import React26, {
440
+ import React27, {
441
441
  useMemo as useMemo11
442
442
  } from "react";
443
443
 
444
444
  // src/contexts/PortalScopeContext.tsx
445
- import * as React5 from "react";
446
- var PortalScopeContext = React5.createContext(void 0);
447
- var PortalScopeProvider = React5.memo(function PortalScopeProvider2({
445
+ import * as React6 from "react";
446
+ var PortalScopeContext = React6.createContext(void 0);
447
+ var PortalScopeProvider = React6.memo(function PortalScopeProvider2({
448
448
  children,
449
449
  portalScopeId
450
450
  }) {
451
- return /* @__PURE__ */ React5.createElement(PortalScopeContext.Provider, { value: portalScopeId }, children);
451
+ return /* @__PURE__ */ React6.createElement(PortalScopeContext.Provider, { value: portalScopeId }, children);
452
452
  });
453
453
  function usePortalScopeId() {
454
- return React5.useContext(PortalScopeContext) ?? "";
454
+ return React6.useContext(PortalScopeContext) ?? "";
455
455
  }
456
456
  var portalScopeDataSetName = "noyaPortalScope";
457
457
  var portalScopePropName = `data-noya-portal-scope`;
@@ -473,21 +473,21 @@ function getClosestPortalScope(element) {
473
473
 
474
474
  // src/components/internal/Menu.tsx
475
475
  import { getShortcutDisplayParts } from "@noya-app/noya-keymap";
476
- import React23, { memo as memo10 } from "react";
476
+ import React24, { memo as memo10 } from "react";
477
477
 
478
478
  // src/contexts/DesignSystemConfiguration.tsx
479
479
  import { getCurrentPlatform } from "@noya-app/noya-keymap";
480
- import * as React22 from "react";
480
+ import * as React23 from "react";
481
481
 
482
482
  // src/components/Toast.tsx
483
483
  import * as ToastPrimitive from "@radix-ui/react-toast";
484
- import React12 from "react";
484
+ import React13 from "react";
485
485
 
486
486
  // src/components/IconButton.tsx
487
- import * as React11 from "react";
487
+ import * as React12 from "react";
488
488
 
489
489
  // src/components/Button.tsx
490
- import React10, {
490
+ import React11, {
491
491
  forwardRef as forwardRef4,
492
492
  useCallback as useCallback10,
493
493
  useMemo as useMemo4
@@ -558,20 +558,20 @@ function mergeConflictingClassNames(classNames, options) {
558
558
 
559
559
  // src/components/Icons.tsx
560
560
  import * as Icons from "@noya-app/noya-icons";
561
- import * as React6 from "react";
561
+ import * as React7 from "react";
562
562
  function renderIcon(iconName) {
563
563
  if (typeof iconName === "string") {
564
564
  const Icon = Icons[iconName];
565
- return /* @__PURE__ */ React6.createElement(Icon, null);
565
+ return /* @__PURE__ */ React7.createElement(Icon, null);
566
566
  }
567
567
  return iconName;
568
568
  }
569
569
 
570
570
  // src/components/Spacer.tsx
571
- import * as React7 from "react";
572
- var SpacerVertical = React7.forwardRef(
571
+ import * as React8 from "react";
572
+ var SpacerVertical = React8.forwardRef(
573
573
  ({ size: size2, inline, ...props }, ref) => {
574
- return /* @__PURE__ */ React7.createElement(
574
+ return /* @__PURE__ */ React8.createElement(
575
575
  "span",
576
576
  {
577
577
  className: `${inline ? "inline-block" : "block"} ${size2 === void 0 ? "flex flex-1" : ""}`,
@@ -584,9 +584,9 @@ var SpacerVertical = React7.forwardRef(
584
584
  );
585
585
  }
586
586
  );
587
- var SpacerHorizontal = React7.forwardRef(
587
+ var SpacerHorizontal = React8.forwardRef(
588
588
  ({ size: size2, inline, ...props }, ref) => {
589
- return /* @__PURE__ */ React7.createElement(
589
+ return /* @__PURE__ */ React8.createElement(
590
590
  "span",
591
591
  {
592
592
  className: `${inline ? "inline-block" : "block"} ${size2 === void 0 ? "flex flex-1" : ""}`,
@@ -607,10 +607,10 @@ var Spacer;
607
607
 
608
608
  // src/components/Tooltip.tsx
609
609
  import * as TooltipPrimitive from "@radix-ui/react-tooltip";
610
- import * as React9 from "react";
610
+ import * as React10 from "react";
611
611
 
612
612
  // src/components/Text.tsx
613
- import React8, { forwardRef as forwardRef3 } from "react";
613
+ import React9, { forwardRef as forwardRef3 } from "react";
614
614
  var elements = {
615
615
  title: "h1",
616
616
  subtitle: "h1",
@@ -653,7 +653,7 @@ var Text = forwardRef3(function Text2({
653
653
  ...rest
654
654
  }, forwardedRef) {
655
655
  const Component = as ?? elements[variant] ?? "span";
656
- return /* @__PURE__ */ React8.createElement(
656
+ return /* @__PURE__ */ React9.createElement(
657
657
  Component,
658
658
  {
659
659
  ref: forwardedRef,
@@ -672,27 +672,27 @@ var Text = forwardRef3(function Text2({
672
672
  );
673
673
  });
674
674
  var Heading1 = forwardRef3(
675
- (props, ref) => /* @__PURE__ */ React8.createElement(Text, { ref, ...props, variant: "heading1" })
675
+ (props, ref) => /* @__PURE__ */ React9.createElement(Text, { ref, ...props, variant: "heading1" })
676
676
  );
677
677
  var Heading2 = forwardRef3(
678
- (props, ref) => /* @__PURE__ */ React8.createElement(Text, { ref, ...props, variant: "heading2" })
678
+ (props, ref) => /* @__PURE__ */ React9.createElement(Text, { ref, ...props, variant: "heading2" })
679
679
  );
680
680
  var Heading3 = forwardRef3(
681
- (props, ref) => /* @__PURE__ */ React8.createElement(Text, { ref, ...props, variant: "heading3" })
681
+ (props, ref) => /* @__PURE__ */ React9.createElement(Text, { ref, ...props, variant: "heading3" })
682
682
  );
683
683
  var Heading4 = forwardRef3(
684
- (props, ref) => /* @__PURE__ */ React8.createElement(Text, { ref, ...props, variant: "heading4" })
684
+ (props, ref) => /* @__PURE__ */ React9.createElement(Text, { ref, ...props, variant: "heading4" })
685
685
  );
686
686
  var Heading5 = forwardRef3(
687
- (props, ref) => /* @__PURE__ */ React8.createElement(Text, { ref, ...props, variant: "heading5" })
687
+ (props, ref) => /* @__PURE__ */ React9.createElement(Text, { ref, ...props, variant: "heading5" })
688
688
  );
689
689
  var Body = forwardRef3(
690
- (props, ref) => /* @__PURE__ */ React8.createElement(Text, { ref, ...props, variant: "body" })
690
+ (props, ref) => /* @__PURE__ */ React9.createElement(Text, { ref, ...props, variant: "body" })
691
691
  );
692
692
  var Small = forwardRef3(
693
- (props, ref) => /* @__PURE__ */ React8.createElement(Text, { ref, ...props, variant: "small" })
693
+ (props, ref) => /* @__PURE__ */ React9.createElement(Text, { ref, ...props, variant: "small" })
694
694
  );
695
- var Italic = ({ children }) => /* @__PURE__ */ React8.createElement(
695
+ var Italic = ({ children }) => /* @__PURE__ */ React9.createElement(
696
696
  "span",
697
697
  {
698
698
  style: {
@@ -703,13 +703,13 @@ var Italic = ({ children }) => /* @__PURE__ */ React8.createElement(
703
703
  );
704
704
 
705
705
  // src/components/Tooltip.tsx
706
- var Tooltip = React9.memo(function Tooltip2({
706
+ var Tooltip = React10.memo(function Tooltip2({
707
707
  children,
708
708
  content,
709
709
  sideOffset = 2
710
710
  }) {
711
711
  const portalScopeId = usePortalScopeId();
712
- return /* @__PURE__ */ React9.createElement(TooltipPrimitive.Provider, null, /* @__PURE__ */ React9.createElement(TooltipPrimitive.Root, null, /* @__PURE__ */ React9.createElement(TooltipPrimitive.Trigger, { asChild: true }, children), /* @__PURE__ */ React9.createElement(TooltipPrimitive.Portal, null, /* @__PURE__ */ React9.createElement(
712
+ return /* @__PURE__ */ React10.createElement(TooltipPrimitive.Provider, null, /* @__PURE__ */ React10.createElement(TooltipPrimitive.Root, null, /* @__PURE__ */ React10.createElement(TooltipPrimitive.Trigger, { asChild: true }, children), /* @__PURE__ */ React10.createElement(TooltipPrimitive.Portal, null, /* @__PURE__ */ React10.createElement(
713
713
  TooltipPrimitive.Content,
714
714
  {
715
715
  ...portalScopeProps(portalScopeId),
@@ -771,7 +771,7 @@ var Button = forwardRef4(function Button2({
771
771
  categories: ["position"]
772
772
  }) : baseClassName;
773
773
  }, [className, baseClassName]);
774
- const buttonElement = /* @__PURE__ */ React10.createElement(
774
+ const buttonElement = /* @__PURE__ */ React11.createElement(
775
775
  Component,
776
776
  {
777
777
  ref: forwardedRef,
@@ -786,35 +786,35 @@ var Button = forwardRef4(function Button2({
786
786
  }, []),
787
787
  ...rest
788
788
  },
789
- /* @__PURE__ */ React10.createElement(
789
+ /* @__PURE__ */ React11.createElement(
790
790
  "span",
791
791
  {
792
792
  className: "min-h-[19px] flex items-center flex-1 justify-center leading-[15px]",
793
793
  style: contentStyle
794
794
  },
795
795
  icon && renderIcon(icon),
796
- icon && children && /* @__PURE__ */ React10.createElement(Spacer.Horizontal, { inline: true, size: 6 }),
796
+ icon && children && /* @__PURE__ */ React11.createElement(Spacer.Horizontal, { inline: true, size: 6 }),
797
797
  children,
798
- iconRight && (icon || children) && /* @__PURE__ */ React10.createElement(Spacer.Horizontal, { inline: true, size: 6 }),
798
+ iconRight && (icon || children) && /* @__PURE__ */ React11.createElement(Spacer.Horizontal, { inline: true, size: 6 }),
799
799
  iconRight && renderIcon(iconRight)
800
800
  )
801
801
  );
802
- return tooltip ? /* @__PURE__ */ React10.createElement(Tooltip, { content: tooltip }, buttonElement) : buttonElement;
802
+ return tooltip ? /* @__PURE__ */ React11.createElement(Tooltip, { content: tooltip }, buttonElement) : buttonElement;
803
803
  });
804
804
  var Button_default = Button;
805
805
 
806
806
  // src/components/IconButton.tsx
807
- var IconButton = React11.memo(
808
- React11.forwardRef(function IconButton2({ selected, iconName, color, size: size2, contentStyle, ...props }, forwardedRef) {
807
+ var IconButton = React12.memo(
808
+ React12.forwardRef(function IconButton2({ selected, iconName, color, size: size2, contentStyle, ...props }, forwardedRef) {
809
809
  const Icon = Icons[iconName];
810
- const style2 = React11.useMemo(() => {
810
+ const style2 = React12.useMemo(() => {
811
811
  return {
812
812
  padding: "0 2px",
813
813
  ...size2 && { minHeight: size2 },
814
814
  ...contentStyle
815
815
  };
816
816
  }, [contentStyle, size2]);
817
- return /* @__PURE__ */ React11.createElement(Button, { ref: forwardedRef, ...props, variant: "none", contentStyle: style2 }, /* @__PURE__ */ React11.createElement(
817
+ return /* @__PURE__ */ React12.createElement(Button, { ref: forwardedRef, ...props, variant: "none", contentStyle: style2 }, /* @__PURE__ */ React12.createElement(
818
818
  Icon,
819
819
  {
820
820
  color: color ?? (selected ? cssVars.colors.iconSelected : cssVars.colors.icon),
@@ -831,34 +831,34 @@ var Toast = ({
831
831
  children,
832
832
  ...props
833
833
  }) => {
834
- return /* @__PURE__ */ React12.createElement(
834
+ return /* @__PURE__ */ React13.createElement(
835
835
  ToastPrimitive.Root,
836
836
  {
837
837
  className: "px-2 py-2.5 grid grid-cols-[auto_max-content] gap-x-2.5 items-center rounded text-sm bg-popover-background shadow-popover text-text-muted",
838
838
  ...props
839
839
  },
840
- title && /* @__PURE__ */ React12.createElement(
840
+ title && /* @__PURE__ */ React13.createElement(
841
841
  ToastPrimitive.Title,
842
842
  {
843
843
  className: `mb-[5px] ${textStyles.label} font-bold text-text`
844
844
  },
845
845
  title
846
846
  ),
847
- /* @__PURE__ */ React12.createElement(
847
+ /* @__PURE__ */ React13.createElement(
848
848
  ToastPrimitive.Description,
849
849
  {
850
850
  className: `${textStyles.small} text-text-muted`
851
851
  },
852
852
  content
853
853
  ),
854
- children && /* @__PURE__ */ React12.createElement(ToastPrimitive.Action, { asChild: true, altText: "" }, children),
855
- /* @__PURE__ */ React12.createElement(ToastPrimitive.Close, { "aria-label": "Close", asChild: true }, /* @__PURE__ */ React12.createElement(IconButton, { iconName: "Cross1Icon" }))
854
+ children && /* @__PURE__ */ React13.createElement(ToastPrimitive.Action, { asChild: true, altText: "" }, children),
855
+ /* @__PURE__ */ React13.createElement(ToastPrimitive.Close, { "aria-label": "Close", asChild: true }, /* @__PURE__ */ React13.createElement(IconButton, { iconName: "Cross1Icon" }))
856
856
  );
857
857
  };
858
- var ToastProvider = ({ children }) => /* @__PURE__ */ React12.createElement(ToastPrimitive.Provider, null, children, /* @__PURE__ */ React12.createElement(ToastPrimitive.Viewport, { className: "fixed bottom-0 right-0 flex flex-col p-5 g-2.5 min-w-[200px] max-w-[100vw] m-0 list-none z-[2147483647] outline-none" }));
858
+ var ToastProvider = ({ children }) => /* @__PURE__ */ React13.createElement(ToastPrimitive.Provider, null, children, /* @__PURE__ */ React13.createElement(ToastPrimitive.Viewport, { className: "fixed bottom-0 right-0 flex flex-col p-5 g-2.5 min-w-[200px] max-w-[100vw] m-0 list-none z-[2147483647] outline-none" }));
859
859
 
860
860
  // src/contexts/DialogContext.tsx
861
- import React20, {
861
+ import React21, {
862
862
  createContext as createContext5,
863
863
  useCallback as useCallback13,
864
864
  useContext as useContext5,
@@ -869,12 +869,12 @@ import React20, {
869
869
 
870
870
  // src/components/Dialog.tsx
871
871
  import * as DialogPrimitive from "@radix-ui/react-dialog";
872
- import React13, {
872
+ import React14, {
873
873
  forwardRef as forwardRef6,
874
874
  useImperativeHandle,
875
875
  useRef as useRef9
876
876
  } from "react";
877
- var StyledOverlay = forwardRef6(({ className, ...props }, ref) => /* @__PURE__ */ React13.createElement(
877
+ var StyledOverlay = forwardRef6(({ className, ...props }, ref) => /* @__PURE__ */ React14.createElement(
878
878
  DialogPrimitive.Overlay,
879
879
  {
880
880
  ref,
@@ -883,7 +883,7 @@ var StyledOverlay = forwardRef6(({ className, ...props }, ref) => /* @__PURE__ *
883
883
  }
884
884
  ));
885
885
  var StyledContent = forwardRef6(({ className, children, ...props }, ref) => {
886
- return /* @__PURE__ */ React13.createElement(
886
+ return /* @__PURE__ */ React14.createElement(
887
887
  DialogPrimitive.Content,
888
888
  {
889
889
  ref,
@@ -902,7 +902,7 @@ var StyledContent = forwardRef6(({ className, children, ...props }, ref) => {
902
902
  children
903
903
  );
904
904
  });
905
- var StyledTitle = forwardRef6(({ className, ...props }, ref) => /* @__PURE__ */ React13.createElement(
905
+ var StyledTitle = forwardRef6(({ className, ...props }, ref) => /* @__PURE__ */ React14.createElement(
906
906
  DialogPrimitive.Title,
907
907
  {
908
908
  ref,
@@ -913,7 +913,7 @@ var StyledTitle = forwardRef6(({ className, ...props }, ref) => /* @__PURE__ */
913
913
  ...props
914
914
  }
915
915
  ));
916
- var StyledDescription = forwardRef6(({ className, ...props }, ref) => /* @__PURE__ */ React13.createElement(
916
+ var StyledDescription = forwardRef6(({ className, ...props }, ref) => /* @__PURE__ */ React14.createElement(
917
917
  DialogPrimitive.Description,
918
918
  {
919
919
  ref,
@@ -943,7 +943,7 @@ var Dialog = forwardRef6(function Dialog2({
943
943
  return contentRef.current.contains(element);
944
944
  }
945
945
  }));
946
- return /* @__PURE__ */ React13.createElement(DialogPrimitive.Root, { open, onOpenChange }, /* @__PURE__ */ React13.createElement(StyledOverlay, null), /* @__PURE__ */ React13.createElement(
946
+ return /* @__PURE__ */ React14.createElement(DialogPrimitive.Root, { open, onOpenChange }, /* @__PURE__ */ React14.createElement(StyledOverlay, null), /* @__PURE__ */ React14.createElement(
947
947
  StyledContent,
948
948
  {
949
949
  ref: contentRef,
@@ -955,7 +955,7 @@ var Dialog = forwardRef6(function Dialog2({
955
955
  onInteractOutside: (event) => event.preventDefault()
956
956
  }
957
957
  },
958
- showCloseButton && /* @__PURE__ */ React13.createElement(DialogPrimitive.Close, { asChild: true }, /* @__PURE__ */ React13.createElement(
958
+ showCloseButton && /* @__PURE__ */ React14.createElement(DialogPrimitive.Close, { asChild: true }, /* @__PURE__ */ React14.createElement(
959
959
  IconButton,
960
960
  {
961
961
  iconName: "Cross1Icon",
@@ -967,13 +967,13 @@ var Dialog = forwardRef6(function Dialog2({
967
967
  }
968
968
  }
969
969
  )),
970
- title && /* @__PURE__ */ React13.createElement(React13.Fragment, null, /* @__PURE__ */ React13.createElement(StyledTitle, null, title), /* @__PURE__ */ React13.createElement(Spacer.Vertical, { size: description ? 10 : 20 })),
971
- description && /* @__PURE__ */ React13.createElement(React13.Fragment, null, /* @__PURE__ */ React13.createElement(StyledDescription, null, description), /* @__PURE__ */ React13.createElement(Spacer.Vertical, { size: 20 })),
970
+ title && /* @__PURE__ */ React14.createElement(React14.Fragment, null, /* @__PURE__ */ React14.createElement(StyledTitle, null, title), /* @__PURE__ */ React14.createElement(Spacer.Vertical, { size: description ? 10 : 20 })),
971
+ description && /* @__PURE__ */ React14.createElement(React14.Fragment, null, /* @__PURE__ */ React14.createElement(StyledDescription, null, description), /* @__PURE__ */ React14.createElement(Spacer.Vertical, { size: 20 })),
972
972
  children
973
973
  ));
974
974
  });
975
975
  var FullscreenDialog = forwardRef6(function FullscreenDialog2({ style: style2, ...rest }, forwardedRef) {
976
- return /* @__PURE__ */ React13.createElement(
976
+ return /* @__PURE__ */ React14.createElement(
977
977
  Dialog,
978
978
  {
979
979
  ref: forwardedRef,
@@ -986,7 +986,7 @@ var FullscreenDialog = forwardRef6(function FullscreenDialog2({ style: style2, .
986
986
 
987
987
  // src/components/InputField.tsx
988
988
  import { DropdownChevronIcon } from "@noya-app/noya-icons";
989
- import React19, {
989
+ import React20, {
990
990
  createContext as createContext4,
991
991
  forwardRef as forwardRef9,
992
992
  memo as memo8,
@@ -998,30 +998,30 @@ import React19, {
998
998
  } from "react";
999
999
 
1000
1000
  // src/hooks/useLabel.ts
1001
- import React14 from "react";
1002
- var LabelContext = React14.createContext({
1001
+ import React15 from "react";
1002
+ var LabelContext = React15.createContext({
1003
1003
  fieldId: "",
1004
1004
  label: void 0
1005
1005
  });
1006
1006
  var useLabel = ({ label, fieldId }) => {
1007
- const { label: labelFromContext, fieldId: fieldIdFromContext } = React14.useContext(LabelContext);
1007
+ const { label: labelFromContext, fieldId: fieldIdFromContext } = React15.useContext(LabelContext);
1008
1008
  return {
1009
1009
  label: label ?? labelFromContext,
1010
1010
  fieldId: fieldId ?? fieldIdFromContext
1011
1011
  };
1012
1012
  };
1013
- var LabelPositionContext = React14.createContext({
1013
+ var LabelPositionContext = React15.createContext({
1014
1014
  position: "start"
1015
1015
  });
1016
1016
  var useLabelPosition = () => {
1017
- const { position } = React14.useContext(LabelPositionContext);
1017
+ const { position } = React15.useContext(LabelPositionContext);
1018
1018
  return position;
1019
1019
  };
1020
- var LabelWidthContext = React14.createContext({
1020
+ var LabelWidthContext = React15.createContext({
1021
1021
  width: 100
1022
1022
  });
1023
1023
  var useLabelWidth = () => {
1024
- const { width } = React14.useContext(LabelWidthContext);
1024
+ const { width } = React15.useContext(LabelWidthContext);
1025
1025
  return width;
1026
1026
  };
1027
1027
 
@@ -1061,7 +1061,7 @@ var startBaseStyles = "absolute left-1.5 inset-y-0 flex items-center";
1061
1061
 
1062
1062
  // src/components/internal/TextInput.tsx
1063
1063
  import { composeRefs } from "@radix-ui/react-compose-refs";
1064
- import React15, {
1064
+ import React16, {
1065
1065
  forwardRef as forwardRef7,
1066
1066
  useCallback as useCallback11,
1067
1067
  useEffect as useEffect10,
@@ -1111,7 +1111,7 @@ function useGlobalInputBlurTrigger() {
1111
1111
 
1112
1112
  // src/components/internal/TextInput.tsx
1113
1113
  var ReadOnlyTextInput = forwardRef7(function ReadOnlyTextInput2({ onKeyDown, onFocusChange, value, ...rest }, forwardedRef) {
1114
- return /* @__PURE__ */ React15.createElement(
1114
+ return /* @__PURE__ */ React16.createElement(
1115
1115
  "input",
1116
1116
  {
1117
1117
  ref: forwardedRef,
@@ -1154,7 +1154,7 @@ var ControlledTextInput = forwardRef7(function ControlledTextInput2({
1154
1154
  },
1155
1155
  [onFocus, onFocusChange]
1156
1156
  );
1157
- return /* @__PURE__ */ React15.createElement(
1157
+ return /* @__PURE__ */ React16.createElement(
1158
1158
  "input",
1159
1159
  {
1160
1160
  ref: forwardedRef,
@@ -1183,7 +1183,7 @@ var SubmittableTextInput = forwardRef7(function SubmittableTextInput2({
1183
1183
  submitOnBlur = true,
1184
1184
  ...rest
1185
1185
  }, forwardedRef) {
1186
- const ref = React15.useRef(null);
1186
+ const ref = React16.useRef(null);
1187
1187
  const latestValue = useRef10(value);
1188
1188
  latestValue.current = value;
1189
1189
  const userDidEdit = useRef10(false);
@@ -1266,7 +1266,7 @@ var SubmittableTextInput = forwardRef7(function SubmittableTextInput2({
1266
1266
  }
1267
1267
  };
1268
1268
  }, [internalValue, submitAutomaticallyAfterDelay]);
1269
- return /* @__PURE__ */ React15.createElement(
1269
+ return /* @__PURE__ */ React16.createElement(
1270
1270
  "input",
1271
1271
  {
1272
1272
  ref: composeRefs(ref, forwardedRef),
@@ -1298,21 +1298,21 @@ var TextInput_default = forwardRef7(function TextInput(props, forwardedRef) {
1298
1298
  ...props
1299
1299
  };
1300
1300
  if ("readOnly" in commonProps) {
1301
- return /* @__PURE__ */ React15.createElement(ReadOnlyTextInput, { ref: forwardedRef, ...commonProps, readOnly: true });
1301
+ return /* @__PURE__ */ React16.createElement(ReadOnlyTextInput, { ref: forwardedRef, ...commonProps, readOnly: true });
1302
1302
  } else if ("onChange" in commonProps) {
1303
- return /* @__PURE__ */ React15.createElement(ControlledTextInput, { ref: forwardedRef, ...commonProps });
1303
+ return /* @__PURE__ */ React16.createElement(ControlledTextInput, { ref: forwardedRef, ...commonProps });
1304
1304
  } else {
1305
- return /* @__PURE__ */ React15.createElement(SubmittableTextInput, { ref: forwardedRef, ...commonProps });
1305
+ return /* @__PURE__ */ React16.createElement(SubmittableTextInput, { ref: forwardedRef, ...commonProps });
1306
1306
  }
1307
1307
  });
1308
1308
 
1309
1309
  // src/components/Label.tsx
1310
- import React16, { forwardRef as forwardRef8, memo as memo6 } from "react";
1310
+ import React17, { forwardRef as forwardRef8, memo as memo6 } from "react";
1311
1311
  var labelStyles = "flex items-center select-none z-label relative";
1312
1312
  var labelTextStyles = "font-sans text-label uppercase leading-3 font-bold text-text-muted";
1313
1313
  var Label = memo6(
1314
1314
  forwardRef8(function Label2({ className, children, ...props }, ref) {
1315
- return /* @__PURE__ */ React16.createElement(
1315
+ return /* @__PURE__ */ React17.createElement(
1316
1316
  "label",
1317
1317
  {
1318
1318
  ref,
@@ -1336,28 +1336,28 @@ var Label = memo6(
1336
1336
 
1337
1337
  // src/components/Popover.tsx
1338
1338
  import * as PopoverPrimitive from "@radix-ui/react-popover";
1339
- import React18, { useEffect as useEffect11, useId, useRef as useRef11 } from "react";
1339
+ import React19, { useEffect as useEffect11, useId, useRef as useRef11 } from "react";
1340
1340
 
1341
1341
  // src/contexts/OpenPortalsContext.tsx
1342
- import * as React17 from "react";
1343
- var OpenPortalsContext = React17.createContext({
1342
+ import * as React18 from "react";
1343
+ var OpenPortalsContext = React18.createContext({
1344
1344
  hasOpenPortals: false
1345
1345
  });
1346
- var OpenPortalControlsContext = React17.createContext({
1346
+ var OpenPortalControlsContext = React18.createContext({
1347
1347
  addOpenPortal: () => {
1348
1348
  },
1349
1349
  removeOpenPortal: () => {
1350
1350
  }
1351
1351
  });
1352
- var OpenPortalsProvider = React17.memo(function OpenPortalsProvider2({
1352
+ var OpenPortalsProvider = React18.memo(function OpenPortalsProvider2({
1353
1353
  children
1354
1354
  }) {
1355
- const [openPortals, setOpenPortals] = React17.useState([]);
1356
- const value = React17.useMemo(
1355
+ const [openPortals, setOpenPortals] = React18.useState([]);
1356
+ const value = React18.useMemo(
1357
1357
  () => ({ hasOpenPortals: openPortals.length > 0 }),
1358
1358
  [openPortals]
1359
1359
  );
1360
- const controlsValue = React17.useMemo(
1360
+ const controlsValue = React18.useMemo(
1361
1361
  () => ({
1362
1362
  addOpenPortal: (portal) => {
1363
1363
  setOpenPortals((prev) => [...prev, portal]);
@@ -1368,13 +1368,13 @@ var OpenPortalsProvider = React17.memo(function OpenPortalsProvider2({
1368
1368
  }),
1369
1369
  []
1370
1370
  );
1371
- return /* @__PURE__ */ React17.createElement(OpenPortalsContext.Provider, { value }, /* @__PURE__ */ React17.createElement(OpenPortalControlsContext.Provider, { value: controlsValue }, children));
1371
+ return /* @__PURE__ */ React18.createElement(OpenPortalsContext.Provider, { value }, /* @__PURE__ */ React18.createElement(OpenPortalControlsContext.Provider, { value: controlsValue }, children));
1372
1372
  });
1373
1373
  function useHasOpenPortals() {
1374
- return React17.useContext(OpenPortalsContext).hasOpenPortals;
1374
+ return React18.useContext(OpenPortalsContext).hasOpenPortals;
1375
1375
  }
1376
1376
  function useOpenPortalsControls() {
1377
- return React17.useContext(OpenPortalControlsContext);
1377
+ return React18.useContext(OpenPortalControlsContext);
1378
1378
  }
1379
1379
 
1380
1380
  // src/components/Popover.tsx
@@ -1422,7 +1422,7 @@ function Popover({
1422
1422
  removeOpenPortal(portalScopeId || defaultId);
1423
1423
  };
1424
1424
  }, [addOpenPortal, isOpen, portalScopeId, removeOpenPortal, defaultId]);
1425
- return /* @__PURE__ */ React18.createElement(PopoverPrimitive.Root, { open: isOpen, onOpenChange: setIsOpen }, /* @__PURE__ */ React18.createElement(PopoverPrimitive.Trigger, { asChild: true }, trigger), /* @__PURE__ */ React18.createElement(PopoverPrimitive.Portal, { container: portalContainer }, /* @__PURE__ */ React18.createElement(
1425
+ return /* @__PURE__ */ React19.createElement(PopoverPrimitive.Root, { open: isOpen, onOpenChange: setIsOpen }, /* @__PURE__ */ React19.createElement(PopoverPrimitive.Trigger, { asChild: true }, trigger), /* @__PURE__ */ React19.createElement(PopoverPrimitive.Portal, { container: portalContainer }, /* @__PURE__ */ React19.createElement(
1426
1426
  PopoverPrimitive.Content,
1427
1427
  {
1428
1428
  ...portalScopeProps(portalScopeId),
@@ -1453,14 +1453,14 @@ function Popover({
1453
1453
  arrowPadding: 2
1454
1454
  },
1455
1455
  children,
1456
- showArrow && /* @__PURE__ */ React18.createElement(PopoverPrimitive.Arrow, { className: "fill-popover-background" }),
1457
- closable && /* @__PURE__ */ React18.createElement(
1456
+ showArrow && /* @__PURE__ */ React19.createElement(PopoverPrimitive.Arrow, { className: "fill-popover-background" }),
1457
+ closable && /* @__PURE__ */ React19.createElement(
1458
1458
  PopoverPrimitive.Close,
1459
1459
  {
1460
1460
  className: "rounded-full h-[25px] w-[25px] inline-flex items-center justify-center absolute top-[5px] right-[5px]",
1461
1461
  style: closeStyles
1462
1462
  },
1463
- /* @__PURE__ */ React18.createElement(IconButton, { iconName: "Cross2Icon", onClick: onClickClose })
1463
+ /* @__PURE__ */ React19.createElement(IconButton, { iconName: "Cross2Icon", onClick: onClickClose })
1464
1464
  )
1465
1465
  )));
1466
1466
  }
@@ -1501,7 +1501,7 @@ var getFieldSpacing = ({
1501
1501
  paddingRight: `${variant === "bare" ? endWidth : endWidth ? endWidth + 12 : 6}px`
1502
1502
  });
1503
1503
  var InputFieldDropdownMenu = memoGeneric(function InputFieldDropdownMenu2({ id, items, onSelect, children }) {
1504
- return /* @__PURE__ */ React19.createElement(
1504
+ return /* @__PURE__ */ React20.createElement(
1505
1505
  DropdownMenu,
1506
1506
  {
1507
1507
  items,
@@ -1509,7 +1509,7 @@ var InputFieldDropdownMenu = memoGeneric(function InputFieldDropdownMenu2({ id,
1509
1509
  align: "end",
1510
1510
  sideOffset: 8
1511
1511
  },
1512
- children || /* @__PURE__ */ React19.createElement(InputFieldButton, { variant: "floating", id }, /* @__PURE__ */ React19.createElement(DropdownChevronIcon, null))
1512
+ children || /* @__PURE__ */ React20.createElement(InputFieldButton, { variant: "floating", id }, /* @__PURE__ */ React20.createElement(DropdownChevronIcon, null))
1513
1513
  );
1514
1514
  });
1515
1515
  var InputFieldButton = memo8(
@@ -1552,7 +1552,7 @@ var InputFieldButton = memo8(
1552
1552
  }),
1553
1553
  [style2, variant]
1554
1554
  );
1555
- return /* @__PURE__ */ React19.createElement(
1555
+ return /* @__PURE__ */ React20.createElement(
1556
1556
  Button,
1557
1557
  {
1558
1558
  as,
@@ -1609,7 +1609,7 @@ var InputElement = forwardRef9(
1609
1609
  [inputClassName]
1610
1610
  );
1611
1611
  if (as === "span") {
1612
- return /* @__PURE__ */ React19.createElement(
1612
+ return /* @__PURE__ */ React20.createElement(
1613
1613
  "span",
1614
1614
  {
1615
1615
  ref,
@@ -1620,7 +1620,7 @@ var InputElement = forwardRef9(
1620
1620
  children
1621
1621
  );
1622
1622
  }
1623
- return /* @__PURE__ */ React19.createElement(
1623
+ return /* @__PURE__ */ React20.createElement(
1624
1624
  TextInput_default,
1625
1625
  {
1626
1626
  ref,
@@ -1644,7 +1644,7 @@ var InputFieldInput = forwardRef9(function InputFieldInput2({ textAlign, variant
1644
1644
  },
1645
1645
  [onFocusChange]
1646
1646
  );
1647
- return /* @__PURE__ */ React19.createElement(
1647
+ return /* @__PURE__ */ React20.createElement(
1648
1648
  InputElement,
1649
1649
  {
1650
1650
  ref,
@@ -1656,7 +1656,7 @@ var InputFieldInput = forwardRef9(function InputFieldInput2({ textAlign, variant
1656
1656
  );
1657
1657
  });
1658
1658
  var InputFieldTypeahead = (props) => {
1659
- return /* @__PURE__ */ React19.createElement(
1659
+ return /* @__PURE__ */ React20.createElement(
1660
1660
  InputElement,
1661
1661
  {
1662
1662
  as: "span",
@@ -1674,8 +1674,8 @@ var InputFieldTypeahead = (props) => {
1674
1674
  []
1675
1675
  )
1676
1676
  },
1677
- /* @__PURE__ */ React19.createElement("span", { style: { opacity: 0 } }, props.prefix),
1678
- props.isFocused && /* @__PURE__ */ React19.createElement("span", { style: { opacity: 0.5 } }, props.value.slice(props.prefix.length))
1677
+ /* @__PURE__ */ React20.createElement("span", { style: { opacity: 0 } }, props.prefix),
1678
+ props.isFocused && /* @__PURE__ */ React20.createElement("span", { style: { opacity: 0.5 } }, props.value.slice(props.prefix.length))
1679
1679
  );
1680
1680
  };
1681
1681
  function parseNumber(value) {
@@ -1731,7 +1731,7 @@ function InputFieldNumberInput(props) {
1731
1731
  },
1732
1732
  [onBlur]
1733
1733
  );
1734
- return /* @__PURE__ */ React19.createElement(
1734
+ return /* @__PURE__ */ React20.createElement(
1735
1735
  InputFieldInput,
1736
1736
  {
1737
1737
  ...rest,
@@ -1744,7 +1744,7 @@ function InputFieldNumberInput(props) {
1744
1744
  }
1745
1745
  );
1746
1746
  }
1747
- var RootContainer = forwardRef9(({ $width, className, ...props }, ref) => /* @__PURE__ */ React19.createElement(
1747
+ var RootContainer = forwardRef9(({ $width, className, ...props }, ref) => /* @__PURE__ */ React20.createElement(
1748
1748
  "div",
1749
1749
  {
1750
1750
  ref,
@@ -1775,10 +1775,10 @@ function InputFieldRoot({
1775
1775
  label: labelProp
1776
1776
  }) {
1777
1777
  const randomId = useId2();
1778
- const [isFocused, setIsFocused] = React19.useState(false);
1779
- const startRef = React19.useRef(null);
1780
- const inputRef = React19.useRef(null);
1781
- const endRef = React19.useRef(null);
1778
+ const [isFocused, setIsFocused] = React20.useState(false);
1779
+ const startRef = React20.useRef(null);
1780
+ const inputRef = React20.useRef(null);
1781
+ const endRef = React20.useRef(null);
1782
1782
  const measuredInputSize = useSize(inputRef, "width");
1783
1783
  const measuredStartSize = useSize(startRef, "width");
1784
1784
  const measuredEndSize = useSize(endRef, "width");
@@ -1809,10 +1809,10 @@ function InputFieldRoot({
1809
1809
  [startWidth, endWidth, size2, isFocused, handleFocusChange, id, randomId]
1810
1810
  );
1811
1811
  const insetLabel = useMemo7(
1812
- () => /* @__PURE__ */ React19.createElement(Label, { htmlFor: id, className: "!text-text-disabled" }, labelProp ?? label),
1812
+ () => /* @__PURE__ */ React20.createElement(Label, { htmlFor: id, className: "!text-text-disabled" }, labelProp ?? label),
1813
1813
  [id, labelProp, label]
1814
1814
  );
1815
- const rootElement = /* @__PURE__ */ React19.createElement(RootContainer, { $width: width, style: style2, className }, children, start && /* @__PURE__ */ React19.createElement("span", { ref: startRef, className: cx(startBaseStyles, startClassName) }, start), (end || label) && /* @__PURE__ */ React19.createElement(
1815
+ const rootElement = /* @__PURE__ */ React20.createElement(RootContainer, { $width: width, style: style2, className }, children, start && /* @__PURE__ */ React20.createElement("span", { ref: startRef, className: cx(startBaseStyles, startClassName) }, start), (end || label) && /* @__PURE__ */ React20.createElement(
1816
1816
  "span",
1817
1817
  {
1818
1818
  ref: endRef,
@@ -1825,7 +1825,7 @@ function InputFieldRoot({
1825
1825
  () => measuredInputSize ? { width: measuredInputSize.width + 4 } : void 0,
1826
1826
  [measuredInputSize]
1827
1827
  );
1828
- return /* @__PURE__ */ React19.createElement(InputFieldContext.Provider, { value: contextValue }, renderPopoverContent ? /* @__PURE__ */ React19.createElement(
1828
+ return /* @__PURE__ */ React20.createElement(InputFieldContext.Provider, { value: contextValue }, renderPopoverContent ? /* @__PURE__ */ React20.createElement(
1829
1829
  Popover,
1830
1830
  {
1831
1831
  open: true,
@@ -1841,7 +1841,7 @@ function InputFieldRoot({
1841
1841
  event.stopPropagation();
1842
1842
  }
1843
1843
  },
1844
- measuredWidthObject && /* @__PURE__ */ React19.createElement(
1844
+ measuredWidthObject && /* @__PURE__ */ React20.createElement(
1845
1845
  "div",
1846
1846
  {
1847
1847
  className: "flex flex-col overflow-hidden",
@@ -1866,7 +1866,7 @@ var PrimitiveInputField = ({
1866
1866
  () => ({ ...spacingStyles, ...style2 }),
1867
1867
  [spacingStyles, style2]
1868
1868
  );
1869
- return /* @__PURE__ */ React19.createElement(
1869
+ return /* @__PURE__ */ React20.createElement(
1870
1870
  "input",
1871
1871
  {
1872
1872
  style: memoizedStyles,
@@ -1907,7 +1907,7 @@ var InputFieldComponent = forwardRef9(
1907
1907
  className,
1908
1908
  ...inputProps
1909
1909
  } = props;
1910
- return /* @__PURE__ */ React19.createElement(
1910
+ return /* @__PURE__ */ React20.createElement(
1911
1911
  InputFieldSubcomponents.Root,
1912
1912
  {
1913
1913
  width,
@@ -1923,7 +1923,7 @@ var InputFieldComponent = forwardRef9(
1923
1923
  style: style2,
1924
1924
  className
1925
1925
  },
1926
- /* @__PURE__ */ React19.createElement(InputFieldSubcomponents.Input, { ref, ...inputProps }),
1926
+ /* @__PURE__ */ React20.createElement(InputFieldSubcomponents.Input, { ref, ...inputProps }),
1927
1927
  children
1928
1928
  );
1929
1929
  }
@@ -2044,7 +2044,7 @@ var DialogProvider = function DialogProvider2({
2044
2044
  if (!dialogRef.current) return false;
2045
2045
  return dialogRef.current.containsElement(element);
2046
2046
  }, []);
2047
- return /* @__PURE__ */ React20.createElement(React20.Fragment, null, /* @__PURE__ */ React20.createElement(
2047
+ return /* @__PURE__ */ React21.createElement(React21.Fragment, null, /* @__PURE__ */ React21.createElement(
2048
2048
  DialogContext.Provider,
2049
2049
  {
2050
2050
  value: useMemo8(
@@ -2058,7 +2058,7 @@ var DialogProvider = function DialogProvider2({
2058
2058
  )
2059
2059
  },
2060
2060
  children
2061
- ), /* @__PURE__ */ React20.createElement(
2061
+ ), /* @__PURE__ */ React21.createElement(
2062
2062
  Dialog,
2063
2063
  {
2064
2064
  ref: dialogRef,
@@ -2089,7 +2089,7 @@ var DialogProvider = function DialogProvider2({
2089
2089
  [contents]
2090
2090
  )
2091
2091
  },
2092
- contents?.type === "confirmation" ? /* @__PURE__ */ React20.createElement("div", { className: "flex flex-1 flex-row items-center" }, /* @__PURE__ */ React20.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React20.createElement(
2092
+ contents?.type === "confirmation" ? /* @__PURE__ */ React21.createElement("div", { className: "flex flex-1 flex-row items-center" }, /* @__PURE__ */ React21.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React21.createElement(
2093
2093
  Button,
2094
2094
  {
2095
2095
  onClick: () => {
@@ -2098,7 +2098,7 @@ var DialogProvider = function DialogProvider2({
2098
2098
  }
2099
2099
  },
2100
2100
  contents.cancelButtonLabel ?? "Cancel"
2101
- ), /* @__PURE__ */ React20.createElement(Spacer.Horizontal, { size: 16 }), /* @__PURE__ */ React20.createElement(
2101
+ ), /* @__PURE__ */ React21.createElement(Spacer.Horizontal, { size: 16 }), /* @__PURE__ */ React21.createElement(
2102
2102
  Button,
2103
2103
  {
2104
2104
  onClick: () => {
@@ -2107,7 +2107,7 @@ var DialogProvider = function DialogProvider2({
2107
2107
  }
2108
2108
  },
2109
2109
  contents.confirmButtonLabel ?? "OK"
2110
- )) : contents?.type === "custom" ? /* @__PURE__ */ React20.createElement(React20.Fragment, null, contents.children) : /* @__PURE__ */ React20.createElement(React20.Fragment, null, /* @__PURE__ */ React20.createElement(InputField2.Root, null, /* @__PURE__ */ React20.createElement(
2110
+ )) : contents?.type === "custom" ? /* @__PURE__ */ React21.createElement(React21.Fragment, null, contents.children) : /* @__PURE__ */ React21.createElement(React21.Fragment, null, /* @__PURE__ */ React21.createElement(InputField2.Root, null, /* @__PURE__ */ React21.createElement(
2111
2111
  InputField2.Input,
2112
2112
  {
2113
2113
  ref: inputRef,
@@ -2123,7 +2123,7 @@ var DialogProvider = function DialogProvider2({
2123
2123
  },
2124
2124
  onKeyDown: handleKeyDown
2125
2125
  }
2126
- )), /* @__PURE__ */ React20.createElement(Spacer.Vertical, { size: 20 }), /* @__PURE__ */ React20.createElement("div", { className: "flex flex-1 flex-row items-center" }, /* @__PURE__ */ React20.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React20.createElement(Button, { onClick: close }, "Cancel"), /* @__PURE__ */ React20.createElement(Spacer.Horizontal, { size: 16 }), /* @__PURE__ */ React20.createElement(
2126
+ )), /* @__PURE__ */ React21.createElement(Spacer.Vertical, { size: 20 }), /* @__PURE__ */ React21.createElement("div", { className: "flex flex-1 flex-row items-center" }, /* @__PURE__ */ React21.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React21.createElement(Button, { onClick: close }, "Cancel"), /* @__PURE__ */ React21.createElement(Spacer.Horizontal, { size: 16 }), /* @__PURE__ */ React21.createElement(
2127
2127
  Button,
2128
2128
  {
2129
2129
  disabled: !contents || contents.type !== "input" || !contents.inputValue,
@@ -2155,7 +2155,7 @@ function useOpenDialog() {
2155
2155
 
2156
2156
  // src/contexts/FloatingWindowContext.tsx
2157
2157
  import { uuid } from "@noya-app/noya-utils";
2158
- import React21, { createContext as createContext6, useContext as useContext6, useMemo as useMemo9, useState as useState15 } from "react";
2158
+ import React22, { createContext as createContext6, useContext as useContext6, useMemo as useMemo9, useState as useState15 } from "react";
2159
2159
  import { createPortal } from "react-dom";
2160
2160
  var FloatingWindowContext = createContext6(void 0);
2161
2161
  var CurrentWindowContext = createContext6(void 0);
@@ -2168,7 +2168,7 @@ var FloatingWindowProvider = ({
2168
2168
  const id = uuid();
2169
2169
  setWindows((windows2) => ({
2170
2170
  ...windows2,
2171
- [id]: /* @__PURE__ */ React21.createElement(CurrentWindowContext.Provider, { value: { id } }, element)
2171
+ [id]: /* @__PURE__ */ React22.createElement(CurrentWindowContext.Provider, { value: { id } }, element)
2172
2172
  }));
2173
2173
  return id;
2174
2174
  };
@@ -2180,7 +2180,7 @@ var FloatingWindowProvider = ({
2180
2180
  };
2181
2181
  return { createWindow, closeWindow };
2182
2182
  }, []);
2183
- return /* @__PURE__ */ React21.createElement(FloatingWindowContext.Provider, { value: contextValue }, children, Object.entries(windows).map(
2183
+ return /* @__PURE__ */ React22.createElement(FloatingWindowContext.Provider, { value: contextValue }, children, Object.entries(windows).map(
2184
2184
  ([id, element]) => createPortal(element, document.body, id)
2185
2185
  ));
2186
2186
  };
@@ -2202,30 +2202,30 @@ var useCurrentFloatingWindowInternal = () => {
2202
2202
  };
2203
2203
 
2204
2204
  // src/contexts/DesignSystemConfiguration.tsx
2205
- var DesignSystemConfigurationContext = React22.createContext({
2205
+ var DesignSystemConfigurationContext = React23.createContext({
2206
2206
  platform: "key"
2207
2207
  });
2208
- var DesignSystemConfigurationProvider = React22.memo(
2208
+ var DesignSystemConfigurationProvider = React23.memo(
2209
2209
  function DesignSystemConfigurationProvider2({
2210
2210
  children,
2211
2211
  platform
2212
2212
  }) {
2213
- const [internalPlatform, setInternalPlatform] = React22.useState(platform ?? "key");
2214
- React22.useEffect(() => {
2213
+ const [internalPlatform, setInternalPlatform] = React23.useState(platform ?? "key");
2214
+ React23.useEffect(() => {
2215
2215
  if (platform !== void 0) return;
2216
2216
  if (typeof navigator !== "undefined") {
2217
2217
  setInternalPlatform(getCurrentPlatform(navigator));
2218
2218
  }
2219
2219
  }, [platform]);
2220
- const contextValue = React22.useMemo(
2220
+ const contextValue = React23.useMemo(
2221
2221
  () => ({ platform: platform ?? internalPlatform }),
2222
2222
  [platform, internalPlatform]
2223
2223
  );
2224
- return /* @__PURE__ */ React22.createElement(DesignSystemConfigurationContext.Provider, { value: contextValue }, /* @__PURE__ */ React22.createElement(OpenPortalsProvider, null, /* @__PURE__ */ React22.createElement(DialogProvider, null, /* @__PURE__ */ React22.createElement(ToastProvider, null, /* @__PURE__ */ React22.createElement(FloatingWindowProvider, null, children)))));
2224
+ return /* @__PURE__ */ React23.createElement(DesignSystemConfigurationContext.Provider, { value: contextValue }, /* @__PURE__ */ React23.createElement(OpenPortalsProvider, null, /* @__PURE__ */ React23.createElement(DialogProvider, null, /* @__PURE__ */ React23.createElement(ToastProvider, null, /* @__PURE__ */ React23.createElement(FloatingWindowProvider, null, children)))));
2225
2225
  }
2226
2226
  );
2227
2227
  function useDesignSystemConfiguration() {
2228
- return React22.useContext(DesignSystemConfigurationContext);
2228
+ return React23.useContext(DesignSystemConfigurationContext);
2229
2229
  }
2230
2230
 
2231
2231
  // src/utils/withSeparatorElements.ts
@@ -2322,7 +2322,7 @@ function getKeyboardShortcutsForMenuItems(menuItems, onSelect) {
2322
2322
  var ShortcutElement = ({
2323
2323
  children,
2324
2324
  fixedWidth
2325
- }) => /* @__PURE__ */ React23.createElement(
2325
+ }) => /* @__PURE__ */ React24.createElement(
2326
2326
  "kbd",
2327
2327
  {
2328
2328
  className: cx(
@@ -2338,7 +2338,7 @@ var KeyboardShortcut = memo10(function KeyboardShortcut2({
2338
2338
  }) {
2339
2339
  const platform = useDesignSystemConfiguration().platform;
2340
2340
  const { keys, separator: separator2 } = getShortcutDisplayParts(shortcut, platform);
2341
- const keyElements = keys.map((key) => /* @__PURE__ */ React23.createElement(
2341
+ const keyElements = keys.map((key) => /* @__PURE__ */ React24.createElement(
2342
2342
  ShortcutElement,
2343
2343
  {
2344
2344
  key,
@@ -2346,9 +2346,9 @@ var KeyboardShortcut = memo10(function KeyboardShortcut2({
2346
2346
  },
2347
2347
  key
2348
2348
  ));
2349
- return /* @__PURE__ */ React23.createElement(React23.Fragment, null, separator2 ? withSeparatorElements(
2349
+ return /* @__PURE__ */ React24.createElement(React24.Fragment, null, separator2 ? withSeparatorElements(
2350
2350
  keyElements,
2351
- /* @__PURE__ */ React23.createElement(ShortcutElement, null, separator2)
2351
+ /* @__PURE__ */ React24.createElement(ShortcutElement, null, separator2)
2352
2352
  ) : keyElements);
2353
2353
  });
2354
2354
  var SectionHeader = memo10(function SectionHeader2({
@@ -2358,7 +2358,7 @@ var SectionHeader = memo10(function SectionHeader2({
2358
2358
  isFirst,
2359
2359
  indented
2360
2360
  }) {
2361
- return /* @__PURE__ */ React23.createElement(
2361
+ return /* @__PURE__ */ React24.createElement(
2362
2362
  "span",
2363
2363
  {
2364
2364
  id,
@@ -2373,7 +2373,7 @@ var SectionHeader = memo10(function SectionHeader2({
2373
2373
  }
2374
2374
  )
2375
2375
  },
2376
- indented && /* @__PURE__ */ React23.createElement(
2376
+ indented && /* @__PURE__ */ React24.createElement(
2377
2377
  Spacer.Horizontal,
2378
2378
  {
2379
2379
  size: CHECKBOX_WIDTH - CHECKBOX_RIGHT_INSET + CHECKBOX_INDENT_WIDTH
@@ -2385,11 +2385,11 @@ var SectionHeader = memo10(function SectionHeader2({
2385
2385
 
2386
2386
  // src/components/internal/MenuViewport.tsx
2387
2387
  import { ChevronRightIcon } from "@noya-app/noya-icons";
2388
- import React25 from "react";
2388
+ import React26 from "react";
2389
2389
 
2390
2390
  // src/components/internal/SelectItem.tsx
2391
- import React24, { useCallback as useCallback14 } from "react";
2392
- var SelectItem = React24.forwardRef(
2391
+ import React25, { useCallback as useCallback14 } from "react";
2392
+ var SelectItem = React25.forwardRef(
2393
2393
  ({
2394
2394
  children,
2395
2395
  icon,
@@ -2414,7 +2414,7 @@ var SelectItem = React24.forwardRef(
2414
2414
  []
2415
2415
  );
2416
2416
  if (checked && Components4.CheckboxItem) {
2417
- return /* @__PURE__ */ React24.createElement("div", { className: "px-1" }, /* @__PURE__ */ React24.createElement(
2417
+ return /* @__PURE__ */ React25.createElement("div", { className: "px-1" }, /* @__PURE__ */ React25.createElement(
2418
2418
  Components4.CheckboxItem,
2419
2419
  {
2420
2420
  checked,
@@ -2426,14 +2426,14 @@ var SelectItem = React24.forwardRef(
2426
2426
  testSelected && styles.testSelectedItemStyle
2427
2427
  )
2428
2428
  },
2429
- /* @__PURE__ */ React24.createElement(Spacer.Horizontal, { size: CHECKBOX_INDENT_WIDTH }),
2430
- Components4.ItemIndicator && /* @__PURE__ */ React24.createElement(Components4.ItemIndicator, { ...styles.itemIndicator }, /* @__PURE__ */ React24.createElement(Checkmark, null)),
2431
- icon && /* @__PURE__ */ React24.createElement(React24.Fragment, null, renderIcon(icon), /* @__PURE__ */ React24.createElement(Spacer.Horizontal, { size: 8 })),
2429
+ /* @__PURE__ */ React25.createElement(Spacer.Horizontal, { size: CHECKBOX_INDENT_WIDTH }),
2430
+ Components4.ItemIndicator && /* @__PURE__ */ React25.createElement(Components4.ItemIndicator, { ...styles.itemIndicator }, /* @__PURE__ */ React25.createElement(Checkmark, null)),
2431
+ icon && /* @__PURE__ */ React25.createElement(React25.Fragment, null, renderIcon(icon), /* @__PURE__ */ React25.createElement(Spacer.Horizontal, { size: 8 })),
2432
2432
  children,
2433
- shortcut && /* @__PURE__ */ React24.createElement(React24.Fragment, null, /* @__PURE__ */ React24.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React24.createElement(Spacer.Horizontal, { size: 24 }), /* @__PURE__ */ React24.createElement(KeyboardShortcut, { shortcut }))
2433
+ shortcut && /* @__PURE__ */ React25.createElement(React25.Fragment, null, /* @__PURE__ */ React25.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React25.createElement(Spacer.Horizontal, { size: 24 }), /* @__PURE__ */ React25.createElement(KeyboardShortcut, { shortcut }))
2434
2434
  ));
2435
2435
  }
2436
- return /* @__PURE__ */ React24.createElement("div", { className: "px-1" }, /* @__PURE__ */ React24.createElement(
2436
+ return /* @__PURE__ */ React25.createElement("div", { className: "px-1" }, /* @__PURE__ */ React25.createElement(
2437
2437
  Components4.Item,
2438
2438
  {
2439
2439
  className: cx(
@@ -2448,12 +2448,12 @@ var SelectItem = React24.forwardRef(
2448
2448
  onSelect: handleSelectItem,
2449
2449
  ...props
2450
2450
  },
2451
- /* @__PURE__ */ React24.createElement("div", { className: "flex flex-1 items-center" }, indented && /* @__PURE__ */ React24.createElement(Spacer.Horizontal, { size: CHECKBOX_INDENT_WIDTH }), checked ? /* @__PURE__ */ React24.createElement("div", { ...styles.itemIndicator }, /* @__PURE__ */ React24.createElement(Checkmark, null)) : indented ? /* @__PURE__ */ React24.createElement(Spacer.Horizontal, { size: CHECKBOX_WIDTH - CHECKBOX_RIGHT_INSET }) : null, icon && /* @__PURE__ */ React24.createElement(React24.Fragment, null, renderIcon(icon), /* @__PURE__ */ React24.createElement(Spacer.Horizontal, { size: 8 })), /* @__PURE__ */ React24.createElement(Components4.ItemText, null, children), shortcut && /* @__PURE__ */ React24.createElement(React24.Fragment, null, /* @__PURE__ */ React24.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React24.createElement(Spacer.Horizontal, { size: 24 }), /* @__PURE__ */ React24.createElement(KeyboardShortcut, { shortcut })))
2451
+ /* @__PURE__ */ React25.createElement("div", { className: "flex flex-1 items-center" }, indented && /* @__PURE__ */ React25.createElement(Spacer.Horizontal, { size: CHECKBOX_INDENT_WIDTH }), checked ? /* @__PURE__ */ React25.createElement("div", { ...styles.itemIndicator }, /* @__PURE__ */ React25.createElement(Checkmark, null)) : indented ? /* @__PURE__ */ React25.createElement(Spacer.Horizontal, { size: CHECKBOX_WIDTH - CHECKBOX_RIGHT_INSET }) : null, icon && /* @__PURE__ */ React25.createElement(React25.Fragment, null, renderIcon(icon), /* @__PURE__ */ React25.createElement(Spacer.Horizontal, { size: 8 })), /* @__PURE__ */ React25.createElement(Components4.ItemText, null, children), shortcut && /* @__PURE__ */ React25.createElement(React25.Fragment, null, /* @__PURE__ */ React25.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React25.createElement(Spacer.Horizontal, { size: 24 }), /* @__PURE__ */ React25.createElement(KeyboardShortcut, { shortcut })))
2452
2452
  ));
2453
2453
  }
2454
2454
  );
2455
2455
  function Checkmark() {
2456
- return /* @__PURE__ */ React24.createElement(
2456
+ return /* @__PURE__ */ React25.createElement(
2457
2457
  "svg",
2458
2458
  {
2459
2459
  viewBox: "0 0 15 15",
@@ -2463,7 +2463,7 @@ function Checkmark() {
2463
2463
  width: 15,
2464
2464
  height: 15
2465
2465
  },
2466
- /* @__PURE__ */ React24.createElement(
2466
+ /* @__PURE__ */ React25.createElement(
2467
2467
  "path",
2468
2468
  {
2469
2469
  className: "scale-90 origin-center",
@@ -2487,10 +2487,10 @@ var MenuViewport = ({
2487
2487
  const hasCheckedItem = items.some(
2488
2488
  (item) => item.type !== "separator" && item.type !== "sectionHeader" && item.checked
2489
2489
  );
2490
- return /* @__PURE__ */ React25.createElement(React25.Fragment, null, items.map((item, index) => {
2490
+ return /* @__PURE__ */ React26.createElement(React26.Fragment, null, items.map((item, index) => {
2491
2491
  switch (item.type) {
2492
2492
  case "separator":
2493
- return /* @__PURE__ */ React25.createElement(
2493
+ return /* @__PURE__ */ React26.createElement(
2494
2494
  Components4.Separator,
2495
2495
  {
2496
2496
  key: index,
@@ -2498,7 +2498,7 @@ var MenuViewport = ({
2498
2498
  }
2499
2499
  );
2500
2500
  case "sectionHeader":
2501
- return /* @__PURE__ */ React25.createElement(
2501
+ return /* @__PURE__ */ React26.createElement(
2502
2502
  SectionHeader,
2503
2503
  {
2504
2504
  isFirst: index === 0,
@@ -2509,7 +2509,7 @@ var MenuViewport = ({
2509
2509
  );
2510
2510
  case "submenu":
2511
2511
  if (item.items && Components4.Sub && Components4.SubTrigger && Components4.SubContent && Components4.Portal) {
2512
- return /* @__PURE__ */ React25.createElement(Components4.Sub, { key: item.id }, /* @__PURE__ */ React25.createElement(
2512
+ return /* @__PURE__ */ React26.createElement(Components4.Sub, { key: item.id }, /* @__PURE__ */ React26.createElement(
2513
2513
  Components4.SubTrigger,
2514
2514
  {
2515
2515
  className: cx(
@@ -2523,7 +2523,7 @@ var MenuViewport = ({
2523
2523
  },
2524
2524
  disabled: item.disabled
2525
2525
  },
2526
- /* @__PURE__ */ React25.createElement(
2526
+ /* @__PURE__ */ React26.createElement(
2527
2527
  SelectItem,
2528
2528
  {
2529
2529
  value: item.id,
@@ -2534,17 +2534,17 @@ var MenuViewport = ({
2534
2534
  indented: hasCheckedItem,
2535
2535
  disabled: item.disabled
2536
2536
  },
2537
- /* @__PURE__ */ React25.createElement("div", { className: "flex items-center flex-1" }, item.title),
2538
- /* @__PURE__ */ React25.createElement(ChevronRightIcon, { className: "-mr-1" })
2537
+ /* @__PURE__ */ React26.createElement("div", { className: "flex items-center flex-1" }, item.title),
2538
+ /* @__PURE__ */ React26.createElement(ChevronRightIcon, { className: "-mr-1" })
2539
2539
  )
2540
- ), /* @__PURE__ */ React25.createElement(Components4.Portal, null, /* @__PURE__ */ React25.createElement(
2540
+ ), /* @__PURE__ */ React26.createElement(Components4.Portal, null, /* @__PURE__ */ React26.createElement(
2541
2541
  Components4.SubContent,
2542
2542
  {
2543
2543
  ...portalScopeProps(portalScopeId),
2544
2544
  alignOffset: -5,
2545
2545
  className: styles.contentStyle
2546
2546
  },
2547
- /* @__PURE__ */ React25.createElement(
2547
+ /* @__PURE__ */ React26.createElement(
2548
2548
  MenuViewport,
2549
2549
  {
2550
2550
  items: item.items,
@@ -2555,7 +2555,7 @@ var MenuViewport = ({
2555
2555
  )));
2556
2556
  } else return null;
2557
2557
  default:
2558
- return /* @__PURE__ */ React25.createElement(
2558
+ return /* @__PURE__ */ React26.createElement(
2559
2559
  SelectItem,
2560
2560
  {
2561
2561
  key: item.value,
@@ -2578,7 +2578,7 @@ var MenuViewport = ({
2578
2578
  // src/components/DropdownMenu.tsx
2579
2579
  var Components = {
2580
2580
  Separator: RadixDropdownMenu.Separator,
2581
- ItemText: React26.Fragment,
2581
+ ItemText: React27.Fragment,
2582
2582
  Item: RadixDropdownMenu.Item,
2583
2583
  CheckboxItem: RadixDropdownMenu.CheckboxItem,
2584
2584
  ItemIndicator: RadixDropdownMenu.ItemIndicator,
@@ -2618,14 +2618,14 @@ var DropdownMenuRoot = forwardRefGeneric(function DropdownMenuRoot2(props, forwa
2618
2618
  }),
2619
2619
  [contentStyle]
2620
2620
  );
2621
- return /* @__PURE__ */ React26.createElement(RadixDropdownMenu.Root, { onOpenChange, open }, /* @__PURE__ */ React26.createElement(
2621
+ return /* @__PURE__ */ React27.createElement(RadixDropdownMenu.Root, { onOpenChange, open }, /* @__PURE__ */ React27.createElement(
2622
2622
  RadixDropdownMenu.Trigger,
2623
2623
  {
2624
2624
  ref: forwardedRef,
2625
2625
  asChild: true
2626
2626
  },
2627
2627
  children
2628
- ), /* @__PURE__ */ React26.createElement(RadixDropdownMenu.Portal, null, /* @__PURE__ */ React26.createElement(
2628
+ ), /* @__PURE__ */ React27.createElement(RadixDropdownMenu.Portal, null, /* @__PURE__ */ React27.createElement(
2629
2629
  RadixDropdownMenu.Content,
2630
2630
  {
2631
2631
  ...portalScopeProps(portalScopeId),
@@ -2639,7 +2639,7 @@ var DropdownMenuRoot = forwardRefGeneric(function DropdownMenuRoot2(props, forwa
2639
2639
  ...{ onCloseAutoFocus }
2640
2640
  },
2641
2641
  items.length === 0 ? emptyState : null,
2642
- /* @__PURE__ */ React26.createElement(
2642
+ /* @__PURE__ */ React27.createElement(
2643
2643
  MenuViewport,
2644
2644
  {
2645
2645
  items,
@@ -2670,14 +2670,14 @@ var ActionMenu = memoGeneric(function ActionMenu2({
2670
2670
  ...style2
2671
2671
  };
2672
2672
  }, [selected, style2, variant]);
2673
- return /* @__PURE__ */ React27.createElement(
2673
+ return /* @__PURE__ */ React28.createElement(
2674
2674
  DropdownMenu,
2675
2675
  {
2676
2676
  items: menuItems,
2677
2677
  onSelect,
2678
2678
  onOpenChange
2679
2679
  },
2680
- /* @__PURE__ */ React27.createElement(
2680
+ /* @__PURE__ */ React28.createElement(
2681
2681
  IconButton,
2682
2682
  {
2683
2683
  style: internalStyle,
@@ -2691,16 +2691,16 @@ var ActionMenu = memoGeneric(function ActionMenu2({
2691
2691
  });
2692
2692
 
2693
2693
  // src/components/ActivityIndicator.tsx
2694
- import * as React28 from "react";
2695
- var ActivityIndicator = React28.memo(function ActivityIndicator2({
2694
+ import * as React29 from "react";
2695
+ var ActivityIndicator = React29.memo(function ActivityIndicator2({
2696
2696
  size: size2 = 16,
2697
2697
  opacity = 1,
2698
2698
  color = "black",
2699
2699
  trackColor = "rgba(0, 0, 0, 0.1)",
2700
2700
  className
2701
2701
  }) {
2702
- const opacityStyle = React28.useMemo(() => ({ opacity }), [opacity]);
2703
- const dynamicStyles = React28.useMemo(
2702
+ const opacityStyle = React29.useMemo(() => ({ opacity }), [opacity]);
2703
+ const dynamicStyles = React29.useMemo(
2704
2704
  () => ({
2705
2705
  border: `2px solid ${trackColor}`,
2706
2706
  borderTopColor: color,
@@ -2709,19 +2709,19 @@ var ActivityIndicator = React28.memo(function ActivityIndicator2({
2709
2709
  }),
2710
2710
  [size2, color, trackColor]
2711
2711
  );
2712
- return /* @__PURE__ */ React28.createElement(
2712
+ return /* @__PURE__ */ React29.createElement(
2713
2713
  "div",
2714
2714
  {
2715
2715
  className: cx("flex justify-center items-center", className),
2716
2716
  style: opacityStyle
2717
2717
  },
2718
- /* @__PURE__ */ React28.createElement("div", { style: dynamicStyles, className: "animate-spin rounded-[50%]" })
2718
+ /* @__PURE__ */ React29.createElement("div", { style: dynamicStyles, className: "animate-spin rounded-[50%]" })
2719
2719
  );
2720
2720
  });
2721
2721
 
2722
2722
  // src/components/Avatar.tsx
2723
2723
  import * as AvatarPrimitive from "@radix-ui/react-avatar";
2724
- import React29, { forwardRef as forwardRef10, useMemo as useMemo14 } from "react";
2724
+ import React30, { forwardRef as forwardRef10, useMemo as useMemo14 } from "react";
2725
2725
 
2726
2726
  // src/utils/colorFromString.ts
2727
2727
  var colorForStringValues = {
@@ -2790,7 +2790,7 @@ var getInnerAvatarStyles = (size2, variant) => {
2790
2790
  minHeight: dimension
2791
2791
  };
2792
2792
  };
2793
- var AvatarRoot = React29.forwardRef(
2793
+ var AvatarRoot = React30.forwardRef(
2794
2794
  ({
2795
2795
  className,
2796
2796
  size: size2 = 21,
@@ -2809,7 +2809,7 @@ var AvatarRoot = React29.forwardRef(
2809
2809
  }),
2810
2810
  [backgroundColor, size2, style2]
2811
2811
  );
2812
- return /* @__PURE__ */ React29.createElement(
2812
+ return /* @__PURE__ */ React30.createElement(
2813
2813
  AvatarPrimitive.Root,
2814
2814
  {
2815
2815
  ref,
@@ -2824,8 +2824,8 @@ var AvatarRoot = React29.forwardRef(
2824
2824
  );
2825
2825
  }
2826
2826
  );
2827
- var AvatarImage = React29.forwardRef(({ className, size: size2 = 21, variant = "normal", ...props }, ref) => {
2828
- return /* @__PURE__ */ React29.createElement(
2827
+ var AvatarImage = React30.forwardRef(({ className, size: size2 = 21, variant = "normal", ...props }, ref) => {
2828
+ return /* @__PURE__ */ React30.createElement(
2829
2829
  AvatarPrimitive.Image,
2830
2830
  {
2831
2831
  ref,
@@ -2841,9 +2841,9 @@ var AvatarImage = React29.forwardRef(({ className, size: size2 = 21, variant = "
2841
2841
  function getMonogram(text) {
2842
2842
  return text?.at(0)?.toLocaleUpperCase();
2843
2843
  }
2844
- var AvatarFallback = React29.forwardRef(
2844
+ var AvatarFallback = React30.forwardRef(
2845
2845
  ({ className, children, style: style2, size: size2 = 21, backgroundColor, ...props }, ref) => {
2846
- return /* @__PURE__ */ React29.createElement(
2846
+ return /* @__PURE__ */ React30.createElement(
2847
2847
  AvatarPrimitive.Fallback,
2848
2848
  {
2849
2849
  ref,
@@ -2864,7 +2864,7 @@ var AvatarFallback = React29.forwardRef(
2864
2864
  );
2865
2865
  }
2866
2866
  );
2867
- var Avatar = React29.memo(
2867
+ var Avatar = React30.memo(
2868
2868
  forwardRef10(function Avatar2({
2869
2869
  image,
2870
2870
  name,
@@ -2877,7 +2877,7 @@ var Avatar = React29.memo(
2877
2877
  ...props
2878
2878
  }, forwardedRef) {
2879
2879
  const getBackgroundColor = backgroundColor ?? colorFromString(userId ?? name ?? "");
2880
- return /* @__PURE__ */ React29.createElement(
2880
+ return /* @__PURE__ */ React30.createElement(
2881
2881
  AvatarRoot,
2882
2882
  {
2883
2883
  ref: forwardedRef,
@@ -2887,7 +2887,7 @@ var Avatar = React29.memo(
2887
2887
  className,
2888
2888
  ...props
2889
2889
  },
2890
- image ? /* @__PURE__ */ React29.createElement(AvatarImage, { src: image, alt: name, size: size2, variant }) : /* @__PURE__ */ React29.createElement(
2890
+ image ? /* @__PURE__ */ React30.createElement(AvatarImage, { src: image, alt: name, size: size2, variant }) : /* @__PURE__ */ React30.createElement(
2891
2891
  AvatarFallback,
2892
2892
  {
2893
2893
  backgroundColor: getBackgroundColor,
@@ -2899,31 +2899,31 @@ var Avatar = React29.memo(
2899
2899
  );
2900
2900
  })
2901
2901
  );
2902
- var OverflowAvatar = React29.memo(function OverflowAvatar2({
2902
+ var OverflowAvatar = React30.memo(function OverflowAvatar2({
2903
2903
  size: size2 = 21,
2904
2904
  count
2905
2905
  }) {
2906
- return /* @__PURE__ */ React29.createElement(AvatarRoot, { size: size2, backgroundColor: "var(--n-text-disabled)", disabled: true }, /* @__PURE__ */ React29.createElement(AvatarFallback, { backgroundColor: "var(--n-text-disabled)", size: size2 }, "+", count));
2906
+ return /* @__PURE__ */ React30.createElement(AvatarRoot, { size: size2, backgroundColor: "var(--n-text-disabled)", disabled: true }, /* @__PURE__ */ React30.createElement(AvatarFallback, { backgroundColor: "var(--n-text-disabled)", size: size2 }, "+", count));
2907
2907
  });
2908
- var AvatarStack = React29.memo(function AvatarStack2({
2908
+ var AvatarStack = React30.memo(function AvatarStack2({
2909
2909
  size: size2 = 21,
2910
2910
  children,
2911
2911
  max = 3,
2912
2912
  className
2913
2913
  }) {
2914
- const avatarCount = React29.Children.count(children);
2914
+ const avatarCount = React30.Children.count(children);
2915
2915
  const overflowCount = avatarCount - max;
2916
2916
  const childrenArray = useMemo14(() => {
2917
- const processedChildren = React29.Children.toArray(children).map((child) => React29.cloneElement(child, { size: size2 })).slice(0, max);
2917
+ const processedChildren = React30.Children.toArray(children).map((child) => React30.cloneElement(child, { size: size2 })).slice(0, max);
2918
2918
  if (avatarCount > max) {
2919
2919
  return [
2920
- /* @__PURE__ */ React29.createElement(OverflowAvatar, { key: "overflow", size: size2, count: overflowCount }),
2920
+ /* @__PURE__ */ React30.createElement(OverflowAvatar, { key: "overflow", size: size2, count: overflowCount }),
2921
2921
  ...processedChildren
2922
2922
  ];
2923
2923
  }
2924
2924
  return processedChildren;
2925
2925
  }, [children, max, size2, avatarCount, overflowCount]);
2926
- return /* @__PURE__ */ React29.createElement(
2926
+ return /* @__PURE__ */ React30.createElement(
2927
2927
  "div",
2928
2928
  {
2929
2929
  className: cx(
@@ -2933,7 +2933,7 @@ var AvatarStack = React29.memo(function AvatarStack2({
2933
2933
  )
2934
2934
  },
2935
2935
  childrenArray.map((child, index) => {
2936
- return /* @__PURE__ */ React29.createElement(
2936
+ return /* @__PURE__ */ React30.createElement(
2937
2937
  "div",
2938
2938
  {
2939
2939
  className: cx("relative", size2 > 36 ? "-ml-3" : "-ml-1.5"),
@@ -2946,10 +2946,10 @@ var AvatarStack = React29.memo(function AvatarStack2({
2946
2946
  });
2947
2947
 
2948
2948
  // src/components/NoyaLogo.tsx
2949
- import React30, { forwardRef as forwardRef11 } from "react";
2949
+ import React31, { forwardRef as forwardRef11 } from "react";
2950
2950
  var Logo = forwardRef11(function Logo2(props, ref) {
2951
2951
  const fill = props.fill || cssVars.colors.logoFill;
2952
- return /* @__PURE__ */ React30.createElement(
2952
+ return /* @__PURE__ */ React31.createElement(
2953
2953
  "svg",
2954
2954
  {
2955
2955
  ref,
@@ -2959,14 +2959,14 @@ var Logo = forwardRef11(function Logo2(props, ref) {
2959
2959
  ...props,
2960
2960
  className: "w-6 aspect-[24/26]"
2961
2961
  },
2962
- /* @__PURE__ */ React30.createElement(
2962
+ /* @__PURE__ */ React31.createElement(
2963
2963
  "path",
2964
2964
  {
2965
2965
  d: "M6.5 3H2V12H5V6H6.5C7.32843 6 8 6.67157 8 7.5V12H11V7.5C11 5.01472 8.98528 3 6.5 3Z",
2966
2966
  fill
2967
2967
  }
2968
2968
  ),
2969
- /* @__PURE__ */ React30.createElement(
2969
+ /* @__PURE__ */ React31.createElement(
2970
2970
  "path",
2971
2971
  {
2972
2972
  fillRule: "evenodd",
@@ -2975,14 +2975,14 @@ var Logo = forwardRef11(function Logo2(props, ref) {
2975
2975
  fill
2976
2976
  }
2977
2977
  ),
2978
- /* @__PURE__ */ React30.createElement(
2978
+ /* @__PURE__ */ React31.createElement(
2979
2979
  "path",
2980
2980
  {
2981
2981
  d: "M5 14H2V18.5C2 20.9853 4.01472 23 6.5 23H8V26H11V17H8V20H6.5C5.67157 20 5 19.3284 5 18.5V14Z",
2982
2982
  fill
2983
2983
  }
2984
2984
  ),
2985
- /* @__PURE__ */ React30.createElement(
2985
+ /* @__PURE__ */ React31.createElement(
2986
2986
  "path",
2987
2987
  {
2988
2988
  fillRule: "evenodd",
@@ -2995,10 +2995,10 @@ var Logo = forwardRef11(function Logo2(props, ref) {
2995
2995
  });
2996
2996
 
2997
2997
  // src/components/ai-assistant/AIAssistantLayout.tsx
2998
- import React32, { forwardRef as forwardRef13 } from "react";
2998
+ import React33, { forwardRef as forwardRef13 } from "react";
2999
2999
 
3000
3000
  // src/components/TextArea.tsx
3001
- import React31, {
3001
+ import React32, {
3002
3002
  forwardRef as forwardRef12,
3003
3003
  memo as memo12,
3004
3004
  useCallback as useCallback15,
@@ -3044,7 +3044,7 @@ var TextArea = memo12(
3044
3044
  },
3045
3045
  [autoResize, autoResizeRef, forwardedRef]
3046
3046
  );
3047
- return /* @__PURE__ */ React31.createElement(
3047
+ return /* @__PURE__ */ React32.createElement(
3048
3048
  "textarea",
3049
3049
  {
3050
3050
  className: cx(
@@ -3069,31 +3069,31 @@ var TextAreaRow = memo12(
3069
3069
  endClassName,
3070
3070
  ...rest
3071
3071
  }, forwardedRef) {
3072
- return /* @__PURE__ */ React31.createElement(
3072
+ return /* @__PURE__ */ React32.createElement(
3073
3073
  "div",
3074
3074
  {
3075
3075
  ref: forwardedRef,
3076
3076
  className: cx("relative w-full h-full", className)
3077
3077
  },
3078
- /* @__PURE__ */ React31.createElement(TextArea, { className: textAreaClassName, ...rest, ref: textAreaRef }),
3079
- /* @__PURE__ */ React31.createElement("div", { className: cx("absolute right-1 top-4", endClassName) }, end)
3078
+ /* @__PURE__ */ React32.createElement(TextArea, { className: textAreaClassName, ...rest, ref: textAreaRef }),
3079
+ /* @__PURE__ */ React32.createElement("div", { className: cx("absolute right-1 top-4", endClassName) }, end)
3080
3080
  );
3081
3081
  })
3082
3082
  );
3083
3083
 
3084
3084
  // src/components/ai-assistant/AIAssistantLayout.tsx
3085
3085
  var AIAssistantLoadingIndicator = () => {
3086
- return /* @__PURE__ */ React32.createElement("div", { className: "flex gap-2" }, /* @__PURE__ */ React32.createElement(
3086
+ return /* @__PURE__ */ React33.createElement("div", { className: "flex gap-2" }, /* @__PURE__ */ React33.createElement(
3087
3087
  Avatar,
3088
3088
  {
3089
3089
  name: "Assistant",
3090
3090
  size: INPUT_HEIGHT,
3091
3091
  backgroundColor: cssVars.colors.primaryPastel
3092
3092
  },
3093
- /* @__PURE__ */ React32.createElement(Logo, { style: { width: 15 }, fill: cssVars.colors.primary })
3094
- ), /* @__PURE__ */ React32.createElement("div", { className: "animate-pulse" }, "\u258B"));
3093
+ /* @__PURE__ */ React33.createElement(Logo, { style: { width: 15 }, fill: cssVars.colors.primary })
3094
+ ), /* @__PURE__ */ React33.createElement("div", { className: "animate-pulse" }, "\u258B"));
3095
3095
  };
3096
- var AIAssistantInput = forwardRef13(({ value, onChange, onSubmitClick, onKeyDown, disabled }, ref) => /* @__PURE__ */ React32.createElement(
3096
+ var AIAssistantInput = forwardRef13(({ value, onChange, onSubmitClick, onKeyDown, disabled }, ref) => /* @__PURE__ */ React33.createElement(
3097
3097
  TextAreaRow,
3098
3098
  {
3099
3099
  autoResize: true,
@@ -3105,7 +3105,7 @@ var AIAssistantInput = forwardRef13(({ value, onChange, onSubmitClick, onKeyDown
3105
3105
  placeholder: "Tell me what you'd like to do...",
3106
3106
  onKeyDown,
3107
3107
  disabled,
3108
- end: /* @__PURE__ */ React32.createElement(
3108
+ end: /* @__PURE__ */ React33.createElement(
3109
3109
  IconButton,
3110
3110
  {
3111
3111
  iconName: "ArrowUpIcon",
@@ -3130,13 +3130,13 @@ var AIAssistantLayout = forwardRef13(
3130
3130
  className,
3131
3131
  style: style2
3132
3132
  }, ref) => {
3133
- return /* @__PURE__ */ React32.createElement("div", { className: cx("flex flex-col flex-1", className), style: style2 }, /* @__PURE__ */ React32.createElement("div", { className: "flex-1 min-h-0 overflow-auto", ref }, /* @__PURE__ */ React32.createElement("div", { className: "flex flex-col gap-2 pb-4 pt-1" }, renderMessages(), isLoading ? renderLoadingIndicator?.() : null)), /* @__PURE__ */ React32.createElement("div", { className: "border-t border-divider pt-1 px-1" }, renderInput()));
3133
+ return /* @__PURE__ */ React33.createElement("div", { className: cx("flex flex-col flex-1", className), style: style2 }, /* @__PURE__ */ React33.createElement("div", { className: "flex-1 min-h-0 overflow-auto", ref }, /* @__PURE__ */ React33.createElement("div", { className: "flex flex-col gap-2 pb-4 pt-1" }, renderMessages(), isLoading ? renderLoadingIndicator?.() : null)), /* @__PURE__ */ React33.createElement("div", { className: "border-t border-divider pt-1 px-1" }, renderInput()));
3134
3134
  }
3135
3135
  );
3136
3136
 
3137
3137
  // src/components/AnimatePresence.tsx
3138
3138
  import { isDeepEqual as isDeepEqual3 } from "@noya-app/noya-utils";
3139
- import React33, {
3139
+ import React34, {
3140
3140
  Children as Children2,
3141
3141
  isValidElement as isValidElement2,
3142
3142
  useCallback as useCallback16,
@@ -3216,7 +3216,7 @@ var PresenceChild = ({
3216
3216
  if (animationState === "exited" && !isPresent) {
3217
3217
  return null;
3218
3218
  }
3219
- return /* @__PURE__ */ React33.createElement("div", { style: mergedAnimationStyles[animationState], className }, children);
3219
+ return /* @__PURE__ */ React34.createElement("div", { style: mergedAnimationStyles[animationState], className }, children);
3220
3220
  };
3221
3221
  var AnimatePresence = ({
3222
3222
  children,
@@ -3291,7 +3291,7 @@ var AnimatePresence = ({
3291
3291
  return filtered;
3292
3292
  });
3293
3293
  }, []);
3294
- return /* @__PURE__ */ React33.createElement(React33.Fragment, null, mountedChildren.map(({ child, isPresent, skipInitialAnimation: skipInitialAnimation2 }) => /* @__PURE__ */ React33.createElement(
3294
+ return /* @__PURE__ */ React34.createElement(React34.Fragment, null, mountedChildren.map(({ child, isPresent, skipInitialAnimation: skipInitialAnimation2 }) => /* @__PURE__ */ React34.createElement(
3295
3295
  PresenceChild,
3296
3296
  {
3297
3297
  key: child.key,
@@ -3307,13 +3307,13 @@ var AnimatePresence = ({
3307
3307
  };
3308
3308
 
3309
3309
  // src/components/Banner.tsx
3310
- import React34 from "react";
3310
+ import React35 from "react";
3311
3311
  var bannerStyles = {
3312
3312
  backgroundColor: cssVars.colors.inputBackground,
3313
3313
  color: cssVars.colors.textDisabled
3314
3314
  };
3315
3315
  function Banner({ label = "No items", className, style: style2 }) {
3316
- return /* @__PURE__ */ React34.createElement(
3316
+ return /* @__PURE__ */ React35.createElement(
3317
3317
  "div",
3318
3318
  {
3319
3319
  className: cx(
@@ -3322,15 +3322,15 @@ function Banner({ label = "No items", className, style: style2 }) {
3322
3322
  ),
3323
3323
  style: { ...bannerStyles, ...style2 }
3324
3324
  },
3325
- /* @__PURE__ */ React34.createElement(Small, { color: "textDisabled" }, label)
3325
+ /* @__PURE__ */ React35.createElement(Small, { color: "textDisabled" }, label)
3326
3326
  );
3327
3327
  }
3328
3328
 
3329
3329
  // src/components/Breadcrumbs.tsx
3330
3330
  import { forwardRef as forwardRef14 } from "react";
3331
- import React35 from "react";
3331
+ import React36 from "react";
3332
3332
  var BreadcrumbText = forwardRef14(function BreadcrumbText2({ children, className, onClick, ...props }, ref) {
3333
- return /* @__PURE__ */ React35.createElement(
3333
+ return /* @__PURE__ */ React36.createElement(
3334
3334
  Text,
3335
3335
  {
3336
3336
  ...props,
@@ -3350,7 +3350,7 @@ var slashStyle = {
3350
3350
  margin: "0 3px"
3351
3351
  };
3352
3352
  var BreadcrumbSlash = () => {
3353
- return /* @__PURE__ */ React35.createElement(
3353
+ return /* @__PURE__ */ React36.createElement(
3354
3354
  "svg",
3355
3355
  {
3356
3356
  width: "7",
@@ -3361,7 +3361,7 @@ var BreadcrumbSlash = () => {
3361
3361
  opacity: 0.5,
3362
3362
  style: slashStyle
3363
3363
  },
3364
- /* @__PURE__ */ React35.createElement(
3364
+ /* @__PURE__ */ React36.createElement(
3365
3365
  "path",
3366
3366
  {
3367
3367
  d: "M1 16L6 1",
@@ -3375,16 +3375,16 @@ var BreadcrumbSlash = () => {
3375
3375
  };
3376
3376
 
3377
3377
  // src/components/Checkbox.tsx
3378
- import * as React36 from "react";
3378
+ import * as React37 from "react";
3379
3379
  var colorSchemeStyles = {
3380
3380
  normal: "text-text-subtle",
3381
3381
  primary: "text-primary",
3382
3382
  secondary: "text-secondary"
3383
3383
  };
3384
- var Checkbox = React36.memo(
3385
- React36.forwardRef(function Checkbox2({ className, style: style2, colorScheme = "secondary", ...props }, ref) {
3384
+ var Checkbox = React37.memo(
3385
+ React37.forwardRef(function Checkbox2({ className, style: style2, colorScheme = "secondary", ...props }, ref) {
3386
3386
  const { fieldId: id } = useLabel({ fieldId: props.id });
3387
- return /* @__PURE__ */ React36.createElement(
3387
+ return /* @__PURE__ */ React37.createElement(
3388
3388
  "div",
3389
3389
  {
3390
3390
  className: cx(
@@ -3394,7 +3394,7 @@ var Checkbox = React36.memo(
3394
3394
  ),
3395
3395
  style: style2
3396
3396
  },
3397
- /* @__PURE__ */ React36.createElement(
3397
+ /* @__PURE__ */ React37.createElement(
3398
3398
  "input",
3399
3399
  {
3400
3400
  ref,
@@ -3423,7 +3423,7 @@ var Checkbox = React36.memo(
3423
3423
  id
3424
3424
  }
3425
3425
  ),
3426
- /* @__PURE__ */ React36.createElement(
3426
+ /* @__PURE__ */ React37.createElement(
3427
3427
  "svg",
3428
3428
  {
3429
3429
  className: `
@@ -3443,7 +3443,7 @@ var Checkbox = React36.memo(
3443
3443
  xmlns: "http://www.w3.org/2000/svg",
3444
3444
  "aria-hidden": "true"
3445
3445
  },
3446
- /* @__PURE__ */ React36.createElement(
3446
+ /* @__PURE__ */ React37.createElement(
3447
3447
  "path",
3448
3448
  {
3449
3449
  d: "M3 6L4.5 7.5L8 4",
@@ -3459,10 +3459,10 @@ var Checkbox = React36.memo(
3459
3459
 
3460
3460
  // src/components/Chip.tsx
3461
3461
  import { Cross1Icon, PlusIcon } from "@noya-app/noya-icons";
3462
- import React38, { forwardRef as forwardRef16, memo as memo14 } from "react";
3462
+ import React39, { forwardRef as forwardRef16, memo as memo14 } from "react";
3463
3463
 
3464
3464
  // src/hooks/useHover.ts
3465
- import * as React37 from "react";
3465
+ import * as React38 from "react";
3466
3466
  var globalIgnoreEmulatedMouseEvents = false;
3467
3467
  var hoverCount = 0;
3468
3468
  function setGlobalIgnoreEmulatedMouseEvents() {
@@ -3492,13 +3492,13 @@ function setupGlobalTouchEvents() {
3492
3492
  }
3493
3493
  function useHover(props = {}) {
3494
3494
  const { onHoverStart, onHoverChange, onHoverEnd, isDisabled } = props;
3495
- const [isHovered, setHovered] = React37.useState(false);
3496
- const state = React37.useRef({
3495
+ const [isHovered, setHovered] = React38.useState(false);
3496
+ const state = React38.useRef({
3497
3497
  isHovered: false,
3498
3498
  ignoreEmulatedMouseEvents: false
3499
3499
  }).current;
3500
- React37.useEffect(setupGlobalTouchEvents, []);
3501
- const hoverProps = React37.useMemo(
3500
+ React38.useEffect(setupGlobalTouchEvents, []);
3501
+ const hoverProps = React38.useMemo(
3502
3502
  function getHoverProps() {
3503
3503
  function triggerHoverStart(event, pointerType) {
3504
3504
  if (isDisabled || pointerType === "touch" || state.isHovered) {
@@ -3644,7 +3644,7 @@ var Chip = memo14(
3644
3644
  className
3645
3645
  );
3646
3646
  const color = colorScheme === "primary" ? cssVars.colors.primary : colorScheme === "secondary" ? cssVars.colors.secondary : cssVars.colors.text;
3647
- return /* @__PURE__ */ React38.createElement(
3647
+ return /* @__PURE__ */ React39.createElement(
3648
3648
  "span",
3649
3649
  {
3650
3650
  ref: forwardedRef,
@@ -3654,7 +3654,7 @@ var Chip = memo14(
3654
3654
  tabIndex,
3655
3655
  ...rest
3656
3656
  },
3657
- addable && /* @__PURE__ */ React38.createElement(
3657
+ addable && /* @__PURE__ */ React39.createElement(
3658
3658
  PlusIcon,
3659
3659
  {
3660
3660
  className: cx(ICON_BASE_STYLES, ICON_SIZE_STYLES[size2].add),
@@ -3666,7 +3666,7 @@ var Chip = memo14(
3666
3666
  }
3667
3667
  ),
3668
3668
  children,
3669
- deletable && /* @__PURE__ */ React38.createElement(
3669
+ deletable && /* @__PURE__ */ React39.createElement(
3670
3670
  Cross1Icon,
3671
3671
  {
3672
3672
  className: cx(ICON_BASE_STYLES, ICON_SIZE_STYLES[size2].delete),
@@ -3683,10 +3683,10 @@ var Chip = memo14(
3683
3683
  );
3684
3684
 
3685
3685
  // src/components/Collection.tsx
3686
- import React51 from "react";
3686
+ import React52 from "react";
3687
3687
 
3688
3688
  // src/components/Grid.tsx
3689
- import React43, { useImperativeHandle as useImperativeHandle3, useRef as useRef17, useState as useState21 } from "react";
3689
+ import React44, { useImperativeHandle as useImperativeHandle3, useRef as useRef17, useState as useState21 } from "react";
3690
3690
 
3691
3691
  // src/utils/selection.ts
3692
3692
  function updateSelection(allIds, selectedIds, clickedId, event) {
@@ -3714,7 +3714,7 @@ function updateSelection(allIds, selectedIds, clickedId, event) {
3714
3714
  }
3715
3715
 
3716
3716
  // src/components/EditableText.tsx
3717
- import React39, {
3717
+ import React40, {
3718
3718
  forwardRef as forwardRef17,
3719
3719
  memo as memo15,
3720
3720
  useCallback as useCallback17,
@@ -3723,7 +3723,7 @@ import React39, {
3723
3723
  useRef as useRef16,
3724
3724
  useState as useState19
3725
3725
  } from "react";
3726
- var defaultRenderPreview = (props) => /* @__PURE__ */ React39.createElement(BreadcrumbText, { ...props });
3726
+ var defaultRenderPreview = (props) => /* @__PURE__ */ React40.createElement(BreadcrumbText, { ...props });
3727
3727
  var EditableText = memo15(
3728
3728
  forwardRef17(function EditableText2({
3729
3729
  value,
@@ -3800,7 +3800,7 @@ var EditableText = memo15(
3800
3800
  style: textStyle,
3801
3801
  className: textClassName
3802
3802
  });
3803
- const input = /* @__PURE__ */ React39.createElement("div", { className: "flex absolute inset-0 -mx-1.5 -my-1" }, /* @__PURE__ */ React39.createElement(InputField2.Root, { onFocusChange: setFocused }, /* @__PURE__ */ React39.createElement(
3803
+ const input = /* @__PURE__ */ React40.createElement("div", { className: "flex absolute inset-0 -mx-1.5 -my-1" }, /* @__PURE__ */ React40.createElement(InputField2.Root, { onFocusChange: setFocused }, /* @__PURE__ */ React40.createElement(
3804
3804
  InputField2.Input,
3805
3805
  {
3806
3806
  ref: inputRef,
@@ -3840,12 +3840,12 @@ var EditableText = memo15(
3840
3840
  }
3841
3841
  }
3842
3842
  )));
3843
- return /* @__PURE__ */ React39.createElement("div", { className: cx("flex relative", className), style: style2 }, preview, focused && !readOnly && input);
3843
+ return /* @__PURE__ */ React40.createElement("div", { className: cx("flex relative", className), style: style2 }, preview, focused && !readOnly && input);
3844
3844
  })
3845
3845
  );
3846
3846
 
3847
3847
  // src/components/GridView.tsx
3848
- import React42, {
3848
+ import React43, {
3849
3849
  createContext as createContext8,
3850
3850
  forwardRef as forwardRef18,
3851
3851
  memo as memo17,
@@ -3857,10 +3857,10 @@ import React42, {
3857
3857
  // src/components/ContextMenu.tsx
3858
3858
  import { useKeyboardShortcuts as useKeyboardShortcuts2 } from "@noya-app/noya-keymap";
3859
3859
  import * as RadixContextMenu from "@radix-ui/react-context-menu";
3860
- import React40, { useCallback as useCallback18, useMemo as useMemo16 } from "react";
3860
+ import React41, { useCallback as useCallback18, useMemo as useMemo16 } from "react";
3861
3861
  var Components2 = {
3862
3862
  Separator: RadixContextMenu.Separator,
3863
- ItemText: React40.Fragment,
3863
+ ItemText: React41.Fragment,
3864
3864
  Item: RadixContextMenu.Item,
3865
3865
  CheckboxItem: RadixContextMenu.CheckboxItem,
3866
3866
  ItemIndicator: RadixContextMenu.ItemIndicator,
@@ -3892,13 +3892,13 @@ function ContextMenuRoot({
3892
3892
  },
3893
3893
  [onSelect]
3894
3894
  );
3895
- return /* @__PURE__ */ React40.createElement(RadixContextMenu.Root, { onOpenChange }, /* @__PURE__ */ React40.createElement(RadixContextMenu.Trigger, { asChild: true, onPointerDown }, children), /* @__PURE__ */ React40.createElement(RadixContextMenu.Portal, null, /* @__PURE__ */ React40.createElement(
3895
+ return /* @__PURE__ */ React41.createElement(RadixContextMenu.Root, { onOpenChange }, /* @__PURE__ */ React41.createElement(RadixContextMenu.Trigger, { asChild: true, onPointerDown }, children), /* @__PURE__ */ React41.createElement(RadixContextMenu.Portal, null, /* @__PURE__ */ React41.createElement(
3896
3896
  RadixContextMenu.Content,
3897
3897
  {
3898
3898
  ...portalScopeProps(portalScopeId),
3899
3899
  className: styles.contentStyle
3900
3900
  },
3901
- /* @__PURE__ */ React40.createElement(
3901
+ /* @__PURE__ */ React41.createElement(
3902
3902
  MenuViewport,
3903
3903
  {
3904
3904
  items,
@@ -3912,26 +3912,26 @@ var ContextMenu = memoGeneric(ContextMenuRoot);
3912
3912
 
3913
3913
  // src/components/ScrollArea.tsx
3914
3914
  import * as RadixScrollArea from "@radix-ui/react-scroll-area";
3915
- import * as React41 from "react";
3916
- var ScrollArea = React41.memo(function ScrollArea2({ children }) {
3917
- const [scrollElementRef, setScrollElementRef] = React41.useState(null);
3918
- return /* @__PURE__ */ React41.createElement("div", { className: "flex-1 min-h-0" }, /* @__PURE__ */ React41.createElement(RadixScrollArea.Root, { style: { width: "100%", height: "100%" } }, /* @__PURE__ */ React41.createElement(
3915
+ import * as React42 from "react";
3916
+ var ScrollArea = React42.memo(function ScrollArea2({ children }) {
3917
+ const [scrollElementRef, setScrollElementRef] = React42.useState(null);
3918
+ return /* @__PURE__ */ React42.createElement("div", { className: "flex-1 min-h-0" }, /* @__PURE__ */ React42.createElement(RadixScrollArea.Root, { style: { width: "100%", height: "100%" } }, /* @__PURE__ */ React42.createElement(
3919
3919
  RadixScrollArea.Viewport,
3920
3920
  {
3921
3921
  className: "w-full h-full [&>div]:block",
3922
- ref: React41.useCallback(
3922
+ ref: React42.useCallback(
3923
3923
  (ref) => setScrollElementRef(ref),
3924
3924
  []
3925
3925
  )
3926
3926
  },
3927
3927
  typeof children === "function" ? scrollElementRef ? children(scrollElementRef) : null : children
3928
- ), /* @__PURE__ */ React41.createElement(
3928
+ ), /* @__PURE__ */ React42.createElement(
3929
3929
  RadixScrollArea.Scrollbar,
3930
3930
  {
3931
3931
  orientation: "vertical",
3932
3932
  className: "scroll-component flex p-[3px] data-[orientation=vertical]:w-[10px]"
3933
3933
  },
3934
- /* @__PURE__ */ React41.createElement(RadixScrollArea.Thumb, { className: "scroll-component flex-1 rounded-[10px] bg-scrollbar" })
3934
+ /* @__PURE__ */ React42.createElement(RadixScrollArea.Thumb, { className: "scroll-component flex-1 rounded-[10px] bg-scrollbar" })
3935
3935
  )));
3936
3936
  });
3937
3937
 
@@ -3940,7 +3940,7 @@ var ItemTitle = ({
3940
3940
  showBackground,
3941
3941
  children
3942
3942
  }) => {
3943
- return /* @__PURE__ */ React42.createElement(
3943
+ return /* @__PURE__ */ React43.createElement(
3944
3944
  "span",
3945
3945
  {
3946
3946
  className: cx(
@@ -3955,7 +3955,7 @@ var ItemDescription = ({
3955
3955
  showBackground,
3956
3956
  children
3957
3957
  }) => {
3958
- return /* @__PURE__ */ React42.createElement(
3958
+ return /* @__PURE__ */ React43.createElement(
3959
3959
  "span",
3960
3960
  {
3961
3961
  className: cx(
@@ -3970,7 +3970,7 @@ var SectionTitle = ({
3970
3970
  last = false,
3971
3971
  children
3972
3972
  }) => {
3973
- return /* @__PURE__ */ React42.createElement(
3973
+ return /* @__PURE__ */ React43.createElement(
3974
3974
  "span",
3975
3975
  {
3976
3976
  className: `font-sans text-heading3 font-medium user-select-none truncate ${last ? "text-text" : "text-text-muted"}`
@@ -4026,7 +4026,7 @@ var GridViewItem = forwardRefGeneric(function GridViewItem2({
4026
4026
  },
4027
4027
  [onSelect, onKeyDown]
4028
4028
  );
4029
- let element = /* @__PURE__ */ React42.createElement(
4029
+ let element = /* @__PURE__ */ React43.createElement(
4030
4030
  "div",
4031
4031
  {
4032
4032
  ...props,
@@ -4049,7 +4049,7 @@ var GridViewItem = forwardRefGeneric(function GridViewItem2({
4049
4049
  onDoubleClick,
4050
4050
  onContextMenu
4051
4051
  },
4052
- /* @__PURE__ */ React42.createElement(
4052
+ /* @__PURE__ */ React43.createElement(
4053
4053
  "div",
4054
4054
  {
4055
4055
  className: cx(
@@ -4060,13 +4060,13 @@ var GridViewItem = forwardRefGeneric(function GridViewItem2({
4060
4060
  },
4061
4061
  children
4062
4062
  ),
4063
- textPosition === "below" && /* @__PURE__ */ React42.createElement(React42.Fragment, null, /* @__PURE__ */ React42.createElement(Spacer.Vertical, { size: 8 }), /* @__PURE__ */ React42.createElement(ItemTitle, null, title || " "), /* @__PURE__ */ React42.createElement(Spacer.Vertical, { size: 2 }), /* @__PURE__ */ React42.createElement(ItemDescription, null, subtitle || " ")),
4064
- textPosition === "overlay" && hovered && (title || subtitle) && /* @__PURE__ */ React42.createElement("div", { className: "absolute inset-0 flex flex-col justify-end items-start p-1 pointer-events-none truncate gap-0.5" }, title && /* @__PURE__ */ React42.createElement(ItemTitle, { showBackground: true }, title), subtitle && /* @__PURE__ */ React42.createElement(ItemDescription, { showBackground: true }, subtitle)),
4065
- action && /* @__PURE__ */ React42.createElement("div", { className: "absolute top-[7px] right-[7px] flex flex-col justify-end items-start p-1 truncate gap-0.5" }, action),
4066
- loading && /* @__PURE__ */ React42.createElement("div", { className: "flex flex-col justify-start items-end p-1 pointer-events-none animate-shimmer absolute inset-0 bg-gradient-to-r from-white/0 via-[rgb(226,232,240)]/50 to-white/0 bg-length:200%_100%]" }, /* @__PURE__ */ React42.createElement(ActivityIndicator, { opacity: 0.5, size: 13 }))
4063
+ textPosition === "below" && /* @__PURE__ */ React43.createElement(React43.Fragment, null, /* @__PURE__ */ React43.createElement(Spacer.Vertical, { size: 8 }), /* @__PURE__ */ React43.createElement(ItemTitle, null, title || " "), /* @__PURE__ */ React43.createElement(Spacer.Vertical, { size: 2 }), /* @__PURE__ */ React43.createElement(ItemDescription, null, subtitle || " ")),
4064
+ textPosition === "overlay" && hovered && (title || subtitle) && /* @__PURE__ */ React43.createElement("div", { className: "absolute inset-0 flex flex-col justify-end items-start p-1 pointer-events-none truncate gap-0.5" }, title && /* @__PURE__ */ React43.createElement(ItemTitle, { showBackground: true }, title), subtitle && /* @__PURE__ */ React43.createElement(ItemDescription, { showBackground: true }, subtitle)),
4065
+ action && /* @__PURE__ */ React43.createElement("div", { className: "absolute top-[7px] right-[7px] flex flex-col justify-end items-start p-1 truncate gap-0.5" }, action),
4066
+ loading && /* @__PURE__ */ React43.createElement("div", { className: "flex flex-col justify-start items-end p-1 pointer-events-none animate-shimmer absolute inset-0 bg-gradient-to-r from-white/0 via-[rgb(226,232,240)]/50 to-white/0 bg-length:200%_100%]" }, /* @__PURE__ */ React43.createElement(ActivityIndicator, { opacity: 0.5, size: 13 }))
4067
4067
  );
4068
4068
  if (menuItems && onSelectMenuItem) {
4069
- element = /* @__PURE__ */ React42.createElement(
4069
+ element = /* @__PURE__ */ React43.createElement(
4070
4070
  ContextMenu,
4071
4071
  {
4072
4072
  items: menuItems,
@@ -4077,10 +4077,10 @@ var GridViewItem = forwardRefGeneric(function GridViewItem2({
4077
4077
  );
4078
4078
  }
4079
4079
  if (textPosition === "toolip") {
4080
- element = /* @__PURE__ */ React42.createElement(
4080
+ element = /* @__PURE__ */ React43.createElement(
4081
4081
  Tooltip,
4082
4082
  {
4083
- content: /* @__PURE__ */ React42.createElement("div", { className: "flex flex-col gap-0.5" }, /* @__PURE__ */ React42.createElement(ItemTitle, null, title), /* @__PURE__ */ React42.createElement(ItemDescription, null, subtitle))
4083
+ content: /* @__PURE__ */ React43.createElement("div", { className: "flex flex-col gap-0.5" }, /* @__PURE__ */ React43.createElement(ItemTitle, null, title), /* @__PURE__ */ React43.createElement(ItemDescription, null, subtitle))
4084
4084
  },
4085
4085
  element
4086
4086
  );
@@ -4135,8 +4135,8 @@ var GridViewRoot = forwardRef18(function GridViewRoot2({
4135
4135
  categories: ["flex"]
4136
4136
  });
4137
4137
  }, [className, scrollable]);
4138
- const content = /* @__PURE__ */ React42.createElement("div", { className: cx("p-3", contentClassName) }, children);
4139
- return /* @__PURE__ */ React42.createElement(GridViewContext.Provider, { value: contextValue }, /* @__PURE__ */ React42.createElement(
4138
+ const content = /* @__PURE__ */ React43.createElement("div", { className: cx("p-3", contentClassName) }, children);
4139
+ return /* @__PURE__ */ React43.createElement(GridViewContext.Provider, { value: contextValue }, /* @__PURE__ */ React43.createElement(
4140
4140
  "div",
4141
4141
  {
4142
4142
  onClick: handleClick,
@@ -4144,7 +4144,7 @@ var GridViewRoot = forwardRef18(function GridViewRoot2({
4144
4144
  ...props,
4145
4145
  ref: forwardedRef
4146
4146
  },
4147
- scrollable ? /* @__PURE__ */ React42.createElement(ScrollArea, null, content) : content
4147
+ scrollable ? /* @__PURE__ */ React43.createElement(ScrollArea, null, content) : content
4148
4148
  ));
4149
4149
  });
4150
4150
  function GridViewSection({
@@ -4157,8 +4157,8 @@ function GridViewSection({
4157
4157
  gridTemplateColumns: `repeat(auto-fill, minmax(${minColumnWidth}, 1fr))`,
4158
4158
  gap: `${gap}px`
4159
4159
  };
4160
- const isEmpty = React42.Children.count(children) === 0;
4161
- return isEmpty && renderEmptyState ? renderEmptyState() : /* @__PURE__ */ React42.createElement(
4160
+ const isEmpty = React43.Children.count(children) === 0;
4161
+ return isEmpty && renderEmptyState ? renderEmptyState() : /* @__PURE__ */ React43.createElement(
4162
4162
  "div",
4163
4163
  {
4164
4164
  role: "presentation",
@@ -4170,9 +4170,9 @@ function GridViewSection({
4170
4170
  }
4171
4171
  function GridViewSectionHeader({ title }) {
4172
4172
  const grouped = title.split("/");
4173
- return /* @__PURE__ */ React42.createElement("div", { className: "px-5" }, /* @__PURE__ */ React42.createElement(Spacer.Vertical, { size: 24 }), withSeparatorElements(
4174
- grouped.map((title2, index) => /* @__PURE__ */ React42.createElement(SectionTitle, { last: index === grouped.length - 1 }, title2)),
4175
- /* @__PURE__ */ React42.createElement(SectionTitle, null, " / ")
4173
+ return /* @__PURE__ */ React43.createElement("div", { className: "px-5" }, /* @__PURE__ */ React43.createElement(Spacer.Vertical, { size: 24 }), withSeparatorElements(
4174
+ grouped.map((title2, index) => /* @__PURE__ */ React43.createElement(SectionTitle, { last: index === grouped.length - 1 }, title2)),
4175
+ /* @__PURE__ */ React43.createElement(SectionTitle, null, " / ")
4176
4176
  ));
4177
4177
  }
4178
4178
  var GridView;
@@ -4287,7 +4287,7 @@ var Grid = memoGeneric(
4287
4287
  onFilesDrop
4288
4288
  );
4289
4289
  const { minColumnWidth, gap } = getGridSize(size2);
4290
- return /* @__PURE__ */ React43.createElement(
4290
+ return /* @__PURE__ */ React44.createElement(
4291
4291
  GridView.Root,
4292
4292
  {
4293
4293
  role: "listbox",
@@ -4304,7 +4304,7 @@ var Grid = memoGeneric(
4304
4304
  ...dropTargetProps,
4305
4305
  ref: fileDropTargetRef
4306
4306
  },
4307
- items.length > 0 ? /* @__PURE__ */ React43.createElement(GridView.Section, null, items.map((item) => {
4307
+ items.length > 0 ? /* @__PURE__ */ React44.createElement(GridView.Section, null, items.map((item) => {
4308
4308
  const id = getId(item);
4309
4309
  const isDropdownOpen = dropdownOpenId === id;
4310
4310
  const isHovered = testHoveredId === id || currentHoveredId === id || isDropdownOpen;
@@ -4323,7 +4323,7 @@ var Grid = memoGeneric(
4323
4323
  handleSelect(id);
4324
4324
  }
4325
4325
  };
4326
- const action = (isHovered || isSelected) && !isRenaming && (typeof renderAction === "function" ? renderAction({ item, selected: isSelected, onOpenChange }) : renderAction === "menu" && menuItems && /* @__PURE__ */ React43.createElement(
4326
+ const action = (isHovered || isSelected) && !isRenaming && (typeof renderAction === "function" ? renderAction({ item, selected: isSelected, onOpenChange }) : renderAction === "menu" && menuItems && /* @__PURE__ */ React44.createElement(
4327
4327
  ActionMenu,
4328
4328
  {
4329
4329
  menuItems,
@@ -4332,7 +4332,7 @@ var Grid = memoGeneric(
4332
4332
  onOpenChange
4333
4333
  }
4334
4334
  ));
4335
- return /* @__PURE__ */ React43.createElement(
4335
+ return /* @__PURE__ */ React44.createElement(
4336
4336
  GridView.Item,
4337
4337
  {
4338
4338
  key: id,
@@ -4345,7 +4345,7 @@ var Grid = memoGeneric(
4345
4345
  onHoverChange: (isHovering) => {
4346
4346
  setHoveredId(isHovering ? id : void 0);
4347
4347
  },
4348
- title: /* @__PURE__ */ React43.createElement(
4348
+ title: /* @__PURE__ */ React44.createElement(
4349
4349
  EditableText,
4350
4350
  {
4351
4351
  tabIndex: isRenaming ? void 0 : -1,
@@ -4362,7 +4362,7 @@ var Grid = memoGeneric(
4362
4362
  },
4363
4363
  textClassName: "bg-listview-editing-background max-h-input-height"
4364
4364
  },
4365
- (props2) => /* @__PURE__ */ React43.createElement(
4365
+ (props2) => /* @__PURE__ */ React44.createElement(
4366
4366
  "span",
4367
4367
  {
4368
4368
  ...props2,
@@ -4373,7 +4373,7 @@ var Grid = memoGeneric(
4373
4373
  }
4374
4374
  )
4375
4375
  ),
4376
- subtitle: /* @__PURE__ */ React43.createElement(
4376
+ subtitle: /* @__PURE__ */ React44.createElement(
4377
4377
  "span",
4378
4378
  {
4379
4379
  className: cx(
@@ -4407,7 +4407,7 @@ var Grid = memoGeneric(
4407
4407
  }
4408
4408
  }
4409
4409
  },
4410
- thumbnail && /* @__PURE__ */ React43.createElement(
4410
+ thumbnail && /* @__PURE__ */ React44.createElement(
4411
4411
  "div",
4412
4412
  {
4413
4413
  className: cx(
@@ -4425,12 +4425,12 @@ var Grid = memoGeneric(
4425
4425
  );
4426
4426
 
4427
4427
  // src/components/List.tsx
4428
- import React50, { memo as memo19, useImperativeHandle as useImperativeHandle5, useRef as useRef20, useState as useState23 } from "react";
4428
+ import React51, { memo as memo19, useImperativeHandle as useImperativeHandle5, useRef as useRef20, useState as useState23 } from "react";
4429
4429
 
4430
4430
  // src/components/ListView.tsx
4431
4431
  import { range } from "@noya-app/noya-utils";
4432
4432
  import { composeRefs as composeRefs2 } from "@radix-ui/react-compose-refs";
4433
- import React48, {
4433
+ import React49, {
4434
4434
  Children as Children3,
4435
4435
  createContext as createContext11,
4436
4436
  forwardRef as forwardRef19,
@@ -4477,13 +4477,13 @@ import {
4477
4477
  useSortable,
4478
4478
  verticalListSortingStrategy
4479
4479
  } from "@dnd-kit/sortable";
4480
- import * as React47 from "react";
4480
+ import * as React48 from "react";
4481
4481
 
4482
4482
  // src/components/sorting/DragRegistration.tsx
4483
- import React44 from "react";
4484
- var DragRegistrationContext = React44.createContext(null);
4483
+ import React45 from "react";
4484
+ var DragRegistrationContext = React45.createContext(null);
4485
4485
  function useDragRegistration(context) {
4486
- const value = React44.useContext(context);
4486
+ const value = React45.useContext(context);
4487
4487
  if (!value) {
4488
4488
  throw new Error(
4489
4489
  "useDragRegistration must be used within a DragRegistrationProvider"
@@ -4492,11 +4492,11 @@ function useDragRegistration(context) {
4492
4492
  return value;
4493
4493
  }
4494
4494
  function useDragRegistrationManager() {
4495
- const [registeredLists, setRegisteredLists] = React44.useState(/* @__PURE__ */ new Map());
4496
- const registerList = React44.useCallback((list) => {
4495
+ const [registeredLists, setRegisteredLists] = React45.useState(/* @__PURE__ */ new Map());
4496
+ const registerList = React45.useCallback((list) => {
4497
4497
  setRegisteredLists((prev) => new Map(prev).set(list.id, list));
4498
4498
  }, []);
4499
- const unregisterList = React44.useCallback((listId) => {
4499
+ const unregisterList = React45.useCallback((listId) => {
4500
4500
  setRegisteredLists((prev) => {
4501
4501
  const newMap = new Map(prev);
4502
4502
  newMap.delete(listId);
@@ -4505,15 +4505,15 @@ function useDragRegistrationManager() {
4505
4505
  }, []);
4506
4506
  return { registerList, unregisterList, registeredLists };
4507
4507
  }
4508
- var ActiveDragContext = React44.createContext(null);
4508
+ var ActiveDragContext = React45.createContext(null);
4509
4509
  function useActiveDrag(context) {
4510
- const value = React44.useContext(context);
4510
+ const value = React45.useContext(context);
4511
4511
  if (!value) {
4512
4512
  throw new Error("useActiveDrag must be used within a ActiveDragProvider");
4513
4513
  }
4514
4514
  return value;
4515
4515
  }
4516
- var AnyDragContext = React44.createContext(false);
4516
+ var AnyDragContext = React45.createContext(false);
4517
4517
 
4518
4518
  // src/components/sorting/SharedDragProvider.tsx
4519
4519
  import {
@@ -4527,7 +4527,7 @@ import {
4527
4527
  } from "@dnd-kit/core";
4528
4528
  import { rectContainsPoint, unionRects } from "@noya-app/noya-geometry";
4529
4529
  import { windowsOf } from "@noya-app/noya-utils";
4530
- import * as React45 from "react";
4530
+ import * as React46 from "react";
4531
4531
  import { useMemo as useMemo19 } from "react";
4532
4532
  import { createPortal as createPortal2 } from "react-dom";
4533
4533
  function SharedDragProvider({
@@ -4546,14 +4546,14 @@ function SharedDragProvider({
4546
4546
  })
4547
4547
  );
4548
4548
  const mounted = useMounted();
4549
- const [dragState, setDragState] = React45.useState({
4549
+ const [dragState, setDragState] = React46.useState({
4550
4550
  source: null,
4551
4551
  target: null,
4552
4552
  indicator: null
4553
4553
  });
4554
4554
  const { registerList, unregisterList, registeredLists } = useDragRegistrationManager();
4555
- const activatorEventRef = React45.useRef(null);
4556
- const handleDragStart = React45.useCallback(
4555
+ const activatorEventRef = React46.useRef(null);
4556
+ const handleDragStart = React46.useCallback(
4557
4557
  (event) => {
4558
4558
  activatorEventRef.current = event.activatorEvent;
4559
4559
  for (const [listId, list] of registeredLists) {
@@ -4575,7 +4575,7 @@ function SharedDragProvider({
4575
4575
  },
4576
4576
  [registeredLists]
4577
4577
  );
4578
- const handleDragMove = React45.useCallback(
4578
+ const handleDragMove = React46.useCallback(
4579
4579
  (event) => {
4580
4580
  const { active, over } = event;
4581
4581
  if (!activatorEventRef.current || !dragState.source) return;
@@ -4599,7 +4599,7 @@ function SharedDragProvider({
4599
4599
  [registeredLists, dragState.source]
4600
4600
  );
4601
4601
  const stableOnMoveItem = useStableCallback(onMoveItem);
4602
- const handleDragEnd = React45.useCallback(
4602
+ const handleDragEnd = React46.useCallback(
4603
4603
  (event) => {
4604
4604
  const { active, over } = event;
4605
4605
  if (!activatorEventRef.current || !dragState.source) return;
@@ -4639,7 +4639,7 @@ function SharedDragProvider({
4639
4639
  },
4640
4640
  [registeredLists, dragState.source, stableOnMoveItem]
4641
4641
  );
4642
- const contextValue = React45.useMemo(
4642
+ const contextValue = React46.useMemo(
4643
4643
  () => ({
4644
4644
  registerList,
4645
4645
  unregisterList
@@ -4647,19 +4647,19 @@ function SharedDragProvider({
4647
4647
  [registerList, unregisterList]
4648
4648
  );
4649
4649
  const activeList = dragState.source ? registeredLists.get(dragState.source.listId) : null;
4650
- const activeDragContextValue = React45.useMemo(
4650
+ const activeDragContextValue = React46.useMemo(
4651
4651
  () => dragState,
4652
4652
  [dragState]
4653
4653
  );
4654
4654
  const collisionDetection = useMemo19(() => {
4655
4655
  return getItemFirstCollisionDetection(registeredLists);
4656
4656
  }, [registeredLists]);
4657
- return /* @__PURE__ */ React45.createElement(AnyDragContext.Provider, { value: true }, /* @__PURE__ */ React45.createElement(sharedDragProps.dragRegistrationContext.Provider, { value: contextValue }, /* @__PURE__ */ React45.createElement(
4657
+ return /* @__PURE__ */ React46.createElement(AnyDragContext.Provider, { value: true }, /* @__PURE__ */ React46.createElement(sharedDragProps.dragRegistrationContext.Provider, { value: contextValue }, /* @__PURE__ */ React46.createElement(
4658
4658
  sharedDragProps.activeDragContext.Provider,
4659
4659
  {
4660
4660
  value: activeDragContextValue
4661
4661
  },
4662
- /* @__PURE__ */ React45.createElement(
4662
+ /* @__PURE__ */ React46.createElement(
4663
4663
  DndContext,
4664
4664
  {
4665
4665
  sensors,
@@ -4670,26 +4670,26 @@ function SharedDragProvider({
4670
4670
  },
4671
4671
  children,
4672
4672
  mounted && activeList?.renderOverlay && dragState.source && createPortal2(
4673
- /* @__PURE__ */ React45.createElement(DragOverlay, { dropAnimation: null }, activeList.renderOverlay(dragState.source.itemId)),
4673
+ /* @__PURE__ */ React46.createElement(DragOverlay, { dropAnimation: null }, activeList.renderOverlay(dragState.source.itemId)),
4674
4674
  document.body
4675
4675
  )
4676
4676
  )
4677
4677
  )));
4678
4678
  }
4679
4679
  function useMounted() {
4680
- const [mounted, setMounted] = React45.useState(false);
4681
- React45.useEffect(() => {
4680
+ const [mounted, setMounted] = React46.useState(false);
4681
+ React46.useEffect(() => {
4682
4682
  setMounted(true);
4683
4683
  }, []);
4684
4684
  return mounted;
4685
4685
  }
4686
4686
  function withDragProvider(Component) {
4687
4687
  return function WithDragProvider(props) {
4688
- const anyDragContext = React45.useContext(AnyDragContext);
4688
+ const anyDragContext = React46.useContext(AnyDragContext);
4689
4689
  if (!anyDragContext) {
4690
- return /* @__PURE__ */ React45.createElement(SharedDragProvider, null, /* @__PURE__ */ React45.createElement(Component, { ...props }));
4690
+ return /* @__PURE__ */ React46.createElement(SharedDragProvider, null, /* @__PURE__ */ React46.createElement(Component, { ...props }));
4691
4691
  }
4692
- return /* @__PURE__ */ React45.createElement(Component, { ...props });
4692
+ return /* @__PURE__ */ React46.createElement(Component, { ...props });
4693
4693
  };
4694
4694
  }
4695
4695
  var getItemFirstCollisionDetection = (registeredLists) => (parameters) => {
@@ -4814,7 +4814,7 @@ function findDropTarget({
4814
4814
  }
4815
4815
 
4816
4816
  // src/components/sorting/sorting.ts
4817
- import * as React46 from "react";
4817
+ import * as React47 from "react";
4818
4818
  var normalizeListTargetIndex = (index, position) => {
4819
4819
  return position === "above" ? index : index + 1;
4820
4820
  };
@@ -4830,7 +4830,7 @@ var defaultAcceptsDrop = ({
4830
4830
  }
4831
4831
  return true;
4832
4832
  };
4833
- var SortableItemContext = React46.createContext({
4833
+ var SortableItemContext = React47.createContext({
4834
4834
  keys: [],
4835
4835
  acceptsDrop: defaultAcceptsDrop,
4836
4836
  axis: "y",
@@ -4899,7 +4899,7 @@ function parseDragItemKey(key) {
4899
4899
  }
4900
4900
 
4901
4901
  // src/components/sorting/Sortable.tsx
4902
- var SortableItemContext2 = React47.createContext({
4902
+ var SortableItemContext2 = React48.createContext({
4903
4903
  acceptsDrop: defaultAcceptsDrop,
4904
4904
  listId: "",
4905
4905
  getDropTargetParentIndex: void 0,
@@ -4912,7 +4912,7 @@ function useSortableDropIndicator({
4912
4912
  acceptsDrop: acceptsDrop2,
4913
4913
  getDropTargetParentIndex
4914
4914
  }) {
4915
- const { activeDragContext } = React47.useContext(SortableItemContext2);
4915
+ const { activeDragContext } = React48.useContext(SortableItemContext2);
4916
4916
  const activeDrag = useActiveDrag(activeDragContext);
4917
4917
  const { source, target } = activeDrag;
4918
4918
  if (!source || !target) return;
@@ -4943,13 +4943,13 @@ function SortableItem({
4943
4943
  disabled,
4944
4944
  children
4945
4945
  }) {
4946
- const { acceptsDrop: acceptsDrop2, listId, getDropTargetParentIndex } = React47.useContext(SortableItemContext2);
4946
+ const { acceptsDrop: acceptsDrop2, listId, getDropTargetParentIndex } = React48.useContext(SortableItemContext2);
4947
4947
  const dragItemKey = createDragItemKey(listId, id);
4948
4948
  const { attributes, listeners, setNodeRef, isDragging, index } = useSortable({
4949
4949
  id: dragItemKey,
4950
4950
  disabled
4951
4951
  });
4952
- const ref = React47.useCallback(
4952
+ const ref = React48.useCallback(
4953
4953
  (node) => setNodeRef(node),
4954
4954
  [setNodeRef]
4955
4955
  );
@@ -4983,9 +4983,9 @@ function SortableRoot_({
4983
4983
  sharedDragProps,
4984
4984
  containerRef
4985
4985
  }) {
4986
- const defaultId = React47.useId();
4986
+ const defaultId = React48.useId();
4987
4987
  const id = idProp ?? defaultId;
4988
- const keys = React47.useMemo(() => {
4988
+ const keys = React48.useMemo(() => {
4989
4989
  return keysProp.map((key) => createDragItemKey(id, key));
4990
4990
  }, [keysProp, id]);
4991
4991
  const { registerList, unregisterList } = useDragRegistration(
@@ -4994,7 +4994,7 @@ function SortableRoot_({
4994
4994
  const { setNodeRef: setDroppableRef } = useDroppable({
4995
4995
  id
4996
4996
  });
4997
- React47.useEffect(() => {
4997
+ React48.useEffect(() => {
4998
4998
  const listConfig = {
4999
4999
  id,
5000
5000
  keys,
@@ -5040,7 +5040,7 @@ function SortableRoot_({
5040
5040
  unregisterList,
5041
5041
  keys
5042
5042
  ]);
5043
- const contextValue = React47.useMemo(
5043
+ const contextValue = React48.useMemo(
5044
5044
  () => ({
5045
5045
  keys,
5046
5046
  acceptsDrop: acceptsDrop2,
@@ -5050,12 +5050,12 @@ function SortableRoot_({
5050
5050
  }),
5051
5051
  [keys, acceptsDrop2, id, getDropTargetParentIndex, sharedDragProps]
5052
5052
  );
5053
- React47.useEffect(() => {
5053
+ React48.useEffect(() => {
5054
5054
  if (containerRef) {
5055
5055
  setDroppableRef(containerRef.current);
5056
5056
  }
5057
5057
  });
5058
- return /* @__PURE__ */ React47.createElement(SortableItemContext2.Provider, { value: contextValue }, /* @__PURE__ */ React47.createElement(
5058
+ return /* @__PURE__ */ React48.createElement(SortableItemContext2.Provider, { value: contextValue }, /* @__PURE__ */ React48.createElement(
5059
5059
  SortableContext,
5060
5060
  {
5061
5061
  items: keys,
@@ -5072,11 +5072,11 @@ var Sortable_ = function Sortable_2({
5072
5072
  renderItem,
5073
5073
  ...rest
5074
5074
  }) {
5075
- const keys = React47.useMemo(
5075
+ const keys = React48.useMemo(
5076
5076
  () => items.map(keyExtractor),
5077
5077
  [items, keyExtractor]
5078
5078
  );
5079
- const renderOverlay = React47.useCallback(
5079
+ const renderOverlay = React48.useCallback(
5080
5080
  (index) => {
5081
5081
  return renderItem(
5082
5082
  items[index],
@@ -5096,14 +5096,14 @@ var Sortable_ = function Sortable_2({
5096
5096
  },
5097
5097
  [renderItem, items]
5098
5098
  );
5099
- return /* @__PURE__ */ React47.createElement(
5099
+ return /* @__PURE__ */ React48.createElement(
5100
5100
  SortableRoot,
5101
5101
  {
5102
5102
  ...rest,
5103
5103
  keys,
5104
5104
  renderOverlay: shouldRenderOverlay ? renderOverlay : void 0
5105
5105
  },
5106
- keys.map((key, index) => /* @__PURE__ */ React47.createElement(SortableItem, { key, id: key }, (props) => {
5106
+ keys.map((key, index) => /* @__PURE__ */ React48.createElement(SortableItem, { key, id: key }, (props) => {
5107
5107
  return renderItem(items[index], props, { isOverlay: false });
5108
5108
  }))
5109
5109
  );
@@ -5138,7 +5138,7 @@ var ListViewRowTitle = ({
5138
5138
  className,
5139
5139
  children,
5140
5140
  ...props
5141
- }) => /* @__PURE__ */ React48.createElement(
5141
+ }) => /* @__PURE__ */ React49.createElement(
5142
5142
  "span",
5143
5143
  {
5144
5144
  className: cx(
@@ -5166,7 +5166,7 @@ function ListViewEditableRowTitle({
5166
5166
  element.select();
5167
5167
  }, 1);
5168
5168
  }, [autoFocus]);
5169
- return /* @__PURE__ */ React48.createElement(
5169
+ return /* @__PURE__ */ React49.createElement(
5170
5170
  InputField2.Input,
5171
5171
  {
5172
5172
  ref: inputRef,
@@ -5205,7 +5205,7 @@ var RowContainer = forwardRef19(
5205
5205
  "aria-selected": ariaSelected,
5206
5206
  ...props
5207
5207
  }, ref) => {
5208
- return /* @__PURE__ */ React48.createElement(
5208
+ return /* @__PURE__ */ React49.createElement(
5209
5209
  "div",
5210
5210
  {
5211
5211
  ref,
@@ -5283,7 +5283,7 @@ var ListViewDragIndicatorElement = forwardRef19(
5283
5283
  style: style2,
5284
5284
  ...props
5285
5285
  }, ref) => {
5286
- return /* @__PURE__ */ React48.createElement(
5286
+ return /* @__PURE__ */ React49.createElement(
5287
5287
  "div",
5288
5288
  {
5289
5289
  ref,
@@ -5384,7 +5384,7 @@ var ListViewRow = forwardRefGeneric(function ListViewRow2({
5384
5384
  }, ref) => {
5385
5385
  const Component = RowContainer;
5386
5386
  const relativeDropPosition = testRelativeDropPosition ?? relativeDropPositionProp;
5387
- const element = /* @__PURE__ */ React48.createElement(
5387
+ const element = /* @__PURE__ */ React49.createElement(
5388
5388
  Component,
5389
5389
  {
5390
5390
  ref,
@@ -5418,7 +5418,7 @@ var ListViewRow = forwardRefGeneric(function ListViewRow2({
5418
5418
  className,
5419
5419
  $clickable: !!onPress
5420
5420
  },
5421
- relativeDropPosition && /* @__PURE__ */ React48.createElement(
5421
+ relativeDropPosition && /* @__PURE__ */ React49.createElement(
5422
5422
  ListViewDragIndicatorElement,
5423
5423
  {
5424
5424
  key: relativeDropPosition,
@@ -5433,11 +5433,11 @@ var ListViewRow = forwardRefGeneric(function ListViewRow2({
5433
5433
  }) : dragIndicatorStyle
5434
5434
  }
5435
5435
  ),
5436
- depth > 0 && /* @__PURE__ */ React48.createElement(Spacer.Horizontal, { size: depth * indentation }),
5436
+ depth > 0 && /* @__PURE__ */ React49.createElement(Spacer.Horizontal, { size: depth * indentation }),
5437
5437
  children
5438
5438
  );
5439
5439
  if (menuItems && onSelectMenuItem) {
5440
- return /* @__PURE__ */ React48.createElement(
5440
+ return /* @__PURE__ */ React49.createElement(
5441
5441
  ContextMenu,
5442
5442
  {
5443
5443
  items: menuItems,
@@ -5450,7 +5450,7 @@ var ListViewRow = forwardRefGeneric(function ListViewRow2({
5450
5450
  return element;
5451
5451
  };
5452
5452
  if (sortable && id) {
5453
- return /* @__PURE__ */ React48.createElement(Sortable.Item, { id, disabled: overrideSortable === false }, ({ ref: sortableRef, ...sortableProps }) => renderContent(
5453
+ return /* @__PURE__ */ React49.createElement(Sortable.Item, { id, disabled: overrideSortable === false }, ({ ref: sortableRef, ...sortableProps }) => renderContent(
5454
5454
  sortableProps,
5455
5455
  composeRefs2(sortableRef, forwardedRef)
5456
5456
  ));
@@ -5466,7 +5466,7 @@ var VirtualizedListRow = memo18(function VirtualizedListRow2({
5466
5466
  style: style2
5467
5467
  }) {
5468
5468
  const renderItem = useContext11(RenderItemContext);
5469
- return /* @__PURE__ */ React48.createElement("div", { key: index, style: style2 }, renderItem(index));
5469
+ return /* @__PURE__ */ React49.createElement("div", { key: index, style: style2 }, renderItem(index));
5470
5470
  });
5471
5471
  var VirtualizedListInner = forwardRefGeneric(function VirtualizedListInner2({
5472
5472
  size: size2,
@@ -5497,7 +5497,7 @@ var VirtualizedListInner = forwardRefGeneric(function VirtualizedListInner2({
5497
5497
  }),
5498
5498
  []
5499
5499
  );
5500
- return /* @__PURE__ */ React48.createElement(RenderItemContext.Provider, { value: renderItem }, /* @__PURE__ */ React48.createElement(
5500
+ return /* @__PURE__ */ React49.createElement(RenderItemContext.Provider, { value: renderItem }, /* @__PURE__ */ React49.createElement(
5501
5501
  WindowScroller,
5502
5502
  {
5503
5503
  scrollElement,
@@ -5508,7 +5508,7 @@ var VirtualizedListInner = forwardRefGeneric(function VirtualizedListInner2({
5508
5508
  registerChild,
5509
5509
  onChildScroll,
5510
5510
  scrollTop
5511
- }) => /* @__PURE__ */ React48.createElement("div", { ref: registerChild }, /* @__PURE__ */ React48.createElement(
5511
+ }) => /* @__PURE__ */ React49.createElement("div", { ref: registerChild }, /* @__PURE__ */ React49.createElement(
5512
5512
  VariableSizeList,
5513
5513
  {
5514
5514
  ref: listRef,
@@ -5682,7 +5682,7 @@ var ListViewRootInner = forwardRefGeneric(function ListViewRootInner2({
5682
5682
  [indentation]
5683
5683
  );
5684
5684
  const renderOverlay = useCallback23(
5685
- (index) => /* @__PURE__ */ React48.createElement("div", { style: { opacity: 0.25 } }, /* @__PURE__ */ React48.createElement(ListViewDraggingContext.Provider, { value: draggingContextOverlayValue }, renderItem(data[index], index, { isDragOverlay: true }))),
5685
+ (index) => /* @__PURE__ */ React49.createElement("div", { style: { opacity: 0.25 } }, /* @__PURE__ */ React49.createElement(ListViewDraggingContext.Provider, { value: draggingContextOverlayValue }, renderItem(data[index], index, { isDragOverlay: true }))),
5686
5686
  [draggingContextOverlayValue, renderItem, data]
5687
5687
  );
5688
5688
  const renderWrappedChild = useCallback23(
@@ -5690,12 +5690,12 @@ var ListViewRootInner = forwardRefGeneric(function ListViewRootInner2({
5690
5690
  const contextValue = getItemContextValue(index);
5691
5691
  const current = renderChild(index);
5692
5692
  if (!contextValue || !isValidElement3(current)) return null;
5693
- return /* @__PURE__ */ React48.createElement(ListRowContext.Provider, { key: current.key, value: contextValue }, current);
5693
+ return /* @__PURE__ */ React49.createElement(ListRowContext.Provider, { key: current.key, value: contextValue }, current);
5694
5694
  },
5695
5695
  [getItemContextValue, renderChild]
5696
5696
  );
5697
5697
  const ids = useMemo21(() => data.map(keyExtractor), [keyExtractor, data]);
5698
- const withSortable = (children) => sortable ? /* @__PURE__ */ React48.createElement(
5698
+ const withSortable = (children) => sortable ? /* @__PURE__ */ React49.createElement(
5699
5699
  Sortable.Root,
5700
5700
  {
5701
5701
  id: sortableId,
@@ -5708,7 +5708,7 @@ var ListViewRootInner = forwardRefGeneric(function ListViewRootInner2({
5708
5708
  },
5709
5709
  children
5710
5710
  ) : children;
5711
- const withScrollable = (children) => scrollable ? /* @__PURE__ */ React48.createElement(ScrollArea, null, children) : children(null);
5711
+ const withScrollable = (children) => scrollable ? /* @__PURE__ */ React49.createElement(ScrollArea, null, children) : children(null);
5712
5712
  const getItemHeight = useCallback23(
5713
5713
  (index) => {
5714
5714
  const child = getItemContextValue(index);
@@ -5723,7 +5723,7 @@ var ListViewRootInner = forwardRefGeneric(function ListViewRootInner2({
5723
5723
  );
5724
5724
  const draggingContextValue = useMemo21(() => ({ indentation }), [indentation]);
5725
5725
  const gapStyle = useMemo21(() => ({ gap: `${gap}px` }), [gap]);
5726
- return /* @__PURE__ */ React48.createElement(ListViewDraggingContext.Provider, { value: draggingContextValue }, /* @__PURE__ */ React48.createElement(
5726
+ return /* @__PURE__ */ React49.createElement(ListViewDraggingContext.Provider, { value: draggingContextValue }, /* @__PURE__ */ React49.createElement(
5727
5727
  "div",
5728
5728
  {
5729
5729
  id,
@@ -5752,7 +5752,7 @@ var ListViewRootInner = forwardRefGeneric(function ListViewRootInner2({
5752
5752
  },
5753
5753
  data.length === 0 && renderEmptyState ? renderEmptyState() : withScrollable(
5754
5754
  (scrollElementRef) => withSortable(
5755
- virtualized ? /* @__PURE__ */ React48.createElement(
5755
+ virtualized ? /* @__PURE__ */ React49.createElement(
5756
5756
  VirtualizedList,
5757
5757
  {
5758
5758
  ref: forwardedRef,
@@ -5776,7 +5776,7 @@ var ChildrenListViewInner = forwardRef19(function ChildrenListViewInner2({ child
5776
5776
  ),
5777
5777
  [children]
5778
5778
  );
5779
- return /* @__PURE__ */ React48.createElement(
5779
+ return /* @__PURE__ */ React49.createElement(
5780
5780
  ListViewRoot,
5781
5781
  {
5782
5782
  ref: forwardedRef,
@@ -5793,9 +5793,9 @@ var ChildrenListViewInner = forwardRef19(function ChildrenListViewInner2({ child
5793
5793
  var ChildrenListView = memo18(ChildrenListViewInner);
5794
5794
  var SimpleListViewInner = forwardRefGeneric(function SimpleListViewInner2(props, forwardedRef) {
5795
5795
  if ("children" in props) {
5796
- return /* @__PURE__ */ React48.createElement(ChildrenListView, { ref: forwardedRef, ...props });
5796
+ return /* @__PURE__ */ React49.createElement(ChildrenListView, { ref: forwardedRef, ...props });
5797
5797
  } else {
5798
- return /* @__PURE__ */ React48.createElement(ListViewRoot, { ref: forwardedRef, ...props });
5798
+ return /* @__PURE__ */ React49.createElement(ListViewRoot, { ref: forwardedRef, ...props });
5799
5799
  }
5800
5800
  });
5801
5801
  var SimpleListView = memoGeneric(SimpleListViewInner);
@@ -5819,7 +5819,7 @@ var ListView;
5819
5819
  })(ListView || (ListView = {}));
5820
5820
 
5821
5821
  // src/components/TreeView.tsx
5822
- import React49, { useCallback as useCallback24, useContext as useContext12 } from "react";
5822
+ import React50, { useCallback as useCallback24, useContext as useContext12 } from "react";
5823
5823
  var TreeRow = forwardRefGeneric(function TreeRow2({
5824
5824
  icon,
5825
5825
  expanded,
@@ -5836,7 +5836,7 @@ var TreeRow = forwardRefGeneric(function TreeRow2({
5836
5836
  },
5837
5837
  [onClickChevron]
5838
5838
  );
5839
- return /* @__PURE__ */ React49.createElement(ListView.Row, { ref: forwardedRef, ...rest }, expandable && /* @__PURE__ */ React49.createElement(React49.Fragment, null, expanded === void 0 ? /* @__PURE__ */ React49.createElement(Spacer.Horizontal, { size: 19 }) : /* @__PURE__ */ React49.createElement(
5839
+ return /* @__PURE__ */ React50.createElement(ListView.Row, { ref: forwardedRef, ...rest }, expandable && /* @__PURE__ */ React50.createElement(React50.Fragment, null, expanded === void 0 ? /* @__PURE__ */ React50.createElement(Spacer.Horizontal, { size: 19 }) : /* @__PURE__ */ React50.createElement(
5840
5840
  IconButton,
5841
5841
  {
5842
5842
  className: chevronClassName,
@@ -5844,7 +5844,7 @@ var TreeRow = forwardRefGeneric(function TreeRow2({
5844
5844
  onClick: handleClickChevron,
5845
5845
  selected: rest.selected
5846
5846
  }
5847
- ), /* @__PURE__ */ React49.createElement(Spacer.Horizontal, { size: 6 })), icon && /* @__PURE__ */ React49.createElement(React49.Fragment, null, renderIcon(icon), /* @__PURE__ */ React49.createElement(Spacer.Horizontal, { size: 10 })), children);
5847
+ ), /* @__PURE__ */ React50.createElement(Spacer.Horizontal, { size: 6 })), icon && /* @__PURE__ */ React50.createElement(React50.Fragment, null, renderIcon(icon), /* @__PURE__ */ React50.createElement(Spacer.Horizontal, { size: 10 })), children);
5848
5848
  });
5849
5849
  var TreeView;
5850
5850
  ((TreeView2) => {
@@ -5938,7 +5938,7 @@ var List = memoGeneric(
5938
5938
  setRenamingId(id);
5939
5939
  }
5940
5940
  }));
5941
- return /* @__PURE__ */ React50.createElement(
5941
+ return /* @__PURE__ */ React51.createElement(
5942
5942
  ViewComponent.Root,
5943
5943
  {
5944
5944
  variant: "bare",
@@ -5983,7 +5983,7 @@ var List = memoGeneric(
5983
5983
  handleSelect(id);
5984
5984
  }
5985
5985
  };
5986
- const action = (isHovered || isSelected) && !isRenaming && (typeof renderAction === "function" ? renderAction({ item, selected: isSelected, onOpenChange }) : renderAction === "menu" && menuItems && /* @__PURE__ */ React50.createElement(
5986
+ const action = (isHovered || isSelected) && !isRenaming && (typeof renderAction === "function" ? renderAction({ item, selected: isSelected, onOpenChange }) : renderAction === "menu" && menuItems && /* @__PURE__ */ React51.createElement(
5987
5987
  ActionMenu,
5988
5988
  {
5989
5989
  menuItems,
@@ -5999,7 +5999,7 @@ var List = memoGeneric(
5999
5999
  ));
6000
6000
  const end = action || detailPosition === "end" && renderDetail?.(item, isSelected);
6001
6001
  const below = detailPosition === "below" && renderDetail?.(item, isSelected);
6002
- return /* @__PURE__ */ React50.createElement(
6002
+ return /* @__PURE__ */ React51.createElement(
6003
6003
  ViewComponent.Row,
6004
6004
  {
6005
6005
  id,
@@ -6047,12 +6047,12 @@ var List = memoGeneric(
6047
6047
  },
6048
6048
  dragIndicatorStyle
6049
6049
  },
6050
- /* @__PURE__ */ React50.createElement(
6050
+ /* @__PURE__ */ React51.createElement(
6051
6051
  "div",
6052
6052
  {
6053
6053
  className: cx("flex flex-1 items-center px-2", rowGapMap[size2])
6054
6054
  },
6055
- thumbnail && /* @__PURE__ */ React50.createElement(
6055
+ thumbnail && /* @__PURE__ */ React51.createElement(
6056
6056
  "div",
6057
6057
  {
6058
6058
  className: cx(
@@ -6065,7 +6065,7 @@ var List = memoGeneric(
6065
6065
  },
6066
6066
  thumbnail
6067
6067
  ),
6068
- /* @__PURE__ */ React50.createElement("div", { className: "flex flex-col flex-1 w-0" }, /* @__PURE__ */ React50.createElement("div", { className: "flex items-center min-h-input-height flex-1 gap-2" }, /* @__PURE__ */ React50.createElement("div", { className: "flex-1 w-0 flex items-center", tabIndex: -1 }, isRenaming ? /* @__PURE__ */ React50.createElement(
6068
+ /* @__PURE__ */ React51.createElement("div", { className: "flex flex-col flex-1 w-0" }, /* @__PURE__ */ React51.createElement("div", { className: "flex items-center min-h-input-height flex-1 gap-2" }, /* @__PURE__ */ React51.createElement("div", { className: "flex-1 w-0 flex items-center", tabIndex: -1 }, isRenaming ? /* @__PURE__ */ React51.createElement(
6069
6069
  ViewComponent.EditableRowTitle,
6070
6070
  {
6071
6071
  value: getName(item),
@@ -6080,7 +6080,7 @@ var List = memoGeneric(
6080
6080
  e.stopPropagation();
6081
6081
  }
6082
6082
  }
6083
- ) : /* @__PURE__ */ React50.createElement(
6083
+ ) : /* @__PURE__ */ React51.createElement(
6084
6084
  ViewComponent.RowTitle,
6085
6085
  {
6086
6086
  className: cx(
@@ -6089,8 +6089,8 @@ var List = memoGeneric(
6089
6089
  )
6090
6090
  },
6091
6091
  getName(item)
6092
- )), end && detailPosition === "end" && /* @__PURE__ */ React50.createElement(DetailContainer, { selected: isSelected }, end)), below && /* @__PURE__ */ React50.createElement(DetailContainer, { selected: isSelected }, below)),
6093
- end && detailPosition === "below" && /* @__PURE__ */ React50.createElement(DetailContainer, { selected: isSelected }, end)
6092
+ )), end && detailPosition === "end" && /* @__PURE__ */ React51.createElement(DetailContainer, { selected: isSelected }, end)), below && /* @__PURE__ */ React51.createElement(DetailContainer, { selected: isSelected }, below)),
6093
+ end && detailPosition === "below" && /* @__PURE__ */ React51.createElement(DetailContainer, { selected: isSelected }, end)
6094
6094
  )
6095
6095
  );
6096
6096
  }
@@ -6102,7 +6102,7 @@ var DetailContainer = memo19(function DetailContainer2({
6102
6102
  children,
6103
6103
  selected
6104
6104
  }) {
6105
- return /* @__PURE__ */ React50.createElement(
6105
+ return /* @__PURE__ */ React51.createElement(
6106
6106
  "div",
6107
6107
  {
6108
6108
  className: cx("flex items-center gap-2", selected && "text-primary"),
@@ -6147,11 +6147,11 @@ var fontStyleMap = {
6147
6147
  // src/components/Collection.tsx
6148
6148
  var Collection = forwardRefGeneric(function Collection2(props, ref) {
6149
6149
  const { viewType, ...rest } = props;
6150
- return viewType === "grid" ? /* @__PURE__ */ React51.createElement(Grid, { ref, ...rest }) : /* @__PURE__ */ React51.createElement(List, { ref, ...rest });
6150
+ return viewType === "grid" ? /* @__PURE__ */ React52.createElement(Grid, { ref, ...rest }) : /* @__PURE__ */ React52.createElement(List, { ref, ...rest });
6151
6151
  });
6152
6152
 
6153
6153
  // src/components/ColorSwatch.tsx
6154
- import React52, { forwardRef as forwardRef20 } from "react";
6154
+ import React53, { forwardRef as forwardRef20 } from "react";
6155
6155
  var colorSwatchSizeMap = {
6156
6156
  xsmall: 21,
6157
6157
  small: 27,
@@ -6160,7 +6160,7 @@ var colorSwatchSizeMap = {
6160
6160
  };
6161
6161
  var ColorSwatch = forwardRef20(function ColorSwatch2({ color, size: size2 = "small", checked, style: style2, ...props }, ref) {
6162
6162
  const sizePx = colorSwatchSizeMap[size2];
6163
- return /* @__PURE__ */ React52.createElement(
6163
+ return /* @__PURE__ */ React53.createElement(
6164
6164
  "button",
6165
6165
  {
6166
6166
  ...props,
@@ -6181,7 +6181,7 @@ var ColorSwatch = forwardRef20(function ColorSwatch2({ color, size: size2 = "sma
6181
6181
 
6182
6182
  // src/components/ColorSwatchControl.tsx
6183
6183
  import * as ToggleGroupPrimitive from "@radix-ui/react-toggle-group";
6184
- import React53, { useMemo as useMemo22 } from "react";
6184
+ import React54, { useMemo as useMemo22 } from "react";
6185
6185
  function ColorSwatchControl(props) {
6186
6186
  const {
6187
6187
  options,
@@ -6204,8 +6204,8 @@ function ColorSwatchControl(props) {
6204
6204
  ...style2
6205
6205
  };
6206
6206
  }, [size2, style2]);
6207
- const content = /* @__PURE__ */ React53.createElement("div", { className, id, style: styles3 }, options.map((option) => {
6208
- const item = /* @__PURE__ */ React53.createElement(
6207
+ const content = /* @__PURE__ */ React54.createElement("div", { className, id, style: styles3 }, options.map((option) => {
6208
+ const item = /* @__PURE__ */ React54.createElement(
6209
6209
  ColorSwatch,
6210
6210
  {
6211
6211
  key: option,
@@ -6218,7 +6218,7 @@ function ColorSwatchControl(props) {
6218
6218
  checked: value === option
6219
6219
  }
6220
6220
  );
6221
- return /* @__PURE__ */ React53.createElement(
6221
+ return /* @__PURE__ */ React54.createElement(
6222
6222
  ToggleGroupPrimitive.Item,
6223
6223
  {
6224
6224
  asChild: true,
@@ -6229,7 +6229,7 @@ function ColorSwatchControl(props) {
6229
6229
  item
6230
6230
  );
6231
6231
  }));
6232
- return /* @__PURE__ */ React53.createElement(
6232
+ return /* @__PURE__ */ React54.createElement(
6233
6233
  ToggleGroupPrimitive.Root,
6234
6234
  {
6235
6235
  type: "single",
@@ -6244,7 +6244,7 @@ function ColorSwatchControl(props) {
6244
6244
 
6245
6245
  // src/components/Combobox.tsx
6246
6246
  import { DropdownChevronIcon as DropdownChevronIcon2 } from "@noya-app/noya-icons";
6247
- import React55, {
6247
+ import React56, {
6248
6248
  useCallback as useCallback25,
6249
6249
  useEffect as useEffect19,
6250
6250
  useImperativeHandle as useImperativeHandle6,
@@ -6586,7 +6586,7 @@ function useComboboxState(state) {
6586
6586
 
6587
6587
  // src/components/ComboboxMenu.tsx
6588
6588
  import { CheckIcon } from "@noya-app/noya-icons";
6589
- import React54 from "react";
6589
+ import React55 from "react";
6590
6590
  var ComboboxMenu = memoGeneric(
6591
6591
  forwardRefGeneric(function ComboboxMenu2({
6592
6592
  items,
@@ -6598,7 +6598,7 @@ var ComboboxMenu = memoGeneric(
6598
6598
  indented,
6599
6599
  iconPosition = "right"
6600
6600
  }, forwardedRef) {
6601
- return /* @__PURE__ */ React54.createElement(
6601
+ return /* @__PURE__ */ React55.createElement(
6602
6602
  ListView.Root,
6603
6603
  {
6604
6604
  ref: forwardedRef,
@@ -6614,7 +6614,7 @@ var ComboboxMenu = memoGeneric(
6614
6614
  style: style2,
6615
6615
  renderItem: (item, i) => {
6616
6616
  if (item.type === "sectionHeader") {
6617
- return /* @__PURE__ */ React54.createElement(ListView.Row, { key: item.id, isSectionHeader: true }, indented && /* @__PURE__ */ React54.createElement(
6617
+ return /* @__PURE__ */ React55.createElement(ListView.Row, { key: item.id, isSectionHeader: true }, indented && /* @__PURE__ */ React55.createElement(
6618
6618
  Spacer.Horizontal,
6619
6619
  {
6620
6620
  size: CHECKBOX_WIDTH - CHECKBOX_RIGHT_INSET + CHECKBOX_INDENT_WIDTH
@@ -6625,7 +6625,7 @@ var ComboboxMenu = memoGeneric(
6625
6625
  item: typeof item.title === "string" ? item.title : item.value,
6626
6626
  itemScore: item
6627
6627
  });
6628
- return /* @__PURE__ */ React54.createElement(
6628
+ return /* @__PURE__ */ React55.createElement(
6629
6629
  ListView.Row,
6630
6630
  {
6631
6631
  key: item.value,
@@ -6638,12 +6638,12 @@ var ComboboxMenu = memoGeneric(
6638
6638
  }
6639
6639
  }
6640
6640
  },
6641
- /* @__PURE__ */ React54.createElement("div", { className: "flex flex-1 min-w-0 items-center" }, indented && /* @__PURE__ */ React54.createElement(Spacer.Horizontal, { size: CHECKBOX_INDENT_WIDTH }), item.checked ? /* @__PURE__ */ React54.createElement("div", { ...styles.itemIndicator }, /* @__PURE__ */ React54.createElement(CheckIcon, null)) : indented ? /* @__PURE__ */ React54.createElement(
6641
+ /* @__PURE__ */ React55.createElement("div", { className: "flex flex-1 min-w-0 items-center" }, indented && /* @__PURE__ */ React55.createElement(Spacer.Horizontal, { size: CHECKBOX_INDENT_WIDTH }), item.checked ? /* @__PURE__ */ React55.createElement("div", { ...styles.itemIndicator }, /* @__PURE__ */ React55.createElement(CheckIcon, null)) : indented ? /* @__PURE__ */ React55.createElement(
6642
6642
  Spacer.Horizontal,
6643
6643
  {
6644
6644
  size: CHECKBOX_WIDTH - CHECKBOX_RIGHT_INSET
6645
6645
  }
6646
- ) : null, iconPosition === "left" && item.icon && /* @__PURE__ */ React54.createElement(React54.Fragment, null, renderIcon(item.icon), /* @__PURE__ */ React54.createElement(Spacer.Horizontal, { size: 8 })), tokens.map((token, j) => /* @__PURE__ */ React54.createElement(
6646
+ ) : null, iconPosition === "left" && item.icon && /* @__PURE__ */ React55.createElement(React55.Fragment, null, renderIcon(item.icon), /* @__PURE__ */ React55.createElement(Spacer.Horizontal, { size: 8 })), tokens.map((token, j) => /* @__PURE__ */ React55.createElement(
6647
6647
  "span",
6648
6648
  {
6649
6649
  key: `${item.value}-token-${j}`,
@@ -6654,7 +6654,7 @@ var ComboboxMenu = memoGeneric(
6654
6654
  },
6655
6655
  token.text
6656
6656
  ))),
6657
- (item.shortcut || item.icon && iconPosition === "right") && /* @__PURE__ */ React54.createElement(React54.Fragment, null, item.shortcut ? /* @__PURE__ */ React54.createElement(KeyboardShortcut, { shortcut: item.shortcut }) : item.icon && renderIcon(item.icon))
6657
+ (item.shortcut || item.icon && iconPosition === "right") && /* @__PURE__ */ React55.createElement(React55.Fragment, null, item.shortcut ? /* @__PURE__ */ React55.createElement(KeyboardShortcut, { shortcut: item.shortcut }) : item.icon && renderIcon(item.icon))
6658
6658
  );
6659
6659
  }
6660
6660
  }
@@ -6976,19 +6976,19 @@ var Combobox = memoGeneric(
6976
6976
  const hasCheckedItems = items.some(
6977
6977
  (item) => isSelectableMenuItem(item) && item.checked
6978
6978
  );
6979
- return /* @__PURE__ */ React55.createElement(
6979
+ return /* @__PURE__ */ React56.createElement(
6980
6980
  InputField2.Root,
6981
6981
  {
6982
6982
  id,
6983
6983
  size: size2,
6984
6984
  sideOffset: 6,
6985
- end: /* @__PURE__ */ React55.createElement(React55.Fragment, null, loading && /* @__PURE__ */ React55.createElement("div", { className: "pr-1.5" }, /* @__PURE__ */ React55.createElement(ActivityIndicator, null)), !readOnly && /* @__PURE__ */ React55.createElement(
6985
+ end: /* @__PURE__ */ React56.createElement(React56.Fragment, null, loading && /* @__PURE__ */ React56.createElement("div", { className: "pr-1.5" }, /* @__PURE__ */ React56.createElement(ActivityIndicator, null)), !readOnly && /* @__PURE__ */ React56.createElement(
6986
6986
  InputField2.Button,
6987
6987
  {
6988
6988
  variant: "floating",
6989
6989
  onClick: handleChevronClick
6990
6990
  },
6991
- /* @__PURE__ */ React55.createElement(
6991
+ /* @__PURE__ */ React56.createElement(
6992
6992
  DropdownChevronIcon2,
6993
6993
  {
6994
6994
  className: cx(
@@ -7007,7 +7007,7 @@ var Combobox = memoGeneric(
7007
7007
  ListView.rowHeight * 10.5
7008
7008
  );
7009
7009
  const listSize = { width, height };
7010
- return /* @__PURE__ */ React55.createElement(
7010
+ return /* @__PURE__ */ React56.createElement(
7011
7011
  "div",
7012
7012
  {
7013
7013
  className: cx(
@@ -7015,7 +7015,7 @@ var Combobox = memoGeneric(
7015
7015
  shouldShowMenu && !readOnly ? "flex" : "hidden"
7016
7016
  )
7017
7017
  },
7018
- filteredItems.length > 0 && !loading ? /* @__PURE__ */ React55.createElement(
7018
+ filteredItems.length > 0 && !loading ? /* @__PURE__ */ React56.createElement(
7019
7019
  ComboboxMenu,
7020
7020
  {
7021
7021
  ref: listRef,
@@ -7029,11 +7029,11 @@ var Combobox = memoGeneric(
7029
7029
  },
7030
7030
  indented: hasCheckedItems
7031
7031
  }
7032
- ) : /* @__PURE__ */ React55.createElement("div", { className: "flex flex-col h-[50px] p-5 items-center justify-center" }, /* @__PURE__ */ React55.createElement(Small, { className: "text-text-disabled" }, loading ? "Loading..." : "No results"))
7032
+ ) : /* @__PURE__ */ React56.createElement("div", { className: "flex flex-col h-[50px] p-5 items-center justify-center" }, /* @__PURE__ */ React56.createElement(Small, { className: "text-text-disabled" }, loading ? "Loading..." : "No results"))
7033
7033
  );
7034
7034
  }
7035
7035
  },
7036
- /* @__PURE__ */ React55.createElement(
7036
+ /* @__PURE__ */ React56.createElement(
7037
7037
  InputField2.Input,
7038
7038
  {
7039
7039
  ref,
@@ -7058,7 +7058,7 @@ var Combobox = memoGeneric(
7058
7058
  ...readOnly ? { readOnly: true } : {}
7059
7059
  }
7060
7060
  ),
7061
- filter && typeaheadValue && typeaheadValue.toLowerCase().startsWith(filter.toLowerCase()) && /* @__PURE__ */ React55.createElement(
7061
+ filter && typeaheadValue && typeaheadValue.toLowerCase().startsWith(filter.toLowerCase()) && /* @__PURE__ */ React56.createElement(
7062
7062
  InputField2.Typeahead,
7063
7063
  {
7064
7064
  value: typeaheadValue,
@@ -7072,11 +7072,11 @@ var Combobox = memoGeneric(
7072
7072
  );
7073
7073
 
7074
7074
  // src/components/CommandPalette.tsx
7075
- import React58, { memo as memo21 } from "react";
7075
+ import React59, { memo as memo21 } from "react";
7076
7076
 
7077
7077
  // src/components/SearchCompletionMenu.tsx
7078
7078
  import { getCurrentPlatform as getCurrentPlatform2, handleKeyboardEvent } from "@noya-app/noya-keymap";
7079
- import React57, {
7079
+ import React58, {
7080
7080
  forwardRef as forwardRef21,
7081
7081
  useCallback as useCallback26,
7082
7082
  useEffect as useEffect20,
@@ -7087,7 +7087,7 @@ import React57, {
7087
7087
  } from "react";
7088
7088
 
7089
7089
  // src/components/Divider.tsx
7090
- import React56, { memo as memo20 } from "react";
7090
+ import React57, { memo as memo20 } from "react";
7091
7091
  var Divider = memo20(function Divider2({
7092
7092
  variant = "normal",
7093
7093
  overflow = 0,
@@ -7095,7 +7095,7 @@ var Divider = memo20(function Divider2({
7095
7095
  style: style2,
7096
7096
  ...props
7097
7097
  }) {
7098
- return /* @__PURE__ */ React56.createElement(
7098
+ return /* @__PURE__ */ React57.createElement(
7099
7099
  "div",
7100
7100
  {
7101
7101
  className: cx(
@@ -7122,7 +7122,7 @@ var DividerVertical = memo20(function DividerVertical2({
7122
7122
  style: style2,
7123
7123
  ...props
7124
7124
  }) {
7125
- return /* @__PURE__ */ React56.createElement(
7125
+ return /* @__PURE__ */ React57.createElement(
7126
7126
  "div",
7127
7127
  {
7128
7128
  className: cx(`
@@ -7156,7 +7156,7 @@ var SearchCompletionMenu = forwardRef21(function SearchCompletionMenu2({
7156
7156
  index: 0
7157
7157
  });
7158
7158
  const { index, search } = state;
7159
- const listRef = React57.useRef(null);
7159
+ const listRef = React58.useRef(null);
7160
7160
  const hasCheckedItems = items.some((item) => item.checked);
7161
7161
  useEffect20(() => {
7162
7162
  listRef.current?.scrollToIndex(index);
@@ -7235,7 +7235,7 @@ var SearchCompletionMenu = forwardRef21(function SearchCompletionMenu2({
7235
7235
  inputRef.current?.focus();
7236
7236
  }
7237
7237
  }));
7238
- return /* @__PURE__ */ React57.createElement("div", { ...elementSize, className: "flex flex-col overflow-hidden" }, /* @__PURE__ */ React57.createElement(InputField2.Root, { className: "flex flex-0" }, /* @__PURE__ */ React57.createElement(
7238
+ return /* @__PURE__ */ React58.createElement("div", { ...elementSize, className: "flex flex-col overflow-hidden" }, /* @__PURE__ */ React58.createElement(InputField2.Root, { className: "flex flex-0" }, /* @__PURE__ */ React58.createElement(
7239
7239
  InputField2.Input,
7240
7240
  {
7241
7241
  ref: inputRef,
@@ -7255,7 +7255,7 @@ var SearchCompletionMenu = forwardRef21(function SearchCompletionMenu2({
7255
7255
  onChange: setSearch,
7256
7256
  onKeyDown: handleKeyDown
7257
7257
  }
7258
- )), /* @__PURE__ */ React57.createElement(Divider, null), results.length > 0 ? /* @__PURE__ */ React57.createElement(
7258
+ )), /* @__PURE__ */ React58.createElement(Divider, null), results.length > 0 ? /* @__PURE__ */ React58.createElement(
7259
7259
  ComboboxMenu,
7260
7260
  {
7261
7261
  ref: listRef,
@@ -7270,13 +7270,13 @@ var SearchCompletionMenu = forwardRef21(function SearchCompletionMenu2({
7270
7270
  onHoverIndex: setIndex,
7271
7271
  indented: hasCheckedItems
7272
7272
  }
7273
- ) : /* @__PURE__ */ React57.createElement(
7273
+ ) : /* @__PURE__ */ React58.createElement(
7274
7274
  "div",
7275
7275
  {
7276
7276
  ...listSize,
7277
7277
  className: "flex flex-col p-20 items-center justify-center"
7278
7278
  },
7279
- /* @__PURE__ */ React57.createElement(Small, { color: "textDisabled" }, "No results")
7279
+ /* @__PURE__ */ React58.createElement(Small, { color: "textDisabled" }, "No results")
7280
7280
  ));
7281
7281
  });
7282
7282
 
@@ -7288,11 +7288,11 @@ var CommandPalette = memo21(function CommandPalette2({
7288
7288
  onSelect,
7289
7289
  onHover
7290
7290
  }) {
7291
- const menuRef = React58.useRef(null);
7292
- const handleClose = React58.useCallback(() => {
7291
+ const menuRef = React59.useRef(null);
7292
+ const handleClose = React59.useCallback(() => {
7293
7293
  setShowCommandPalette(false);
7294
7294
  }, [setShowCommandPalette]);
7295
- return /* @__PURE__ */ React58.createElement(
7295
+ return /* @__PURE__ */ React59.createElement(
7296
7296
  Dialog,
7297
7297
  {
7298
7298
  style: {
@@ -7318,7 +7318,7 @@ var CommandPalette = memo21(function CommandPalette2({
7318
7318
  }, 0);
7319
7319
  }
7320
7320
  },
7321
- /* @__PURE__ */ React58.createElement("div", { className: "flex flex-col flex-1" }, /* @__PURE__ */ React58.createElement(AutoSizer, null, (size2) => /* @__PURE__ */ React58.createElement(
7321
+ /* @__PURE__ */ React59.createElement("div", { className: "flex flex-col flex-1" }, /* @__PURE__ */ React59.createElement(AutoSizer, null, (size2) => /* @__PURE__ */ React59.createElement(
7322
7322
  SearchCompletionMenu,
7323
7323
  {
7324
7324
  ref: menuRef,
@@ -7333,21 +7333,21 @@ var CommandPalette = memo21(function CommandPalette2({
7333
7333
  });
7334
7334
 
7335
7335
  // src/components/connected-users-menu/ConnectedUsersMenuLayout.tsx
7336
- import React59 from "react";
7337
- var UserAvatar = ({ userId, name, image }) => /* @__PURE__ */ React59.createElement(
7336
+ import React60 from "react";
7337
+ var UserAvatar = ({ userId, name, image }) => /* @__PURE__ */ React60.createElement(
7338
7338
  Tooltip,
7339
7339
  {
7340
7340
  key: userId,
7341
- content: /* @__PURE__ */ React59.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ React59.createElement(Small, null, name))
7341
+ content: /* @__PURE__ */ React60.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ React60.createElement(Small, null, name))
7342
7342
  },
7343
- /* @__PURE__ */ React59.createElement(Avatar, { size: INPUT_HEIGHT, userId, name, image })
7343
+ /* @__PURE__ */ React60.createElement(Avatar, { size: INPUT_HEIGHT, userId, name, image })
7344
7344
  );
7345
7345
  var ConnectedUsersMenuLayout = ({
7346
7346
  renderUsers,
7347
7347
  launchAIAssistant,
7348
7348
  isAssistantOpen
7349
7349
  }) => {
7350
- return /* @__PURE__ */ React59.createElement("div", { className: "flex gap-1.5" }, /* @__PURE__ */ React59.createElement(AvatarStack, { size: INPUT_HEIGHT, className: "mr-1" }, renderUsers()), launchAIAssistant && /* @__PURE__ */ React59.createElement(Tooltip, { content: "AI Assistant" }, /* @__PURE__ */ React59.createElement(
7350
+ return /* @__PURE__ */ React60.createElement("div", { className: "flex gap-1.5" }, /* @__PURE__ */ React60.createElement(AvatarStack, { size: INPUT_HEIGHT, className: "mr-1" }, renderUsers()), launchAIAssistant && /* @__PURE__ */ React60.createElement(Tooltip, { content: "AI Assistant" }, /* @__PURE__ */ React60.createElement(
7351
7351
  Button_default,
7352
7352
  {
7353
7353
  active: isAssistantOpen,
@@ -7360,7 +7360,7 @@ var ConnectedUsersMenuLayout = ({
7360
7360
 
7361
7361
  // src/components/DraggableMenuButton.tsx
7362
7362
  import { DragHandleDots2Icon } from "@noya-app/noya-icons";
7363
- import React60, { useCallback as useCallback27, useState as useState26 } from "react";
7363
+ import React61, { useCallback as useCallback27, useState as useState26 } from "react";
7364
7364
  var DraggableMenuButton = memoGeneric(function DraggableMenuButton2({
7365
7365
  items,
7366
7366
  onSelect,
@@ -7406,7 +7406,7 @@ var DraggableMenuButton = memoGeneric(function DraggableMenuButton2({
7406
7406
  },
7407
7407
  [setOpen]
7408
7408
  );
7409
- return /* @__PURE__ */ React60.createElement(
7409
+ return /* @__PURE__ */ React61.createElement(
7410
7410
  "div",
7411
7411
  {
7412
7412
  className: cx(
@@ -7422,7 +7422,7 @@ var DraggableMenuButton = memoGeneric(function DraggableMenuButton2({
7422
7422
  onClick?.();
7423
7423
  }
7424
7424
  },
7425
- items && onSelect ? /* @__PURE__ */ React60.createElement(
7425
+ items && onSelect ? /* @__PURE__ */ React61.createElement(
7426
7426
  DropdownMenu,
7427
7427
  {
7428
7428
  open,
@@ -7431,13 +7431,13 @@ var DraggableMenuButton = memoGeneric(function DraggableMenuButton2({
7431
7431
  onSelect,
7432
7432
  shouldBindKeyboardShortcuts: false
7433
7433
  },
7434
- /* @__PURE__ */ React60.createElement("div", { className: "pointer-events-none h-[15px]" }, /* @__PURE__ */ React60.createElement(
7434
+ /* @__PURE__ */ React61.createElement("div", { className: "pointer-events-none h-[15px]" }, /* @__PURE__ */ React61.createElement(
7435
7435
  DragHandleDots2Icon,
7436
7436
  {
7437
7437
  color: isVisible || open ? cssVars.colors.icon : "transparent"
7438
7438
  }
7439
7439
  ))
7440
- ) : /* @__PURE__ */ React60.createElement(
7440
+ ) : /* @__PURE__ */ React61.createElement(
7441
7441
  DragHandleDots2Icon,
7442
7442
  {
7443
7443
  color: isVisible || open ? cssVars.colors.icon : "transparent"
@@ -7448,10 +7448,10 @@ var DraggableMenuButton = memoGeneric(function DraggableMenuButton2({
7448
7448
 
7449
7449
  // src/components/Drawer.tsx
7450
7450
  import * as Dialog3 from "@radix-ui/react-dialog";
7451
- import * as React61 from "react";
7451
+ import * as React62 from "react";
7452
7452
  import { useImperativeHandle as useImperativeHandle8 } from "react";
7453
- var Drawer = React61.memo(
7454
- React61.forwardRef(function Drawer2({
7453
+ var Drawer = React62.memo(
7454
+ React62.forwardRef(function Drawer2({
7455
7455
  open,
7456
7456
  onOpenChange,
7457
7457
  trigger,
@@ -7481,7 +7481,7 @@ var Drawer = React61.memo(
7481
7481
  return internalOpen;
7482
7482
  }
7483
7483
  }));
7484
- const inner = /* @__PURE__ */ React61.createElement(React61.Fragment, null, /* @__PURE__ */ React61.createElement(
7484
+ const inner = /* @__PURE__ */ React62.createElement(React62.Fragment, null, /* @__PURE__ */ React62.createElement(
7485
7485
  Dialog3.Overlay,
7486
7486
  {
7487
7487
  className: cx(
@@ -7489,7 +7489,7 @@ var Drawer = React61.memo(
7489
7489
  positioning === "absolute" ? "absolute" : "fixed"
7490
7490
  )
7491
7491
  }
7492
- ), /* @__PURE__ */ React61.createElement(
7492
+ ), /* @__PURE__ */ React62.createElement(
7493
7493
  Dialog3.Content,
7494
7494
  {
7495
7495
  id,
@@ -7501,24 +7501,24 @@ var Drawer = React61.memo(
7501
7501
  className
7502
7502
  )
7503
7503
  },
7504
- title && /* @__PURE__ */ React61.createElement(Dialog3.Title, null, title),
7504
+ title && /* @__PURE__ */ React62.createElement(Dialog3.Title, null, title),
7505
7505
  children
7506
7506
  ));
7507
- return /* @__PURE__ */ React61.createElement(
7507
+ return /* @__PURE__ */ React62.createElement(
7508
7508
  Dialog3.Root,
7509
7509
  {
7510
7510
  key: "dialog",
7511
7511
  open: internalOpen,
7512
7512
  onOpenChange: setInternalOpen
7513
7513
  },
7514
- /* @__PURE__ */ React61.createElement(Dialog3.Trigger, { key: "trigger" }, trigger),
7515
- portalled ? /* @__PURE__ */ React61.createElement(Dialog3.Portal, { container: portalContainer }, inner) : inner
7514
+ /* @__PURE__ */ React62.createElement(Dialog3.Trigger, { key: "trigger" }, trigger),
7515
+ portalled ? /* @__PURE__ */ React62.createElement(Dialog3.Portal, { container: portalContainer }, inner) : inner
7516
7516
  );
7517
7517
  })
7518
7518
  );
7519
7519
 
7520
7520
  // src/components/Fade.tsx
7521
- import React62 from "react";
7521
+ import React63 from "react";
7522
7522
  var Fade = ({
7523
7523
  children,
7524
7524
  direction = "right",
@@ -7540,7 +7540,7 @@ var Fade = ({
7540
7540
  top: "left-0 right-0 top-0",
7541
7541
  bottom: "left-0 right-0 bottom-0"
7542
7542
  }[direction];
7543
- return /* @__PURE__ */ React62.createElement("div", { className: cx("relative", className), style: { height } }, position === "front" ? children : null, /* @__PURE__ */ React62.createElement(
7543
+ return /* @__PURE__ */ React63.createElement("div", { className: cx("relative", className), style: { height } }, position === "front" ? children : null, /* @__PURE__ */ React63.createElement(
7544
7544
  "div",
7545
7545
  {
7546
7546
  className: cx(
@@ -7559,17 +7559,17 @@ var Fade = ({
7559
7559
  };
7560
7560
 
7561
7561
  // src/components/file-explorer/FileExplorerLayout.tsx
7562
- import React63 from "react";
7562
+ import React64 from "react";
7563
7563
  var FileExplorerLayout = ({
7564
7564
  children,
7565
7565
  className,
7566
7566
  ...props
7567
- }) => /* @__PURE__ */ React63.createElement(Section, { className: cx(className, "px-3 flex-1"), ...props }, children);
7567
+ }) => /* @__PURE__ */ React64.createElement(Section, { className: cx(className, "px-3 flex-1"), ...props }, children);
7568
7568
  var FileExplorerUploadButton = ({
7569
7569
  showUploadButton,
7570
7570
  onUpload,
7571
7571
  children
7572
- }) => /* @__PURE__ */ React63.createElement("div", { className: "flex items-center gap-2" }, showUploadButton && /* @__PURE__ */ React63.createElement(
7572
+ }) => /* @__PURE__ */ React64.createElement("div", { className: "flex items-center gap-2" }, showUploadButton && /* @__PURE__ */ React64.createElement(
7573
7573
  IconButton,
7574
7574
  {
7575
7575
  iconName: "UploadIcon",
@@ -7580,14 +7580,14 @@ var FileExplorerUploadButton = ({
7580
7580
  ), children);
7581
7581
  var FileExplorerCollection = forwardRefGeneric(
7582
7582
  function FileExplorerCollection2({ ...props }, ref) {
7583
- return /* @__PURE__ */ React63.createElement(Collection, { ref, className: "-mx-3 flex-1", ...props });
7583
+ return /* @__PURE__ */ React64.createElement(Collection, { ref, className: "-mx-3 flex-1", ...props });
7584
7584
  }
7585
7585
  );
7586
7586
  var FileExplorerDetail = ({
7587
7587
  selected,
7588
7588
  size: size2,
7589
7589
  children
7590
- }) => /* @__PURE__ */ React63.createElement(
7590
+ }) => /* @__PURE__ */ React64.createElement(
7591
7591
  "span",
7592
7592
  {
7593
7593
  className: cx(
@@ -7600,10 +7600,10 @@ var FileExplorerDetail = ({
7600
7600
  var FileExplorerEmptyState = ({
7601
7601
  label = "No files",
7602
7602
  ...props
7603
- }) => /* @__PURE__ */ React63.createElement(Banner, { label, className: "mx-3", ...props });
7603
+ }) => /* @__PURE__ */ React64.createElement(Banner, { label, className: "mx-3", ...props });
7604
7604
 
7605
7605
  // src/components/FillInputField.tsx
7606
- import React66, { forwardRef as forwardRef23, memo as memo25 } from "react";
7606
+ import React67, { forwardRef as forwardRef23, memo as memo25 } from "react";
7607
7607
 
7608
7608
  // ../noya-file-format/src/types.ts
7609
7609
  var types_exports = {};
@@ -7928,25 +7928,25 @@ var ClassValue = /* @__PURE__ */ ((ClassValue2) => {
7928
7928
  })(ClassValue || {});
7929
7929
 
7930
7930
  // src/components/FillPreviewBackground.tsx
7931
- import * as React65 from "react";
7931
+ import * as React66 from "react";
7932
7932
 
7933
7933
  // src/contexts/ImageDataContext.tsx
7934
- import * as React64 from "react";
7935
- var ImageDataContext = React64.createContext(
7934
+ import * as React65 from "react";
7935
+ var ImageDataContext = React65.createContext(
7936
7936
  void 0
7937
7937
  );
7938
- var ImageDataProvider = React64.memo(function ImageDataProvider2({
7938
+ var ImageDataProvider = React65.memo(function ImageDataProvider2({
7939
7939
  children,
7940
7940
  getImageData
7941
7941
  }) {
7942
- const contextValue = React64.useMemo(
7942
+ const contextValue = React65.useMemo(
7943
7943
  () => ({ getImageData: getImageData ?? (() => void 0) }),
7944
7944
  [getImageData]
7945
7945
  );
7946
- return /* @__PURE__ */ React64.createElement(ImageDataContext.Provider, { value: contextValue }, children);
7946
+ return /* @__PURE__ */ React65.createElement(ImageDataContext.Provider, { value: contextValue }, children);
7947
7947
  });
7948
7948
  function useImageData(ref) {
7949
- const value = React64.useContext(ImageDataContext);
7949
+ const value = React65.useContext(ImageDataContext);
7950
7950
  if (!value) {
7951
7951
  throw new Error("Missing ImageDataProvider");
7952
7952
  }
@@ -8016,10 +8016,10 @@ var dotsHorizontalSvg = (fillColor) => `
8016
8016
  <path d='M3.625 7.5C3.625 8.12132 3.12132 8.625 2.5 8.625C1.87868 8.625 1.375 8.12132 1.375 7.5C1.375 6.87868 1.87868 6.375 2.5 6.375C3.12132 6.375 3.625 6.87868 3.625 7.5ZM8.625 7.5C8.625 8.12132 8.12132 8.625 7.5 8.625C6.87868 8.625 6.375 8.12132 6.375 7.5C6.375 6.87868 6.87868 6.375 7.5 6.375C8.12132 6.375 8.625 6.87868 8.625 7.5ZM12.5 8.625C13.1213 8.625 13.625 8.12132 13.625 7.5C13.625 6.87868 13.1213 6.375 12.5 6.375C11.8787 6.375 11.375 6.87868 11.375 7.5C11.375 8.12132 11.8787 8.625 12.5 8.625Z'></path>
8017
8017
  </svg>
8018
8018
  `;
8019
- var Background = React65.memo(function Background2({
8019
+ var Background = React66.memo(function Background2({
8020
8020
  background: background2
8021
8021
  }) {
8022
- return /* @__PURE__ */ React65.createElement(
8022
+ return /* @__PURE__ */ React66.createElement(
8023
8023
  "span",
8024
8024
  {
8025
8025
  className: `${background2 ? `bg-[${background2}]` : "bg-input-background"} absolute inset-0`
@@ -8038,7 +8038,7 @@ function getPatternSizeAndPosition(fillType, tileScale) {
8038
8038
  return "center / 100% 100%";
8039
8039
  }
8040
8040
  }
8041
- var PatternPreviewBackground = React65.memo(
8041
+ var PatternPreviewBackground = React66.memo(
8042
8042
  function PatternPreviewBackground2({
8043
8043
  fillType,
8044
8044
  tileScale,
@@ -8047,7 +8047,7 @@ var PatternPreviewBackground = React65.memo(
8047
8047
  const image = useImageData(imageRef);
8048
8048
  const url = useObjectURL(image);
8049
8049
  const size2 = getPatternSizeAndPosition(fillType, tileScale);
8050
- const background2 = React65.useMemo(
8050
+ const background2 = React66.useMemo(
8051
8051
  () => [
8052
8052
  size2,
8053
8053
  `url(${url})`,
@@ -8055,44 +8055,44 @@ var PatternPreviewBackground = React65.memo(
8055
8055
  ].join(" "),
8056
8056
  [fillType, size2, url]
8057
8057
  );
8058
- return /* @__PURE__ */ React65.createElement(Background, { background: background2 });
8058
+ return /* @__PURE__ */ React66.createElement(Background, { background: background2 });
8059
8059
  }
8060
8060
  );
8061
- var ColorPreviewBackground = React65.memo(function ColorPreviewBackground2({
8061
+ var ColorPreviewBackground = React66.memo(function ColorPreviewBackground2({
8062
8062
  color
8063
8063
  }) {
8064
- const background2 = React65.useMemo(
8064
+ const background2 = React66.useMemo(
8065
8065
  () => sketchColorToRgbaString(color),
8066
8066
  [color]
8067
8067
  );
8068
- return /* @__PURE__ */ React65.createElement(Background, { background: background2 });
8068
+ return /* @__PURE__ */ React66.createElement(Background, { background: background2 });
8069
8069
  });
8070
- var GradientPreviewBackground = React65.memo(
8070
+ var GradientPreviewBackground = React66.memo(
8071
8071
  function GradientPreviewBackground2({
8072
8072
  gradient
8073
8073
  }) {
8074
- const background2 = React65.useMemo(
8074
+ const background2 = React66.useMemo(
8075
8075
  () => getGradientBackground(gradient.stops, gradient.gradientType, 180),
8076
8076
  [gradient.gradientType, gradient.stops]
8077
8077
  );
8078
- return /* @__PURE__ */ React65.createElement(Background, { background: background2 });
8078
+ return /* @__PURE__ */ React66.createElement(Background, { background: background2 });
8079
8079
  }
8080
8080
  );
8081
8081
  var background = `center url("data:image/svg+xml;utf8,${dotsHorizontalSvg(
8082
8082
  cssVars.colors.placeholderDots
8083
8083
  )}") no-repeat`;
8084
- var FillPreviewBackground = React65.memo(function FillPreviewBackground2({
8084
+ var FillPreviewBackground = React66.memo(function FillPreviewBackground2({
8085
8085
  value
8086
8086
  }) {
8087
- if (!value) return /* @__PURE__ */ React65.createElement(Background, { background });
8087
+ if (!value) return /* @__PURE__ */ React66.createElement(Background, { background });
8088
8088
  switch (value._class) {
8089
8089
  case "color":
8090
- return /* @__PURE__ */ React65.createElement(ColorPreviewBackground, { color: value });
8090
+ return /* @__PURE__ */ React66.createElement(ColorPreviewBackground, { color: value });
8091
8091
  case "gradient":
8092
- return /* @__PURE__ */ React65.createElement(GradientPreviewBackground, { gradient: value });
8092
+ return /* @__PURE__ */ React66.createElement(GradientPreviewBackground, { gradient: value });
8093
8093
  case "pattern":
8094
8094
  if (!value.image) return null;
8095
- return /* @__PURE__ */ React65.createElement(
8095
+ return /* @__PURE__ */ React66.createElement(
8096
8096
  PatternPreviewBackground,
8097
8097
  {
8098
8098
  fillType: value.patternFillType,
@@ -8104,7 +8104,7 @@ var FillPreviewBackground = React65.memo(function FillPreviewBackground2({
8104
8104
  });
8105
8105
 
8106
8106
  // src/components/FillInputField.tsx
8107
- var FillButton = forwardRef23(({ className, ...props }, ref) => /* @__PURE__ */ React66.createElement(
8107
+ var FillButton = forwardRef23(({ className, ...props }, ref) => /* @__PURE__ */ React67.createElement(
8108
8108
  "button",
8109
8109
  {
8110
8110
  ref,
@@ -8117,12 +8117,12 @@ var FillButton = forwardRef23(({ className, ...props }, ref) => /* @__PURE__ */
8117
8117
  ));
8118
8118
  var FillInputField = memo25(
8119
8119
  forwardRef23(function FillInputField2({ id, value, ...rest }, ref) {
8120
- return /* @__PURE__ */ React66.createElement(FillButton, { ref, id, ...rest }, /* @__PURE__ */ React66.createElement(FillPreviewBackground, { value }));
8120
+ return /* @__PURE__ */ React67.createElement(FillButton, { ref, id, ...rest }, /* @__PURE__ */ React67.createElement(FillPreviewBackground, { value }));
8121
8121
  })
8122
8122
  );
8123
8123
 
8124
8124
  // src/components/FloatingWindow.tsx
8125
- import React67, { useCallback as useCallback28, useRef as useRef23, useState as useState27 } from "react";
8125
+ import React68, { useCallback as useCallback28, useRef as useRef23, useState as useState27 } from "react";
8126
8126
  var styles2 = {
8127
8127
  noSelect: {
8128
8128
  userSelect: "none",
@@ -8215,7 +8215,7 @@ function defaultRenderToolbar({
8215
8215
  toolbarContent,
8216
8216
  onClose
8217
8217
  }) {
8218
- return /* @__PURE__ */ React67.createElement(React67.Fragment, null, /* @__PURE__ */ React67.createElement(Small, { className: "flex-1 font-medium text-text" }, title), toolbarContent, /* @__PURE__ */ React67.createElement(
8218
+ return /* @__PURE__ */ React68.createElement(React68.Fragment, null, /* @__PURE__ */ React68.createElement(Small, { className: "flex-1 font-medium text-text" }, title), toolbarContent, /* @__PURE__ */ React68.createElement(
8219
8219
  IconButton,
8220
8220
  {
8221
8221
  iconName: "Cross3Icon",
@@ -8337,7 +8337,7 @@ var FloatingWindow = ({
8337
8337
  setResizeDirection(null);
8338
8338
  toggleGlobalTextSelection(false);
8339
8339
  }, []);
8340
- React67.useEffect(() => {
8340
+ React68.useEffect(() => {
8341
8341
  document.addEventListener("mousemove", handleMouseMove);
8342
8342
  document.addEventListener("mouseup", handleMouseUp);
8343
8343
  return () => {
@@ -8351,7 +8351,7 @@ var FloatingWindow = ({
8351
8351
  if (onClose) onClose();
8352
8352
  floatingWindowManager.closeWindow(currentFloatingWindow.id);
8353
8353
  }, [currentFloatingWindow.id, floatingWindowManager, onClose]);
8354
- return /* @__PURE__ */ React67.createElement(
8354
+ return /* @__PURE__ */ React68.createElement(
8355
8355
  "div",
8356
8356
  {
8357
8357
  ref: wrapperRef,
@@ -8366,7 +8366,7 @@ var FloatingWindow = ({
8366
8366
  zIndex: cssVars.zIndex.menu
8367
8367
  }
8368
8368
  },
8369
- /* @__PURE__ */ React67.createElement(
8369
+ /* @__PURE__ */ React68.createElement(
8370
8370
  "div",
8371
8371
  {
8372
8372
  style: {
@@ -8377,9 +8377,9 @@ var FloatingWindow = ({
8377
8377
  },
8378
8378
  renderToolbar({ title, toolbarContent, onClose: handleClose })
8379
8379
  ),
8380
- /* @__PURE__ */ React67.createElement(Divider, null),
8381
- /* @__PURE__ */ React67.createElement("div", { style: styles2.content }, children),
8382
- Object.entries(resizeHandlePositions).map(([direction, style2]) => /* @__PURE__ */ React67.createElement(
8380
+ /* @__PURE__ */ React68.createElement(Divider, null),
8381
+ /* @__PURE__ */ React68.createElement("div", { style: styles2.content }, children),
8382
+ Object.entries(resizeHandlePositions).map(([direction, style2]) => /* @__PURE__ */ React68.createElement(
8383
8383
  "div",
8384
8384
  {
8385
8385
  key: direction,
@@ -8401,8 +8401,8 @@ import {
8401
8401
  hsvaToRgba,
8402
8402
  rgbaToHsva as rgbaToHsva2
8403
8403
  } from "@noya-app/noya-colorpicker";
8404
- import * as React68 from "react";
8405
- var GradientPicker = React68.memo(function GradientPicker2({
8404
+ import * as React69 from "react";
8405
+ var GradientPicker = React69.memo(function GradientPicker2({
8406
8406
  value,
8407
8407
  selectedStop,
8408
8408
  onChangeColor,
@@ -8411,7 +8411,7 @@ var GradientPicker = React68.memo(function GradientPicker2({
8411
8411
  onDelete,
8412
8412
  onSelectStop
8413
8413
  }) {
8414
- const colorModel = React68.useMemo(
8414
+ const colorModel = React69.useMemo(
8415
8415
  () => ({
8416
8416
  defaultColor: { r: 0, g: 0, b: 0, a: 1 },
8417
8417
  toHsva: rgbaToHsva2,
@@ -8420,30 +8420,30 @@ var GradientPicker = React68.memo(function GradientPicker2({
8420
8420
  }),
8421
8421
  []
8422
8422
  );
8423
- const rgbaColor = React68.useMemo(
8423
+ const rgbaColor = React69.useMemo(
8424
8424
  () => sketchColorToRgba(value[selectedStop].color),
8425
8425
  [value, selectedStop]
8426
8426
  );
8427
- const handleChangeColor = React68.useCallback(
8427
+ const handleChangeColor = React69.useCallback(
8428
8428
  (value2) => {
8429
8429
  onChangeColor(rgbaToSketchColor(value2));
8430
8430
  },
8431
8431
  [onChangeColor]
8432
8432
  );
8433
- const handleAddGradientStop = React68.useCallback(
8433
+ const handleAddGradientStop = React69.useCallback(
8434
8434
  (value2, position) => {
8435
8435
  onAdd(rgbaToSketchColor(value2), position);
8436
8436
  },
8437
8437
  [onAdd]
8438
8438
  );
8439
- return /* @__PURE__ */ React68.createElement(
8439
+ return /* @__PURE__ */ React69.createElement(
8440
8440
  NoyaColorPicker,
8441
8441
  {
8442
8442
  onChange: handleChangeColor,
8443
8443
  colorModel,
8444
8444
  color: rgbaColor
8445
8445
  },
8446
- /* @__PURE__ */ React68.createElement(
8446
+ /* @__PURE__ */ React69.createElement(
8447
8447
  Gradient,
8448
8448
  {
8449
8449
  gradients: value,
@@ -8454,17 +8454,17 @@ var GradientPicker = React68.memo(function GradientPicker2({
8454
8454
  onDelete
8455
8455
  }
8456
8456
  ),
8457
- /* @__PURE__ */ React68.createElement(Spacer.Vertical, { size: 10 }),
8458
- /* @__PURE__ */ React68.createElement(Saturation, null),
8459
- /* @__PURE__ */ React68.createElement(Spacer.Vertical, { size: 12 }),
8460
- /* @__PURE__ */ React68.createElement(Hue, null),
8461
- /* @__PURE__ */ React68.createElement(Spacer.Vertical, { size: 5 }),
8462
- /* @__PURE__ */ React68.createElement(Alpha, null)
8457
+ /* @__PURE__ */ React69.createElement(Spacer.Vertical, { size: 10 }),
8458
+ /* @__PURE__ */ React69.createElement(Saturation, null),
8459
+ /* @__PURE__ */ React69.createElement(Spacer.Vertical, { size: 12 }),
8460
+ /* @__PURE__ */ React69.createElement(Hue, null),
8461
+ /* @__PURE__ */ React69.createElement(Spacer.Vertical, { size: 5 }),
8462
+ /* @__PURE__ */ React69.createElement(Alpha, null)
8463
8463
  );
8464
8464
  });
8465
8465
 
8466
8466
  // src/components/InspectorContainer.tsx
8467
- import React69, { forwardRef as forwardRef24, memo as memo27 } from "react";
8467
+ import React70, { forwardRef as forwardRef24, memo as memo27 } from "react";
8468
8468
  var InspectorContainer = memo27(
8469
8469
  forwardRef24(function InspectorContainer2({
8470
8470
  header,
@@ -8475,7 +8475,7 @@ var InspectorContainer = memo27(
8475
8475
  className,
8476
8476
  style: style2
8477
8477
  }, forwardedRef) {
8478
- return /* @__PURE__ */ React69.createElement(
8478
+ return /* @__PURE__ */ React70.createElement(
8479
8479
  "div",
8480
8480
  {
8481
8481
  ref: forwardedRef,
@@ -8490,32 +8490,32 @@ var InspectorContainer = memo27(
8490
8490
  }
8491
8491
  },
8492
8492
  header,
8493
- children ? /* @__PURE__ */ React69.createElement(ScrollArea, null, /* @__PURE__ */ React69.createElement("div", { className: "flex flex-col relative" }, showDividers ? withSeparatorElements(children, /* @__PURE__ */ React69.createElement(Divider, null)) : children)) : fallback ? /* @__PURE__ */ React69.createElement("div", { className: "flex flex-col relative h-full" }, fallback) : null
8493
+ children ? /* @__PURE__ */ React70.createElement(ScrollArea, null, /* @__PURE__ */ React70.createElement("div", { className: "flex flex-col relative" }, showDividers ? withSeparatorElements(children, /* @__PURE__ */ React70.createElement(Divider, null)) : children)) : fallback ? /* @__PURE__ */ React70.createElement("div", { className: "flex flex-col relative h-full" }, fallback) : null
8494
8494
  );
8495
8495
  })
8496
8496
  );
8497
8497
 
8498
8498
  // src/components/LabeledElementView.tsx
8499
8499
  import * as kiwi from "kiwi.js";
8500
- import * as React70 from "react";
8501
- var LabeledElementView = React70.memo(function LabeledElementView2({
8500
+ import * as React71 from "react";
8501
+ var LabeledElementView = React71.memo(function LabeledElementView2({
8502
8502
  children,
8503
8503
  renderLabel
8504
8504
  }) {
8505
- const elementIds = React70.Children.toArray(children).flatMap(
8506
- (child) => React70.isValidElement(child) && child.type === React70.Fragment ? child.props.children : [child]
8505
+ const elementIds = React71.Children.toArray(children).flatMap(
8506
+ (child) => React71.isValidElement(child) && child.type === React71.Fragment ? child.props.children : [child]
8507
8507
  ).map(
8508
- (child) => React70.isValidElement(child) && "id" in child.props ? child.props.id : null
8508
+ (child) => React71.isValidElement(child) && "id" in child.props ? child.props.id : null
8509
8509
  ).filter((id) => !!id);
8510
8510
  const serializedIds = elementIds.join(",");
8511
- const containerRef = React70.useRef(null);
8512
- const refs = React70.useMemo(() => {
8511
+ const containerRef = React71.useRef(null);
8512
+ const refs = React71.useMemo(() => {
8513
8513
  return Object.fromEntries(
8514
- serializedIds.split(",").map((id) => [id, React70.createRef()])
8514
+ serializedIds.split(",").map((id) => [id, React71.createRef()])
8515
8515
  );
8516
8516
  }, [serializedIds]);
8517
- const labelElements = React70.useMemo(() => {
8518
- return serializedIds.split(",").map((id, index) => /* @__PURE__ */ React70.createElement(
8517
+ const labelElements = React71.useMemo(() => {
8518
+ return serializedIds.split(",").map((id, index) => /* @__PURE__ */ React71.createElement(
8519
8519
  "span",
8520
8520
  {
8521
8521
  key: id,
@@ -8528,7 +8528,7 @@ var LabeledElementView = React70.memo(function LabeledElementView2({
8528
8528
  })
8529
8529
  ));
8530
8530
  }, [refs, serializedIds, renderLabel]);
8531
- React70.useLayoutEffect(() => {
8531
+ React71.useLayoutEffect(() => {
8532
8532
  if (!containerRef.current) return;
8533
8533
  const containerRect = containerRef.current.getBoundingClientRect();
8534
8534
  const solver = new kiwi.Solver();
@@ -8590,19 +8590,19 @@ var LabeledElementView = React70.memo(function LabeledElementView2({
8590
8590
  `${Math.max(...heights)}px`
8591
8591
  );
8592
8592
  }, [refs, labelElements]);
8593
- return /* @__PURE__ */ React70.createElement("div", { className: "flex flex-1 flex-col relative", ref: containerRef }, /* @__PURE__ */ React70.createElement("div", { className: "flex flex-1 items-center" }, children), /* @__PURE__ */ React70.createElement("div", { className: "relative overflow-hidden select-none" }, labelElements));
8593
+ return /* @__PURE__ */ React71.createElement("div", { className: "flex flex-1 flex-col relative", ref: containerRef }, /* @__PURE__ */ React71.createElement("div", { className: "flex flex-1 items-center" }, children), /* @__PURE__ */ React71.createElement("div", { className: "relative overflow-hidden select-none" }, labelElements));
8594
8594
  });
8595
8595
 
8596
8596
  // src/components/LabeledField.tsx
8597
- import React72, { memo as memo29, useMemo as useMemo30 } from "react";
8597
+ import React73, { memo as memo29, useMemo as useMemo30 } from "react";
8598
8598
 
8599
8599
  // src/hooks/useIndent.ts
8600
- import React71 from "react";
8601
- var IndentContext = React71.createContext({
8600
+ import React72 from "react";
8601
+ var IndentContext = React72.createContext({
8602
8602
  indentLevel: 0
8603
8603
  });
8604
8604
  var useIndent = () => {
8605
- const { indentLevel } = React71.useContext(IndentContext);
8605
+ const { indentLevel } = React72.useContext(IndentContext);
8606
8606
  return indentLevel;
8607
8607
  };
8608
8608
 
@@ -8661,7 +8661,7 @@ var LabeledField = memo29(function LabeledField2({
8661
8661
  }),
8662
8662
  [labelWidth, indentLevel, labelStyleProp]
8663
8663
  );
8664
- return /* @__PURE__ */ React72.createElement(LabelContext.Provider, { value: labelContextValue }, labelPosition === "inset" ? /* @__PURE__ */ React72.createElement(LabelPositionContext.Provider, { value: labelPositionInset }, children) : /* @__PURE__ */ React72.createElement("div", { className: cx("flex relative flex-1", className), style: style2 }, Boolean(indentLevel) && /* @__PURE__ */ React72.createElement("div", { style: indentStyle }), /* @__PURE__ */ React72.createElement("div", { className: labeledFieldClasses }, /* @__PURE__ */ React72.createElement(
8664
+ return /* @__PURE__ */ React73.createElement(LabelContext.Provider, { value: labelContextValue }, labelPosition === "inset" ? /* @__PURE__ */ React73.createElement(LabelPositionContext.Provider, { value: labelPositionInset }, children) : /* @__PURE__ */ React73.createElement("div", { className: cx("flex relative flex-1", className), style: style2 }, Boolean(indentLevel) && /* @__PURE__ */ React73.createElement("div", { style: indentStyle }), /* @__PURE__ */ React73.createElement("div", { className: labeledFieldClasses }, /* @__PURE__ */ React73.createElement(
8665
8665
  Label,
8666
8666
  {
8667
8667
  htmlFor: fieldId,
@@ -8670,7 +8670,7 @@ var LabeledField = memo29(function LabeledField2({
8670
8670
  ...props
8671
8671
  },
8672
8672
  label
8673
- ), labelPosition === "start" ? /* @__PURE__ */ React72.createElement("div", { className: "flex-auto flex", style: fieldStyle }, children) : children)));
8673
+ ), labelPosition === "start" ? /* @__PURE__ */ React73.createElement("div", { className: "flex-auto flex", style: fieldStyle }, children) : children)));
8674
8674
  });
8675
8675
 
8676
8676
  // src/components/MediaThumbnail.tsx
@@ -8680,7 +8680,7 @@ import {
8680
8680
  SpeakerLoudIcon,
8681
8681
  VideoIcon
8682
8682
  } from "@noya-app/noya-icons";
8683
- import React73, { memo as memo30, useMemo as useMemo31 } from "react";
8683
+ import React74, { memo as memo30, useMemo as useMemo31 } from "react";
8684
8684
 
8685
8685
  // src/components/catppuccin/fileIcons.ts
8686
8686
  var fileIcons = {
@@ -11145,8 +11145,8 @@ var MediaThumbnail = memo30(function MediaThumbnail2({
11145
11145
  const content = useMemo31(() => {
11146
11146
  switch (contentType) {
11147
11147
  case "image":
11148
- if (!url) return /* @__PURE__ */ React73.createElement(ImageIcon, { color: iconColor, style: iconStyles });
11149
- return /* @__PURE__ */ React73.createElement(
11148
+ if (!url) return /* @__PURE__ */ React74.createElement(ImageIcon, { color: iconColor, style: iconStyles });
11149
+ return /* @__PURE__ */ React74.createElement(
11150
11150
  "img",
11151
11151
  {
11152
11152
  src: url,
@@ -11156,18 +11156,18 @@ var MediaThumbnail = memo30(function MediaThumbnail2({
11156
11156
  }
11157
11157
  );
11158
11158
  case "video":
11159
- return /* @__PURE__ */ React73.createElement(VideoIcon, { color: iconColor, style: iconStyles });
11159
+ return /* @__PURE__ */ React74.createElement(VideoIcon, { color: iconColor, style: iconStyles });
11160
11160
  case "audio":
11161
- return /* @__PURE__ */ React73.createElement(SpeakerLoudIcon, { color: iconColor, style: iconStyles });
11161
+ return /* @__PURE__ */ React74.createElement(SpeakerLoudIcon, { color: iconColor, style: iconStyles });
11162
11162
  default:
11163
11163
  if (iconName) {
11164
11164
  const Icon = Icons[iconName];
11165
- return /* @__PURE__ */ React73.createElement(Icon, { color: iconColor, style: iconStyles });
11165
+ return /* @__PURE__ */ React74.createElement(Icon, { color: iconColor, style: iconStyles });
11166
11166
  }
11167
11167
  if (fileName) {
11168
11168
  const fileIcon = findFileIcon(fileName);
11169
11169
  if (fileIcon) {
11170
- return /* @__PURE__ */ React73.createElement(
11170
+ return /* @__PURE__ */ React74.createElement(
11171
11171
  "img",
11172
11172
  {
11173
11173
  src: `https://api.iconify.design/catppuccin/${fileIcon}.svg?height=none&box=1`,
@@ -11177,10 +11177,10 @@ var MediaThumbnail = memo30(function MediaThumbnail2({
11177
11177
  );
11178
11178
  }
11179
11179
  }
11180
- return /* @__PURE__ */ React73.createElement(FileIcon, { color: iconColor, style: iconStyles });
11180
+ return /* @__PURE__ */ React74.createElement(FileIcon, { color: iconColor, style: iconStyles });
11181
11181
  }
11182
11182
  }, [contentType, url, iconColor, iconStyles, iconName, fileName]);
11183
- return /* @__PURE__ */ React73.createElement(
11183
+ return /* @__PURE__ */ React74.createElement(
11184
11184
  "div",
11185
11185
  {
11186
11186
  className: cx(
@@ -11211,7 +11211,7 @@ function findFileIcon(fileName) {
11211
11211
  }
11212
11212
 
11213
11213
  // src/components/Message.tsx
11214
- import React74, { forwardRef as forwardRef25, memo as memo31, useMemo as useMemo32 } from "react";
11214
+ import React75, { forwardRef as forwardRef25, memo as memo31, useMemo as useMemo32 } from "react";
11215
11215
  var Message = memo31(
11216
11216
  forwardRef25(function Message2({ role, children, user, avatarSize = INPUT_HEIGHT }, ref) {
11217
11217
  const randomId = crypto.randomUUID();
@@ -11222,7 +11222,7 @@ var Message = memo31(
11222
11222
  } : void 0,
11223
11223
  [userMessageBackgroundColor, role]
11224
11224
  );
11225
- return /* @__PURE__ */ React74.createElement(
11225
+ return /* @__PURE__ */ React75.createElement(
11226
11226
  "div",
11227
11227
  {
11228
11228
  className: cx(
@@ -11230,15 +11230,15 @@ var Message = memo31(
11230
11230
  role === "user" ? "flex-row-reverse" : "flex-row"
11231
11231
  )
11232
11232
  },
11233
- role === "assistant" ? /* @__PURE__ */ React74.createElement(
11233
+ role === "assistant" ? /* @__PURE__ */ React75.createElement(
11234
11234
  Avatar,
11235
11235
  {
11236
11236
  name: "Assistant",
11237
11237
  size: avatarSize,
11238
11238
  backgroundColor: cssVars.colors.primaryPastel
11239
11239
  },
11240
- /* @__PURE__ */ React74.createElement(Logo, { style: { width: 15 }, fill: cssVars.colors.primary })
11241
- ) : /* @__PURE__ */ React74.createElement(
11240
+ /* @__PURE__ */ React75.createElement(Logo, { style: { width: 15 }, fill: cssVars.colors.primary })
11241
+ ) : /* @__PURE__ */ React75.createElement(
11242
11242
  Avatar,
11243
11243
  {
11244
11244
  userId: !user ? randomId : user?.id,
@@ -11247,7 +11247,7 @@ var Message = memo31(
11247
11247
  size: avatarSize
11248
11248
  }
11249
11249
  ),
11250
- /* @__PURE__ */ React74.createElement(
11250
+ /* @__PURE__ */ React75.createElement(
11251
11251
  "div",
11252
11252
  {
11253
11253
  className: cx(
@@ -11257,7 +11257,7 @@ var Message = memo31(
11257
11257
  style: styles3,
11258
11258
  ref
11259
11259
  },
11260
- /* @__PURE__ */ React74.createElement(
11260
+ /* @__PURE__ */ React75.createElement(
11261
11261
  Text,
11262
11262
  {
11263
11263
  variant: "small",
@@ -11272,9 +11272,9 @@ var Message = memo31(
11272
11272
 
11273
11273
  // src/components/pipeline/PipelineResultLayout.tsx
11274
11274
  import { Link1Icon } from "@noya-app/noya-icons";
11275
- import React75 from "react";
11275
+ import React76 from "react";
11276
11276
  var PipelineResultLink = ({ url }) => {
11277
- return /* @__PURE__ */ React75.createElement("div", { className: "flex flex-col gap-0.5" }, /* @__PURE__ */ React75.createElement(
11277
+ return /* @__PURE__ */ React76.createElement("div", { className: "flex flex-col gap-0.5" }, /* @__PURE__ */ React76.createElement(
11278
11278
  "a",
11279
11279
  {
11280
11280
  href: url,
@@ -11282,15 +11282,15 @@ var PipelineResultLink = ({ url }) => {
11282
11282
  rel: "noopener noreferrer",
11283
11283
  className: "flex text-primary hover:opacity-80 border border-divider rounded-md"
11284
11284
  },
11285
- /* @__PURE__ */ React75.createElement("div", { className: "flex gap-1 items-center p-2" }, /* @__PURE__ */ React75.createElement(Link1Icon, { className: "w-[15px] h-[15px] flex-shrink-0" })),
11286
- /* @__PURE__ */ React75.createElement(DividerVertical, null),
11287
- /* @__PURE__ */ React75.createElement(Small, { className: "truncate p-2 flex-1" }, url)
11285
+ /* @__PURE__ */ React76.createElement("div", { className: "flex gap-1 items-center p-2" }, /* @__PURE__ */ React76.createElement(Link1Icon, { className: "w-[15px] h-[15px] flex-shrink-0" })),
11286
+ /* @__PURE__ */ React76.createElement(DividerVertical, null),
11287
+ /* @__PURE__ */ React76.createElement(Small, { className: "truncate p-2 flex-1" }, url)
11288
11288
  ));
11289
11289
  };
11290
11290
  var PipelineResultLayout = ({
11291
11291
  children
11292
11292
  }) => {
11293
- return /* @__PURE__ */ React75.createElement("div", { className: "flex flex-col gap-2" }, children);
11293
+ return /* @__PURE__ */ React76.createElement("div", { className: "flex flex-col gap-2" }, children);
11294
11294
  };
11295
11295
  function getPipelineResultLink(value) {
11296
11296
  if (typeof value !== "object" || value === null) return void 0;
@@ -11306,27 +11306,27 @@ function getPipelineResultLink(value) {
11306
11306
  // src/components/Progress.tsx
11307
11307
  import { clamp } from "@noya-app/noya-utils";
11308
11308
  import * as ProgressPrimitive from "@radix-ui/react-progress";
11309
- import * as React76 from "react";
11309
+ import * as React77 from "react";
11310
11310
  function Progress({
11311
11311
  value,
11312
11312
  variant = "normal",
11313
11313
  className
11314
11314
  }) {
11315
11315
  const clampedValue = clamp(value, 0, 100);
11316
- const transformStyles = React76.useMemo(
11316
+ const transformStyles = React77.useMemo(
11317
11317
  () => ({
11318
11318
  transform: `translateX(-${100 - clampedValue}%)`
11319
11319
  }),
11320
11320
  [clampedValue]
11321
11321
  );
11322
- return /* @__PURE__ */ React76.createElement(
11322
+ return /* @__PURE__ */ React77.createElement(
11323
11323
  ProgressPrimitive.Root,
11324
11324
  {
11325
11325
  className: cx(`relative hidden bg-input-background h-[5px] `, className),
11326
11326
  style: { transform: "translateZ(0)" },
11327
11327
  value: clampedValue
11328
11328
  },
11329
- /* @__PURE__ */ React76.createElement(
11329
+ /* @__PURE__ */ React77.createElement(
11330
11330
  ProgressPrimitive.Indicator,
11331
11331
  {
11332
11332
  className: `${variant === "primary" ? "bg-primary" : variant === "secondary" ? "bg-secondary" : variant === "warning" ? "bg-warning" : "bg-text"} transition-[transform_660ms_cubic-bezier(0.65,0,0.35,1) w-full h-full`,
@@ -11337,7 +11337,7 @@ function Progress({
11337
11337
  }
11338
11338
 
11339
11339
  // src/components/Section.tsx
11340
- import React77, { memo as memo32, useMemo as useMemo34 } from "react";
11340
+ import React78, { memo as memo32, useMemo as useMemo34 } from "react";
11341
11341
  var titleIconStyle = {
11342
11342
  marginRight: "8px",
11343
11343
  alignSelf: "flex-start",
@@ -11372,7 +11372,7 @@ var SectionInternal = ({
11372
11372
  }),
11373
11373
  [titleTextStyle, title, extraPadding, styleProp]
11374
11374
  );
11375
- const hasChildren = React77.Children.toArray(children).some((child) => !!child);
11375
+ const hasChildren = React78.Children.toArray(children).some((child) => !!child);
11376
11376
  const headerStyle = useMemo34(
11377
11377
  () => ({
11378
11378
  marginBottom: hasChildren ? "4px" : void 0,
@@ -11380,7 +11380,7 @@ var SectionInternal = ({
11380
11380
  }),
11381
11381
  [hasChildren]
11382
11382
  );
11383
- return /* @__PURE__ */ React77.createElement("div", { style: style2, className }, (title || titleIcon || right) && /* @__PURE__ */ React77.createElement(InspectorPrimitives_exports.SectionHeader, { style: headerStyle }, titleIcon && /* @__PURE__ */ React77.createElement("div", { style: titleIconStyle, className: textStyles[titleTextStyle] }, titleIconOptions.inlineBlockWrapper ? /* @__PURE__ */ React77.createElement("div", { style: titleIconWrapperStyle }, titleIcon) : titleIcon), title && /* @__PURE__ */ React77.createElement(React77.Fragment, null, onClickTitle ? /* @__PURE__ */ React77.createElement(Button, { variant: "none", onClick: onClickTitle }, /* @__PURE__ */ React77.createElement(InspectorPrimitives_exports.Title, { $textStyle: titleTextStyle }, title)) : /* @__PURE__ */ React77.createElement(InspectorPrimitives_exports.Title, { $textStyle: titleTextStyle }, title)), /* @__PURE__ */ React77.createElement(Spacer.Horizontal, null), right), /* @__PURE__ */ React77.createElement(IndentContext.Provider, { value: { indentLevel: 1 } }, children));
11383
+ return /* @__PURE__ */ React78.createElement("div", { style: style2, className }, (title || titleIcon || right) && /* @__PURE__ */ React78.createElement(InspectorPrimitives_exports.SectionHeader, { style: headerStyle }, titleIcon && /* @__PURE__ */ React78.createElement("div", { style: titleIconStyle, className: textStyles[titleTextStyle] }, titleIconOptions.inlineBlockWrapper ? /* @__PURE__ */ React78.createElement("div", { style: titleIconWrapperStyle }, titleIcon) : titleIcon), title && /* @__PURE__ */ React78.createElement(React78.Fragment, null, onClickTitle ? /* @__PURE__ */ React78.createElement(Button, { variant: "none", onClick: onClickTitle }, /* @__PURE__ */ React78.createElement(InspectorPrimitives_exports.Title, { $textStyle: titleTextStyle }, title)) : /* @__PURE__ */ React78.createElement(InspectorPrimitives_exports.Title, { $textStyle: titleTextStyle }, title)), /* @__PURE__ */ React78.createElement(Spacer.Horizontal, null), right), /* @__PURE__ */ React78.createElement(IndentContext.Provider, { value: { indentLevel: 1 } }, children));
11384
11384
  };
11385
11385
  var ExpandableSection = ({
11386
11386
  storageKey,
@@ -11393,12 +11393,12 @@ var ExpandableSection = ({
11393
11393
  initialVisibility
11394
11394
  );
11395
11395
  const expanded = visibility === "show";
11396
- return /* @__PURE__ */ React77.createElement(
11396
+ return /* @__PURE__ */ React78.createElement(
11397
11397
  SectionInternal,
11398
11398
  {
11399
11399
  ...props,
11400
11400
  right: !props.hideRightWhenCollapsed || expanded ? props.right : null,
11401
- title: /* @__PURE__ */ React77.createElement("div", { className: "flex gap-1 items-center" }, props.title, /* @__PURE__ */ React77.createElement(
11401
+ title: /* @__PURE__ */ React78.createElement("div", { className: "flex gap-1 items-center" }, props.title, /* @__PURE__ */ React78.createElement(
11402
11402
  IconButton,
11403
11403
  {
11404
11404
  iconName: expanded ? "ChevronDownIcon2" : "ChevronRightIcon2",
@@ -11413,12 +11413,12 @@ var Section = memo32(function InspectorSection({
11413
11413
  storageKey,
11414
11414
  ...props
11415
11415
  }) {
11416
- return storageKey ? /* @__PURE__ */ React77.createElement(ExpandableSection, { ...props, storageKey }) : /* @__PURE__ */ React77.createElement(SectionInternal, { ...props });
11416
+ return storageKey ? /* @__PURE__ */ React78.createElement(ExpandableSection, { ...props, storageKey }) : /* @__PURE__ */ React78.createElement(SectionInternal, { ...props });
11417
11417
  });
11418
11418
 
11419
11419
  // src/components/SegmentedControl.tsx
11420
11420
  import * as ToggleGroupPrimitive2 from "@radix-ui/react-toggle-group";
11421
- import React78, {
11421
+ import React79, {
11422
11422
  createContext as createContext13,
11423
11423
  forwardRef as forwardRef26,
11424
11424
  useCallback as useCallback30,
@@ -11439,7 +11439,7 @@ var SegmentedControlItem = forwardRef26(function SegmentedControlItem2({
11439
11439
  ...props
11440
11440
  }, forwardedRef) {
11441
11441
  const { colorScheme } = useContext14(SegmentedControlContext);
11442
- const itemElement = /* @__PURE__ */ React78.createElement(
11442
+ const itemElement = /* @__PURE__ */ React79.createElement(
11443
11443
  ToggleGroupPrimitive2.Item,
11444
11444
  {
11445
11445
  ref: forwardedRef,
@@ -11459,7 +11459,7 @@ var SegmentedControlItem = forwardRef26(function SegmentedControlItem2({
11459
11459
  ),
11460
11460
  ...props
11461
11461
  },
11462
- /* @__PURE__ */ React78.createElement(
11462
+ /* @__PURE__ */ React79.createElement(
11463
11463
  "span",
11464
11464
  {
11465
11465
  className: cx(
@@ -11471,7 +11471,7 @@ var SegmentedControlItem = forwardRef26(function SegmentedControlItem2({
11471
11471
  title
11472
11472
  )
11473
11473
  );
11474
- return tooltip ? /* @__PURE__ */ React78.createElement(Tooltip, { content: tooltip }, itemElement) : itemElement;
11474
+ return tooltip ? /* @__PURE__ */ React79.createElement(Tooltip, { content: tooltip }, itemElement) : itemElement;
11475
11475
  });
11476
11476
  var SegmentedControl = memoGeneric(function SegmentedControl2({
11477
11477
  id: idProp,
@@ -11493,7 +11493,7 @@ var SegmentedControl = memoGeneric(function SegmentedControl2({
11493
11493
  },
11494
11494
  [allowEmpty, onValueChange]
11495
11495
  );
11496
- return /* @__PURE__ */ React78.createElement(SegmentedControlContext.Provider, { value: contextValue }, /* @__PURE__ */ React78.createElement(
11496
+ return /* @__PURE__ */ React79.createElement(SegmentedControlContext.Provider, { value: contextValue }, /* @__PURE__ */ React79.createElement(
11497
11497
  ToggleGroupPrimitive2.Root,
11498
11498
  {
11499
11499
  id,
@@ -11511,13 +11511,13 @@ var SegmentedControl = memoGeneric(function SegmentedControl2({
11511
11511
  gridTemplateColumns: `repeat(${items.length}, 1fr)`
11512
11512
  }
11513
11513
  },
11514
- items.map((item, index) => /* @__PURE__ */ React78.createElement(SegmentedControlItem, { key: index, ...item, variant }))
11514
+ items.map((item, index) => /* @__PURE__ */ React79.createElement(SegmentedControlItem, { key: index, ...item, variant }))
11515
11515
  ));
11516
11516
  });
11517
11517
 
11518
11518
  // src/components/SelectionToolbar.tsx
11519
11519
  import * as PopperPrimitive from "@radix-ui/react-popper";
11520
- import React79, { memo as memo33, useMemo as useMemo36 } from "react";
11520
+ import React80, { memo as memo33, useMemo as useMemo36 } from "react";
11521
11521
  import { createPortal as createPortal3 } from "react-dom";
11522
11522
  var createVirtualElement = (rect) => ({
11523
11523
  getBoundingClientRect: () => ({
@@ -11539,7 +11539,7 @@ var SelectionToolbarContainer = memo33(
11539
11539
  portalContainer
11540
11540
  }) {
11541
11541
  const portalScopeId = usePortalScopeId();
11542
- const containerRef = React79.useRef(null);
11542
+ const containerRef = React80.useRef(null);
11543
11543
  const size2 = useSize(containerRef, "width");
11544
11544
  const virtualRef = useMemo36(
11545
11545
  () => ({
@@ -11547,7 +11547,7 @@ var SelectionToolbarContainer = memo33(
11547
11547
  }),
11548
11548
  [rect]
11549
11549
  );
11550
- const popperContent = /* @__PURE__ */ React79.createElement(
11550
+ const popperContent = /* @__PURE__ */ React80.createElement(
11551
11551
  PopperPrimitive.Content,
11552
11552
  {
11553
11553
  ...portalScopeProps(portalScopeId),
@@ -11564,7 +11564,7 @@ var SelectionToolbarContainer = memo33(
11564
11564
  ["--n-input-background"]: "transparent"
11565
11565
  }
11566
11566
  },
11567
- /* @__PURE__ */ React79.createElement(
11567
+ /* @__PURE__ */ React80.createElement(
11568
11568
  "div",
11569
11569
  {
11570
11570
  ref: containerRef,
@@ -11577,7 +11577,7 @@ var SelectionToolbarContainer = memo33(
11577
11577
  children
11578
11578
  )
11579
11579
  );
11580
- return /* @__PURE__ */ React79.createElement(PopperPrimitive.Root, null, /* @__PURE__ */ React79.createElement(PopperPrimitive.Anchor, { virtualRef }), portalContainer ? createPortal3(popperContent, portalContainer) : popperContent);
11580
+ return /* @__PURE__ */ React80.createElement(PopperPrimitive.Root, null, /* @__PURE__ */ React80.createElement(PopperPrimitive.Anchor, { virtualRef }), portalContainer ? createPortal3(popperContent, portalContainer) : popperContent);
11581
11581
  }
11582
11582
  );
11583
11583
 
@@ -11588,7 +11588,7 @@ import {
11588
11588
  DropdownChevronIcon as DropdownChevronIcon3
11589
11589
  } from "@noya-app/noya-icons";
11590
11590
  import * as Select from "@radix-ui/react-select";
11591
- import React80, {
11591
+ import React81, {
11592
11592
  useMemo as useMemo37,
11593
11593
  useState as useState28
11594
11594
  } from "react";
@@ -11622,7 +11622,7 @@ var SelectMenuTrigger = memoGeneric(function SelectMenuTrigger2({
11622
11622
  fieldId: props.id
11623
11623
  });
11624
11624
  const labelPosition = useLabelPosition();
11625
- return /* @__PURE__ */ React80.createElement(Select.SelectTrigger, { asChild: true, onFocus, onBlur }, /* @__PURE__ */ React80.createElement(
11625
+ return /* @__PURE__ */ React81.createElement(Select.SelectTrigger, { asChild: true, onFocus, onBlur }, /* @__PURE__ */ React81.createElement(
11626
11626
  Button,
11627
11627
  {
11628
11628
  id,
@@ -11634,10 +11634,10 @@ var SelectMenuTrigger = memoGeneric(function SelectMenuTrigger2({
11634
11634
  ),
11635
11635
  disabled
11636
11636
  },
11637
- icon && /* @__PURE__ */ React80.createElement("span", { className: "pr-1.5" }, renderIcon(icon)),
11638
- label && labelPosition === "inset" && /* @__PURE__ */ React80.createElement("div", { className: insetEndStyles }, /* @__PURE__ */ React80.createElement(Label, { className: "pr-4 text-text-disabled", htmlFor: id }, label)),
11639
- /* @__PURE__ */ React80.createElement("span", { className: "flex-1 flex" }, /* @__PURE__ */ React80.createElement(Select.Value, { placeholder })),
11640
- /* @__PURE__ */ React80.createElement(
11637
+ icon && /* @__PURE__ */ React81.createElement("span", { className: "pr-1.5" }, renderIcon(icon)),
11638
+ label && labelPosition === "inset" && /* @__PURE__ */ React81.createElement("div", { className: insetEndStyles }, /* @__PURE__ */ React81.createElement(Label, { className: "pr-4 text-text-disabled", htmlFor: id }, label)),
11639
+ /* @__PURE__ */ React81.createElement("span", { className: "flex-1 flex" }, /* @__PURE__ */ React81.createElement(Select.Value, { placeholder })),
11640
+ /* @__PURE__ */ React81.createElement(
11641
11641
  DropdownChevronIcon3,
11642
11642
  {
11643
11643
  className: cx(
@@ -11686,7 +11686,7 @@ var SelectMenu = memoGeneric(function SelectMenu2({
11686
11686
  setInternalOpen(open2);
11687
11687
  };
11688
11688
  const readOnlyButton = useMemo37(
11689
- () => /* @__PURE__ */ React80.createElement(
11689
+ () => /* @__PURE__ */ React81.createElement(
11690
11690
  Button,
11691
11691
  {
11692
11692
  id,
@@ -11696,7 +11696,7 @@ var SelectMenu = memoGeneric(function SelectMenu2({
11696
11696
  disabled
11697
11697
  },
11698
11698
  icon && renderIcon(icon),
11699
- /* @__PURE__ */ React80.createElement("span", { className: "flex flex-1" }, selectedItem?.title ?? value)
11699
+ /* @__PURE__ */ React81.createElement("span", { className: "flex flex-1" }, selectedItem?.title ?? value)
11700
11700
  ),
11701
11701
  [icon, id, style2, className, disabled, value, selectedItem]
11702
11702
  );
@@ -11708,7 +11708,7 @@ var SelectMenu = memoGeneric(function SelectMenu2({
11708
11708
  ...contentStyleProp
11709
11709
  };
11710
11710
  }, [contentStyleProp]);
11711
- const content = /* @__PURE__ */ React80.createElement(
11711
+ const content = /* @__PURE__ */ React81.createElement(
11712
11712
  Select.Root,
11713
11713
  {
11714
11714
  value,
@@ -11716,7 +11716,7 @@ var SelectMenu = memoGeneric(function SelectMenu2({
11716
11716
  open,
11717
11717
  onOpenChange: handleOpenChange
11718
11718
  },
11719
- /* @__PURE__ */ React80.createElement(
11719
+ /* @__PURE__ */ React81.createElement(
11720
11720
  SelectMenuTrigger,
11721
11721
  {
11722
11722
  id,
@@ -11731,7 +11731,7 @@ var SelectMenu = memoGeneric(function SelectMenu2({
11731
11731
  label
11732
11732
  }
11733
11733
  ),
11734
- /* @__PURE__ */ React80.createElement(Select.Portal, null, /* @__PURE__ */ React80.createElement(
11734
+ /* @__PURE__ */ React81.createElement(Select.Portal, null, /* @__PURE__ */ React81.createElement(
11735
11735
  Select.Content,
11736
11736
  {
11737
11737
  ...portalScopeProps(portalScopeId),
@@ -11742,14 +11742,14 @@ var SelectMenu = memoGeneric(function SelectMenu2({
11742
11742
  align: "center",
11743
11743
  style: contentStyle
11744
11744
  },
11745
- /* @__PURE__ */ React80.createElement(Select.ScrollUpButton, { className: scrollButtonStyles }, /* @__PURE__ */ React80.createElement(
11745
+ /* @__PURE__ */ React81.createElement(Select.ScrollUpButton, { className: scrollButtonStyles }, /* @__PURE__ */ React81.createElement(
11746
11746
  ChevronUpIcon,
11747
11747
  {
11748
11748
  className: cx("transition-transform duration-100")
11749
11749
  }
11750
11750
  )),
11751
- /* @__PURE__ */ React80.createElement(Select.Viewport, null, /* @__PURE__ */ React80.createElement(MenuViewport, { items, Components: Components3 })),
11752
- /* @__PURE__ */ React80.createElement(Select.ScrollDownButton, { className: scrollButtonStyles }, /* @__PURE__ */ React80.createElement(ChevronDownIcon, null))
11751
+ /* @__PURE__ */ React81.createElement(Select.Viewport, null, /* @__PURE__ */ React81.createElement(MenuViewport, { items, Components: Components3 })),
11752
+ /* @__PURE__ */ React81.createElement(Select.ScrollDownButton, { className: scrollButtonStyles }, /* @__PURE__ */ React81.createElement(ChevronDownIcon, null))
11753
11753
  ))
11754
11754
  );
11755
11755
  return readOnly ? readOnlyButton : content;
@@ -11757,7 +11757,7 @@ var SelectMenu = memoGeneric(function SelectMenu2({
11757
11757
 
11758
11758
  // src/components/Slider.tsx
11759
11759
  import * as RadixSlider from "@radix-ui/react-slider";
11760
- import React81, { memo as memo34, useCallback as useCallback31, useMemo as useMemo38 } from "react";
11760
+ import React82, { memo as memo34, useCallback as useCallback31, useMemo as useMemo38 } from "react";
11761
11761
  var THUMB_WIDTH = 8;
11762
11762
  var thumbStyle = {
11763
11763
  width: THUMB_WIDTH
@@ -11812,7 +11812,7 @@ var Slider = memo34(function Slider2({
11812
11812
  }),
11813
11813
  [percentage.raw]
11814
11814
  );
11815
- return /* @__PURE__ */ React81.createElement(
11815
+ return /* @__PURE__ */ React82.createElement(
11816
11816
  RadixSlider.Root,
11817
11817
  {
11818
11818
  min,
@@ -11830,7 +11830,7 @@ var Slider = memo34(function Slider2({
11830
11830
  onBlur,
11831
11831
  disabled: readOnly
11832
11832
  },
11833
- /* @__PURE__ */ React81.createElement(RadixSlider.Track, { className: "flex-grow h-full rounded overflow-hidden bg-input-background" }, label && labelPosition === "inset" && /* @__PURE__ */ React81.createElement("div", { className: insetEndStyles2 }, /* @__PURE__ */ React81.createElement(Label, { htmlFor: id, className: "text-text-disabled" }, label)), /* @__PURE__ */ React81.createElement(
11833
+ /* @__PURE__ */ React82.createElement(RadixSlider.Track, { className: "flex-grow h-full rounded overflow-hidden bg-input-background" }, label && labelPosition === "inset" && /* @__PURE__ */ React82.createElement("div", { className: insetEndStyles2 }, /* @__PURE__ */ React82.createElement(Label, { htmlFor: id, className: "text-text-disabled" }, label)), /* @__PURE__ */ React82.createElement(
11834
11834
  "div",
11835
11835
  {
11836
11836
  style: trackFillStyle,
@@ -11841,8 +11841,8 @@ var Slider = memo34(function Slider2({
11841
11841
  )
11842
11842
  }
11843
11843
  )),
11844
- label && labelPosition === "inset" && colorScheme !== void 0 && /* @__PURE__ */ React81.createElement("div", { className: insetEndStyles2 }, /* @__PURE__ */ React81.createElement(Label, { className: "text-white overflow-hidden", style: labelStyle }, label)),
11845
- /* @__PURE__ */ React81.createElement(
11844
+ label && labelPosition === "inset" && colorScheme !== void 0 && /* @__PURE__ */ React82.createElement("div", { className: insetEndStyles2 }, /* @__PURE__ */ React82.createElement(Label, { className: "text-white overflow-hidden", style: labelStyle }, label)),
11845
+ /* @__PURE__ */ React82.createElement(
11846
11846
  RadixSlider.Thumb,
11847
11847
  {
11848
11848
  style: thumbStyle,
@@ -11858,27 +11858,27 @@ var Slider = memo34(function Slider2({
11858
11858
  });
11859
11859
 
11860
11860
  // src/components/sorting/createSharedDrag.tsx
11861
- import * as React82 from "react";
11861
+ import * as React83 from "react";
11862
11862
  function createSharedDrag() {
11863
- const dragRegistrationContext = React82.createContext(null);
11864
- const activeDragContext = React82.createContext(
11863
+ const dragRegistrationContext = React83.createContext(null);
11864
+ const activeDragContext = React83.createContext(
11865
11865
  null
11866
11866
  );
11867
11867
  const sharedDragProps = {
11868
11868
  dragRegistrationContext,
11869
11869
  activeDragContext
11870
11870
  };
11871
- const Provider3 = ({ children }) => /* @__PURE__ */ React82.createElement(SharedDragProvider, { sharedDragProps }, children);
11871
+ const Provider3 = ({ children }) => /* @__PURE__ */ React83.createElement(SharedDragProvider, { sharedDragProps }, children);
11872
11872
  return {
11873
11873
  Provider: Provider3,
11874
- Sortable: (props) => /* @__PURE__ */ React82.createElement(Sortable, { sharedDragProps, ...props }),
11874
+ Sortable: (props) => /* @__PURE__ */ React83.createElement(Sortable, { sharedDragProps, ...props }),
11875
11875
  props: sharedDragProps
11876
11876
  };
11877
11877
  }
11878
11878
 
11879
11879
  // src/components/Switch.tsx
11880
11880
  import * as SwitchPrimitive from "@radix-ui/react-switch";
11881
- import * as React83 from "react";
11881
+ import * as React84 from "react";
11882
11882
  var Switch = function Switch2({
11883
11883
  id,
11884
11884
  value,
@@ -11890,7 +11890,7 @@ var Switch = function Switch2({
11890
11890
  style: style2,
11891
11891
  className
11892
11892
  }) {
11893
- return /* @__PURE__ */ React83.createElement(
11893
+ return /* @__PURE__ */ React84.createElement(
11894
11894
  SwitchPrimitive.Root,
11895
11895
  {
11896
11896
  id,
@@ -11909,12 +11909,12 @@ var Switch = function Switch2({
11909
11909
  onFocus,
11910
11910
  onBlur
11911
11911
  },
11912
- /* @__PURE__ */ React83.createElement(SwitchPrimitive.Thumb, { className: "block w-[15px] h-[15px] bg-background rounded-full transition-transform translate-x-[2px] data-[state=checked]:translate-x-[15px]" })
11912
+ /* @__PURE__ */ React84.createElement(SwitchPrimitive.Thumb, { className: "block w-[15px] h-[15px] bg-background rounded-full transition-transform translate-x-[2px] data-[state=checked]:translate-x-[15px]" })
11913
11913
  );
11914
11914
  };
11915
11915
 
11916
11916
  // src/components/UserPointer.tsx
11917
- import React84, { memo as memo35, useMemo as useMemo39 } from "react";
11917
+ import React85, { memo as memo35, useMemo as useMemo39 } from "react";
11918
11918
  var UserPointerContainer = memo35(function UserPointerContainer2({
11919
11919
  point,
11920
11920
  visible,
@@ -11922,7 +11922,7 @@ var UserPointerContainer = memo35(function UserPointerContainer2({
11922
11922
  className,
11923
11923
  style: style2
11924
11924
  }) {
11925
- return /* @__PURE__ */ React84.createElement(
11925
+ return /* @__PURE__ */ React85.createElement(
11926
11926
  "div",
11927
11927
  {
11928
11928
  style: {
@@ -11945,7 +11945,7 @@ var UserNameTag = memo35(function UserNameTag2({
11945
11945
  style: style2,
11946
11946
  children
11947
11947
  }) {
11948
- return /* @__PURE__ */ React84.createElement(
11948
+ return /* @__PURE__ */ React85.createElement(
11949
11949
  "span",
11950
11950
  {
11951
11951
  className: cx(
@@ -11968,7 +11968,7 @@ var UserPointerIcon = memo35(function PointerIcon({
11968
11968
  style: style2
11969
11969
  }) {
11970
11970
  const points = "0,5 10,0 10,10";
11971
- return /* @__PURE__ */ React84.createElement(
11971
+ return /* @__PURE__ */ React85.createElement(
11972
11972
  "svg",
11973
11973
  {
11974
11974
  width: size2,
@@ -11983,7 +11983,7 @@ var UserPointerIcon = memo35(function PointerIcon({
11983
11983
  ...style2
11984
11984
  }
11985
11985
  },
11986
- /* @__PURE__ */ React84.createElement(
11986
+ /* @__PURE__ */ React85.createElement(
11987
11987
  "polygon",
11988
11988
  {
11989
11989
  points,
@@ -12020,7 +12020,7 @@ var UserPointer = memo35(function UserPointer2({
12020
12020
  () => ({ marginLeft: `${POINTER_SIZE - POINTER_OVERLAP + 1}px` }),
12021
12021
  []
12022
12022
  );
12023
- return /* @__PURE__ */ React84.createElement(
12023
+ return /* @__PURE__ */ React85.createElement(
12024
12024
  UserPointerContainer,
12025
12025
  {
12026
12026
  point,
@@ -12028,14 +12028,14 @@ var UserPointer = memo35(function UserPointer2({
12028
12028
  className,
12029
12029
  style: style2
12030
12030
  },
12031
- name && /* @__PURE__ */ React84.createElement("div", { className: "relative" }, /* @__PURE__ */ React84.createElement(
12031
+ name && /* @__PURE__ */ React85.createElement("div", { className: "relative" }, /* @__PURE__ */ React85.createElement(
12032
12032
  UserPointerIcon,
12033
12033
  {
12034
12034
  size: POINTER_SIZE,
12035
12035
  color: userBackgroundColor,
12036
12036
  style: pointerOverlapStyle
12037
12037
  }
12038
- ), /* @__PURE__ */ React84.createElement(
12038
+ ), /* @__PURE__ */ React85.createElement(
12039
12039
  UserNameTag,
12040
12040
  {
12041
12041
  backgroundColor: userBackgroundColor,
@@ -12048,7 +12048,7 @@ var UserPointer = memo35(function UserPointer2({
12048
12048
 
12049
12049
  // src/components/workspace/WorkspaceLayout.tsx
12050
12050
  import { useKeyboardShortcuts as useKeyboardShortcuts3 } from "@noya-app/noya-keymap";
12051
- import React88, {
12051
+ import React89, {
12052
12052
  forwardRef as forwardRef27,
12053
12053
  memo as memo38,
12054
12054
  useCallback as useCallback32,
@@ -12078,7 +12078,7 @@ function useWindowSize() {
12078
12078
  }
12079
12079
 
12080
12080
  // src/components/workspace/DrawerWorkspaceLayout.tsx
12081
- import React86, { memo as memo36, useLayoutEffect as useLayoutEffect10, useRef as useRef26, useState as useState30 } from "react";
12081
+ import React87, { memo as memo36, useLayoutEffect as useLayoutEffect10, useRef as useRef26, useState as useState30 } from "react";
12082
12082
 
12083
12083
  // src/hooks/usePreservePanelSize.tsx
12084
12084
  import { useLayoutEffect as useLayoutEffect9, useRef as useRef25 } from "react";
@@ -12239,14 +12239,14 @@ var DrawerWorkspaceLayout = memo36(function DrawerWorkspaceLayout2({
12239
12239
  }, [handleChangeLayoutState, mounted]);
12240
12240
  const leftSidebarCollapsed = internalLayoutState?.leftSidebarCollapsed ?? false;
12241
12241
  const rightSidebarCollapsed = internalLayoutState?.rightSidebarCollapsed ?? false;
12242
- return /* @__PURE__ */ React86.createElement(
12242
+ return /* @__PURE__ */ React87.createElement(
12243
12243
  "div",
12244
12244
  {
12245
12245
  ref: portalContainer,
12246
12246
  id: EDITOR_PANEL_GROUP_ID,
12247
12247
  className: "flex flex-1 relative focus:outline-none"
12248
12248
  },
12249
- leftPanel && /* @__PURE__ */ React86.createElement(
12249
+ leftPanel && /* @__PURE__ */ React87.createElement(
12250
12250
  Drawer,
12251
12251
  {
12252
12252
  id: LEFT_SIDEBAR_ID,
@@ -12267,7 +12267,7 @@ var DrawerWorkspaceLayout = memo36(function DrawerWorkspaceLayout2({
12267
12267
  leftPanel
12268
12268
  ),
12269
12269
  centerPanel,
12270
- rightPanel && /* @__PURE__ */ React86.createElement(
12270
+ rightPanel && /* @__PURE__ */ React87.createElement(
12271
12271
  Drawer,
12272
12272
  {
12273
12273
  id: RIGHT_SIDEBAR_ID,
@@ -12291,7 +12291,7 @@ var DrawerWorkspaceLayout = memo36(function DrawerWorkspaceLayout2({
12291
12291
  });
12292
12292
 
12293
12293
  // src/components/workspace/PanelWorkspaceLayout.tsx
12294
- import React87, { memo as memo37, useRef as useRef27 } from "react";
12294
+ import React88, { memo as memo37, useRef as useRef27 } from "react";
12295
12295
  import {
12296
12296
  Panel,
12297
12297
  PanelGroup,
@@ -12312,7 +12312,7 @@ var PanelWorkspaceLayout = memo37(function PanelWorkspaceLayout2({
12312
12312
  }) {
12313
12313
  const panelGroupRef = useRef27(null);
12314
12314
  usePreservePanelSize(panelGroupRef, handleChangeLayoutState);
12315
- return /* @__PURE__ */ React87.createElement(
12315
+ return /* @__PURE__ */ React88.createElement(
12316
12316
  PanelGroup,
12317
12317
  {
12318
12318
  ref: panelGroupRef,
@@ -12321,7 +12321,7 @@ var PanelWorkspaceLayout = memo37(function PanelWorkspaceLayout2({
12321
12321
  direction: "horizontal",
12322
12322
  autoSaveId: autoSavePrefix ? `${autoSavePrefix}--${EDITOR_PANEL_GROUP_ID}` : void 0
12323
12323
  },
12324
- leftPanel && /* @__PURE__ */ React87.createElement(React87.Fragment, null, /* @__PURE__ */ React87.createElement(
12324
+ leftPanel && /* @__PURE__ */ React88.createElement(React88.Fragment, null, /* @__PURE__ */ React88.createElement(
12325
12325
  Panel,
12326
12326
  {
12327
12327
  id: LEFT_SIDEBAR_ID,
@@ -12334,8 +12334,8 @@ var PanelWorkspaceLayout = memo37(function PanelWorkspaceLayout2({
12334
12334
  collapsible: true
12335
12335
  },
12336
12336
  internalLayoutState?.leftSidebarCollapsed ? null : leftPanel
12337
- ), /* @__PURE__ */ React87.createElement(PanelResizeHandle, { className: "cursor-col-resize w-px h-full bg-divider" })),
12338
- /* @__PURE__ */ React87.createElement(
12337
+ ), /* @__PURE__ */ React88.createElement(PanelResizeHandle, { className: "cursor-col-resize w-px h-full bg-divider" })),
12338
+ /* @__PURE__ */ React88.createElement(
12339
12339
  Panel,
12340
12340
  {
12341
12341
  id: CONTENT_AREA_ID,
@@ -12346,7 +12346,7 @@ var PanelWorkspaceLayout = memo37(function PanelWorkspaceLayout2({
12346
12346
  },
12347
12347
  centerPanel
12348
12348
  ),
12349
- rightPanel && /* @__PURE__ */ React87.createElement(React87.Fragment, null, /* @__PURE__ */ React87.createElement(PanelResizeHandle, { className: "cursor-col-resize w-px h-full bg-divider" }), /* @__PURE__ */ React87.createElement(
12349
+ rightPanel && /* @__PURE__ */ React88.createElement(React88.Fragment, null, /* @__PURE__ */ React88.createElement(PanelResizeHandle, { className: "cursor-col-resize w-px h-full bg-divider" }), /* @__PURE__ */ React88.createElement(
12350
12350
  Panel,
12351
12351
  {
12352
12352
  id: RIGHT_SIDEBAR_ID,
@@ -12395,7 +12395,7 @@ var WorkspaceLayout = forwardRef27(function WorkspaceLayout2({
12395
12395
  } = {},
12396
12396
  theme
12397
12397
  }, forwardedRef) {
12398
- const containerRef = React88.useRef(null);
12398
+ const containerRef = React89.useRef(null);
12399
12399
  const containerSize = useSize(containerRef);
12400
12400
  const windowSize = useWindowSize();
12401
12401
  const parentSize = detectSize === "window" ? windowSize : containerSize && containerSize.width > 0 ? containerSize : windowSize;
@@ -12493,7 +12493,7 @@ var WorkspaceLayout = forwardRef27(function WorkspaceLayout2({
12493
12493
  }
12494
12494
  });
12495
12495
  const centerPanelPercentage = 100 - (left ? leftSidebarPercentage : 0) - (right ? rightSidebarPercentage : 0);
12496
- const leftPanel = left ? /* @__PURE__ */ React88.createElement(
12496
+ const leftPanel = left ? /* @__PURE__ */ React89.createElement(
12497
12497
  PanelInner,
12498
12498
  {
12499
12499
  style: leftStyle,
@@ -12501,7 +12501,7 @@ var WorkspaceLayout = forwardRef27(function WorkspaceLayout2({
12501
12501
  },
12502
12502
  left
12503
12503
  ) : null;
12504
- const rightPanel = right ? /* @__PURE__ */ React88.createElement(
12504
+ const rightPanel = right ? /* @__PURE__ */ React89.createElement(
12505
12505
  PanelInner,
12506
12506
  {
12507
12507
  style: rightStyle,
@@ -12509,7 +12509,7 @@ var WorkspaceLayout = forwardRef27(function WorkspaceLayout2({
12509
12509
  },
12510
12510
  right
12511
12511
  ) : null;
12512
- const centerPanel = /* @__PURE__ */ React88.createElement(PanelInner, { className: "bg-canvas-background" }, children);
12512
+ const centerPanel = /* @__PURE__ */ React89.createElement(PanelInner, { className: "bg-canvas-background" }, children);
12513
12513
  const leftSidebarOptions = {
12514
12514
  minSize: leftSidebarMinPercentage,
12515
12515
  maxSize: leftSidebarMaxPercentage,
@@ -12524,7 +12524,7 @@ var WorkspaceLayout = forwardRef27(function WorkspaceLayout2({
12524
12524
  };
12525
12525
  const LayoutComponent = sideType === "panel" ? PanelWorkspaceLayout : sideType === "drawer" ? DrawerWorkspaceLayout : parentSize.width > sideTypeBreakpoint ? PanelWorkspaceLayout : DrawerWorkspaceLayout;
12526
12526
  const readyToRender = detectSize === "window" || containerSize && containerSize.width > 0;
12527
- return /* @__PURE__ */ React88.createElement(
12527
+ return /* @__PURE__ */ React89.createElement(
12528
12528
  "div",
12529
12529
  {
12530
12530
  ref: containerRef,
@@ -12534,7 +12534,7 @@ var WorkspaceLayout = forwardRef27(function WorkspaceLayout2({
12534
12534
  "data-theme": theme
12535
12535
  },
12536
12536
  toolbar,
12537
- /* @__PURE__ */ React88.createElement("div", { className: "flex flex-row flex-1 relative" }, readyToRender && /* @__PURE__ */ React88.createElement(
12537
+ /* @__PURE__ */ React89.createElement("div", { className: "flex flex-row flex-1 relative" }, readyToRender && /* @__PURE__ */ React89.createElement(
12538
12538
  LayoutComponent,
12539
12539
  {
12540
12540
  leftPanel,
@@ -12557,7 +12557,7 @@ var PanelInner = memo38(function PanelInner2({
12557
12557
  style: style2,
12558
12558
  className
12559
12559
  }) {
12560
- return /* @__PURE__ */ React88.createElement("div", { style: style2, className: cx("absolute inset-0 flex", className) }, children);
12560
+ return /* @__PURE__ */ React89.createElement("div", { style: style2, className: cx("absolute inset-0 flex", className) }, children);
12561
12561
  });
12562
12562
 
12563
12563
  // src/hooks/usePlatform.ts
@@ -12712,11 +12712,11 @@ var SUPPORTED_CANVAS_UPLOAD_TYPES = [
12712
12712
 
12713
12713
  // src/components/DimensionInput.tsx
12714
12714
  import { round } from "@noya-app/noya-utils";
12715
- import * as React89 from "react";
12715
+ import * as React90 from "react";
12716
12716
  function getNewValue(value, mode, delta) {
12717
12717
  return delta === void 0 ? value : mode === "replace" ? delta : value + delta;
12718
12718
  }
12719
- var DimensionInput = React89.memo(function DimensionInput2({
12719
+ var DimensionInput = React90.memo(function DimensionInput2({
12720
12720
  id,
12721
12721
  value,
12722
12722
  onSetValue,
@@ -12726,15 +12726,15 @@ var DimensionInput = React89.memo(function DimensionInput2({
12726
12726
  disabled,
12727
12727
  trigger = "submit"
12728
12728
  }) {
12729
- const handleNudgeValue = React89.useCallback(
12729
+ const handleNudgeValue = React90.useCallback(
12730
12730
  (value2) => onSetValue(value2, "adjust"),
12731
12731
  [onSetValue]
12732
12732
  );
12733
- const handleSetValue = React89.useCallback(
12733
+ const handleSetValue = React90.useCallback(
12734
12734
  (value2) => onSetValue(value2, "replace"),
12735
12735
  [onSetValue]
12736
12736
  );
12737
- return /* @__PURE__ */ React89.createElement(LabeledField, { label, labelPosition: "inset" }, /* @__PURE__ */ React89.createElement(InputField2.Root, { id, width: size2 }, /* @__PURE__ */ React89.createElement(
12737
+ return /* @__PURE__ */ React90.createElement(LabeledField, { label, labelPosition: "inset" }, /* @__PURE__ */ React90.createElement(InputField2.Root, { id, width: size2 }, /* @__PURE__ */ React90.createElement(
12738
12738
  InputField2.NumberInput,
12739
12739
  {
12740
12740
  value: value === void 0 ? value : round(value, 2),
@@ -12761,11 +12761,11 @@ __export(InspectorPrimitives_exports, {
12761
12761
  Title: () => Title4,
12762
12762
  VerticalSeparator: () => VerticalSeparator
12763
12763
  });
12764
- import React90, {
12764
+ import React91, {
12765
12765
  forwardRef as forwardRef28,
12766
12766
  memo as memo40
12767
12767
  } from "react";
12768
- var Section2 = forwardRef28(({ className, ...props }, ref) => /* @__PURE__ */ React90.createElement(
12768
+ var Section2 = forwardRef28(({ className, ...props }, ref) => /* @__PURE__ */ React91.createElement(
12769
12769
  "div",
12770
12770
  {
12771
12771
  ref,
@@ -12773,8 +12773,8 @@ var Section2 = forwardRef28(({ className, ...props }, ref) => /* @__PURE__ */ Re
12773
12773
  ...props
12774
12774
  }
12775
12775
  ));
12776
- var SectionHeader3 = forwardRef28(({ className, ...props }, ref) => /* @__PURE__ */ React90.createElement("div", { ref, className: cx(`flex items-center `, className), ...props }));
12777
- var Title4 = forwardRef28(({ className, $textStyle, ...props }, ref) => /* @__PURE__ */ React90.createElement(
12776
+ var SectionHeader3 = forwardRef28(({ className, ...props }, ref) => /* @__PURE__ */ React91.createElement("div", { ref, className: cx(`flex items-center `, className), ...props }));
12777
+ var Title4 = forwardRef28(({ className, $textStyle, ...props }, ref) => /* @__PURE__ */ React91.createElement(
12778
12778
  "div",
12779
12779
  {
12780
12780
  ref,
@@ -12785,7 +12785,7 @@ var Title4 = forwardRef28(({ className, $textStyle, ...props }, ref) => /* @__PU
12785
12785
  ...props
12786
12786
  }
12787
12787
  ));
12788
- var Row = forwardRef28(({ className, ...props }, ref) => /* @__PURE__ */ React90.createElement(
12788
+ var Row = forwardRef28(({ className, ...props }, ref) => /* @__PURE__ */ React91.createElement(
12789
12789
  "div",
12790
12790
  {
12791
12791
  ref,
@@ -12793,7 +12793,7 @@ var Row = forwardRef28(({ className, ...props }, ref) => /* @__PURE__ */ React90
12793
12793
  ...props
12794
12794
  }
12795
12795
  ));
12796
- var Column = forwardRef28(({ className, ...props }, ref) => /* @__PURE__ */ React90.createElement(
12796
+ var Column = forwardRef28(({ className, ...props }, ref) => /* @__PURE__ */ React91.createElement(
12797
12797
  "div",
12798
12798
  {
12799
12799
  ref,
@@ -12801,7 +12801,7 @@ var Column = forwardRef28(({ className, ...props }, ref) => /* @__PURE__ */ Reac
12801
12801
  ...props
12802
12802
  }
12803
12803
  ));
12804
- var Checkbox3 = forwardRef28(({ className, ...props }, ref) => /* @__PURE__ */ React90.createElement(
12804
+ var Checkbox3 = forwardRef28(({ className, ...props }, ref) => /* @__PURE__ */ React91.createElement(
12805
12805
  "input",
12806
12806
  {
12807
12807
  ref,
@@ -12810,7 +12810,7 @@ var Checkbox3 = forwardRef28(({ className, ...props }, ref) => /* @__PURE__ */ R
12810
12810
  ...props
12811
12811
  }
12812
12812
  ));
12813
- var Text3 = forwardRef28(({ className, ...props }, ref) => /* @__PURE__ */ React90.createElement(
12813
+ var Text3 = forwardRef28(({ className, ...props }, ref) => /* @__PURE__ */ React91.createElement(
12814
12814
  "span",
12815
12815
  {
12816
12816
  ref,
@@ -12818,14 +12818,14 @@ var Text3 = forwardRef28(({ className, ...props }, ref) => /* @__PURE__ */ React
12818
12818
  ...props
12819
12819
  }
12820
12820
  ));
12821
- var VerticalSeparator = () => /* @__PURE__ */ React90.createElement(Spacer.Vertical, { size: "inspector-v-separator" });
12822
- var HorizontalSeparator = () => /* @__PURE__ */ React90.createElement(Spacer.Horizontal, { size: "inspector-h-separator" });
12821
+ var VerticalSeparator = () => /* @__PURE__ */ React91.createElement(Spacer.Vertical, { size: "inspector-v-separator" });
12822
+ var HorizontalSeparator = () => /* @__PURE__ */ React91.createElement(Spacer.Horizontal, { size: "inspector-h-separator" });
12823
12823
  var RowLabel = forwardRef28(function RowLabel2({
12824
12824
  className,
12825
12825
  $textStyle,
12826
12826
  ...props
12827
12827
  }, ref) {
12828
- return /* @__PURE__ */ React90.createElement(
12828
+ return /* @__PURE__ */ React91.createElement(
12829
12829
  "label",
12830
12830
  {
12831
12831
  ref,
@@ -12845,11 +12845,11 @@ var LabeledRow = memo40(function LabeledRow2({
12845
12845
  right,
12846
12846
  className
12847
12847
  }) {
12848
- return /* @__PURE__ */ React90.createElement(Row, { id, className }, /* @__PURE__ */ React90.createElement(Column, null, /* @__PURE__ */ React90.createElement(RowLabel, { $textStyle: labelTextStyle }, label, right && /* @__PURE__ */ React90.createElement(Spacer.Horizontal, null), right), /* @__PURE__ */ React90.createElement(Row, null, children)));
12848
+ return /* @__PURE__ */ React91.createElement(Row, { id, className }, /* @__PURE__ */ React91.createElement(Column, null, /* @__PURE__ */ React91.createElement(RowLabel, { $textStyle: labelTextStyle }, label, right && /* @__PURE__ */ React91.createElement(Spacer.Horizontal, null), right), /* @__PURE__ */ React91.createElement(Row, null, children)));
12849
12849
  });
12850
12850
 
12851
12851
  // src/components/BaseToolbar.tsx
12852
- import React91 from "react";
12852
+ import React92 from "react";
12853
12853
  var toolbarStyle = {
12854
12854
  [cssVarNames.colors.inputBackground]: "transparent"
12855
12855
  };
@@ -12860,7 +12860,7 @@ function BaseToolbar({
12860
12860
  logo,
12861
12861
  showDivider = true
12862
12862
  }) {
12863
- return /* @__PURE__ */ React91.createElement("div", { className: "flex flex-col", style: toolbarStyle }, /* @__PURE__ */ React91.createElement(
12863
+ return /* @__PURE__ */ React92.createElement("div", { className: "flex flex-col", style: toolbarStyle }, /* @__PURE__ */ React92.createElement(
12864
12864
  "div",
12865
12865
  {
12866
12866
  className: "flex items-center pr-2.5 bg-sidebar-background flex-none relative @container/toolbar",
@@ -12868,10 +12868,10 @@ function BaseToolbar({
12868
12868
  flex: `0 0 ${cssVars.spacing.toolbarHeight}`
12869
12869
  }
12870
12870
  },
12871
- logo && /* @__PURE__ */ React91.createElement(React91.Fragment, null, logo, /* @__PURE__ */ React91.createElement(DividerVertical, null)),
12872
- /* @__PURE__ */ React91.createElement(Spacer.Horizontal, { size: 10 }),
12873
- left && /* @__PURE__ */ React91.createElement(React91.Fragment, null, /* @__PURE__ */ React91.createElement("div", { className: "flex gap-toolbar-separator" }, left), /* @__PURE__ */ React91.createElement(Spacer.Horizontal, { size: 10 })),
12874
- /* @__PURE__ */ React91.createElement("div", { className: "flex items-center justify-center text-text-muted pointer-events-none @2xl/toolbar:absolute inset-0" }, /* @__PURE__ */ React91.createElement(
12871
+ logo && /* @__PURE__ */ React92.createElement(React92.Fragment, null, logo, /* @__PURE__ */ React92.createElement(DividerVertical, null)),
12872
+ /* @__PURE__ */ React92.createElement(Spacer.Horizontal, { size: 10 }),
12873
+ left && /* @__PURE__ */ React92.createElement(React92.Fragment, null, /* @__PURE__ */ React92.createElement("div", { className: "flex gap-toolbar-separator" }, left), /* @__PURE__ */ React92.createElement(Spacer.Horizontal, { size: 10 })),
12874
+ /* @__PURE__ */ React92.createElement("div", { className: "flex items-center justify-center text-text-muted pointer-events-none @2xl/toolbar:absolute inset-0" }, /* @__PURE__ */ React92.createElement(
12875
12875
  "div",
12876
12876
  {
12877
12877
  style: {
@@ -12883,15 +12883,15 @@ function BaseToolbar({
12883
12883
  },
12884
12884
  children
12885
12885
  )),
12886
- /* @__PURE__ */ React91.createElement(Spacer.Horizontal, null),
12887
- /* @__PURE__ */ React91.createElement(Spacer.Horizontal, { size: 10 }),
12888
- /* @__PURE__ */ React91.createElement("div", { className: "flex gap-toolbar-separator" }, right)
12889
- ), showDivider && /* @__PURE__ */ React91.createElement(Divider, { variant: "strong" }));
12886
+ /* @__PURE__ */ React92.createElement(Spacer.Horizontal, null),
12887
+ /* @__PURE__ */ React92.createElement(Spacer.Horizontal, { size: 10 }),
12888
+ /* @__PURE__ */ React92.createElement("div", { className: "flex gap-toolbar-separator" }, right)
12889
+ ), showDivider && /* @__PURE__ */ React92.createElement(Divider, { variant: "strong" }));
12890
12890
  }
12891
12891
 
12892
12892
  // src/components/Toolbar.tsx
12893
12893
  import { useKeyboardShortcuts as useKeyboardShortcuts4 } from "@noya-app/noya-keymap";
12894
- import React92 from "react";
12894
+ import React93 from "react";
12895
12895
  var iconButtonStyle = {
12896
12896
  height: 27,
12897
12897
  width: 27,
@@ -12901,8 +12901,8 @@ var ToolbarMenuDropdown = memoGeneric(function ToolbarMenuDropdown2({
12901
12901
  item,
12902
12902
  onSelectMenuItem
12903
12903
  }) {
12904
- const [open, setOpen] = React92.useState(false);
12905
- return /* @__PURE__ */ React92.createElement(
12904
+ const [open, setOpen] = React93.useState(false);
12905
+ return /* @__PURE__ */ React93.createElement(
12906
12906
  DropdownMenu,
12907
12907
  {
12908
12908
  open,
@@ -12914,7 +12914,7 @@ var ToolbarMenuDropdown = memoGeneric(function ToolbarMenuDropdown2({
12914
12914
  }
12915
12915
  }
12916
12916
  },
12917
- /* @__PURE__ */ React92.createElement(
12917
+ /* @__PURE__ */ React93.createElement(
12918
12918
  Button,
12919
12919
  {
12920
12920
  disabled: item.disabled,
@@ -12931,7 +12931,7 @@ var ToolbarMenuButton = memoGeneric(function ToolbarMenuButton2({
12931
12931
  onSelectMenuItem,
12932
12932
  as
12933
12933
  }) {
12934
- const content = /* @__PURE__ */ React92.createElement(
12934
+ const content = /* @__PURE__ */ React93.createElement(
12935
12935
  Button,
12936
12936
  {
12937
12937
  as,
@@ -12948,7 +12948,7 @@ var ToolbarMenuButton = memoGeneric(function ToolbarMenuButton2({
12948
12948
  },
12949
12949
  item.title
12950
12950
  );
12951
- return item.tooltip ? /* @__PURE__ */ React92.createElement(Tooltip, { sideOffset: 10, content: item.tooltip }, content) : content;
12951
+ return item.tooltip ? /* @__PURE__ */ React93.createElement(Tooltip, { sideOffset: 10, content: item.tooltip }, content) : content;
12952
12952
  });
12953
12953
  var ToolbarMenuItem = memoGeneric(function ToolbarMenuItem2({
12954
12954
  item,
@@ -12957,10 +12957,10 @@ var ToolbarMenuItem = memoGeneric(function ToolbarMenuItem2({
12957
12957
  }) {
12958
12958
  if (item.type === "sectionHeader") return null;
12959
12959
  if (item.type === "separator") {
12960
- return /* @__PURE__ */ React92.createElement(DividerVertical, { overflow: 4 });
12960
+ return /* @__PURE__ */ React93.createElement(DividerVertical, { overflow: 4 });
12961
12961
  }
12962
12962
  if (isSelectableMenuItem(item)) {
12963
- return /* @__PURE__ */ React92.createElement(
12963
+ return /* @__PURE__ */ React93.createElement(
12964
12964
  ToolbarMenuButton,
12965
12965
  {
12966
12966
  item,
@@ -12969,15 +12969,15 @@ var ToolbarMenuItem = memoGeneric(function ToolbarMenuItem2({
12969
12969
  }
12970
12970
  );
12971
12971
  }
12972
- return /* @__PURE__ */ React92.createElement(ToolbarMenuDropdown, { item, onSelectMenuItem });
12972
+ return /* @__PURE__ */ React93.createElement(ToolbarMenuDropdown, { item, onSelectMenuItem });
12973
12973
  });
12974
12974
  var ToolbarMenu = memoGeneric(function ToolbarMenu2({
12975
12975
  items,
12976
12976
  onSelectMenuItem,
12977
12977
  buttonAs
12978
12978
  }) {
12979
- return /* @__PURE__ */ React92.createElement(React92.Fragment, null, items.map((item, i) => {
12980
- return /* @__PURE__ */ React92.createElement(
12979
+ return /* @__PURE__ */ React93.createElement(React93.Fragment, null, items.map((item, i) => {
12980
+ return /* @__PURE__ */ React93.createElement(
12981
12981
  ToolbarMenuItem,
12982
12982
  {
12983
12983
  key: i,
@@ -12996,28 +12996,28 @@ function Toolbar({
12996
12996
  onSelectMenuItem,
12997
12997
  shouldBindKeyboardShortcuts = true
12998
12998
  }) {
12999
- const allMenuItems = React92.useMemo(
12999
+ const allMenuItems = React93.useMemo(
13000
13000
  () => [...leftMenuItems, ...rightMenuItems],
13001
13001
  [leftMenuItems, rightMenuItems]
13002
13002
  );
13003
13003
  useKeyboardShortcuts4(
13004
- React92.useMemo(
13004
+ React93.useMemo(
13005
13005
  () => onSelectMenuItem && shouldBindKeyboardShortcuts ? getKeyboardShortcutsForMenuItems(allMenuItems, onSelectMenuItem) : {},
13006
13006
  [allMenuItems, onSelectMenuItem, shouldBindKeyboardShortcuts]
13007
13007
  )
13008
13008
  );
13009
- return /* @__PURE__ */ React92.createElement(
13009
+ return /* @__PURE__ */ React93.createElement(
13010
13010
  BaseToolbar,
13011
13011
  {
13012
13012
  logo,
13013
- left: leftMenuItems.length > 0 && /* @__PURE__ */ React92.createElement("div", { className: "flex gap-2" }, /* @__PURE__ */ React92.createElement(
13013
+ left: leftMenuItems.length > 0 && /* @__PURE__ */ React93.createElement("div", { className: "flex gap-2" }, /* @__PURE__ */ React93.createElement(
13014
13014
  ToolbarMenu,
13015
13015
  {
13016
13016
  items: leftMenuItems,
13017
13017
  onSelectMenuItem
13018
13018
  }
13019
13019
  )),
13020
- right: rightMenuItems.length > 0 && /* @__PURE__ */ React92.createElement("div", { className: "flex gap-2" }, /* @__PURE__ */ React92.createElement(
13020
+ right: rightMenuItems.length > 0 && /* @__PURE__ */ React93.createElement("div", { className: "flex gap-2" }, /* @__PURE__ */ React93.createElement(
13021
13021
  ToolbarMenu,
13022
13022
  {
13023
13023
  items: rightMenuItems,