@minimalstuff/ui 4.3.2 → 4.3.3

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.
@@ -294,7 +294,7 @@ function q(...e) {
294
294
  // src/components/shared/option_card_styles.ts
295
295
  function xe(e) {
296
296
  let { isSelected: t, isError: n, isDisabled: r, radius: i, unstyled: a } = e;
297
- return x("flex cursor-pointer items-start gap-3 transition-colors duration-150", w, n ? E : T, !a && [
297
+ return x("relative flex cursor-pointer items-start gap-3 transition-colors duration-150", w, n ? E : T, !a && [
298
298
  j[i],
299
299
  "border px-3 py-2.5",
300
300
  t ? n ? x("border-red-500 dark:border-red-400", "bg-red-50 dark:bg-red-950/20") : "border-blue-500 bg-blue-50 dark:border-blue-500 dark:bg-blue-950/25" : n ? "border-red-300 bg-white dark:border-red-800/50 dark:bg-gray-800/50" : x("border-gray-200 dark:border-gray-700", "bg-gray-50 hover:border-gray-300 hover:bg-white dark:bg-gray-800/50 dark:hover:border-gray-600 dark:hover:bg-gray-800")
@@ -1827,7 +1827,7 @@ function Qn({ children: e, items: t, radius: n = "md", className: r, ref: i, "ar
1827
1827
  });
1828
1828
  Jn(c, v, u);
1829
1829
  let y = o(() => {
1830
- p(), s.current?.focus();
1830
+ p(), s.current?.focus({ preventScroll: !0 });
1831
1831
  }, [p]);
1832
1832
  return /* @__PURE__ */ _("div", {
1833
1833
  ref: i,
@@ -2317,7 +2317,7 @@ function ii({ isEnded: e, onDismiss: t, dismissible: n, initialFocusRef: r, init
2317
2317
  }, [s, e]), c(() => {
2318
2318
  if (!e) return;
2319
2319
  let t = m.current;
2320
- (t?.isConnected ? t : a?.())?.focus();
2320
+ (t?.isConnected ? t : a?.())?.focus({ preventScroll: !0 });
2321
2321
  }, [e, a]), ri(u, {
2322
2322
  isEnded: e,
2323
2323
  onDismiss: t,
@@ -2338,7 +2338,7 @@ function ii({ isEnded: e, onDismiss: t, dismissible: n, initialFocusRef: r, init
2338
2338
  }
2339
2339
  };
2340
2340
  }
2341
- // node_modules/.pnpm/zustand@5.0.15_@types+react@19.3.0_react@19.3.1_use-sync-external-store@1.7.0_react@19.3.1_/node_modules/zustand/esm/vanilla.mjs
2341
+ // node_modules/.pnpm/zustand@5.0.16_@types+react@19.3.0_react@19.3.1_use-sync-external-store@1.7.0_react@19.3.1_/node_modules/zustand/esm/vanilla.mjs
2342
2342
  var ai = (e) => {
2343
2343
  let t, n = /* @__PURE__ */ new Set(), r = (e, r) => {
2344
2344
  let i = typeof e == "function" ? e(t) : e;
@@ -2355,7 +2355,7 @@ var ai = (e) => {
2355
2355
  return a;
2356
2356
  }, oi = ((e) => e ? ai(e) : ai), si = (e) => e;
2357
2357
  function ci(e, n = si) {
2358
- let r = t.useSyncExternalStore(e.subscribe, t.useCallback(() => n(e.getState()), [e, n]), t.useCallback(() => n(e.getInitialState()), [e, n]));
2358
+ let r = t.useSyncExternalStore(e.subscribe, t.useCallback(() => n(e.getState()), [e, n]), () => n(e.getInitialState()));
2359
2359
  return t.useDebugValue(r), r;
2360
2360
  }
2361
2361
  var li = (e) => {
@@ -2533,7 +2533,7 @@ function Ti({ trigger: e, children: t, side: r = "bottom", align: i = "start", r
2533
2533
  });
2534
2534
  Jn(v, E, b);
2535
2535
  let D = l(), O = (a(e) ? e.props.id : void 0) ?? D, k = `${O}-menu`, A = o(() => {
2536
- C(), d.current?.querySelector("button, [href], [tabindex]")?.focus();
2536
+ C(), d.current?.querySelector("button, [href], [tabindex]")?.focus({ preventScroll: !0 });
2537
2537
  }, [C]), j = o((e) => we(w.setReference, d, u)(e), [w, u]), M = {
2538
2538
  id: O,
2539
2539
  onClick: (t) => {
@@ -2573,16 +2573,16 @@ function Ei({ label: e, children: t, unstyled: n = !1, className: r, wrapperClas
2573
2573
  children: [/* @__PURE__ */ g("div", {
2574
2574
  id: a,
2575
2575
  role: "presentation",
2576
- className: x(!n && "px-4 py-1.5 text-xs font-semibold uppercase tracking-wide text-gray-500 dark:text-gray-400", r),
2576
+ className: x(!n && "px-3 pt-2 pb-1 text-xs font-medium text-gray-500 dark:text-gray-400", r),
2577
2577
  children: e
2578
2578
  }), t]
2579
2579
  });
2580
2580
  }
2581
2581
  // src/components/menu_item/menu_item_content.tsx
2582
- var Di = ({ icon: e, children: t }) => /* @__PURE__ */ _(h, { children: [e && /* @__PURE__ */ g("div", {
2583
- className: x(e, "h-4 w-4 flex-shrink-0"),
2582
+ var Di = ({ icon: e, danger: t = !1, children: n }) => /* @__PURE__ */ _(h, { children: [e && /* @__PURE__ */ g("span", {
2583
+ className: x(e, "h-4 w-4 flex-shrink-0", !t && "text-gray-500 dark:text-gray-400"),
2584
2584
  "aria-hidden": "true"
2585
- }), t] });
2585
+ }), n] });
2586
2586
  // src/components/menu_item/menu_item_end.tsx
2587
2587
  function Oi({ trailing: e, selected: t }) {
2588
2588
  let n = t !== void 0;
@@ -2592,23 +2592,26 @@ function Oi({ trailing: e, selected: t }) {
2592
2592
  className: "text-xs text-gray-500 dark:text-gray-400",
2593
2593
  children: e
2594
2594
  }), n && /* @__PURE__ */ g("span", {
2595
- className: x("i-mdi-check h-4 w-4", !t && "invisible"),
2595
+ className: x("i-mdi-check h-4 w-4 text-blue-600 dark:text-blue-400", !t && "invisible"),
2596
2596
  "aria-hidden": "true"
2597
2597
  })]
2598
2598
  });
2599
2599
  }
2600
2600
  // src/components/menu_item/menu_item_styles.ts
2601
- var ki = [
2602
- "flex w-full cursor-pointer items-center gap-2 whitespace-nowrap px-4 py-2 text-left text-sm transition-colors",
2603
- "focus-visible:bg-gray-100 dark:focus-visible:bg-gray-700",
2604
- D
2605
- ];
2606
- function Ai(e, t, n) {
2607
- return x(ki, e, t ? "text-red-700 dark:text-red-300" : "text-gray-700 dark:text-gray-300", n);
2601
+ var ki = ["flex w-full cursor-pointer items-center gap-2 whitespace-nowrap px-3 py-2 text-left text-sm transition-colors", D], Ai = {
2602
+ default: "text-gray-900 dark:text-gray-100 focus-visible:bg-blue-50 dark:focus-visible:bg-blue-900/40",
2603
+ danger: "text-red-700 dark:text-red-400 focus-visible:bg-red-50 dark:focus-visible:bg-red-950/40"
2604
+ };
2605
+ function ji(e, t, n, r) {
2606
+ let i = n ? "danger" : "default";
2607
+ return x(ki, Ai[i], e[i], t, r);
2608
2608
  }
2609
2609
  // src/components/menu_item/menu_item_button.tsx
2610
- var ji = ["hover:enabled:bg-gray-100 dark:hover:enabled:bg-gray-700", "disabled:cursor-not-allowed disabled:opacity-50"];
2611
- function Mi({ icon: e, trailing: t, onClick: n, selected: r, danger: i = !1, disabled: a = !1, children: o, className: s, ref: c }) {
2610
+ var Mi = {
2611
+ default: "hover:enabled:bg-gray-50 dark:hover:enabled:bg-gray-800/60",
2612
+ danger: "hover:enabled:bg-red-50 dark:hover:enabled:bg-red-950/40"
2613
+ }, Ni = ["disabled:cursor-not-allowed disabled:opacity-50"];
2614
+ function Pi({ icon: e, trailing: t, onClick: n, selected: r, danger: i = !1, disabled: a = !1, children: o, className: s, ref: c }) {
2612
2615
  let l = Rn();
2613
2616
  return /* @__PURE__ */ _("button", {
2614
2617
  ref: c,
@@ -2620,9 +2623,10 @@ function Mi({ icon: e, trailing: t, onClick: n, selected: r, danger: i = !1, dis
2620
2623
  e.stopPropagation(), n(e), l?.();
2621
2624
  },
2622
2625
  disabled: a,
2623
- className: Ai(ji, i, s),
2626
+ className: ji(Mi, Ni, i, s),
2624
2627
  children: [/* @__PURE__ */ g(Di, {
2625
2628
  icon: e,
2629
+ danger: i,
2626
2630
  children: o
2627
2631
  }), /* @__PURE__ */ g(Oi, {
2628
2632
  trailing: t,
@@ -2631,8 +2635,11 @@ function Mi({ icon: e, trailing: t, onClick: n, selected: r, danger: i = !1, dis
2631
2635
  });
2632
2636
  }
2633
2637
  // src/components/menu_item/menu_item_link.tsx
2634
- var Ni = "_blank", Pi = "noopener noreferrer", Fi = ["no-underline hover:bg-gray-100 dark:hover:bg-gray-700", "aria-disabled:pointer-events-none aria-disabled:cursor-not-allowed aria-disabled:opacity-50"];
2635
- function Ii({ icon: e, trailing: t, href: n, target: r, rel: i, danger: a = !1, disabled: o = !1, children: s, className: c, ref: l }) {
2638
+ var Fi = "_blank", Ii = "noopener noreferrer", Li = {
2639
+ default: "hover:bg-gray-50 dark:hover:bg-gray-800/60",
2640
+ danger: "hover:bg-red-50 dark:hover:bg-red-950/40"
2641
+ }, Ri = ["no-underline", "aria-disabled:pointer-events-none aria-disabled:cursor-not-allowed aria-disabled:opacity-50"];
2642
+ function zi({ icon: e, trailing: t, href: n, target: r, rel: i, danger: a = !1, disabled: o = !1, children: s, className: c, ref: l }) {
2636
2643
  let u = Rn();
2637
2644
  return /* @__PURE__ */ _("a", {
2638
2645
  ref: l,
@@ -2640,28 +2647,29 @@ function Ii({ icon: e, trailing: t, href: n, target: r, rel: i, danger: a = !1,
2640
2647
  tabIndex: -1,
2641
2648
  href: o ? void 0 : n,
2642
2649
  target: r,
2643
- rel: i ?? (r === Ni ? Pi : void 0),
2650
+ rel: i ?? (r === Fi ? Ii : void 0),
2644
2651
  "aria-disabled": o || void 0,
2645
2652
  onClick: (e) => {
2646
2653
  e.stopPropagation(), u?.();
2647
2654
  },
2648
- className: Ai(Fi, a, c),
2655
+ className: ji(Li, Ri, a, c),
2649
2656
  children: [/* @__PURE__ */ g(Di, {
2650
2657
  icon: e,
2658
+ danger: a,
2651
2659
  children: s
2652
2660
  }), /* @__PURE__ */ g(Oi, { trailing: t })]
2653
2661
  });
2654
2662
  }
2655
2663
  // src/components/menu_item/menu_item.tsx
2656
- function Li(e) {
2657
- return e.href === void 0 ? /* @__PURE__ */ g(Mi, { ...e }) : /* @__PURE__ */ g(Ii, { ...e });
2664
+ function Bi(e) {
2665
+ return e.href === void 0 ? /* @__PURE__ */ g(Pi, { ...e }) : /* @__PURE__ */ g(zi, { ...e });
2658
2666
  }
2659
2667
  // src/components/menu_separator/menu_separator.tsx
2660
- var Ri = ({ unstyled: e = !1, className: t }) => /* @__PURE__ */ g("hr", {
2668
+ var Vi = ({ unstyled: e = !1, className: t }) => /* @__PURE__ */ g("hr", {
2661
2669
  "aria-orientation": "horizontal",
2662
- className: x("w-full", !e && ["my-1 border-0 border-t", "border-gray-200 dark:border-gray-700"], t)
2663
- }), zi = [];
2664
- function Bi() {
2670
+ className: x("w-full", !e && ["my-1 border-0 border-t", "border-gray-100 dark:border-gray-800"], t)
2671
+ }), Hi = [];
2672
+ function Ui() {
2665
2673
  let e = 0, t = [], n = null, r = /* @__PURE__ */ new Set(), i = () => {
2666
2674
  for (let e of r) e(t);
2667
2675
  };
@@ -2682,7 +2690,7 @@ function Bi() {
2682
2690
  r.delete(i), r.size || (e = 0, t = [], n = null);
2683
2691
  }),
2684
2692
  getSnapshot: () => t,
2685
- getServerSnapshot: () => zi,
2693
+ getServerSnapshot: () => Hi,
2686
2694
  getListenersSize: () => r.size,
2687
2695
  getUpsertPromise: () => n,
2688
2696
  setUpsertPromise: (e) => {
@@ -2690,9 +2698,9 @@ function Bi() {
2690
2698
  }
2691
2699
  };
2692
2700
  }
2693
- var Vi = /* @__PURE__ */ new Map();
2694
- function Hi(e, t = 0) {
2695
- let n = { current: Bi() }, r = (e) => (r) => {
2701
+ var Wi = /* @__PURE__ */ new Map();
2702
+ function Gi(e, t = 0) {
2703
+ let n = { current: Ui() }, r = (e) => (r) => {
2696
2704
  let i = /* @__PURE__ */ new Set();
2697
2705
  n.current.set(e, (e) => (e.resolve(r), i.add(e.promise), {
2698
2706
  ...e,
@@ -2778,47 +2786,47 @@ function Hi(e, t = 0) {
2778
2786
  set: (r) => {
2779
2787
  if (t || (e = r, !r)) return;
2780
2788
  t = !0;
2781
- let i = Vi.get(r);
2782
- i ? n.current = i : Vi.set(r, n.current);
2789
+ let i = Wi.get(r);
2790
+ i ? n.current = i : Wi.set(r, n.current);
2783
2791
  }
2784
2792
  });
2785
2793
  }
2786
2794
  return d;
2787
2795
  }
2788
2796
  // src/components/modal/confirm_modal_title.tsx
2789
- var Ui = {
2797
+ var Ki = {
2790
2798
  danger: "i-mdi-alert-circle",
2791
2799
  primary: "i-mdi-help-circle",
2792
2800
  success: "i-mdi-check-circle"
2793
- }, Wi = {
2801
+ }, qi = {
2794
2802
  danger: "bg-red-50 text-red-600 dark:bg-red-500/10 dark:text-red-400",
2795
2803
  primary: "bg-blue-50 text-blue-600 dark:bg-blue-500/10 dark:text-blue-400",
2796
2804
  success: "bg-green-50 text-green-600 dark:bg-green-500/10 dark:text-green-400"
2797
2805
  };
2798
- function Gi({ title: e, color: t }) {
2806
+ function Ji({ title: e, color: t }) {
2799
2807
  return /* @__PURE__ */ _("div", {
2800
2808
  className: "flex items-center gap-3",
2801
2809
  children: [/* @__PURE__ */ g("span", {
2802
- className: x("flex h-9 w-9 shrink-0 items-center justify-center rounded-full", Wi[t]),
2810
+ className: x("flex h-9 w-9 shrink-0 items-center justify-center rounded-full", qi[t]),
2803
2811
  "aria-hidden": "true",
2804
- children: /* @__PURE__ */ g("span", { className: x(Ui[t], "h-5 w-5") })
2812
+ children: /* @__PURE__ */ g("span", { className: x(Ki[t], "h-5 w-5") })
2805
2813
  }), e]
2806
2814
  });
2807
2815
  }
2808
2816
  // src/components/modal/modal_shell.tsx
2809
- var Ki = {
2817
+ var Yi = {
2810
2818
  sm: "max-w-md",
2811
2819
  md: "max-w-lg",
2812
2820
  lg: "max-w-2xl",
2813
2821
  xl: "max-w-4xl"
2814
- }, qi = {
2822
+ }, Xi = {
2815
2823
  auto: "",
2816
2824
  fixed: "ms-modal-height-fixed"
2817
- }, Ji = {
2825
+ }, Zi = {
2818
2826
  auto: "overflow-y-auto",
2819
2827
  fixed: "overflow-hidden flex flex-col"
2820
2828
  };
2821
- function Yi({ isEnded: e, onDismiss: t, title: n, children: r, footer: i, size: a = "md", height: o = "auto", radius: s = "xl", className: c, dismissible: u = !0, closeLabel: d, role: f = "dialog", initialFocusRef: p, "aria-label": m }) {
2829
+ function Qi({ isEnded: e, onDismiss: t, title: n, children: r, footer: i, size: a = "md", height: o = "auto", radius: s = "xl", className: c, dismissible: u = !0, closeLabel: d, role: f = "dialog", initialFocusRef: p, "aria-label": m }) {
2822
2830
  let h = l(), v = l(), { dialogRef: b, contentRef: S, footerSlot: C, setFooterSlot: w, isVisible: T, handleBackdropClick: E, handleBackdropMouseDown: D } = ii({
2823
2831
  isEnded: e,
2824
2832
  onDismiss: t,
@@ -2840,7 +2848,7 @@ function Yi({ isEnded: e, onDismiss: t, title: n, children: r, footer: i, size:
2840
2848
  "aria-label": n ? void 0 : m,
2841
2849
  "aria-describedby": O ? v : void 0,
2842
2850
  tabIndex: -1,
2843
- className: x("relative w-full", Ki[a], qi[o], W, G, "shadow-2xl", j[s], "ms-modal-max-height overflow-hidden flex flex-col", "transition-all duration-200 ease-out", "focus:outline-none", T ? "opacity-100 scale-100 translate-y-0" : "opacity-0 scale-95 translate-y-1"),
2851
+ className: x("relative w-full", Yi[a], Xi[o], W, G, "shadow-2xl", j[s], "ms-modal-max-height overflow-hidden flex flex-col", "transition-all duration-200 ease-out", "focus:outline-none", T ? "opacity-100 scale-100 translate-y-0" : "opacity-0 scale-95 translate-y-1"),
2844
2852
  onClick: (e) => e.stopPropagation(),
2845
2853
  children: [
2846
2854
  n && /* @__PURE__ */ g(Dr, {
@@ -2853,7 +2861,7 @@ function Yi({ isEnded: e, onDismiss: t, title: n, children: r, footer: i, size:
2853
2861
  /* @__PURE__ */ g("div", {
2854
2862
  ref: S,
2855
2863
  id: O ? v : void 0,
2856
- className: x("flex-1 px-6 pb-6 text-sm leading-relaxed text-gray-600 dark:text-gray-400 min-h-0", Ji[o], !n && "pt-6", c),
2864
+ className: x("flex-1 px-6 pb-6 text-sm leading-relaxed text-gray-600 dark:text-gray-400 min-h-0", Zi[o], !n && "pt-6", c),
2857
2865
  children: /* @__PURE__ */ g(fr.Provider, {
2858
2866
  value: C,
2859
2867
  children: r
@@ -2868,7 +2876,7 @@ function Yi({ isEnded: e, onDismiss: t, title: n, children: r, footer: i, size:
2868
2876
  }), document.body);
2869
2877
  }
2870
2878
  // src/components/modal/confirm_modal.tsx
2871
- var Xi = Hi(({ call: e, title: t, children: n, confirmLabel: r, cancelLabel: i, confirmColor: a, radius: o, closeLabel: s, onConfirm: c, onError: l }) => {
2879
+ var $i = Gi(({ call: e, title: t, children: n, confirmLabel: r, cancelLabel: i, confirmColor: a, radius: o, closeLabel: s, onConfirm: c, onError: l }) => {
2872
2880
  pi();
2873
2881
  let [u, d] = p(!1), m = f(null), v = () => e.end(!1), y = async () => {
2874
2882
  if (!c) e.end(!0);
@@ -2881,10 +2889,10 @@ var Xi = Hi(({ call: e, title: t, children: n, confirmLabel: r, cancelLabel: i,
2881
2889
  }
2882
2890
  }
2883
2891
  }, b = Ae(), x = r ?? b.confirm, S = i ?? b.cancel, C = a ?? "primary";
2884
- return /* @__PURE__ */ g(Yi, {
2892
+ return /* @__PURE__ */ g(Qi, {
2885
2893
  isEnded: e.ended,
2886
2894
  onDismiss: v,
2887
- title: /* @__PURE__ */ g(Gi, {
2895
+ title: /* @__PURE__ */ g(Ji, {
2888
2896
  title: t,
2889
2897
  color: C
2890
2898
  }),
@@ -2914,10 +2922,10 @@ var Xi = Hi(({ call: e, title: t, children: n, confirmLabel: r, cancelLabel: i,
2914
2922
  });
2915
2923
  }, 200);
2916
2924
  // src/components/modal/modal.tsx
2917
- function Zi(e, t) {
2925
+ function ea(e, t) {
2918
2926
  return typeof e == "function" ? e(t) : e;
2919
2927
  }
2920
- var Qi = Hi(({ call: e, title: t, children: n, size: r, height: i, radius: a, className: o, dismissible: s, closeLabel: c, role: l, initialFocusRef: u, "aria-label": d }) => {
2928
+ var ta = Gi(({ call: e, title: t, children: n, size: r, height: i, radius: a, className: o, dismissible: s, closeLabel: c, role: l, initialFocusRef: u, "aria-label": d }) => {
2921
2929
  pi();
2922
2930
  let { dismiss: f, registry: p } = kr({
2923
2931
  onDismiss: () => e.end(),
@@ -2925,7 +2933,7 @@ var Qi = Hi(({ call: e, title: t, children: n, size: r, height: i, radius: a, cl
2925
2933
  });
2926
2934
  return /* @__PURE__ */ g(ur.Provider, {
2927
2935
  value: p,
2928
- children: /* @__PURE__ */ g(Yi, {
2936
+ children: /* @__PURE__ */ g(Qi, {
2929
2937
  isEnded: e.ended,
2930
2938
  onDismiss: f,
2931
2939
  title: t,
@@ -2938,17 +2946,17 @@ var Qi = Hi(({ call: e, title: t, children: n, size: r, height: i, radius: a, cl
2938
2946
  role: l,
2939
2947
  initialFocusRef: u,
2940
2948
  "aria-label": d,
2941
- children: Zi(n, f)
2949
+ children: ea(n, f)
2942
2950
  })
2943
2951
  });
2944
2952
  }, 200);
2945
2953
  // src/components/modal/modal_footer.tsx
2946
- function $i({ children: e }) {
2954
+ function na({ children: e }) {
2947
2955
  let t = s(fr);
2948
2956
  return t ? y(e, t) : null;
2949
2957
  }
2950
2958
  // src/components/modal/use_dismiss_guard.ts
2951
- function ea(e, t = !0) {
2959
+ function ra(e, t = !0) {
2952
2960
  let n = s(ur), r = f(e);
2953
2961
  if (u(() => {
2954
2962
  r.current = e;
@@ -2957,18 +2965,18 @@ function ea(e, t = !0) {
2957
2965
  }, [n, t]), !n) throw Error("useDismissGuard must be used inside a Modal or a Drawer");
2958
2966
  }
2959
2967
  // src/components/modal_provider/modal_provider.tsx
2960
- function ta() {
2961
- return /* @__PURE__ */ _(h, { children: [/* @__PURE__ */ g(Qi, {}), /* @__PURE__ */ g(Xi, {})] });
2968
+ function ia() {
2969
+ return /* @__PURE__ */ _(h, { children: [/* @__PURE__ */ g(ta, {}), /* @__PURE__ */ g($i, {})] });
2962
2970
  }
2963
2971
  // src/components/multi_combobox/multi_combobox.tsx
2964
- var na = 2;
2965
- function ra(e, t, n, r) {
2972
+ var aa = 2;
2973
+ function oa(e, t, n, r) {
2966
2974
  return r?.(e, t) ? !0 : n === void 0 || t.includes(e) ? !1 : t.length >= n;
2967
2975
  }
2968
- function ia(e, t) {
2976
+ function sa(e, t) {
2969
2977
  return e.includes(t) ? e.filter((e) => e !== t) : [...e, t];
2970
2978
  }
2971
- function aa(e, t) {
2979
+ function ca(e, t) {
2972
2980
  if (e.length <= t) return {
2973
2981
  visibleOptions: e,
2974
2982
  hiddenCount: 0
@@ -2979,8 +2987,8 @@ function aa(e, t) {
2979
2987
  hiddenCount: e.length - n
2980
2988
  };
2981
2989
  }
2982
- var oa = "inline-flex items-center rounded-full bg-gray-200 dark:bg-gray-700 px-2 py-0.5 text-xs text-gray-900 dark:text-gray-100";
2983
- function sa({ options: e, label: t, "aria-label": n, error: r, placeholder: i, searchPlaceholder: a, noResultsText: s, clearLabel: l, clearText: u, maxSelectedValues: m, isOptionDisabled: v, maxDisplayedValues: y = na, formatOverflowCount: b, formatSelectedCount: S, formatMaxSelectedHint: C, radius: w = "sm", unstyled: T = !1, disabled: E = !1, required: D = !1, className: k, wrapperClassName: A, values: N, defaultValues: P = [], onChange: F, onDropdownClose: I, id: L }) {
2990
+ var la = "inline-flex items-center rounded-full bg-gray-200 dark:bg-gray-700 px-2 py-0.5 text-xs text-gray-900 dark:text-gray-100";
2991
+ function ua({ options: e, label: t, "aria-label": n, error: r, placeholder: i, searchPlaceholder: a, noResultsText: s, clearLabel: l, clearText: u, maxSelectedValues: m, isOptionDisabled: v, maxDisplayedValues: y = aa, formatOverflowCount: b, formatSelectedCount: S, formatMaxSelectedHint: C, radius: w = "sm", unstyled: T = !1, disabled: E = !1, required: D = !1, className: k, wrapperClassName: A, values: N, defaultValues: P = [], onChange: F, onDropdownClose: I, id: L }) {
2984
2992
  let R = Ae(), { fieldId: z, errorId: ee, labelId: te } = J(L), B = `${z}-listbox`, V = `${z}-max-hint`, ne = f(null), H = f(null), re = f(null), [U, W] = Ce(N, P), [ie, ae] = p(""), [G, oe] = p(!1), K = d(() => {
2985
2993
  let t = ie.trim().toLowerCase();
2986
2994
  return t ? e.filter((e) => e.label.toLowerCase().includes(t)) : e;
@@ -2988,7 +2996,7 @@ function sa({ options: e, label: t, "aria-label": n, error: r, placeholder: i, s
2988
2996
  optionCount: K.length,
2989
2997
  getOptionId: (e) => `${B}-option-${e}`,
2990
2998
  isOpen: G
2991
- }), me = d(() => e.filter((e) => U.includes(e.value)), [e, U]), { visibleOptions: he, hiddenCount: ge } = aa(me, y), _e = () => {
2999
+ }), me = d(() => e.filter((e) => U.includes(e.value)), [e, U]), { visibleOptions: he, hiddenCount: ge } = ca(me, y), _e = () => {
2992
3000
  E || oe(!0);
2993
3001
  }, ve = o(() => {
2994
3002
  oe(!1), ae(""), pe(), I?.(U);
@@ -2999,8 +3007,8 @@ function sa({ options: e, label: t, "aria-label": n, error: r, placeholder: i, s
2999
3007
  ]), ye = () => {
3000
3008
  G ? ve() : _e();
3001
3009
  }, be = (e) => {
3002
- if (ra(e, U, m, v)) return;
3003
- let t = ia(U, e);
3010
+ if (oa(e, U, m, v)) return;
3011
+ let t = sa(U, e);
3004
3012
  W(t), F?.(t);
3005
3013
  }, q = () => {
3006
3014
  W([]), F?.([]);
@@ -3076,10 +3084,10 @@ function sa({ options: e, label: t, "aria-label": n, error: r, placeholder: i, s
3076
3084
  className: x(!T && "text-gray-500 dark:text-gray-400"),
3077
3085
  children: i
3078
3086
  }) : /* @__PURE__ */ _(h, { children: [he.map((e) => /* @__PURE__ */ g("span", {
3079
- className: x(!T && oa),
3087
+ className: x(!T && la),
3080
3088
  children: e.label
3081
3089
  }, e.value)), ge > 0 && /* @__PURE__ */ g("span", {
3082
- className: x(!T && oa),
3090
+ className: x(!T && la),
3083
3091
  children: (b ?? R.overflowCount)(ge)
3084
3092
  })] })
3085
3093
  }),
@@ -3135,7 +3143,7 @@ function sa({ options: e, label: t, "aria-label": n, error: r, placeholder: i, s
3135
3143
  "aria-multiselectable": !0,
3136
3144
  className: x("max-h-60 overflow-auto py-1", "[scrollbar-width:thin] [scrollbar-color:theme(colors.gray.300)_transparent] hover:[scrollbar-color:theme(colors.gray.400)_transparent] dark:[scrollbar-color:theme(colors.gray.600)_transparent] dark:hover:[scrollbar-color:theme(colors.gray.500)_transparent]"),
3137
3145
  children: K.map((e, t) => {
3138
- let n = U.includes(e.value), r = ra(e.value, U, m, v);
3146
+ let n = U.includes(e.value), r = oa(e.value, U, m, v);
3139
3147
  return /* @__PURE__ */ _("li", {
3140
3148
  id: `${B}-option-${t}`,
3141
3149
  role: "option",
@@ -3189,7 +3197,7 @@ function sa({ options: e, label: t, "aria-label": n, error: r, placeholder: i, s
3189
3197
  });
3190
3198
  }
3191
3199
  // src/components/radio_options/radio_option_row.tsx
3192
- function ca({ option: e, optionId: t, descriptionId: n, name: r, orientation: i, isSelected: a, isDisabled: o, isFirstOption: s, required: c, error: l, radius: u, unstyled: d, className: f, onSelect: p }) {
3200
+ function da({ option: e, optionId: t, descriptionId: n, name: r, orientation: i, isSelected: a, isDisabled: o, isFirstOption: s, required: c, error: l, radius: u, unstyled: d, className: f, onSelect: p }) {
3193
3201
  let m = !!l;
3194
3202
  return /* @__PURE__ */ g(De, {
3195
3203
  item: e,
@@ -3225,7 +3233,7 @@ function ca({ option: e, optionId: t, descriptionId: n, name: r, orientation: i,
3225
3233
  });
3226
3234
  }
3227
3235
  // src/components/radio_options/radio_options.tsx
3228
- function la({ options: e, orientation: t = "vertical", value: n, defaultValue: r, onChange: i, name: a, label: o, error: s, required: c, disabled: l, radius: u = "lg", unstyled: d = !1, className: f, wrapperClassName: p, id: m, "aria-describedby": h, ...v }) {
3236
+ function fa({ options: e, orientation: t = "vertical", value: n, defaultValue: r, onChange: i, name: a, label: o, error: s, required: c, disabled: l, radius: u = "lg", unstyled: d = !1, className: f, wrapperClassName: p, id: m, "aria-describedby": h, ...v }) {
3229
3237
  let { fieldId: y, errorId: b } = J(m), S = a ?? y, [C, w] = Ce(n, r ?? ""), T = e.map((e) => typeof e == "string" ? {
3230
3238
  value: e,
3231
3239
  label: e
@@ -3249,7 +3257,7 @@ function la({ options: e, orientation: t = "vertical", value: n, defaultValue: r
3249
3257
  }),
3250
3258
  /* @__PURE__ */ g("div", {
3251
3259
  className: x(t === "horizontal" ? "flex flex-row gap-2" : "flex flex-col gap-2"),
3252
- children: T.map((e, n) => /* @__PURE__ */ g(ca, {
3260
+ children: T.map((e, n) => /* @__PURE__ */ g(da, {
3253
3261
  option: e,
3254
3262
  optionId: `${y}-${n}`,
3255
3263
  descriptionId: `${y}-${n}-desc`,
@@ -3275,7 +3283,7 @@ function la({ options: e, orientation: t = "vertical", value: n, defaultValue: r
3275
3283
  });
3276
3284
  }
3277
3285
  // src/components/select/select.tsx
3278
- function ua({ options: e, label: t, description: n, error: r, placeholder: i, radius: a = "md", unstyled: o = !1, className: s, wrapperClassName: c, value: l, defaultValue: u, onChange: d, id: f, "aria-describedby": p, ...m }) {
3286
+ function pa({ options: e, label: t, description: n, error: r, placeholder: i, radius: a = "md", unstyled: o = !1, className: s, wrapperClassName: c, value: l, defaultValue: u, onChange: d, id: f, "aria-describedby": p, ...m }) {
3279
3287
  let { fieldId: h, errorId: v, descriptionId: y } = J(f);
3280
3288
  return /* @__PURE__ */ g(Fe, {
3281
3289
  fieldId: h,
@@ -3310,7 +3318,7 @@ function ua({ options: e, label: t, description: n, error: r, placeholder: i, ra
3310
3318
  });
3311
3319
  }
3312
3320
  // src/components/switch/switch.tsx
3313
- function da({ label: e, description: t, error: n, unstyled: r = !1, fullWidth: i = !1, className: a, wrapperClassName: o, checked: s, defaultChecked: c = !1, onChange: l, id: u, "aria-describedby": d, ...f }) {
3321
+ function ma({ label: e, description: t, error: n, unstyled: r = !1, fullWidth: i = !1, className: a, wrapperClassName: o, checked: s, defaultChecked: c = !1, onChange: l, id: u, "aria-describedby": d, ...f }) {
3314
3322
  let { fieldId: p, errorId: m, descriptionId: v } = J(u), [y, b] = Ce(s, c), S = q(d, !!t && v, n && m);
3315
3323
  return /* @__PURE__ */ _("div", {
3316
3324
  className: x(i ? "w-full" : "w-fit", o),
@@ -3365,11 +3373,11 @@ function da({ label: e, description: t, error: n, unstyled: r = !1, fullWidth: i
3365
3373
  });
3366
3374
  }
3367
3375
  // src/components/tabs/tabs_styles.ts
3368
- var fa = {
3376
+ var ha = {
3369
3377
  list: "gap-1 p-1 bg-gray-100 dark:bg-gray-800/50",
3370
3378
  tab: "",
3371
3379
  indicator: `absolute inset-0 ${H} border border-gray-200 dark:border-gray-700`
3372
- }, pa = {
3380
+ }, ga = {
3373
3381
  line: {
3374
3382
  activeTab: "border-transparent text-gray-900 dark:text-gray-100",
3375
3383
  idleTab: "border-transparent text-gray-500 dark:text-gray-400",
@@ -3392,52 +3400,52 @@ var fa = {
3392
3400
  idleTab: "text-gray-600 dark:text-gray-400",
3393
3401
  idleHover: "hover:text-gray-900 dark:hover:text-gray-100",
3394
3402
  byOrientation: {
3395
- horizontal: fa,
3396
- vertical: fa
3403
+ horizontal: ha,
3404
+ vertical: ha
3397
3405
  }
3398
3406
  }
3399
- }, ma = {
3407
+ }, _a = {
3400
3408
  xs: "px-2 py-1 text-xs",
3401
3409
  sm: "px-3 py-1.5 text-sm",
3402
3410
  md: "px-4 py-2.5 text-sm",
3403
3411
  lg: "px-5 py-3 text-base"
3404
- }, ha = {
3412
+ }, va = {
3405
3413
  xs: "w-3.5 h-3.5",
3406
3414
  sm: "w-4 h-4",
3407
3415
  md: "w-4 h-4",
3408
3416
  lg: "w-5 h-5"
3409
- }, ga = {
3417
+ }, ya = {
3410
3418
  horizontal: x(S, O.primary.focusOutline),
3411
3419
  vertical: x("outline-hidden focus-visible:outline-2", "focus-visible:-outline-offset-2", O.primary.focusOutline)
3412
- }, _a = "items-center", va = x("flex-col items-stretch min-h-0 overflow-y-auto overflow-x-hidden", ae), ya = "w-48 shrink-0", ba = "justify-start text-left whitespace-normal", xa = "whitespace-nowrap", Sa = "flex min-h-0", Ca = x("flex-1 min-w-0 min-h-0 overflow-y-auto", ae), wa = "ml-6", Ta = "mt-4";
3413
- function Ea(e, t) {
3414
- return x("w-full", e === "vertical" && Sa, t);
3420
+ }, ba = "items-center", xa = x("flex-col items-stretch min-h-0 overflow-y-auto overflow-x-hidden", ae), Sa = "w-48 shrink-0", Ca = "justify-start text-left whitespace-normal", wa = "whitespace-nowrap", Ta = "flex min-h-0", Ea = x("flex-1 min-w-0 min-h-0 overflow-y-auto", ae), Da = "ml-6", Oa = "mt-4";
3421
+ function ka(e, t) {
3422
+ return x("w-full", e === "vertical" && Ta, t);
3415
3423
  }
3416
- function Da(e) {
3424
+ function Aa(e) {
3417
3425
  let { orientation: t, unstyled: n, className: r } = e, i = t === "vertical";
3418
- return x(i && Ca, !n && [i ? wa : Ta, ga[t]], r);
3426
+ return x(i && Ea, !n && [i ? Da : Oa, ya[t]], r);
3419
3427
  }
3420
- function Oa(e) {
3428
+ function ja(e) {
3421
3429
  let { variant: t, orientation: n, radius: r, unstyled: i, isFullWidth: a, className: o } = e, s = n === "vertical";
3422
- return x("flex", s ? va : _a, !s && a && "w-full", !i && s && ya, !i && pa[t].byOrientation[n].list, !i && t === "segmented" && j[r], o);
3430
+ return x("flex", s ? xa : ba, !s && a && "w-full", !i && s && Sa, !i && ga[t].byOrientation[n].list, !i && t === "segmented" && j[r], o);
3423
3431
  }
3424
- function ka(e) {
3425
- let { variant: t, orientation: n, size: r, radius: i, unstyled: a, isActive: o, isDisabled: s, isFullWidth: c, className: l } = e, u = n === "vertical", d = pa[t];
3426
- return x("relative flex items-center gap-2", u ? ba : xa, !u && c && "flex-1 justify-center", s ? "opacity-50 cursor-not-allowed" : "cursor-pointer", !a && [
3432
+ function Ma(e) {
3433
+ let { variant: t, orientation: n, size: r, radius: i, unstyled: a, isActive: o, isDisabled: s, isFullWidth: c, className: l } = e, u = n === "vertical", d = ga[t];
3434
+ return x("relative flex items-center gap-2", u ? Ca : wa, !u && c && "flex-1 justify-center", s ? "opacity-50 cursor-not-allowed" : "cursor-pointer", !a && [
3427
3435
  "font-medium transition-colors duration-200",
3428
- ma[r],
3436
+ _a[r],
3429
3437
  d.byOrientation[n].tab,
3430
3438
  o ? d.activeTab : [d.idleTab, !s && d.idleHover],
3431
3439
  t === "segmented" && j[i],
3432
- ga[n]
3440
+ ya[n]
3433
3441
  ], l);
3434
3442
  }
3435
- function Aa(e) {
3443
+ function Na(e) {
3436
3444
  let { variant: t, orientation: n, radius: r } = e;
3437
- return x("tabs-indicator pointer-events-none", pa[t].byOrientation[n].indicator, t === "segmented" && j[r]);
3445
+ return x("tabs-indicator pointer-events-none", ga[t].byOrientation[n].indicator, t === "segmented" && j[r]);
3438
3446
  }
3439
3447
  // src/components/tabs/tab_button.tsx
3440
- function ja({ item: e, isActive: t, hasMountedPanel: n, isTabStop: r, isFullWidth: i, variant: a, orientation: o, size: s, radius: c, unstyled: l, tabId: u, panelId: d, onSelect: f, onKeyDown: p, ref: m, indicatorRef: v }) {
3448
+ function Pa({ item: e, isActive: t, hasMountedPanel: n, isTabStop: r, isFullWidth: i, variant: a, orientation: o, size: s, radius: c, unstyled: l, tabId: u, panelId: d, onSelect: f, onKeyDown: p, ref: m, indicatorRef: v }) {
3441
3449
  let y = !!e.disabled;
3442
3450
  return /* @__PURE__ */ _("button", {
3443
3451
  ref: m,
@@ -3451,7 +3459,7 @@ function ja({ item: e, isActive: t, hasMountedPanel: n, isTabStop: r, isFullWidt
3451
3459
  disabled: e.disabled,
3452
3460
  onClick: f,
3453
3461
  onKeyDown: p,
3454
- className: ka({
3462
+ className: Ma({
3455
3463
  variant: a,
3456
3464
  orientation: o,
3457
3465
  size: s,
@@ -3465,7 +3473,7 @@ function ja({ item: e, isActive: t, hasMountedPanel: n, isTabStop: r, isFullWidt
3465
3473
  t && !l && /* @__PURE__ */ g("span", {
3466
3474
  ref: v,
3467
3475
  "aria-hidden": "true",
3468
- className: Aa({
3476
+ className: Na({
3469
3477
  variant: a,
3470
3478
  orientation: o,
3471
3479
  radius: c
@@ -3473,7 +3481,7 @@ function ja({ item: e, isActive: t, hasMountedPanel: n, isTabStop: r, isFullWidt
3473
3481
  }),
3474
3482
  e.icon && /* @__PURE__ */ g("span", {
3475
3483
  "aria-hidden": "true",
3476
- className: x("relative shrink-0", ha[s], e.icon)
3484
+ className: x("relative shrink-0", va[s], e.icon)
3477
3485
  }),
3478
3486
  /* @__PURE__ */ g("span", {
3479
3487
  className: "relative",
@@ -3484,7 +3492,7 @@ function ja({ item: e, isActive: t, hasMountedPanel: n, isTabStop: r, isFullWidt
3484
3492
  });
3485
3493
  }
3486
3494
  // src/components/tabs/tab_panel.tsx
3487
- function Ma({ panelId: e, tabId: t, isHidden: n, isAnimated: r, className: i, contentKey: a, children: o }) {
3495
+ function Fa({ panelId: e, tabId: t, isHidden: n, isAnimated: r, className: i, contentKey: a, children: o }) {
3488
3496
  return /* @__PURE__ */ g("div", {
3489
3497
  role: "tabpanel",
3490
3498
  id: e,
@@ -3499,11 +3507,11 @@ function Ma({ panelId: e, tabId: t, isHidden: n, isAnimated: r, className: i, co
3499
3507
  });
3500
3508
  }
3501
3509
  // src/components/tabs/use_tab_indicator_transition.ts
3502
- var Na = 200, Pa = "ease-out", Fa = "(prefers-reduced-motion: reduce)";
3503
- function Ia() {
3504
- return typeof window > "u" || typeof window.matchMedia != "function" ? !1 : window.matchMedia(Fa).matches;
3510
+ var Ia = 200, La = "ease-out", Ra = "(prefers-reduced-motion: reduce)";
3511
+ function za() {
3512
+ return typeof window > "u" || typeof window.matchMedia != "function" ? !1 : window.matchMedia(Ra).matches;
3505
3513
  }
3506
- function La(e, t, n) {
3514
+ function Ba(e, t, n) {
3507
3515
  return e === "vertical" ? [{
3508
3516
  transform: `translateY(${t.top - n.top}px)`,
3509
3517
  height: `${t.height}px`
@@ -3518,16 +3526,16 @@ function La(e, t, n) {
3518
3526
  width: `${n.width}px`
3519
3527
  }];
3520
3528
  }
3521
- function Ra(e, t, n, r) {
3522
- e.animate(La(t, n, r), {
3523
- duration: Na,
3524
- easing: Pa
3529
+ function Va(e, t, n, r) {
3530
+ e.animate(Ba(t, n, r), {
3531
+ duration: Ia,
3532
+ easing: La
3525
3533
  });
3526
3534
  }
3527
- function za(e, t, n) {
3528
- return !e || !t || !n ? !1 : !Ia();
3535
+ function Ha(e, t, n) {
3536
+ return !e || !t || !n ? !1 : !za();
3529
3537
  }
3530
- function Ba(e) {
3538
+ function Ua(e) {
3531
3539
  let { activeIndex: t, indicatorRef: n, isAnimated: r, orientation: i } = e, a = f(null);
3532
3540
  u(() => {
3533
3541
  let e = n.current;
@@ -3536,7 +3544,7 @@ function Ba(e) {
3536
3544
  return;
3537
3545
  }
3538
3546
  let t = e.getBoundingClientRect(), o = typeof e.animate == "function";
3539
- za(a.current, r, o) && Ra(e, i, a.current, t), a.current = t;
3547
+ Ha(a.current, r, o) && Va(e, i, a.current, t), a.current = t;
3540
3548
  }, [
3541
3549
  t,
3542
3550
  n,
@@ -3545,34 +3553,34 @@ function Ba(e) {
3545
3553
  ]);
3546
3554
  }
3547
3555
  // src/components/tabs/use_tabs_keyboard_navigation.ts
3548
- var Va = {
3556
+ var Wa = {
3549
3557
  Home: () => 0,
3550
3558
  End: (e, t) => t - 1
3551
- }, Ha = (e, t) => (e + 1) % t, Ua = (e, t) => (e - 1 + t) % t, Wa = {
3559
+ }, Ga = (e, t) => (e + 1) % t, Ka = (e, t) => (e - 1 + t) % t, qa = {
3552
3560
  horizontal: {
3553
- ...Va,
3554
- ArrowRight: Ha,
3555
- ArrowLeft: Ua
3561
+ ...Wa,
3562
+ ArrowRight: Ga,
3563
+ ArrowLeft: Ka
3556
3564
  },
3557
3565
  vertical: {
3558
- ...Va,
3559
- ArrowDown: Ha,
3560
- ArrowUp: Ua
3566
+ ...Wa,
3567
+ ArrowDown: Ga,
3568
+ ArrowUp: Ka
3561
3569
  }
3562
3570
  };
3563
- function Ga(e) {
3571
+ function Ja(e) {
3564
3572
  return e.flatMap((e, t) => e.disabled ? [] : [t]);
3565
3573
  }
3566
- function Ka(e, t) {
3574
+ function Ya(e, t) {
3567
3575
  let n = e[t];
3568
- return n && !n.disabled ? t : Ga(e)[0] ?? -1;
3576
+ return n && !n.disabled ? t : Ja(e)[0] ?? -1;
3569
3577
  }
3570
- function qa(e) {
3578
+ function Xa(e) {
3571
3579
  let { items: t, activeIndex: n, orientation: r, onNavigate: i } = e;
3572
3580
  return (e) => {
3573
- let a = Wa[r][e.key];
3581
+ let a = qa[r][e.key];
3574
3582
  if (!a) return;
3575
- let o = Ga(t);
3583
+ let o = Ja(t);
3576
3584
  if (o.length === 0) return;
3577
3585
  e.preventDefault();
3578
3586
  let s = a(o.indexOf(n), o.length);
@@ -3580,32 +3588,32 @@ function qa(e) {
3580
3588
  };
3581
3589
  }
3582
3590
  // src/components/tabs/tabs.tsx
3583
- function Ja({ items: e, value: t, defaultIndex: n = 0, variant: r = "line", orientation: i = "horizontal", size: a = "md", radius: o = "md", fullWidth: s = !1, unstyled: c = !1, animated: u = !0, keepMounted: d = !1, className: p, tabListClassName: m, panelClassName: h, onChange: v }) {
3591
+ function Za({ items: e, value: t, defaultIndex: n = 0, variant: r = "line", orientation: i = "horizontal", size: a = "md", radius: o = "md", fullWidth: s = !1, unstyled: c = !1, animated: u = !0, keepMounted: d = !1, className: p, tabListClassName: m, panelClassName: h, onChange: v }) {
3584
3592
  let [y, b] = Ce(t, n), x = l(), S = f([]), C = f(null), w = (t) => {
3585
3593
  e[t]?.disabled || (b(t), v?.(t));
3586
3594
  }, T = (e) => {
3587
3595
  S.current[e]?.focus(), w(e);
3588
- }, E = Ka(e, y), D = qa({
3596
+ }, E = Ya(e, y), D = Xa({
3589
3597
  items: e,
3590
3598
  activeIndex: E,
3591
3599
  orientation: i,
3592
3600
  onNavigate: T
3593
- }), O = Da({
3601
+ }), O = Aa({
3594
3602
  orientation: i,
3595
3603
  unstyled: c,
3596
3604
  className: h
3597
3605
  }), k = u && !c;
3598
- return Ba({
3606
+ return Ua({
3599
3607
  activeIndex: y,
3600
3608
  indicatorRef: C,
3601
3609
  isAnimated: u,
3602
3610
  orientation: i
3603
3611
  }), /* @__PURE__ */ _("div", {
3604
- className: Ea(i, p),
3612
+ className: ka(i, p),
3605
3613
  children: [/* @__PURE__ */ g("div", {
3606
3614
  role: "tablist",
3607
3615
  "aria-orientation": i,
3608
- className: Oa({
3616
+ className: ja({
3609
3617
  variant: r,
3610
3618
  orientation: i,
3611
3619
  radius: o,
@@ -3613,7 +3621,7 @@ function Ja({ items: e, value: t, defaultIndex: n = 0, variant: r = "line", orie
3613
3621
  isFullWidth: s,
3614
3622
  className: m
3615
3623
  }),
3616
- children: e.map((e, t) => /* @__PURE__ */ g(ja, {
3624
+ children: e.map((e, t) => /* @__PURE__ */ g(Pa, {
3617
3625
  ref: (e) => {
3618
3626
  S.current[t] = e;
3619
3627
  },
@@ -3633,14 +3641,14 @@ function Ja({ items: e, value: t, defaultIndex: n = 0, variant: r = "line", orie
3633
3641
  onSelect: () => w(t),
3634
3642
  onKeyDown: D
3635
3643
  }, e.title))
3636
- }), d ? e.map((e, t) => /* @__PURE__ */ g(Ma, {
3644
+ }), d ? e.map((e, t) => /* @__PURE__ */ g(Fa, {
3637
3645
  panelId: `${x}-panel-${t}`,
3638
3646
  tabId: `${x}-tab-${t}`,
3639
3647
  isHidden: t !== y,
3640
3648
  isAnimated: k,
3641
3649
  className: O,
3642
3650
  children: e.content
3643
- }, e.title)) : /* @__PURE__ */ g(Ma, {
3651
+ }, e.title)) : /* @__PURE__ */ g(Fa, {
3644
3652
  panelId: `${x}-panel-${y}`,
3645
3653
  tabId: `${x}-tab-${y}`,
3646
3654
  isHidden: !1,
@@ -3652,7 +3660,7 @@ function Ja({ items: e, value: t, defaultIndex: n = 0, variant: r = "line", orie
3652
3660
  });
3653
3661
  }
3654
3662
  // src/components/textarea/textarea.tsx
3655
- function Ya({ label: e, description: t, error: n, showCharCount: r = !1, minLength: i, maxLength: a, radius: o = "md", unstyled: s = !1, className: c, wrapperClassName: l, value: u, defaultValue: d, onChange: f, id: p, "aria-describedby": m, ...h }) {
3663
+ function Qa({ label: e, description: t, error: n, showCharCount: r = !1, minLength: i, maxLength: a, radius: o = "md", unstyled: s = !1, className: c, wrapperClassName: l, value: u, defaultValue: d, onChange: f, id: p, "aria-describedby": m, ...h }) {
3656
3664
  let { fieldId: v, errorId: y, descriptionId: b, characterCountId: S } = J(p), { length: C, trackLength: w } = yi(u, d), T = r && (i !== void 0 || a !== void 0), E = (e) => {
3657
3665
  w(e.target.value), f?.(e);
3658
3666
  };
@@ -3690,7 +3698,7 @@ function Ya({ label: e, description: t, error: n, showCharCount: r = !1, minLeng
3690
3698
  });
3691
3699
  }
3692
3700
  // src/lib/is_webkit_gtk.ts
3693
- var Xa = "AppleWebKit", Za = ["Linux", "X11"], Qa = [
3701
+ var $a = "AppleWebKit", eo = ["Linux", "X11"], to = [
3694
3702
  "Chrome",
3695
3703
  "Chromium",
3696
3704
  "Edg",
@@ -3698,12 +3706,12 @@ var Xa = "AppleWebKit", Za = ["Linux", "X11"], Qa = [
3698
3706
  "CriOS",
3699
3707
  "FxiOS"
3700
3708
  ];
3701
- function $a(e) {
3702
- return !e.includes(Xa) || !Za.some((t) => e.includes(t)) ? !1 : !Qa.some((t) => e.includes(t));
3709
+ function no(e) {
3710
+ return !e.includes($a) || !eo.some((t) => e.includes(t)) ? !1 : !to.some((t) => e.includes(t));
3703
3711
  }
3704
3712
  // src/lib/theme_transition.ts
3705
- var eo = 750, to = "ease-in-out";
3706
- async function no({ theme: e, element: t, transitionDuration: n = eo, transitionEasing: r = to, applyThemeCallback: i }) {
3713
+ var ro = 750, io = "ease-in-out";
3714
+ async function ao({ theme: e, element: t, transitionDuration: n = ro, transitionEasing: r = io, applyThemeCallback: i }) {
3707
3715
  if (!document.startViewTransition || globalThis.matchMedia("(prefers-reduced-motion: reduce)").matches) {
3708
3716
  i(e);
3709
3717
  return;
@@ -3717,51 +3725,51 @@ async function no({ theme: e, element: t, transitionDuration: n = eo, transition
3717
3725
  pseudoElement: "::view-transition-new(root)"
3718
3726
  });
3719
3727
  }
3720
- function ro(e) {
3728
+ function oo(e) {
3721
3729
  return e === "light" ? "dark" : e === "dark" ? "system" : "light";
3722
3730
  }
3723
3731
  // src/stores/theme_store/theme_store.ts
3724
- var io = "theme";
3725
- function ao(e) {
3732
+ var so = "theme";
3733
+ function co(e) {
3726
3734
  return e === "light" || e === "dark" || e === "system";
3727
3735
  }
3728
- function oo() {
3736
+ function lo() {
3729
3737
  return globalThis.window !== void 0 && globalThis.document !== void 0;
3730
3738
  }
3731
- function so(e) {
3739
+ function uo(e) {
3732
3740
  let t = window.matchMedia("(prefers-color-scheme: dark)").matches, n = e === "dark" || e === "system" && t;
3733
3741
  document.documentElement.classList.toggle("dark", n);
3734
3742
  }
3735
- function co() {
3736
- if (!oo()) return "system";
3737
- let e = globalThis.localStorage.getItem(io);
3738
- return ao(e) ? e : "system";
3743
+ function fo() {
3744
+ if (!lo()) return "system";
3745
+ let e = globalThis.localStorage.getItem(so);
3746
+ return co(e) ? e : "system";
3739
3747
  }
3740
- var lo = co();
3741
- oo() && so(lo);
3742
- var uo = ui((e) => ({
3743
- theme: lo,
3748
+ var po = fo();
3749
+ lo() && uo(po);
3750
+ var mo = ui((e) => ({
3751
+ theme: po,
3744
3752
  setTheme: (t) => {
3745
- so(t), oo() && globalThis.localStorage.setItem(io, t), e({ theme: t });
3753
+ uo(t), lo() && globalThis.localStorage.setItem(so, t), e({ theme: t });
3746
3754
  }
3747
3755
  }));
3748
- oo() && (globalThis.addEventListener("storage", (e) => {
3749
- if (e.key !== io) return;
3750
- let t = ao(e.newValue) ? e.newValue : "system";
3751
- so(t), uo.setState({ theme: t });
3756
+ lo() && (globalThis.addEventListener("storage", (e) => {
3757
+ if (e.key !== so) return;
3758
+ let t = co(e.newValue) ? e.newValue : "system";
3759
+ uo(t), mo.setState({ theme: t });
3752
3760
  }), globalThis.matchMedia("(prefers-color-scheme: dark)").addEventListener("change", () => {
3753
- uo.getState().theme === "system" && so("system");
3761
+ mo.getState().theme === "system" && uo("system");
3754
3762
  }));
3755
3763
  // src/components/theme_toggle/theme_toggle.tsx
3756
- var fo = {
3764
+ var ho = {
3757
3765
  light: "i-tabler-sun text-yellow-500",
3758
3766
  dark: "i-tabler-moon-stars text-gray-700 dark:text-yellow-500",
3759
3767
  system: "i-tabler-device-desktop text-blue-500"
3760
- }, po = "i-tabler-device-desktop text-gray-400";
3761
- function mo({ isTransitionEnabled: e, transitionDuration: t, transitionEasing: n, size: r = "md", radius: i, variant: a, getAriaLabel: s, tooltip: c }) {
3762
- let l = uo((e) => e.theme), u = uo((e) => e.setTheme), d = Ae(), p = Ne(), m = f(null), h = o(async () => {
3763
- let r = ro(l), i = m.current, a = e ?? !$a(navigator.userAgent);
3764
- i && a ? await no({
3768
+ }, go = "i-tabler-device-desktop text-gray-400";
3769
+ function _o({ isTransitionEnabled: e, transitionDuration: t, transitionEasing: n, size: r = "md", radius: i, variant: a, getAriaLabel: s, tooltip: c }) {
3770
+ let l = mo((e) => e.theme), u = mo((e) => e.setTheme), d = Ae(), p = Ne(), m = f(null), h = o(async () => {
3771
+ let r = oo(l), i = m.current, a = e ?? !no(navigator.userAgent);
3772
+ i && a ? await ao({
3765
3773
  theme: r,
3766
3774
  element: i,
3767
3775
  transitionDuration: t,
@@ -3774,7 +3782,7 @@ function mo({ isTransitionEnabled: e, transitionDuration: t, transitionEasing: n
3774
3782
  t,
3775
3783
  n,
3776
3784
  u
3777
- ]), _ = p ? fo[l] : po;
3785
+ ]), _ = p ? ho[l] : go;
3778
3786
  return /* @__PURE__ */ g(Er, {
3779
3787
  ref: m,
3780
3788
  icon: _,
@@ -3789,7 +3797,7 @@ function mo({ isTransitionEnabled: e, transitionDuration: t, transitionEasing: n
3789
3797
  });
3790
3798
  }
3791
3799
  // src/components/toolbar/toolbar_items.ts
3792
- var ho = "a[href], button, input:not([type=\"hidden\"]), select, textarea, summary, [contenteditable]:not([contenteditable=\"false\"]), [tabindex]", go = [
3800
+ var vo = "a[href], button, input:not([type=\"hidden\"]), select, textarea, summary, [contenteditable]:not([contenteditable=\"false\"]), [tabindex]", yo = [
3793
3801
  "textarea",
3794
3802
  "[contenteditable]:not([contenteditable=\"false\"])",
3795
3803
  `input:not(${[
@@ -3804,45 +3812,45 @@ var ho = "a[href], button, input:not([type=\"hidden\"]), select, textarea, summa
3804
3812
  "submit"
3805
3813
  ].map((e) => `[type="${e}"]`).join(", ")})`
3806
3814
  ].join(", ");
3807
- function _o(e) {
3815
+ function bo(e) {
3808
3816
  return e.matches(":disabled, [aria-disabled=\"true\"]");
3809
3817
  }
3810
- function vo(e) {
3811
- return Array.from(e.querySelectorAll(ho));
3818
+ function xo(e) {
3819
+ return Array.from(e.querySelectorAll(vo));
3812
3820
  }
3813
- function yo(e) {
3814
- return vo(e).filter((e) => !_o(e));
3821
+ function So(e) {
3822
+ return xo(e).filter((e) => !bo(e));
3815
3823
  }
3816
- function bo(e) {
3817
- return e instanceof HTMLElement && e.matches(go);
3824
+ function Co(e) {
3825
+ return e instanceof HTMLElement && e.matches(yo);
3818
3826
  }
3819
3827
  // src/components/toolbar/toolbar_navigation.ts
3820
- var xo = (e, t) => (e + 1) % t, So = (e, t) => (e - 1 + t) % t, Co = () => 0, wo = (e, t) => t - 1, To = {
3828
+ var wo = (e, t) => (e + 1) % t, To = (e, t) => (e - 1 + t) % t, Eo = () => 0, Do = (e, t) => t - 1, Oo = {
3821
3829
  horizontal: {
3822
- ArrowRight: xo,
3823
- ArrowLeft: So,
3824
- Home: Co,
3825
- End: wo
3830
+ ArrowRight: wo,
3831
+ ArrowLeft: To,
3832
+ Home: Eo,
3833
+ End: Do
3826
3834
  },
3827
3835
  vertical: {
3828
- ArrowDown: xo,
3829
- ArrowUp: So,
3830
- Home: Co,
3831
- End: wo
3836
+ ArrowDown: wo,
3837
+ ArrowUp: To,
3838
+ Home: Eo,
3839
+ End: Do
3832
3840
  }
3833
3841
  };
3834
- function Eo(e) {
3835
- let { key: t, orientation: n, currentPosition: r, itemCount: i } = e, a = To[n][t];
3842
+ function ko(e) {
3843
+ let { key: t, orientation: n, currentPosition: r, itemCount: i } = e, a = Oo[n][t];
3836
3844
  if (a && i !== 0) return a(r, i);
3837
3845
  }
3838
3846
  // src/components/toolbar/use_toolbar_roving_focus.ts
3839
- var Do = ["disabled", "aria-disabled"];
3840
- function Oo(e, t) {
3847
+ var Ao = ["disabled", "aria-disabled"];
3848
+ function jo(e, t) {
3841
3849
  let n = f(null), r = o(() => {
3842
3850
  let t = e.current;
3843
3851
  if (!t) return;
3844
- let r = yo(t), i = n.current, a = i && r.includes(i) ? i : r[0];
3845
- for (let e of vo(t)) e.tabIndex = e === a ? 0 : -1;
3852
+ let r = So(t), i = n.current, a = i && r.includes(i) ? i : r[0];
3853
+ for (let e of xo(t)) e.tabIndex = e === a ? 0 : -1;
3846
3854
  }, [e]);
3847
3855
  return c(() => {
3848
3856
  let t = e.current;
@@ -3853,19 +3861,19 @@ function Oo(e, t) {
3853
3861
  subtree: !0,
3854
3862
  childList: !0,
3855
3863
  attributes: !0,
3856
- attributeFilter: Do
3864
+ attributeFilter: Ao
3857
3865
  }), () => n.disconnect();
3858
3866
  }, [e, r]), {
3859
3867
  handleFocus: (t) => {
3860
3868
  let i = e.current;
3861
3869
  if (!i) return;
3862
- let a = yo(i).find((e) => e === t.target);
3870
+ let a = So(i).find((e) => e === t.target);
3863
3871
  a && (n.current = a, r());
3864
3872
  },
3865
3873
  handleKeyDown: (n) => {
3866
3874
  let r = e.current;
3867
- if (!r || bo(n.target)) return;
3868
- let i = yo(r), a = Eo({
3875
+ if (!r || Co(n.target)) return;
3876
+ let i = So(r), a = ko({
3869
3877
  key: n.key,
3870
3878
  orientation: t,
3871
3879
  currentPosition: i.findIndex((e) => e === n.target),
@@ -3876,18 +3884,18 @@ function Oo(e, t) {
3876
3884
  };
3877
3885
  }
3878
3886
  // src/components/toolbar/toolbar.tsx
3879
- var ko = {
3887
+ var Mo = {
3880
3888
  horizontal: "flex items-center gap-1",
3881
3889
  vertical: "flex flex-col items-stretch gap-1"
3882
3890
  };
3883
- function Ao(e) {
3884
- let { orientation: t = "horizontal", unstyled: n = !1, className: r, ref: i, onFocus: a, onKeyDown: o, ...s } = e, c = f(null), { handleFocus: l, handleKeyDown: u } = Oo(c, t);
3891
+ function No(e) {
3892
+ let { orientation: t = "horizontal", unstyled: n = !1, className: r, ref: i, onFocus: a, onKeyDown: o, ...s } = e, c = f(null), { handleFocus: l, handleKeyDown: u } = jo(c, t);
3885
3893
  return /* @__PURE__ */ g("div", {
3886
3894
  ...s,
3887
3895
  ref: we(c, i),
3888
3896
  role: "toolbar",
3889
3897
  "aria-orientation": t,
3890
- className: x(!n && ko[t], r),
3898
+ className: x(!n && Mo[t], r),
3891
3899
  onFocus: (e) => {
3892
3900
  l(e), a?.(e);
3893
3901
  },
@@ -3897,13 +3905,13 @@ function Ao(e) {
3897
3905
  });
3898
3906
  }
3899
3907
  // src/components/ui_provider/ui_provider.tsx
3900
- function jo(e = {}) {
3908
+ function Po(e = {}) {
3901
3909
  return Object.fromEntries(Object.entries(e).filter(([, e]) => e !== void 0));
3902
3910
  }
3903
- function Mo({ labels: e, announceFieldErrors: t, children: n }) {
3911
+ function Fo({ labels: e, announceFieldErrors: t, children: n }) {
3904
3912
  let r = s(ke), i = ye(), a = d(() => ({
3905
3913
  ...r,
3906
- ...jo(e)
3914
+ ...Po(e)
3907
3915
  }), [r, e]);
3908
3916
  return /* @__PURE__ */ g(ke.Provider, {
3909
3917
  value: a,
@@ -3914,10 +3922,10 @@ function Mo({ labels: e, announceFieldErrors: t, children: n }) {
3914
3922
  });
3915
3923
  }
3916
3924
  // src/hooks/use_is_client/with_client_only.tsx
3917
- var No = (e) => {
3925
+ var Io = (e) => {
3918
3926
  function t(t) {
3919
3927
  return Ne() ? /* @__PURE__ */ g(e, { ...t }) : null;
3920
3928
  }
3921
3929
  return t;
3922
3930
  };
3923
- export { I as Avatar, fe as BASE_INPUT_STYLES, R as Badge, te as Button, K as Card, le as CharacterCount, Ee as Checkbox, Me as CheckboxOptions, Pe as ClientOnly, ze as Combobox, Xi as ConfirmModal, Qn as ContextMenu, tr as CopyButton, _i as Drawer, ir as Highlight, Er as IconButton, bi as Input, Si as Kbd, Ti as Menu, Ei as MenuGroup, Li as MenuItem, Ri as MenuSeparator, Qi as Modal, $i as ModalFooter, ta as ModalProvider, sa as MultiCombobox, la as RadioOptions, ua as Select, da as Switch, Ja as Tabs, Ya as Textarea, mo as ThemeToggle, Ao as Toolbar, Sr as Tooltip, Mo as UIProvider, nr as splitIntoHighlightSegments, pi as useDisableHotkeysWhileMounted, ea as useDismissGuard, di as useGlobalHotkeysStore, Ne as useIsClient, uo as useThemeStore, No as withClientOnly };
3931
+ export { I as Avatar, fe as BASE_INPUT_STYLES, R as Badge, te as Button, K as Card, le as CharacterCount, Ee as Checkbox, Me as CheckboxOptions, Pe as ClientOnly, ze as Combobox, $i as ConfirmModal, Qn as ContextMenu, tr as CopyButton, _i as Drawer, ir as Highlight, Er as IconButton, bi as Input, Si as Kbd, Ti as Menu, Ei as MenuGroup, Bi as MenuItem, Vi as MenuSeparator, ta as Modal, na as ModalFooter, ia as ModalProvider, ua as MultiCombobox, fa as RadioOptions, pa as Select, ma as Switch, Za as Tabs, Qa as Textarea, _o as ThemeToggle, No as Toolbar, Sr as Tooltip, Fo as UIProvider, nr as splitIntoHighlightSegments, pi as useDisableHotkeysWhileMounted, ra as useDismissGuard, di as useGlobalHotkeysStore, Ne as useIsClient, mo as useThemeStore, Io as withClientOnly };