@noya-app/noya-designsystem 0.1.23 → 0.1.25

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
@@ -397,12 +397,12 @@ var Button = forwardRef3(function Button2({
397
397
 
398
398
  // src/components/Chip.tsx
399
399
  import { Cross1Icon, PlusIcon } from "@noya-app/noya-icons";
400
- import React22, { forwardRef as forwardRef10, memo as memo11 } from "react";
400
+ import React23, { forwardRef as forwardRef10, memo as memo11 } from "react";
401
401
  import styled14 from "styled-components";
402
402
 
403
403
  // src/contexts/DesignSystemConfiguration.tsx
404
404
  import { getCurrentPlatform } from "@noya-app/noya-keymap";
405
- import React20, {
405
+ import React21, {
406
406
  createContext as createContext5,
407
407
  memo as memo10,
408
408
  useContext as useContext5,
@@ -414,17 +414,29 @@ import { ThemeProvider, useTheme as useTheme2 } from "styled-components";
414
414
 
415
415
  // src/components/Toast.tsx
416
416
  import * as ToastPrimitive from "@radix-ui/react-toast";
417
- import React7 from "react";
417
+ import React8 from "react";
418
418
  import styled6 from "styled-components";
419
419
 
420
420
  // src/components/IconButton.tsx
421
- import * as Icons from "@noya-app/noya-icons";
422
- import React6, {
421
+ import React7, {
423
422
  forwardRef as forwardRef4,
424
423
  memo as memo4,
425
424
  useMemo
426
425
  } from "react";
427
426
  import { useTheme } from "styled-components";
427
+
428
+ // src/components/Icons.tsx
429
+ import * as Icons from "@noya-app/noya-icons";
430
+ import React6 from "react";
431
+ function renderIcon(iconName) {
432
+ if (typeof iconName === "string") {
433
+ const Icon = Icons[iconName];
434
+ return /* @__PURE__ */ React6.createElement(Icon, null);
435
+ }
436
+ return iconName;
437
+ }
438
+
439
+ // src/components/IconButton.tsx
428
440
  var IconButton = memo4(
429
441
  forwardRef4(function IconButton2({ selected, iconName, color, size: size2, contentStyle, ...props }, forwardedRef) {
430
442
  const { icon: iconColor, iconSelected: iconSelectedColor } = useTheme().colors;
@@ -436,7 +448,7 @@ var IconButton = memo4(
436
448
  ...contentStyle
437
449
  };
438
450
  }, [contentStyle, size2]);
439
- return /* @__PURE__ */ React6.createElement(Button, { ref: forwardedRef, ...props, variant: "none", contentStyle: style3 }, /* @__PURE__ */ React6.createElement(
451
+ return /* @__PURE__ */ React7.createElement(Button, { ref: forwardedRef, ...props, variant: "none", contentStyle: style3 }, /* @__PURE__ */ React7.createElement(
440
452
  Icon,
441
453
  {
442
454
  color: color ?? (selected ? iconSelectedColor : iconColor),
@@ -496,9 +508,9 @@ var Toast = ({
496
508
  children,
497
509
  ...props
498
510
  }) => {
499
- return /* @__PURE__ */ React7.createElement(ToastRoot, { ...props }, title && /* @__PURE__ */ React7.createElement(ToastTitle, null, title), /* @__PURE__ */ React7.createElement(ToastDescription, null, content), children && /* @__PURE__ */ React7.createElement(ToastAction, { asChild: true, altText: "" }, children), /* @__PURE__ */ React7.createElement(ToastPrimitive.Close, { "aria-label": "Close", asChild: true }, /* @__PURE__ */ React7.createElement(IconButton, { iconName: "Cross1Icon" })));
511
+ return /* @__PURE__ */ React8.createElement(ToastRoot, { ...props }, title && /* @__PURE__ */ React8.createElement(ToastTitle, null, title), /* @__PURE__ */ React8.createElement(ToastDescription, null, content), children && /* @__PURE__ */ React8.createElement(ToastAction, { asChild: true, altText: "" }, children), /* @__PURE__ */ React8.createElement(ToastPrimitive.Close, { "aria-label": "Close", asChild: true }, /* @__PURE__ */ React8.createElement(IconButton, { iconName: "Cross1Icon" })));
500
512
  };
501
- var ToastProvider = ({ children }) => /* @__PURE__ */ React7.createElement(ToastPrimitive.Provider, null, children, /* @__PURE__ */ React7.createElement(ToastViewport, null));
513
+ var ToastProvider = ({ children }) => /* @__PURE__ */ React8.createElement(ToastPrimitive.Provider, null, children, /* @__PURE__ */ React8.createElement(ToastViewport, null));
502
514
 
503
515
  // src/theme/dark.ts
504
516
  var dark_exports = {};
@@ -781,7 +793,7 @@ var colors2 = produce(colors, (colors3) => {
781
793
  });
782
794
 
783
795
  // src/contexts/DialogContext.tsx
784
- import React18, {
796
+ import React19, {
785
797
  createContext as createContext3,
786
798
  useCallback as useCallback12,
787
799
  useContext as useContext3,
@@ -793,7 +805,7 @@ import styled13 from "styled-components";
793
805
 
794
806
  // src/components/Dialog.tsx
795
807
  import * as DialogPrimitive from "@radix-ui/react-dialog";
796
- import React9, {
808
+ import React10, {
797
809
  forwardRef as forwardRef6,
798
810
  useImperativeHandle,
799
811
  useRef
@@ -801,7 +813,7 @@ import React9, {
801
813
  import styled8 from "styled-components";
802
814
 
803
815
  // src/components/Spacer.tsx
804
- import React8, { forwardRef as forwardRef5 } from "react";
816
+ import React9, { forwardRef as forwardRef5 } from "react";
805
817
  import styled7 from "styled-components";
806
818
  var SpacerVertical_ = styled7.span(({ $size, $inline }) => ({
807
819
  display: $inline ? "inline-block" : "block",
@@ -809,7 +821,7 @@ var SpacerVertical_ = styled7.span(({ $size, $inline }) => ({
809
821
  }));
810
822
  var SpacerVertical = forwardRef5(
811
823
  ({ size: size2, inline, ...props }, ref) => {
812
- return /* @__PURE__ */ React8.createElement(SpacerVertical_, { $size: size2, $inline: inline, ...props, ref });
824
+ return /* @__PURE__ */ React9.createElement(SpacerVertical_, { $size: size2, $inline: inline, ...props, ref });
813
825
  }
814
826
  );
815
827
  var SpacerHorizontal_ = styled7.span(({ $size, $inline }) => ({
@@ -818,7 +830,7 @@ var SpacerHorizontal_ = styled7.span(({ $size, $inline }) => ({
818
830
  }));
819
831
  var SpacerHorizontal = forwardRef5(
820
832
  ({ size: size2, inline, ...props }, ref) => {
821
- return /* @__PURE__ */ React8.createElement(SpacerHorizontal_, { $size: size2, $inline: inline, ...props, ref });
833
+ return /* @__PURE__ */ React9.createElement(SpacerHorizontal_, { $size: size2, $inline: inline, ...props, ref });
822
834
  }
823
835
  );
824
836
  var Spacer;
@@ -891,7 +903,7 @@ var Dialog = forwardRef6(function Dialog2({
891
903
  return contentRef.current.contains(element);
892
904
  }
893
905
  }));
894
- return /* @__PURE__ */ React9.createElement(DialogPrimitive.Root, { open, onOpenChange }, /* @__PURE__ */ React9.createElement(StyledOverlay, null), /* @__PURE__ */ React9.createElement(
906
+ return /* @__PURE__ */ React10.createElement(DialogPrimitive.Root, { open, onOpenChange }, /* @__PURE__ */ React10.createElement(StyledOverlay, null), /* @__PURE__ */ React10.createElement(
895
907
  StyledContent,
896
908
  {
897
909
  ref: contentRef,
@@ -906,14 +918,14 @@ var Dialog = forwardRef6(function Dialog2({
906
918
  }
907
919
  }
908
920
  },
909
- /* @__PURE__ */ React9.createElement(CloseButtonContainer, null, /* @__PURE__ */ React9.createElement(DialogPrimitive.Close, { asChild: true }, /* @__PURE__ */ React9.createElement(IconButton, { iconName: "Cross1Icon" }))),
910
- title && /* @__PURE__ */ React9.createElement(React9.Fragment, null, /* @__PURE__ */ React9.createElement(StyledTitle, null, title), /* @__PURE__ */ React9.createElement(Spacer.Vertical, { size: description ? 10 : 20 })),
911
- description && /* @__PURE__ */ React9.createElement(React9.Fragment, null, /* @__PURE__ */ React9.createElement(Spacer.Vertical, { size: 10 }), /* @__PURE__ */ React9.createElement(StyledDescription, null, description), /* @__PURE__ */ React9.createElement(Spacer.Vertical, { size: 20 })),
921
+ /* @__PURE__ */ React10.createElement(CloseButtonContainer, null, /* @__PURE__ */ React10.createElement(DialogPrimitive.Close, { asChild: true }, /* @__PURE__ */ React10.createElement(IconButton, { iconName: "Cross1Icon" }))),
922
+ title && /* @__PURE__ */ React10.createElement(React10.Fragment, null, /* @__PURE__ */ React10.createElement(StyledTitle, null, title), /* @__PURE__ */ React10.createElement(Spacer.Vertical, { size: description ? 10 : 20 })),
923
+ description && /* @__PURE__ */ React10.createElement(React10.Fragment, null, /* @__PURE__ */ React10.createElement(Spacer.Vertical, { size: 10 }), /* @__PURE__ */ React10.createElement(StyledDescription, null, description), /* @__PURE__ */ React10.createElement(Spacer.Vertical, { size: 20 })),
912
924
  children
913
925
  ));
914
926
  });
915
927
  var FullscreenDialog = forwardRef6(function FullscreenDialog2({ style: style3, ...rest }, forwardedRef) {
916
- return /* @__PURE__ */ React9.createElement(
928
+ return /* @__PURE__ */ React10.createElement(
917
929
  Dialog,
918
930
  {
919
931
  ref: forwardedRef,
@@ -939,13 +951,13 @@ var FullscreenDialog = forwardRef6(function FullscreenDialog2({ style: style3, .
939
951
  import { CaretDownIcon } from "@noya-app/noya-icons";
940
952
 
941
953
  // ../noya-react-utils/src/components/AutoSizer.tsx
942
- import React11, { memo as memo5, useRef as useRef2 } from "react";
954
+ import React12, { memo as memo5, useRef as useRef2 } from "react";
943
955
 
944
956
  // ../noya-react-utils/src/hooks/useSize.ts
945
- import * as React10 from "react";
957
+ import * as React11 from "react";
946
958
  function useSize(refToObserve, dimensions = "both") {
947
- const [size2, setSize] = React10.useState(void 0);
948
- React10.useEffect(() => {
959
+ const [size2, setSize] = React11.useState(void 0);
960
+ React11.useEffect(() => {
949
961
  if (refToObserve.current) {
950
962
  const elementToObserve = refToObserve.current;
951
963
  const resizeObserver = new ResizeObserver((entries) => {
@@ -998,7 +1010,7 @@ var AutoSizer = memo5(function AutoSizer2({
998
1010
  }) {
999
1011
  const containerRef = useRef2(null);
1000
1012
  const containerSize = useSize(containerRef);
1001
- return /* @__PURE__ */ React11.createElement("div", { ref: containerRef, style, className }, containerSize && containerSize.width > 0 && containerSize.height > 0 && children(containerSize));
1013
+ return /* @__PURE__ */ React12.createElement("div", { ref: containerRef, style, className }, containerSize && containerSize.width > 0 && containerSize.height > 0 && children(containerSize));
1002
1014
  });
1003
1015
  var SingleDimensionAutoSizer = memo5(function SingleDimensionAutoSizer2({
1004
1016
  children,
@@ -1007,11 +1019,11 @@ var SingleDimensionAutoSizer = memo5(function SingleDimensionAutoSizer2({
1007
1019
  }) {
1008
1020
  const containerRef = useRef2(null);
1009
1021
  const containerSize = useSize(containerRef, dimension);
1010
- return /* @__PURE__ */ React11.createElement("div", { ref: containerRef, style, className }, containerSize && containerSize[dimension] > 0 && children(containerSize[dimension]));
1022
+ return /* @__PURE__ */ React12.createElement("div", { ref: containerRef, style, className }, containerSize && containerSize[dimension] > 0 && children(containerSize[dimension]));
1011
1023
  });
1012
1024
 
1013
1025
  // ../noya-react-utils/src/components/FileDropTarget.tsx
1014
- import React12, {
1026
+ import React13, {
1015
1027
  memo as memo6,
1016
1028
  useCallback as useCallback3
1017
1029
  } from "react";
@@ -1086,7 +1098,7 @@ var FileDropTarget = memo6(function FileDropTarget2({
1086
1098
  [onDropFiles, supportedFileTypes]
1087
1099
  );
1088
1100
  const { dropTargetProps, isDropTargetActive } = useFileDropTarget(handleFile);
1089
- return /* @__PURE__ */ React12.createElement("div", { style: style2, ...dropTargetProps }, typeof children === "function" ? children(isDropTargetActive) : children);
1101
+ return /* @__PURE__ */ React13.createElement("div", { style: style2, ...dropTargetProps }, typeof children === "function" ? children(isDropTargetActive) : children);
1090
1102
  });
1091
1103
 
1092
1104
  // ../noya-react-utils/src/hooks/useDeepArray.ts
@@ -1226,7 +1238,7 @@ function assignRef(ref, value) {
1226
1238
  }
1227
1239
 
1228
1240
  // src/components/InputField.tsx
1229
- import React17, {
1241
+ import React18, {
1230
1242
  Children as Children3,
1231
1243
  createContext as createContext2,
1232
1244
  forwardRef as forwardRef9,
@@ -1270,7 +1282,7 @@ function handleNudge(e) {
1270
1282
  import { CheckIcon, ChevronRightIcon } from "@noya-app/noya-icons";
1271
1283
  import { useKeyboardShortcuts } from "@noya-app/noya-keymap";
1272
1284
  import * as RadixDropdownMenu from "@radix-ui/react-dropdown-menu";
1273
- import React14, {
1285
+ import React15, {
1274
1286
  forwardRef as forwardRef7,
1275
1287
  memo as memo8,
1276
1288
  useCallback as useCallback9,
@@ -1280,7 +1292,7 @@ import styled10 from "styled-components";
1280
1292
 
1281
1293
  // src/components/internal/Menu.tsx
1282
1294
  import { getShortcutDisplayParts } from "@noya-app/noya-keymap";
1283
- import React13, { memo as memo7 } from "react";
1295
+ import React14, { memo as memo7 } from "react";
1284
1296
  import styled9 from "styled-components";
1285
1297
  var SEPARATOR_ITEM = "separator";
1286
1298
  var CHECKBOX_WIDTH = 15;
@@ -1372,7 +1384,7 @@ var KeyboardShortcut = memo7(function KeyboardShortcut2({
1372
1384
  }) {
1373
1385
  const platform = useDesignSystemConfiguration().platform;
1374
1386
  const { keys, separator } = getShortcutDisplayParts(shortcut, platform);
1375
- const keyElements = keys.map((key) => /* @__PURE__ */ React13.createElement(
1387
+ const keyElements = keys.map((key) => /* @__PURE__ */ React14.createElement(
1376
1388
  ShortcutElement,
1377
1389
  {
1378
1390
  key,
@@ -1380,9 +1392,9 @@ var KeyboardShortcut = memo7(function KeyboardShortcut2({
1380
1392
  },
1381
1393
  key
1382
1394
  ));
1383
- return /* @__PURE__ */ React13.createElement(React13.Fragment, null, separator ? withSeparatorElements(
1395
+ return /* @__PURE__ */ React14.createElement(React14.Fragment, null, separator ? withSeparatorElements(
1384
1396
  keyElements,
1385
- /* @__PURE__ */ React13.createElement(ShortcutElement, null, separator)
1397
+ /* @__PURE__ */ React14.createElement(ShortcutElement, null, separator)
1386
1398
  ) : keyElements);
1387
1399
  });
1388
1400
 
@@ -1414,21 +1426,21 @@ var DropdownMenuItem = memo8(function ContextMenuItem({
1414
1426
  onSelect(value);
1415
1427
  }, [onSelect, value]);
1416
1428
  if (checked) {
1417
- return /* @__PURE__ */ React14.createElement(
1429
+ return /* @__PURE__ */ React15.createElement(
1418
1430
  CheckboxItemElement,
1419
1431
  {
1420
1432
  checked,
1421
1433
  disabled,
1422
1434
  onSelect: handleSelectItem
1423
1435
  },
1424
- /* @__PURE__ */ React14.createElement(StyledItemIndicator, null, /* @__PURE__ */ React14.createElement(CheckIcon, null)),
1425
- icon && /* @__PURE__ */ React14.createElement(React14.Fragment, null, icon, /* @__PURE__ */ React14.createElement(Spacer.Horizontal, { size: 8 })),
1436
+ /* @__PURE__ */ React15.createElement(StyledItemIndicator, null, /* @__PURE__ */ React15.createElement(CheckIcon, null)),
1437
+ icon && /* @__PURE__ */ React15.createElement(React15.Fragment, null, renderIcon(icon), /* @__PURE__ */ React15.createElement(Spacer.Horizontal, { size: 8 })),
1426
1438
  children
1427
1439
  );
1428
1440
  }
1429
- const element = /* @__PURE__ */ React14.createElement(ItemElement, { disabled, onSelect: handleSelectItem }, indented && /* @__PURE__ */ React14.createElement(Spacer.Horizontal, { size: CHECKBOX_WIDTH - CHECKBOX_RIGHT_INSET }), icon && /* @__PURE__ */ React14.createElement(React14.Fragment, null, icon, /* @__PURE__ */ React14.createElement(Spacer.Horizontal, { size: 8 })), children, shortcut && /* @__PURE__ */ React14.createElement(React14.Fragment, null, /* @__PURE__ */ React14.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React14.createElement(Spacer.Horizontal, { size: 24 }), /* @__PURE__ */ React14.createElement(KeyboardShortcut, { shortcut })), items && items.length > 0 && /* @__PURE__ */ React14.createElement(React14.Fragment, null, /* @__PURE__ */ React14.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React14.createElement(Spacer.Horizontal, { size: 16 }), /* @__PURE__ */ React14.createElement(ChevronRightIcon, null)));
1441
+ const element = /* @__PURE__ */ React15.createElement(ItemElement, { disabled, onSelect: handleSelectItem }, indented && /* @__PURE__ */ React15.createElement(Spacer.Horizontal, { size: CHECKBOX_WIDTH - CHECKBOX_RIGHT_INSET }), icon && /* @__PURE__ */ React15.createElement(React15.Fragment, null, renderIcon(icon), /* @__PURE__ */ React15.createElement(Spacer.Horizontal, { size: 8 })), children, shortcut && /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React15.createElement(Spacer.Horizontal, { size: 24 }), /* @__PURE__ */ React15.createElement(KeyboardShortcut, { shortcut })), items && items.length > 0 && /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React15.createElement(Spacer.Horizontal, { size: 16 }), /* @__PURE__ */ React15.createElement(ChevronRightIcon, null)));
1430
1442
  if (items && items.length > 0) {
1431
- return /* @__PURE__ */ React14.createElement(
1443
+ return /* @__PURE__ */ React15.createElement(
1432
1444
  DropdownMenuRoot,
1433
1445
  {
1434
1446
  isNested: true,
@@ -1471,7 +1483,7 @@ var DropdownMenuRoot = forwardRef7(function DropdownMenuRoot2({
1471
1483
  const TriggerComponent = isNested ? RadixDropdownMenu.SubTrigger : RadixDropdownMenu.Trigger;
1472
1484
  const ContentComponent = isNested ? SubContent2 : Content5;
1473
1485
  const contentStyle = useMemo5(() => ({ zIndex: 1e3 }), []);
1474
- return /* @__PURE__ */ React14.createElement(RootComponent, { onOpenChange, open }, /* @__PURE__ */ React14.createElement(TriggerComponent, { ref: forwardedRef, asChild: true }, children), /* @__PURE__ */ React14.createElement(RadixDropdownMenu.Portal, null, /* @__PURE__ */ React14.createElement(
1486
+ return /* @__PURE__ */ React15.createElement(RootComponent, { onOpenChange, open }, /* @__PURE__ */ React15.createElement(TriggerComponent, { ref: forwardedRef, asChild: true }, children), /* @__PURE__ */ React15.createElement(RadixDropdownMenu.Portal, null, /* @__PURE__ */ React15.createElement(
1475
1487
  ContentComponent,
1476
1488
  {
1477
1489
  side,
@@ -1483,7 +1495,7 @@ var DropdownMenuRoot = forwardRef7(function DropdownMenuRoot2({
1483
1495
  ...{ onCloseAutoFocus }
1484
1496
  },
1485
1497
  items.map(
1486
- (item, index) => item === SEPARATOR_ITEM ? /* @__PURE__ */ React14.createElement(SeparatorElement, { key: index }) : /* @__PURE__ */ React14.createElement(
1498
+ (item, index) => item === SEPARATOR_ITEM ? /* @__PURE__ */ React15.createElement(SeparatorElement, { key: index }) : /* @__PURE__ */ React15.createElement(
1487
1499
  DropdownMenuItem,
1488
1500
  {
1489
1501
  key: item.value ?? index,
@@ -1505,7 +1517,7 @@ var DropdownMenu = memo8(DropdownMenuRoot);
1505
1517
 
1506
1518
  // src/components/internal/TextInput.tsx
1507
1519
  import { composeRefs } from "@radix-ui/react-compose-refs";
1508
- import React15, {
1520
+ import React16, {
1509
1521
  forwardRef as forwardRef8,
1510
1522
  useCallback as useCallback10,
1511
1523
  useEffect as useEffect9,
@@ -1556,7 +1568,7 @@ function useGlobalInputBlurTrigger() {
1556
1568
 
1557
1569
  // src/components/internal/TextInput.tsx
1558
1570
  var ReadOnlyTextInput = forwardRef8(function ReadOnlyTextInput2({ onKeyDown, onFocusChange, value, ...rest }, forwardedRef) {
1559
- return /* @__PURE__ */ React15.createElement(
1571
+ return /* @__PURE__ */ React16.createElement(
1560
1572
  "input",
1561
1573
  {
1562
1574
  ref: forwardedRef,
@@ -1590,7 +1602,7 @@ var ControlledTextInput = forwardRef8(function ControlledTextInput2({
1590
1602
  },
1591
1603
  [onFocusCapture, onFocusChange]
1592
1604
  );
1593
- return /* @__PURE__ */ React15.createElement(
1605
+ return /* @__PURE__ */ React16.createElement(
1594
1606
  "input",
1595
1607
  {
1596
1608
  ref: forwardedRef,
@@ -1617,7 +1629,7 @@ var SubmittableTextInput = forwardRef8(function SubmittableTextInput2({
1617
1629
  submitAutomaticallyAfterDelay,
1618
1630
  ...rest
1619
1631
  }, forwardedRef) {
1620
- const ref = React15.useRef(null);
1632
+ const ref = React16.useRef(null);
1621
1633
  const latestValue = useRef9(value);
1622
1634
  latestValue.current = value;
1623
1635
  const userDidEdit = useRef9(false);
@@ -1701,7 +1713,7 @@ var SubmittableTextInput = forwardRef8(function SubmittableTextInput2({
1701
1713
  }
1702
1714
  };
1703
1715
  }, [internalValue, submitAutomaticallyAfterDelay]);
1704
- return /* @__PURE__ */ React15.createElement(
1716
+ return /* @__PURE__ */ React16.createElement(
1705
1717
  "input",
1706
1718
  {
1707
1719
  ref: composeRefs(ref, forwardedRef),
@@ -1733,17 +1745,17 @@ var TextInput_default = forwardRef8(function TextInput(props, forwardedRef) {
1733
1745
  ...props
1734
1746
  };
1735
1747
  if ("readOnly" in commonProps) {
1736
- return /* @__PURE__ */ React15.createElement(ReadOnlyTextInput, { ref: forwardedRef, ...commonProps, readOnly: true });
1748
+ return /* @__PURE__ */ React16.createElement(ReadOnlyTextInput, { ref: forwardedRef, ...commonProps, readOnly: true });
1737
1749
  } else if ("onChange" in commonProps) {
1738
- return /* @__PURE__ */ React15.createElement(ControlledTextInput, { ref: forwardedRef, ...commonProps });
1750
+ return /* @__PURE__ */ React16.createElement(ControlledTextInput, { ref: forwardedRef, ...commonProps });
1739
1751
  } else {
1740
- return /* @__PURE__ */ React15.createElement(SubmittableTextInput, { ref: forwardedRef, ...commonProps });
1752
+ return /* @__PURE__ */ React16.createElement(SubmittableTextInput, { ref: forwardedRef, ...commonProps });
1741
1753
  }
1742
1754
  });
1743
1755
 
1744
1756
  // src/components/Popover.tsx
1745
1757
  import * as PopoverPrimitive from "@radix-ui/react-popover";
1746
- import React16 from "react";
1758
+ import React17 from "react";
1747
1759
  import styled11 from "styled-components";
1748
1760
  var ContentElement = styled11(PopoverPrimitive.Content)(({ theme, variant }) => ({
1749
1761
  borderRadius: 4,
@@ -1790,7 +1802,7 @@ function Popover({
1790
1802
  onFocusOutside,
1791
1803
  onClickClose
1792
1804
  }) {
1793
- return /* @__PURE__ */ React16.createElement(PopoverPrimitive.Root, { open, onOpenChange }, /* @__PURE__ */ React16.createElement(PopoverPrimitive.Trigger, { asChild: true }, trigger), /* @__PURE__ */ React16.createElement(PopoverPrimitive.Portal, null, /* @__PURE__ */ React16.createElement(
1805
+ return /* @__PURE__ */ React17.createElement(PopoverPrimitive.Root, { open, onOpenChange }, /* @__PURE__ */ React17.createElement(PopoverPrimitive.Trigger, { asChild: true }, trigger), /* @__PURE__ */ React17.createElement(PopoverPrimitive.Portal, null, /* @__PURE__ */ React17.createElement(
1794
1806
  ContentElement,
1795
1807
  {
1796
1808
  variant,
@@ -1806,8 +1818,8 @@ function Popover({
1806
1818
  arrowPadding: 2
1807
1819
  },
1808
1820
  children,
1809
- showArrow && /* @__PURE__ */ React16.createElement(ArrowElement, null),
1810
- closable && /* @__PURE__ */ React16.createElement(PopoverClose, null, /* @__PURE__ */ React16.createElement(IconButton, { iconName: "Cross2Icon", onClick: onClickClose }))
1821
+ showArrow && /* @__PURE__ */ React17.createElement(ArrowElement, null),
1822
+ closable && /* @__PURE__ */ React17.createElement(PopoverClose, null, /* @__PURE__ */ React17.createElement(IconButton, { iconName: "Cross2Icon", onClick: onClickClose }))
1811
1823
  )));
1812
1824
  }
1813
1825
 
@@ -1852,7 +1864,7 @@ var InputFieldLabel = memo9(
1852
1864
  return;
1853
1865
  setLabelWidth(width);
1854
1866
  }, [setLabelWidth]);
1855
- return /* @__PURE__ */ React17.createElement(
1867
+ return /* @__PURE__ */ React18.createElement(
1856
1868
  LabelContainer,
1857
1869
  {
1858
1870
  ref: (element) => {
@@ -1885,7 +1897,7 @@ var InputFieldDropdownMenu = memo9(function InputFieldDropdownMenu2({ id, items,
1885
1897
  }),
1886
1898
  [size2]
1887
1899
  );
1888
- return /* @__PURE__ */ React17.createElement(DropdownContainer, null, /* @__PURE__ */ React17.createElement(DropdownMenu, { items, onSelect }, children || /* @__PURE__ */ React17.createElement(Button, { id, variant: "thin", flex: "1", contentStyle }, /* @__PURE__ */ React17.createElement(CaretDownIcon, null))));
1900
+ return /* @__PURE__ */ React18.createElement(DropdownContainer, null, /* @__PURE__ */ React18.createElement(DropdownMenu, { items, onSelect }, children || /* @__PURE__ */ React18.createElement(Button, { id, variant: "thin", flex: "1", contentStyle }, /* @__PURE__ */ React18.createElement(CaretDownIcon, null))));
1889
1901
  });
1890
1902
  var ButtonContainer = styled12.span(
1891
1903
  ({ theme, $size }) => ({
@@ -1914,7 +1926,7 @@ var InputFieldButton = memo9(function InputFieldButton2({
1914
1926
  event.preventDefault();
1915
1927
  event.stopPropagation();
1916
1928
  }, []);
1917
- return /* @__PURE__ */ React17.createElement(ButtonContainer, { $size: size2 }, /* @__PURE__ */ React17.createElement(
1929
+ return /* @__PURE__ */ React18.createElement(ButtonContainer, { $size: size2 }, /* @__PURE__ */ React18.createElement(
1918
1930
  Button,
1919
1931
  {
1920
1932
  variant: "floating",
@@ -2008,7 +2020,7 @@ var InputFieldInput = forwardRef9(function InputFieldInput2({
2008
2020
  useLayoutEffect4(() => {
2009
2021
  setInputRef?.(forwardedRef);
2010
2022
  }, [forwardedRef, setInputRef]);
2011
- return /* @__PURE__ */ React17.createElement(
2023
+ return /* @__PURE__ */ React18.createElement(
2012
2024
  InputElement,
2013
2025
  {
2014
2026
  ref: forwardedRef,
@@ -2033,7 +2045,7 @@ var InputFieldTypeahead = (props) => {
2033
2045
  size: size2,
2034
2046
  onFocusChange
2035
2047
  } = useContext2(InputFieldContext);
2036
- return /* @__PURE__ */ React17.createElement(
2048
+ return /* @__PURE__ */ React18.createElement(
2037
2049
  InputElement,
2038
2050
  {
2039
2051
  $labelPosition: labelPosition,
@@ -2114,7 +2126,7 @@ function InputFieldNumberInput(props) {
2114
2126
  },
2115
2127
  [onBlur]
2116
2128
  );
2117
- return /* @__PURE__ */ React17.createElement(
2129
+ return /* @__PURE__ */ React18.createElement(
2118
2130
  InputFieldInput,
2119
2131
  {
2120
2132
  ...rest,
@@ -2155,9 +2167,9 @@ function InputFieldRoot({
2155
2167
  const hasLabel = childrenArray.some(
2156
2168
  (child) => isValidElement2(child) && child.type === InputFieldLabel
2157
2169
  );
2158
- const [isFocused, setIsFocused] = React17.useState(false);
2159
- const [measuredLabelSize, setMeasuredLabelSize] = React17.useState();
2160
- const [measuredWidth, setMeasuredWidth] = React17.useState();
2170
+ const [isFocused, setIsFocused] = React18.useState(false);
2171
+ const [measuredLabelSize, setMeasuredLabelSize] = React18.useState();
2172
+ const [measuredWidth, setMeasuredWidth] = React18.useState();
2161
2173
  const handleFocusChange = useCallback11(
2162
2174
  (isFocused2) => {
2163
2175
  setIsFocused(isFocused2);
@@ -2165,7 +2177,7 @@ function InputFieldRoot({
2165
2177
  },
2166
2178
  [onFocusChange]
2167
2179
  );
2168
- const [inputRef, setInputRef] = React17.useState();
2180
+ const [inputRef, setInputRef] = React18.useState();
2169
2181
  useEffect10(() => {
2170
2182
  if (inputRef && typeof inputRef !== "function") {
2171
2183
  setMeasuredWidth?.(
@@ -2198,7 +2210,7 @@ function InputFieldRoot({
2198
2210
  inputRef
2199
2211
  ]
2200
2212
  );
2201
- const rootElement = /* @__PURE__ */ React17.createElement(
2213
+ const rootElement = /* @__PURE__ */ React18.createElement(
2202
2214
  RootContainer,
2203
2215
  {
2204
2216
  id,
@@ -2209,7 +2221,7 @@ function InputFieldRoot({
2209
2221
  },
2210
2222
  children
2211
2223
  );
2212
- return /* @__PURE__ */ React17.createElement(InputFieldContext.Provider, { value: contextValue }, renderPopoverContent ? /* @__PURE__ */ React17.createElement(
2224
+ return /* @__PURE__ */ React18.createElement(InputFieldContext.Provider, { value: contextValue }, renderPopoverContent ? /* @__PURE__ */ React18.createElement(
2213
2225
  Popover,
2214
2226
  {
2215
2227
  open: true,
@@ -2225,9 +2237,38 @@ function InputFieldRoot({
2225
2237
  event.stopPropagation();
2226
2238
  }
2227
2239
  },
2228
- measuredWidth && /* @__PURE__ */ React17.createElement(Stack.V, { width: measuredWidth, overflow: "hidden" }, renderPopoverContent({ width: measuredWidth }))
2240
+ measuredWidth && /* @__PURE__ */ React18.createElement(Stack.V, { width: measuredWidth, overflow: "hidden" }, renderPopoverContent({ width: measuredWidth }))
2229
2241
  ) : rootElement);
2230
2242
  }
2243
+ var PrimitiveInputField = styled12.input(({ theme, readOnly, disabled }) => {
2244
+ return {
2245
+ // placeholder
2246
+ "&::placeholder": {
2247
+ color: theme.colors.textDisabled
2248
+ },
2249
+ ...theme.textStyles.small,
2250
+ color: readOnly ? theme.colors.textMuted : disabled ? theme.colors.textDisabled : theme.colors.text,
2251
+ width: "0px",
2252
+ // Reset intrinsic width
2253
+ flex: "1 1 0px",
2254
+ position: "relative",
2255
+ border: "0",
2256
+ outline: "none",
2257
+ minWidth: "0",
2258
+ alignSelf: "stretch",
2259
+ borderRadius: "4px",
2260
+ paddingTop: "4px",
2261
+ paddingBottom: "4px",
2262
+ paddingLeft: "6px",
2263
+ paddingRight: "6px",
2264
+ background: theme.colors.inputBackground,
2265
+ "&:focus": {
2266
+ boxShadow: `0 0 0 2px ${theme.colors.primary}`
2267
+ },
2268
+ userSelect: "all",
2269
+ pointerEvents: "all"
2270
+ };
2271
+ });
2231
2272
  var InputField;
2232
2273
  ((InputField2) => {
2233
2274
  InputField2.Root = memo9(InputFieldRoot);
@@ -2237,6 +2278,7 @@ var InputField;
2237
2278
  InputField2.DropdownMenu = InputFieldDropdownMenu;
2238
2279
  InputField2.Button = InputFieldButton;
2239
2280
  InputField2.Label = InputFieldLabel;
2281
+ InputField2.PrimitiveElement = PrimitiveInputField;
2240
2282
  })(InputField || (InputField = {}));
2241
2283
 
2242
2284
  // src/contexts/DialogContext.tsx
@@ -2306,7 +2348,7 @@ var DialogProvider = function DialogProvider2({
2306
2348
  return false;
2307
2349
  return dialogRef.current.containsElement(element);
2308
2350
  }, []);
2309
- return /* @__PURE__ */ React18.createElement(React18.Fragment, null, /* @__PURE__ */ React18.createElement(
2351
+ return /* @__PURE__ */ React19.createElement(React19.Fragment, null, /* @__PURE__ */ React19.createElement(
2310
2352
  DialogContext.Provider,
2311
2353
  {
2312
2354
  value: useMemo7(
@@ -2315,7 +2357,7 @@ var DialogProvider = function DialogProvider2({
2315
2357
  )
2316
2358
  },
2317
2359
  children
2318
- ), /* @__PURE__ */ React18.createElement(
2360
+ ), /* @__PURE__ */ React19.createElement(
2319
2361
  Dialog,
2320
2362
  {
2321
2363
  ref: dialogRef,
@@ -2336,7 +2378,7 @@ var DialogProvider = function DialogProvider2({
2336
2378
  inputRef.current?.setSelectionRange(0, inputRef.current.value.length);
2337
2379
  }, [])
2338
2380
  },
2339
- /* @__PURE__ */ React18.createElement(InputField.Root, null, /* @__PURE__ */ React18.createElement(
2381
+ /* @__PURE__ */ React19.createElement(InputField.Root, null, /* @__PURE__ */ React19.createElement(
2340
2382
  InputField.Input,
2341
2383
  {
2342
2384
  ref: inputRef,
@@ -2352,8 +2394,8 @@ var DialogProvider = function DialogProvider2({
2352
2394
  onKeyDown: handleKeyDown
2353
2395
  }
2354
2396
  )),
2355
- /* @__PURE__ */ React18.createElement(Spacer.Vertical, { size: 20 }),
2356
- /* @__PURE__ */ React18.createElement(Row, null, /* @__PURE__ */ React18.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React18.createElement(Button, { onClick: close }, "Cancel"), /* @__PURE__ */ React18.createElement(Spacer.Horizontal, { size: 16 }), /* @__PURE__ */ React18.createElement(Button, { disabled: !contents?.inputValue, onClick: submit }, "Submit"))
2397
+ /* @__PURE__ */ React19.createElement(Spacer.Vertical, { size: 20 }),
2398
+ /* @__PURE__ */ React19.createElement(Row, null, /* @__PURE__ */ React19.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React19.createElement(Button, { onClick: close }, "Cancel"), /* @__PURE__ */ React19.createElement(Spacer.Horizontal, { size: 16 }), /* @__PURE__ */ React19.createElement(Button, { disabled: !contents?.inputValue, onClick: submit }, "Submit"))
2357
2399
  ));
2358
2400
  };
2359
2401
  function useDialog() {
@@ -2372,7 +2414,7 @@ function useDialogContainsElement() {
2372
2414
 
2373
2415
  // src/contexts/FloatingWindowContext.tsx
2374
2416
  import { uuid } from "@noya-app/noya-utils";
2375
- import React19, { createContext as createContext4, useContext as useContext4, useMemo as useMemo8, useState as useState13 } from "react";
2417
+ import React20, { createContext as createContext4, useContext as useContext4, useMemo as useMemo8, useState as useState13 } from "react";
2376
2418
  import { createPortal } from "react-dom";
2377
2419
  var FloatingWindowContext = createContext4(void 0);
2378
2420
  var CurrentWindowContext = createContext4(void 0);
@@ -2385,7 +2427,7 @@ var FloatingWindowProvider = ({
2385
2427
  const id = uuid();
2386
2428
  setWindows((windows2) => ({
2387
2429
  ...windows2,
2388
- [id]: /* @__PURE__ */ React19.createElement(CurrentWindowContext.Provider, { value: { id } }, element)
2430
+ [id]: /* @__PURE__ */ React20.createElement(CurrentWindowContext.Provider, { value: { id } }, element)
2389
2431
  }));
2390
2432
  return id;
2391
2433
  };
@@ -2397,7 +2439,7 @@ var FloatingWindowProvider = ({
2397
2439
  };
2398
2440
  return { createWindow, closeWindow };
2399
2441
  }, []);
2400
- return /* @__PURE__ */ React19.createElement(FloatingWindowContext.Provider, { value: contextValue }, children, Object.entries(windows).map(
2442
+ return /* @__PURE__ */ React20.createElement(FloatingWindowContext.Provider, { value: contextValue }, children, Object.entries(windows).map(
2401
2443
  ([id, element]) => createPortal(element, document.body, id)
2402
2444
  ));
2403
2445
  };
@@ -2430,11 +2472,11 @@ var DesignSystemThemeProvider = memo10(
2430
2472
  } catch (e) {
2431
2473
  }
2432
2474
  if (theme) {
2433
- return /* @__PURE__ */ React20.createElement(ThemeProvider, { theme }, children);
2475
+ return /* @__PURE__ */ React21.createElement(ThemeProvider, { theme }, children);
2434
2476
  } else if (parentTheme) {
2435
2477
  return children;
2436
2478
  } else {
2437
- return /* @__PURE__ */ React20.createElement(ThemeProvider, { theme: light_exports }, children);
2479
+ return /* @__PURE__ */ React21.createElement(ThemeProvider, { theme: light_exports }, children);
2438
2480
  }
2439
2481
  }
2440
2482
  );
@@ -2462,7 +2504,7 @@ var DesignSystemConfigurationProvider = memo10(
2462
2504
  [platform, internalPlatform]
2463
2505
  );
2464
2506
  const resolvedTheme = theme === "light" ? light_exports : theme === "dark" ? dark_exports : theme ?? light_exports;
2465
- return /* @__PURE__ */ React20.createElement(DesignSystemConfigurationContext.Provider, { value: contextValue }, /* @__PURE__ */ React20.createElement(ThemeProvider, { theme: resolvedTheme }, /* @__PURE__ */ React20.createElement(DialogProvider, null, /* @__PURE__ */ React20.createElement(ToastProvider, null, /* @__PURE__ */ React20.createElement(FloatingWindowProvider, null, children)))));
2507
+ return /* @__PURE__ */ React21.createElement(DesignSystemConfigurationContext.Provider, { value: contextValue }, /* @__PURE__ */ React21.createElement(ThemeProvider, { theme: resolvedTheme }, /* @__PURE__ */ React21.createElement(DialogProvider, null, /* @__PURE__ */ React21.createElement(ToastProvider, null, /* @__PURE__ */ React21.createElement(FloatingWindowProvider, null, children)))));
2466
2508
  }
2467
2509
  );
2468
2510
  function useDesignSystemConfiguration() {
@@ -2473,7 +2515,7 @@ function useDesignSystemTheme() {
2473
2515
  }
2474
2516
 
2475
2517
  // src/hooks/useHover.ts
2476
- import * as React21 from "react";
2518
+ import * as React22 from "react";
2477
2519
  var globalIgnoreEmulatedMouseEvents = false;
2478
2520
  var hoverCount = 0;
2479
2521
  function setGlobalIgnoreEmulatedMouseEvents() {
@@ -2503,13 +2545,13 @@ function setupGlobalTouchEvents() {
2503
2545
  }
2504
2546
  function useHover(props = {}) {
2505
2547
  const { onHoverStart, onHoverChange, onHoverEnd, isDisabled } = props;
2506
- const [isHovered, setHovered] = React21.useState(false);
2507
- const state = React21.useRef({
2548
+ const [isHovered, setHovered] = React22.useState(false);
2549
+ const state = React22.useRef({
2508
2550
  isHovered: false,
2509
2551
  ignoreEmulatedMouseEvents: false
2510
2552
  }).current;
2511
- React21.useEffect(setupGlobalTouchEvents, []);
2512
- const hoverProps = React21.useMemo(
2553
+ React22.useEffect(setupGlobalTouchEvents, []);
2554
+ const hoverProps = React22.useMemo(
2513
2555
  function getHoverProps() {
2514
2556
  function triggerHoverStart(event, pointerType) {
2515
2557
  if (isDisabled || pointerType === "touch" || state.isHovered) {
@@ -2582,9 +2624,12 @@ var ChipElement = styled14.span(({ theme, $colorScheme, $size, $variant, $monosp
2582
2624
  // lineHeight: "1.4",
2583
2625
  lineHeight: "15px",
2584
2626
  whiteSpace: "pre",
2585
- ...$size === "medium" ? {
2627
+ ...$size === "large" ? {
2586
2628
  fontSize: "11px",
2587
2629
  padding: "4px 8px"
2630
+ } : $size === "medium" ? {
2631
+ fontSize: "10px",
2632
+ padding: "2px 6px"
2588
2633
  } : {
2589
2634
  fontSize: "9px",
2590
2635
  padding: "0px 4px"
@@ -2619,7 +2664,7 @@ var DeleteElement = styled14(Cross1Icon)(({ size: size2 }) => ({
2619
2664
  marginRight: "-2px",
2620
2665
  cursor: "pointer",
2621
2666
  opacity: 0.5,
2622
- ...size2 === "medium" ? {
2667
+ ...size2 === "large" ? {
2623
2668
  marginLeft: "2px",
2624
2669
  // top: '-1px',
2625
2670
  transform: "scale(0.75)"
@@ -2638,7 +2683,7 @@ var AddElement = styled14(PlusIcon).withConfig({
2638
2683
  marginLeft: "-2px",
2639
2684
  cursor: "pointer",
2640
2685
  opacity: 0.5,
2641
- ...size2 === "medium" ? {
2686
+ ...size2 === "large" ? {
2642
2687
  marginRight: "2px",
2643
2688
  top: "-1px",
2644
2689
  transform: "scale(0.75)"
@@ -2658,7 +2703,7 @@ var Chip = memo11(
2658
2703
  addable,
2659
2704
  clickable,
2660
2705
  style: style3,
2661
- size: size2 = "medium",
2706
+ size: size2 = "large",
2662
2707
  variant = "solid",
2663
2708
  monospace = false,
2664
2709
  tabIndex,
@@ -2674,7 +2719,7 @@ var Chip = memo11(
2674
2719
  });
2675
2720
  const handleClick = !children && !deletable && addable ? onAdd : onClick;
2676
2721
  const color = colorScheme === "primary" ? theme.colors.primary : colorScheme === "secondary" ? theme.colors.secondary : theme.colors.text;
2677
- return /* @__PURE__ */ React22.createElement(
2722
+ return /* @__PURE__ */ React23.createElement(
2678
2723
  ChipElement,
2679
2724
  {
2680
2725
  ref: forwardedRef,
@@ -2688,7 +2733,7 @@ var Chip = memo11(
2688
2733
  tabIndex,
2689
2734
  ...rest
2690
2735
  },
2691
- addable && /* @__PURE__ */ React22.createElement(
2736
+ addable && /* @__PURE__ */ React23.createElement(
2692
2737
  AddElement,
2693
2738
  {
2694
2739
  size: size2,
@@ -2701,7 +2746,7 @@ var Chip = memo11(
2701
2746
  }
2702
2747
  ),
2703
2748
  children,
2704
- deletable && /* @__PURE__ */ React22.createElement(
2749
+ deletable && /* @__PURE__ */ React23.createElement(
2705
2750
  DeleteElement,
2706
2751
  {
2707
2752
  size: size2,
@@ -2721,7 +2766,7 @@ var Chip = memo11(
2721
2766
  import { CheckIcon as CheckIcon2, ChevronRightIcon as ChevronRightIcon2 } from "@noya-app/noya-icons";
2722
2767
  import { useKeyboardShortcuts as useKeyboardShortcuts2 } from "@noya-app/noya-keymap";
2723
2768
  import * as RadixContextMenu from "@radix-ui/react-context-menu";
2724
- import React23, { memo as memo12, useCallback as useCallback13, useMemo as useMemo11 } from "react";
2769
+ import React24, { memo as memo12, useCallback as useCallback13, useMemo as useMemo11 } from "react";
2725
2770
  import styled15 from "styled-components";
2726
2771
  var SeparatorElement2 = styled15(RadixContextMenu.Separator)(
2727
2772
  styles.separatorStyle
@@ -2754,32 +2799,32 @@ var ContextMenuItem2 = memo12(function ContextMenuItem3({
2754
2799
  onSelect(value);
2755
2800
  }, [onSelect, value]);
2756
2801
  if (checked) {
2757
- return /* @__PURE__ */ React23.createElement(
2802
+ return /* @__PURE__ */ React24.createElement(
2758
2803
  CheckboxItemElement2,
2759
2804
  {
2760
2805
  checked,
2761
2806
  disabled,
2762
2807
  onSelect: handleSelectItem
2763
2808
  },
2764
- /* @__PURE__ */ React23.createElement(StyledItemIndicator2, null, /* @__PURE__ */ React23.createElement(CheckIcon2, null)),
2809
+ /* @__PURE__ */ React24.createElement(StyledItemIndicator2, null, /* @__PURE__ */ React24.createElement(CheckIcon2, null)),
2765
2810
  children
2766
2811
  );
2767
2812
  }
2768
- const element = /* @__PURE__ */ React23.createElement(
2813
+ const element = /* @__PURE__ */ React24.createElement(
2769
2814
  ItemElement2,
2770
2815
  {
2771
2816
  disabled,
2772
2817
  onSelect: handleSelectItem,
2773
2818
  onPointerDown: handlePointerDown
2774
2819
  },
2775
- indented && /* @__PURE__ */ React23.createElement(Spacer.Horizontal, { size: CHECKBOX_WIDTH - CHECKBOX_RIGHT_INSET }),
2776
- icon && /* @__PURE__ */ React23.createElement(React23.Fragment, null, icon, /* @__PURE__ */ React23.createElement(Spacer.Horizontal, { size: 8 })),
2820
+ indented && /* @__PURE__ */ React24.createElement(Spacer.Horizontal, { size: CHECKBOX_WIDTH - CHECKBOX_RIGHT_INSET }),
2821
+ icon && /* @__PURE__ */ React24.createElement(React24.Fragment, null, renderIcon(icon), /* @__PURE__ */ React24.createElement(Spacer.Horizontal, { size: 8 })),
2777
2822
  children,
2778
- shortcut && /* @__PURE__ */ React23.createElement(React23.Fragment, null, /* @__PURE__ */ React23.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React23.createElement(Spacer.Horizontal, { size: 24 }), /* @__PURE__ */ React23.createElement(KeyboardShortcut, { shortcut })),
2779
- items && items.length > 0 && /* @__PURE__ */ React23.createElement(React23.Fragment, null, /* @__PURE__ */ React23.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React23.createElement(Spacer.Horizontal, { size: 16 }), /* @__PURE__ */ React23.createElement(ChevronRightIcon2, null))
2823
+ 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 })),
2824
+ items && items.length > 0 && /* @__PURE__ */ React24.createElement(React24.Fragment, null, /* @__PURE__ */ React24.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React24.createElement(Spacer.Horizontal, { size: 16 }), /* @__PURE__ */ React24.createElement(ChevronRightIcon2, null))
2780
2825
  );
2781
2826
  if (items && items.length > 0) {
2782
- return /* @__PURE__ */ React23.createElement(ContextMenuRoot, { isNested: true, items, onSelect }, element);
2827
+ return /* @__PURE__ */ React24.createElement(ContextMenuRoot, { isNested: true, items, onSelect }, element);
2783
2828
  } else {
2784
2829
  return element;
2785
2830
  }
@@ -2808,8 +2853,8 @@ function ContextMenuRoot({
2808
2853
  const RootComponent = isNested ? RadixContextMenu.Sub : RadixContextMenu.Root;
2809
2854
  const TriggerComponent = isNested ? RadixContextMenu.SubTrigger : RadixContextMenu.Trigger;
2810
2855
  const ContentComponent = isNested ? SubContent4 : Content8;
2811
- return /* @__PURE__ */ React23.createElement(RootComponent, { onOpenChange }, /* @__PURE__ */ React23.createElement(TriggerComponent, { asChild: true, onPointerDown }, children), /* @__PURE__ */ React23.createElement(RadixContextMenu.Portal, null, /* @__PURE__ */ React23.createElement(ContentComponent, null, items.map(
2812
- (item, index) => item === SEPARATOR_ITEM ? /* @__PURE__ */ React23.createElement(SeparatorElement2, { key: index }) : /* @__PURE__ */ React23.createElement(
2856
+ return /* @__PURE__ */ React24.createElement(RootComponent, { onOpenChange }, /* @__PURE__ */ React24.createElement(TriggerComponent, { asChild: true, onPointerDown }, children), /* @__PURE__ */ React24.createElement(RadixContextMenu.Portal, null, /* @__PURE__ */ React24.createElement(ContentComponent, null, items.map(
2857
+ (item, index) => item === SEPARATOR_ITEM ? /* @__PURE__ */ React24.createElement(SeparatorElement2, { key: index }) : /* @__PURE__ */ React24.createElement(
2813
2858
  ContextMenuItem2,
2814
2859
  {
2815
2860
  key: item.value ?? index,
@@ -2829,7 +2874,7 @@ function ContextMenuRoot({
2829
2874
  var ContextMenu = memo12(ContextMenuRoot);
2830
2875
 
2831
2876
  // src/components/Divider.tsx
2832
- import React24, { memo as memo13 } from "react";
2877
+ import React25, { memo as memo13 } from "react";
2833
2878
  import styled16 from "styled-components";
2834
2879
  var DividerContainer = styled16.div(({ theme, $variant = "normal", $orientation, $overflow = 0 }) => ({
2835
2880
  ...$orientation === "horizontal" ? { height: "1px", minHeight: "1px", margin: `0px -${$overflow}px` } : { width: "1px", minWidth: "1px", margin: `-${$overflow}px 0px` },
@@ -2841,7 +2886,7 @@ var Divider = memo13(function Divider2({
2841
2886
  overflow,
2842
2887
  ...props
2843
2888
  }) {
2844
- return /* @__PURE__ */ React24.createElement(
2889
+ return /* @__PURE__ */ React25.createElement(
2845
2890
  DividerContainer,
2846
2891
  {
2847
2892
  $orientation: "horizontal",
@@ -2856,7 +2901,7 @@ var DividerVertical = memo13(function DividerVertical2({
2856
2901
  overflow,
2857
2902
  ...props
2858
2903
  }) {
2859
- return /* @__PURE__ */ React24.createElement(
2904
+ return /* @__PURE__ */ React25.createElement(
2860
2905
  DividerContainer,
2861
2906
  {
2862
2907
  $orientation: "vertical",
@@ -2869,7 +2914,7 @@ var DividerVertical = memo13(function DividerVertical2({
2869
2914
 
2870
2915
  // src/components/DraggableMenuButton.tsx
2871
2916
  import { DragHandleDots2Icon } from "@noya-app/noya-icons";
2872
- import React25, { memo as memo14, useCallback as useCallback14, useState as useState16 } from "react";
2917
+ import React26, { memo as memo14, useCallback as useCallback14, useState as useState16 } from "react";
2873
2918
  import styled17 from "styled-components";
2874
2919
  var DotButtonElement = styled17.div(({ theme }) => ({
2875
2920
  cursor: "pointer",
@@ -2896,7 +2941,7 @@ var DraggableMenuButton = memo14(function DraggableMenuButton2({
2896
2941
  }) {
2897
2942
  const color = useDesignSystemTheme().colors.icon;
2898
2943
  const [open, setOpen] = useState16(false);
2899
- const [downPosition, setDownPosition] = React25.useState(null);
2944
+ const [downPosition, setDownPosition] = React26.useState(null);
2900
2945
  const handlePointerDownCapture = useCallback14(
2901
2946
  (event) => {
2902
2947
  if (open) {
@@ -2933,7 +2978,7 @@ var DraggableMenuButton = memo14(function DraggableMenuButton2({
2933
2978
  },
2934
2979
  [setOpen]
2935
2980
  );
2936
- return /* @__PURE__ */ React25.createElement(
2981
+ return /* @__PURE__ */ React26.createElement(
2937
2982
  DotButtonElement,
2938
2983
  {
2939
2984
  onPointerDownCapture: handlePointerDownCapture,
@@ -2943,7 +2988,7 @@ var DraggableMenuButton = memo14(function DraggableMenuButton2({
2943
2988
  event.preventDefault();
2944
2989
  }
2945
2990
  },
2946
- items && onSelect ? /* @__PURE__ */ React25.createElement(
2991
+ items && onSelect ? /* @__PURE__ */ React26.createElement(
2947
2992
  DropdownMenu,
2948
2993
  {
2949
2994
  open,
@@ -2952,13 +2997,13 @@ var DraggableMenuButton = memo14(function DraggableMenuButton2({
2952
2997
  onSelect,
2953
2998
  shouldBindKeyboardShortcuts: false
2954
2999
  },
2955
- /* @__PURE__ */ React25.createElement(TriggerElement, null, /* @__PURE__ */ React25.createElement(
3000
+ /* @__PURE__ */ React26.createElement(TriggerElement, null, /* @__PURE__ */ React26.createElement(
2956
3001
  DragHandleDots2Icon,
2957
3002
  {
2958
3003
  color: isVisible || open ? color : "transparent"
2959
3004
  }
2960
3005
  ))
2961
- ) : /* @__PURE__ */ React25.createElement(
3006
+ ) : /* @__PURE__ */ React26.createElement(
2962
3007
  DragHandleDots2Icon,
2963
3008
  {
2964
3009
  color: isVisible || open ? color : "transparent"
@@ -2968,7 +3013,7 @@ var DraggableMenuButton = memo14(function DraggableMenuButton2({
2968
3013
  });
2969
3014
 
2970
3015
  // src/components/FillInputField.tsx
2971
- import React28, { forwardRef as forwardRef11, memo as memo17 } from "react";
3016
+ import React29, { forwardRef as forwardRef11, memo as memo17 } from "react";
2972
3017
  import styled19 from "styled-components";
2973
3018
 
2974
3019
  // ../noya-file-format/src/types.ts
@@ -3294,11 +3339,11 @@ var ClassValue = /* @__PURE__ */ ((ClassValue2) => {
3294
3339
  })(ClassValue || {});
3295
3340
 
3296
3341
  // src/components/FillPreviewBackground.tsx
3297
- import React27, { memo as memo16, useMemo as useMemo14 } from "react";
3342
+ import React28, { memo as memo16, useMemo as useMemo14 } from "react";
3298
3343
  import styled18, { useTheme as useTheme3 } from "styled-components";
3299
3344
 
3300
3345
  // src/contexts/ImageDataContext.tsx
3301
- import React26, {
3346
+ import React27, {
3302
3347
  createContext as createContext6,
3303
3348
  memo as memo15,
3304
3349
  useContext as useContext6,
@@ -3315,7 +3360,7 @@ var ImageDataProvider = memo15(function ImageDataProvider2({
3315
3360
  () => ({ getImageData: getImageData ?? (() => void 0) }),
3316
3361
  [getImageData]
3317
3362
  );
3318
- return /* @__PURE__ */ React26.createElement(ImageDataContext.Provider, { value: contextValue }, children);
3363
+ return /* @__PURE__ */ React27.createElement(ImageDataContext.Provider, { value: contextValue }, children);
3319
3364
  });
3320
3365
  function useImageData(ref) {
3321
3366
  const value = useContext6(ImageDataContext);
@@ -3405,7 +3450,7 @@ var HorizontalDotsBackground = memo16(function HorizontalDotsBackground2() {
3405
3450
  ].join(","),
3406
3451
  [inputBackground, placeholderDots]
3407
3452
  );
3408
- return /* @__PURE__ */ React27.createElement(Background, { background });
3453
+ return /* @__PURE__ */ React28.createElement(Background, { background });
3409
3454
  });
3410
3455
  function getPatternSizeAndPosition(fillType, tileScale) {
3411
3456
  switch (fillType) {
@@ -3435,13 +3480,13 @@ var PatternPreviewBackground = memo16(function PatternPreviewBackground2({
3435
3480
  ].join(" "),
3436
3481
  [fillType, size2, url]
3437
3482
  );
3438
- return /* @__PURE__ */ React27.createElement(Background, { background });
3483
+ return /* @__PURE__ */ React28.createElement(Background, { background });
3439
3484
  });
3440
3485
  var ColorPreviewBackground = memo16(function ColorPreviewBackground2({
3441
3486
  color
3442
3487
  }) {
3443
3488
  const background = useMemo14(() => sketchColorToRgbaString(color), [color]);
3444
- return /* @__PURE__ */ React27.createElement(Background, { background });
3489
+ return /* @__PURE__ */ React28.createElement(Background, { background });
3445
3490
  });
3446
3491
  var GradientPreviewBackground = memo16(function GradientPreviewBackground2({
3447
3492
  gradient
@@ -3450,22 +3495,22 @@ var GradientPreviewBackground = memo16(function GradientPreviewBackground2({
3450
3495
  () => getGradientBackground(gradient.stops, gradient.gradientType, 180),
3451
3496
  [gradient.gradientType, gradient.stops]
3452
3497
  );
3453
- return /* @__PURE__ */ React27.createElement(Background, { background });
3498
+ return /* @__PURE__ */ React28.createElement(Background, { background });
3454
3499
  });
3455
3500
  var FillPreviewBackground = memo16(function FillPreviewBackground2({
3456
3501
  value
3457
3502
  }) {
3458
3503
  if (!value)
3459
- return /* @__PURE__ */ React27.createElement(HorizontalDotsBackground, null);
3504
+ return /* @__PURE__ */ React28.createElement(HorizontalDotsBackground, null);
3460
3505
  switch (value._class) {
3461
3506
  case "color":
3462
- return /* @__PURE__ */ React27.createElement(ColorPreviewBackground, { color: value });
3507
+ return /* @__PURE__ */ React28.createElement(ColorPreviewBackground, { color: value });
3463
3508
  case "gradient":
3464
- return /* @__PURE__ */ React27.createElement(GradientPreviewBackground, { gradient: value });
3509
+ return /* @__PURE__ */ React28.createElement(GradientPreviewBackground, { gradient: value });
3465
3510
  case "pattern":
3466
3511
  if (!value.image)
3467
3512
  return null;
3468
- return /* @__PURE__ */ React27.createElement(
3513
+ return /* @__PURE__ */ React28.createElement(
3469
3514
  PatternPreviewBackground,
3470
3515
  {
3471
3516
  fillType: value.patternFillType,
@@ -3497,12 +3542,12 @@ var Container = styled19.button(
3497
3542
  );
3498
3543
  var FillInputField = memo17(
3499
3544
  forwardRef11(function FillInputField2({ id, value, flex, ...rest }, ref) {
3500
- return /* @__PURE__ */ React28.createElement(Container, { ref, id, $flex: flex, ...rest }, /* @__PURE__ */ React28.createElement(FillPreviewBackground, { value }));
3545
+ return /* @__PURE__ */ React29.createElement(Container, { ref, id, $flex: flex, ...rest }, /* @__PURE__ */ React29.createElement(FillPreviewBackground, { value }));
3501
3546
  })
3502
3547
  );
3503
3548
 
3504
3549
  // src/components/FloatingWindow.tsx
3505
- import React29, { useCallback as useCallback15, useRef as useRef13, useState as useState17 } from "react";
3550
+ import React30, { useCallback as useCallback15, useRef as useRef13, useState as useState17 } from "react";
3506
3551
  var styles2 = {
3507
3552
  noSelect: {
3508
3553
  userSelect: "none",
@@ -3595,7 +3640,7 @@ function defaultRenderToolbar({
3595
3640
  toolbarContent,
3596
3641
  onClose
3597
3642
  }) {
3598
- return /* @__PURE__ */ React29.createElement(React29.Fragment, null, /* @__PURE__ */ React29.createElement(Small, { flex: "1", fontWeight: "500", color: "text" }, title), toolbarContent, /* @__PURE__ */ React29.createElement(
3643
+ return /* @__PURE__ */ React30.createElement(React30.Fragment, null, /* @__PURE__ */ React30.createElement(Small, { flex: "1", fontWeight: "500", color: "text" }, title), toolbarContent, /* @__PURE__ */ React30.createElement(
3599
3644
  IconButton,
3600
3645
  {
3601
3646
  iconName: "Cross3Icon",
@@ -3716,7 +3761,7 @@ var FloatingWindow = ({
3716
3761
  setResizeDirection(null);
3717
3762
  toggleGlobalTextSelection(false);
3718
3763
  }, []);
3719
- React29.useEffect(() => {
3764
+ React30.useEffect(() => {
3720
3765
  document.addEventListener("mousemove", handleMouseMove);
3721
3766
  document.addEventListener("mouseup", handleMouseUp);
3722
3767
  return () => {
@@ -3732,7 +3777,7 @@ var FloatingWindow = ({
3732
3777
  onClose();
3733
3778
  floatingWindowManager.closeWindow(currentFloatingWindow.id);
3734
3779
  }, [currentFloatingWindow.id, floatingWindowManager, onClose]);
3735
- return /* @__PURE__ */ React29.createElement(
3780
+ return /* @__PURE__ */ React30.createElement(
3736
3781
  "div",
3737
3782
  {
3738
3783
  ref: wrapperRef,
@@ -3746,7 +3791,7 @@ var FloatingWindow = ({
3746
3791
  backgroundColor: theme.colors.canvas.background
3747
3792
  }
3748
3793
  },
3749
- /* @__PURE__ */ React29.createElement(
3794
+ /* @__PURE__ */ React30.createElement(
3750
3795
  "div",
3751
3796
  {
3752
3797
  style: {
@@ -3757,9 +3802,9 @@ var FloatingWindow = ({
3757
3802
  },
3758
3803
  renderToolbar({ title, toolbarContent, onClose: handleClose })
3759
3804
  ),
3760
- /* @__PURE__ */ React29.createElement(Divider, null),
3761
- /* @__PURE__ */ React29.createElement("div", { style: styles2.content }, children),
3762
- Object.entries(resizeHandlePositions).map(([direction, style3]) => /* @__PURE__ */ React29.createElement(
3805
+ /* @__PURE__ */ React30.createElement(Divider, null),
3806
+ /* @__PURE__ */ React30.createElement("div", { style: styles2.content }, children),
3807
+ Object.entries(resizeHandlePositions).map(([direction, style3]) => /* @__PURE__ */ React30.createElement(
3763
3808
  "div",
3764
3809
  {
3765
3810
  key: direction,
@@ -3781,7 +3826,7 @@ import {
3781
3826
  hsvaToRgba,
3782
3827
  rgbaToHsva as rgbaToHsva2
3783
3828
  } from "@noya-app/noya-colorpicker";
3784
- import React30, { memo as memo18, useCallback as useCallback16, useMemo as useMemo15 } from "react";
3829
+ import React31, { memo as memo18, useCallback as useCallback16, useMemo as useMemo15 } from "react";
3785
3830
  var GradientPicker = memo18(function GradientPicker2({
3786
3831
  value,
3787
3832
  selectedStop,
@@ -3816,14 +3861,14 @@ var GradientPicker = memo18(function GradientPicker2({
3816
3861
  },
3817
3862
  [onAdd]
3818
3863
  );
3819
- return /* @__PURE__ */ React30.createElement(
3864
+ return /* @__PURE__ */ React31.createElement(
3820
3865
  NoyaColorPicker,
3821
3866
  {
3822
3867
  onChange: handleChangeColor,
3823
3868
  colorModel,
3824
3869
  color: rgbaColor
3825
3870
  },
3826
- /* @__PURE__ */ React30.createElement(
3871
+ /* @__PURE__ */ React31.createElement(
3827
3872
  Gradient,
3828
3873
  {
3829
3874
  gradients: value,
@@ -3834,12 +3879,12 @@ var GradientPicker = memo18(function GradientPicker2({
3834
3879
  onDelete
3835
3880
  }
3836
3881
  ),
3837
- /* @__PURE__ */ React30.createElement(Spacer.Vertical, { size: 10 }),
3838
- /* @__PURE__ */ React30.createElement(Saturation, null),
3839
- /* @__PURE__ */ React30.createElement(Spacer.Vertical, { size: 12 }),
3840
- /* @__PURE__ */ React30.createElement(Hue, null),
3841
- /* @__PURE__ */ React30.createElement(Spacer.Vertical, { size: 5 }),
3842
- /* @__PURE__ */ React30.createElement(Alpha, null)
3882
+ /* @__PURE__ */ React31.createElement(Spacer.Vertical, { size: 10 }),
3883
+ /* @__PURE__ */ React31.createElement(Saturation, null),
3884
+ /* @__PURE__ */ React31.createElement(Spacer.Vertical, { size: 12 }),
3885
+ /* @__PURE__ */ React31.createElement(Hue, null),
3886
+ /* @__PURE__ */ React31.createElement(Spacer.Vertical, { size: 5 }),
3887
+ /* @__PURE__ */ React31.createElement(Alpha, null)
3843
3888
  );
3844
3889
  });
3845
3890
 
@@ -3871,7 +3916,7 @@ var Grid = styled20.div((props) => ({
3871
3916
  }));
3872
3917
 
3873
3918
  // src/components/GridView.tsx
3874
- import React32, {
3919
+ import React33, {
3875
3920
  createContext as createContext7,
3876
3921
  forwardRef as forwardRef12,
3877
3922
  memo as memo20,
@@ -3883,7 +3928,7 @@ import styled22, { keyframes as keyframes2 } from "styled-components";
3883
3928
 
3884
3929
  // src/components/ScrollArea.tsx
3885
3930
  import * as RadixScrollArea from "@radix-ui/react-scroll-area";
3886
- import React31, { memo as memo19, useCallback as useCallback17, useState as useState18 } from "react";
3931
+ import React32, { memo as memo19, useCallback as useCallback17, useState as useState18 } from "react";
3887
3932
  import styled21 from "styled-components";
3888
3933
  var SCROLLBAR_SIZE = 10;
3889
3934
  var StyledViewport = styled21(RadixScrollArea.Viewport)({
@@ -3913,7 +3958,7 @@ var Container2 = styled21.div({
3913
3958
  });
3914
3959
  var ScrollArea = memo19(function ScrollArea2({ children }) {
3915
3960
  const [scrollElementRef, setScrollElementRef] = useState18(null);
3916
- return /* @__PURE__ */ React31.createElement(Container2, null, /* @__PURE__ */ React31.createElement(RadixScrollArea.Root, { style: { width: "100%", height: "100%" } }, /* @__PURE__ */ React31.createElement(
3961
+ return /* @__PURE__ */ React32.createElement(Container2, null, /* @__PURE__ */ React32.createElement(RadixScrollArea.Root, { style: { width: "100%", height: "100%" } }, /* @__PURE__ */ React32.createElement(
3917
3962
  StyledViewport,
3918
3963
  {
3919
3964
  ref: useCallback17(
@@ -3922,7 +3967,7 @@ var ScrollArea = memo19(function ScrollArea2({ children }) {
3922
3967
  )
3923
3968
  },
3924
3969
  typeof children === "function" ? scrollElementRef ? children(scrollElementRef) : null : children
3925
- ), /* @__PURE__ */ React31.createElement(StyledScrollbar, { orientation: "vertical", className: "scroll-component" }, /* @__PURE__ */ React31.createElement(StyledThumb, { className: "scroll-component" }))));
3970
+ ), /* @__PURE__ */ React32.createElement(StyledScrollbar, { orientation: "vertical", className: "scroll-component" }, /* @__PURE__ */ React32.createElement(StyledThumb, { className: "scroll-component" }))));
3926
3971
  });
3927
3972
 
3928
3973
  // src/components/GridView.tsx
@@ -4118,7 +4163,7 @@ var GridViewItem = forwardRef12(function GridViewItem2({
4118
4163
  onContextMenu,
4119
4164
  style: style3
4120
4165
  }, forwardedRef) {
4121
- const [hovered, setHovered] = React32.useState(false);
4166
+ const [hovered, setHovered] = React33.useState(false);
4122
4167
  const { hoverProps } = useHover({
4123
4168
  onHoverChange: (isHovering) => {
4124
4169
  onHoverChange?.(isHovering);
@@ -4147,7 +4192,7 @@ var GridViewItem = forwardRef12(function GridViewItem2({
4147
4192
  },
4148
4193
  [onPress]
4149
4194
  );
4150
- let element = /* @__PURE__ */ React32.createElement(
4195
+ let element = /* @__PURE__ */ React33.createElement(
4151
4196
  ItemContainer,
4152
4197
  {
4153
4198
  id,
@@ -4156,7 +4201,7 @@ var GridViewItem = forwardRef12(function GridViewItem2({
4156
4201
  tabIndex: disabled ? void 0 : 0,
4157
4202
  onKeyDown: handleKeyDown
4158
4203
  },
4159
- /* @__PURE__ */ React32.createElement(
4204
+ /* @__PURE__ */ React33.createElement(
4160
4205
  ContentContainer,
4161
4206
  {
4162
4207
  disabled,
@@ -4170,18 +4215,18 @@ var GridViewItem = forwardRef12(function GridViewItem2({
4170
4215
  },
4171
4216
  children
4172
4217
  ),
4173
- textPosition === "below" && /* @__PURE__ */ React32.createElement(React32.Fragment, null, /* @__PURE__ */ React32.createElement(Spacer.Vertical, { size: 8 }), /* @__PURE__ */ React32.createElement(ItemTitle, { showBackground: false }, title || " "), /* @__PURE__ */ React32.createElement(ItemDescription, { showBackground: false }, subtitle || " ")),
4174
- textPosition === "overlay" && hovered && (title || subtitle) && /* @__PURE__ */ React32.createElement(TextOverlay, null, title && /* @__PURE__ */ React32.createElement(ItemTitle, { showBackground: true }, title), subtitle && /* @__PURE__ */ React32.createElement(ItemDescription, { showBackground: true }, subtitle)),
4175
- loading && /* @__PURE__ */ React32.createElement(Shimmer, null, /* @__PURE__ */ React32.createElement(ActivityIndicator, { opacity: 0.5, size: 13 }))
4218
+ textPosition === "below" && /* @__PURE__ */ React33.createElement(React33.Fragment, null, /* @__PURE__ */ React33.createElement(Spacer.Vertical, { size: 8 }), /* @__PURE__ */ React33.createElement(ItemTitle, { showBackground: false }, title || " "), /* @__PURE__ */ React33.createElement(ItemDescription, { showBackground: false }, subtitle || " ")),
4219
+ textPosition === "overlay" && hovered && (title || subtitle) && /* @__PURE__ */ React33.createElement(TextOverlay, null, title && /* @__PURE__ */ React33.createElement(ItemTitle, { showBackground: true }, title), subtitle && /* @__PURE__ */ React33.createElement(ItemDescription, { showBackground: true }, subtitle)),
4220
+ loading && /* @__PURE__ */ React33.createElement(Shimmer, null, /* @__PURE__ */ React33.createElement(ActivityIndicator, { opacity: 0.5, size: 13 }))
4176
4221
  );
4177
4222
  if (menuItems && onSelectMenuItem) {
4178
- element = /* @__PURE__ */ React32.createElement(ContextMenu, { items: menuItems, onSelect: onSelectMenuItem }, element);
4223
+ element = /* @__PURE__ */ React33.createElement(ContextMenu, { items: menuItems, onSelect: onSelectMenuItem }, element);
4179
4224
  }
4180
4225
  if (textPosition === "toolip") {
4181
- element = /* @__PURE__ */ React32.createElement(
4226
+ element = /* @__PURE__ */ React33.createElement(
4182
4227
  Tooltip,
4183
4228
  {
4184
- content: /* @__PURE__ */ React32.createElement(Stack.V, { gap: 2 }, /* @__PURE__ */ React32.createElement(ItemTitle, { showBackground: false }, title), /* @__PURE__ */ React32.createElement(ItemDescription, { showBackground: false }, subtitle))
4229
+ content: /* @__PURE__ */ React33.createElement(Stack.V, { gap: 2 }, /* @__PURE__ */ React33.createElement(ItemTitle, { showBackground: false }, title), /* @__PURE__ */ React33.createElement(ItemDescription, { showBackground: false }, subtitle))
4185
4230
  },
4186
4231
  element
4187
4232
  );
@@ -4220,20 +4265,20 @@ function GridViewRoot({
4220
4265
  }),
4221
4266
  [bordered, disabled, size2, textPosition]
4222
4267
  );
4223
- return /* @__PURE__ */ React32.createElement(GridViewContext.Provider, { value: contextValue }, /* @__PURE__ */ React32.createElement(Container3, { onClick: handleClick, scrollable }, scrollable ? /* @__PURE__ */ React32.createElement(ScrollArea, null, children) : children));
4268
+ return /* @__PURE__ */ React33.createElement(GridViewContext.Provider, { value: contextValue }, /* @__PURE__ */ React33.createElement(Container3, { onClick: handleClick, scrollable }, scrollable ? /* @__PURE__ */ React33.createElement(ScrollArea, null, children) : children));
4224
4269
  }
4225
4270
  function GridViewSection({
4226
4271
  children,
4227
4272
  padding = "20px"
4228
4273
  }) {
4229
4274
  const { size: size2 } = useContext7(GridViewContext);
4230
- return /* @__PURE__ */ React32.createElement(Grid2, { size: size2, padding }, children);
4275
+ return /* @__PURE__ */ React33.createElement(Grid2, { size: size2, padding }, children);
4231
4276
  }
4232
4277
  function GridViewSectionHeader({ title }) {
4233
4278
  const grouped = title.split("/");
4234
- return /* @__PURE__ */ React32.createElement(SectionHeaderContainer, null, /* @__PURE__ */ React32.createElement(Spacer.Vertical, { size: 24 }), withSeparatorElements(
4235
- grouped.map((title2, index) => /* @__PURE__ */ React32.createElement(SectionTitle, { last: index === grouped.length - 1 }, title2)),
4236
- /* @__PURE__ */ React32.createElement(SectionTitle, null, " / ")
4279
+ return /* @__PURE__ */ React33.createElement(SectionHeaderContainer, null, /* @__PURE__ */ React33.createElement(Spacer.Vertical, { size: 24 }), withSeparatorElements(
4280
+ grouped.map((title2, index) => /* @__PURE__ */ React33.createElement(SectionTitle, { last: index === grouped.length - 1 }, title2)),
4281
+ /* @__PURE__ */ React33.createElement(SectionTitle, null, " / ")
4237
4282
  ));
4238
4283
  }
4239
4284
  var GridView;
@@ -4246,7 +4291,7 @@ var GridView;
4246
4291
 
4247
4292
  // src/components/InputFieldWithCompletions.tsx
4248
4293
  import { chunkBy, partition } from "@noya-app/noya-utils";
4249
- import React36, {
4294
+ import React37, {
4250
4295
  forwardRef as forwardRef15,
4251
4296
  memo as memo23,
4252
4297
  useCallback as useCallback21,
@@ -4333,7 +4378,7 @@ function mergeRanges(ranges) {
4333
4378
  // src/components/ListView.tsx
4334
4379
  import { range } from "@noya-app/noya-utils";
4335
4380
  import { composeRefs as composeRefs2 } from "@radix-ui/react-compose-refs";
4336
- import React34, {
4381
+ import React35, {
4337
4382
  Children as Children4,
4338
4383
  createContext as createContext9,
4339
4384
  forwardRef as forwardRef13,
@@ -4387,7 +4432,7 @@ import {
4387
4432
  useSortable,
4388
4433
  verticalListSortingStrategy
4389
4434
  } from "@dnd-kit/sortable";
4390
- import React33, {
4435
+ import React34, {
4391
4436
  createContext as createContext8,
4392
4437
  memo as memo21,
4393
4438
  useCallback as useCallback19,
@@ -4529,7 +4574,7 @@ function SortableRoot({
4529
4574
  useEffect13(() => {
4530
4575
  setMounted(true);
4531
4576
  }, []);
4532
- return /* @__PURE__ */ React33.createElement(
4577
+ return /* @__PURE__ */ React34.createElement(
4533
4578
  SortableItemContext.Provider,
4534
4579
  {
4535
4580
  value: useMemo17(
@@ -4543,7 +4588,7 @@ function SortableRoot({
4543
4588
  [acceptsDrop, axis, keys, position, setActivatorEvent]
4544
4589
  )
4545
4590
  },
4546
- /* @__PURE__ */ React33.createElement(
4591
+ /* @__PURE__ */ React34.createElement(
4547
4592
  DndContext,
4548
4593
  {
4549
4594
  sensors,
@@ -4552,9 +4597,9 @@ function SortableRoot({
4552
4597
  onDragMove: handleDragMove,
4553
4598
  onDragEnd: handleDragEnd
4554
4599
  },
4555
- /* @__PURE__ */ React33.createElement(SortableContext, { items: keys, strategy: verticalListSortingStrategy }, children),
4600
+ /* @__PURE__ */ React34.createElement(SortableContext, { items: keys, strategy: verticalListSortingStrategy }, children),
4556
4601
  mounted && renderOverlay && createPortal2(
4557
- /* @__PURE__ */ React33.createElement(DragOverlay, { dropAnimation: null }, activeIndex !== void 0 && activeIndex >= 0 && renderOverlay(activeIndex)),
4602
+ /* @__PURE__ */ React34.createElement(DragOverlay, { dropAnimation: null }, activeIndex !== void 0 && activeIndex >= 0 && renderOverlay(activeIndex)),
4558
4603
  document.body
4559
4604
  )
4560
4605
  )
@@ -4569,9 +4614,10 @@ var Sortable;
4569
4614
  // src/components/ListView.tsx
4570
4615
  var ROW_HEIGHT = 31;
4571
4616
  var SECTION_HEADER_LABEL_HEIGHT = 27;
4572
- var DraggingContext = createContext9({
4617
+ var ListViewDraggingContext = createContext9({
4573
4618
  indentation: 12
4574
4619
  });
4620
+ ListViewDraggingContext.displayName = "ListViewDraggingContext";
4575
4621
  var ListRowContext = createContext9({
4576
4622
  marginType: "none",
4577
4623
  selectedPosition: "only",
@@ -4585,6 +4631,7 @@ var ListRowContext = createContext9({
4585
4631
  isSectionHeader: false,
4586
4632
  colorScheme: "primary"
4587
4633
  });
4634
+ ListRowContext.displayName = "ListRowContext";
4588
4635
  var ListViewRowTitle = styled23.span(({ theme }) => ({
4589
4636
  flex: "1 1 0",
4590
4637
  overflow: "hidden",
@@ -4612,7 +4659,7 @@ function ListViewEditableRowTitle({
4612
4659
  element.select();
4613
4660
  }, 0);
4614
4661
  }, [autoFocus]);
4615
- return /* @__PURE__ */ React34.createElement(
4662
+ return /* @__PURE__ */ React35.createElement(
4616
4663
  ListViewEditableRowTitleElement,
4617
4664
  {
4618
4665
  ref: inputRef,
@@ -4772,7 +4819,7 @@ var ListViewRow = forwardRef13(function ListViewRow2({
4772
4819
  const { hoverProps } = useHover({
4773
4820
  onHoverChange
4774
4821
  });
4775
- const { indentation, isDragging } = useContext9(DraggingContext);
4822
+ const { indentation, isDragging } = useContext9(ListViewDraggingContext);
4776
4823
  const handlePress = useCallback20(
4777
4824
  (event) => {
4778
4825
  event.preventDefault();
@@ -4802,7 +4849,7 @@ var ListViewRow = forwardRef13(function ListViewRow2({
4802
4849
  ...renderProps
4803
4850
  }, ref) => {
4804
4851
  const Component = RowContainer;
4805
- const element = /* @__PURE__ */ React34.createElement(
4852
+ const element = /* @__PURE__ */ React35.createElement(
4806
4853
  Component,
4807
4854
  {
4808
4855
  ref,
@@ -4833,7 +4880,7 @@ var ListViewRow = forwardRef13(function ListViewRow2({
4833
4880
  ),
4834
4881
  tabIndex
4835
4882
  },
4836
- relativeDropPosition && /* @__PURE__ */ React34.createElement(
4883
+ relativeDropPosition && /* @__PURE__ */ React35.createElement(
4837
4884
  ListViewDragIndicatorElement,
4838
4885
  {
4839
4886
  $colorScheme: colorScheme,
@@ -4847,11 +4894,11 @@ var ListViewRow = forwardRef13(function ListViewRow2({
4847
4894
  }) : dragIndicatorStyle
4848
4895
  }
4849
4896
  ),
4850
- depth > 0 && /* @__PURE__ */ React34.createElement(Spacer.Horizontal, { size: depth * indentation }),
4897
+ depth > 0 && /* @__PURE__ */ React35.createElement(Spacer.Horizontal, { size: depth * indentation }),
4851
4898
  children
4852
4899
  );
4853
4900
  if (menuItems && onSelectMenuItem) {
4854
- return /* @__PURE__ */ React34.createElement(
4901
+ return /* @__PURE__ */ React35.createElement(
4855
4902
  ContextMenu,
4856
4903
  {
4857
4904
  items: menuItems,
@@ -4864,7 +4911,7 @@ var ListViewRow = forwardRef13(function ListViewRow2({
4864
4911
  return element;
4865
4912
  };
4866
4913
  if (sortable && id) {
4867
- return /* @__PURE__ */ React34.createElement(Sortable.Item, { id, disabled: overrideSortable === false }, ({ ref: sortableRef, ...sortableProps }) => renderContent(
4914
+ return /* @__PURE__ */ React35.createElement(Sortable.Item, { id, disabled: overrideSortable === false }, ({ ref: sortableRef, ...sortableProps }) => renderContent(
4868
4915
  sortableProps,
4869
4916
  composeRefs2(sortableRef, forwardedRef)
4870
4917
  ));
@@ -4874,12 +4921,13 @@ var ListViewRow = forwardRef13(function ListViewRow2({
4874
4921
  var RenderItemContext = createContext9(
4875
4922
  () => null
4876
4923
  );
4924
+ RenderItemContext.displayName = "RenderItemContext";
4877
4925
  var VirtualizedListRow = memo22(function VirtualizedListRow2({
4878
4926
  index,
4879
4927
  style: style3
4880
4928
  }) {
4881
4929
  const renderItem = useContext9(RenderItemContext);
4882
- return /* @__PURE__ */ React34.createElement("div", { key: index, style: style3 }, renderItem(index));
4930
+ return /* @__PURE__ */ React35.createElement("div", { key: index, style: style3 }, renderItem(index));
4883
4931
  });
4884
4932
  var VirtualizedListInner = forwardRef13(function VirtualizedListInner2({
4885
4933
  size: size2,
@@ -4910,7 +4958,7 @@ var VirtualizedListInner = forwardRef13(function VirtualizedListInner2({
4910
4958
  }),
4911
4959
  []
4912
4960
  );
4913
- return /* @__PURE__ */ React34.createElement(RenderItemContext.Provider, { value: renderItem }, /* @__PURE__ */ React34.createElement(
4961
+ return /* @__PURE__ */ React35.createElement(RenderItemContext.Provider, { value: renderItem }, /* @__PURE__ */ React35.createElement(
4914
4962
  WindowScroller,
4915
4963
  {
4916
4964
  scrollElement,
@@ -4921,7 +4969,7 @@ var VirtualizedListInner = forwardRef13(function VirtualizedListInner2({
4921
4969
  registerChild,
4922
4970
  onChildScroll,
4923
4971
  scrollTop
4924
- }) => /* @__PURE__ */ React34.createElement("div", { ref: registerChild }, /* @__PURE__ */ React34.createElement(
4972
+ }) => /* @__PURE__ */ React35.createElement("div", { ref: registerChild }, /* @__PURE__ */ React35.createElement(
4925
4973
  VariableSizeList,
4926
4974
  {
4927
4975
  ref: listRef,
@@ -4998,8 +5046,26 @@ var ListViewRootInner = forwardRef13(function ListViewRootInner2({
4998
5046
  (index) => renderItem(data[index], index, { isDragging: false }),
4999
5047
  [data, renderItem]
5000
5048
  );
5049
+ const defaultContextValue = useMemo18(
5050
+ () => ({
5051
+ colorScheme,
5052
+ marginType: "none",
5053
+ selectedPosition: "only",
5054
+ sortable,
5055
+ expandable,
5056
+ divider,
5057
+ pressEventName,
5058
+ variant,
5059
+ gap,
5060
+ sectionHeaderVariant: "normal",
5061
+ isSectionHeader: false
5062
+ }),
5063
+ [colorScheme, sortable, expandable, divider, pressEventName, variant, gap]
5064
+ );
5001
5065
  const getItemContextValue = useCallback20(
5002
5066
  (i) => {
5067
+ if (variant === "bare" || variant === "normal")
5068
+ return defaultContextValue;
5003
5069
  const current = renderChild(i);
5004
5070
  if (!isValidElement3(current))
5005
5071
  return;
@@ -5046,6 +5112,8 @@ var ListViewRootInner = forwardRef13(function ListViewRootInner2({
5046
5112
  };
5047
5113
  },
5048
5114
  [
5115
+ variant,
5116
+ defaultContextValue,
5049
5117
  renderChild,
5050
5118
  data.length,
5051
5119
  colorScheme,
@@ -5053,7 +5121,6 @@ var ListViewRootInner = forwardRef13(function ListViewRootInner2({
5053
5121
  expandable,
5054
5122
  divider,
5055
5123
  pressEventName,
5056
- variant,
5057
5124
  sectionHeaderVariant,
5058
5125
  gap
5059
5126
  ]
@@ -5063,7 +5130,7 @@ var ListViewRootInner = forwardRef13(function ListViewRootInner2({
5063
5130
  [indentation]
5064
5131
  );
5065
5132
  const renderOverlay = useCallback20(
5066
- (index) => /* @__PURE__ */ React34.createElement("div", { style: { opacity: 0.25 } }, /* @__PURE__ */ React34.createElement(DraggingContext.Provider, { value: draggingContextOverlayValue }, renderItem(data[index], index, { isDragging: true }))),
5133
+ (index) => /* @__PURE__ */ React35.createElement("div", { style: { opacity: 0.25 } }, /* @__PURE__ */ React35.createElement(ListViewDraggingContext.Provider, { value: draggingContextOverlayValue }, renderItem(data[index], index, { isDragging: true }))),
5067
5134
  [draggingContextOverlayValue, renderItem, data]
5068
5135
  );
5069
5136
  const renderWrappedChild = useCallback20(
@@ -5072,12 +5139,12 @@ var ListViewRootInner = forwardRef13(function ListViewRootInner2({
5072
5139
  const current = renderChild(index);
5073
5140
  if (!contextValue || !isValidElement3(current))
5074
5141
  return null;
5075
- return /* @__PURE__ */ React34.createElement(ListRowContext.Provider, { key: current.key, value: contextValue }, current);
5142
+ return /* @__PURE__ */ React35.createElement(ListRowContext.Provider, { key: current.key, value: contextValue }, current);
5076
5143
  },
5077
5144
  [getItemContextValue, renderChild]
5078
5145
  );
5079
5146
  const ids = useMemo18(() => data.map(keyExtractor), [keyExtractor, data]);
5080
- const withSortable = (children) => sortable ? /* @__PURE__ */ React34.createElement(
5147
+ const withSortable = (children) => sortable ? /* @__PURE__ */ React35.createElement(
5081
5148
  Sortable.Root,
5082
5149
  {
5083
5150
  onMoveItem,
@@ -5087,7 +5154,7 @@ var ListViewRootInner = forwardRef13(function ListViewRootInner2({
5087
5154
  },
5088
5155
  children
5089
5156
  ) : children;
5090
- const withScrollable = (children) => scrollable ? /* @__PURE__ */ React34.createElement(ScrollArea, null, children) : children(null);
5157
+ const withScrollable = (children) => scrollable ? /* @__PURE__ */ React35.createElement(ScrollArea, null, children) : children(null);
5091
5158
  const getItemHeight = useCallback20(
5092
5159
  (index) => {
5093
5160
  const child = getItemContextValue(index);
@@ -5102,7 +5169,7 @@ var ListViewRootInner = forwardRef13(function ListViewRootInner2({
5102
5169
  [data, keyExtractor]
5103
5170
  );
5104
5171
  const draggingContextValue = useMemo18(() => ({ indentation }), [indentation]);
5105
- return /* @__PURE__ */ React34.createElement(DraggingContext.Provider, { value: draggingContextValue }, /* @__PURE__ */ React34.createElement(
5172
+ return /* @__PURE__ */ React35.createElement(ListViewDraggingContext.Provider, { value: draggingContextValue }, /* @__PURE__ */ React35.createElement(
5106
5173
  RootContainer2,
5107
5174
  {
5108
5175
  id,
@@ -5116,7 +5183,7 @@ var ListViewRootInner = forwardRef13(function ListViewRootInner2({
5116
5183
  },
5117
5184
  withScrollable(
5118
5185
  (scrollElementRef) => withSortable(
5119
- virtualized ? /* @__PURE__ */ React34.createElement(
5186
+ virtualized ? /* @__PURE__ */ React35.createElement(
5120
5187
  VirtualizedList,
5121
5188
  {
5122
5189
  ref: forwardedRef,
@@ -5140,7 +5207,7 @@ var ChildrenListViewInner = forwardRef13(function ChildrenListViewInner2({ child
5140
5207
  ),
5141
5208
  [children]
5142
5209
  );
5143
- return /* @__PURE__ */ React34.createElement(
5210
+ return /* @__PURE__ */ React35.createElement(
5144
5211
  ListViewRoot,
5145
5212
  {
5146
5213
  ref: forwardedRef,
@@ -5157,9 +5224,9 @@ var ChildrenListViewInner = forwardRef13(function ChildrenListViewInner2({ child
5157
5224
  var ChildrenListView = memo22(ChildrenListViewInner);
5158
5225
  var SimpleListViewInner = forwardRef13(function SimpleListViewInner2(props, forwardedRef) {
5159
5226
  if ("children" in props) {
5160
- return /* @__PURE__ */ React34.createElement(ChildrenListView, { ref: forwardedRef, ...props });
5227
+ return /* @__PURE__ */ React35.createElement(ChildrenListView, { ref: forwardedRef, ...props });
5161
5228
  } else {
5162
- return /* @__PURE__ */ React34.createElement(ListViewRoot, { ref: forwardedRef, ...props });
5229
+ return /* @__PURE__ */ React35.createElement(ListViewRoot, { ref: forwardedRef, ...props });
5163
5230
  }
5164
5231
  });
5165
5232
  var SimpleListView = memo22(SimpleListViewInner);
@@ -5180,7 +5247,7 @@ var ListView;
5180
5247
  })(ListView || (ListView = {}));
5181
5248
 
5182
5249
  // src/components/Text.tsx
5183
- import React35, { forwardRef as forwardRef14 } from "react";
5250
+ import React36, { forwardRef as forwardRef14 } from "react";
5184
5251
  import styled24 from "styled-components";
5185
5252
  var elements = {
5186
5253
  title: "h1",
@@ -5216,7 +5283,7 @@ var Text = forwardRef14(function Text2({
5216
5283
  ...rest
5217
5284
  }, forwardedRef) {
5218
5285
  const element = as ?? elements[variant] ?? "span";
5219
- return /* @__PURE__ */ React35.createElement(
5286
+ return /* @__PURE__ */ React36.createElement(
5220
5287
  StyledElement,
5221
5288
  {
5222
5289
  ref: forwardedRef,
@@ -5235,27 +5302,27 @@ var Text = forwardRef14(function Text2({
5235
5302
  );
5236
5303
  });
5237
5304
  var Heading1 = forwardRef14(
5238
- (props, ref) => /* @__PURE__ */ React35.createElement(Text, { ref, ...props, variant: "heading1" })
5305
+ (props, ref) => /* @__PURE__ */ React36.createElement(Text, { ref, ...props, variant: "heading1" })
5239
5306
  );
5240
5307
  var Heading2 = forwardRef14(
5241
- (props, ref) => /* @__PURE__ */ React35.createElement(Text, { ref, ...props, variant: "heading2" })
5308
+ (props, ref) => /* @__PURE__ */ React36.createElement(Text, { ref, ...props, variant: "heading2" })
5242
5309
  );
5243
5310
  var Heading3 = forwardRef14(
5244
- (props, ref) => /* @__PURE__ */ React35.createElement(Text, { ref, ...props, variant: "heading3" })
5311
+ (props, ref) => /* @__PURE__ */ React36.createElement(Text, { ref, ...props, variant: "heading3" })
5245
5312
  );
5246
5313
  var Heading4 = forwardRef14(
5247
- (props, ref) => /* @__PURE__ */ React35.createElement(Text, { ref, ...props, variant: "heading4" })
5314
+ (props, ref) => /* @__PURE__ */ React36.createElement(Text, { ref, ...props, variant: "heading4" })
5248
5315
  );
5249
5316
  var Heading5 = forwardRef14(
5250
- (props, ref) => /* @__PURE__ */ React35.createElement(Text, { ref, ...props, variant: "heading5" })
5317
+ (props, ref) => /* @__PURE__ */ React36.createElement(Text, { ref, ...props, variant: "heading5" })
5251
5318
  );
5252
5319
  var Body = forwardRef14(
5253
- (props, ref) => /* @__PURE__ */ React35.createElement(Text, { ref, ...props, variant: "body" })
5320
+ (props, ref) => /* @__PURE__ */ React36.createElement(Text, { ref, ...props, variant: "body" })
5254
5321
  );
5255
5322
  var Small = forwardRef14(
5256
- (props, ref) => /* @__PURE__ */ React35.createElement(Text, { ref, ...props, variant: "small" })
5323
+ (props, ref) => /* @__PURE__ */ React36.createElement(Text, { ref, ...props, variant: "small" })
5257
5324
  );
5258
- var Italic = ({ children }) => /* @__PURE__ */ React35.createElement(
5325
+ var Italic = ({ children }) => /* @__PURE__ */ React36.createElement(
5259
5326
  "span",
5260
5327
  {
5261
5328
  style: {
@@ -5305,7 +5372,7 @@ var CompletionMenu = memo23(
5305
5372
  onHoverIndex,
5306
5373
  listSize
5307
5374
  }, forwardedRef) {
5308
- return /* @__PURE__ */ React36.createElement(
5375
+ return /* @__PURE__ */ React37.createElement(
5309
5376
  ListView.Root,
5310
5377
  {
5311
5378
  ref: forwardedRef,
@@ -5317,13 +5384,13 @@ var CompletionMenu = memo23(
5317
5384
  sectionHeaderVariant: "label",
5318
5385
  renderItem: (item, i) => {
5319
5386
  if (item.type === "sectionHeader") {
5320
- return /* @__PURE__ */ React36.createElement(ListView.Row, { key: item.id, isSectionHeader: true }, item.name);
5387
+ return /* @__PURE__ */ React37.createElement(ListView.Row, { key: item.id, isSectionHeader: true }, item.name);
5321
5388
  }
5322
5389
  const tokens = fuzzyTokenize({
5323
5390
  item: item.name,
5324
5391
  itemScore: item
5325
5392
  });
5326
- return /* @__PURE__ */ React36.createElement(
5393
+ return /* @__PURE__ */ React37.createElement(
5327
5394
  ListView.Row,
5328
5395
  {
5329
5396
  key: item.id,
@@ -5335,8 +5402,8 @@ var CompletionMenu = memo23(
5335
5402
  }
5336
5403
  }
5337
5404
  },
5338
- tokens.map((token, j) => /* @__PURE__ */ React36.createElement(CompletionToken, { key: j, $type: token.type }, token.text)),
5339
- item.icon && /* @__PURE__ */ React36.createElement(React36.Fragment, null, /* @__PURE__ */ React36.createElement(Spacer.Horizontal, null), item.icon)
5405
+ tokens.map((token, j) => /* @__PURE__ */ React37.createElement(CompletionToken, { key: j, $type: token.type }, token.text)),
5406
+ item.icon && /* @__PURE__ */ React37.createElement(React37.Fragment, null, /* @__PURE__ */ React37.createElement(Spacer.Horizontal, null), item.icon)
5340
5407
  );
5341
5408
  }
5342
5409
  }
@@ -5405,7 +5472,7 @@ var InputFieldWithCompletions = memo23(
5405
5472
  updateState({ filter: initialValue });
5406
5473
  }, [initialValue, updateState]);
5407
5474
  const { filter, selectedIndex } = state;
5408
- const listRef = React36.useRef(null);
5475
+ const listRef = React37.useRef(null);
5409
5476
  const filteredItems = useMemo19(
5410
5477
  () => filterWithGroupedSections(items, filter),
5411
5478
  [items, filter]
@@ -5541,14 +5608,14 @@ var InputFieldWithCompletions = memo23(
5541
5608
  ref.current?.setSelectionRange(0, ref.current.value.length);
5542
5609
  }
5543
5610
  }));
5544
- return /* @__PURE__ */ React36.createElement(
5611
+ return /* @__PURE__ */ React37.createElement(
5545
5612
  InputField.Root,
5546
5613
  {
5547
5614
  size: size2,
5548
5615
  labelSize: 16,
5549
5616
  renderPopoverContent: ({ width }) => {
5550
5617
  const listSize = { width, height };
5551
- return /* @__PURE__ */ React36.createElement(Stack.V, { flex: `0 0 ${height}px`, display }, filteredItems.length > 0 ? /* @__PURE__ */ React36.createElement(
5618
+ return /* @__PURE__ */ React37.createElement(Stack.V, { flex: `0 0 ${height}px`, display }, filteredItems.length > 0 ? /* @__PURE__ */ React37.createElement(
5552
5619
  CompletionMenu,
5553
5620
  {
5554
5621
  ref: listRef,
@@ -5558,7 +5625,7 @@ var InputFieldWithCompletions = memo23(
5558
5625
  onHoverIndex: handleIndexChange,
5559
5626
  listSize
5560
5627
  }
5561
- ) : /* @__PURE__ */ React36.createElement(
5628
+ ) : /* @__PURE__ */ React37.createElement(
5562
5629
  Stack.V,
5563
5630
  {
5564
5631
  height: "100px",
@@ -5566,11 +5633,11 @@ var InputFieldWithCompletions = memo23(
5566
5633
  alignItems: "center",
5567
5634
  justifyContent: "center"
5568
5635
  },
5569
- /* @__PURE__ */ React36.createElement(Small, { color: "textDisabled" }, loading ? "Loading" : "No results")
5636
+ /* @__PURE__ */ React37.createElement(Small, { color: "textDisabled" }, loading ? "Loading" : "No results")
5570
5637
  ));
5571
5638
  }
5572
5639
  },
5573
- /* @__PURE__ */ React36.createElement(
5640
+ /* @__PURE__ */ React37.createElement(
5574
5641
  InputField.Input,
5575
5642
  {
5576
5643
  ref,
@@ -5594,9 +5661,9 @@ var InputFieldWithCompletions = memo23(
5594
5661
  "aria-controls": "component-listbox"
5595
5662
  }
5596
5663
  ),
5597
- filter && typeaheadValue && typeaheadValue.startsWith(filter) && /* @__PURE__ */ React36.createElement(InputField.Typeahead, { value: typeaheadValue }),
5664
+ filter && typeaheadValue && typeaheadValue.startsWith(filter) && /* @__PURE__ */ React37.createElement(InputField.Typeahead, { value: typeaheadValue }),
5598
5665
  (!isFocused || !hideChildrenWhenFocused) && children,
5599
- loading && isFocused && /* @__PURE__ */ React36.createElement(InputField.Label, null, /* @__PURE__ */ React36.createElement(ActivityIndicator, null))
5666
+ loading && isFocused && /* @__PURE__ */ React37.createElement(InputField.Label, null, /* @__PURE__ */ React37.createElement(ActivityIndicator, null))
5600
5667
  );
5601
5668
  })
5602
5669
  );
@@ -5618,7 +5685,7 @@ function getNextIndex(items, currentIndex, direction, isDisabled) {
5618
5685
  }
5619
5686
 
5620
5687
  // src/components/InspectorContainer.tsx
5621
- import React37, { forwardRef as forwardRef16, memo as memo24 } from "react";
5688
+ import React38, { forwardRef as forwardRef16, memo as memo24 } from "react";
5622
5689
  var InspectorContainer = memo24(
5623
5690
  forwardRef16(function InspectorContainer2({
5624
5691
  header,
@@ -5630,7 +5697,7 @@ var InspectorContainer = memo24(
5630
5697
  style: style3
5631
5698
  }, forwardedRef) {
5632
5699
  const theme = useDesignSystemTheme();
5633
- return /* @__PURE__ */ React37.createElement(
5700
+ return /* @__PURE__ */ React38.createElement(
5634
5701
  "div",
5635
5702
  {
5636
5703
  ref: forwardedRef,
@@ -5645,13 +5712,13 @@ var InspectorContainer = memo24(
5645
5712
  }
5646
5713
  },
5647
5714
  header,
5648
- children ? /* @__PURE__ */ React37.createElement(ScrollArea, null, /* @__PURE__ */ React37.createElement(Stack.V, { position: "relative" }, showDividers ? withSeparatorElements(children, /* @__PURE__ */ React37.createElement(Divider, null)) : children)) : fallback ? /* @__PURE__ */ React37.createElement(Stack.V, { position: "relative", height: "100%" }, fallback) : null
5715
+ children ? /* @__PURE__ */ React38.createElement(ScrollArea, null, /* @__PURE__ */ React38.createElement(Stack.V, { position: "relative" }, showDividers ? withSeparatorElements(children, /* @__PURE__ */ React38.createElement(Divider, null)) : children)) : fallback ? /* @__PURE__ */ React38.createElement(Stack.V, { position: "relative", height: "100%" }, fallback) : null
5649
5716
  );
5650
5717
  })
5651
5718
  );
5652
5719
 
5653
5720
  // src/components/Label.tsx
5654
- import React38, { memo as memo25 } from "react";
5721
+ import React39, { memo as memo25 } from "react";
5655
5722
  import styled26 from "styled-components";
5656
5723
  var LabelLabel = styled26.label(
5657
5724
  ({ theme, $selected }) => ({
@@ -5680,7 +5747,7 @@ var LabelContainer2 = styled26.span(({ theme }) => ({
5680
5747
  alignItems: "center"
5681
5748
  }));
5682
5749
  function LabelRoot({ label, children }) {
5683
- return /* @__PURE__ */ React38.createElement(LabelContainer2, null, children, label && /* @__PURE__ */ React38.createElement(React38.Fragment, null, /* @__PURE__ */ React38.createElement(Spacer.Vertical, { size: 2 }), /* @__PURE__ */ React38.createElement(LabelLabel, null, label)));
5750
+ return /* @__PURE__ */ React39.createElement(LabelContainer2, null, children, label && /* @__PURE__ */ React39.createElement(React39.Fragment, null, /* @__PURE__ */ React39.createElement(Spacer.Vertical, { size: 2 }), /* @__PURE__ */ React39.createElement(LabelLabel, null, label)));
5684
5751
  }
5685
5752
  var Label;
5686
5753
  ((_Label) => {
@@ -5690,7 +5757,7 @@ var Label;
5690
5757
 
5691
5758
  // src/components/LabeledElementView.tsx
5692
5759
  import * as kiwi from "kiwi.js";
5693
- import React39, {
5760
+ import React40, {
5694
5761
  Children as Children5,
5695
5762
  createRef,
5696
5763
  Fragment,
@@ -5735,7 +5802,7 @@ var LabeledElementView = memo26(function LabeledElementView2({
5735
5802
  );
5736
5803
  }, [serializedIds]);
5737
5804
  const labelElements = useMemo20(() => {
5738
- return serializedIds.split(",").map((id, index) => /* @__PURE__ */ React39.createElement(
5805
+ return serializedIds.split(",").map((id, index) => /* @__PURE__ */ React40.createElement(
5739
5806
  "span",
5740
5807
  {
5741
5808
  key: id,
@@ -5813,13 +5880,13 @@ var LabeledElementView = memo26(function LabeledElementView2({
5813
5880
  `${Math.max(...heights)}px`
5814
5881
  );
5815
5882
  }, [refs, labelElements]);
5816
- return /* @__PURE__ */ React39.createElement(Container4, { ref: containerRef }, /* @__PURE__ */ React39.createElement(Tools, null, children), /* @__PURE__ */ React39.createElement(Labels, null, labelElements));
5883
+ return /* @__PURE__ */ React40.createElement(Container4, { ref: containerRef }, /* @__PURE__ */ React40.createElement(Tools, null, children), /* @__PURE__ */ React40.createElement(Labels, null, labelElements));
5817
5884
  });
5818
5885
 
5819
5886
  // src/components/Progress.tsx
5820
5887
  import { clamp } from "@noya-app/noya-utils";
5821
5888
  import * as ProgressPrimitive from "@radix-ui/react-progress";
5822
- import React40 from "react";
5889
+ import React41 from "react";
5823
5890
  import styled28 from "styled-components";
5824
5891
  function Progress({
5825
5892
  value,
@@ -5829,7 +5896,7 @@ function Progress({
5829
5896
  variant = "normal"
5830
5897
  }) {
5831
5898
  const clampedValue = clamp(value, 0, 100);
5832
- return /* @__PURE__ */ React40.createElement(ProgressRoot, { value: clampedValue, style: { width, flex, height } }, /* @__PURE__ */ React40.createElement(
5899
+ return /* @__PURE__ */ React41.createElement(ProgressRoot, { value: clampedValue, style: { width, flex, height } }, /* @__PURE__ */ React41.createElement(
5833
5900
  ProgressIndicator,
5834
5901
  {
5835
5902
  variant,
@@ -5854,7 +5921,7 @@ var ProgressIndicator = styled28(ProgressPrimitive.Indicator)(({ theme, variant
5854
5921
 
5855
5922
  // src/components/RadioGroup.tsx
5856
5923
  import * as ToggleGroupPrimitive from "@radix-ui/react-toggle-group";
5857
- import React41, {
5924
+ import React42, {
5858
5925
  createContext as createContext10,
5859
5926
  forwardRef as forwardRef17,
5860
5927
  memo as memo27,
@@ -5916,7 +5983,7 @@ var StyledItem = styled29(ToggleGroupPrimitive.Item).withConfig({
5916
5983
  }));
5917
5984
  var ToggleGroupItem = forwardRef17(function ToggleGroupItem2({ value, tooltip, children, disabled = false }, forwardedRef) {
5918
5985
  const { colorScheme } = useContext10(RadioGroupContext);
5919
- const itemElement = /* @__PURE__ */ React41.createElement(
5986
+ const itemElement = /* @__PURE__ */ React42.createElement(
5920
5987
  StyledItem,
5921
5988
  {
5922
5989
  ref: forwardedRef,
@@ -5926,7 +5993,7 @@ var ToggleGroupItem = forwardRef17(function ToggleGroupItem2({ value, tooltip, c
5926
5993
  },
5927
5994
  children
5928
5995
  );
5929
- return tooltip ? /* @__PURE__ */ React41.createElement(Tooltip, { content: tooltip }, itemElement) : itemElement;
5996
+ return tooltip ? /* @__PURE__ */ React42.createElement(Tooltip, { content: tooltip }, itemElement) : itemElement;
5930
5997
  });
5931
5998
  var RadioGroupContext = createContext10({
5932
5999
  colorScheme: "primary"
@@ -5948,7 +6015,7 @@ function ToggleGroupRoot({
5948
6015
  },
5949
6016
  [allowEmpty, onValueChange]
5950
6017
  );
5951
- return /* @__PURE__ */ React41.createElement(RadioGroupContext.Provider, { value: contextValue }, /* @__PURE__ */ React41.createElement(
6018
+ return /* @__PURE__ */ React42.createElement(RadioGroupContext.Provider, { value: contextValue }, /* @__PURE__ */ React42.createElement(
5952
6019
  StyledRoot,
5953
6020
  {
5954
6021
  id,
@@ -5968,7 +6035,7 @@ var RadioGroup;
5968
6035
 
5969
6036
  // src/components/Select.tsx
5970
6037
  import { memoize } from "@noya-app/noya-utils";
5971
- import React42, {
6038
+ import React43, {
5972
6039
  createContext as createContext11,
5973
6040
  memo as memo28,
5974
6041
  useCallback as useCallback23,
@@ -5991,7 +6058,7 @@ var SelectOption = memo28(function SelectOption2({
5991
6058
  addListener(value, onSelect);
5992
6059
  return () => removeListener(value);
5993
6060
  }, [addListener, onSelect, removeListener, value]);
5994
- return /* @__PURE__ */ React42.createElement("option", { value }, title ?? value);
6061
+ return /* @__PURE__ */ React43.createElement("option", { value }, title ?? value);
5995
6062
  });
5996
6063
  var createChevronSVGString = memoize(
5997
6064
  (color) => `
@@ -6065,7 +6132,7 @@ var Select = memo28(function Select2({
6065
6132
  const onChange = "options" in rest ? rest.onChange : void 0;
6066
6133
  const children = "options" in rest ? void 0 : rest.children;
6067
6134
  const optionElements = useMemo22(
6068
- () => options ? options.map((option, index) => /* @__PURE__ */ React42.createElement(
6135
+ () => options ? options.map((option, index) => /* @__PURE__ */ React43.createElement(
6069
6136
  SelectOption,
6070
6137
  {
6071
6138
  key: option,
@@ -6084,7 +6151,7 @@ var Select = memo28(function Select2({
6084
6151
  }),
6085
6152
  []
6086
6153
  );
6087
- return /* @__PURE__ */ React42.createElement(SelectContext.Provider, { value: contextValue }, /* @__PURE__ */ React42.createElement(SelectContainer, { $flex: flex }, /* @__PURE__ */ React42.createElement(
6154
+ return /* @__PURE__ */ React43.createElement(SelectContext.Provider, { value: contextValue }, /* @__PURE__ */ React43.createElement(SelectContainer, { $flex: flex }, /* @__PURE__ */ React43.createElement(
6088
6155
  SelectElement,
6089
6156
  {
6090
6157
  id,
@@ -6097,14 +6164,18 @@ var Select = memo28(function Select2({
6097
6164
  onPointerDown: (event) => event.stopPropagation()
6098
6165
  },
6099
6166
  optionElements
6100
- )), label && /* @__PURE__ */ React42.createElement(SelectLabel, { htmlFor: id }, label));
6167
+ )), label && /* @__PURE__ */ React43.createElement(SelectLabel, { htmlFor: id }, label));
6101
6168
  });
6102
6169
 
6103
6170
  // src/components/SelectMenu.tsx
6104
6171
  import { DropdownChevronIcon } from "@noya-app/noya-icons";
6105
6172
  import * as Select3 from "@radix-ui/react-select";
6106
- import React43, { memo as memo29 } from "react";
6173
+ import React44, { memo as memo29 } from "react";
6107
6174
  import { styled as styled31 } from "styled-components";
6175
+ var readOnlyStyle = {
6176
+ justifyContent: "flex-start",
6177
+ textAlign: "left"
6178
+ };
6108
6179
  var SelectMenu = memo29(function SelectMenu2({
6109
6180
  id,
6110
6181
  style: style3,
@@ -6112,29 +6183,45 @@ var SelectMenu = memo29(function SelectMenu2({
6112
6183
  menuItems,
6113
6184
  value,
6114
6185
  onSelect,
6115
- placeholder
6186
+ placeholder,
6187
+ disabled,
6188
+ readOnly
6116
6189
  }) {
6117
6190
  const selectedItem = menuItems.find(
6118
6191
  (item) => typeof item !== "string" && item.value === value
6119
6192
  );
6120
6193
  const icon = selectedItem?.icon;
6121
- return /* @__PURE__ */ React43.createElement(Select3.Root, { value, onValueChange: onSelect }, /* @__PURE__ */ React43.createElement(Select3.SelectTrigger, { asChild: true }, /* @__PURE__ */ React43.createElement(Button, { id, style: style3, className }, icon && /* @__PURE__ */ React43.createElement(React43.Fragment, null, icon, /* @__PURE__ */ React43.createElement(Spacer.Horizontal, { size: 8 })), /* @__PURE__ */ React43.createElement(Select3.Value, { placeholder }), /* @__PURE__ */ React43.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React43.createElement(DropdownChevronIcon, null))), /* @__PURE__ */ React43.createElement(Select3.Portal, null, /* @__PURE__ */ React43.createElement(SelectContent, null, /* @__PURE__ */ React43.createElement(SelectViewport, null, menuItems.map((menuItem) => {
6194
+ if (readOnly) {
6195
+ return /* @__PURE__ */ React44.createElement(
6196
+ Button,
6197
+ {
6198
+ id,
6199
+ style: style3,
6200
+ contentStyle: readOnlyStyle,
6201
+ className,
6202
+ disabled
6203
+ },
6204
+ icon && /* @__PURE__ */ React44.createElement(React44.Fragment, null, renderIcon(icon), /* @__PURE__ */ React44.createElement(Spacer.Horizontal, { size: 8 })),
6205
+ selectedItem?.title ?? value
6206
+ );
6207
+ }
6208
+ return /* @__PURE__ */ React44.createElement(Select3.Root, { value, onValueChange: onSelect }, /* @__PURE__ */ React44.createElement(Select3.SelectTrigger, { asChild: true }, /* @__PURE__ */ React44.createElement(Button, { id, style: style3, className, disabled }, icon && /* @__PURE__ */ React44.createElement(React44.Fragment, null, renderIcon(icon), /* @__PURE__ */ React44.createElement(Spacer.Horizontal, { size: 8 })), /* @__PURE__ */ React44.createElement(Select3.Value, { placeholder }), /* @__PURE__ */ React44.createElement(Spacer.Horizontal, null), /* @__PURE__ */ React44.createElement(DropdownChevronIcon, null))), /* @__PURE__ */ React44.createElement(Select3.Portal, null, /* @__PURE__ */ React44.createElement(SelectContent, null, /* @__PURE__ */ React44.createElement(SelectViewport, null, menuItems.map((menuItem) => {
6122
6209
  if (typeof menuItem === "string") {
6123
- return /* @__PURE__ */ React43.createElement(StyledSeparator, null);
6210
+ return /* @__PURE__ */ React44.createElement(StyledSeparator, null);
6124
6211
  }
6125
6212
  const value2 = menuItem.value ?? "";
6126
- return /* @__PURE__ */ React43.createElement(SelectItem, { key: value2, value: value2, icon: menuItem.icon }, menuItem.title ?? value2);
6213
+ return /* @__PURE__ */ React44.createElement(SelectItem, { key: value2, value: value2, icon: menuItem.icon }, menuItem.title ?? value2);
6127
6214
  })))));
6128
6215
  });
6129
6216
  var SelectContent = styled31(Select3.Content)(styles.contentStyle);
6130
6217
  var SelectViewport = styled31(Select3.Viewport)({});
6131
- var SelectItem = React43.forwardRef(
6218
+ var SelectItem = React44.forwardRef(
6132
6219
  ({
6133
6220
  children,
6134
6221
  icon,
6135
6222
  ...props
6136
6223
  }, forwardedRef) => {
6137
- return /* @__PURE__ */ React43.createElement(StyledItem2, { ...props, ref: forwardedRef }, icon && /* @__PURE__ */ React43.createElement(React43.Fragment, null, icon, /* @__PURE__ */ React43.createElement(Spacer.Horizontal, { size: 8 })), /* @__PURE__ */ React43.createElement(Select3.ItemText, null, children));
6224
+ return /* @__PURE__ */ React44.createElement(StyledItem2, { ...props, ref: forwardedRef }, icon && /* @__PURE__ */ React44.createElement(React44.Fragment, null, renderIcon(icon), /* @__PURE__ */ React44.createElement(Spacer.Horizontal, { size: 8 })), /* @__PURE__ */ React44.createElement(Select3.ItemText, null, children));
6138
6225
  }
6139
6226
  );
6140
6227
  var StyledItem2 = styled31(Select3.Item)(styles.itemStyle);
@@ -6142,7 +6229,7 @@ var StyledSeparator = styled31(Select3.Separator)(styles.separatorStyle);
6142
6229
 
6143
6230
  // src/components/Slider.tsx
6144
6231
  import * as RadixSlider from "@radix-ui/react-slider";
6145
- import React44, { useCallback as useCallback24, useMemo as useMemo23 } from "react";
6232
+ import React45, { useCallback as useCallback24, useMemo as useMemo23 } from "react";
6146
6233
  import styled32 from "styled-components";
6147
6234
  var StyledSlider = styled32(RadixSlider.Root)({
6148
6235
  flex: "1",
@@ -6193,7 +6280,7 @@ var Slider = function Slider2({
6193
6280
  },
6194
6281
  [onValueChange]
6195
6282
  );
6196
- return /* @__PURE__ */ React44.createElement(
6283
+ return /* @__PURE__ */ React45.createElement(
6197
6284
  StyledSlider,
6198
6285
  {
6199
6286
  min,
@@ -6202,14 +6289,14 @@ var Slider = function Slider2({
6202
6289
  value: arrayValue,
6203
6290
  onValueChange: handleValueChange
6204
6291
  },
6205
- /* @__PURE__ */ React44.createElement(StyledTrack, null, /* @__PURE__ */ React44.createElement(StyledRange, null)),
6206
- /* @__PURE__ */ React44.createElement(StyledThumb2, null)
6292
+ /* @__PURE__ */ React45.createElement(StyledTrack, null, /* @__PURE__ */ React45.createElement(StyledRange, null)),
6293
+ /* @__PURE__ */ React45.createElement(StyledThumb2, null)
6207
6294
  );
6208
6295
  };
6209
6296
 
6210
6297
  // src/components/Switch.tsx
6211
6298
  import * as SwitchPrimitive from "@radix-ui/react-switch";
6212
- import React45 from "react";
6299
+ import React46 from "react";
6213
6300
  import styled33 from "styled-components";
6214
6301
  var SwitchRoot = styled33(SwitchPrimitive.Root)(({ theme, $colorScheme }) => ({
6215
6302
  all: "unset",
@@ -6242,23 +6329,25 @@ var SwitchThumb = styled33(SwitchPrimitive.Thumb)({
6242
6329
  var Switch = function Switch2({
6243
6330
  value,
6244
6331
  onChange,
6245
- colorScheme = "normal"
6332
+ colorScheme = "normal",
6333
+ disabled
6246
6334
  }) {
6247
- return /* @__PURE__ */ React45.createElement(
6335
+ return /* @__PURE__ */ React46.createElement(
6248
6336
  SwitchRoot,
6249
6337
  {
6250
6338
  $colorScheme: colorScheme,
6251
6339
  checked: value,
6340
+ disabled,
6252
6341
  onCheckedChange: (newValue) => {
6253
6342
  onChange(newValue);
6254
6343
  }
6255
6344
  },
6256
- /* @__PURE__ */ React45.createElement(SwitchThumb, null)
6345
+ /* @__PURE__ */ React46.createElement(SwitchThumb, null)
6257
6346
  );
6258
6347
  };
6259
6348
 
6260
6349
  // src/components/TreeView.tsx
6261
- import React46, {
6350
+ import React47, {
6262
6351
  forwardRef as forwardRef18,
6263
6352
  memo as memo30,
6264
6353
  useCallback as useCallback25,
@@ -6279,14 +6368,14 @@ var TreeRow = forwardRef18(function TreeRow2({
6279
6368
  },
6280
6369
  [onClickChevron]
6281
6370
  );
6282
- return /* @__PURE__ */ React46.createElement(ListView.Row, { ref: forwardedRef, ...rest }, expandable && /* @__PURE__ */ React46.createElement(React46.Fragment, null, expanded === void 0 ? /* @__PURE__ */ React46.createElement(Spacer.Horizontal, { size: 19 }) : /* @__PURE__ */ React46.createElement(
6371
+ return /* @__PURE__ */ React47.createElement(ListView.Row, { ref: forwardedRef, ...rest }, expandable && /* @__PURE__ */ React47.createElement(React47.Fragment, null, expanded === void 0 ? /* @__PURE__ */ React47.createElement(Spacer.Horizontal, { size: 19 }) : /* @__PURE__ */ React47.createElement(
6283
6372
  IconButton,
6284
6373
  {
6285
6374
  iconName: expanded ? "ChevronDownIcon2" : "ChevronRightIcon2",
6286
6375
  onClick: handleClickChevron,
6287
6376
  selected: rest.selected
6288
6377
  }
6289
- ), /* @__PURE__ */ React46.createElement(Spacer.Horizontal, { size: 6 })), icon && /* @__PURE__ */ React46.createElement(React46.Fragment, null, icon, /* @__PURE__ */ React46.createElement(Spacer.Horizontal, { size: 10 })), children);
6378
+ ), /* @__PURE__ */ React47.createElement(Spacer.Horizontal, { size: 6 })), icon && /* @__PURE__ */ React47.createElement(React47.Fragment, null, renderIcon(icon), /* @__PURE__ */ React47.createElement(Spacer.Horizontal, { size: 10 })), children);
6290
6379
  });
6291
6380
  var TreeView;
6292
6381
  ((TreeView2) => {
@@ -6298,7 +6387,7 @@ var TreeView;
6298
6387
 
6299
6388
  // src/components/WorkspaceLayout.tsx
6300
6389
  import { useKeyboardShortcuts as useKeyboardShortcuts3 } from "@noya-app/noya-keymap";
6301
- import React48, { forwardRef as forwardRef19, useImperativeHandle as useImperativeHandle4, useRef as useRef20 } from "react";
6390
+ import React49, { forwardRef as forwardRef19, useImperativeHandle as useImperativeHandle4, useRef as useRef20 } from "react";
6302
6391
  import {
6303
6392
  Panel,
6304
6393
  PanelGroup,
@@ -6526,7 +6615,7 @@ var WorkspaceLayout = forwardRef19(function WorkspaceLayout2({
6526
6615
  }
6527
6616
  });
6528
6617
  const centerPanelPercentage = 100 - (leftPanelContent ? leftSidebarPercentage : 0) - (rightPanelContent ? rightSidebarPercentage : 0);
6529
- return /* @__PURE__ */ React48.createElement(
6618
+ return /* @__PURE__ */ React49.createElement(
6530
6619
  "div",
6531
6620
  {
6532
6621
  id,
@@ -6538,7 +6627,7 @@ var WorkspaceLayout = forwardRef19(function WorkspaceLayout2({
6538
6627
  ...style3
6539
6628
  }
6540
6629
  },
6541
- /* @__PURE__ */ React48.createElement(
6630
+ /* @__PURE__ */ React49.createElement(
6542
6631
  PanelGroup,
6543
6632
  {
6544
6633
  ref: panelGroupRef,
@@ -6547,7 +6636,7 @@ var WorkspaceLayout = forwardRef19(function WorkspaceLayout2({
6547
6636
  autoSaveId: autoSavePrefix ? `${autoSavePrefix}--${EDITOR_PANEL_GROUP_ID}` : void 0,
6548
6637
  style: { flex: "1" }
6549
6638
  },
6550
- hasLeftSidebar && /* @__PURE__ */ React48.createElement(React48.Fragment, null, /* @__PURE__ */ React48.createElement(
6639
+ hasLeftSidebar && /* @__PURE__ */ React49.createElement(React49.Fragment, null, /* @__PURE__ */ React49.createElement(
6551
6640
  Panel,
6552
6641
  {
6553
6642
  id: LEFT_SIDEBAR_ID,
@@ -6564,7 +6653,7 @@ var WorkspaceLayout = forwardRef19(function WorkspaceLayout2({
6564
6653
  }
6565
6654
  },
6566
6655
  leftPanelContent
6567
- ), /* @__PURE__ */ React48.createElement(
6656
+ ), /* @__PURE__ */ React49.createElement(
6568
6657
  PanelResizeHandle,
6569
6658
  {
6570
6659
  style: {
@@ -6575,7 +6664,7 @@ var WorkspaceLayout = forwardRef19(function WorkspaceLayout2({
6575
6664
  }
6576
6665
  }
6577
6666
  )),
6578
- /* @__PURE__ */ React48.createElement(
6667
+ /* @__PURE__ */ React49.createElement(
6579
6668
  Panel,
6580
6669
  {
6581
6670
  id: CONTENT_AREA_ID,
@@ -6590,7 +6679,7 @@ var WorkspaceLayout = forwardRef19(function WorkspaceLayout2({
6590
6679
  },
6591
6680
  centerPanelContent
6592
6681
  ),
6593
- hasRightSidebar && /* @__PURE__ */ React48.createElement(React48.Fragment, null, /* @__PURE__ */ React48.createElement(
6682
+ hasRightSidebar && /* @__PURE__ */ React49.createElement(React49.Fragment, null, /* @__PURE__ */ React49.createElement(
6594
6683
  PanelResizeHandle,
6595
6684
  {
6596
6685
  style: {
@@ -6600,7 +6689,7 @@ var WorkspaceLayout = forwardRef19(function WorkspaceLayout2({
6600
6689
  backgroundColor: theme.colors.divider
6601
6690
  }
6602
6691
  }
6603
- ), /* @__PURE__ */ React48.createElement(
6692
+ ), /* @__PURE__ */ React49.createElement(
6604
6693
  Panel,
6605
6694
  {
6606
6695
  id: RIGHT_SIDEBAR_ID,
@@ -6663,7 +6752,7 @@ var SUPPORTED_CANVAS_UPLOAD_TYPES = [
6663
6752
 
6664
6753
  // src/components/ArrayController.tsx
6665
6754
  import { range as range2 } from "@noya-app/noya-utils";
6666
- import React50, { memo as memo32, useCallback as useCallback26, useMemo as useMemo24 } from "react";
6755
+ import React51, { memo as memo32, useCallback as useCallback26, useMemo as useMemo24 } from "react";
6667
6756
  import styled35, { useTheme as useTheme5 } from "styled-components";
6668
6757
 
6669
6758
  // src/components/InspectorPrimitives.tsx
@@ -6682,7 +6771,7 @@ __export(InspectorPrimitives_exports, {
6682
6771
  Title: () => Title3,
6683
6772
  VerticalSeparator: () => VerticalSeparator
6684
6773
  });
6685
- import React49, { memo as memo31 } from "react";
6774
+ import React50, { memo as memo31 } from "react";
6686
6775
  import styled34, { useTheme as useTheme4 } from "styled-components";
6687
6776
  var Section = styled34.div(({ theme, $padding = "10px", $gap }) => ({
6688
6777
  flex: "0 0 auto",
@@ -6729,8 +6818,8 @@ var Checkbox = styled34.input(({ theme }) => ({
6729
6818
  var Text3 = styled34.span(({ theme }) => ({
6730
6819
  ...theme.textStyles.small
6731
6820
  }));
6732
- var VerticalSeparator = () => /* @__PURE__ */ React49.createElement(Spacer.Vertical, { size: useTheme4().sizes.inspector.verticalSeparator });
6733
- var HorizontalSeparator = () => /* @__PURE__ */ React49.createElement(Spacer.Horizontal, { size: useTheme4().sizes.inspector.horizontalSeparator });
6821
+ var VerticalSeparator = () => /* @__PURE__ */ React50.createElement(Spacer.Vertical, { size: useTheme4().sizes.inspector.verticalSeparator });
6822
+ var HorizontalSeparator = () => /* @__PURE__ */ React50.createElement(Spacer.Horizontal, { size: useTheme4().sizes.inspector.horizontalSeparator });
6734
6823
  var SliderRowLabel = styled34.span(({ theme }) => ({
6735
6824
  ...theme.textStyles.small,
6736
6825
  color: theme.colors.textMuted,
@@ -6758,13 +6847,13 @@ var LabeledRow = memo31(function LabeledRow2({
6758
6847
  gap,
6759
6848
  right
6760
6849
  }) {
6761
- return /* @__PURE__ */ React49.createElement(Row2, { id }, /* @__PURE__ */ React49.createElement(Column, null, /* @__PURE__ */ React49.createElement(RowLabel, { $textStyle: labelTextStyle }, label, right && /* @__PURE__ */ React49.createElement(Spacer.Horizontal, null), right), /* @__PURE__ */ React49.createElement(Row2, { $gap: gap }, children)));
6850
+ return /* @__PURE__ */ React50.createElement(Row2, { id }, /* @__PURE__ */ React50.createElement(Column, null, /* @__PURE__ */ React50.createElement(RowLabel, { $textStyle: labelTextStyle }, label, right && /* @__PURE__ */ React50.createElement(Spacer.Horizontal, null), right), /* @__PURE__ */ React50.createElement(Row2, { $gap: gap }, children)));
6762
6851
  });
6763
6852
  var LabeledSliderRow = memo31(function LabeledRow3({
6764
6853
  children,
6765
6854
  label
6766
6855
  }) {
6767
- return /* @__PURE__ */ React49.createElement(Row2, null, /* @__PURE__ */ React49.createElement(Column, null, /* @__PURE__ */ React49.createElement(SliderRowLabel, null, label), /* @__PURE__ */ React49.createElement(Row2, null, children)));
6856
+ return /* @__PURE__ */ React50.createElement(Row2, null, /* @__PURE__ */ React50.createElement(Column, null, /* @__PURE__ */ React50.createElement(SliderRowLabel, null, label), /* @__PURE__ */ React50.createElement(Row2, null, children)));
6768
6857
  });
6769
6858
 
6770
6859
  // src/components/ArrayController.tsx
@@ -6817,11 +6906,11 @@ var ArrayController = memo32(function ArrayController2({
6817
6906
  [onMoveItem, reversed]
6818
6907
  );
6819
6908
  const renderRow = (index) => {
6820
- return /* @__PURE__ */ React50.createElement(ElementRow, { key: keys[index] }, renderItem({ item: items[index], index }));
6909
+ return /* @__PURE__ */ React51.createElement(ElementRow, { key: keys[index] }, renderItem({ item: items[index], index }));
6821
6910
  };
6822
- return /* @__PURE__ */ React50.createElement(Section, { id, $padding: padding, $gap: "2px" }, /* @__PURE__ */ React50.createElement(SectionHeader, null, /* @__PURE__ */ React50.createElement(Button, { variant: "none", onClick: onClickPlus }, /* @__PURE__ */ React50.createElement(Title3, null, title)), /* @__PURE__ */ React50.createElement(Spacer.Horizontal, null), withSeparatorElements(
6911
+ return /* @__PURE__ */ React51.createElement(Section, { id, $padding: padding, $gap: "2px" }, /* @__PURE__ */ React51.createElement(SectionHeader, null, /* @__PURE__ */ React51.createElement(Button, { variant: "none", onClick: onClickPlus }, /* @__PURE__ */ React51.createElement(Title3, null, title)), /* @__PURE__ */ React51.createElement(Spacer.Horizontal, null), withSeparatorElements(
6823
6912
  [
6824
- onClickTrash && /* @__PURE__ */ React50.createElement(
6913
+ onClickTrash && /* @__PURE__ */ React51.createElement(
6825
6914
  IconButton,
6826
6915
  {
6827
6916
  id: `${id}-trash`,
@@ -6830,7 +6919,7 @@ var ArrayController = memo32(function ArrayController2({
6830
6919
  onClick: onClickTrash
6831
6920
  }
6832
6921
  ),
6833
- onClickExpand && /* @__PURE__ */ React50.createElement(
6922
+ onClickExpand && /* @__PURE__ */ React51.createElement(
6834
6923
  IconButton,
6835
6924
  {
6836
6925
  id: `${id}-gear`,
@@ -6839,7 +6928,7 @@ var ArrayController = memo32(function ArrayController2({
6839
6928
  onClick: onClickExpand
6840
6929
  }
6841
6930
  ),
6842
- onClickPlus && /* @__PURE__ */ React50.createElement(
6931
+ onClickPlus && /* @__PURE__ */ React51.createElement(
6843
6932
  IconButton,
6844
6933
  {
6845
6934
  id: `${id}-add`,
@@ -6849,15 +6938,15 @@ var ArrayController = memo32(function ArrayController2({
6849
6938
  }
6850
6939
  )
6851
6940
  ],
6852
- /* @__PURE__ */ React50.createElement(Spacer.Horizontal, { size: 8 })
6853
- )), /* @__PURE__ */ React50.createElement(Stack.V, { gap: "4px" }, sortable ? /* @__PURE__ */ React50.createElement(
6941
+ /* @__PURE__ */ React51.createElement(Spacer.Horizontal, { size: 8 })
6942
+ )), /* @__PURE__ */ React51.createElement(Stack.V, { gap: "4px" }, sortable ? /* @__PURE__ */ React51.createElement(
6854
6943
  Sortable.Root,
6855
6944
  {
6856
6945
  keys,
6857
6946
  renderOverlay: renderRow,
6858
6947
  onMoveItem: handleMoveItem
6859
6948
  },
6860
- indexes.map((index) => /* @__PURE__ */ React50.createElement(Sortable.Item, { id: keys[index], key: keys[index] }, ({ relativeDropPosition, ...sortableProps }) => /* @__PURE__ */ React50.createElement(ItemContainer2, { ...sortableProps }, renderRow(index), relativeDropPosition && /* @__PURE__ */ React50.createElement(
6949
+ indexes.map((index) => /* @__PURE__ */ React51.createElement(Sortable.Item, { id: keys[index], key: keys[index] }, ({ relativeDropPosition, ...sortableProps }) => /* @__PURE__ */ React51.createElement(ItemContainer2, { ...sortableProps }, renderRow(index), relativeDropPosition && /* @__PURE__ */ React51.createElement(
6861
6950
  ListView.DragIndicator,
6862
6951
  {
6863
6952
  $gap: 0,
@@ -6871,7 +6960,7 @@ var ArrayController = memo32(function ArrayController2({
6871
6960
 
6872
6961
  // src/components/DimensionInput.tsx
6873
6962
  import { round } from "@noya-app/noya-utils";
6874
- import React51, { memo as memo33, useCallback as useCallback27 } from "react";
6963
+ import React52, { memo as memo33, useCallback as useCallback27 } from "react";
6875
6964
  function getNewValue(value, mode, delta) {
6876
6965
  return delta === void 0 ? value : mode === "replace" ? delta : value + delta;
6877
6966
  }
@@ -6893,7 +6982,7 @@ var DimensionInput = memo33(function DimensionInput2({
6893
6982
  (value2) => onSetValue(value2, "replace"),
6894
6983
  [onSetValue]
6895
6984
  );
6896
- return /* @__PURE__ */ React51.createElement(InputField.Root, { id, width: size2 }, /* @__PURE__ */ React51.createElement(
6985
+ return /* @__PURE__ */ React52.createElement(InputField.Root, { id, width: size2 }, /* @__PURE__ */ React52.createElement(
6897
6986
  InputField.NumberInput,
6898
6987
  {
6899
6988
  value: value === void 0 ? value : round(value, 2),
@@ -6902,7 +6991,7 @@ var DimensionInput = memo33(function DimensionInput2({
6902
6991
  disabled,
6903
6992
  ...trigger === "change" ? { onChange: handleSetValue } : { onSubmit: handleSetValue }
6904
6993
  }
6905
- ), label && /* @__PURE__ */ React51.createElement(InputField.Label, null, label));
6994
+ ), label && /* @__PURE__ */ React52.createElement(InputField.Label, null, label));
6906
6995
  });
6907
6996
  export {
6908
6997
  ActivityIndicator,