simvyn 2.2.0 → 2.5.1

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.
@@ -16001,18 +16001,18 @@ function composeEventHandlers(originalEventHandler, ourEventHandler, { checkForD
16001
16001
  }
16002
16002
  };
16003
16003
  }
16004
- function setRef(ref, value) {
16004
+ function setRef$1(ref, value) {
16005
16005
  if (typeof ref === "function") {
16006
16006
  return ref(value);
16007
16007
  } else if (ref !== null && ref !== void 0) {
16008
16008
  ref.current = value;
16009
16009
  }
16010
16010
  }
16011
- function composeRefs(...refs) {
16011
+ function composeRefs$1(...refs) {
16012
16012
  return (node) => {
16013
16013
  let hasCleanup = false;
16014
16014
  const cleanups = refs.map((ref) => {
16015
- const cleanup = setRef(ref, node);
16015
+ const cleanup = setRef$1(ref, node);
16016
16016
  if (!hasCleanup && typeof cleanup == "function") {
16017
16017
  hasCleanup = true;
16018
16018
  }
@@ -16025,15 +16025,15 @@ function composeRefs(...refs) {
16025
16025
  if (typeof cleanup == "function") {
16026
16026
  cleanup();
16027
16027
  } else {
16028
- setRef(refs[i], null);
16028
+ setRef$1(refs[i], null);
16029
16029
  }
16030
16030
  }
16031
16031
  };
16032
16032
  }
16033
16033
  };
16034
16034
  }
16035
- function useComposedRefs(...refs) {
16036
- return reactExports.useCallback(composeRefs(...refs), refs);
16035
+ function useComposedRefs$1(...refs) {
16036
+ return reactExports.useCallback(composeRefs$1(...refs), refs);
16037
16037
  }
16038
16038
  function createContext2(rootComponentName, defaultContext) {
16039
16039
  const Context = reactExports.createContext(defaultContext);
@@ -16215,7 +16215,7 @@ function createSlotClone$1(ownerName) {
16215
16215
  const childrenRef = getElementRef$2(children);
16216
16216
  const props2 = mergeProps$1(slotProps, children.props);
16217
16217
  if (children.type !== reactExports.Fragment) {
16218
- props2.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;
16218
+ props2.ref = forwardedRef ? composeRefs$1(forwardedRef, childrenRef) : childrenRef;
16219
16219
  }
16220
16220
  return reactExports.cloneElement(children, props2);
16221
16221
  }
@@ -16344,7 +16344,7 @@ var DismissableLayer = reactExports.forwardRef(
16344
16344
  const [node, setNode] = reactExports.useState(null);
16345
16345
  const ownerDocument = node?.ownerDocument ?? globalThis?.document;
16346
16346
  const [, force] = reactExports.useState({});
16347
- const composedRefs = useComposedRefs(forwardedRef, (node2) => setNode(node2));
16347
+ const composedRefs = useComposedRefs$1(forwardedRef, (node2) => setNode(node2));
16348
16348
  const layers = Array.from(context.layers);
16349
16349
  const [highestLayerWithOutsidePointerEventsDisabled] = [...context.layersWithOutsidePointerEventsDisabled].slice(-1);
16350
16350
  const highestLayerWithOutsidePointerEventsDisabledIndex = layers.indexOf(highestLayerWithOutsidePointerEventsDisabled);
@@ -16430,7 +16430,7 @@ var BRANCH_NAME = "DismissableLayerBranch";
16430
16430
  var DismissableLayerBranch = reactExports.forwardRef((props, forwardedRef) => {
16431
16431
  const context = reactExports.useContext(DismissableLayerContext);
16432
16432
  const ref = reactExports.useRef(null);
16433
- const composedRefs = useComposedRefs(forwardedRef, ref);
16433
+ const composedRefs = useComposedRefs$1(forwardedRef, ref);
16434
16434
  reactExports.useEffect(() => {
16435
16435
  const node = ref.current;
16436
16436
  if (node) {
@@ -16568,7 +16568,7 @@ var FocusScope = reactExports.forwardRef((props, forwardedRef) => {
16568
16568
  const onMountAutoFocus = useCallbackRef$1(onMountAutoFocusProp);
16569
16569
  const onUnmountAutoFocus = useCallbackRef$1(onUnmountAutoFocusProp);
16570
16570
  const lastFocusedElementRef = reactExports.useRef(null);
16571
- const composedRefs = useComposedRefs(forwardedRef, (node) => setContainer(node));
16571
+ const composedRefs = useComposedRefs$1(forwardedRef, (node) => setContainer(node));
16572
16572
  const focusScope = reactExports.useRef({
16573
16573
  paused: false,
16574
16574
  pause() {
@@ -16802,7 +16802,7 @@ var Presence = (props) => {
16802
16802
  const { present, children } = props;
16803
16803
  const presence = usePresence$1(present);
16804
16804
  const child = typeof children === "function" ? children({ present: presence.isPresent }) : reactExports.Children.only(children);
16805
- const ref = useComposedRefs(presence.ref, getElementRef$1(child));
16805
+ const ref = useComposedRefs$1(presence.ref, getElementRef$1(child));
16806
16806
  const forceMount = typeof children === "function";
16807
16807
  return forceMount || presence.isPresent ? reactExports.cloneElement(child, { ref }) : null;
16808
16808
  };
@@ -17793,7 +17793,7 @@ var DialogTrigger = reactExports.forwardRef(
17793
17793
  (props, forwardedRef) => {
17794
17794
  const { __scopeDialog, ...triggerProps } = props;
17795
17795
  const context = useDialogContext(TRIGGER_NAME, __scopeDialog);
17796
- const composedTriggerRef = useComposedRefs(forwardedRef, context.triggerRef);
17796
+ const composedTriggerRef = useComposedRefs$1(forwardedRef, context.triggerRef);
17797
17797
  return /* @__PURE__ */ jsxRuntimeExports.jsx(
17798
17798
  Primitive$1.button,
17799
17799
  {
@@ -17864,7 +17864,7 @@ var DialogContentModal = reactExports.forwardRef(
17864
17864
  (props, forwardedRef) => {
17865
17865
  const context = useDialogContext(CONTENT_NAME, props.__scopeDialog);
17866
17866
  const contentRef = reactExports.useRef(null);
17867
- const composedRefs = useComposedRefs(forwardedRef, context.contentRef, contentRef);
17867
+ const composedRefs = useComposedRefs$1(forwardedRef, context.contentRef, contentRef);
17868
17868
  reactExports.useEffect(() => {
17869
17869
  const content = contentRef.current;
17870
17870
  if (content) return hideOthers(content);
@@ -17939,7 +17939,7 @@ var DialogContentImpl = reactExports.forwardRef(
17939
17939
  const { __scopeDialog, trapFocus, onOpenAutoFocus, onCloseAutoFocus, ...contentProps } = props;
17940
17940
  const context = useDialogContext(CONTENT_NAME, __scopeDialog);
17941
17941
  const contentRef = reactExports.useRef(null);
17942
- const composedRefs = useComposedRefs(forwardedRef, contentRef);
17942
+ const composedRefs = useComposedRefs$1(forwardedRef, contentRef);
17943
17943
  useFocusGuards();
17944
17944
  return /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
17945
17945
  /* @__PURE__ */ jsxRuntimeExports.jsx(
@@ -18094,7 +18094,7 @@ function createSlotClone(ownerName) {
18094
18094
  const childrenRef = getElementRef(children);
18095
18095
  const props2 = mergeProps(slotProps, children.props);
18096
18096
  if (children.type !== reactExports.Fragment) {
18097
- props2.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;
18097
+ props2.ref = forwardedRef ? composeRefs$1(forwardedRef, childrenRef) : childrenRef;
18098
18098
  }
18099
18099
  return reactExports.cloneElement(children, props2);
18100
18100
  }
@@ -18371,15 +18371,15 @@ var N = '[cmdk-group=""]', Y$1 = '[cmdk-group-items=""]', be$1 = '[cmdk-group-he
18371
18371
  }
18372
18372
  if (!x2) return null;
18373
18373
  let { disabled: A2, value: ge, onSelect: j, forceMount: O, keywords: $2, ...q } = r;
18374
- return reactExports.createElement(Primitive.div, { ref: composeRefs(u2, o), ...q, id: n, "cmdk-item": "", role: "option", "aria-disabled": !!A2, "aria-selected": !!R, "data-disabled": !!A2, "data-selected": !!R, onPointerMove: A2 || d.getDisablePointerSelection() ? void 0 : S, onClick: A2 ? void 0 : C2 }, r.children);
18374
+ return reactExports.createElement(Primitive.div, { ref: composeRefs$1(u2, o), ...q, id: n, "cmdk-item": "", role: "option", "aria-disabled": !!A2, "aria-selected": !!R, "data-disabled": !!A2, "data-selected": !!R, onPointerMove: A2 || d.getDisablePointerSelection() ? void 0 : S, onClick: A2 ? void 0 : C2 }, r.children);
18375
18375
  }), Ee$1 = reactExports.forwardRef((r, o) => {
18376
18376
  let { heading: n, children: u2, forceMount: c, ...d } = r, f = useId(), p2 = reactExports.useRef(null), b = reactExports.useRef(null), m2 = useId(), R = K$1(), x2 = P$1((S) => c || R.filter() === false ? true : S.search ? S.filtered.groups.has(f) : true);
18377
18377
  k$1(() => R.group(f), []), ve$1(f, p2, [r.value, r.heading, b]);
18378
18378
  let C2 = reactExports.useMemo(() => ({ id: f, forceMount: c }), [c]);
18379
- return reactExports.createElement(Primitive.div, { ref: composeRefs(p2, o), ...d, "cmdk-group": "", role: "presentation", hidden: x2 ? void 0 : true }, n && reactExports.createElement("div", { ref: b, "cmdk-group-heading": "", "aria-hidden": true, id: m2 }, n), B(r, (S) => reactExports.createElement("div", { "cmdk-group-items": "", role: "group", "aria-labelledby": n ? m2 : void 0 }, reactExports.createElement(fe$1.Provider, { value: C2 }, S))));
18379
+ return reactExports.createElement(Primitive.div, { ref: composeRefs$1(p2, o), ...d, "cmdk-group": "", role: "presentation", hidden: x2 ? void 0 : true }, n && reactExports.createElement("div", { ref: b, "cmdk-group-heading": "", "aria-hidden": true, id: m2 }, n), B(r, (S) => reactExports.createElement("div", { "cmdk-group-items": "", role: "group", "aria-labelledby": n ? m2 : void 0 }, reactExports.createElement(fe$1.Provider, { value: C2 }, S))));
18380
18380
  }), ye$1 = reactExports.forwardRef((r, o) => {
18381
18381
  let { alwaysRender: n, ...u2 } = r, c = reactExports.useRef(null), d = P$1((f) => !f.search);
18382
- return !n && !d ? null : reactExports.createElement(Primitive.div, { ref: composeRefs(c, o), ...u2, "cmdk-separator": "", role: "separator" });
18382
+ return !n && !d ? null : reactExports.createElement(Primitive.div, { ref: composeRefs$1(c, o), ...u2, "cmdk-separator": "", role: "separator" });
18383
18383
  }), Se$1 = reactExports.forwardRef((r, o) => {
18384
18384
  let { onValueChange: n, ...u2 } = r, c = r.value != null, d = ee(), f = P$1((m2) => m2.search), p2 = P$1((m2) => m2.selectedItemId), b = K$1();
18385
18385
  return reactExports.useEffect(() => {
@@ -18401,7 +18401,7 @@ var N = '[cmdk-group=""]', Y$1 = '[cmdk-group-items=""]', be$1 = '[cmdk-group-he
18401
18401
  cancelAnimationFrame(x2), C2.unobserve(m2);
18402
18402
  };
18403
18403
  }
18404
- }, []), reactExports.createElement(Primitive.div, { ref: composeRefs(d, o), ...c, "cmdk-list": "", role: "listbox", tabIndex: -1, "aria-activedescendant": p2, "aria-label": u2, id: b.listId }, B(r, (m2) => reactExports.createElement("div", { ref: composeRefs(f, b.listInnerRef), "cmdk-list-sizer": "" }, m2)));
18404
+ }, []), reactExports.createElement(Primitive.div, { ref: composeRefs$1(d, o), ...c, "cmdk-list": "", role: "listbox", tabIndex: -1, "aria-activedescendant": p2, "aria-label": u2, id: b.listId }, B(r, (m2) => reactExports.createElement("div", { ref: composeRefs$1(f, b.listInnerRef), "cmdk-list-sizer": "" }, m2)));
18405
18405
  }), xe$1 = reactExports.forwardRef((r, o) => {
18406
18406
  let { open: n, onOpenChange: u2, overlayClassName: c, contentClassName: d, container: f, ...p2 } = r;
18407
18407
  return reactExports.createElement(Root, { open: n, onOpenChange: u2 }, reactExports.createElement(Portal, { container: f }, reactExports.createElement(Overlay, { "cmdk-overlay": "", className: c }), reactExports.createElement(Content, { "aria-label": r.label, "cmdk-dialog": "", className: d }, reactExports.createElement(me$1, { ref: o, ...p2 }))));
@@ -18544,27 +18544,27 @@ const createLucideIcon = (iconName, iconNode) => {
18544
18544
  Component.displayName = toPascalCase(iconName);
18545
18545
  return Component;
18546
18546
  };
18547
- const __iconNode$U = [
18547
+ const __iconNode$V = [
18548
18548
  ["path", { d: "M12 5v14", key: "s699le" }],
18549
18549
  ["path", { d: "m19 12-7 7-7-7", key: "1idqje" }]
18550
18550
  ];
18551
- const ArrowDown = createLucideIcon("arrow-down", __iconNode$U);
18552
- const __iconNode$T = [
18551
+ const ArrowDown = createLucideIcon("arrow-down", __iconNode$V);
18552
+ const __iconNode$U = [
18553
18553
  ["path", { d: "m12 19-7-7 7-7", key: "1l729n" }],
18554
18554
  ["path", { d: "M19 12H5", key: "x3x0zl" }]
18555
18555
  ];
18556
- const ArrowLeft = createLucideIcon("arrow-left", __iconNode$T);
18557
- const __iconNode$S = [
18556
+ const ArrowLeft = createLucideIcon("arrow-left", __iconNode$U);
18557
+ const __iconNode$T = [
18558
18558
  ["path", { d: "m5 12 7-7 7 7", key: "hav0vg" }],
18559
18559
  ["path", { d: "M12 19V5", key: "x0mq9r" }]
18560
18560
  ];
18561
- const ArrowUp = createLucideIcon("arrow-up", __iconNode$S);
18562
- const __iconNode$R = [
18561
+ const ArrowUp = createLucideIcon("arrow-up", __iconNode$T);
18562
+ const __iconNode$S = [
18563
18563
  ["path", { d: "M 22 14 L 22 10", key: "nqc4tb" }],
18564
18564
  ["rect", { x: "2", y: "6", width: "16", height: "12", rx: "2", key: "13zb55" }]
18565
18565
  ];
18566
- const Battery = createLucideIcon("battery", __iconNode$R);
18567
- const __iconNode$Q = [
18566
+ const Battery = createLucideIcon("battery", __iconNode$S);
18567
+ const __iconNode$R = [
18568
18568
  ["path", { d: "M12 20v-9", key: "1qisl0" }],
18569
18569
  ["path", { d: "M14 7a4 4 0 0 1 4 4v3a6 6 0 0 1-12 0v-3a4 4 0 0 1 4-4z", key: "uouzyp" }],
18570
18570
  ["path", { d: "M14.12 3.88 16 2", key: "qol33r" }],
@@ -18577,8 +18577,8 @@ const __iconNode$Q = [
18577
18577
  ["path", { d: "m8 2 1.88 1.88", key: "fmnt4t" }],
18578
18578
  ["path", { d: "M9 7.13V6a3 3 0 1 1 6 0v1.13", key: "1vgav8" }]
18579
18579
  ];
18580
- const Bug = createLucideIcon("bug", __iconNode$Q);
18581
- const __iconNode$P = [
18580
+ const Bug = createLucideIcon("bug", __iconNode$R);
18581
+ const __iconNode$Q = [
18582
18582
  [
18583
18583
  "path",
18584
18584
  {
@@ -18588,47 +18588,47 @@ const __iconNode$P = [
18588
18588
  ],
18589
18589
  ["circle", { cx: "12", cy: "13", r: "3", key: "1vg3eu" }]
18590
18590
  ];
18591
- const Camera = createLucideIcon("camera", __iconNode$P);
18592
- const __iconNode$O = [["path", { d: "M20 6 9 17l-5-5", key: "1gmf2c" }]];
18593
- const Check = createLucideIcon("check", __iconNode$O);
18594
- const __iconNode$N = [["path", { d: "m6 9 6 6 6-6", key: "qrunsl" }]];
18595
- const ChevronDown = createLucideIcon("chevron-down", __iconNode$N);
18596
- const __iconNode$M = [["path", { d: "m15 18-6-6 6-6", key: "1wnfg3" }]];
18597
- const ChevronLeft = createLucideIcon("chevron-left", __iconNode$M);
18598
- const __iconNode$L = [["path", { d: "m9 18 6-6-6-6", key: "mthhwq" }]];
18599
- const ChevronRight = createLucideIcon("chevron-right", __iconNode$L);
18600
- const __iconNode$K = [["path", { d: "m18 15-6-6-6 6", key: "153udz" }]];
18601
- const ChevronUp = createLucideIcon("chevron-up", __iconNode$K);
18602
- const __iconNode$J = [
18591
+ const Camera = createLucideIcon("camera", __iconNode$Q);
18592
+ const __iconNode$P = [["path", { d: "M20 6 9 17l-5-5", key: "1gmf2c" }]];
18593
+ const Check = createLucideIcon("check", __iconNode$P);
18594
+ const __iconNode$O = [["path", { d: "m6 9 6 6 6-6", key: "qrunsl" }]];
18595
+ const ChevronDown = createLucideIcon("chevron-down", __iconNode$O);
18596
+ const __iconNode$N = [["path", { d: "m15 18-6-6 6-6", key: "1wnfg3" }]];
18597
+ const ChevronLeft = createLucideIcon("chevron-left", __iconNode$N);
18598
+ const __iconNode$M = [["path", { d: "m9 18 6-6-6-6", key: "mthhwq" }]];
18599
+ const ChevronRight = createLucideIcon("chevron-right", __iconNode$M);
18600
+ const __iconNode$L = [["path", { d: "m18 15-6-6-6 6", key: "153udz" }]];
18601
+ const ChevronUp = createLucideIcon("chevron-up", __iconNode$L);
18602
+ const __iconNode$K = [
18603
18603
  ["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
18604
18604
  ["path", { d: "M12 6v6l4 2", key: "mmk7yg" }]
18605
18605
  ];
18606
- const Clock = createLucideIcon("clock", __iconNode$J);
18607
- const __iconNode$I = [
18606
+ const Clock = createLucideIcon("clock", __iconNode$K);
18607
+ const __iconNode$J = [
18608
18608
  ["line", { x1: "15", x2: "15", y1: "12", y2: "18", key: "1p7wdc" }],
18609
18609
  ["line", { x1: "12", x2: "18", y1: "15", y2: "15", key: "1nscbv" }],
18610
18610
  ["rect", { width: "14", height: "14", x: "8", y: "8", rx: "2", ry: "2", key: "17jyea" }],
18611
18611
  ["path", { d: "M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2", key: "zix9uf" }]
18612
18612
  ];
18613
- const CopyPlus = createLucideIcon("copy-plus", __iconNode$I);
18614
- const __iconNode$H = [
18613
+ const CopyPlus = createLucideIcon("copy-plus", __iconNode$J);
18614
+ const __iconNode$I = [
18615
18615
  ["rect", { width: "14", height: "14", x: "8", y: "8", rx: "2", ry: "2", key: "17jyea" }],
18616
18616
  ["path", { d: "M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2", key: "zix9uf" }]
18617
18617
  ];
18618
- const Copy = createLucideIcon("copy", __iconNode$H);
18619
- const __iconNode$G = [
18618
+ const Copy = createLucideIcon("copy", __iconNode$I);
18619
+ const __iconNode$H = [
18620
18620
  ["ellipse", { cx: "12", cy: "5", rx: "9", ry: "3", key: "msslwz" }],
18621
18621
  ["path", { d: "M3 5V19A9 3 0 0 0 21 19V5", key: "1wlel7" }],
18622
18622
  ["path", { d: "M3 12A9 3 0 0 0 21 12", key: "mv7ke4" }]
18623
18623
  ];
18624
- const Database = createLucideIcon("database", __iconNode$G);
18625
- const __iconNode$F = [
18624
+ const Database = createLucideIcon("database", __iconNode$H);
18625
+ const __iconNode$G = [
18626
18626
  ["path", { d: "M12 15V3", key: "m9g1x1" }],
18627
18627
  ["path", { d: "M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4", key: "ih7n3h" }],
18628
18628
  ["path", { d: "m7 10 5 5 5-5", key: "brsn70" }]
18629
18629
  ];
18630
- const Download = createLucideIcon("download", __iconNode$F);
18631
- const __iconNode$E = [
18630
+ const Download = createLucideIcon("download", __iconNode$G);
18631
+ const __iconNode$F = [
18632
18632
  [
18633
18633
  "path",
18634
18634
  {
@@ -18638,14 +18638,14 @@ const __iconNode$E = [
18638
18638
  ],
18639
18639
  ["path", { d: "m5.082 11.09 8.828 8.828", key: "1wx5vj" }]
18640
18640
  ];
18641
- const Eraser = createLucideIcon("eraser", __iconNode$E);
18642
- const __iconNode$D = [
18641
+ const Eraser = createLucideIcon("eraser", __iconNode$F);
18642
+ const __iconNode$E = [
18643
18643
  ["path", { d: "M15 3h6v6", key: "1q9fwt" }],
18644
18644
  ["path", { d: "M10 14 21 3", key: "gplh6r" }],
18645
18645
  ["path", { d: "M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6", key: "a6xqqp" }]
18646
18646
  ];
18647
- const ExternalLink = createLucideIcon("external-link", __iconNode$D);
18648
- const __iconNode$C = [
18647
+ const ExternalLink = createLucideIcon("external-link", __iconNode$E);
18648
+ const __iconNode$D = [
18649
18649
  [
18650
18650
  "path",
18651
18651
  {
@@ -18657,8 +18657,8 @@ const __iconNode$C = [
18657
18657
  ["path", { d: "M12 18v-6", key: "17g6i2" }],
18658
18658
  ["path", { d: "m9 15 3 3 3-3", key: "1npd3o" }]
18659
18659
  ];
18660
- const FileDown = createLucideIcon("file-down", __iconNode$C);
18661
- const __iconNode$B = [
18660
+ const FileDown = createLucideIcon("file-down", __iconNode$D);
18661
+ const __iconNode$C = [
18662
18662
  [
18663
18663
  "path",
18664
18664
  {
@@ -18671,8 +18671,8 @@ const __iconNode$B = [
18671
18671
  ["path", { d: "M16 13H8", key: "t4e002" }],
18672
18672
  ["path", { d: "M16 17H8", key: "z1uh3a" }]
18673
18673
  ];
18674
- const FileText = createLucideIcon("file-text", __iconNode$B);
18675
- const __iconNode$A = [
18674
+ const FileText = createLucideIcon("file-text", __iconNode$C);
18675
+ const __iconNode$B = [
18676
18676
  [
18677
18677
  "path",
18678
18678
  {
@@ -18682,8 +18682,8 @@ const __iconNode$A = [
18682
18682
  ],
18683
18683
  ["path", { d: "M14 2v5a1 1 0 0 0 1 1h5", key: "wfsgrz" }]
18684
18684
  ];
18685
- const File = createLucideIcon("file", __iconNode$A);
18686
- const __iconNode$z = [
18685
+ const File = createLucideIcon("file", __iconNode$B);
18686
+ const __iconNode$A = [
18687
18687
  [
18688
18688
  "path",
18689
18689
  {
@@ -18692,8 +18692,8 @@ const __iconNode$z = [
18692
18692
  }
18693
18693
  ]
18694
18694
  ];
18695
- const Folder = createLucideIcon("folder", __iconNode$z);
18696
- const __iconNode$y = [
18695
+ const Folder = createLucideIcon("folder", __iconNode$A);
18696
+ const __iconNode$z = [
18697
18697
  [
18698
18698
  "path",
18699
18699
  {
@@ -18703,14 +18703,14 @@ const __iconNode$y = [
18703
18703
  ],
18704
18704
  ["path", { d: "M9 18c-4.51 2-5-2-7-2", key: "9comsn" }]
18705
18705
  ];
18706
- const Github = createLucideIcon("github", __iconNode$y);
18707
- const __iconNode$x = [
18706
+ const Github = createLucideIcon("github", __iconNode$z);
18707
+ const __iconNode$y = [
18708
18708
  ["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
18709
18709
  ["path", { d: "M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20", key: "13o1zl" }],
18710
18710
  ["path", { d: "M2 12h20", key: "9i4pu4" }]
18711
18711
  ];
18712
- const Globe = createLucideIcon("globe", __iconNode$x);
18713
- const __iconNode$w = [
18712
+ const Globe = createLucideIcon("globe", __iconNode$y);
18713
+ const __iconNode$x = [
18714
18714
  ["circle", { cx: "9", cy: "12", r: "1", key: "1vctgf" }],
18715
18715
  ["circle", { cx: "9", cy: "5", r: "1", key: "hp0tcf" }],
18716
18716
  ["circle", { cx: "9", cy: "19", r: "1", key: "fkjjf6" }],
@@ -18718,8 +18718,8 @@ const __iconNode$w = [
18718
18718
  ["circle", { cx: "15", cy: "5", r: "1", key: "19l28e" }],
18719
18719
  ["circle", { cx: "15", cy: "19", r: "1", key: "f4zoj3" }]
18720
18720
  ];
18721
- const GripVertical = createLucideIcon("grip-vertical", __iconNode$w);
18722
- const __iconNode$v = [
18721
+ const GripVertical = createLucideIcon("grip-vertical", __iconNode$x);
18722
+ const __iconNode$w = [
18723
18723
  [
18724
18724
  "path",
18725
18725
  {
@@ -18728,8 +18728,8 @@ const __iconNode$v = [
18728
18728
  }
18729
18729
  ]
18730
18730
  ];
18731
- const Heart = createLucideIcon("heart", __iconNode$v);
18732
- const __iconNode$u = [
18731
+ const Heart = createLucideIcon("heart", __iconNode$w);
18732
+ const __iconNode$v = [
18733
18733
  ["path", { d: "M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8", key: "5wwlr5" }],
18734
18734
  [
18735
18735
  "path",
@@ -18739,8 +18739,8 @@ const __iconNode$u = [
18739
18739
  }
18740
18740
  ]
18741
18741
  ];
18742
- const House = createLucideIcon("house", __iconNode$u);
18743
- const __iconNode$t = [
18742
+ const House = createLucideIcon("house", __iconNode$v);
18743
+ const __iconNode$u = [
18744
18744
  [
18745
18745
  "path",
18746
18746
  {
@@ -18763,15 +18763,15 @@ const __iconNode$t = [
18763
18763
  }
18764
18764
  ]
18765
18765
  ];
18766
- const Layers = createLucideIcon("layers", __iconNode$t);
18767
- const __iconNode$s = [
18766
+ const Layers = createLucideIcon("layers", __iconNode$u);
18767
+ const __iconNode$t = [
18768
18768
  ["path", { d: "M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71", key: "1cjeqo" }],
18769
18769
  ["path", { d: "M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71", key: "19qd67" }]
18770
18770
  ];
18771
- const Link = createLucideIcon("link", __iconNode$s);
18772
- const __iconNode$r = [["path", { d: "M21 12a9 9 0 1 1-6.219-8.56", key: "13zald" }]];
18773
- const LoaderCircle = createLucideIcon("loader-circle", __iconNode$r);
18774
- const __iconNode$q = [
18771
+ const Link = createLucideIcon("link", __iconNode$t);
18772
+ const __iconNode$s = [["path", { d: "M21 12a9 9 0 1 1-6.219-8.56", key: "13zald" }]];
18773
+ const LoaderCircle = createLucideIcon("loader-circle", __iconNode$s);
18774
+ const __iconNode$r = [
18775
18775
  [
18776
18776
  "path",
18777
18777
  {
@@ -18781,14 +18781,14 @@ const __iconNode$q = [
18781
18781
  ],
18782
18782
  ["circle", { cx: "12", cy: "10", r: "3", key: "ilqhr7" }]
18783
18783
  ];
18784
- const MapPin = createLucideIcon("map-pin", __iconNode$q);
18785
- const __iconNode$p = [
18784
+ const MapPin = createLucideIcon("map-pin", __iconNode$r);
18785
+ const __iconNode$q = [
18786
18786
  ["rect", { width: "20", height: "14", x: "2", y: "3", rx: "2", key: "48i651" }],
18787
18787
  ["line", { x1: "8", x2: "16", y1: "21", y2: "21", key: "1svkeh" }],
18788
18788
  ["line", { x1: "12", x2: "12", y1: "17", y2: "21", key: "vw1qmm" }]
18789
18789
  ];
18790
- const Monitor = createLucideIcon("monitor", __iconNode$p);
18791
- const __iconNode$o = [
18790
+ const Monitor = createLucideIcon("monitor", __iconNode$q);
18791
+ const __iconNode$p = [
18792
18792
  [
18793
18793
  "path",
18794
18794
  {
@@ -18797,8 +18797,8 @@ const __iconNode$o = [
18797
18797
  }
18798
18798
  ]
18799
18799
  ];
18800
- const Moon = createLucideIcon("moon", __iconNode$o);
18801
- const __iconNode$n = [
18800
+ const Moon = createLucideIcon("moon", __iconNode$p);
18801
+ const __iconNode$o = [
18802
18802
  ["path", { d: "M12.586 12.586 19 19", key: "ea5xo7" }],
18803
18803
  [
18804
18804
  "path",
@@ -18808,15 +18808,20 @@ const __iconNode$n = [
18808
18808
  }
18809
18809
  ]
18810
18810
  ];
18811
- const MousePointer = createLucideIcon("mouse-pointer", __iconNode$n);
18812
- const __iconNode$m = [
18811
+ const MousePointer = createLucideIcon("mouse-pointer", __iconNode$o);
18812
+ const __iconNode$n = [
18813
18813
  ["rect", { x: "16", y: "16", width: "6", height: "6", rx: "1", key: "4q2zg0" }],
18814
18814
  ["rect", { x: "2", y: "16", width: "6", height: "6", rx: "1", key: "8cvhb9" }],
18815
18815
  ["rect", { x: "9", y: "2", width: "6", height: "6", rx: "1", key: "1egb70" }],
18816
18816
  ["path", { d: "M5 16v-3a1 1 0 0 1 1-1h12a1 1 0 0 1 1 1v3", key: "1jsf9p" }],
18817
18817
  ["path", { d: "M12 12V8", key: "2874zd" }]
18818
18818
  ];
18819
- const Network = createLucideIcon("network", __iconNode$m);
18819
+ const Network = createLucideIcon("network", __iconNode$n);
18820
+ const __iconNode$m = [
18821
+ ["rect", { x: "14", y: "3", width: "5", height: "18", rx: "1", key: "kaeet6" }],
18822
+ ["rect", { x: "5", y: "3", width: "5", height: "18", rx: "1", key: "1wsw3u" }]
18823
+ ];
18824
+ const Pause = createLucideIcon("pause", __iconNode$m);
18820
18825
  const __iconNode$l = [
18821
18826
  [
18822
18827
  "path",
@@ -27908,6 +27913,151 @@ const MotionConfigContext = reactExports.createContext({
27908
27913
  isStatic: false,
27909
27914
  reducedMotion: "never"
27910
27915
  });
27916
+ function setRef(ref, value) {
27917
+ if (typeof ref === "function") {
27918
+ return ref(value);
27919
+ } else if (ref !== null && ref !== void 0) {
27920
+ ref.current = value;
27921
+ }
27922
+ }
27923
+ function composeRefs(...refs) {
27924
+ return (node) => {
27925
+ let hasCleanup = false;
27926
+ const cleanups = refs.map((ref) => {
27927
+ const cleanup = setRef(ref, node);
27928
+ if (!hasCleanup && typeof cleanup === "function") {
27929
+ hasCleanup = true;
27930
+ }
27931
+ return cleanup;
27932
+ });
27933
+ if (hasCleanup) {
27934
+ return () => {
27935
+ for (let i = 0; i < cleanups.length; i++) {
27936
+ const cleanup = cleanups[i];
27937
+ if (typeof cleanup === "function") {
27938
+ cleanup();
27939
+ } else {
27940
+ setRef(refs[i], null);
27941
+ }
27942
+ }
27943
+ };
27944
+ }
27945
+ };
27946
+ }
27947
+ function useComposedRefs(...refs) {
27948
+ return reactExports.useCallback(composeRefs(...refs), refs);
27949
+ }
27950
+ class PopChildMeasure extends reactExports.Component {
27951
+ getSnapshotBeforeUpdate(prevProps) {
27952
+ const element = this.props.childRef.current;
27953
+ if (element && prevProps.isPresent && !this.props.isPresent && this.props.pop !== false) {
27954
+ const parent = element.offsetParent;
27955
+ const parentWidth = isHTMLElement(parent) ? parent.offsetWidth || 0 : 0;
27956
+ const parentHeight = isHTMLElement(parent) ? parent.offsetHeight || 0 : 0;
27957
+ const size = this.props.sizeRef.current;
27958
+ size.height = element.offsetHeight || 0;
27959
+ size.width = element.offsetWidth || 0;
27960
+ size.top = element.offsetTop;
27961
+ size.left = element.offsetLeft;
27962
+ size.right = parentWidth - size.width - size.left;
27963
+ size.bottom = parentHeight - size.height - size.top;
27964
+ }
27965
+ return null;
27966
+ }
27967
+ /**
27968
+ * Required with getSnapshotBeforeUpdate to stop React complaining.
27969
+ */
27970
+ componentDidUpdate() {
27971
+ }
27972
+ render() {
27973
+ return this.props.children;
27974
+ }
27975
+ }
27976
+ function PopChild({ children, isPresent, anchorX, anchorY, root, pop }) {
27977
+ const id2 = reactExports.useId();
27978
+ const ref = reactExports.useRef(null);
27979
+ const size = reactExports.useRef({
27980
+ width: 0,
27981
+ height: 0,
27982
+ top: 0,
27983
+ left: 0,
27984
+ right: 0,
27985
+ bottom: 0
27986
+ });
27987
+ const { nonce } = reactExports.useContext(MotionConfigContext);
27988
+ const childRef = children.props?.ref ?? children?.ref;
27989
+ const composedRef = useComposedRefs(ref, childRef);
27990
+ reactExports.useInsertionEffect(() => {
27991
+ const { width, height, top, left, right, bottom } = size.current;
27992
+ if (isPresent || pop === false || !ref.current || !width || !height)
27993
+ return;
27994
+ const x2 = anchorX === "left" ? `left: ${left}` : `right: ${right}`;
27995
+ const y = anchorY === "bottom" ? `bottom: ${bottom}` : `top: ${top}`;
27996
+ ref.current.dataset.motionPopId = id2;
27997
+ const style = document.createElement("style");
27998
+ if (nonce)
27999
+ style.nonce = nonce;
28000
+ const parent = root ?? document.head;
28001
+ parent.appendChild(style);
28002
+ if (style.sheet) {
28003
+ style.sheet.insertRule(`
28004
+ [data-motion-pop-id="${id2}"] {
28005
+ position: absolute !important;
28006
+ width: ${width}px !important;
28007
+ height: ${height}px !important;
28008
+ ${x2}px !important;
28009
+ ${y}px !important;
28010
+ }
28011
+ `);
28012
+ }
28013
+ return () => {
28014
+ if (parent.contains(style)) {
28015
+ parent.removeChild(style);
28016
+ }
28017
+ };
28018
+ }, [isPresent]);
28019
+ return jsxRuntimeExports.jsx(PopChildMeasure, { isPresent, childRef: ref, sizeRef: size, pop, children: pop === false ? children : reactExports.cloneElement(children, { ref: composedRef }) });
28020
+ }
28021
+ const PresenceChild = ({ children, initial, isPresent, onExitComplete, custom, presenceAffectsLayout, mode, anchorX, anchorY, root }) => {
28022
+ const presenceChildren = useConstant(newChildrenMap);
28023
+ const id2 = reactExports.useId();
28024
+ let isReusedContext = true;
28025
+ let context = reactExports.useMemo(() => {
28026
+ isReusedContext = false;
28027
+ return {
28028
+ id: id2,
28029
+ initial,
28030
+ isPresent,
28031
+ custom,
28032
+ onExitComplete: (childId) => {
28033
+ presenceChildren.set(childId, true);
28034
+ for (const isComplete of presenceChildren.values()) {
28035
+ if (!isComplete)
28036
+ return;
28037
+ }
28038
+ onExitComplete && onExitComplete();
28039
+ },
28040
+ register: (childId) => {
28041
+ presenceChildren.set(childId, false);
28042
+ return () => presenceChildren.delete(childId);
28043
+ }
28044
+ };
28045
+ }, [isPresent, presenceChildren, onExitComplete]);
28046
+ if (presenceAffectsLayout && isReusedContext) {
28047
+ context = { ...context };
28048
+ }
28049
+ reactExports.useMemo(() => {
28050
+ presenceChildren.forEach((_, key) => presenceChildren.set(key, false));
28051
+ }, [isPresent]);
28052
+ reactExports.useEffect(() => {
28053
+ !isPresent && !presenceChildren.size && onExitComplete && onExitComplete();
28054
+ }, [isPresent]);
28055
+ children = jsxRuntimeExports.jsx(PopChild, { pop: mode === "popLayout", isPresent, anchorX, anchorY, root, children });
28056
+ return jsxRuntimeExports.jsx(PresenceContext.Provider, { value: context, children });
28057
+ };
28058
+ function newChildrenMap() {
28059
+ return /* @__PURE__ */ new Map();
28060
+ }
27911
28061
  function usePresence(subscribe = true) {
27912
28062
  const context = reactExports.useContext(PresenceContext);
27913
28063
  if (context === null)
@@ -27922,6 +28072,87 @@ function usePresence(subscribe = true) {
27922
28072
  const safeToRemove = reactExports.useCallback(() => subscribe && onExitComplete && onExitComplete(id2), [id2, onExitComplete, subscribe]);
27923
28073
  return !isPresent && onExitComplete ? [false, safeToRemove] : [true];
27924
28074
  }
28075
+ const getChildKey = (child) => child.key || "";
28076
+ function onlyElements(children) {
28077
+ const filtered = [];
28078
+ reactExports.Children.forEach(children, (child) => {
28079
+ if (reactExports.isValidElement(child))
28080
+ filtered.push(child);
28081
+ });
28082
+ return filtered;
28083
+ }
28084
+ const AnimatePresence = ({ children, custom, initial = true, onExitComplete, presenceAffectsLayout = true, mode = "sync", propagate = false, anchorX = "left", anchorY = "top", root }) => {
28085
+ const [isParentPresent, safeToRemove] = usePresence(propagate);
28086
+ const presentChildren = reactExports.useMemo(() => onlyElements(children), [children]);
28087
+ const presentKeys = propagate && !isParentPresent ? [] : presentChildren.map(getChildKey);
28088
+ const isInitialRender = reactExports.useRef(true);
28089
+ const pendingPresentChildren = reactExports.useRef(presentChildren);
28090
+ const exitComplete = useConstant(() => /* @__PURE__ */ new Map());
28091
+ const exitingComponents = reactExports.useRef(/* @__PURE__ */ new Set());
28092
+ const [diffedChildren, setDiffedChildren] = reactExports.useState(presentChildren);
28093
+ const [renderedChildren, setRenderedChildren] = reactExports.useState(presentChildren);
28094
+ useIsomorphicLayoutEffect(() => {
28095
+ isInitialRender.current = false;
28096
+ pendingPresentChildren.current = presentChildren;
28097
+ for (let i = 0; i < renderedChildren.length; i++) {
28098
+ const key = getChildKey(renderedChildren[i]);
28099
+ if (!presentKeys.includes(key)) {
28100
+ if (exitComplete.get(key) !== true) {
28101
+ exitComplete.set(key, false);
28102
+ }
28103
+ } else {
28104
+ exitComplete.delete(key);
28105
+ exitingComponents.current.delete(key);
28106
+ }
28107
+ }
28108
+ }, [renderedChildren, presentKeys.length, presentKeys.join("-")]);
28109
+ const exitingChildren = [];
28110
+ if (presentChildren !== diffedChildren) {
28111
+ let nextChildren = [...presentChildren];
28112
+ for (let i = 0; i < renderedChildren.length; i++) {
28113
+ const child = renderedChildren[i];
28114
+ const key = getChildKey(child);
28115
+ if (!presentKeys.includes(key)) {
28116
+ nextChildren.splice(i, 0, child);
28117
+ exitingChildren.push(child);
28118
+ }
28119
+ }
28120
+ if (mode === "wait" && exitingChildren.length) {
28121
+ nextChildren = exitingChildren;
28122
+ }
28123
+ setRenderedChildren(onlyElements(nextChildren));
28124
+ setDiffedChildren(presentChildren);
28125
+ return null;
28126
+ }
28127
+ const { forceRender } = reactExports.useContext(LayoutGroupContext);
28128
+ return jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment, { children: renderedChildren.map((child) => {
28129
+ const key = getChildKey(child);
28130
+ const isPresent = propagate && !isParentPresent ? false : presentChildren === renderedChildren || presentKeys.includes(key);
28131
+ const onExit = () => {
28132
+ if (exitingComponents.current.has(key)) {
28133
+ return;
28134
+ }
28135
+ exitingComponents.current.add(key);
28136
+ if (exitComplete.has(key)) {
28137
+ exitComplete.set(key, true);
28138
+ } else {
28139
+ return;
28140
+ }
28141
+ let isEveryExitComplete = true;
28142
+ exitComplete.forEach((isExitComplete) => {
28143
+ if (!isExitComplete)
28144
+ isEveryExitComplete = false;
28145
+ });
28146
+ if (isEveryExitComplete) {
28147
+ forceRender?.();
28148
+ setRenderedChildren(pendingPresentChildren.current);
28149
+ propagate && safeToRemove?.();
28150
+ onExitComplete && onExitComplete();
28151
+ }
28152
+ };
28153
+ return jsxRuntimeExports.jsx(PresenceChild, { isPresent, initial: !isInitialRender.current || initial ? void 0 : false, custom, presenceAffectsLayout, mode, root, onExitComplete: isPresent ? void 0 : onExit, anchorX, anchorY, children: child }, key);
28154
+ }) });
28155
+ };
27925
28156
  const LazyContext = reactExports.createContext({ strict: false });
27926
28157
  const featureProps = {
27927
28158
  animation: [
@@ -30049,40 +30280,62 @@ function ModuleShell() {
30049
30280
  );
30050
30281
  }) });
30051
30282
  }
30283
+ const COLLAPSED_WIDTH = 52;
30284
+ const EXPANDED_WIDTH = 172;
30285
+ const sidebarTransition = { type: "spring", stiffness: 400, damping: 30, mass: 0.8 };
30286
+ const labelTransition = { duration: 0.15, ease: "easeOut" };
30052
30287
  function Sidebar() {
30053
30288
  const modules = useModuleStore((s) => s.modules);
30054
30289
  const activeModule = useModuleStore((s) => s.activeModule);
30055
30290
  const navigate = useNavigate();
30056
- const [tooltip, setTooltip] = reactExports.useState(null);
30057
- const showTooltip = reactExports.useCallback((e, label) => {
30058
- const rect = e.currentTarget.getBoundingClientRect();
30059
- setTooltip({ label, top: rect.top + rect.height / 2, left: rect.right + 8 });
30060
- }, []);
30061
- const hideTooltip = reactExports.useCallback(() => setTooltip(null), []);
30062
- return /* @__PURE__ */ jsxRuntimeExports.jsxs("aside", { className: "dock-sidebar", children: [
30063
- modules.map((mod) => {
30064
- const isActive = activeModule === mod.name;
30065
- const Icon2 = moduleIconMap[mod.name];
30066
- const label = moduleLabelMap[mod.name] ?? mod.name;
30067
- return /* @__PURE__ */ jsxRuntimeExports.jsx(
30068
- "button",
30291
+ const [isHovered, setIsHovered] = reactExports.useState(false);
30292
+ return /* @__PURE__ */ jsxRuntimeExports.jsx(
30293
+ "div",
30294
+ {
30295
+ className: "dock-sidebar-hitarea",
30296
+ onMouseEnter: () => setIsHovered(true),
30297
+ onMouseLeave: () => setIsHovered(false),
30298
+ children: /* @__PURE__ */ jsxRuntimeExports.jsxs(
30299
+ motion.aside,
30069
30300
  {
30070
- type: "button",
30071
- onClick: () => navigate(`/${mod.name}`),
30072
- className: `dock-icon ${isActive ? "active" : ""}`,
30073
- onMouseEnter: (e) => showTooltip(e, label),
30074
- onMouseLeave: hideTooltip,
30075
- children: Icon2 ? /* @__PURE__ */ jsxRuntimeExports.jsx(Icon2, { size: 24 }) : /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-sm", children: mod.name[0]?.toUpperCase() })
30076
- },
30077
- mod.name
30078
- );
30079
- }),
30080
- modules.length === 0 && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-text-muted text-[10px] text-center px-1 py-4", children: "No modules" }),
30081
- tooltip && reactDomExports.createPortal(
30082
- /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "dock-tooltip-fixed", style: { top: tooltip.top, left: tooltip.left }, children: tooltip.label }),
30083
- document.body
30084
- )
30085
- ] });
30301
+ className: "dock-sidebar",
30302
+ animate: { width: isHovered ? EXPANDED_WIDTH : COLLAPSED_WIDTH },
30303
+ transition: sidebarTransition,
30304
+ children: [
30305
+ modules.map((mod) => {
30306
+ const isActive = activeModule === mod.name;
30307
+ const Icon2 = moduleIconMap[mod.name];
30308
+ const label = moduleLabelMap[mod.name] ?? mod.name;
30309
+ return /* @__PURE__ */ jsxRuntimeExports.jsxs(
30310
+ "button",
30311
+ {
30312
+ type: "button",
30313
+ onClick: () => navigate(`/${mod.name}`),
30314
+ className: `dock-icon ${isActive ? "active" : ""}`,
30315
+ children: [
30316
+ /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "dock-icon-svg", children: Icon2 ? /* @__PURE__ */ jsxRuntimeExports.jsx(Icon2, { size: 24 }) : /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-sm", children: mod.name[0]?.toUpperCase() }) }),
30317
+ /* @__PURE__ */ jsxRuntimeExports.jsx(AnimatePresence, { children: isHovered && /* @__PURE__ */ jsxRuntimeExports.jsx(
30318
+ motion.span,
30319
+ {
30320
+ className: "dock-label",
30321
+ initial: { opacity: 0, width: 0 },
30322
+ animate: { opacity: 1, width: "auto" },
30323
+ exit: { opacity: 0, width: 0 },
30324
+ transition: labelTransition,
30325
+ children: label
30326
+ }
30327
+ ) })
30328
+ ]
30329
+ },
30330
+ mod.name
30331
+ );
30332
+ }),
30333
+ modules.length === 0 && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-text-muted text-[10px] text-center px-1 py-4", children: "No modules" })
30334
+ ]
30335
+ }
30336
+ )
30337
+ }
30338
+ );
30086
30339
  }
30087
30340
  const WsContext = reactExports.createContext(null);
30088
30341
  const MAX_RETRIES = 10;
@@ -30497,6 +30750,63 @@ function TopBar() {
30497
30750
  ] })
30498
30751
  ] });
30499
30752
  }
30753
+ function UpdateBanner() {
30754
+ const [info, setInfo] = reactExports.useState(null);
30755
+ const [dismissed, setDismissed] = reactExports.useState(false);
30756
+ reactExports.useEffect(() => {
30757
+ if (sessionStorage.getItem("simvyn-update-dismissed")) return;
30758
+ fetch("/api/update-check").then((res) => res.json()).then((data) => {
30759
+ if (data.needsUpdate) setInfo(data);
30760
+ }).catch(() => {
30761
+ });
30762
+ }, []);
30763
+ if (!info || dismissed) return null;
30764
+ return /* @__PURE__ */ jsxRuntimeExports.jsxs(
30765
+ "div",
30766
+ {
30767
+ style: {
30768
+ background: "rgba(40, 40, 55, 0.50)",
30769
+ backdropFilter: "blur(20px) saturate(1.4)",
30770
+ WebkitBackdropFilter: "blur(20px) saturate(1.4)",
30771
+ border: "1px solid rgba(255, 255, 255, 0.08)",
30772
+ borderRadius: "12px"
30773
+ },
30774
+ className: "flex items-center justify-between px-4 py-2 mx-4 mt-2 text-sm",
30775
+ children: [
30776
+ /* @__PURE__ */ jsxRuntimeExports.jsxs("span", { children: [
30777
+ "Update available: ",
30778
+ /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-green-400", children: info.current }),
30779
+ /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-text-muted", children: " → " }),
30780
+ /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-green-400", children: info.latest })
30781
+ ] }),
30782
+ /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-3", children: [
30783
+ /* @__PURE__ */ jsxRuntimeExports.jsx(
30784
+ "a",
30785
+ {
30786
+ href: `https://github.com/pranshuchittora/simvyn/releases/tag/v${info.latest}`,
30787
+ target: "_blank",
30788
+ rel: "noopener noreferrer",
30789
+ className: "text-blue-400 hover:text-blue-300 underline",
30790
+ children: "View release →"
30791
+ }
30792
+ ),
30793
+ /* @__PURE__ */ jsxRuntimeExports.jsx(
30794
+ "button",
30795
+ {
30796
+ type: "button",
30797
+ onClick: () => {
30798
+ setDismissed(true);
30799
+ sessionStorage.setItem("simvyn-update-dismissed", "true");
30800
+ },
30801
+ className: "text-text-muted hover:text-text-primary",
30802
+ children: /* @__PURE__ */ jsxRuntimeExports.jsx(X$1, { size: 14 })
30803
+ }
30804
+ )
30805
+ ] })
30806
+ ]
30807
+ }
30808
+ );
30809
+ }
30500
30810
  function DevicePanel() {
30501
30811
  const devices = useDeviceStore((s) => s.devices);
30502
30812
  const setDevices = useDeviceStore((s) => s.setDevices);
@@ -47183,6 +47493,7 @@ const initialState = {
47183
47493
  isLoadingHistory: false,
47184
47494
  isStreaming: false,
47185
47495
  streamDeviceId: null,
47496
+ isPaused: false,
47186
47497
  enabledLevels: [...ALL_LEVELS],
47187
47498
  searchPattern: "",
47188
47499
  processFilter: ""
@@ -47190,6 +47501,7 @@ const initialState = {
47190
47501
  const useLogStore = create((set) => ({
47191
47502
  ...initialState,
47192
47503
  addNewBatch: (batch) => set((s) => {
47504
+ if (s.isPaused) return s;
47193
47505
  const newEntries = [...batch].reverse();
47194
47506
  const combined = [...newEntries, ...s.entries];
47195
47507
  const trimmed = combined.length > MAX_ENTRIES ? combined.slice(0, MAX_ENTRIES) : combined;
@@ -47211,10 +47523,13 @@ const useLogStore = create((set) => ({
47211
47523
  entries: [],
47212
47524
  firstItemIndex: INITIAL_INDEX,
47213
47525
  cursor: null,
47214
- hasMore: true
47526
+ hasMore: true,
47527
+ isPaused: false
47215
47528
  }),
47216
47529
  reset: () => set({ ...initialState }),
47217
47530
  setStreaming: (deviceId) => set({ streamDeviceId: deviceId, isStreaming: deviceId !== null }),
47531
+ pause: () => set({ isPaused: true }),
47532
+ resume: () => set({ isPaused: false }),
47218
47533
  toggleLevel: (level) => set((s) => {
47219
47534
  const has = s.enabledLevels.includes(level);
47220
47535
  if (has && s.enabledLevels.length === 1) return s;
@@ -47408,6 +47723,9 @@ function LogToolbar({ selectedDeviceId }) {
47408
47723
  const setSearchPattern = useLogStore((s) => s.setSearchPattern);
47409
47724
  const setProcessFilter = useLogStore((s) => s.setProcessFilter);
47410
47725
  const clear = useLogStore((s) => s.clear);
47726
+ const isPaused = useLogStore((s) => s.isPaused);
47727
+ const pause = useLogStore((s) => s.pause);
47728
+ const resume = useLogStore((s) => s.resume);
47411
47729
  const entries2 = useLogStore((s) => s.entries);
47412
47730
  const totalCount = entries2.length;
47413
47731
  const filteredCount = reactExports.useMemo(
@@ -47494,6 +47812,21 @@ function LogToolbar({ selectedDeviceId }) {
47494
47812
  /* @__PURE__ */ jsxRuntimeExports.jsx("button", { type: "button", onClick: () => handleExport("json"), className: "glass-button", children: "JSON" }),
47495
47813
  /* @__PURE__ */ jsxRuntimeExports.jsx("button", { type: "button", onClick: () => handleExport("text"), className: "glass-button", children: "TXT" })
47496
47814
  ] }),
47815
+ /* @__PURE__ */ jsxRuntimeExports.jsx(
47816
+ "button",
47817
+ {
47818
+ type: "button",
47819
+ onClick: isPaused ? resume : pause,
47820
+ className: "glass-button",
47821
+ style: isPaused ? {
47822
+ background: "rgba(234,179,8,0.2)",
47823
+ color: "#fde047",
47824
+ borderColor: "rgba(234,179,8,0.3)"
47825
+ } : void 0,
47826
+ title: isPaused ? "Resume log stream" : "Pause log stream",
47827
+ children: isPaused ? /* @__PURE__ */ jsxRuntimeExports.jsx(Play, { size: 14 }) : /* @__PURE__ */ jsxRuntimeExports.jsx(Pause, { size: 14 })
47828
+ }
47829
+ ),
47497
47830
  /* @__PURE__ */ jsxRuntimeExports.jsx(
47498
47831
  "button",
47499
47832
  {
@@ -47514,7 +47847,7 @@ function LogToolbar({ selectedDeviceId }) {
47514
47847
  children: "Clear"
47515
47848
  }
47516
47849
  ),
47517
- /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-xs text-text-muted ml-auto", children: filteredCount === totalCount ? `${totalCount} entries` : `${filteredCount} / ${totalCount} entries` })
47850
+ /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: `text-xs ml-auto ${isPaused ? "text-yellow-400" : "text-text-muted"}`, children: isPaused ? "Paused" : filteredCount === totalCount ? `${totalCount} entries` : `${filteredCount} / ${totalCount} entries` })
47518
47851
  ] });
47519
47852
  }
47520
47853
  function LogPanel() {
@@ -47527,6 +47860,7 @@ function LogPanel() {
47527
47860
  const clear = useLogStore((s) => s.clear);
47528
47861
  const reset = useLogStore((s) => s.reset);
47529
47862
  const setStreaming = useLogStore((s) => s.setStreaming);
47863
+ const isPaused = useLogStore((s) => s.isPaused);
47530
47864
  const hasMore = useLogStore((s) => s.hasMore);
47531
47865
  const isLoadingHistory = useLogStore((s) => s.isLoadingHistory);
47532
47866
  reactExports.useEffect(() => {
@@ -47556,6 +47890,7 @@ function LogPanel() {
47556
47890
  payload: { deviceId: prevDeviceRef.current }
47557
47891
  });
47558
47892
  clear();
47893
+ useLogStore.getState().resume();
47559
47894
  }
47560
47895
  if (selectedDeviceId) {
47561
47896
  send({
@@ -47580,6 +47915,19 @@ function LogPanel() {
47580
47915
  }
47581
47916
  };
47582
47917
  }, [selectedDeviceId, send, clear]);
47918
+ const wasPausedRef = reactExports.useRef(false);
47919
+ reactExports.useEffect(() => {
47920
+ const deviceId = selectedDeviceIdRef.current;
47921
+ if (!deviceId) return;
47922
+ if (isPaused) {
47923
+ send({ channel: "logs", type: "stop-stream", payload: { deviceId } });
47924
+ } else if (wasPausedRef.current) {
47925
+ clear();
47926
+ send({ channel: "logs", type: "start-stream", payload: { deviceId } });
47927
+ send({ channel: "logs", type: "get-history", payload: { deviceId, limit: 500 } });
47928
+ }
47929
+ wasPausedRef.current = isPaused;
47930
+ }, [isPaused, send, clear]);
47583
47931
  const loadMoreHistory = reactExports.useCallback(() => {
47584
47932
  if (!selectedDeviceId || !hasMore || isLoadingHistory) return;
47585
47933
  setLoadingHistory(true);
@@ -47615,7 +47963,9 @@ function LogPanel() {
47615
47963
  const handleStreamStarted = reactExports.useCallback(
47616
47964
  (payload) => {
47617
47965
  const data = payload;
47618
- setStreaming(data.deviceId);
47966
+ if (!useLogStore.getState().isPaused) {
47967
+ setStreaming(data.deviceId);
47968
+ }
47619
47969
  },
47620
47970
  [setStreaming]
47621
47971
  );
@@ -51692,7 +52042,7 @@ function ToolSettingsPanel() {
51692
52042
  const [copied, setCopied] = reactExports.useState(false);
51693
52043
  const devices = useDeviceStore((s) => s.devices);
51694
52044
  const modules = useModuleStore((s) => s.modules);
51695
- const version = "2.2.0";
52045
+ const version = "2.5.1";
51696
52046
  const fetchStorage = reactExports.useCallback(() => {
51697
52047
  fetch("/api/tool-settings/storage").then((r) => r.json()).then((data) => setStorage(data)).catch(() => {
51698
52048
  });
@@ -52999,6 +53349,7 @@ function AppContent() {
52999
53349
  /* @__PURE__ */ jsxRuntimeExports.jsx(RouterSync, {}),
53000
53350
  /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex h-screen flex-col bg-bg-base", children: [
53001
53351
  /* @__PURE__ */ jsxRuntimeExports.jsx(TopBar, {}),
53352
+ /* @__PURE__ */ jsxRuntimeExports.jsx(UpdateBanner, {}),
53002
53353
  /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex flex-1 overflow-hidden", children: [
53003
53354
  /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex items-center", children: /* @__PURE__ */ jsxRuntimeExports.jsx(Sidebar, {}) }),
53004
53355
  /* @__PURE__ */ jsxRuntimeExports.jsx(ModuleShell, {})
@@ -53040,4 +53391,4 @@ function App() {
53040
53391
  clientExports.createRoot(document.getElementById("root")).render(
53041
53392
  /* @__PURE__ */ jsxRuntimeExports.jsx(reactExports.StrictMode, { children: /* @__PURE__ */ jsxRuntimeExports.jsx(App, {}) })
53042
53393
  );
53043
- //# sourceMappingURL=index-B_mApJSj.js.map
53394
+ //# sourceMappingURL=index-D67XE6HO.js.map