vxui-react 1.2.6 → 1.2.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,6 +1,6 @@
1
- import { jsx as a, Fragment as J, jsxs as k } from "react/jsx-runtime";
1
+ import { jsx as a, Fragment as ee, jsxs as k } from "react/jsx-runtime";
2
2
  import * as _ from "react";
3
- import ue, { useState as I, useEffect as $, useContext as ye, createContext as _e, forwardRef as ce, createElement as pt, useRef as z, useMemo as Ne, useCallback as q, useId as fn, useLayoutEffect as mn } from "react";
3
+ import ue, { useState as I, useEffect as z, useContext as ye, createContext as _e, forwardRef as ce, createElement as pt, useRef as B, useMemo as Ne, useId as fn, useLayoutEffect as mn, useCallback as Y } from "react";
4
4
  import * as hn from "react-dom";
5
5
  import jr, { createPortal as yt } from "react-dom";
6
6
  const Kr = 767, Vr = 1023;
@@ -21,7 +21,7 @@ function zt() {
21
21
  }
22
22
  function Wi({ children: e }) {
23
23
  const [t, n] = I(Bt), [r, o] = I(zt);
24
- $(() => {
24
+ z(() => {
25
25
  const i = () => {
26
26
  const d = Bt();
27
27
  n((u) => u === d ? u : d);
@@ -44,7 +44,7 @@ function bn() {
44
44
  }
45
45
  function Hi({ desktop: e, mobile: t, tablet: n }) {
46
46
  const { viewport: r } = bn();
47
- return r === "phone" ? /* @__PURE__ */ a(J, { children: t }) : r === "tablet" ? /* @__PURE__ */ a(J, { children: n ?? e }) : /* @__PURE__ */ a(J, { children: e });
47
+ return r === "phone" ? /* @__PURE__ */ a(ee, { children: t }) : r === "tablet" ? /* @__PURE__ */ a(ee, { children: n ?? e }) : /* @__PURE__ */ a(ee, { children: e });
48
48
  }
49
49
  /**
50
50
  * @license lucide-react v0.511.0 - ISC
@@ -121,7 +121,7 @@ const Qr = ce(
121
121
  * This source code is licensed under the ISC license.
122
122
  * See the LICENSE file in the root directory of this source tree.
123
123
  */
124
- const Q = (e, t) => {
124
+ const J = (e, t) => {
125
125
  const n = ce(
126
126
  ({ className: r, ...o }, s) => pt(Qr, {
127
127
  ref: s,
@@ -142,28 +142,28 @@ const Q = (e, t) => {
142
142
  * This source code is licensed under the ISC license.
143
143
  * See the LICENSE file in the root directory of this source tree.
144
144
  */
145
- const Jr = [["path", { d: "M20 6 9 17l-5-5", key: "1gmf2c" }]], Ke = Q("check", Jr);
145
+ const Jr = [["path", { d: "M20 6 9 17l-5-5", key: "1gmf2c" }]], Ke = J("check", Jr);
146
146
  /**
147
147
  * @license lucide-react v0.511.0 - ISC
148
148
  *
149
149
  * This source code is licensed under the ISC license.
150
150
  * See the LICENSE file in the root directory of this source tree.
151
151
  */
152
- const ea = [["path", { d: "m6 9 6 6 6-6", key: "qrunsl" }]], Ee = Q("chevron-down", ea);
152
+ const ea = [["path", { d: "m6 9 6 6 6-6", key: "qrunsl" }]], Ee = J("chevron-down", ea);
153
153
  /**
154
154
  * @license lucide-react v0.511.0 - ISC
155
155
  *
156
156
  * This source code is licensed under the ISC license.
157
157
  * See the LICENSE file in the root directory of this source tree.
158
158
  */
159
- const ta = [["path", { d: "m15 18-6-6 6-6", key: "1wnfg3" }]], yn = Q("chevron-left", ta);
159
+ const ta = [["path", { d: "m15 18-6-6 6-6", key: "1wnfg3" }]], yn = J("chevron-left", ta);
160
160
  /**
161
161
  * @license lucide-react v0.511.0 - ISC
162
162
  *
163
163
  * This source code is licensed under the ISC license.
164
164
  * See the LICENSE file in the root directory of this source tree.
165
165
  */
166
- const na = [["path", { d: "m9 18 6-6-6-6", key: "mthhwq" }]], Ce = Q("chevron-right", na);
166
+ const na = [["path", { d: "m9 18 6-6-6-6", key: "mthhwq" }]], Te = J("chevron-right", na);
167
167
  /**
168
168
  * @license lucide-react v0.511.0 - ISC
169
169
  *
@@ -174,7 +174,7 @@ const ra = [
174
174
  ["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
175
175
  ["line", { x1: "12", x2: "12", y1: "8", y2: "12", key: "1pkeuh" }],
176
176
  ["line", { x1: "12", x2: "12.01", y1: "16", y2: "16", key: "4dfq90" }]
177
- ], aa = Q("circle-alert", ra);
177
+ ], aa = J("circle-alert", ra);
178
178
  /**
179
179
  * @license lucide-react v0.511.0 - ISC
180
180
  *
@@ -184,7 +184,7 @@ const ra = [
184
184
  const oa = [
185
185
  ["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
186
186
  ["path", { d: "m9 12 2 2 4-4", key: "dzmm74" }]
187
- ], sa = Q("circle-check", oa);
187
+ ], sa = J("circle-check", oa);
188
188
  /**
189
189
  * @license lucide-react v0.511.0 - ISC
190
190
  *
@@ -194,7 +194,7 @@ const oa = [
194
194
  const ia = [
195
195
  ["rect", { width: "14", height: "14", x: "8", y: "8", rx: "2", ry: "2", key: "17jyea" }],
196
196
  ["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" }]
197
- ], la = Q("copy", ia);
197
+ ], la = J("copy", ia);
198
198
  /**
199
199
  * @license lucide-react v0.511.0 - ISC
200
200
  *
@@ -204,7 +204,7 @@ const ia = [
204
204
  const ca = [
205
205
  ["path", { d: "M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z", key: "1rqfz7" }],
206
206
  ["path", { d: "M14 2v4a2 2 0 0 0 2 2h4", key: "tnqrlb" }]
207
- ], da = Q("file", ca);
207
+ ], da = J("file", ca);
208
208
  /**
209
209
  * @license lucide-react v0.511.0 - ISC
210
210
  *
@@ -215,7 +215,7 @@ const ua = [
215
215
  ["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
216
216
  ["path", { d: "M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20", key: "13o1zl" }],
217
217
  ["path", { d: "M2 12h20", key: "9i4pu4" }]
218
- ], pa = Q("globe", ua);
218
+ ], pa = J("globe", ua);
219
219
  /**
220
220
  * @license lucide-react v0.511.0 - ISC
221
221
  *
@@ -226,7 +226,7 @@ const va = [
226
226
  ["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
227
227
  ["path", { d: "M12 16v-4", key: "1dtifu" }],
228
228
  ["path", { d: "M12 8h.01", key: "e9boi3" }]
229
- ], fa = Q("info", va);
229
+ ], fa = J("info", va);
230
230
  /**
231
231
  * @license lucide-react v0.511.0 - ISC
232
232
  *
@@ -237,7 +237,7 @@ const ma = [
237
237
  ["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", key: "afitv7" }],
238
238
  ["path", { d: "M9 3v18", key: "fh3hqa" }],
239
239
  ["path", { d: "m16 15-3-3 3-3", key: "14y99z" }]
240
- ], _n = Q("panel-left-close", ma);
240
+ ], _n = J("panel-left-close", ma);
241
241
  /**
242
242
  * @license lucide-react v0.511.0 - ISC
243
243
  *
@@ -248,7 +248,7 @@ const ha = [
248
248
  ["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", key: "afitv7" }],
249
249
  ["path", { d: "M9 3v18", key: "fh3hqa" }],
250
250
  ["path", { d: "m14 9 3 3-3 3", key: "8010ee" }]
251
- ], wn = Q("panel-left-open", ha);
251
+ ], wn = J("panel-left-open", ha);
252
252
  /**
253
253
  * @license lucide-react v0.511.0 - ISC
254
254
  *
@@ -265,7 +265,7 @@ const ga = [
265
265
  ],
266
266
  ["path", { d: "M12 9v4", key: "juzpu7" }],
267
267
  ["path", { d: "M12 17h.01", key: "p32p05" }]
268
- ], ba = Q("triangle-alert", ga);
268
+ ], ba = J("triangle-alert", ga);
269
269
  /**
270
270
  * @license lucide-react v0.511.0 - ISC
271
271
  *
@@ -276,7 +276,7 @@ const xa = [
276
276
  ["path", { d: "M12 3v12", key: "1x0j5s" }],
277
277
  ["path", { d: "m17 8-5-5-5 5", key: "7q97r8" }],
278
278
  ["path", { d: "M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4", key: "ih7n3h" }]
279
- ], ya = Q("upload", xa);
279
+ ], ya = J("upload", xa);
280
280
  /**
281
281
  * @license lucide-react v0.511.0 - ISC
282
282
  *
@@ -286,8 +286,8 @@ const xa = [
286
286
  const _a = [
287
287
  ["path", { d: "M18 6 6 18", key: "1bl5f8" }],
288
288
  ["path", { d: "m6 6 12 12", key: "d8bk6v" }]
289
- ], le = Q("x", _a);
290
- function C(...e) {
289
+ ], le = J("x", _a);
290
+ function T(...e) {
291
291
  return e.filter(Boolean).join(" ");
292
292
  }
293
293
  const xe = ce(function({
@@ -311,7 +311,7 @@ const xe = ce(function({
311
311
  type: u,
312
312
  disabled: c || l,
313
313
  "aria-busy": l || void 0,
314
- className: C(
314
+ className: T(
315
315
  "vx-button",
316
316
  `vx-button--${n}`,
317
317
  `vx-button--${r}`,
@@ -332,7 +332,7 @@ const xe = ce(function({
332
332
  );
333
333
  }), vt = _e(!1);
334
334
  function kn(e, t) {
335
- $(() => {
335
+ z(() => {
336
336
  const n = e.current, r = t.current;
337
337
  if (!n || !r) return;
338
338
  let o;
@@ -363,7 +363,7 @@ function wa({ collapsed: e = !1, mobileNavOpen: t = !1, density: n, sidebarWidth
363
363
  return /* @__PURE__ */ a(vt.Provider, { value: e, children: /* @__PURE__ */ a(
364
364
  "div",
365
365
  {
366
- className: C("vx-shell", o),
366
+ className: T("vx-shell", o),
367
367
  "data-collapsed": e,
368
368
  "data-nav-open": t,
369
369
  "data-tablet": l,
@@ -386,7 +386,7 @@ function ka({
386
386
  onSidebarClick: d,
387
387
  children: c
388
388
  }) {
389
- const u = z(null), p = z(null);
389
+ const u = B(null), p = B(null);
390
390
  return kn(u, p), /* @__PURE__ */ k(
391
391
  "aside",
392
392
  {
@@ -447,8 +447,8 @@ function Sa({ title: e, children: t }) {
447
447
  ] });
448
448
  }
449
449
  function Ea({ label: e, icon: t, badge: n, trailing: r, active: o, onSelect: s, children: l, defaultOpen: i = !1 }) {
450
- const [d, c] = I(i), [u, p] = I(!1), [b, w] = I({ top: 0, left: 0 }), S = z(null), g = z(void 0), h = ye(vt), y = !!l;
451
- $(() => () => {
450
+ const [d, c] = I(i), [u, p] = I(!1), [b, w] = I({ top: 0, left: 0 }), S = B(null), g = B(void 0), h = ye(vt), y = !!l;
451
+ z(() => () => {
452
452
  g.current !== void 0 && clearTimeout(g.current);
453
453
  }, []);
454
454
  const v = () => {
@@ -456,7 +456,7 @@ function Ea({ label: e, icon: t, badge: n, trailing: r, active: o, onSelect: s,
456
456
  }, f = () => {
457
457
  if (!h || !y || !S.current) return;
458
458
  g.current !== void 0 && clearTimeout(g.current);
459
- const E = S.current.getBoundingClientRect(), T = S.current.closest(".vx-sidebar"), A = T ? T.getBoundingClientRect().right : E.right;
459
+ const E = S.current.getBoundingClientRect(), C = S.current.closest(".vx-sidebar"), A = C ? C.getBoundingClientRect().right : E.right;
460
460
  w({ top: E.top - 6, left: A + 4 }), p(!0);
461
461
  }, m = () => {
462
462
  g.current = setTimeout(() => p(!1), 100);
@@ -466,7 +466,7 @@ function Ea({ label: e, icon: t, badge: n, trailing: r, active: o, onSelect: s,
466
466
  "button",
467
467
  {
468
468
  type: "button",
469
- className: C("vx-nav-item", o && "vx-nav-item--active", y && "vx-nav-item--parent"),
469
+ className: T("vx-nav-item", o && "vx-nav-item--active", y && "vx-nav-item--parent"),
470
470
  onClick: v,
471
471
  "aria-expanded": y && !h ? d : void 0,
472
472
  title: h ? e : void 0,
@@ -474,7 +474,7 @@ function Ea({ label: e, icon: t, badge: n, trailing: r, active: o, onSelect: s,
474
474
  t ? /* @__PURE__ */ a("span", { className: "vx-nav-item__icon", children: t }) : null,
475
475
  /* @__PURE__ */ a("span", { className: "vx-nav-item__label", children: e }),
476
476
  n ? /* @__PURE__ */ a("span", { className: "vx-nav-item__badge", children: n }) : null,
477
- y ? /* @__PURE__ */ a(Ce, { size: 14, className: C("vx-nav-item__chevron", d && "vx-nav-item__chevron--open") }) : r ? /* @__PURE__ */ a("span", { className: "vx-nav-item__trailing", children: r }) : null
477
+ y ? /* @__PURE__ */ a(Te, { size: 14, className: T("vx-nav-item__chevron", d && "vx-nav-item__chevron--open") }) : r ? /* @__PURE__ */ a("span", { className: "vx-nav-item__trailing", children: r }) : null
478
478
  ]
479
479
  }
480
480
  );
@@ -509,7 +509,7 @@ function Ea({ label: e, icon: t, badge: n, trailing: r, active: o, onSelect: s,
509
509
  }
510
510
  ) : N;
511
511
  }
512
- function Ca({ onClose: e, closeLabel: t = "Close sidebar" }) {
512
+ function Ta({ onClose: e, closeLabel: t = "Close sidebar" }) {
513
513
  return /* @__PURE__ */ a(
514
514
  "button",
515
515
  {
@@ -520,7 +520,7 @@ function Ca({ onClose: e, closeLabel: t = "Close sidebar" }) {
520
520
  }
521
521
  );
522
522
  }
523
- function Ta({ children: e }) {
523
+ function Ca({ children: e }) {
524
524
  return /* @__PURE__ */ a("div", { className: "vx-shell__main", children: e });
525
525
  }
526
526
  const Aa = ce(function({
@@ -552,7 +552,7 @@ const Aa = ce(function({
552
552
  ] });
553
553
  });
554
554
  function Pa({ children: e }) {
555
- const t = z(null), n = z(null);
555
+ const t = B(null), n = B(null);
556
556
  return kn(t, n), /* @__PURE__ */ k(
557
557
  "div",
558
558
  {
@@ -597,17 +597,17 @@ function Gi({
597
597
  children: N
598
598
  }) {
599
599
  const E = d ?? (i ? [{ items: i }] : []);
600
- function T(A) {
601
- const { key: P, onSelect: R, children: L, defaultOpen: B, ...D } = A, W = (L == null ? void 0 : L.some((G) => G.active)) ?? !1;
600
+ function C(A) {
601
+ const { key: R, onSelect: P, children: L, defaultOpen: $, ...D } = A, U = (L == null ? void 0 : L.some((H) => H.active)) ?? !1;
602
602
  return /* @__PURE__ */ a(
603
603
  Ea,
604
604
  {
605
- onSelect: R,
606
- defaultOpen: B ?? (L ? W : void 0),
605
+ onSelect: P,
606
+ defaultOpen: $ ?? (L ? U : void 0),
607
607
  ...D,
608
- children: L == null ? void 0 : L.map(T)
608
+ children: L == null ? void 0 : L.map(C)
609
609
  },
610
- P
610
+ R
611
611
  );
612
612
  }
613
613
  return /* @__PURE__ */ k(wa, { collapsed: c, mobileNavOpen: p, density: f, sidebarWidth: u, children: [
@@ -623,11 +623,11 @@ function Gi({
623
623
  onSidebarClick: S,
624
624
  collapseLabel: h,
625
625
  expandLabel: y,
626
- children: /* @__PURE__ */ a(Na, { children: E.map((A, P) => /* @__PURE__ */ a(Sa, { title: A.title, children: A.items.map(T) }, A.key ?? A.title ?? P)) })
626
+ children: /* @__PURE__ */ a(Na, { children: E.map((A, R) => /* @__PURE__ */ a(Sa, { title: A.title, children: A.items.map(C) }, A.key ?? A.title ?? R)) })
627
627
  }
628
628
  ),
629
- w ? /* @__PURE__ */ a(Ca, { onClose: w, closeLabel: v }) : null,
630
- /* @__PURE__ */ k(Ta, { children: [
629
+ w ? /* @__PURE__ */ a(Ta, { onClose: w, closeLabel: v }) : null,
630
+ /* @__PURE__ */ k(Ca, { children: [
631
631
  /* @__PURE__ */ a(
632
632
  Aa,
633
633
  {
@@ -646,13 +646,13 @@ function Gi({
646
646
  ] });
647
647
  }
648
648
  function ji({ className: e, variant: t = "neutral", ...n }) {
649
- return /* @__PURE__ */ a("span", { className: C("vx-badge", `vx-badge--${t}`, e), ...n });
649
+ return /* @__PURE__ */ a("span", { className: T("vx-badge", `vx-badge--${t}`, e), ...n });
650
650
  }
651
651
  function Ki({ className: e, variant: t = "default", padding: n, hoverable: r = !1, ...o }) {
652
652
  return /* @__PURE__ */ a(
653
653
  "section",
654
654
  {
655
- className: C(
655
+ className: T(
656
656
  "vx-card",
657
657
  t !== "default" && `vx-card--${t}`,
658
658
  n && `vx-card--pad-${n}`,
@@ -664,18 +664,18 @@ function Ki({ className: e, variant: t = "default", padding: n, hoverable: r = !
664
664
  );
665
665
  }
666
666
  function Vi({ className: e, ...t }) {
667
- return /* @__PURE__ */ a("header", { className: C("vx-card__header", e), ...t });
667
+ return /* @__PURE__ */ a("header", { className: T("vx-card__header", e), ...t });
668
668
  }
669
669
  function qi({ className: e, ...t }) {
670
- return /* @__PURE__ */ a("h2", { className: C("vx-card__title", e), ...t });
670
+ return /* @__PURE__ */ a("h2", { className: T("vx-card__title", e), ...t });
671
671
  }
672
672
  function Yi({ className: e, ...t }) {
673
- return /* @__PURE__ */ a("p", { className: C("vx-card__description", e), ...t });
673
+ return /* @__PURE__ */ a("p", { className: T("vx-card__description", e), ...t });
674
674
  }
675
675
  function Xi({ className: e, ...t }) {
676
- return /* @__PURE__ */ a("div", { className: C("vx-card__content", e), ...t });
676
+ return /* @__PURE__ */ a("div", { className: T("vx-card__content", e), ...t });
677
677
  }
678
- function j(e, t, { checkForDefaultPrevented: n = !0 } = {}) {
678
+ function G(e, t, { checkForDefaultPrevented: n = !0 } = {}) {
679
679
  return function(o) {
680
680
  if (e == null || e(o), n === !1 || !o.defaultPrevented)
681
681
  return t == null ? void 0 : t(o);
@@ -702,7 +702,7 @@ function Nn(...e) {
702
702
  };
703
703
  };
704
704
  }
705
- function ee(...e) {
705
+ function te(...e) {
706
706
  return _.useCallback(Nn(...e), e);
707
707
  }
708
708
  function Ra(e, t) {
@@ -779,7 +779,7 @@ function Se(e) {
779
779
  }, [e]), e || (t ? `radix-${t}` : "");
780
780
  }
781
781
  var Ia = _[" useInsertionEffect ".trim().toString()] || pe;
782
- function Te({
782
+ function Ce({
783
783
  prop: e,
784
784
  defaultProp: t,
785
785
  onChange: n = () => {
@@ -803,7 +803,7 @@ function Te({
803
803
  (u) => {
804
804
  var p;
805
805
  if (i) {
806
- const b = Oa(u) ? u(e) : u;
806
+ const b = $a(u) ? u(e) : u;
807
807
  b !== e && ((p = l.current) == null || p.call(l, b));
808
808
  } else
809
809
  s(u);
@@ -824,12 +824,12 @@ function Ma({
824
824
  o.current !== n && ((l = s.current) == null || l.call(s, n), o.current = n);
825
825
  }, [n, o]), [n, r, s];
826
826
  }
827
- function Oa(e) {
827
+ function $a(e) {
828
828
  return typeof e == "function";
829
829
  }
830
830
  // @__NO_SIDE_EFFECTS__
831
831
  function We(e) {
832
- const t = /* @__PURE__ */ $a(e), n = _.forwardRef((r, o) => {
832
+ const t = /* @__PURE__ */ Oa(e), n = _.forwardRef((r, o) => {
833
833
  const { children: s, ...l } = r, i = _.Children.toArray(s), d = i.find(za);
834
834
  if (d) {
835
835
  const c = d.props.children, u = i.map((p) => p === d ? _.Children.count(c) > 1 ? _.Children.only(null) : _.isValidElement(c) ? c.props.children : null : p);
@@ -840,7 +840,7 @@ function We(e) {
840
840
  return n.displayName = `${e}.Slot`, n;
841
841
  }
842
842
  // @__NO_SIDE_EFFECTS__
843
- function $a(e) {
843
+ function Oa(e) {
844
844
  const t = _.forwardRef((n, r) => {
845
845
  const { children: o, ...s } = n;
846
846
  if (_.isValidElement(o)) {
@@ -931,12 +931,12 @@ var ja = "DismissableLayer", ft = "dismissableLayer.update", Ka = "dismissableLa
931
931
  onInteractOutside: l,
932
932
  onDismiss: i,
933
933
  ...d
934
- } = e, c = _.useContext(En), [u, p] = _.useState(null), b = (u == null ? void 0 : u.ownerDocument) ?? (globalThis == null ? void 0 : globalThis.document), [, w] = _.useState({}), S = ee(t, (E) => p(E)), g = Array.from(c.layers), [h] = [...c.layersWithOutsidePointerEventsDisabled].slice(-1), y = g.indexOf(h), v = u ? g.indexOf(u) : -1, f = c.layersWithOutsidePointerEventsDisabled.size > 0, m = v >= y, x = Ya((E) => {
935
- const T = E.target, A = [...c.branches].some((P) => P.contains(T));
934
+ } = e, c = _.useContext(En), [u, p] = _.useState(null), b = (u == null ? void 0 : u.ownerDocument) ?? (globalThis == null ? void 0 : globalThis.document), [, w] = _.useState({}), S = te(t, (E) => p(E)), g = Array.from(c.layers), [h] = [...c.layersWithOutsidePointerEventsDisabled].slice(-1), y = g.indexOf(h), v = u ? g.indexOf(u) : -1, f = c.layersWithOutsidePointerEventsDisabled.size > 0, m = v >= y, x = Ya((E) => {
935
+ const C = E.target, A = [...c.branches].some((R) => R.contains(C));
936
936
  !m || A || (o == null || o(E), l == null || l(E), E.defaultPrevented || i == null || i());
937
937
  }, b), N = Xa((E) => {
938
- const T = E.target;
939
- [...c.branches].some((P) => P.contains(T)) || (s == null || s(E), l == null || l(E), E.defaultPrevented || i == null || i());
938
+ const C = E.target;
939
+ [...c.branches].some((R) => R.contains(C)) || (s == null || s(E), l == null || l(E), E.defaultPrevented || i == null || i());
940
940
  }, b);
941
941
  return Ga((E) => {
942
942
  v === c.layers.size - 1 && (r == null || r(E), !E.defaultPrevented && i && (E.preventDefault(), i()));
@@ -959,9 +959,9 @@ var ja = "DismissableLayer", ft = "dismissableLayer.update", Ka = "dismissableLa
959
959
  pointerEvents: f ? m ? "auto" : "none" : void 0,
960
960
  ...e.style
961
961
  },
962
- onFocusCapture: j(e.onFocusCapture, N.onFocusCapture),
963
- onBlurCapture: j(e.onBlurCapture, N.onBlurCapture),
964
- onPointerDownCapture: j(
962
+ onFocusCapture: G(e.onFocusCapture, N.onFocusCapture),
963
+ onBlurCapture: G(e.onBlurCapture, N.onBlurCapture),
964
+ onPointerDownCapture: G(
965
965
  e.onPointerDownCapture,
966
966
  x.onPointerDownCapture
967
967
  )
@@ -970,8 +970,8 @@ var ja = "DismissableLayer", ft = "dismissableLayer.update", Ka = "dismissableLa
970
970
  }
971
971
  );
972
972
  _t.displayName = ja;
973
- var qa = "DismissableLayerBranch", Cn = _.forwardRef((e, t) => {
974
- const n = _.useContext(En), r = _.useRef(null), o = ee(t, r);
973
+ var qa = "DismissableLayerBranch", Tn = _.forwardRef((e, t) => {
974
+ const n = _.useContext(En), r = _.useRef(null), o = te(t, r);
975
975
  return _.useEffect(() => {
976
976
  const s = r.current;
977
977
  if (s)
@@ -980,7 +980,7 @@ var qa = "DismissableLayerBranch", Cn = _.forwardRef((e, t) => {
980
980
  };
981
981
  }, [n.branches]), /* @__PURE__ */ a(V.div, { ...e, ref: o });
982
982
  });
983
- Cn.displayName = qa;
983
+ Tn.displayName = qa;
984
984
  function Ya(e, t = globalThis == null ? void 0 : globalThis.document) {
985
985
  const n = oe(e), r = _.useRef(!1), o = _.useRef(() => {
986
986
  });
@@ -988,7 +988,7 @@ function Ya(e, t = globalThis == null ? void 0 : globalThis.document) {
988
988
  const s = (i) => {
989
989
  if (i.target && !r.current) {
990
990
  let d = function() {
991
- Tn(
991
+ Cn(
992
992
  Ka,
993
993
  n,
994
994
  c,
@@ -1015,7 +1015,7 @@ function Xa(e, t = globalThis == null ? void 0 : globalThis.document) {
1015
1015
  const n = oe(e), r = _.useRef(!1);
1016
1016
  return _.useEffect(() => {
1017
1017
  const o = (s) => {
1018
- s.target && !r.current && Tn(Va, n, { originalEvent: s }, {
1018
+ s.target && !r.current && Cn(Va, n, { originalEvent: s }, {
1019
1019
  discrete: !1
1020
1020
  });
1021
1021
  };
@@ -1029,18 +1029,18 @@ function Gt() {
1029
1029
  const e = new CustomEvent(ft);
1030
1030
  document.dispatchEvent(e);
1031
1031
  }
1032
- function Tn(e, t, n, { discrete: r }) {
1032
+ function Cn(e, t, n, { discrete: r }) {
1033
1033
  const o = n.originalEvent.target, s = new CustomEvent(e, { bubbles: !1, cancelable: !0, detail: n });
1034
1034
  t && o.addEventListener(e, t, { once: !0 }), r ? Sn(o, s) : o.dispatchEvent(s);
1035
1035
  }
1036
- var Za = _t, Qa = Cn, et = "focusScope.autoFocusOnMount", tt = "focusScope.autoFocusOnUnmount", jt = { bubbles: !1, cancelable: !0 }, Ja = "FocusScope", An = _.forwardRef((e, t) => {
1036
+ var Za = _t, Qa = Tn, et = "focusScope.autoFocusOnMount", tt = "focusScope.autoFocusOnUnmount", jt = { bubbles: !1, cancelable: !0 }, Ja = "FocusScope", An = _.forwardRef((e, t) => {
1037
1037
  const {
1038
1038
  loop: n = !1,
1039
1039
  trapped: r = !1,
1040
1040
  onMountAutoFocus: o,
1041
1041
  onUnmountAutoFocus: s,
1042
1042
  ...l
1043
- } = e, [i, d] = _.useState(null), c = oe(o), u = oe(s), p = _.useRef(null), b = ee(t, (g) => d(g)), w = _.useRef({
1043
+ } = e, [i, d] = _.useState(null), c = oe(o), u = oe(s), p = _.useRef(null), b = te(t, (g) => d(g)), w = _.useRef({
1044
1044
  paused: !1,
1045
1045
  pause() {
1046
1046
  this.paused = !0;
@@ -1174,7 +1174,7 @@ function io(e, t) {
1174
1174
  return _.useReducer((n, r) => t[n][r] ?? n, e);
1175
1175
  }
1176
1176
  var ke = (e) => {
1177
- const { present: t, children: n } = e, r = lo(t), o = typeof n == "function" ? n({ present: r.isPresent }) : _.Children.only(n), s = ee(r.ref, co(o));
1177
+ const { present: t, children: n } = e, r = lo(t), o = typeof n == "function" ? n({ present: r.isPresent }) : _.Children.only(n), s = te(r.ref, co(o));
1178
1178
  return typeof n == "function" || r.isPresent ? _.cloneElement(o, { ref: s }) : null;
1179
1179
  };
1180
1180
  ke.displayName = "Presence";
@@ -1443,7 +1443,7 @@ var Eo = function() {
1443
1443
  e--, !e && t && (t.parentNode && t.parentNode.removeChild(t), t = null);
1444
1444
  }
1445
1445
  };
1446
- }, Co = function() {
1446
+ }, To = function() {
1447
1447
  var e = Eo();
1448
1448
  return function(t, n) {
1449
1449
  _.useEffect(function() {
@@ -1453,12 +1453,12 @@ var Eo = function() {
1453
1453
  }, [t && n]);
1454
1454
  };
1455
1455
  }, Ln = function() {
1456
- var e = Co(), t = function(n) {
1456
+ var e = To(), t = function(n) {
1457
1457
  var r = n.styles, o = n.dynamic;
1458
1458
  return e(r, o), null;
1459
1459
  };
1460
1460
  return t;
1461
- }, To = {
1461
+ }, Co = {
1462
1462
  left: 0,
1463
1463
  top: 0,
1464
1464
  right: 0,
@@ -1470,7 +1470,7 @@ var Eo = function() {
1470
1470
  return [ot(n), ot(r), ot(o)];
1471
1471
  }, Po = function(e) {
1472
1472
  if (e === void 0 && (e = "margin"), typeof window > "u")
1473
- return To;
1473
+ return Co;
1474
1474
  var t = Ao(e), n = document.documentElement.clientWidth, r = window.innerWidth;
1475
1475
  return {
1476
1476
  left: t[0],
@@ -1564,7 +1564,7 @@ var me = mt ? { passive: !1 } : !1, Io = function(e) {
1564
1564
  );
1565
1565
  }, Mo = function(e) {
1566
1566
  return In(e, "overflowY");
1567
- }, Oo = function(e) {
1567
+ }, $o = function(e) {
1568
1568
  return In(e, "overflowX");
1569
1569
  }, Qt = function(e, t) {
1570
1570
  var n = t.ownerDocument, r = t;
@@ -1572,14 +1572,14 @@ var me = mt ? { passive: !1 } : !1, Io = function(e) {
1572
1572
  typeof ShadowRoot < "u" && r instanceof ShadowRoot && (r = r.host);
1573
1573
  var o = Mn(e, r);
1574
1574
  if (o) {
1575
- var s = On(e, r), l = s[1], i = s[2];
1575
+ var s = $n(e, r), l = s[1], i = s[2];
1576
1576
  if (l > i)
1577
1577
  return !0;
1578
1578
  }
1579
1579
  r = r.parentNode;
1580
1580
  } while (r && r !== n.body);
1581
1581
  return !1;
1582
- }, $o = function(e) {
1582
+ }, Oo = function(e) {
1583
1583
  var t = e.scrollTop, n = e.scrollHeight, r = e.clientHeight;
1584
1584
  return [
1585
1585
  t,
@@ -1594,9 +1594,9 @@ var me = mt ? { passive: !1 } : !1, Io = function(e) {
1594
1594
  r
1595
1595
  ];
1596
1596
  }, Mn = function(e, t) {
1597
- return e === "v" ? Mo(t) : Oo(t);
1598
- }, On = function(e, t) {
1599
- return e === "v" ? $o(t) : Bo(t);
1597
+ return e === "v" ? Mo(t) : $o(t);
1598
+ }, $n = function(e, t) {
1599
+ return e === "v" ? Oo(t) : Bo(t);
1600
1600
  }, zo = function(e, t) {
1601
1601
  return e === "h" && t === "rtl" ? -1 : 1;
1602
1602
  }, Uo = function(e, t, n, r, o) {
@@ -1604,7 +1604,7 @@ var me = mt ? { passive: !1 } : !1, Io = function(e) {
1604
1604
  do {
1605
1605
  if (!i)
1606
1606
  break;
1607
- var w = On(e, i), S = w[0], g = w[1], h = w[2], y = g - h - s * S;
1607
+ var w = $n(e, i), S = w[0], g = w[1], h = w[2], y = g - h - s * S;
1608
1608
  (S || y) && Mn(e, i) && (p += y, b += S);
1609
1609
  var v = i.parentNode;
1610
1610
  i = v && v.nodeType === Node.DOCUMENT_FRAGMENT_NODE ? v.host : v;
@@ -1651,13 +1651,13 @@ function jo(e) {
1651
1651
  var y = Le(g), v = n.current, f = "deltaX" in g ? g.deltaX : v[0] - y[0], m = "deltaY" in g ? g.deltaY : v[1] - y[1], x, N = g.target, E = Math.abs(f) > Math.abs(m) ? "h" : "v";
1652
1652
  if ("touches" in g && E === "h" && N.type === "range")
1653
1653
  return !1;
1654
- var T = window.getSelection(), A = T && T.anchorNode, P = A ? A === N || A.contains(N) : !1;
1655
- if (P)
1654
+ var C = window.getSelection(), A = C && C.anchorNode, R = A ? A === N || A.contains(N) : !1;
1655
+ if (R)
1656
1656
  return !1;
1657
- var R = Qt(E, N);
1658
- if (!R)
1657
+ var P = Qt(E, N);
1658
+ if (!P)
1659
1659
  return !0;
1660
- if (R ? x = E : (x = E === "v" ? "h" : "v", R = Qt(E, N)), !R)
1660
+ if (P ? x = E : (x = E === "v" ? "h" : "v", P = Qt(E, N)), !P)
1661
1661
  return !1;
1662
1662
  if (!r.current && "changedTouches" in g && (f || m) && (r.current = x), !x)
1663
1663
  return !0;
@@ -1719,10 +1719,10 @@ function Ko(e) {
1719
1719
  return t;
1720
1720
  }
1721
1721
  const Vo = _o(Fn, jo);
1722
- var $n = _.forwardRef(function(e, t) {
1722
+ var On = _.forwardRef(function(e, t) {
1723
1723
  return _.createElement(Ve, ae({}, e, { ref: t, sideCar: Vo }));
1724
1724
  });
1725
- $n.classNames = Ve.classNames;
1725
+ On.classNames = Ve.classNames;
1726
1726
  var qo = function(e) {
1727
1727
  if (typeof document > "u")
1728
1728
  return null;
@@ -1779,7 +1779,7 @@ var qo = function(e) {
1779
1779
  defaultOpen: o,
1780
1780
  onOpenChange: s,
1781
1781
  modal: l = !0
1782
- } = e, i = _.useRef(null), d = _.useRef(null), [c, u] = Te({
1782
+ } = e, i = _.useRef(null), d = _.useRef(null), [c, u] = Ce({
1783
1783
  prop: r,
1784
1784
  defaultProp: o ?? !1,
1785
1785
  onChange: s,
@@ -1805,7 +1805,7 @@ var qo = function(e) {
1805
1805
  Un.displayName = qe;
1806
1806
  var Wn = "DialogTrigger", Hn = _.forwardRef(
1807
1807
  (e, t) => {
1808
- const { __scopeDialog: n, ...r } = e, o = re(Wn, n), s = ee(t, o.triggerRef);
1808
+ const { __scopeDialog: n, ...r } = e, o = re(Wn, n), s = te(t, o.triggerRef);
1809
1809
  return /* @__PURE__ */ a(
1810
1810
  V.button,
1811
1811
  {
@@ -1816,7 +1816,7 @@ var Wn = "DialogTrigger", Hn = _.forwardRef(
1816
1816
  "data-state": St(o.open),
1817
1817
  ...r,
1818
1818
  ref: s,
1819
- onClick: j(e.onClick, o.onOpenToggle)
1819
+ onClick: G(e.onClick, o.onOpenToggle)
1820
1820
  }
1821
1821
  );
1822
1822
  }
@@ -1842,7 +1842,7 @@ var es = /* @__PURE__ */ We("DialogOverlay.RemoveScroll"), ts = _.forwardRef(
1842
1842
  return (
1843
1843
  // Make sure `Content` is scrollable even when it doesn't live inside `RemoveScroll`
1844
1844
  // ie. when `Overlay` and `Content` are siblings
1845
- /* @__PURE__ */ a($n, { as: es, allowPinchZoom: !0, shards: [o.contentRef], children: /* @__PURE__ */ a(
1845
+ /* @__PURE__ */ a(On, { as: es, allowPinchZoom: !0, shards: [o.contentRef], children: /* @__PURE__ */ a(
1846
1846
  V.div,
1847
1847
  {
1848
1848
  "data-state": St(o.open),
@@ -1862,7 +1862,7 @@ var es = /* @__PURE__ */ We("DialogOverlay.RemoveScroll"), ts = _.forwardRef(
1862
1862
  Vn.displayName = ve;
1863
1863
  var ns = _.forwardRef(
1864
1864
  (e, t) => {
1865
- const n = re(ve, e.__scopeDialog), r = _.useRef(null), o = ee(t, n.contentRef, r);
1865
+ const n = re(ve, e.__scopeDialog), r = _.useRef(null), o = te(t, n.contentRef, r);
1866
1866
  return _.useEffect(() => {
1867
1867
  const s = r.current;
1868
1868
  if (s) return Zo(s);
@@ -1873,15 +1873,15 @@ var ns = _.forwardRef(
1873
1873
  ref: o,
1874
1874
  trapFocus: n.open,
1875
1875
  disableOutsidePointerEvents: !0,
1876
- onCloseAutoFocus: j(e.onCloseAutoFocus, (s) => {
1876
+ onCloseAutoFocus: G(e.onCloseAutoFocus, (s) => {
1877
1877
  var l;
1878
1878
  s.preventDefault(), (l = n.triggerRef.current) == null || l.focus();
1879
1879
  }),
1880
- onPointerDownOutside: j(e.onPointerDownOutside, (s) => {
1880
+ onPointerDownOutside: G(e.onPointerDownOutside, (s) => {
1881
1881
  const l = s.detail.originalEvent, i = l.button === 0 && l.ctrlKey === !0;
1882
1882
  (l.button === 2 || i) && s.preventDefault();
1883
1883
  }),
1884
- onFocusOutside: j(
1884
+ onFocusOutside: G(
1885
1885
  e.onFocusOutside,
1886
1886
  (s) => s.preventDefault()
1887
1887
  )
@@ -1913,8 +1913,8 @@ var ns = _.forwardRef(
1913
1913
  }
1914
1914
  ), qn = _.forwardRef(
1915
1915
  (e, t) => {
1916
- const { __scopeDialog: n, trapFocus: r, onOpenAutoFocus: o, onCloseAutoFocus: s, ...l } = e, i = re(ve, n), d = _.useRef(null), c = ee(t, d);
1917
- return uo(), /* @__PURE__ */ k(J, { children: [
1916
+ const { __scopeDialog: n, trapFocus: r, onOpenAutoFocus: o, onCloseAutoFocus: s, ...l } = e, i = re(ve, n), d = _.useRef(null), c = te(t, d);
1917
+ return uo(), /* @__PURE__ */ k(ee, { children: [
1918
1918
  /* @__PURE__ */ a(
1919
1919
  An,
1920
1920
  {
@@ -1938,7 +1938,7 @@ var ns = _.forwardRef(
1938
1938
  )
1939
1939
  }
1940
1940
  ),
1941
- /* @__PURE__ */ k(J, { children: [
1941
+ /* @__PURE__ */ k(ee, { children: [
1942
1942
  /* @__PURE__ */ a(as, { titleId: i.titleId }),
1943
1943
  /* @__PURE__ */ a(ss, { contentRef: d, descriptionId: i.descriptionId })
1944
1944
  ] })
@@ -1967,7 +1967,7 @@ var Qn = "DialogClose", Jn = _.forwardRef(
1967
1967
  type: "button",
1968
1968
  ...r,
1969
1969
  ref: t,
1970
- onClick: j(e.onClick, () => o.onOpenChange(!1))
1970
+ onClick: G(e.onClick, () => o.onOpenChange(!1))
1971
1971
  }
1972
1972
  );
1973
1973
  }
@@ -1996,7 +1996,7 @@ For more information, see https://radix-ui.com/primitives/docs/components/${t.do
1996
1996
  const o = (s = e.current) == null ? void 0 : s.getAttribute("aria-describedby");
1997
1997
  t && o && (document.getElementById(t) || console.warn(r));
1998
1998
  }, [r, e, t]), null;
1999
- }, Et = Un, Ct = Hn, Tt = jn, At = Kn, Pt = Vn, Rt = Yn, Dt = Zn, Ge = Jn;
1999
+ }, Et = Un, Tt = Hn, Ct = jn, At = Kn, Pt = Vn, Rt = Yn, Dt = Zn, Ge = Jn;
2000
2000
  function Qi({
2001
2001
  trigger: e,
2002
2002
  title: t,
@@ -2010,16 +2010,16 @@ function Qi({
2010
2010
  closable: c = !0,
2011
2011
  ...u
2012
2012
  }) {
2013
- const p = z(null);
2013
+ const p = B(null);
2014
2014
  return /* @__PURE__ */ k(Et, { ...u, children: [
2015
- /* @__PURE__ */ a(Ct, { asChild: !0, children: e }),
2016
- /* @__PURE__ */ k(Tt, { children: [
2015
+ /* @__PURE__ */ a(Tt, { asChild: !0, children: e }),
2016
+ /* @__PURE__ */ k(Ct, { children: [
2017
2017
  /* @__PURE__ */ a(At, { className: "vx-dialog__overlay" }),
2018
2018
  /* @__PURE__ */ k(
2019
2019
  Pt,
2020
2020
  {
2021
2021
  ref: p,
2022
- className: C(
2022
+ className: T(
2023
2023
  "vx-dialog__content",
2024
2024
  l !== "md" && `vx-dialog__content--${l}`,
2025
2025
  i && `vx-dialog__content--pad-${i}`,
@@ -2030,10 +2030,14 @@ function Qi({
2030
2030
  const w = p.current;
2031
2031
  if (!w) return;
2032
2032
  const S = !!w.querySelector(
2033
- ".vx-datepicker__popover, .vx-timepicker__popover, .vx-colorpicker__panel"
2033
+ ".vx-select__dropdown, .vx-multiselect__dropdown, .vx-datepicker__popover, .vx-timepicker__popover, .vx-colorpicker__panel"
2034
2034
  ), g = w.dataset.hasOpenPortal === "1";
2035
2035
  (S || g) && b.preventDefault();
2036
2036
  },
2037
+ onPointerDownOutside: (b) => {
2038
+ const w = p.current;
2039
+ (w == null ? void 0 : w.dataset.hasOpenPortal) === "1" && b.preventDefault();
2040
+ },
2037
2041
  children: [
2038
2042
  /* @__PURE__ */ k("div", { className: "vx-dialog__header", children: [
2039
2043
  /* @__PURE__ */ k("div", { children: [
@@ -2064,7 +2068,7 @@ function Ji({
2064
2068
  }) {
2065
2069
  return /* @__PURE__ */ k("label", { className: "vx-field-group", children: [
2066
2070
  t ? /* @__PURE__ */ a("span", { className: "vx-field-group__label", children: t }) : null,
2067
- /* @__PURE__ */ k("span", { className: C(
2071
+ /* @__PURE__ */ k("span", { className: T(
2068
2072
  "vx-input",
2069
2073
  l !== "default" && `vx-input--${l}`,
2070
2074
  i !== "md" && `vx-input--${i}`,
@@ -2119,7 +2123,7 @@ var Ye = "Switch", [cs] = we(Ye), [ds, us] = cs(Ye), nr = _.forwardRef(
2119
2123
  onCheckedChange: c,
2120
2124
  form: u,
2121
2125
  ...p
2122
- } = e, [b, w] = _.useState(null), S = ee(t, (f) => w(f)), g = _.useRef(!1), h = b ? u || !!b.closest("form") : !0, [y, v] = Te({
2126
+ } = e, [b, w] = _.useState(null), S = te(t, (f) => w(f)), g = _.useRef(!1), h = b ? u || !!b.closest("form") : !0, [y, v] = Ce({
2123
2127
  prop: o,
2124
2128
  defaultProp: s ?? !1,
2125
2129
  onChange: c,
@@ -2139,7 +2143,7 @@ var Ye = "Switch", [cs] = we(Ye), [ds, us] = cs(Ye), nr = _.forwardRef(
2139
2143
  value: d,
2140
2144
  ...p,
2141
2145
  ref: S,
2142
- onClick: j(e.onClick, (f) => {
2146
+ onClick: G(e.onClick, (f) => {
2143
2147
  v((m) => !m), h && (g.current = f.isPropagationStopped(), g.current || f.stopPropagation());
2144
2148
  })
2145
2149
  }
@@ -2185,7 +2189,7 @@ var ps = "SwitchBubbleInput", or = _.forwardRef(
2185
2189
  bubbles: r = !0,
2186
2190
  ...o
2187
2191
  }, s) => {
2188
- const l = _.useRef(null), i = ee(l, s), d = is(n), c = ls(t);
2192
+ const l = _.useRef(null), i = te(l, s), d = is(n), c = ls(t);
2189
2193
  return _.useEffect(() => {
2190
2194
  const u = l.current;
2191
2195
  if (!u) return;
@@ -2229,7 +2233,7 @@ function el({ className: e, label: t, description: n, ...r }) {
2229
2233
  /* @__PURE__ */ a("span", { className: "vx-switch__label", children: t }),
2230
2234
  n ? /* @__PURE__ */ a("span", { className: "vx-switch__description", children: n }) : null
2231
2235
  ] }),
2232
- /* @__PURE__ */ a(vs, { className: C("vx-switch__control", e), ...r, children: /* @__PURE__ */ a(fs, { className: "vx-switch__thumb" }) })
2236
+ /* @__PURE__ */ a(vs, { className: T("vx-switch__control", e), ...r, children: /* @__PURE__ */ a(fs, { className: "vx-switch__thumb" }) })
2233
2237
  ] });
2234
2238
  }
2235
2239
  function ir(e) {
@@ -2243,14 +2247,14 @@ function ir(e) {
2243
2247
  l.displayName = t;
2244
2248
  const i = e + "CollectionSlot", d = /* @__PURE__ */ We(i), c = ue.forwardRef(
2245
2249
  (g, h) => {
2246
- const { scope: y, children: v } = g, f = s(i, y), m = ee(h, f.collectionRef);
2250
+ const { scope: y, children: v } = g, f = s(i, y), m = te(h, f.collectionRef);
2247
2251
  return /* @__PURE__ */ a(d, { ref: m, children: v });
2248
2252
  }
2249
2253
  );
2250
2254
  c.displayName = i;
2251
2255
  const u = e + "CollectionItemSlot", p = "data-radix-collection-item", b = /* @__PURE__ */ We(u), w = ue.forwardRef(
2252
2256
  (g, h) => {
2253
- const { scope: y, children: v, ...f } = g, m = ue.useRef(null), x = ee(h, m), N = s(u, y);
2257
+ const { scope: y, children: v, ...f } = g, m = ue.useRef(null), x = te(h, m), N = s(u, y);
2254
2258
  return ue.useEffect(() => (N.itemMap.set(m, { ref: m, ...f }), () => void N.itemMap.delete(m))), /* @__PURE__ */ a(b, { [p]: "", ref: x, children: v });
2255
2259
  }
2256
2260
  );
@@ -2296,16 +2300,16 @@ var _s = _.forwardRef((e, t) => {
2296
2300
  onEntryFocus: c,
2297
2301
  preventScrollOnEntryFocus: u = !1,
2298
2302
  ...p
2299
- } = e, b = _.useRef(null), w = ee(t, b), S = lr(s), [g, h] = Te({
2303
+ } = e, b = _.useRef(null), w = te(t, b), S = lr(s), [g, h] = Ce({
2300
2304
  prop: l,
2301
2305
  defaultProp: i ?? null,
2302
2306
  onChange: d,
2303
2307
  caller: Ae
2304
2308
  }), [y, v] = _.useState(!1), f = oe(c), m = cr(n), x = _.useRef(!1), [N, E] = _.useState(0);
2305
2309
  return _.useEffect(() => {
2306
- const T = b.current;
2307
- if (T)
2308
- return T.addEventListener(it, f), () => T.removeEventListener(it, f);
2310
+ const C = b.current;
2311
+ if (C)
2312
+ return C.addEventListener(it, f), () => C.removeEventListener(it, f);
2309
2313
  }, [f]), /* @__PURE__ */ a(
2310
2314
  xs,
2311
2315
  {
@@ -2315,16 +2319,16 @@ var _s = _.forwardRef((e, t) => {
2315
2319
  loop: o,
2316
2320
  currentTabStopId: g,
2317
2321
  onItemFocus: _.useCallback(
2318
- (T) => h(T),
2322
+ (C) => h(C),
2319
2323
  [h]
2320
2324
  ),
2321
2325
  onItemShiftTab: _.useCallback(() => v(!0), []),
2322
2326
  onFocusableItemAdd: _.useCallback(
2323
- () => E((T) => T + 1),
2327
+ () => E((C) => C + 1),
2324
2328
  []
2325
2329
  ),
2326
2330
  onFocusableItemRemove: _.useCallback(
2327
- () => E((T) => T - 1),
2331
+ () => E((C) => C - 1),
2328
2332
  []
2329
2333
  ),
2330
2334
  children: /* @__PURE__ */ a(
@@ -2335,23 +2339,23 @@ var _s = _.forwardRef((e, t) => {
2335
2339
  ...p,
2336
2340
  ref: w,
2337
2341
  style: { outline: "none", ...e.style },
2338
- onMouseDown: j(e.onMouseDown, () => {
2342
+ onMouseDown: G(e.onMouseDown, () => {
2339
2343
  x.current = !0;
2340
2344
  }),
2341
- onFocus: j(e.onFocus, (T) => {
2345
+ onFocus: G(e.onFocus, (C) => {
2342
2346
  const A = !x.current;
2343
- if (T.target === T.currentTarget && A && !y) {
2344
- const P = new CustomEvent(it, hs);
2345
- if (T.currentTarget.dispatchEvent(P), !P.defaultPrevented) {
2346
- const R = m().filter((G) => G.focusable), L = R.find((G) => G.active), B = R.find((G) => G.id === g), W = [L, B, ...R].filter(
2347
+ if (C.target === C.currentTarget && A && !y) {
2348
+ const R = new CustomEvent(it, hs);
2349
+ if (C.currentTarget.dispatchEvent(R), !R.defaultPrevented) {
2350
+ const P = m().filter((H) => H.focusable), L = P.find((H) => H.active), $ = P.find((H) => H.id === g), U = [L, $, ...P].filter(
2347
2351
  Boolean
2348
- ).map((G) => G.ref.current);
2349
- fr(W, u);
2352
+ ).map((H) => H.ref.current);
2353
+ fr(U, u);
2350
2354
  }
2351
2355
  }
2352
2356
  x.current = !1;
2353
2357
  }),
2354
- onBlur: j(e.onBlur, () => v(!1))
2358
+ onBlur: G(e.onBlur, () => v(!1))
2355
2359
  }
2356
2360
  )
2357
2361
  }
@@ -2383,11 +2387,11 @@ var _s = _.forwardRef((e, t) => {
2383
2387
  "data-orientation": u.orientation,
2384
2388
  ...i,
2385
2389
  ref: t,
2386
- onMouseDown: j(e.onMouseDown, (h) => {
2390
+ onMouseDown: G(e.onMouseDown, (h) => {
2387
2391
  r ? u.onItemFocus(c) : h.preventDefault();
2388
2392
  }),
2389
- onFocus: j(e.onFocus, () => u.onItemFocus(c)),
2390
- onKeyDown: j(e.onKeyDown, (h) => {
2393
+ onFocus: G(e.onFocus, () => u.onItemFocus(c)),
2394
+ onKeyDown: G(e.onKeyDown, (h) => {
2391
2395
  if (h.key === "Tab" && h.shiftKey) {
2392
2396
  u.onItemShiftTab();
2393
2397
  return;
@@ -2441,9 +2445,9 @@ function fr(e, t = !1) {
2441
2445
  function Ss(e, t) {
2442
2446
  return e.map((n, r) => e[(t + r) % e.length]);
2443
2447
  }
2444
- var Es = ur, Cs = vr, Xe = "Tabs", [Ts] = we(Xe, [
2448
+ var Es = ur, Ts = vr, Xe = "Tabs", [Cs] = we(Xe, [
2445
2449
  dr
2446
- ]), mr = dr(), [As, Ft] = Ts(Xe), hr = _.forwardRef(
2450
+ ]), mr = dr(), [As, Ft] = Cs(Xe), hr = _.forwardRef(
2447
2451
  (e, t) => {
2448
2452
  const {
2449
2453
  __scopeTabs: n,
@@ -2454,7 +2458,7 @@ var Es = ur, Cs = vr, Xe = "Tabs", [Ts] = we(Xe, [
2454
2458
  dir: i,
2455
2459
  activationMode: d = "automatic",
2456
2460
  ...c
2457
- } = e, u = lr(i), [p, b] = Te({
2461
+ } = e, u = lr(i), [p, b] = Ce({
2458
2462
  prop: r,
2459
2463
  onChange: o,
2460
2464
  defaultProp: s ?? "",
@@ -2513,7 +2517,7 @@ var xr = "TabsTrigger", yr = _.forwardRef(
2513
2517
  (e, t) => {
2514
2518
  const { __scopeTabs: n, value: r, disabled: o = !1, ...s } = e, l = Ft(xr, n), i = mr(n), d = kr(l.baseId, r), c = Nr(l.baseId, r), u = r === l.value;
2515
2519
  return /* @__PURE__ */ a(
2516
- Cs,
2520
+ Ts,
2517
2521
  {
2518
2522
  asChild: !0,
2519
2523
  ...i,
@@ -2532,13 +2536,13 @@ var xr = "TabsTrigger", yr = _.forwardRef(
2532
2536
  id: d,
2533
2537
  ...s,
2534
2538
  ref: t,
2535
- onMouseDown: j(e.onMouseDown, (p) => {
2539
+ onMouseDown: G(e.onMouseDown, (p) => {
2536
2540
  !o && p.button === 0 && p.ctrlKey === !1 ? l.onValueChange(r) : p.preventDefault();
2537
2541
  }),
2538
- onKeyDown: j(e.onKeyDown, (p) => {
2542
+ onKeyDown: G(e.onKeyDown, (p) => {
2539
2543
  [" ", "Enter"].includes(p.key) && l.onValueChange(r);
2540
2544
  }),
2541
- onFocus: j(e.onFocus, () => {
2545
+ onFocus: G(e.onFocus, () => {
2542
2546
  const p = l.activationMode !== "manual";
2543
2547
  !u && !o && p && l.onValueChange(r);
2544
2548
  })
@@ -2585,11 +2589,11 @@ function Nr(e, t) {
2585
2589
  }
2586
2590
  var Ps = hr, Rs = br, Ds = yr, Fs = wr;
2587
2591
  const tl = Ps, nl = ce(function({ className: t, ...n }, r) {
2588
- return /* @__PURE__ */ a(Rs, { ref: r, className: C("vx-tabs__list", t), ...n });
2592
+ return /* @__PURE__ */ a(Rs, { ref: r, className: T("vx-tabs__list", t), ...n });
2589
2593
  }), rl = ce(function({ className: t, ...n }, r) {
2590
- return /* @__PURE__ */ a(Ds, { ref: r, className: C("vx-tabs__trigger", t), ...n });
2594
+ return /* @__PURE__ */ a(Ds, { ref: r, className: T("vx-tabs__trigger", t), ...n });
2591
2595
  }), al = ce(function({ className: t, ...n }, r) {
2592
- return /* @__PURE__ */ a(Fs, { ref: r, className: C("vx-tabs__content", t), ...n });
2596
+ return /* @__PURE__ */ a(Fs, { ref: r, className: T("vx-tabs__content", t), ...n });
2593
2597
  }), Sr = {
2594
2598
  light: {
2595
2599
  label: "Light",
@@ -2934,7 +2938,7 @@ function Ms(e, t) {
2934
2938
  const n = window.localStorage.getItem(e);
2935
2939
  return n && t[n] ? n : null;
2936
2940
  }
2937
- function Os(e, t, n) {
2941
+ function $s(e, t, n) {
2938
2942
  var o;
2939
2943
  if (((o = e[n]) == null ? void 0 : o.mode) === t)
2940
2944
  return n;
@@ -2948,10 +2952,10 @@ function sl({
2948
2952
  storageKey: n = "vxui-react-theme",
2949
2953
  themes: r
2950
2954
  }) {
2951
- const o = Ne(() => Ls(r), [r]), s = Ne(() => Is(t, o), [t, o]), l = z([]), [i, d] = I(() => typeof window > "u" ? s : Ms(n, o) ?? s), c = o[i] ? i : s, u = o[c];
2952
- $(() => {
2955
+ const o = Ne(() => Ls(r), [r]), s = Ne(() => Is(t, o), [t, o]), l = B([]), [i, d] = I(() => typeof window > "u" ? s : Ms(n, o) ?? s), c = o[i] ? i : s, u = o[c];
2956
+ z(() => {
2953
2957
  i !== c && d(c);
2954
- }, [c, i]), $(() => {
2958
+ }, [c, i]), z(() => {
2955
2959
  const b = document.documentElement;
2956
2960
  for (const S of l.current)
2957
2961
  b.style.removeProperty(S);
@@ -2974,7 +2978,7 @@ function sl({
2974
2978
  toggleTheme: () => {
2975
2979
  d((b) => {
2976
2980
  const S = (o[b] ?? u).mode === "light" ? "dark" : "light";
2977
- return Os(o, S, S) ?? b;
2981
+ return $s(o, S, S) ?? b;
2978
2982
  });
2979
2983
  }
2980
2984
  }),
@@ -2988,7 +2992,7 @@ function il() {
2988
2992
  throw new Error("useTheme must be used within ThemeProvider.");
2989
2993
  return e;
2990
2994
  }
2991
- var $s = Object.freeze({
2995
+ var Os = Object.freeze({
2992
2996
  // See: https://github.com/twbs/bootstrap/blob/main/scss/mixins/_visually-hidden.scss
2993
2997
  position: "absolute",
2994
2998
  border: 0,
@@ -3006,12 +3010,12 @@ var $s = Object.freeze({
3006
3010
  {
3007
3011
  ...e,
3008
3012
  ref: t,
3009
- style: { ...$s, ...e.style }
3013
+ style: { ...Os, ...e.style }
3010
3014
  }
3011
3015
  )
3012
3016
  );
3013
3017
  Lt.displayName = Bs;
3014
- var It = "ToastProvider", [Mt, zs, Us] = ir("Toast"), [Cr] = we("Toast", [Us]), [Ws, Ze] = Cr(It), Tr = (e) => {
3018
+ var It = "ToastProvider", [Mt, zs, Us] = ir("Toast"), [Tr] = we("Toast", [Us]), [Ws, Ze] = Tr(It), Cr = (e) => {
3015
3019
  const {
3016
3020
  __scopeToast: t,
3017
3021
  label: n = "Notification",
@@ -3041,7 +3045,7 @@ var It = "ToastProvider", [Mt, zs, Us] = ir("Toast"), [Cr] = we("Toast", [Us]),
3041
3045
  }
3042
3046
  ) });
3043
3047
  };
3044
- Tr.displayName = It;
3048
+ Cr.displayName = It;
3045
3049
  var Ar = "ToastViewport", Hs = ["F8"], gt = "toast.viewportPause", bt = "toast.viewportResume", Pr = _.forwardRef(
3046
3050
  (e, t) => {
3047
3051
  const {
@@ -3049,7 +3053,7 @@ var Ar = "ToastViewport", Hs = ["F8"], gt = "toast.viewportPause", bt = "toast.v
3049
3053
  hotkey: r = Hs,
3050
3054
  label: o = "Notifications ({hotkey})",
3051
3055
  ...s
3052
- } = e, l = Ze(Ar, n), i = zs(n), d = _.useRef(null), c = _.useRef(null), u = _.useRef(null), p = _.useRef(null), b = ee(t, p, l.onViewportChange), w = r.join("+").replace(/Key/g, "").replace(/Digit/g, ""), S = l.toastCount > 0;
3056
+ } = e, l = Ze(Ar, n), i = zs(n), d = _.useRef(null), c = _.useRef(null), u = _.useRef(null), p = _.useRef(null), b = te(t, p, l.onViewportChange), w = r.join("+").replace(/Key/g, "").replace(/Digit/g, ""), S = l.toastCount > 0;
3053
3057
  _.useEffect(() => {
3054
3058
  const h = (y) => {
3055
3059
  var f;
@@ -3096,13 +3100,13 @@ var Ar = "ToastViewport", Hs = ["F8"], gt = "toast.viewportPause", bt = "toast.v
3096
3100
  var x, N, E;
3097
3101
  const f = v.altKey || v.ctrlKey || v.metaKey;
3098
3102
  if (v.key === "Tab" && !f) {
3099
- const T = document.activeElement, A = v.shiftKey;
3103
+ const C = document.activeElement, A = v.shiftKey;
3100
3104
  if (v.target === h && A) {
3101
3105
  (x = c.current) == null || x.focus();
3102
3106
  return;
3103
3107
  }
3104
- const L = g({ tabbingDirection: A ? "backwards" : "forwards" }), B = L.findIndex((D) => D === T);
3105
- lt(L.slice(B + 1)) ? v.preventDefault() : A ? (N = c.current) == null || N.focus() : (E = u.current) == null || E.focus();
3108
+ const L = g({ tabbingDirection: A ? "backwards" : "forwards" }), $ = L.findIndex((D) => D === C);
3109
+ lt(L.slice($ + 1)) ? v.preventDefault() : A ? (N = c.current) == null || N.focus() : (E = u.current) == null || E.focus();
3106
3110
  }
3107
3111
  };
3108
3112
  return h.addEventListener("keydown", y), () => h.removeEventListener("keydown", y);
@@ -3169,7 +3173,7 @@ var Rr = "ToastFocusProxy", xt = _.forwardRef(
3169
3173
  xt.displayName = Rr;
3170
3174
  var Pe = "Toast", Gs = "toast.swipeStart", js = "toast.swipeMove", Ks = "toast.swipeCancel", Vs = "toast.swipeEnd", Dr = _.forwardRef(
3171
3175
  (e, t) => {
3172
- const { forceMount: n, open: r, defaultOpen: o, onOpenChange: s, ...l } = e, [i, d] = Te({
3176
+ const { forceMount: n, open: r, defaultOpen: o, onOpenChange: s, ...l } = e, [i, d] = Ce({
3173
3177
  prop: r,
3174
3178
  defaultProp: o ?? !0,
3175
3179
  onChange: s,
@@ -3184,17 +3188,17 @@ var Pe = "Toast", Gs = "toast.swipeStart", js = "toast.swipeMove", Ks = "toast.s
3184
3188
  onClose: () => d(!1),
3185
3189
  onPause: oe(e.onPause),
3186
3190
  onResume: oe(e.onResume),
3187
- onSwipeStart: j(e.onSwipeStart, (c) => {
3191
+ onSwipeStart: G(e.onSwipeStart, (c) => {
3188
3192
  c.currentTarget.setAttribute("data-swipe", "start");
3189
3193
  }),
3190
- onSwipeMove: j(e.onSwipeMove, (c) => {
3194
+ onSwipeMove: G(e.onSwipeMove, (c) => {
3191
3195
  const { x: u, y: p } = c.detail.delta;
3192
3196
  c.currentTarget.setAttribute("data-swipe", "move"), c.currentTarget.style.setProperty("--radix-toast-swipe-move-x", `${u}px`), c.currentTarget.style.setProperty("--radix-toast-swipe-move-y", `${p}px`);
3193
3197
  }),
3194
- onSwipeCancel: j(e.onSwipeCancel, (c) => {
3198
+ onSwipeCancel: G(e.onSwipeCancel, (c) => {
3195
3199
  c.currentTarget.setAttribute("data-swipe", "cancel"), c.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"), c.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"), c.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"), c.currentTarget.style.removeProperty("--radix-toast-swipe-end-y");
3196
3200
  }),
3197
- onSwipeEnd: j(e.onSwipeEnd, (c) => {
3201
+ onSwipeEnd: G(e.onSwipeEnd, (c) => {
3198
3202
  const { x: u, y: p } = c.detail.delta;
3199
3203
  c.currentTarget.setAttribute("data-swipe", "end"), c.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"), c.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"), c.currentTarget.style.setProperty("--radix-toast-swipe-end-x", `${u}px`), c.currentTarget.style.setProperty("--radix-toast-swipe-end-y", `${p}px`), d(!1);
3200
3204
  })
@@ -3203,7 +3207,7 @@ var Pe = "Toast", Gs = "toast.swipeStart", js = "toast.swipeMove", Ks = "toast.s
3203
3207
  }
3204
3208
  );
3205
3209
  Dr.displayName = Pe;
3206
- var [qs, Ys] = Cr(Pe, {
3210
+ var [qs, Ys] = Tr(Pe, {
3207
3211
  onClose() {
3208
3212
  }
3209
3213
  }), Xs = _.forwardRef(
@@ -3222,49 +3226,49 @@ var [qs, Ys] = Cr(Pe, {
3222
3226
  onSwipeCancel: b,
3223
3227
  onSwipeEnd: w,
3224
3228
  ...S
3225
- } = e, g = Ze(Pe, n), [h, y] = _.useState(null), v = ee(t, (D) => y(D)), f = _.useRef(null), m = _.useRef(null), x = o || g.duration, N = _.useRef(0), E = _.useRef(x), T = _.useRef(0), { onToastAdd: A, onToastRemove: P } = g, R = oe(() => {
3226
- var W;
3227
- (h == null ? void 0 : h.contains(document.activeElement)) && ((W = g.viewport) == null || W.focus()), l();
3229
+ } = e, g = Ze(Pe, n), [h, y] = _.useState(null), v = te(t, (D) => y(D)), f = _.useRef(null), m = _.useRef(null), x = o || g.duration, N = _.useRef(0), E = _.useRef(x), C = _.useRef(0), { onToastAdd: A, onToastRemove: R } = g, P = oe(() => {
3230
+ var U;
3231
+ (h == null ? void 0 : h.contains(document.activeElement)) && ((U = g.viewport) == null || U.focus()), l();
3228
3232
  }), L = _.useCallback(
3229
3233
  (D) => {
3230
- !D || D === 1 / 0 || (window.clearTimeout(T.current), N.current = (/* @__PURE__ */ new Date()).getTime(), T.current = window.setTimeout(R, D));
3234
+ !D || D === 1 / 0 || (window.clearTimeout(C.current), N.current = (/* @__PURE__ */ new Date()).getTime(), C.current = window.setTimeout(P, D));
3231
3235
  },
3232
- [R]
3236
+ [P]
3233
3237
  );
3234
3238
  _.useEffect(() => {
3235
3239
  const D = g.viewport;
3236
3240
  if (D) {
3237
- const W = () => {
3241
+ const U = () => {
3238
3242
  L(E.current), c == null || c();
3239
- }, G = () => {
3240
- const X = (/* @__PURE__ */ new Date()).getTime() - N.current;
3241
- E.current = E.current - X, window.clearTimeout(T.current), d == null || d();
3243
+ }, H = () => {
3244
+ const Z = (/* @__PURE__ */ new Date()).getTime() - N.current;
3245
+ E.current = E.current - Z, window.clearTimeout(C.current), d == null || d();
3242
3246
  };
3243
- return D.addEventListener(gt, G), D.addEventListener(bt, W), () => {
3244
- D.removeEventListener(gt, G), D.removeEventListener(bt, W);
3247
+ return D.addEventListener(gt, H), D.addEventListener(bt, U), () => {
3248
+ D.removeEventListener(gt, H), D.removeEventListener(bt, U);
3245
3249
  };
3246
3250
  }
3247
3251
  }, [g.viewport, x, d, c, L]), _.useEffect(() => {
3248
3252
  s && !g.isClosePausedRef.current && L(x);
3249
- }, [s, x, g.isClosePausedRef, L]), _.useEffect(() => (A(), () => P()), [A, P]);
3250
- const B = _.useMemo(() => h ? $r(h) : null, [h]);
3251
- return g.viewport ? /* @__PURE__ */ k(J, { children: [
3252
- B && /* @__PURE__ */ a(
3253
+ }, [s, x, g.isClosePausedRef, L]), _.useEffect(() => (A(), () => R()), [A, R]);
3254
+ const $ = _.useMemo(() => h ? Or(h) : null, [h]);
3255
+ return g.viewport ? /* @__PURE__ */ k(ee, { children: [
3256
+ $ && /* @__PURE__ */ a(
3253
3257
  Zs,
3254
3258
  {
3255
3259
  __scopeToast: n,
3256
3260
  role: "status",
3257
3261
  "aria-live": r === "foreground" ? "assertive" : "polite",
3258
- children: B
3262
+ children: $
3259
3263
  }
3260
3264
  ),
3261
- /* @__PURE__ */ a(qs, { scope: n, onClose: R, children: hn.createPortal(
3265
+ /* @__PURE__ */ a(qs, { scope: n, onClose: P, children: hn.createPortal(
3262
3266
  /* @__PURE__ */ a(Mt.ItemSlot, { scope: n, children: /* @__PURE__ */ a(
3263
3267
  Za,
3264
3268
  {
3265
3269
  asChild: !0,
3266
- onEscapeKeyDown: j(i, () => {
3267
- g.isFocusedToastEscapeKeyDownRef.current || R(), g.isFocusedToastEscapeKeyDownRef.current = !1;
3270
+ onEscapeKeyDown: G(i, () => {
3271
+ g.isFocusedToastEscapeKeyDownRef.current || P(), g.isFocusedToastEscapeKeyDownRef.current = !1;
3268
3272
  }),
3269
3273
  children: /* @__PURE__ */ a(
3270
3274
  V.li,
@@ -3275,35 +3279,35 @@ var [qs, Ys] = Cr(Pe, {
3275
3279
  ...S,
3276
3280
  ref: v,
3277
3281
  style: { userSelect: "none", touchAction: "none", ...e.style },
3278
- onKeyDown: j(e.onKeyDown, (D) => {
3279
- D.key === "Escape" && (i == null || i(D.nativeEvent), D.nativeEvent.defaultPrevented || (g.isFocusedToastEscapeKeyDownRef.current = !0, R()));
3282
+ onKeyDown: G(e.onKeyDown, (D) => {
3283
+ D.key === "Escape" && (i == null || i(D.nativeEvent), D.nativeEvent.defaultPrevented || (g.isFocusedToastEscapeKeyDownRef.current = !0, P()));
3280
3284
  }),
3281
- onPointerDown: j(e.onPointerDown, (D) => {
3285
+ onPointerDown: G(e.onPointerDown, (D) => {
3282
3286
  D.button === 0 && (f.current = { x: D.clientX, y: D.clientY });
3283
3287
  }),
3284
- onPointerMove: j(e.onPointerMove, (D) => {
3288
+ onPointerMove: G(e.onPointerMove, (D) => {
3285
3289
  if (!f.current) return;
3286
- const W = D.clientX - f.current.x, G = D.clientY - f.current.y, X = !!m.current, K = ["left", "right"].includes(g.swipeDirection), Y = ["left", "up"].includes(g.swipeDirection) ? Math.min : Math.max, M = K ? Y(0, W) : 0, H = K ? 0 : Y(0, G), F = D.pointerType === "touch" ? 10 : 2, O = { x: M, y: H }, U = { originalEvent: D, delta: O };
3287
- X ? (m.current = O, Oe(js, p, U, {
3290
+ const U = D.clientX - f.current.x, H = D.clientY - f.current.y, Z = !!m.current, j = ["left", "right"].includes(g.swipeDirection), X = ["left", "up"].includes(g.swipeDirection) ? Math.min : Math.max, M = j ? X(0, U) : 0, q = j ? 0 : X(0, H), F = D.pointerType === "touch" ? 10 : 2, O = { x: M, y: q }, W = { originalEvent: D, delta: O };
3291
+ Z ? (m.current = O, $e(js, p, W, {
3288
3292
  discrete: !1
3289
- })) : tn(O, g.swipeDirection, F) ? (m.current = O, Oe(Gs, u, U, {
3293
+ })) : tn(O, g.swipeDirection, F) ? (m.current = O, $e(Gs, u, W, {
3290
3294
  discrete: !1
3291
- }), D.target.setPointerCapture(D.pointerId)) : (Math.abs(W) > F || Math.abs(G) > F) && (f.current = null);
3295
+ }), D.target.setPointerCapture(D.pointerId)) : (Math.abs(U) > F || Math.abs(H) > F) && (f.current = null);
3292
3296
  }),
3293
- onPointerUp: j(e.onPointerUp, (D) => {
3294
- const W = m.current, G = D.target;
3295
- if (G.hasPointerCapture(D.pointerId) && G.releasePointerCapture(D.pointerId), m.current = null, f.current = null, W) {
3296
- const X = D.currentTarget, K = { originalEvent: D, delta: W };
3297
- tn(W, g.swipeDirection, g.swipeThreshold) ? Oe(Vs, w, K, {
3297
+ onPointerUp: G(e.onPointerUp, (D) => {
3298
+ const U = m.current, H = D.target;
3299
+ if (H.hasPointerCapture(D.pointerId) && H.releasePointerCapture(D.pointerId), m.current = null, f.current = null, U) {
3300
+ const Z = D.currentTarget, j = { originalEvent: D, delta: U };
3301
+ tn(U, g.swipeDirection, g.swipeThreshold) ? $e(Vs, w, j, {
3298
3302
  discrete: !0
3299
- }) : Oe(
3303
+ }) : $e(
3300
3304
  Ks,
3301
3305
  b,
3302
- K,
3306
+ j,
3303
3307
  {
3304
3308
  discrete: !0
3305
3309
  }
3306
- ), X.addEventListener("click", (Y) => Y.preventDefault(), {
3310
+ ), Z.addEventListener("click", (X) => X.preventDefault(), {
3307
3311
  once: !0
3308
3312
  });
3309
3313
  }
@@ -3321,7 +3325,7 @@ var [qs, Ys] = Cr(Pe, {
3321
3325
  return ti(() => l(!0)), _.useEffect(() => {
3322
3326
  const c = window.setTimeout(() => d(!0), 1e3);
3323
3327
  return () => window.clearTimeout(c);
3324
- }, []), i ? null : /* @__PURE__ */ a(wt, { asChild: !0, children: /* @__PURE__ */ a(Lt, { ...r, children: s && /* @__PURE__ */ k(J, { children: [
3328
+ }, []), i ? null : /* @__PURE__ */ a(wt, { asChild: !0, children: /* @__PURE__ */ a(Lt, { ...r, children: s && /* @__PURE__ */ k(ee, { children: [
3325
3329
  o.label,
3326
3330
  " ",
3327
3331
  n
@@ -3343,28 +3347,28 @@ Lr.displayName = Js;
3343
3347
  var Ir = "ToastAction", ei = _.forwardRef(
3344
3348
  (e, t) => {
3345
3349
  const { altText: n, ...r } = e;
3346
- return n.trim() ? /* @__PURE__ */ a(Or, { altText: n, asChild: !0, children: /* @__PURE__ */ a(Ot, { ...r, ref: t }) }) : (console.error(
3350
+ return n.trim() ? /* @__PURE__ */ a($r, { altText: n, asChild: !0, children: /* @__PURE__ */ a($t, { ...r, ref: t }) }) : (console.error(
3347
3351
  `Invalid prop \`altText\` supplied to \`${Ir}\`. Expected non-empty \`string\`.`
3348
3352
  ), null);
3349
3353
  }
3350
3354
  );
3351
3355
  ei.displayName = Ir;
3352
- var Mr = "ToastClose", Ot = _.forwardRef(
3356
+ var Mr = "ToastClose", $t = _.forwardRef(
3353
3357
  (e, t) => {
3354
3358
  const { __scopeToast: n, ...r } = e, o = Ys(Mr, n);
3355
- return /* @__PURE__ */ a(Or, { asChild: !0, children: /* @__PURE__ */ a(
3359
+ return /* @__PURE__ */ a($r, { asChild: !0, children: /* @__PURE__ */ a(
3356
3360
  V.button,
3357
3361
  {
3358
3362
  type: "button",
3359
3363
  ...r,
3360
3364
  ref: t,
3361
- onClick: j(e.onClick, o.onClose)
3365
+ onClick: G(e.onClick, o.onClose)
3362
3366
  }
3363
3367
  ) });
3364
3368
  }
3365
3369
  );
3366
- Ot.displayName = Mr;
3367
- var Or = _.forwardRef((e, t) => {
3370
+ $t.displayName = Mr;
3371
+ var $r = _.forwardRef((e, t) => {
3368
3372
  const { __scopeToast: n, altText: r, ...o } = e;
3369
3373
  return /* @__PURE__ */ a(
3370
3374
  V.div,
@@ -3376,7 +3380,7 @@ var Or = _.forwardRef((e, t) => {
3376
3380
  }
3377
3381
  );
3378
3382
  });
3379
- function $r(e) {
3383
+ function Or(e) {
3380
3384
  const t = [];
3381
3385
  return Array.from(e.childNodes).forEach((r) => {
3382
3386
  if (r.nodeType === r.TEXT_NODE && r.textContent && t.push(r.textContent), ni(r)) {
@@ -3386,11 +3390,11 @@ function $r(e) {
3386
3390
  const l = r.dataset.radixToastAnnounceAlt;
3387
3391
  l && t.push(l);
3388
3392
  } else
3389
- t.push(...$r(r));
3393
+ t.push(...Or(r));
3390
3394
  }
3391
3395
  }), t;
3392
3396
  }
3393
- function Oe(e, t, n, { discrete: r }) {
3397
+ function $e(e, t, n, { discrete: r }) {
3394
3398
  const o = n.originalEvent.currentTarget, s = new CustomEvent(e, { bubbles: !0, cancelable: !0, detail: n });
3395
3399
  t && o.addEventListener(e, t, { once: !0 }), r ? Sn(o, s) : o.dispatchEvent(s);
3396
3400
  }
@@ -3425,7 +3429,7 @@ function lt(e) {
3425
3429
  const t = document.activeElement;
3426
3430
  return e.some((n) => n === t ? !0 : (n.focus(), document.activeElement !== t));
3427
3431
  }
3428
- var ai = Tr, oi = Pr, si = Dr, ii = Fr, li = Lr, ci = Ot;
3432
+ var ai = Cr, oi = Pr, si = Dr, ii = Fr, li = Lr, ci = $t;
3429
3433
  const Br = _e(null);
3430
3434
  let di = 1;
3431
3435
  const ui = {
@@ -3448,7 +3452,7 @@ function ll({ children: e }) {
3448
3452
  t.map((o) => /* @__PURE__ */ k(
3449
3453
  si,
3450
3454
  {
3451
- className: C("vx-toast", `vx-toast--${o.tone ?? "info"}`),
3455
+ className: T("vx-toast", `vx-toast--${o.tone ?? "info"}`),
3452
3456
  duration: 4500,
3453
3457
  open: !0,
3454
3458
  onOpenChange: (s) => {
@@ -3488,7 +3492,7 @@ function dl({
3488
3492
  return /* @__PURE__ */ a(
3489
3493
  e,
3490
3494
  {
3491
- className: C(
3495
+ className: T(
3492
3496
  "vx-text-component",
3493
3497
  `vx-text--${t}`,
3494
3498
  `vx-text-size--${n}`,
@@ -3513,7 +3517,7 @@ function ul({
3513
3517
  return /* @__PURE__ */ a(
3514
3518
  i,
3515
3519
  {
3516
- className: C(
3520
+ className: T(
3517
3521
  "vx-heading",
3518
3522
  `vx-heading--h${t}`,
3519
3523
  `vx-heading--${n}`,
@@ -3525,27 +3529,186 @@ function ul({
3525
3529
  }
3526
3530
  );
3527
3531
  }
3528
- function pl({ className: e, label: t, hint: n, placeholder: r, children: o, ...s }) {
3529
- return /* @__PURE__ */ k("label", { className: "vx-field-group", children: [
3530
- t ? /* @__PURE__ */ a("span", { className: "vx-field-group__label", children: t }) : null,
3531
- /* @__PURE__ */ k("span", { className: C("vx-select", e), children: [
3532
- /* @__PURE__ */ k("select", { className: "vx-select__field", ...s, children: [
3533
- r ? /* @__PURE__ */ a("option", { value: "", disabled: !0, children: r }) : null,
3534
- o
3535
- ] }),
3536
- /* @__PURE__ */ a("span", { className: "vx-select__arrow", "aria-hidden": "true", children: /* @__PURE__ */ a("svg", { width: "12", height: "12", viewBox: "0 0 12 12", fill: "none", children: /* @__PURE__ */ a("path", { d: "M2.5 4.5L6 8L9.5 4.5", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) }) })
3537
- ] }),
3538
- n ? /* @__PURE__ */ a("span", { className: "vx-field-group__hint", children: n }) : null
3532
+ function pl({
3533
+ options: e,
3534
+ value: t,
3535
+ defaultValue: n,
3536
+ onChange: r,
3537
+ placeholder: o = "Select...",
3538
+ searchPlaceholder: s = "Search...",
3539
+ label: l,
3540
+ hint: i,
3541
+ error: d,
3542
+ disabled: c,
3543
+ clearable: u = !1,
3544
+ emptyText: p = "No results",
3545
+ searchable: b = !0,
3546
+ className: w
3547
+ }) {
3548
+ const S = t !== void 0, [g, h] = I(n), y = S ? t : g, [v, f] = I(!1), [m, x] = I(""), N = B(null), E = B(null), C = B(null), A = B(null), R = fn(), [P, L] = I(null), [$, D] = I(!1), U = e.find((M) => M.value === y), H = e.filter(
3549
+ (M) => M.label.toLowerCase().includes(m.toLowerCase())
3550
+ ), Z = typeof b == "number" ? e.length > b : b;
3551
+ z(() => {
3552
+ if (!v) {
3553
+ x("");
3554
+ return;
3555
+ }
3556
+ if (Z) {
3557
+ const M = setTimeout(() => {
3558
+ var q;
3559
+ return (q = A.current) == null ? void 0 : q.focus();
3560
+ }, 0);
3561
+ return () => clearTimeout(M);
3562
+ }
3563
+ }, [v, Z]), z(() => {
3564
+ if (!v) return;
3565
+ const M = (F) => {
3566
+ var K, Q;
3567
+ const O = (K = N.current) == null ? void 0 : K.contains(F.target), W = (Q = C.current) == null ? void 0 : Q.contains(F.target);
3568
+ !O && !W && f(!1);
3569
+ }, q = (F) => {
3570
+ F.key === "Escape" && (F.preventDefault(), f(!1));
3571
+ };
3572
+ return document.addEventListener("mousedown", M), document.addEventListener("touchstart", M, { passive: !0 }), document.addEventListener("keydown", q), () => {
3573
+ document.removeEventListener("mousedown", M), document.removeEventListener("touchstart", M), document.removeEventListener("keydown", q);
3574
+ };
3575
+ }, [v]), z(() => {
3576
+ if (!(!v || !window.matchMedia("(max-width: 640px)").matches))
3577
+ return document.body.style.overflow = "hidden", () => {
3578
+ document.body.style.overflow = "";
3579
+ };
3580
+ }, [v]), mn(() => {
3581
+ var W;
3582
+ if (!v || !E.current || window.matchMedia("(max-width: 640px)").matches) {
3583
+ L(null), D(!1);
3584
+ return;
3585
+ }
3586
+ const M = E.current.getBoundingClientRect(), q = window.innerHeight - M.bottom, F = M.top, O = q < 280 && F > q ? "up" : "down";
3587
+ D(!!((W = N.current) != null && W.closest(".vx-dialog__content"))), L(
3588
+ O === "down" ? { top: M.bottom + 4, left: M.left, width: M.width, direction: O } : { bottom: window.innerHeight - M.top + 4, left: M.left, width: M.width, direction: O }
3589
+ );
3590
+ }, [v]), z(() => {
3591
+ if (!v || !P || $) return;
3592
+ const M = (q) => {
3593
+ var F;
3594
+ (F = C.current) != null && F.contains(q.target) || f(!1);
3595
+ };
3596
+ return window.addEventListener("scroll", M, { capture: !0, passive: !0 }), window.addEventListener("resize", M), () => {
3597
+ window.removeEventListener("scroll", M, { capture: !0 }), window.removeEventListener("resize", M);
3598
+ };
3599
+ }, [v, P, $]);
3600
+ const j = (M) => {
3601
+ M.disabled || (S || h(M.value), r == null || r(M.value), f(!1));
3602
+ }, X = (M) => {
3603
+ M.stopPropagation(), S || h(void 0), r == null || r(void 0);
3604
+ };
3605
+ return /* @__PURE__ */ k("div", { ref: N, className: T("vx-select", v && "vx-select--open", w), children: [
3606
+ l ? /* @__PURE__ */ a("span", { className: "vx-field-group__label", children: l }) : null,
3607
+ /* @__PURE__ */ k(
3608
+ "button",
3609
+ {
3610
+ ref: E,
3611
+ type: "button",
3612
+ className: T(
3613
+ "vx-select__trigger",
3614
+ d && "vx-select__trigger--invalid",
3615
+ c && "vx-select__trigger--disabled"
3616
+ ),
3617
+ onClick: () => !c && f((M) => !M),
3618
+ disabled: c,
3619
+ "aria-haspopup": "listbox",
3620
+ "aria-expanded": v,
3621
+ "aria-controls": R,
3622
+ children: [
3623
+ /* @__PURE__ */ a("span", { className: T("vx-select__value", !U && "vx-select__value--placeholder"), children: (U == null ? void 0 : U.label) ?? o }),
3624
+ /* @__PURE__ */ k("span", { className: "vx-select__icons", children: [
3625
+ u && U && /* @__PURE__ */ a(
3626
+ "span",
3627
+ {
3628
+ className: "vx-select__clear",
3629
+ onClick: X,
3630
+ role: "button",
3631
+ "aria-label": "Clear selection",
3632
+ children: /* @__PURE__ */ a(le, { size: 14 })
3633
+ }
3634
+ ),
3635
+ /* @__PURE__ */ a(
3636
+ Ee,
3637
+ {
3638
+ size: 14,
3639
+ className: T("vx-select__chevron", v && "vx-select__chevron--open")
3640
+ }
3641
+ )
3642
+ ] })
3643
+ ]
3644
+ }
3645
+ ),
3646
+ d ? /* @__PURE__ */ a("span", { className: "vx-field-group__error", children: d }) : null,
3647
+ !d && i ? /* @__PURE__ */ a("span", { className: "vx-field-group__hint", children: i }) : null,
3648
+ v && (() => {
3649
+ const M = !!(P && !$), q = M && P ? { top: P.top, bottom: P.bottom, left: P.left, width: P.width } : P && $ ? {
3650
+ position: "absolute",
3651
+ left: 0,
3652
+ width: "100%",
3653
+ top: P.direction === "down" ? "calc(100% + 4px)" : void 0,
3654
+ bottom: P.direction === "up" ? "calc(100% + 4px)" : void 0
3655
+ } : void 0, F = /* @__PURE__ */ k(
3656
+ "div",
3657
+ {
3658
+ ref: C,
3659
+ className: T(
3660
+ "vx-select__dropdown",
3661
+ (P == null ? void 0 : P.direction) === "up" && "vx-select__dropdown--up",
3662
+ P && $ && "vx-select__dropdown--in-dialog"
3663
+ ),
3664
+ style: q,
3665
+ children: [
3666
+ Z && /* @__PURE__ */ a("div", { className: "vx-select__search-wrap", children: /* @__PURE__ */ a(
3667
+ "input",
3668
+ {
3669
+ ref: A,
3670
+ type: "text",
3671
+ className: "vx-select__search",
3672
+ placeholder: s,
3673
+ value: m,
3674
+ onChange: (O) => x(O.target.value),
3675
+ "aria-label": s
3676
+ }
3677
+ ) }),
3678
+ /* @__PURE__ */ a("ul", { id: R, className: "vx-select__list", role: "listbox", "aria-label": l ?? "Options", children: H.length === 0 ? /* @__PURE__ */ a("li", { className: "vx-select__empty", children: p }) : H.map((O) => /* @__PURE__ */ k(
3679
+ "li",
3680
+ {
3681
+ className: T(
3682
+ "vx-select__option",
3683
+ O.value === y && "vx-select__option--selected",
3684
+ O.disabled && "vx-select__option--disabled"
3685
+ ),
3686
+ role: "option",
3687
+ "aria-selected": O.value === y,
3688
+ "aria-disabled": O.disabled,
3689
+ onClick: () => j(O),
3690
+ children: [
3691
+ /* @__PURE__ */ a("span", { children: O.label }),
3692
+ O.value === y ? /* @__PURE__ */ a(Ke, { size: 14 }) : null
3693
+ ]
3694
+ },
3695
+ O.value
3696
+ )) })
3697
+ ]
3698
+ }
3699
+ );
3700
+ return M ? yt(F, document.body) : F;
3701
+ })()
3539
3702
  ] });
3540
3703
  }
3541
3704
  function vl({ className: e, label: t, description: n, indeterminate: r, ...o }) {
3542
- return /* @__PURE__ */ k("label", { className: C("vx-checkbox", o.disabled && "vx-checkbox--disabled"), children: [
3705
+ return /* @__PURE__ */ k("label", { className: T("vx-checkbox", o.disabled && "vx-checkbox--disabled"), children: [
3543
3706
  /* @__PURE__ */ k("span", { className: "vx-checkbox__control-wrap", children: [
3544
3707
  /* @__PURE__ */ a(
3545
3708
  "input",
3546
3709
  {
3547
3710
  type: "checkbox",
3548
- className: C("vx-checkbox__input", e),
3711
+ className: T("vx-checkbox__input", e),
3549
3712
  ref: (s) => {
3550
3713
  s && (s.indeterminate = r ?? !1);
3551
3714
  },
@@ -3570,8 +3733,8 @@ function fl({
3570
3733
  size: l = "md"
3571
3734
  }) {
3572
3735
  var h;
3573
- const [i, d] = I(n ?? ((h = e[0]) == null ? void 0 : h.value)), c = t !== void 0, u = c ? t : i, [p, b] = I({ left: 0, width: 0, opacity: 0 }), w = z(null), S = z({});
3574
- $(() => {
3736
+ const [i, d] = I(n ?? ((h = e[0]) == null ? void 0 : h.value)), c = t !== void 0, u = c ? t : i, [p, b] = I({ left: 0, width: 0, opacity: 0 }), w = B(null), S = B({});
3737
+ z(() => {
3575
3738
  requestAnimationFrame(() => {
3576
3739
  const y = S.current[u];
3577
3740
  y && b({
@@ -3588,7 +3751,7 @@ function fl({
3588
3751
  "div",
3589
3752
  {
3590
3753
  ref: w,
3591
- className: C(
3754
+ className: T(
3592
3755
  "vx-segmented-control",
3593
3756
  `vx-segmented-control--${l}`,
3594
3757
  s && "vx-segmented-control--full",
@@ -3619,7 +3782,7 @@ function fl({
3619
3782
  "aria-checked": v,
3620
3783
  disabled: y.disabled,
3621
3784
  onClick: () => !y.disabled && g(y.value),
3622
- className: C(
3785
+ className: T(
3623
3786
  "vx-segmented-control__item",
3624
3787
  v && "vx-segmented-control__item--active"
3625
3788
  ),
@@ -3633,9 +3796,9 @@ function fl({
3633
3796
  );
3634
3797
  }
3635
3798
  function ml({ className: e, label: t, description: n, ...r }) {
3636
- return /* @__PURE__ */ k("label", { className: C("vx-radio", r.disabled && "vx-radio--disabled"), children: [
3799
+ return /* @__PURE__ */ k("label", { className: T("vx-radio", r.disabled && "vx-radio--disabled"), children: [
3637
3800
  /* @__PURE__ */ k("span", { className: "vx-radio__control-wrap", children: [
3638
- /* @__PURE__ */ a("input", { type: "radio", className: C("vx-radio__input", e), ...r }),
3801
+ /* @__PURE__ */ a("input", { type: "radio", className: T("vx-radio__input", e), ...r }),
3639
3802
  /* @__PURE__ */ a("span", { className: "vx-radio__circle", "aria-hidden": "true", children: /* @__PURE__ */ a("span", { className: "vx-radio__dot" }) })
3640
3803
  ] }),
3641
3804
  t ? /* @__PURE__ */ k("span", { className: "vx-radio__copy", children: [
@@ -3645,7 +3808,7 @@ function ml({ className: e, label: t, description: n, ...r }) {
3645
3808
  ] });
3646
3809
  }
3647
3810
  function hl({ label: e, children: t, className: n }) {
3648
- return /* @__PURE__ */ k("fieldset", { className: C("vx-radio-group", n), children: [
3811
+ return /* @__PURE__ */ k("fieldset", { className: T("vx-radio-group", n), children: [
3649
3812
  e ? /* @__PURE__ */ a("legend", { className: "vx-field-group__label", children: e }) : null,
3650
3813
  /* @__PURE__ */ a("div", { className: "vx-radio-group__items", children: t })
3651
3814
  ] });
@@ -3656,7 +3819,7 @@ function gl({ className: e, label: t, hint: n, resize: r = "vertical", style: o,
3656
3819
  /* @__PURE__ */ a(
3657
3820
  "textarea",
3658
3821
  {
3659
- className: C("vx-textarea", e),
3822
+ className: T("vx-textarea", e),
3660
3823
  style: { resize: r, ...o },
3661
3824
  ...s
3662
3825
  }
@@ -3674,7 +3837,7 @@ function bl({ className: e, label: t, showValue: n = !1, hint: r, value: o, defa
3674
3837
  "input",
3675
3838
  {
3676
3839
  type: "range",
3677
- className: C("vx-slider", e),
3840
+ className: T("vx-slider", e),
3678
3841
  value: o,
3679
3842
  defaultValue: s,
3680
3843
  ...l
@@ -3691,7 +3854,7 @@ function xl({ className: e, size: t = "md", label: n = "Loading…", ...r }) {
3691
3854
  {
3692
3855
  role: "status",
3693
3856
  "aria-label": n,
3694
- className: C("vx-spinner", `vx-spinner--${t}`, e),
3857
+ className: T("vx-spinner", `vx-spinner--${t}`, e),
3695
3858
  ...r,
3696
3859
  children: /* @__PURE__ */ a(
3697
3860
  "svg",
@@ -3730,7 +3893,7 @@ function yl({
3730
3893
  ...d
3731
3894
  }) {
3732
3895
  const c = i ? void 0 : Math.min(100, Math.max(0, t / n * 100));
3733
- return /* @__PURE__ */ k("div", { className: C("vx-progress-wrap", e), ...d, children: [
3896
+ return /* @__PURE__ */ k("div", { className: T("vx-progress-wrap", e), ...d, children: [
3734
3897
  r || o ? /* @__PURE__ */ k("div", { className: "vx-progress__header", children: [
3735
3898
  r ? /* @__PURE__ */ a("span", { className: "vx-progress__label", children: r }) : null,
3736
3899
  o && !i ? /* @__PURE__ */ k("span", { className: "vx-progress__value", children: [
@@ -3746,7 +3909,7 @@ function yl({
3746
3909
  "aria-valuemin": 0,
3747
3910
  "aria-valuemax": n,
3748
3911
  "aria-label": r,
3749
- className: C(
3912
+ className: T(
3750
3913
  "vx-progress",
3751
3914
  `vx-progress--${s}`,
3752
3915
  `vx-progress--${l}`,
@@ -3794,7 +3957,7 @@ function _l({
3794
3957
  "div",
3795
3958
  {
3796
3959
  role: "alert",
3797
- className: C("vx-alert", `vx-alert--${t}`, e),
3960
+ className: T("vx-alert", `vx-alert--${t}`, e),
3798
3961
  ...l,
3799
3962
  children: [
3800
3963
  /* @__PURE__ */ a("span", { className: "vx-alert__icon", children: r ?? vi[t] }),
@@ -3816,7 +3979,7 @@ function wl({
3816
3979
  style: s,
3817
3980
  ...l
3818
3981
  }) {
3819
- return r === "text" && o > 1 ? /* @__PURE__ */ a("span", { className: C("vx-skeleton-text", e), ...l, children: Array.from({ length: o }).map((i, d) => /* @__PURE__ */ a(
3982
+ return r === "text" && o > 1 ? /* @__PURE__ */ a("span", { className: T("vx-skeleton-text", e), ...l, children: Array.from({ length: o }).map((i, d) => /* @__PURE__ */ a(
3820
3983
  "span",
3821
3984
  {
3822
3985
  className: "vx-skeleton vx-skeleton--text",
@@ -3826,7 +3989,7 @@ function wl({
3826
3989
  )) }) : /* @__PURE__ */ a(
3827
3990
  "span",
3828
3991
  {
3829
- className: C(
3992
+ className: T(
3830
3993
  "vx-skeleton",
3831
3994
  `vx-skeleton--${r}`,
3832
3995
  e
@@ -3841,16 +4004,16 @@ function wl({
3841
4004
  );
3842
4005
  }
3843
4006
  function kl({ content: e, placement: t = "top", delay: n = 600, children: r, className: o }) {
3844
- const [s, l] = I(!1), i = z(null), d = q(() => {
4007
+ const [s, l] = I(!1), i = B(null), d = Y(() => {
3845
4008
  i.current = setTimeout(() => l(!0), n);
3846
- }, [n]), c = q(() => {
4009
+ }, [n]), c = Y(() => {
3847
4010
  i.current && clearTimeout(i.current), l(!1);
3848
4011
  }, []);
3849
- return $(() => () => {
4012
+ return z(() => () => {
3850
4013
  i.current && clearTimeout(i.current);
3851
- }, []), /* @__PURE__ */ k("span", { className: C("vx-tooltip-wrap", o), onMouseEnter: d, onMouseLeave: c, onFocus: d, onBlur: c, children: [
4014
+ }, []), /* @__PURE__ */ k("span", { className: T("vx-tooltip-wrap", o), onMouseEnter: d, onMouseLeave: c, onFocus: d, onBlur: c, children: [
3852
4015
  r,
3853
- s ? /* @__PURE__ */ a("span", { role: "tooltip", className: C("vx-tooltip", `vx-tooltip--${t}`), children: e }) : null
4016
+ s ? /* @__PURE__ */ a("span", { role: "tooltip", className: T("vx-tooltip", `vx-tooltip--${t}`), children: e }) : null
3854
4017
  ] });
3855
4018
  }
3856
4019
  function Nl({
@@ -3862,10 +4025,10 @@ function Nl({
3862
4025
  open: s,
3863
4026
  onOpenChange: l
3864
4027
  }) {
3865
- const [i, d] = I(!1), c = s !== void 0, u = c ? s : i, p = z(null), b = q((g) => {
4028
+ const [i, d] = I(!1), c = s !== void 0, u = c ? s : i, p = B(null), b = Y((g) => {
3866
4029
  c || d(g), l == null || l(g);
3867
- }, [c, l]), w = q(() => b(!u), [u, b]);
3868
- $(() => {
4030
+ }, [c, l]), w = Y(() => b(!u), [u, b]);
4031
+ z(() => {
3869
4032
  if (!u) return;
3870
4033
  const g = (y) => {
3871
4034
  y.key === "Escape" && b(!1);
@@ -3877,9 +4040,9 @@ function Nl({
3877
4040
  };
3878
4041
  }, [u, b]);
3879
4042
  const S = n === "click" ? { onClick: w } : { onMouseEnter: () => b(!0), onMouseLeave: () => b(!1) };
3880
- return /* @__PURE__ */ k("div", { ref: p, className: C("vx-popover-wrap", o), ...S, children: [
4043
+ return /* @__PURE__ */ k("div", { ref: p, className: T("vx-popover-wrap", o), ...S, children: [
3881
4044
  r,
3882
- u ? /* @__PURE__ */ a("div", { className: C("vx-popover", `vx-popover--${t}`), role: "dialog", children: e }) : null
4045
+ u ? /* @__PURE__ */ a("div", { className: T("vx-popover", `vx-popover--${t}`), role: "dialog", children: e }) : null
3883
4046
  ] });
3884
4047
  }
3885
4048
  function Sl({
@@ -3891,10 +4054,10 @@ function Sl({
3891
4054
  open: s,
3892
4055
  onOpenChange: l
3893
4056
  }) {
3894
- const [i, d] = I(!1), c = s !== void 0, u = c ? s : i, p = z(null), b = q((g) => {
4057
+ const [i, d] = I(!1), c = s !== void 0, u = c ? s : i, p = B(null), b = Y((g) => {
3895
4058
  c || d(g), l == null || l(g);
3896
- }, [c, l]), w = q(() => b(!u), [u, b]);
3897
- $(() => {
4059
+ }, [c, l]), w = Y(() => b(!u), [u, b]);
4060
+ z(() => {
3898
4061
  if (!u) return;
3899
4062
  const g = (y) => {
3900
4063
  y.key === "Escape" && b(!1);
@@ -3906,7 +4069,7 @@ function Sl({
3906
4069
  };
3907
4070
  }, [u, b]);
3908
4071
  const S = t ?? (n ? [{ items: n }] : []);
3909
- return /* @__PURE__ */ k("div", { ref: p, className: C("vx-dropdown", u && "vx-dropdown--open", o), children: [
4072
+ return /* @__PURE__ */ k("div", { ref: p, className: T("vx-dropdown", u && "vx-dropdown--open", o), children: [
3910
4073
  /* @__PURE__ */ a(
3911
4074
  "div",
3912
4075
  {
@@ -3920,7 +4083,7 @@ function Sl({
3920
4083
  children: e
3921
4084
  }
3922
4085
  ),
3923
- u ? /* @__PURE__ */ a("div", { className: C("vx-dropdown__menu", `vx-dropdown__menu--${r}`), role: "menu", children: S.map((g, h) => /* @__PURE__ */ k("div", { className: "vx-dropdown__group", children: [
4086
+ u ? /* @__PURE__ */ a("div", { className: T("vx-dropdown__menu", `vx-dropdown__menu--${r}`), role: "menu", children: S.map((g, h) => /* @__PURE__ */ k("div", { className: "vx-dropdown__group", children: [
3924
4087
  g.label ? /* @__PURE__ */ a("div", { className: "vx-dropdown__group-label", children: g.label }) : null,
3925
4088
  h > 0 && !g.label ? /* @__PURE__ */ a("div", { className: "vx-dropdown__separator", role: "separator" }) : null,
3926
4089
  g.items.map((y, v) => /* @__PURE__ */ k(
@@ -3928,7 +4091,7 @@ function Sl({
3928
4091
  {
3929
4092
  role: "menuitem",
3930
4093
  disabled: y.disabled,
3931
- className: C(
4094
+ className: T(
3932
4095
  "vx-dropdown__item",
3933
4096
  y.danger && "vx-dropdown__item--danger",
3934
4097
  y.disabled && "vx-dropdown__item--disabled"
@@ -3950,7 +4113,7 @@ function Sl({
3950
4113
  }
3951
4114
  const fi = () => /* @__PURE__ */ a("svg", { width: "12", height: "12", viewBox: "0 0 12 12", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ a("path", { d: "M4.5 2.5L7.5 6l-3 3.5", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
3952
4115
  function El({ items: e, separator: t, className: n }) {
3953
- return /* @__PURE__ */ a("nav", { "aria-label": "Breadcrumb", className: C("vx-breadcrumb", n), children: /* @__PURE__ */ a("ol", { className: "vx-breadcrumb__list", children: e.map((r, o) => {
4116
+ return /* @__PURE__ */ a("nav", { "aria-label": "Breadcrumb", className: T("vx-breadcrumb", n), children: /* @__PURE__ */ a("ol", { className: "vx-breadcrumb__list", children: e.map((r, o) => {
3954
4117
  const s = o === e.length - 1;
3955
4118
  return /* @__PURE__ */ k("li", { className: "vx-breadcrumb__item", children: [
3956
4119
  s ? /* @__PURE__ */ a("span", { className: "vx-breadcrumb__current", "aria-current": "page", children: r.label }) : r.href ? /* @__PURE__ */ a("a", { href: r.href, className: "vx-breadcrumb__link", children: r.label }) : /* @__PURE__ */ a("button", { type: "button", className: "vx-breadcrumb__link", onClick: r.onClick, children: r.label }),
@@ -3958,17 +4121,17 @@ function El({ items: e, separator: t, className: n }) {
3958
4121
  ] }, o);
3959
4122
  }) }) });
3960
4123
  }
3961
- function $e(e, t) {
4124
+ function Oe(e, t) {
3962
4125
  return Array.from({ length: t - e + 1 }, (n, r) => e + r);
3963
4126
  }
3964
- function Cl({ page: e, total: t, pageSize: n = 10, siblingCount: r = 1, onChange: o, className: s }) {
4127
+ function Tl({ page: e, total: t, pageSize: n = 10, siblingCount: r = 1, onChange: o, className: s }) {
3965
4128
  const l = Math.max(1, Math.ceil(t / n)), i = (() => {
3966
4129
  const d = r * 2 + 5;
3967
- if (l <= d) return $e(1, l);
4130
+ if (l <= d) return Oe(1, l);
3968
4131
  const c = Math.max(e - r, 1), u = Math.min(e + r, l), p = c > 3, b = u < l - 2;
3969
- return !p && b ? [...$e(1, 3 + r * 2), "…", l] : p && !b ? [1, "…", ...$e(l - (2 + r * 2), l)] : [1, "…", ...$e(c, u), "…", l];
4132
+ return !p && b ? [...Oe(1, 3 + r * 2), "…", l] : p && !b ? [1, "…", ...Oe(l - (2 + r * 2), l)] : [1, "…", ...Oe(c, u), "…", l];
3970
4133
  })();
3971
- return /* @__PURE__ */ k("nav", { role: "navigation", "aria-label": "Pagination", className: C("vx-pagination", s), children: [
4134
+ return /* @__PURE__ */ k("nav", { role: "navigation", "aria-label": "Pagination", className: T("vx-pagination", s), children: [
3972
4135
  /* @__PURE__ */ a(
3973
4136
  "button",
3974
4137
  {
@@ -3986,7 +4149,7 @@ function Cl({ page: e, total: t, pageSize: n = 10, siblingCount: r = 1, onChange
3986
4149
  {
3987
4150
  type: "button",
3988
4151
  "aria-current": d === e ? "page" : void 0,
3989
- className: C("vx-pagination__btn", d === e && "vx-pagination__btn--active"),
4152
+ className: T("vx-pagination__btn", d === e && "vx-pagination__btn--active"),
3990
4153
  onClick: () => o(d),
3991
4154
  children: d
3992
4155
  },
@@ -4006,7 +4169,7 @@ function Cl({ page: e, total: t, pageSize: n = 10, siblingCount: r = 1, onChange
4006
4169
  )
4007
4170
  ] });
4008
4171
  }
4009
- function Tl({ items: e, multiple: t = !1, defaultOpen: n = [], className: r }) {
4172
+ function Cl({ items: e, multiple: t = !1, defaultOpen: n = [], className: r }) {
4010
4173
  const [o, s] = I(new Set(n));
4011
4174
  function l(i) {
4012
4175
  s((d) => {
@@ -4014,9 +4177,9 @@ function Tl({ items: e, multiple: t = !1, defaultOpen: n = [], className: r }) {
4014
4177
  return d.has(i) ? c.delete(i) : c.add(i), c;
4015
4178
  });
4016
4179
  }
4017
- return /* @__PURE__ */ a("div", { className: C("vx-accordion", r), children: e.map((i) => {
4180
+ return /* @__PURE__ */ a("div", { className: T("vx-accordion", r), children: e.map((i) => {
4018
4181
  const d = o.has(i.key);
4019
- return /* @__PURE__ */ k("div", { className: C("vx-accordion__item", d && "vx-accordion__item--open", i.disabled && "vx-accordion__item--disabled"), children: [
4182
+ return /* @__PURE__ */ k("div", { className: T("vx-accordion__item", d && "vx-accordion__item--open", i.disabled && "vx-accordion__item--disabled"), children: [
4020
4183
  /* @__PURE__ */ k(
4021
4184
  "button",
4022
4185
  {
@@ -4041,7 +4204,7 @@ function Al({ className: e, orientation: t = "horizontal", decorative: n = !0, .
4041
4204
  {
4042
4205
  role: n ? "none" : "separator",
4043
4206
  "aria-orientation": n ? void 0 : t,
4044
- className: C("vx-separator", `vx-separator--${t}`, e),
4207
+ className: T("vx-separator", `vx-separator--${t}`, e),
4045
4208
  ...r
4046
4209
  }
4047
4210
  );
@@ -4061,7 +4224,7 @@ function Pl({ src: e, name: t, size: n = "md", shape: r = "circle", fallback: o,
4061
4224
  return /* @__PURE__ */ a(
4062
4225
  "span",
4063
4226
  {
4064
- className: C("vx-avatar", `vx-avatar--${n}`, `vx-avatar--${r}`, s),
4227
+ className: T("vx-avatar", `vx-avatar--${n}`, `vx-avatar--${r}`, s),
4065
4228
  "aria-label": p || void 0,
4066
4229
  style: u ? void 0 : { "--vx-avatar-hue": b },
4067
4230
  children: u ? /* @__PURE__ */ a(
@@ -4101,11 +4264,11 @@ function Rl({
4101
4264
  className: y,
4102
4265
  ...v
4103
4266
  }) {
4104
- const f = l ? "sm" : n, [m, x] = I(null), [N, E] = I(null), T = S !== void 0, A = T ? S : m, P = T ? g ?? null : N, R = q((L) => {
4105
- let B;
4106
- A !== L ? B = "asc" : P === "asc" ? B = "desc" : P === "desc" ? B = null : B = "asc", T || (x(B === null ? null : L), E(B)), h == null || h(L, B);
4107
- }, [A, P, T, h]);
4108
- return /* @__PURE__ */ a("div", { className: C(
4267
+ const f = l ? "sm" : n, [m, x] = I(null), [N, E] = I(null), C = S !== void 0, A = C ? S : m, R = C ? g ?? null : N, P = Y((L) => {
4268
+ let $;
4269
+ A !== L ? $ = "asc" : R === "asc" ? $ = "desc" : R === "desc" ? $ = null : $ = "asc", C || (x($ === null ? null : L), E($)), h == null || h(L, $);
4270
+ }, [A, R, C, h]);
4271
+ return /* @__PURE__ */ a("div", { className: T(
4109
4272
  "vx-table-wrap",
4110
4273
  d && "vx-table-wrap--borderless",
4111
4274
  !u && "vx-table-wrap--square",
@@ -4113,7 +4276,7 @@ function Rl({
4113
4276
  ), ...v, children: /* @__PURE__ */ k(
4114
4277
  "table",
4115
4278
  {
4116
- className: C(
4279
+ className: T(
4117
4280
  "vx-table",
4118
4281
  r && "vx-table--striped",
4119
4282
  o && "vx-table--hoverable",
@@ -4127,50 +4290,50 @@ function Rl({
4127
4290
  c ? null : /* @__PURE__ */ a("thead", { children: /* @__PURE__ */ a("tr", { children: e.map((L) => /* @__PURE__ */ a(
4128
4291
  "th",
4129
4292
  {
4130
- className: C(
4293
+ className: T(
4131
4294
  "vx-table__th",
4132
4295
  L.sortable && "vx-table__th--sortable",
4133
4296
  L.align && `vx-table__th--${L.align}`,
4134
4297
  L.className
4135
4298
  ),
4136
4299
  style: { width: L.width },
4137
- onClick: L.sortable ? () => R(L.key) : void 0,
4138
- "aria-sort": A === L.key ? P === "asc" ? "ascending" : P === "desc" ? "descending" : "none" : void 0,
4300
+ onClick: L.sortable ? () => P(L.key) : void 0,
4301
+ "aria-sort": A === L.key ? R === "asc" ? "ascending" : R === "desc" ? "descending" : "none" : void 0,
4139
4302
  children: /* @__PURE__ */ k("span", { className: "vx-table__th-inner", children: [
4140
4303
  L.header,
4141
- L.sortable ? /* @__PURE__ */ a("span", { className: "vx-table__sort-icon", "aria-hidden": "true", children: A === L.key && P === "asc" ? "↑" : A === L.key && P === "desc" ? "↓" : "↕" }) : null
4304
+ L.sortable ? /* @__PURE__ */ a("span", { className: "vx-table__sort-icon", "aria-hidden": "true", children: A === L.key && R === "asc" ? "↑" : A === L.key && R === "desc" ? "↓" : "↕" }) : null
4142
4305
  ] })
4143
4306
  },
4144
4307
  L.key
4145
4308
  )) }) }),
4146
- /* @__PURE__ */ a("tbody", { className: C(p && "vx-table__body--loading"), children: t.length === 0 ? /* @__PURE__ */ a("tr", { children: /* @__PURE__ */ a("td", { colSpan: e.length, className: "vx-table__empty", children: w }) }) : t.map((L, B) => /* @__PURE__ */ a("tr", { className: "vx-table__row", children: e.map((D) => /* @__PURE__ */ a(
4309
+ /* @__PURE__ */ a("tbody", { className: T(p && "vx-table__body--loading"), children: t.length === 0 ? /* @__PURE__ */ a("tr", { children: /* @__PURE__ */ a("td", { colSpan: e.length, className: "vx-table__empty", children: w }) }) : t.map((L, $) => /* @__PURE__ */ a("tr", { className: "vx-table__row", children: e.map((D) => /* @__PURE__ */ a(
4147
4310
  "td",
4148
4311
  {
4149
- className: C("vx-table__td", D.align && `vx-table__td--${D.align}`, D.className),
4312
+ className: T("vx-table__td", D.align && `vx-table__td--${D.align}`, D.className),
4150
4313
  children: D.accessor(L)
4151
4314
  },
4152
4315
  D.key
4153
- )) }, B)) })
4316
+ )) }, $)) })
4154
4317
  ]
4155
4318
  }
4156
4319
  ) });
4157
4320
  }
4158
4321
  function Dl({ topBar: e, bottomNav: t, children: n, className: r }) {
4159
- return /* @__PURE__ */ k("div", { className: C("vxm-shell", r), children: [
4322
+ return /* @__PURE__ */ k("div", { className: T("vxm-shell", r), children: [
4160
4323
  e && /* @__PURE__ */ a("div", { className: "vxm-shell__topbar", children: e }),
4161
4324
  /* @__PURE__ */ a("main", { className: "vxm-shell__main", children: n }),
4162
4325
  t && /* @__PURE__ */ a("div", { className: "vxm-shell__bottomnav", children: t })
4163
4326
  ] });
4164
4327
  }
4165
4328
  function Fl({ title: e, leading: t, trailing: n, className: r }) {
4166
- return /* @__PURE__ */ k("div", { className: C("vxm-topbar", r), children: [
4329
+ return /* @__PURE__ */ k("div", { className: T("vxm-topbar", r), children: [
4167
4330
  /* @__PURE__ */ a("div", { className: "vxm-topbar__leading", children: t }),
4168
4331
  /* @__PURE__ */ a("div", { className: "vxm-topbar__title", children: e }),
4169
4332
  /* @__PURE__ */ a("div", { className: "vxm-topbar__trailing", children: n })
4170
4333
  ] });
4171
4334
  }
4172
4335
  function Ll({ label: e, className: t, children: n, ...r }) {
4173
- return /* @__PURE__ */ a("button", { type: "button", className: C("vxm-icon-btn", t), "aria-label": e, ...r, children: n });
4336
+ return /* @__PURE__ */ a("button", { type: "button", className: T("vxm-icon-btn", t), "aria-label": e, ...r, children: n });
4174
4337
  }
4175
4338
  function Il({ items: e, className: t }) {
4176
4339
  const [n, r] = I(null), o = n ? e.find((l) => l.key === n) : null, s = (l) => {
@@ -4178,7 +4341,7 @@ function Il({ items: e, className: t }) {
4178
4341
  (i = l.submenu) != null && i.length ? r((c) => c === l.key ? null : l.key) : (r(null), (d = l.onSelect) == null || d.call(l));
4179
4342
  };
4180
4343
  return /* @__PURE__ */ k("div", { className: "vxm-bottomnav-wrap", children: [
4181
- n && (o == null ? void 0 : o.submenu) && /* @__PURE__ */ k(J, { children: [
4344
+ n && (o == null ? void 0 : o.submenu) && /* @__PURE__ */ k(ee, { children: [
4182
4345
  /* @__PURE__ */ a(
4183
4346
  "div",
4184
4347
  {
@@ -4205,13 +4368,13 @@ function Il({ items: e, className: t }) {
4205
4368
  l.key
4206
4369
  )) })
4207
4370
  ] }),
4208
- /* @__PURE__ */ a("nav", { className: C("vxm-bottomnav", t), "aria-label": "底部导航", children: e.map((l) => {
4371
+ /* @__PURE__ */ a("nav", { className: T("vxm-bottomnav", t), "aria-label": "底部导航", children: e.map((l) => {
4209
4372
  var i, d, c;
4210
4373
  return /* @__PURE__ */ k(
4211
4374
  "button",
4212
4375
  {
4213
4376
  type: "button",
4214
- className: C(
4377
+ className: T(
4215
4378
  "vxm-bottomnav__item",
4216
4379
  l.active && "vxm-bottomnav__item--active",
4217
4380
  ((i = l.submenu) == null ? void 0 : i.length) && n === l.key && "vxm-bottomnav__item--submenu-open"
@@ -4241,16 +4404,16 @@ function Ml({
4241
4404
  children: o,
4242
4405
  className: s
4243
4406
  }) {
4244
- const l = z(null), i = z(0), [d, c] = I(!1), [u, p] = I(0), b = z(0);
4245
- $(() => {
4407
+ const l = B(null), i = B(0), [d, c] = I(!1), [u, p] = I(0), b = B(0);
4408
+ z(() => {
4246
4409
  e || (p(0), b.current = 0);
4247
- }, [e]), $(() => {
4410
+ }, [e]), z(() => {
4248
4411
  if (!e) return;
4249
4412
  const h = (y) => {
4250
4413
  y.key === "Escape" && t();
4251
4414
  };
4252
4415
  return document.addEventListener("keydown", h), () => document.removeEventListener("keydown", h);
4253
- }, [e, t]), $(() => (e ? document.body.style.overflow = "hidden" : document.body.style.overflow = "", () => {
4416
+ }, [e, t]), z(() => (e ? document.body.style.overflow = "hidden" : document.body.style.overflow = "", () => {
4254
4417
  document.body.style.overflow = "";
4255
4418
  }), [e]);
4256
4419
  const w = (h) => {
@@ -4276,7 +4439,7 @@ function Ml({
4276
4439
  "div",
4277
4440
  {
4278
4441
  ref: l,
4279
- className: C("vxm-actionsheet", s),
4442
+ className: T("vxm-actionsheet", s),
4280
4443
  style: {
4281
4444
  transform: `translateY(${u}px)`,
4282
4445
  transition: d ? "none" : "transform 280ms cubic-bezier(0.32, 0.72, 0, 1)"
@@ -4301,12 +4464,12 @@ function Ml({
4301
4464
  }
4302
4465
  ) : null;
4303
4466
  }
4304
- function Ol({ icon: e, destructive: t, className: n, children: r, ...o }) {
4467
+ function $l({ icon: e, destructive: t, className: n, children: r, ...o }) {
4305
4468
  return /* @__PURE__ */ k(
4306
4469
  "button",
4307
4470
  {
4308
4471
  type: "button",
4309
- className: C("vxm-actionsheet-item", t && "vxm-actionsheet-item--destructive", n),
4472
+ className: T("vxm-actionsheet-item", t && "vxm-actionsheet-item--destructive", n),
4310
4473
  ...o,
4311
4474
  children: [
4312
4475
  e && /* @__PURE__ */ a("span", { className: "vxm-actionsheet-item__icon", children: e }),
@@ -4315,11 +4478,11 @@ function Ol({ icon: e, destructive: t, className: n, children: r, ...o }) {
4315
4478
  }
4316
4479
  );
4317
4480
  }
4318
- function $l({ className: e, ...t }) {
4319
- return /* @__PURE__ */ a("ul", { className: C("vxm-list", e), role: "list", ...t });
4481
+ function Ol({ className: e, ...t }) {
4482
+ return /* @__PURE__ */ a("ul", { className: T("vxm-list", e), role: "list", ...t });
4320
4483
  }
4321
4484
  function Bl({ title: e, className: t, children: n, ...r }) {
4322
- return /* @__PURE__ */ k("div", { className: C("vxm-list-section", t), ...r, children: [
4485
+ return /* @__PURE__ */ k("div", { className: T("vxm-list-section", t), ...r, children: [
4323
4486
  e && /* @__PURE__ */ a("div", { className: "vxm-list-section__title", children: e }),
4324
4487
  n
4325
4488
  ] });
@@ -4335,19 +4498,19 @@ function zl({
4335
4498
  onClick: i,
4336
4499
  className: d
4337
4500
  }) {
4338
- const c = /* @__PURE__ */ k(J, { children: [
4501
+ const c = /* @__PURE__ */ k(ee, { children: [
4339
4502
  e && /* @__PURE__ */ a("span", { className: "vxm-list-item__leading", children: e }),
4340
4503
  /* @__PURE__ */ k("span", { className: "vxm-list-item__content", children: [
4341
4504
  /* @__PURE__ */ a("span", { className: "vxm-list-item__label", children: n }),
4342
4505
  r && /* @__PURE__ */ a("span", { className: "vxm-list-item__description", children: r })
4343
4506
  ] }),
4344
4507
  t && /* @__PURE__ */ a("span", { className: "vxm-list-item__trailing", children: t }),
4345
- o && /* @__PURE__ */ a(Ce, { size: 16, className: "vxm-list-item__chevron", "aria-hidden": "true" })
4508
+ o && /* @__PURE__ */ a(Te, { size: 16, className: "vxm-list-item__chevron", "aria-hidden": "true" })
4346
4509
  ] });
4347
4510
  return /* @__PURE__ */ a(
4348
4511
  "li",
4349
4512
  {
4350
- className: C(
4513
+ className: T(
4351
4514
  "vxm-list-item",
4352
4515
  s && "vxm-list-item--destructive",
4353
4516
  l && "vxm-list-item--disabled",
@@ -4377,16 +4540,16 @@ function Ul({
4377
4540
  children: s,
4378
4541
  className: l
4379
4542
  }) {
4380
- const i = z(null), d = z(0), c = z(0), [u, p] = I(!1), [b, w] = I(0);
4381
- $(() => {
4543
+ const i = B(null), d = B(0), c = B(0), [u, p] = I(!1), [b, w] = I(0);
4544
+ z(() => {
4382
4545
  e || (w(0), c.current = 0);
4383
- }, [e]), $(() => {
4546
+ }, [e]), z(() => {
4384
4547
  if (!e) return;
4385
4548
  const f = (m) => {
4386
4549
  m.key === "Escape" && t();
4387
4550
  };
4388
4551
  return document.addEventListener("keydown", f), () => document.removeEventListener("keydown", f);
4389
- }, [e, t]), $(() => (document.body.style.overflow = e ? "hidden" : "", () => {
4552
+ }, [e, t]), z(() => (document.body.style.overflow = e ? "hidden" : "", () => {
4390
4553
  document.body.style.overflow = "";
4391
4554
  }), [e]);
4392
4555
  const S = (f) => {
@@ -4412,7 +4575,7 @@ function Ul({
4412
4575
  "div",
4413
4576
  {
4414
4577
  ref: i,
4415
- className: C("vxm-drawer", l),
4578
+ className: T("vxm-drawer", l),
4416
4579
  style: {
4417
4580
  width: n,
4418
4581
  transform: `translateX(${b}px)`,
@@ -4438,7 +4601,7 @@ function Wl({ icon: e, label: t, badge: n, active: r, onClick: o }) {
4438
4601
  "button",
4439
4602
  {
4440
4603
  type: "button",
4441
- className: C("vxm-drawer-item", r && "vxm-drawer-item--active"),
4604
+ className: T("vxm-drawer-item", r && "vxm-drawer-item--active"),
4442
4605
  onClick: o,
4443
4606
  "aria-current": r ? "page" : void 0,
4444
4607
  children: [
@@ -4451,7 +4614,7 @@ function Wl({ icon: e, label: t, badge: n, active: r, onClick: o }) {
4451
4614
  }
4452
4615
  function Hl({ title: e, collapsible: t = !1, defaultOpen: n = !0, children: r }) {
4453
4616
  const [o, s] = I(n);
4454
- return /* @__PURE__ */ k("div", { className: C("vxm-drawer-section", t && "vxm-drawer-section--collapsible"), children: [
4617
+ return /* @__PURE__ */ k("div", { className: T("vxm-drawer-section", t && "vxm-drawer-section--collapsible"), children: [
4455
4618
  e && (t ? /* @__PURE__ */ k(
4456
4619
  "button",
4457
4620
  {
@@ -4465,17 +4628,17 @@ function Hl({ title: e, collapsible: t = !1, defaultOpen: n = !0, children: r })
4465
4628
  Ee,
4466
4629
  {
4467
4630
  size: 14,
4468
- className: C("vxm-drawer-section__chevron", o && "vxm-drawer-section__chevron--open")
4631
+ className: T("vxm-drawer-section__chevron", o && "vxm-drawer-section__chevron--open")
4469
4632
  }
4470
4633
  )
4471
4634
  ]
4472
4635
  }
4473
4636
  ) : /* @__PURE__ */ a("div", { className: "vxm-drawer-section__title", children: e })),
4474
- /* @__PURE__ */ a("div", { className: C("vxm-drawer-section__items-wrap", !o && "vxm-drawer-section__items-wrap--closed"), children: /* @__PURE__ */ a("div", { className: "vxm-drawer-section__items", children: r }) })
4637
+ /* @__PURE__ */ a("div", { className: T("vxm-drawer-section__items-wrap", !o && "vxm-drawer-section__items-wrap--closed"), children: /* @__PURE__ */ a("div", { className: "vxm-drawer-section__items", children: r }) })
4475
4638
  ] });
4476
4639
  }
4477
4640
  const Gl = ce(function({ className: t, required: n, children: r, ...o }, s) {
4478
- return /* @__PURE__ */ k("label", { ref: s, className: C("vx-label", t), ...o, children: [
4641
+ return /* @__PURE__ */ k("label", { ref: s, className: T("vx-label", t), ...o, children: [
4479
4642
  r,
4480
4643
  n ? /* @__PURE__ */ a("span", { className: "vx-label__required", "aria-hidden": "true", children: " *" }) : null
4481
4644
  ] });
@@ -4484,23 +4647,23 @@ function gi() {
4484
4647
  return ye(zr);
4485
4648
  }
4486
4649
  function jl({ className: e, ...t }) {
4487
- return /* @__PURE__ */ a("form", { noValidate: !0, className: C("vx-form", e), ...t });
4650
+ return /* @__PURE__ */ a("form", { noValidate: !0, className: T("vx-form", e), ...t });
4488
4651
  }
4489
4652
  function Kl({ error: e, children: t, className: n }) {
4490
- return /* @__PURE__ */ a(zr.Provider, { value: { error: e }, children: /* @__PURE__ */ a("div", { className: C("vx-form-field", e && "vx-form-field--invalid", n), children: t }) });
4653
+ return /* @__PURE__ */ a(zr.Provider, { value: { error: e }, children: /* @__PURE__ */ a("div", { className: T("vx-form-field", e && "vx-form-field--invalid", n), children: t }) });
4491
4654
  }
4492
4655
  function Vl({ className: e, required: t, children: n, ...r }) {
4493
- return /* @__PURE__ */ k("label", { className: C("vx-form-label", e), ...r, children: [
4656
+ return /* @__PURE__ */ k("label", { className: T("vx-form-label", e), ...r, children: [
4494
4657
  n,
4495
4658
  t ? /* @__PURE__ */ a("span", { className: "vx-form-label__required", "aria-hidden": "true", children: " *" }) : null
4496
4659
  ] });
4497
4660
  }
4498
4661
  function ql({ className: e, children: t, ...n }) {
4499
- return /* @__PURE__ */ a("p", { className: C("vx-form-description", e), ...n, children: t });
4662
+ return /* @__PURE__ */ a("p", { className: T("vx-form-description", e), ...n, children: t });
4500
4663
  }
4501
4664
  function Yl({ className: e, children: t, ...n }) {
4502
4665
  const { error: r } = gi(), o = r ?? t;
4503
- return o ? /* @__PURE__ */ a("p", { className: C("vx-form-message", r && "vx-form-message--error", e), ...n, children: o }) : null;
4666
+ return o ? /* @__PURE__ */ a("p", { className: T("vx-form-message", r && "vx-form-message--error", e), ...n, children: o }) : null;
4504
4667
  }
4505
4668
  function Xl({
4506
4669
  trigger: e,
@@ -4515,13 +4678,13 @@ function Xl({
4515
4678
  ...c
4516
4679
  }) {
4517
4680
  return /* @__PURE__ */ k(Et, { ...c, children: [
4518
- /* @__PURE__ */ a(Ct, { asChild: !0, children: e }),
4519
- /* @__PURE__ */ k(Tt, { children: [
4681
+ /* @__PURE__ */ a(Tt, { asChild: !0, children: e }),
4682
+ /* @__PURE__ */ k(Ct, { children: [
4520
4683
  /* @__PURE__ */ a(At, { className: "vx-dialog__overlay" }),
4521
4684
  /* @__PURE__ */ k(
4522
4685
  Pt,
4523
4686
  {
4524
- className: C("vx-alert-dialog__content", d),
4687
+ className: T("vx-alert-dialog__content", d),
4525
4688
  role: "alertdialog",
4526
4689
  "aria-modal": "true",
4527
4690
  children: [
@@ -4550,7 +4713,7 @@ function Zl({
4550
4713
  disabled: c,
4551
4714
  ...u
4552
4715
  }) {
4553
- const p = q(
4716
+ const p = Y(
4554
4717
  (y) => {
4555
4718
  let v = y;
4556
4719
  return l !== void 0 && (v = Math.max(l, v)), i !== void 0 && (v = Math.min(i, v)), v;
@@ -4569,7 +4732,7 @@ function Zl({
4569
4732
  /* @__PURE__ */ k(
4570
4733
  "span",
4571
4734
  {
4572
- className: C(
4735
+ className: T(
4573
4736
  "vx-number-input",
4574
4737
  r && "vx-number-input--invalid",
4575
4738
  c && "vx-number-input--disabled",
@@ -4649,33 +4812,33 @@ function yi({
4649
4812
  weekStartsOnMonday: l = !1
4650
4813
  }) {
4651
4814
  const i = /* @__PURE__ */ new Date(), d = e !== void 0, [c, u] = I(t), p = d ? e : c, [b, w] = I((p ?? i).getFullYear()), [S, g] = I((p ?? i).getMonth()), h = bi(b, S), y = xi(b, S), v = l ? y === 0 ? 6 : y - 1 : y, f = l ? ["Mo", "Tu", "We", "Th", "Fr", "Sa", "Su"] : ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"], m = () => {
4652
- S === 0 ? (w((P) => P - 1), g(11)) : g((P) => P - 1);
4815
+ S === 0 ? (w((R) => R - 1), g(11)) : g((R) => R - 1);
4653
4816
  }, x = () => {
4654
- S === 11 ? (w((P) => P + 1), g(0)) : g((P) => P + 1);
4655
- }, N = q(
4656
- (P) => {
4657
- const R = new Date(b, S, P);
4817
+ S === 11 ? (w((R) => R + 1), g(0)) : g((R) => R + 1);
4818
+ }, N = Y(
4819
+ (R) => {
4820
+ const P = new Date(b, S, R);
4658
4821
  if (r) {
4659
4822
  const L = new Date(r.getFullYear(), r.getMonth(), r.getDate());
4660
- if (R < L) return !0;
4823
+ if (P < L) return !0;
4661
4824
  }
4662
4825
  if (o) {
4663
4826
  const L = new Date(o.getFullYear(), o.getMonth(), o.getDate());
4664
- if (R > L) return !0;
4827
+ if (P > L) return !0;
4665
4828
  }
4666
4829
  return !1;
4667
4830
  },
4668
4831
  [b, S, r, o]
4669
- ), E = (P) => {
4670
- if (N(P)) return;
4671
- const R = new Date(b, S, P);
4672
- d || u(R), n == null || n(R);
4673
- }, T = new Date(b, S).toLocaleString("default", { month: "long" }), A = [
4832
+ ), E = (R) => {
4833
+ if (N(R)) return;
4834
+ const P = new Date(b, S, R);
4835
+ d || u(P), n == null || n(P);
4836
+ }, C = new Date(b, S).toLocaleString("default", { month: "long" }), A = [
4674
4837
  ...Array(v).fill(null),
4675
- ...Array.from({ length: h }, (P, R) => R + 1)
4838
+ ...Array.from({ length: h }, (R, P) => P + 1)
4676
4839
  ];
4677
4840
  for (; A.length % 7 !== 0; ) A.push(null);
4678
- return /* @__PURE__ */ k("div", { className: C("vx-calendar", s), children: [
4841
+ return /* @__PURE__ */ k("div", { className: T("vx-calendar", s), children: [
4679
4842
  /* @__PURE__ */ k("div", { className: "vx-calendar__header", children: [
4680
4843
  /* @__PURE__ */ a(
4681
4844
  "button",
@@ -4688,7 +4851,7 @@ function yi({
4688
4851
  }
4689
4852
  ),
4690
4853
  /* @__PURE__ */ k("span", { className: "vx-calendar__month-label", children: [
4691
- T,
4854
+ C,
4692
4855
  " ",
4693
4856
  b
4694
4857
  ] }),
@@ -4699,34 +4862,34 @@ function yi({
4699
4862
  className: "vx-calendar__nav-btn",
4700
4863
  onClick: x,
4701
4864
  "aria-label": "Next month",
4702
- children: /* @__PURE__ */ a(Ce, { size: 16 })
4865
+ children: /* @__PURE__ */ a(Te, { size: 16 })
4703
4866
  }
4704
4867
  )
4705
4868
  ] }),
4706
- /* @__PURE__ */ k("div", { className: "vx-calendar__grid", role: "grid", "aria-label": `${T} ${b}`, children: [
4707
- f.map((P) => /* @__PURE__ */ a("div", { className: "vx-calendar__weekday", role: "columnheader", children: P }, P)),
4708
- A.map((P, R) => {
4709
- if (P === null)
4710
- return /* @__PURE__ */ a("div", { className: "vx-calendar__cell vx-calendar__cell--empty" }, `e-${R}`);
4711
- const L = new Date(b, S, P), B = rn(L, i), D = p ? rn(L, p) : !1, W = N(P);
4869
+ /* @__PURE__ */ k("div", { className: "vx-calendar__grid", role: "grid", "aria-label": `${C} ${b}`, children: [
4870
+ f.map((R) => /* @__PURE__ */ a("div", { className: "vx-calendar__weekday", role: "columnheader", children: R }, R)),
4871
+ A.map((R, P) => {
4872
+ if (R === null)
4873
+ return /* @__PURE__ */ a("div", { className: "vx-calendar__cell vx-calendar__cell--empty" }, `e-${P}`);
4874
+ const L = new Date(b, S, R), $ = rn(L, i), D = p ? rn(L, p) : !1, U = N(R);
4712
4875
  return /* @__PURE__ */ a(
4713
4876
  "button",
4714
4877
  {
4715
4878
  type: "button",
4716
4879
  role: "gridcell",
4717
- className: C(
4880
+ className: T(
4718
4881
  "vx-calendar__cell",
4719
- B && "vx-calendar__cell--today",
4882
+ $ && "vx-calendar__cell--today",
4720
4883
  D && "vx-calendar__cell--selected",
4721
- W && "vx-calendar__cell--disabled"
4884
+ U && "vx-calendar__cell--disabled"
4722
4885
  ),
4723
- onClick: () => E(P),
4724
- disabled: W,
4886
+ onClick: () => E(R),
4887
+ disabled: U,
4725
4888
  "aria-label": L.toLocaleDateString(),
4726
4889
  "aria-selected": D,
4727
- children: P
4890
+ children: R
4728
4891
  },
4729
- P
4892
+ R
4730
4893
  );
4731
4894
  })
4732
4895
  ] })
@@ -4734,7 +4897,7 @@ function yi({
4734
4897
  }
4735
4898
  function Ur(e, t, n = 260) {
4736
4899
  const [r, o] = I("down");
4737
- return $(() => {
4900
+ return z(() => {
4738
4901
  if (!t || !e.current) {
4739
4902
  o("down");
4740
4903
  return;
@@ -4767,8 +4930,8 @@ function Ql({
4767
4930
  weekStartsOnMonday: u,
4768
4931
  className: p
4769
4932
  }) {
4770
- const b = e !== void 0, [w, S] = I(t), g = b ? e : w, [h, y] = I(!1), v = z(null), f = Ur(v, h, 320);
4771
- $(() => {
4933
+ const b = e !== void 0, [w, S] = I(t), g = b ? e : w, [h, y] = I(!1), v = B(null), f = Ur(v, h, 320);
4934
+ z(() => {
4772
4935
  if (!h) return;
4773
4936
  const x = (E) => {
4774
4937
  v.current && !v.current.contains(E.target) && y(!1);
@@ -4778,7 +4941,7 @@ function Ql({
4778
4941
  return document.addEventListener("mousedown", x), document.addEventListener("touchstart", x, { passive: !0 }), document.addEventListener("keydown", N), () => {
4779
4942
  document.removeEventListener("mousedown", x), document.removeEventListener("touchstart", x), document.removeEventListener("keydown", N);
4780
4943
  };
4781
- }, [h]), $(() => {
4944
+ }, [h]), z(() => {
4782
4945
  if (!(!h || !window.matchMedia("(max-width: 640px)").matches))
4783
4946
  return document.body.style.overflow = "hidden", () => {
4784
4947
  document.body.style.overflow = "";
@@ -4787,13 +4950,13 @@ function Ql({
4787
4950
  const m = (x) => {
4788
4951
  b || S(x), n == null || n(x), y(!1);
4789
4952
  };
4790
- return /* @__PURE__ */ k("div", { ref: v, className: C("vx-datepicker", p), children: [
4953
+ return /* @__PURE__ */ k("div", { ref: v, className: T("vx-datepicker", p), children: [
4791
4954
  o ? /* @__PURE__ */ a("span", { className: "vx-field-group__label", children: o }) : null,
4792
4955
  /* @__PURE__ */ k(
4793
4956
  "button",
4794
4957
  {
4795
4958
  type: "button",
4796
- className: C(
4959
+ className: T(
4797
4960
  "vx-datepicker__trigger",
4798
4961
  l && "vx-datepicker__trigger--invalid",
4799
4962
  c && "vx-datepicker__trigger--disabled"
@@ -4804,13 +4967,13 @@ function Ql({
4804
4967
  "aria-expanded": h,
4805
4968
  children: [
4806
4969
  /* @__PURE__ */ a(wi, {}),
4807
- /* @__PURE__ */ a("span", { className: C("vx-datepicker__value", !g && "vx-datepicker__value--placeholder"), children: g ? _i(g) : r })
4970
+ /* @__PURE__ */ a("span", { className: T("vx-datepicker__value", !g && "vx-datepicker__value--placeholder"), children: g ? _i(g) : r })
4808
4971
  ]
4809
4972
  }
4810
4973
  ),
4811
4974
  l ? /* @__PURE__ */ a("span", { className: "vx-field-group__error", children: l }) : null,
4812
4975
  !l && s ? /* @__PURE__ */ a("span", { className: "vx-field-group__hint", children: s }) : null,
4813
- h ? /* @__PURE__ */ a("div", { className: C("vx-datepicker__popover", f === "up" && "vx-datepicker__popover--up"), role: "dialog", "aria-label": "Date picker", children: /* @__PURE__ */ a(
4976
+ h ? /* @__PURE__ */ a("div", { className: T("vx-datepicker__popover", f === "up" && "vx-datepicker__popover--up"), role: "dialog", "aria-label": "Date picker", children: /* @__PURE__ */ a(
4814
4977
  yi,
4815
4978
  {
4816
4979
  value: g,
@@ -4823,180 +4986,6 @@ function Ql({
4823
4986
  ] });
4824
4987
  }
4825
4988
  function Jl({
4826
- options: e,
4827
- value: t,
4828
- defaultValue: n,
4829
- onChange: r,
4830
- placeholder: o = "Select...",
4831
- searchPlaceholder: s = "Search...",
4832
- label: l,
4833
- hint: i,
4834
- error: d,
4835
- disabled: c,
4836
- clearable: u = !1,
4837
- emptyText: p = "No results",
4838
- searchable: b = !0,
4839
- className: w
4840
- }) {
4841
- const S = t !== void 0, [g, h] = I(n), y = S ? t : g, [v, f] = I(!1), [m, x] = I(""), N = z(null), E = z(null), T = z(null), A = z(null), P = fn(), [R, L] = I(null), [B, D] = I(!1), W = e.find((M) => M.value === y), G = e.filter(
4842
- (M) => M.label.toLowerCase().includes(m.toLowerCase())
4843
- ), X = typeof b == "number" ? e.length > b : b;
4844
- $(() => {
4845
- if (!v) {
4846
- x("");
4847
- return;
4848
- }
4849
- if (X) {
4850
- const M = setTimeout(() => {
4851
- var H;
4852
- return (H = A.current) == null ? void 0 : H.focus();
4853
- }, 0);
4854
- return () => clearTimeout(M);
4855
- }
4856
- }, [v, X]), $(() => {
4857
- if (!v) return;
4858
- const M = (F) => {
4859
- var Z, te;
4860
- const O = (Z = N.current) == null ? void 0 : Z.contains(F.target), U = (te = T.current) == null ? void 0 : te.contains(F.target);
4861
- !O && !U && f(!1);
4862
- }, H = (F) => {
4863
- F.key === "Escape" && (F.preventDefault(), f(!1));
4864
- };
4865
- return document.addEventListener("mousedown", M), document.addEventListener("touchstart", M, { passive: !0 }), document.addEventListener("keydown", H), () => {
4866
- document.removeEventListener("mousedown", M), document.removeEventListener("touchstart", M), document.removeEventListener("keydown", H);
4867
- };
4868
- }, [v]), $(() => {
4869
- if (!(!v || !window.matchMedia("(max-width: 640px)").matches))
4870
- return document.body.style.overflow = "hidden", () => {
4871
- document.body.style.overflow = "";
4872
- };
4873
- }, [v]), mn(() => {
4874
- var U;
4875
- if (!v || !E.current || window.matchMedia("(max-width: 640px)").matches) {
4876
- L(null), D(!1);
4877
- return;
4878
- }
4879
- const M = E.current.getBoundingClientRect(), H = window.innerHeight - M.bottom, F = M.top, O = H < 280 && F > H ? "up" : "down";
4880
- D(!!((U = N.current) != null && U.closest(".vx-dialog__content"))), L(
4881
- O === "down" ? { top: M.bottom + 4, left: M.left, width: M.width, direction: O } : { bottom: window.innerHeight - M.top + 4, left: M.left, width: M.width, direction: O }
4882
- );
4883
- }, [v]), $(() => {
4884
- if (!v || !R) return;
4885
- const M = (H) => {
4886
- var F;
4887
- (F = T.current) != null && F.contains(H.target) || f(!1);
4888
- };
4889
- return window.addEventListener("scroll", M, { capture: !0, passive: !0 }), window.addEventListener("resize", M), () => {
4890
- window.removeEventListener("scroll", M, { capture: !0 }), window.removeEventListener("resize", M);
4891
- };
4892
- }, [v, R]), $(() => {
4893
- var H;
4894
- if (!B) return;
4895
- const M = (H = N.current) == null ? void 0 : H.closest(".vx-dialog__content");
4896
- if (M)
4897
- return v ? M.dataset.hasOpenPortal = "1" : delete M.dataset.hasOpenPortal, () => {
4898
- delete M.dataset.hasOpenPortal;
4899
- };
4900
- }, [v, B]);
4901
- const K = (M) => {
4902
- M.disabled || (S || h(M.value), r == null || r(M.value), f(!1));
4903
- }, Y = (M) => {
4904
- M.stopPropagation(), S || h(void 0), r == null || r(void 0);
4905
- };
4906
- return /* @__PURE__ */ k("div", { ref: N, className: C("vx-combobox", v && "vx-combobox--open", w), children: [
4907
- l ? /* @__PURE__ */ a("span", { className: "vx-field-group__label", children: l }) : null,
4908
- /* @__PURE__ */ k(
4909
- "button",
4910
- {
4911
- ref: E,
4912
- type: "button",
4913
- className: C(
4914
- "vx-combobox__trigger",
4915
- d && "vx-combobox__trigger--invalid",
4916
- c && "vx-combobox__trigger--disabled"
4917
- ),
4918
- onClick: () => !c && f((M) => !M),
4919
- disabled: c,
4920
- "aria-haspopup": "listbox",
4921
- "aria-expanded": v,
4922
- "aria-controls": P,
4923
- children: [
4924
- /* @__PURE__ */ a("span", { className: C("vx-combobox__value", !W && "vx-combobox__value--placeholder"), children: (W == null ? void 0 : W.label) ?? o }),
4925
- /* @__PURE__ */ k("span", { className: "vx-combobox__icons", children: [
4926
- u && W && /* @__PURE__ */ a(
4927
- "span",
4928
- {
4929
- className: "vx-combobox__clear",
4930
- onClick: Y,
4931
- role: "button",
4932
- "aria-label": "Clear selection",
4933
- children: /* @__PURE__ */ a(le, { size: 14 })
4934
- }
4935
- ),
4936
- /* @__PURE__ */ a(
4937
- Ee,
4938
- {
4939
- size: 14,
4940
- className: C("vx-combobox__chevron", v && "vx-combobox__chevron--open")
4941
- }
4942
- )
4943
- ] })
4944
- ]
4945
- }
4946
- ),
4947
- d ? /* @__PURE__ */ a("span", { className: "vx-field-group__error", children: d }) : null,
4948
- !d && i ? /* @__PURE__ */ a("span", { className: "vx-field-group__hint", children: i }) : null,
4949
- v && (() => {
4950
- const M = /* @__PURE__ */ k(
4951
- "div",
4952
- {
4953
- ref: T,
4954
- className: C(
4955
- "vx-combobox__dropdown",
4956
- (R == null ? void 0 : R.direction) === "up" && "vx-combobox__dropdown--up",
4957
- R && B && "vx-combobox__dropdown--in-dialog"
4958
- ),
4959
- style: R ? { top: R.top, bottom: R.bottom, left: R.left, width: R.width } : void 0,
4960
- children: [
4961
- X && /* @__PURE__ */ a("div", { className: "vx-combobox__search-wrap", children: /* @__PURE__ */ a(
4962
- "input",
4963
- {
4964
- ref: A,
4965
- type: "text",
4966
- className: "vx-combobox__search",
4967
- placeholder: s,
4968
- value: m,
4969
- onChange: (H) => x(H.target.value),
4970
- "aria-label": s
4971
- }
4972
- ) }),
4973
- /* @__PURE__ */ a("ul", { id: P, className: "vx-combobox__list", role: "listbox", "aria-label": l ?? "Options", children: G.length === 0 ? /* @__PURE__ */ a("li", { className: "vx-combobox__empty", children: p }) : G.map((H) => /* @__PURE__ */ k(
4974
- "li",
4975
- {
4976
- className: C(
4977
- "vx-combobox__option",
4978
- H.value === y && "vx-combobox__option--selected",
4979
- H.disabled && "vx-combobox__option--disabled"
4980
- ),
4981
- role: "option",
4982
- "aria-selected": H.value === y,
4983
- "aria-disabled": H.disabled,
4984
- onClick: () => K(H),
4985
- children: [
4986
- /* @__PURE__ */ a("span", { children: H.label }),
4987
- H.value === y ? /* @__PURE__ */ a(Ke, { size: 14 }) : null
4988
- ]
4989
- },
4990
- H.value
4991
- )) })
4992
- ]
4993
- }
4994
- );
4995
- return R ? yt(M, document.body) : M;
4996
- })()
4997
- ] });
4998
- }
4999
- function ec({
5000
4989
  options: e,
5001
4990
  value: t,
5002
4991
  defaultValue: n = [],
@@ -5012,10 +5001,10 @@ function ec({
5012
5001
  maxDisplay: b,
5013
5002
  className: w
5014
5003
  }) {
5015
- const S = t !== void 0, [g, h] = I(n), y = S ? t : g, [v, f] = I(!1), [m, x] = I(""), N = z(null), E = z(null), T = z(null), A = z(null), P = fn(), [R, L] = I(null), [B, D] = I(!1), W = e.filter(
5004
+ const S = t !== void 0, [g, h] = I(n), y = S ? t : g, [v, f] = I(!1), [m, x] = I(""), N = B(null), E = B(null), C = B(null), A = B(null), R = fn(), [P, L] = I(null), [$, D] = I(!1), U = e.filter(
5016
5005
  (F) => F.label.toLowerCase().includes(m.toLowerCase())
5017
5006
  );
5018
- $(() => {
5007
+ z(() => {
5019
5008
  if (!v) {
5020
5009
  x("");
5021
5010
  return;
@@ -5025,70 +5014,62 @@ function ec({
5025
5014
  return (O = A.current) == null ? void 0 : O.focus();
5026
5015
  }, 0);
5027
5016
  return () => clearTimeout(F);
5028
- }, [v]), $(() => {
5017
+ }, [v]), z(() => {
5029
5018
  if (!v) return;
5030
- const F = (U) => {
5019
+ const F = (W) => {
5031
5020
  var de, fe;
5032
- const Z = (de = N.current) == null ? void 0 : de.contains(U.target), te = (fe = T.current) == null ? void 0 : fe.contains(U.target);
5033
- !Z && !te && f(!1);
5034
- }, O = (U) => {
5035
- U.key === "Escape" && (U.preventDefault(), f(!1));
5021
+ const K = (de = N.current) == null ? void 0 : de.contains(W.target), Q = (fe = C.current) == null ? void 0 : fe.contains(W.target);
5022
+ !K && !Q && f(!1);
5023
+ }, O = (W) => {
5024
+ W.key === "Escape" && (W.preventDefault(), f(!1));
5036
5025
  };
5037
5026
  return document.addEventListener("mousedown", F), document.addEventListener("touchstart", F, { passive: !0 }), document.addEventListener("keydown", O), () => {
5038
5027
  document.removeEventListener("mousedown", F), document.removeEventListener("touchstart", F), document.removeEventListener("keydown", O);
5039
5028
  };
5040
- }, [v]), $(() => {
5029
+ }, [v]), z(() => {
5041
5030
  if (!(!v || !window.matchMedia("(max-width: 640px)").matches))
5042
5031
  return document.body.style.overflow = "hidden", () => {
5043
5032
  document.body.style.overflow = "";
5044
5033
  };
5045
5034
  }, [v]), mn(() => {
5046
- var te;
5035
+ var Q;
5047
5036
  if (!v || !E.current || window.matchMedia("(max-width: 640px)").matches) {
5048
5037
  L(null), D(!1);
5049
5038
  return;
5050
5039
  }
5051
- const F = E.current.getBoundingClientRect(), O = window.innerHeight - F.bottom, U = F.top, Z = O < 300 && U > O ? "up" : "down";
5052
- D(!!((te = N.current) != null && te.closest(".vx-dialog__content"))), L(
5053
- Z === "down" ? { top: F.bottom + 4, left: F.left, width: F.width, direction: Z } : { bottom: window.innerHeight - F.top + 4, left: F.left, width: F.width, direction: Z }
5040
+ const F = E.current.getBoundingClientRect(), O = window.innerHeight - F.bottom, W = F.top, K = O < 300 && W > O ? "up" : "down";
5041
+ D(!!((Q = N.current) != null && Q.closest(".vx-dialog__content"))), L(
5042
+ K === "down" ? { top: F.bottom + 4, left: F.left, width: F.width, direction: K } : { bottom: window.innerHeight - F.top + 4, left: F.left, width: F.width, direction: K }
5054
5043
  );
5055
- }, [v]), $(() => {
5056
- if (!v || !R) return;
5044
+ }, [v]), z(() => {
5045
+ if (!v || !P || $) return;
5057
5046
  const F = (O) => {
5058
- var U;
5059
- (U = T.current) != null && U.contains(O.target) || f(!1);
5047
+ var W;
5048
+ (W = C.current) != null && W.contains(O.target) || f(!1);
5060
5049
  };
5061
5050
  return window.addEventListener("scroll", F, { capture: !0, passive: !0 }), window.addEventListener("resize", F), () => {
5062
5051
  window.removeEventListener("scroll", F, { capture: !0 }), window.removeEventListener("resize", F);
5063
5052
  };
5064
- }, [v, R]), $(() => {
5065
- var O;
5066
- if (!B) return;
5067
- const F = (O = N.current) == null ? void 0 : O.closest(".vx-dialog__content");
5068
- if (F)
5069
- return v ? F.dataset.hasOpenPortal = "1" : delete F.dataset.hasOpenPortal, () => {
5070
- delete F.dataset.hasOpenPortal;
5071
- };
5072
- }, [v, B]);
5073
- const G = (F) => {
5053
+ }, [v, P, $]);
5054
+ const H = (F) => {
5074
5055
  if (F.disabled) return;
5075
- const O = y.includes(F.value) ? y.filter((U) => U !== F.value) : [...y, F.value];
5056
+ const O = y.includes(F.value) ? y.filter((W) => W !== F.value) : [...y, F.value];
5076
5057
  S || h(O), r == null || r(O);
5077
- }, X = (F, O) => {
5058
+ }, Z = (F, O) => {
5078
5059
  F.stopPropagation();
5079
- const U = y.filter((Z) => Z !== O);
5080
- S || h(U), r == null || r(U);
5081
- }, K = (F) => {
5060
+ const W = y.filter((K) => K !== O);
5061
+ S || h(W), r == null || r(W);
5062
+ }, j = (F) => {
5082
5063
  F.stopPropagation(), S || h([]), r == null || r([]);
5083
- }, Y = b ? y.slice(0, b) : y, M = b ? Math.max(0, y.length - b) : 0, H = e.reduce((F, O) => (F[O.value] = O.label, F), {});
5084
- return /* @__PURE__ */ k("div", { ref: N, className: C("vx-multiselect", v && "vx-multiselect--open", w), children: [
5064
+ }, X = b ? y.slice(0, b) : y, M = b ? Math.max(0, y.length - b) : 0, q = e.reduce((F, O) => (F[O.value] = O.label, F), {});
5065
+ return /* @__PURE__ */ k("div", { ref: N, className: T("vx-multiselect", v && "vx-multiselect--open", w), children: [
5085
5066
  l ? /* @__PURE__ */ a("span", { className: "vx-field-group__label", children: l }) : null,
5086
5067
  /* @__PURE__ */ k(
5087
5068
  "button",
5088
5069
  {
5089
5070
  ref: E,
5090
5071
  type: "button",
5091
- className: C(
5072
+ className: T(
5092
5073
  "vx-multiselect__trigger",
5093
5074
  d && "vx-multiselect__trigger--invalid",
5094
5075
  c && "vx-multiselect__trigger--disabled"
@@ -5097,18 +5078,18 @@ function ec({
5097
5078
  disabled: c,
5098
5079
  "aria-haspopup": "listbox",
5099
5080
  "aria-expanded": v,
5100
- "aria-controls": P,
5081
+ "aria-controls": R,
5101
5082
  children: [
5102
- /* @__PURE__ */ a("span", { className: "vx-multiselect__tags", children: y.length === 0 ? /* @__PURE__ */ a("span", { className: "vx-multiselect__placeholder", children: o }) : /* @__PURE__ */ k(J, { children: [
5103
- Y.map((F) => /* @__PURE__ */ k("span", { className: "vx-multiselect__tag", children: [
5104
- H[F] ?? F,
5083
+ /* @__PURE__ */ a("span", { className: "vx-multiselect__tags", children: y.length === 0 ? /* @__PURE__ */ a("span", { className: "vx-multiselect__placeholder", children: o }) : /* @__PURE__ */ k(ee, { children: [
5084
+ X.map((F) => /* @__PURE__ */ k("span", { className: "vx-multiselect__tag", children: [
5085
+ q[F] ?? F,
5105
5086
  !c && /* @__PURE__ */ a(
5106
5087
  "span",
5107
5088
  {
5108
5089
  className: "vx-multiselect__tag-remove",
5109
5090
  role: "button",
5110
- "aria-label": `Remove ${H[F] ?? F}`,
5111
- onClick: (O) => X(O, F),
5091
+ "aria-label": `Remove ${q[F] ?? F}`,
5092
+ onClick: (O) => Z(O, F),
5112
5093
  children: /* @__PURE__ */ a(le, { size: 11 })
5113
5094
  }
5114
5095
  )
@@ -5125,7 +5106,7 @@ function ec({
5125
5106
  className: "vx-multiselect__clear",
5126
5107
  role: "button",
5127
5108
  "aria-label": "Clear all",
5128
- onClick: K,
5109
+ onClick: j,
5129
5110
  children: /* @__PURE__ */ a(le, { size: 14 })
5130
5111
  }
5131
5112
  ),
@@ -5133,7 +5114,7 @@ function ec({
5133
5114
  Ee,
5134
5115
  {
5135
5116
  size: 14,
5136
- className: C("vx-multiselect__chevron", v && "vx-multiselect__chevron--open")
5117
+ className: T("vx-multiselect__chevron", v && "vx-multiselect__chevron--open")
5137
5118
  }
5138
5119
  )
5139
5120
  ] })
@@ -5143,16 +5124,22 @@ function ec({
5143
5124
  d ? /* @__PURE__ */ a("span", { className: "vx-field-group__error", children: d }) : null,
5144
5125
  !d && i ? /* @__PURE__ */ a("span", { className: "vx-field-group__hint", children: i }) : null,
5145
5126
  v && (() => {
5146
- const F = /* @__PURE__ */ k(
5127
+ const F = !!(P && !$), O = F ? { top: P.top, bottom: P.bottom, left: P.left, width: P.width } : P && $ ? {
5128
+ position: "absolute",
5129
+ left: 0,
5130
+ width: "100%",
5131
+ top: P.direction === "down" ? "calc(100% + 4px)" : void 0,
5132
+ bottom: P.direction === "up" ? "calc(100% + 4px)" : void 0
5133
+ } : void 0, W = /* @__PURE__ */ k(
5147
5134
  "div",
5148
5135
  {
5149
- ref: T,
5150
- className: C(
5136
+ ref: C,
5137
+ className: T(
5151
5138
  "vx-multiselect__dropdown",
5152
- (R == null ? void 0 : R.direction) === "up" && "vx-multiselect__dropdown--up",
5153
- R && B && "vx-multiselect__dropdown--in-dialog"
5139
+ (P == null ? void 0 : P.direction) === "up" && "vx-multiselect__dropdown--up",
5140
+ P && $ && "vx-multiselect__dropdown--in-dialog"
5154
5141
  ),
5155
- style: R ? { top: R.top, bottom: R.bottom, left: R.left, width: R.width } : void 0,
5142
+ style: O,
5156
5143
  children: [
5157
5144
  /* @__PURE__ */ a("div", { className: "vx-multiselect__search-wrap", children: /* @__PURE__ */ a(
5158
5145
  "input",
@@ -5162,36 +5149,36 @@ function ec({
5162
5149
  className: "vx-multiselect__search",
5163
5150
  placeholder: s,
5164
5151
  value: m,
5165
- onChange: (O) => x(O.target.value),
5152
+ onChange: (K) => x(K.target.value),
5166
5153
  "aria-label": s
5167
5154
  }
5168
5155
  ) }),
5169
- /* @__PURE__ */ a("ul", { id: P, className: "vx-multiselect__list", role: "listbox", "aria-multiselectable": "true", "aria-label": l ?? "Options", children: W.length === 0 ? /* @__PURE__ */ a("li", { className: "vx-multiselect__empty", children: p }) : W.map((O) => {
5170
- const U = y.includes(O.value);
5156
+ /* @__PURE__ */ a("ul", { id: R, className: "vx-multiselect__list", role: "listbox", "aria-multiselectable": "true", "aria-label": l ?? "Options", children: U.length === 0 ? /* @__PURE__ */ a("li", { className: "vx-multiselect__empty", children: p }) : U.map((K) => {
5157
+ const Q = y.includes(K.value);
5171
5158
  return /* @__PURE__ */ k(
5172
5159
  "li",
5173
5160
  {
5174
- className: C(
5161
+ className: T(
5175
5162
  "vx-multiselect__option",
5176
- U && "vx-multiselect__option--selected",
5177
- O.disabled && "vx-multiselect__option--disabled"
5163
+ Q && "vx-multiselect__option--selected",
5164
+ K.disabled && "vx-multiselect__option--disabled"
5178
5165
  ),
5179
5166
  role: "option",
5180
- "aria-selected": U,
5181
- "aria-disabled": O.disabled,
5182
- onClick: () => G(O),
5167
+ "aria-selected": Q,
5168
+ "aria-disabled": K.disabled,
5169
+ onClick: () => H(K),
5183
5170
  children: [
5184
- /* @__PURE__ */ a("span", { className: C("vx-multiselect__checkbox", U && "vx-multiselect__checkbox--checked"), children: U ? /* @__PURE__ */ a(Ke, { size: 11 }) : null }),
5185
- /* @__PURE__ */ a("span", { children: O.label })
5171
+ /* @__PURE__ */ a("span", { className: T("vx-multiselect__checkbox", Q && "vx-multiselect__checkbox--checked"), children: Q ? /* @__PURE__ */ a(Ke, { size: 11 }) : null }),
5172
+ /* @__PURE__ */ a("span", { children: K.label })
5186
5173
  ]
5187
5174
  },
5188
- O.value
5175
+ K.value
5189
5176
  );
5190
5177
  }) })
5191
5178
  ]
5192
5179
  }
5193
5180
  );
5194
- return R ? yt(F, document.body) : F;
5181
+ return F ? yt(W, document.body) : W;
5195
5182
  })()
5196
5183
  ] });
5197
5184
  }
@@ -5268,7 +5255,7 @@ function ct({ value: e, min: t, max: n, onChange: r, label: o }) {
5268
5255
  }
5269
5256
  );
5270
5257
  }
5271
- function tc({
5258
+ function ec({
5272
5259
  value: e,
5273
5260
  defaultValue: t,
5274
5261
  onChange: n,
@@ -5280,48 +5267,48 @@ function tc({
5280
5267
  seconds: d = !1,
5281
5268
  className: c
5282
5269
  }) {
5283
- const u = e !== void 0, [p, b] = I(t), w = u ? e : p, S = w ? an(w) : { h: 12, m: 0, s: 0 }, [g, h] = I(S.h), [y, v] = I(S.m), [f, m] = I(S.s), [x, N] = I(!1), E = z(null), T = Ur(E, x, 220);
5284
- $(() => {
5270
+ const u = e !== void 0, [p, b] = I(t), w = u ? e : p, S = w ? an(w) : { h: 12, m: 0, s: 0 }, [g, h] = I(S.h), [y, v] = I(S.m), [f, m] = I(S.s), [x, N] = I(!1), E = B(null), C = Ur(E, x, 220);
5271
+ z(() => {
5285
5272
  if (e) {
5286
5273
  const D = an(e);
5287
5274
  h(D.h), v(D.m), m(D.s);
5288
5275
  }
5289
- }, [e]), $(() => {
5276
+ }, [e]), z(() => {
5290
5277
  if (!x) return;
5291
- const D = (G) => {
5292
- E.current && !E.current.contains(G.target) && N(!1);
5293
- }, W = (G) => {
5294
- G.key === "Escape" && (G.preventDefault(), N(!1));
5278
+ const D = (H) => {
5279
+ E.current && !E.current.contains(H.target) && N(!1);
5280
+ }, U = (H) => {
5281
+ H.key === "Escape" && (H.preventDefault(), N(!1));
5295
5282
  };
5296
- return document.addEventListener("mousedown", D), document.addEventListener("touchstart", D, { passive: !0 }), document.addEventListener("keydown", W), () => {
5297
- document.removeEventListener("mousedown", D), document.removeEventListener("touchstart", D), document.removeEventListener("keydown", W);
5283
+ return document.addEventListener("mousedown", D), document.addEventListener("touchstart", D, { passive: !0 }), document.addEventListener("keydown", U), () => {
5284
+ document.removeEventListener("mousedown", D), document.removeEventListener("touchstart", D), document.removeEventListener("keydown", U);
5298
5285
  };
5299
- }, [x]), $(() => {
5286
+ }, [x]), z(() => {
5300
5287
  if (!(!x || !window.matchMedia("(max-width: 640px)").matches))
5301
5288
  return document.body.style.overflow = "hidden", () => {
5302
5289
  document.body.style.overflow = "";
5303
5290
  };
5304
5291
  }, [x]);
5305
- const A = q(
5306
- (D, W, G) => {
5307
- const X = on(D, W, G, d);
5308
- u || b(X), n == null || n(X);
5292
+ const A = Y(
5293
+ (D, U, H) => {
5294
+ const Z = on(D, U, H, d);
5295
+ u || b(Z), n == null || n(Z);
5309
5296
  },
5310
5297
  [u, d, n]
5311
- ), P = (D) => {
5298
+ ), R = (D) => {
5312
5299
  h(D), A(D, y, f);
5313
- }, R = (D) => {
5300
+ }, P = (D) => {
5314
5301
  v(D), A(g, D, f);
5315
5302
  }, L = (D) => {
5316
5303
  m(D), A(g, y, D);
5317
- }, B = w ?? (x ? on(g, y, f, d) : void 0);
5318
- return /* @__PURE__ */ k("div", { ref: E, className: C("vx-timepicker", c), children: [
5304
+ }, $ = w ?? (x ? on(g, y, f, d) : void 0);
5305
+ return /* @__PURE__ */ k("div", { ref: E, className: T("vx-timepicker", c), children: [
5319
5306
  o ? /* @__PURE__ */ a("span", { className: "vx-field-group__label", children: o }) : null,
5320
5307
  /* @__PURE__ */ k(
5321
5308
  "button",
5322
5309
  {
5323
5310
  type: "button",
5324
- className: C(
5311
+ className: T(
5325
5312
  "vx-timepicker__trigger",
5326
5313
  l && "vx-timepicker__trigger--invalid",
5327
5314
  i && "vx-timepicker__trigger--disabled"
@@ -5332,18 +5319,18 @@ function tc({
5332
5319
  "aria-expanded": x,
5333
5320
  children: [
5334
5321
  /* @__PURE__ */ a(ki, {}),
5335
- /* @__PURE__ */ a("span", { className: C("vx-timepicker__value", !B && "vx-timepicker__value--placeholder"), children: B ?? r })
5322
+ /* @__PURE__ */ a("span", { className: T("vx-timepicker__value", !$ && "vx-timepicker__value--placeholder"), children: $ ?? r })
5336
5323
  ]
5337
5324
  }
5338
5325
  ),
5339
5326
  l ? /* @__PURE__ */ a("span", { className: "vx-field-group__error", children: l }) : null,
5340
5327
  !l && s ? /* @__PURE__ */ a("span", { className: "vx-field-group__hint", children: s }) : null,
5341
- x && /* @__PURE__ */ k("div", { className: C("vx-timepicker__popover", T === "up" && "vx-timepicker__popover--up"), role: "dialog", "aria-label": "Time picker", children: [
5328
+ x && /* @__PURE__ */ k("div", { className: T("vx-timepicker__popover", C === "up" && "vx-timepicker__popover--up"), role: "dialog", "aria-label": "Time picker", children: [
5342
5329
  /* @__PURE__ */ k("div", { className: "vx-timepicker__columns", children: [
5343
- /* @__PURE__ */ a(ct, { value: g, min: 0, max: 23, onChange: P, label: "Hours" }),
5330
+ /* @__PURE__ */ a(ct, { value: g, min: 0, max: 23, onChange: R, label: "Hours" }),
5344
5331
  /* @__PURE__ */ a("span", { className: "vx-timepicker__sep", children: ":" }),
5345
- /* @__PURE__ */ a(ct, { value: y, min: 0, max: 59, onChange: R, label: "Minutes" }),
5346
- d && /* @__PURE__ */ k(J, { children: [
5332
+ /* @__PURE__ */ a(ct, { value: y, min: 0, max: 59, onChange: P, label: "Minutes" }),
5333
+ d && /* @__PURE__ */ k(ee, { children: [
5347
5334
  /* @__PURE__ */ a("span", { className: "vx-timepicker__sep", children: ":" }),
5348
5335
  /* @__PURE__ */ a(ct, { value: f, min: 0, max: 59, onChange: L, label: "Seconds" })
5349
5336
  ] })
@@ -5353,14 +5340,16 @@ function tc({
5353
5340
  {
5354
5341
  type: "button",
5355
5342
  className: "vx-timepicker__done",
5356
- onClick: () => N(!1),
5343
+ onClick: () => {
5344
+ w || A(g, y, f), N(!1);
5345
+ },
5357
5346
  children: "Done"
5358
5347
  }
5359
5348
  ) })
5360
5349
  ] })
5361
5350
  ] });
5362
5351
  }
5363
- function nc({
5352
+ function tc({
5364
5353
  label: e,
5365
5354
  hint: t,
5366
5355
  error: n,
@@ -5371,11 +5360,11 @@ function nc({
5371
5360
  onFiles: i,
5372
5361
  className: d
5373
5362
  }) {
5374
- const [c, u] = I(!1), [p, b] = I([]), [w, S] = I(), g = z(null), h = q(
5363
+ const [c, u] = I(!1), [p, b] = I([]), [w, S] = I(), g = B(null), h = Y(
5375
5364
  (x) => {
5376
5365
  if (!x) return;
5377
5366
  const N = Array.from(x);
5378
- if (s && N.filter((P) => P.size > s).length > 0) {
5367
+ if (s && N.filter((R) => R.size > s).length > 0) {
5379
5368
  S(`File too large (max ${(s / 1024 / 1024).toFixed(1)} MB)`);
5380
5369
  return;
5381
5370
  }
@@ -5383,8 +5372,8 @@ function nc({
5383
5372
  const E = N.map((A) => ({
5384
5373
  file: A,
5385
5374
  id: crypto.randomUUID()
5386
- })), T = o ? [...p, ...E] : E;
5387
- b(T), i == null || i(T.map((A) => A.file));
5375
+ })), C = o ? [...p, ...E] : E;
5376
+ b(C), i == null || i(C.map((A) => A.file));
5388
5377
  },
5389
5378
  [p, s, o, i]
5390
5379
  ), y = (x) => {
@@ -5395,12 +5384,12 @@ function nc({
5395
5384
  const N = p.filter((E) => E.id !== x);
5396
5385
  b(N), i == null || i(N.map((E) => E.file));
5397
5386
  }, m = n ?? w;
5398
- return /* @__PURE__ */ k("div", { className: C("vx-file-upload", d), children: [
5387
+ return /* @__PURE__ */ k("div", { className: T("vx-file-upload", d), children: [
5399
5388
  e ? /* @__PURE__ */ a("span", { className: "vx-field-group__label", children: e }) : null,
5400
5389
  /* @__PURE__ */ k(
5401
5390
  "div",
5402
5391
  {
5403
- className: C(
5392
+ className: T(
5404
5393
  "vx-file-upload__zone",
5405
5394
  c && "vx-file-upload__zone--dragging",
5406
5395
  l && "vx-file-upload__zone--disabled",
@@ -5465,7 +5454,7 @@ function nc({
5465
5454
  ] }, x)) })
5466
5455
  ] });
5467
5456
  }
5468
- function rc({
5457
+ function nc({
5469
5458
  trigger: e,
5470
5459
  title: t,
5471
5460
  description: n,
@@ -5476,10 +5465,10 @@ function rc({
5476
5465
  ...i
5477
5466
  }) {
5478
5467
  return /* @__PURE__ */ k(Et, { ...i, children: [
5479
- e ? /* @__PURE__ */ a(Ct, { asChild: !0, children: e }) : null,
5480
- /* @__PURE__ */ k(Tt, { children: [
5468
+ e ? /* @__PURE__ */ a(Tt, { asChild: !0, children: e }) : null,
5469
+ /* @__PURE__ */ k(Ct, { children: [
5481
5470
  /* @__PURE__ */ a(At, { className: "vx-sheet__overlay" }),
5482
- /* @__PURE__ */ k(Pt, { className: C("vx-sheet", `vx-sheet--${r}`, l), children: [
5471
+ /* @__PURE__ */ k(Pt, { className: T("vx-sheet", `vx-sheet--${r}`, l), children: [
5483
5472
  /* @__PURE__ */ k("div", { className: "vx-sheet__header", children: [
5484
5473
  /* @__PURE__ */ k("div", { children: [
5485
5474
  t ? /* @__PURE__ */ a(Rt, { className: "vx-sheet__title", children: t }) : null,
@@ -5493,7 +5482,7 @@ function rc({
5493
5482
  ] })
5494
5483
  ] });
5495
5484
  }
5496
- function ac({
5485
+ function rc({
5497
5486
  maxHeight: e,
5498
5487
  maxWidth: t,
5499
5488
  children: n,
@@ -5504,7 +5493,7 @@ function ac({
5504
5493
  return /* @__PURE__ */ a(
5505
5494
  "div",
5506
5495
  {
5507
- className: C("vx-scroll-area", r),
5496
+ className: T("vx-scroll-area", r),
5508
5497
  style: {
5509
5498
  maxHeight: typeof e == "number" ? `${e}px` : e,
5510
5499
  maxWidth: typeof t == "number" ? `${t}px` : t,
@@ -5515,7 +5504,7 @@ function ac({
5515
5504
  }
5516
5505
  );
5517
5506
  }
5518
- function oc({
5507
+ function ac({
5519
5508
  pressed: e,
5520
5509
  defaultPressed: t = !1,
5521
5510
  onPressedChange: n,
@@ -5533,14 +5522,14 @@ function oc({
5533
5522
  {
5534
5523
  type: "button",
5535
5524
  "aria-pressed": p,
5536
- className: C("vx-toggle", `vx-toggle--${r}`, p && "vx-toggle--on", o),
5525
+ className: T("vx-toggle", `vx-toggle--${r}`, p && "vx-toggle--on", o),
5537
5526
  onClick: b,
5538
5527
  ...i,
5539
5528
  children: s
5540
5529
  }
5541
5530
  );
5542
5531
  }
5543
- function sc({
5532
+ function oc({
5544
5533
  items: e,
5545
5534
  value: t,
5546
5535
  defaultValue: n,
@@ -5560,13 +5549,13 @@ function sc({
5560
5549
  S = u === w ? "" : w;
5561
5550
  c || d(S), r == null || r(S);
5562
5551
  };
5563
- return /* @__PURE__ */ a("div", { className: C("vx-toggle-group", l), role: "group", children: e.map((w) => /* @__PURE__ */ a(
5552
+ return /* @__PURE__ */ a("div", { className: T("vx-toggle-group", l), role: "group", children: e.map((w) => /* @__PURE__ */ a(
5564
5553
  "button",
5565
5554
  {
5566
5555
  type: "button",
5567
5556
  "aria-pressed": p(w.value),
5568
5557
  disabled: w.disabled,
5569
- className: C(
5558
+ className: T(
5570
5559
  "vx-toggle",
5571
5560
  `vx-toggle--${s}`,
5572
5561
  p(w.value) && "vx-toggle--on",
@@ -5578,9 +5567,9 @@ function sc({
5578
5567
  w.value
5579
5568
  )) });
5580
5569
  }
5581
- function ic({ groups: e, items: t, children: n, className: r }) {
5582
- const [o, s] = I(null), l = z(null), i = e ?? (t ? [{ items: t }] : []);
5583
- $(() => {
5570
+ function sc({ groups: e, items: t, children: n, className: r }) {
5571
+ const [o, s] = I(null), l = B(null), i = e ?? (t ? [{ items: t }] : []);
5572
+ z(() => {
5584
5573
  if (!o) return;
5585
5574
  const c = (p) => {
5586
5575
  l.current && !l.current.contains(p.target) && s(null);
@@ -5591,10 +5580,10 @@ function ic({ groups: e, items: t, children: n, className: r }) {
5591
5580
  document.removeEventListener("mousedown", c), document.removeEventListener("keydown", u);
5592
5581
  };
5593
5582
  }, [o]);
5594
- const d = q((c) => {
5583
+ const d = Y((c) => {
5595
5584
  c.preventDefault(), s({ x: c.clientX, y: c.clientY });
5596
5585
  }, []);
5597
- return /* @__PURE__ */ k("div", { className: C("vx-context-menu-wrap", r), onContextMenu: d, children: [
5586
+ return /* @__PURE__ */ k("div", { className: T("vx-context-menu-wrap", r), onContextMenu: d, children: [
5598
5587
  n,
5599
5588
  o && /* @__PURE__ */ a(
5600
5589
  "div",
@@ -5612,7 +5601,7 @@ function ic({ groups: e, items: t, children: n, className: r }) {
5612
5601
  type: "button",
5613
5602
  role: "menuitem",
5614
5603
  disabled: p.disabled,
5615
- className: C(
5604
+ className: T(
5616
5605
  "vx-dropdown__item",
5617
5606
  p.danger && "vx-dropdown__item--danger",
5618
5607
  p.disabled && "vx-dropdown__item--disabled"
@@ -5634,36 +5623,36 @@ function ic({ groups: e, items: t, children: n, className: r }) {
5634
5623
  )
5635
5624
  ] });
5636
5625
  }
5637
- function lc({
5626
+ function ic({
5638
5627
  content: e,
5639
5628
  placement: t = "bottom",
5640
5629
  delay: n = 400,
5641
5630
  children: r,
5642
5631
  className: o
5643
5632
  }) {
5644
- const [s, l] = I(!1), i = z(null), d = q(() => {
5633
+ const [s, l] = I(!1), i = B(null), d = Y(() => {
5645
5634
  i.current = setTimeout(() => l(!0), n);
5646
- }, [n]), c = q(() => {
5635
+ }, [n]), c = Y(() => {
5647
5636
  i.current && clearTimeout(i.current), l(!1);
5648
5637
  }, []);
5649
5638
  return /* @__PURE__ */ k(
5650
5639
  "span",
5651
5640
  {
5652
- className: C("vx-hovercard-wrap", o),
5641
+ className: T("vx-hovercard-wrap", o),
5653
5642
  onMouseEnter: d,
5654
5643
  onMouseLeave: c,
5655
5644
  onFocus: d,
5656
5645
  onBlur: c,
5657
5646
  children: [
5658
5647
  r,
5659
- s && /* @__PURE__ */ a("div", { className: C("vx-hovercard", `vx-hovercard--${t}`), children: e })
5648
+ s && /* @__PURE__ */ a("div", { className: T("vx-hovercard", `vx-hovercard--${t}`), children: e })
5660
5649
  ]
5661
5650
  }
5662
5651
  );
5663
5652
  }
5664
- function cc({ menus: e, className: t }) {
5665
- const [n, r] = I(null), o = z(null);
5666
- return $(() => {
5653
+ function lc({ menus: e, className: t }) {
5654
+ const [n, r] = I(null), o = B(null);
5655
+ return z(() => {
5667
5656
  if (n === null) return;
5668
5657
  const s = (i) => {
5669
5658
  o.current && !o.current.contains(i.target) && r(null);
@@ -5673,7 +5662,7 @@ function cc({ menus: e, className: t }) {
5673
5662
  return document.addEventListener("mousedown", s), document.addEventListener("keydown", l), () => {
5674
5663
  document.removeEventListener("mousedown", s), document.removeEventListener("keydown", l);
5675
5664
  };
5676
- }, [n]), /* @__PURE__ */ a("div", { ref: o, className: C("vx-menubar", t), role: "menubar", children: e.map((s, l) => {
5665
+ }, [n]), /* @__PURE__ */ a("div", { ref: o, className: T("vx-menubar", t), role: "menubar", children: e.map((s, l) => {
5677
5666
  const i = s.groups ?? (s.items ? [{ items: s.items }] : []), d = n === l;
5678
5667
  return /* @__PURE__ */ k("div", { className: "vx-menubar__item-wrap", children: [
5679
5668
  /* @__PURE__ */ a(
@@ -5681,7 +5670,7 @@ function cc({ menus: e, className: t }) {
5681
5670
  {
5682
5671
  type: "button",
5683
5672
  role: "menuitem",
5684
- className: C("vx-menubar__trigger", d && "vx-menubar__trigger--open"),
5673
+ className: T("vx-menubar__trigger", d && "vx-menubar__trigger--open"),
5685
5674
  disabled: s.disabled,
5686
5675
  "aria-haspopup": "menu",
5687
5676
  "aria-expanded": d,
@@ -5701,7 +5690,7 @@ function cc({ menus: e, className: t }) {
5701
5690
  type: "button",
5702
5691
  role: "menuitem",
5703
5692
  disabled: p.disabled,
5704
- className: C(
5693
+ className: T(
5705
5694
  "vx-dropdown__item",
5706
5695
  p.danger && "vx-dropdown__item--danger",
5707
5696
  p.disabled && "vx-dropdown__item--disabled"
@@ -5722,9 +5711,9 @@ function cc({ menus: e, className: t }) {
5722
5711
  ] }, l);
5723
5712
  }) });
5724
5713
  }
5725
- function dc({ items: e, className: t }) {
5726
- const [n, r] = I(null), o = z(null);
5727
- return $(() => {
5714
+ function cc({ items: e, className: t }) {
5715
+ const [n, r] = I(null), o = B(null);
5716
+ return z(() => {
5728
5717
  if (n === null) return;
5729
5718
  const s = (i) => {
5730
5719
  o.current && !o.current.contains(i.target) && r(null);
@@ -5734,14 +5723,14 @@ function dc({ items: e, className: t }) {
5734
5723
  return document.addEventListener("mousedown", s), document.addEventListener("keydown", l), () => {
5735
5724
  document.removeEventListener("mousedown", s), document.removeEventListener("keydown", l);
5736
5725
  };
5737
- }, [n]), /* @__PURE__ */ a("nav", { ref: o, className: C("vx-nav-menu", t), "aria-label": "Main navigation", children: /* @__PURE__ */ a("ul", { className: "vx-nav-menu__list", role: "list", children: e.map((s, l) => {
5726
+ }, [n]), /* @__PURE__ */ a("nav", { ref: o, className: T("vx-nav-menu", t), "aria-label": "Main navigation", children: /* @__PURE__ */ a("ul", { className: "vx-nav-menu__list", role: "list", children: e.map((s, l) => {
5738
5727
  const i = s.items && s.items.length > 0, d = n === l;
5739
5728
  return /* @__PURE__ */ k("li", { className: "vx-nav-menu__item-wrap", children: [
5740
5729
  i ? /* @__PURE__ */ k(
5741
5730
  "button",
5742
5731
  {
5743
5732
  type: "button",
5744
- className: C(
5733
+ className: T(
5745
5734
  "vx-nav-menu__link",
5746
5735
  s.active && "vx-nav-menu__link--active",
5747
5736
  d && "vx-nav-menu__link--open"
@@ -5755,7 +5744,7 @@ function dc({ items: e, className: t }) {
5755
5744
  Ee,
5756
5745
  {
5757
5746
  size: 14,
5758
- className: C(
5747
+ className: T(
5759
5748
  "vx-nav-menu__chevron",
5760
5749
  d && "vx-nav-menu__chevron--open"
5761
5750
  )
@@ -5767,7 +5756,7 @@ function dc({ items: e, className: t }) {
5767
5756
  "a",
5768
5757
  {
5769
5758
  href: s.href ?? "#",
5770
- className: C(
5759
+ className: T(
5771
5760
  "vx-nav-menu__link",
5772
5761
  s.active && "vx-nav-menu__link--active"
5773
5762
  ),
@@ -5797,7 +5786,7 @@ function dc({ items: e, className: t }) {
5797
5786
  ] }, l);
5798
5787
  }) }) });
5799
5788
  }
5800
- function uc({
5789
+ function dc({
5801
5790
  steps: e,
5802
5791
  currentStep: t = 0,
5803
5792
  orientation: n = "horizontal",
@@ -5806,11 +5795,11 @@ function uc({
5806
5795
  return /* @__PURE__ */ a(
5807
5796
  "ol",
5808
5797
  {
5809
- className: C("vx-stepper", `vx-stepper--${n}`, r),
5798
+ className: T("vx-stepper", `vx-stepper--${n}`, r),
5810
5799
  "aria-label": "Steps",
5811
5800
  children: e.map((o, s) => {
5812
5801
  const l = o.status ?? (s < t ? "completed" : s === t ? "active" : "pending");
5813
- return /* @__PURE__ */ k("li", { className: C("vx-stepper__step", `vx-stepper__step--${l}`), children: [
5802
+ return /* @__PURE__ */ k("li", { className: T("vx-stepper__step", `vx-stepper__step--${l}`), children: [
5814
5803
  /* @__PURE__ */ a("div", { className: "vx-stepper__indicator", "aria-hidden": "true", children: l === "completed" ? /* @__PURE__ */ a(Ke, { size: 14 }) : /* @__PURE__ */ a("span", { children: s + 1 }) }),
5815
5804
  /* @__PURE__ */ k("div", { className: "vx-stepper__content", children: [
5816
5805
  /* @__PURE__ */ a("span", { className: "vx-stepper__label", children: o.label }),
@@ -5822,11 +5811,11 @@ function uc({
5822
5811
  }
5823
5812
  );
5824
5813
  }
5825
- function pc({ items: e, className: t }) {
5826
- return /* @__PURE__ */ a("ol", { className: C("vx-timeline", t), "aria-label": "Timeline", children: e.map((n, r) => /* @__PURE__ */ k(
5814
+ function uc({ items: e, className: t }) {
5815
+ return /* @__PURE__ */ a("ol", { className: T("vx-timeline", t), "aria-label": "Timeline", children: e.map((n, r) => /* @__PURE__ */ k(
5827
5816
  "li",
5828
5817
  {
5829
- className: C(
5818
+ className: T(
5830
5819
  "vx-timeline__item",
5831
5820
  n.status && `vx-timeline__item--${n.status}`
5832
5821
  ),
@@ -5844,15 +5833,15 @@ function pc({ items: e, className: t }) {
5844
5833
  r
5845
5834
  )) });
5846
5835
  }
5847
- function vc({ icon: e, title: t, description: n, action: r, className: o }) {
5848
- return /* @__PURE__ */ k("div", { className: C("vx-empty-state", o), role: "status", "aria-live": "polite", children: [
5836
+ function pc({ icon: e, title: t, description: n, action: r, className: o }) {
5837
+ return /* @__PURE__ */ k("div", { className: T("vx-empty-state", o), role: "status", "aria-live": "polite", children: [
5849
5838
  e && /* @__PURE__ */ a("div", { className: "vx-empty-state__icon", "aria-hidden": "true", children: e }),
5850
5839
  /* @__PURE__ */ a("p", { className: "vx-empty-state__title", children: t }),
5851
5840
  n && /* @__PURE__ */ a("p", { className: "vx-empty-state__description", children: n }),
5852
5841
  r && /* @__PURE__ */ a("div", { className: "vx-empty-state__action", children: r })
5853
5842
  ] });
5854
5843
  }
5855
- function fc({
5844
+ function vc({
5856
5845
  items: e,
5857
5846
  defaultIndex: t = 0,
5858
5847
  index: n,
@@ -5864,14 +5853,14 @@ function fc({
5864
5853
  showArrows: d = !0,
5865
5854
  className: c
5866
5855
  }) {
5867
- const u = n !== void 0, [p, b] = I(t), w = u ? n : p, S = e.length, g = z(null), h = q(
5856
+ const u = n !== void 0, [p, b] = I(t), w = u ? n : p, S = e.length, g = B(null), h = Y(
5868
5857
  (f) => {
5869
5858
  let m = f;
5870
5859
  l ? m = (f % S + S) % S : m = Math.max(0, Math.min(f, S - 1)), u || b(m), r == null || r(m);
5871
5860
  },
5872
5861
  [u, l, r, S]
5873
5862
  );
5874
- $(() => {
5863
+ z(() => {
5875
5864
  if (o)
5876
5865
  return g.current = setInterval(() => h(w + 1), s), () => {
5877
5866
  g.current && clearInterval(g.current);
@@ -5881,7 +5870,7 @@ function fc({
5881
5870
  return S === 0 ? null : /* @__PURE__ */ k(
5882
5871
  "div",
5883
5872
  {
5884
- className: C("vx-carousel", c),
5873
+ className: T("vx-carousel", c),
5885
5874
  role: "region",
5886
5875
  "aria-roledescription": "carousel",
5887
5876
  "aria-label": "Carousel",
@@ -5905,7 +5894,7 @@ function fc({
5905
5894
  ))
5906
5895
  }
5907
5896
  ) }),
5908
- d && /* @__PURE__ */ k(J, { children: [
5897
+ d && /* @__PURE__ */ k(ee, { children: [
5909
5898
  /* @__PURE__ */ a(
5910
5899
  "button",
5911
5900
  {
@@ -5925,7 +5914,7 @@ function fc({
5925
5914
  onClick: v,
5926
5915
  disabled: !l && w === S - 1,
5927
5916
  "aria-label": "Next slide",
5928
- children: /* @__PURE__ */ a(Ce, { size: 20 })
5917
+ children: /* @__PURE__ */ a(Te, { size: 20 })
5929
5918
  }
5930
5919
  )
5931
5920
  ] }),
@@ -5934,7 +5923,7 @@ function fc({
5934
5923
  {
5935
5924
  type: "button",
5936
5925
  role: "tab",
5937
- className: C("vx-carousel__dot", m === w && "vx-carousel__dot--active"),
5926
+ className: T("vx-carousel__dot", m === w && "vx-carousel__dot--active"),
5938
5927
  onClick: () => h(m),
5939
5928
  "aria-selected": m === w,
5940
5929
  "aria-label": `Go to slide ${m + 1}`
@@ -5946,7 +5935,7 @@ function fc({
5946
5935
  );
5947
5936
  }
5948
5937
  function Ei({ filled: e, half: t }) {
5949
- return /* @__PURE__ */ a("svg", { width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: t ? /* @__PURE__ */ k(J, { children: [
5938
+ return /* @__PURE__ */ a("svg", { width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: t ? /* @__PURE__ */ k(ee, { children: [
5950
5939
  /* @__PURE__ */ a("defs", { children: /* @__PURE__ */ k("linearGradient", { id: "vx-star-half", children: [
5951
5940
  /* @__PURE__ */ a("stop", { offset: "50%", stopColor: "currentColor" }),
5952
5941
  /* @__PURE__ */ a("stop", { offset: "50%", stopColor: "none", stopOpacity: "0" })
@@ -5972,7 +5961,7 @@ function Ei({ filled: e, half: t }) {
5972
5961
  }
5973
5962
  ) });
5974
5963
  }
5975
- function mc({
5964
+ function fc({
5976
5965
  value: e,
5977
5966
  defaultValue: t = 0,
5978
5967
  onChange: n,
@@ -5998,18 +5987,18 @@ function mc({
5998
5987
  return /* @__PURE__ */ a(
5999
5988
  "div",
6000
5989
  {
6001
- className: C("vx-rating", `vx-rating--${c}`, s && "vx-rating--disabled", d),
5990
+ className: T("vx-rating", `vx-rating--${c}`, s && "vx-rating--disabled", d),
6002
5991
  role: "group",
6003
5992
  "aria-label": i ?? "Rating",
6004
5993
  children: Array.from({ length: r }, (m, x) => {
6005
- const N = x + 1, E = h >= N, T = !E && h >= N - 0.5;
5994
+ const N = x + 1, E = h >= N, C = !E && h >= N - 0.5;
6006
5995
  return /* @__PURE__ */ a(
6007
5996
  "button",
6008
5997
  {
6009
5998
  type: "button",
6010
- className: C(
5999
+ className: T(
6011
6000
  "vx-rating__star",
6012
- (E || T) && "vx-rating__star--active"
6001
+ (E || C) && "vx-rating__star--active"
6013
6002
  ),
6014
6003
  onClick: (A) => v(N, A),
6015
6004
  onMouseMove: (A) => f(N, A),
@@ -6018,7 +6007,7 @@ function mc({
6018
6007
  "aria-label": `${N} star${N !== 1 ? "s" : ""}`,
6019
6008
  "aria-pressed": w >= N,
6020
6009
  tabIndex: l || s ? -1 : 0,
6021
- children: /* @__PURE__ */ a(Ei, { filled: E, half: T })
6010
+ children: /* @__PURE__ */ a(Ei, { filled: E, half: C })
6022
6011
  },
6023
6012
  x
6024
6013
  );
@@ -6034,7 +6023,7 @@ function Wr({ node: e, depth: t, selected: n, expanded: r, onSelect: o, onToggle
6034
6023
  /* @__PURE__ */ k(
6035
6024
  "div",
6036
6025
  {
6037
- className: C(
6026
+ className: T(
6038
6027
  "vx-tree__node",
6039
6028
  d && "vx-tree__node--selected",
6040
6029
  e.disabled && "vx-tree__node--disabled"
@@ -6048,11 +6037,11 @@ function Wr({ node: e, depth: t, selected: n, expanded: r, onSelect: o, onToggle
6048
6037
  role: "button",
6049
6038
  "aria-label": typeof e.label == "string" ? e.label : void 0,
6050
6039
  children: [
6051
- /* @__PURE__ */ a("span", { className: C("vx-tree__expand", !l && "vx-tree__expand--hidden"), children: /* @__PURE__ */ a(
6052
- Ce,
6040
+ /* @__PURE__ */ a("span", { className: T("vx-tree__expand", !l && "vx-tree__expand--hidden"), children: /* @__PURE__ */ a(
6041
+ Te,
6053
6042
  {
6054
6043
  size: 14,
6055
- className: C("vx-tree__chevron", i && "vx-tree__chevron--open")
6044
+ className: T("vx-tree__chevron", i && "vx-tree__chevron--open")
6056
6045
  }
6057
6046
  ) }),
6058
6047
  e.icon && /* @__PURE__ */ a("span", { className: "vx-tree__icon", children: e.icon }),
@@ -6074,7 +6063,7 @@ function Wr({ node: e, depth: t, selected: n, expanded: r, onSelect: o, onToggle
6074
6063
  )) })
6075
6064
  ] });
6076
6065
  }
6077
- function hc({
6066
+ function mc({
6078
6067
  nodes: e,
6079
6068
  selected: t,
6080
6069
  defaultSelected: n,
@@ -6086,12 +6075,12 @@ function hc({
6086
6075
  }) {
6087
6076
  const d = t !== void 0, [c, u] = I(n), p = d ? t : c, b = s !== void 0, [w, S] = I(
6088
6077
  new Set(o)
6089
- ), g = b ? new Set(s) : w, h = q(
6078
+ ), g = b ? new Set(s) : w, h = Y(
6090
6079
  (v, f) => {
6091
6080
  d || u(v), r == null || r(v, f);
6092
6081
  },
6093
6082
  [d, r]
6094
- ), y = q(
6083
+ ), y = Y(
6095
6084
  (v) => {
6096
6085
  const f = new Set(g);
6097
6086
  f.has(v) ? f.delete(v) : f.add(v), b || S(f), l == null || l([...f]);
@@ -6101,7 +6090,7 @@ function hc({
6101
6090
  return /* @__PURE__ */ a(
6102
6091
  "ul",
6103
6092
  {
6104
- className: C("vx-tree", i),
6093
+ className: T("vx-tree", i),
6105
6094
  role: "tree",
6106
6095
  "aria-multiselectable": "false",
6107
6096
  children: e.map((v) => /* @__PURE__ */ a(
@@ -6119,7 +6108,7 @@ function hc({
6119
6108
  }
6120
6109
  );
6121
6110
  }
6122
- function gc({
6111
+ function hc({
6123
6112
  value: e,
6124
6113
  defaultValue: t = [],
6125
6114
  onChange: n,
@@ -6134,10 +6123,10 @@ function gc({
6134
6123
  className: p,
6135
6124
  ...b
6136
6125
  }) {
6137
- const w = e !== void 0, [S, g] = I(t), h = w ? e : S, [y, v] = I(""), [f, m] = I(), x = z(null), N = (R) => {
6138
- w || g(R), n == null || n(R);
6139
- }, E = (R) => {
6140
- const L = R.trim();
6126
+ const w = e !== void 0, [S, g] = I(t), h = w ? e : S, [y, v] = I(""), [f, m] = I(), x = B(null), N = (P) => {
6127
+ w || g(P), n == null || n(P);
6128
+ }, E = (P) => {
6129
+ const L = P.trim();
6141
6130
  if (L) {
6142
6131
  if (h.includes(L)) {
6143
6132
  m("Tag already exists");
@@ -6148,49 +6137,49 @@ function gc({
6148
6137
  return;
6149
6138
  }
6150
6139
  if (c) {
6151
- const B = c(L);
6152
- if (B === !1) {
6140
+ const $ = c(L);
6141
+ if ($ === !1) {
6153
6142
  m("Invalid tag");
6154
6143
  return;
6155
6144
  }
6156
- if (typeof B == "string") {
6157
- m(B);
6145
+ if (typeof $ == "string") {
6146
+ m($);
6158
6147
  return;
6159
6148
  }
6160
6149
  }
6161
6150
  m(void 0), N([...h, L]), v("");
6162
6151
  }
6163
- }, T = (R) => {
6164
- N(h.filter((L, B) => B !== R));
6165
- }, A = (R) => {
6166
- i.includes(R.key) ? (R.preventDefault(), E(y)) : R.key === "Backspace" && !y && h.length > 0 && T(h.length - 1);
6167
- }, P = s ?? f;
6168
- return /* @__PURE__ */ k("div", { className: C("vx-tag-input", p), children: [
6152
+ }, C = (P) => {
6153
+ N(h.filter((L, $) => $ !== P));
6154
+ }, A = (P) => {
6155
+ i.includes(P.key) ? (P.preventDefault(), E(y)) : P.key === "Backspace" && !y && h.length > 0 && C(h.length - 1);
6156
+ }, R = s ?? f;
6157
+ return /* @__PURE__ */ k("div", { className: T("vx-tag-input", p), children: [
6169
6158
  r ? /* @__PURE__ */ a("span", { className: "vx-field-group__label", children: r }) : null,
6170
6159
  /* @__PURE__ */ k(
6171
6160
  "div",
6172
6161
  {
6173
- className: C(
6162
+ className: T(
6174
6163
  "vx-tag-input__wrap",
6175
- P && "vx-tag-input__wrap--invalid",
6164
+ R && "vx-tag-input__wrap--invalid",
6176
6165
  u && "vx-tag-input__wrap--disabled"
6177
6166
  ),
6178
6167
  onClick: () => {
6179
- var R;
6180
- return (R = x.current) == null ? void 0 : R.focus();
6168
+ var P;
6169
+ return (P = x.current) == null ? void 0 : P.focus();
6181
6170
  },
6182
6171
  children: [
6183
- h.map((R, L) => /* @__PURE__ */ k("span", { className: "vx-tag-input__tag", children: [
6184
- R,
6172
+ h.map((P, L) => /* @__PURE__ */ k("span", { className: "vx-tag-input__tag", children: [
6173
+ P,
6185
6174
  !u && /* @__PURE__ */ a(
6186
6175
  "button",
6187
6176
  {
6188
6177
  type: "button",
6189
6178
  className: "vx-tag-input__remove",
6190
- onClick: (B) => {
6191
- B.stopPropagation(), T(L);
6179
+ onClick: ($) => {
6180
+ $.stopPropagation(), C(L);
6192
6181
  },
6193
- "aria-label": `Remove tag ${R}`,
6182
+ "aria-label": `Remove tag ${P}`,
6194
6183
  children: /* @__PURE__ */ a(le, { size: 11 })
6195
6184
  }
6196
6185
  )
@@ -6204,8 +6193,8 @@ function gc({
6204
6193
  placeholder: h.length === 0 ? l : "",
6205
6194
  disabled: u,
6206
6195
  onKeyDown: A,
6207
- onChange: (R) => {
6208
- v(R.target.value), m(void 0);
6196
+ onChange: (P) => {
6197
+ v(P.target.value), m(void 0);
6209
6198
  },
6210
6199
  onBlur: () => {
6211
6200
  y.trim() && E(y);
@@ -6217,11 +6206,11 @@ function gc({
6217
6206
  ]
6218
6207
  }
6219
6208
  ),
6220
- P ? /* @__PURE__ */ a("span", { className: "vx-field-group__error", children: P }) : null,
6221
- !P && o ? /* @__PURE__ */ a("span", { className: "vx-field-group__hint", children: o }) : null
6209
+ R ? /* @__PURE__ */ a("span", { className: "vx-field-group__error", children: R }) : null,
6210
+ !R && o ? /* @__PURE__ */ a("span", { className: "vx-field-group__hint", children: o }) : null
6222
6211
  ] });
6223
6212
  }
6224
- function Ci(e) {
6213
+ function Ti(e) {
6225
6214
  const t = parseInt(e.slice(1, 3), 16) / 255, n = parseInt(e.slice(3, 5), 16) / 255, r = parseInt(e.slice(5, 7), 16) / 255, o = Math.max(t, n, r), s = Math.min(t, n, r), l = (o + s) / 2;
6226
6215
  let i = 0, d = 0;
6227
6216
  if (o !== s) {
@@ -6258,7 +6247,7 @@ function dt(e, t, n) {
6258
6247
  function sn(e) {
6259
6248
  return /^#[0-9a-f]{6}$/i.test(e);
6260
6249
  }
6261
- const Ti = [
6250
+ const Ci = [
6262
6251
  "#ef4444",
6263
6252
  "#f97316",
6264
6253
  "#eab308",
@@ -6272,7 +6261,7 @@ const Ti = [
6272
6261
  "#ffffff",
6273
6262
  "#f8fafc"
6274
6263
  ];
6275
- function bc({
6264
+ function gc({
6276
6265
  value: e,
6277
6266
  defaultValue: t = "#3b82f6",
6278
6267
  onChange: n,
@@ -6280,49 +6269,49 @@ function bc({
6280
6269
  hint: o,
6281
6270
  error: s,
6282
6271
  disabled: l,
6283
- presets: i = Ti,
6272
+ presets: i = Ci,
6284
6273
  showPresets: d = !0,
6285
6274
  className: c
6286
6275
  }) {
6287
- const u = e !== void 0, [p, b] = I(t), w = u ? e : p, [S, g] = I(w), [h, y] = I(!1), v = z(null);
6288
- $(() => {
6276
+ const u = e !== void 0, [p, b] = I(t), w = u ? e : p, [S, g] = I(w), [h, y] = I(!1), v = B(null);
6277
+ z(() => {
6289
6278
  if (!h) return;
6290
- const T = (P) => {
6291
- v.current && !v.current.contains(P.target) && y(!1);
6292
- }, A = (P) => {
6293
- P.key === "Escape" && (P.preventDefault(), y(!1));
6279
+ const C = (R) => {
6280
+ v.current && !v.current.contains(R.target) && y(!1);
6281
+ }, A = (R) => {
6282
+ R.key === "Escape" && (R.preventDefault(), y(!1));
6294
6283
  };
6295
- return document.addEventListener("mousedown", T), document.addEventListener("touchstart", T, { passive: !0 }), document.addEventListener("keydown", A), () => {
6296
- document.removeEventListener("mousedown", T), document.removeEventListener("touchstart", T), document.removeEventListener("keydown", A);
6284
+ return document.addEventListener("mousedown", C), document.addEventListener("touchstart", C, { passive: !0 }), document.addEventListener("keydown", A), () => {
6285
+ document.removeEventListener("mousedown", C), document.removeEventListener("touchstart", C), document.removeEventListener("keydown", A);
6297
6286
  };
6298
- }, [h]), $(() => {
6287
+ }, [h]), z(() => {
6299
6288
  if (!(!h || !window.matchMedia("(max-width: 640px)").matches))
6300
6289
  return document.body.style.overflow = "hidden", () => {
6301
6290
  document.body.style.overflow = "";
6302
6291
  };
6303
6292
  }, [h]);
6304
- const [f, m, x] = sn(w) ? Ci(w) : [0, 0, 50], N = q(
6305
- (T) => {
6306
- u || b(T), g(T), n == null || n(T);
6293
+ const [f, m, x] = sn(w) ? Ti(w) : [0, 0, 50], N = Y(
6294
+ (C) => {
6295
+ u || b(C), g(C), n == null || n(C);
6307
6296
  },
6308
6297
  [u, n]
6309
- ), E = (T) => {
6310
- const A = T.startsWith("#") ? T : `#${T}`;
6298
+ ), E = (C) => {
6299
+ const A = C.startsWith("#") ? C : `#${C}`;
6311
6300
  g(A), sn(A) && N(A);
6312
6301
  };
6313
- return /* @__PURE__ */ k("div", { ref: v, className: C("vx-colorpicker", c), children: [
6302
+ return /* @__PURE__ */ k("div", { ref: v, className: T("vx-colorpicker", c), children: [
6314
6303
  r ? /* @__PURE__ */ a("span", { className: "vx-field-group__label", children: r }) : null,
6315
6304
  /* @__PURE__ */ k("div", { className: "vx-colorpicker__row", children: [
6316
6305
  /* @__PURE__ */ a(
6317
6306
  "button",
6318
6307
  {
6319
6308
  type: "button",
6320
- className: C(
6309
+ className: T(
6321
6310
  "vx-colorpicker__swatch-btn",
6322
6311
  l && "vx-colorpicker__swatch-btn--disabled"
6323
6312
  ),
6324
6313
  style: { "--vx-cp-color": w },
6325
- onClick: () => !l && y((T) => !T),
6314
+ onClick: () => !l && y((C) => !C),
6326
6315
  disabled: l,
6327
6316
  "aria-label": `Current color: ${w}. Click to open color picker.`,
6328
6317
  "aria-haspopup": "dialog",
@@ -6335,7 +6324,7 @@ function bc({
6335
6324
  type: "text",
6336
6325
  className: "vx-colorpicker__hex-input",
6337
6326
  value: S,
6338
- onChange: (T) => E(T.target.value),
6327
+ onChange: (C) => E(C.target.value),
6339
6328
  disabled: l,
6340
6329
  "aria-label": "Hex color value",
6341
6330
  maxLength: 7
@@ -6354,7 +6343,7 @@ function bc({
6354
6343
  min: "0",
6355
6344
  max: "360",
6356
6345
  value: f,
6357
- onChange: (T) => N(dt(Number(T.target.value), m, x)),
6346
+ onChange: (C) => N(dt(Number(C.target.value), m, x)),
6358
6347
  "aria-label": "Hue"
6359
6348
  }
6360
6349
  ),
@@ -6368,7 +6357,7 @@ function bc({
6368
6357
  max: "100",
6369
6358
  value: m,
6370
6359
  style: { "--vx-cp-hue": f },
6371
- onChange: (T) => N(dt(f, Number(T.target.value), x)),
6360
+ onChange: (C) => N(dt(f, Number(C.target.value), x)),
6372
6361
  "aria-label": "Saturation"
6373
6362
  }
6374
6363
  ),
@@ -6382,23 +6371,23 @@ function bc({
6382
6371
  max: "100",
6383
6372
  value: x,
6384
6373
  style: { "--vx-cp-hue": f, "--vx-cp-sat": `${m}%` },
6385
- onChange: (T) => N(dt(f, m, Number(T.target.value))),
6374
+ onChange: (C) => N(dt(f, m, Number(C.target.value))),
6386
6375
  "aria-label": "Lightness"
6387
6376
  }
6388
6377
  ),
6389
- d && /* @__PURE__ */ a("div", { className: "vx-colorpicker__presets", children: i.map((T) => /* @__PURE__ */ a(
6378
+ d && /* @__PURE__ */ a("div", { className: "vx-colorpicker__presets", children: i.map((C) => /* @__PURE__ */ a(
6390
6379
  "button",
6391
6380
  {
6392
6381
  type: "button",
6393
- className: C(
6382
+ className: T(
6394
6383
  "vx-colorpicker__preset",
6395
- w.toLowerCase() === T.toLowerCase() && "vx-colorpicker__preset--active"
6384
+ w.toLowerCase() === C.toLowerCase() && "vx-colorpicker__preset--active"
6396
6385
  ),
6397
- style: { background: T },
6398
- onClick: () => N(T),
6399
- "aria-label": T
6386
+ style: { background: C },
6387
+ onClick: () => N(C),
6388
+ "aria-label": C
6400
6389
  },
6401
- T
6390
+ C
6402
6391
  )) }),
6403
6392
  /* @__PURE__ */ a(
6404
6393
  "button",
@@ -6412,7 +6401,7 @@ function bc({
6412
6401
  ] })
6413
6402
  ] });
6414
6403
  }
6415
- function xc({
6404
+ function bc({
6416
6405
  direction: e = "horizontal",
6417
6406
  children: t,
6418
6407
  className: n
@@ -6420,7 +6409,7 @@ function xc({
6420
6409
  return /* @__PURE__ */ a(
6421
6410
  "div",
6422
6411
  {
6423
- className: C(
6412
+ className: T(
6424
6413
  "vx-resizable-group",
6425
6414
  `vx-resizable-group--${e}`,
6426
6415
  n
@@ -6429,7 +6418,7 @@ function xc({
6429
6418
  }
6430
6419
  );
6431
6420
  }
6432
- function yc({
6421
+ function xc({
6433
6422
  children: e,
6434
6423
  defaultSize: t = 50,
6435
6424
  minSize: n = 10,
@@ -6440,7 +6429,7 @@ function yc({
6440
6429
  return /* @__PURE__ */ a(
6441
6430
  "div",
6442
6431
  {
6443
- className: C("vx-resizable-panel", o),
6432
+ className: T("vx-resizable-panel", o),
6444
6433
  style: { "--vx-panel-size": `${t}%`, ...s },
6445
6434
  "data-min": n,
6446
6435
  "data-max": r,
@@ -6448,11 +6437,11 @@ function yc({
6448
6437
  }
6449
6438
  );
6450
6439
  }
6451
- function _c({
6440
+ function yc({
6452
6441
  className: e,
6453
6442
  direction: t = "horizontal"
6454
6443
  }) {
6455
- const n = z(!1), [r, o] = I(!1), s = q(
6444
+ const n = B(!1), [r, o] = I(!1), s = Y(
6456
6445
  (l) => {
6457
6446
  const i = l.currentTarget, d = i.previousElementSibling, c = i.nextElementSibling;
6458
6447
  if (!d || !c) return;
@@ -6460,8 +6449,8 @@ function _c({
6460
6449
  n.current = !0, o(!0);
6461
6450
  const y = Number(d.dataset.min ?? 10) / 100 * b, v = Number(d.dataset.max ?? 90) / 100 * b, f = Number(c.dataset.min ?? 10) / 100 * b, m = Number(c.dataset.max ?? 90) / 100 * b, x = (E) => {
6462
6451
  if (!n.current) return;
6463
- const T = g(E) - h, A = Math.min(Math.max(w + T, y), v), P = Math.min(Math.max(S - T, f), m);
6464
- d.style.flexBasis = `${A / b * 100}%`, c.style.flexBasis = `${P / b * 100}%`;
6452
+ const C = g(E) - h, A = Math.min(Math.max(w + C, y), v), R = Math.min(Math.max(S - C, f), m);
6453
+ d.style.flexBasis = `${A / b * 100}%`, c.style.flexBasis = `${R / b * 100}%`;
6465
6454
  }, N = () => {
6466
6455
  n.current = !1, o(!1), document.removeEventListener("mousemove", x), document.removeEventListener("mouseup", N), document.removeEventListener("touchmove", x), document.removeEventListener("touchend", N);
6467
6456
  };
@@ -6474,7 +6463,7 @@ function _c({
6474
6463
  {
6475
6464
  role: "separator",
6476
6465
  "aria-orientation": t === "horizontal" ? "vertical" : "horizontal",
6477
- className: C(
6466
+ className: T(
6478
6467
  "vx-resizable-handle",
6479
6468
  `vx-resizable-handle--${t}`,
6480
6469
  r && "vx-resizable-handle--active",
@@ -6489,7 +6478,7 @@ function _c({
6489
6478
  function ln(e, t) {
6490
6479
  if (!t) return e;
6491
6480
  const n = e.toLowerCase().indexOf(t.toLowerCase());
6492
- return n === -1 ? e : /* @__PURE__ */ k(J, { children: [
6481
+ return n === -1 ? e : /* @__PURE__ */ k(ee, { children: [
6493
6482
  e.slice(0, n),
6494
6483
  /* @__PURE__ */ a("mark", { className: "vx-cmd__mark", children: e.slice(n, n + t.length) }),
6495
6484
  e.slice(n + t.length)
@@ -6499,7 +6488,7 @@ function Ai(e, t) {
6499
6488
  const n = t.toLowerCase(), r = e.title.toLowerCase(), o = e.section.toLowerCase(), s = e.description.toLowerCase(), l = (e.keywords ?? []).join(" ").toLowerCase();
6500
6489
  return r === n ? 100 : r.startsWith(n) ? 80 : r.includes(n) ? 60 : o.includes(n) ? 40 : l.includes(n) ? 35 : s.includes(n) ? 20 : 0;
6501
6490
  }
6502
- function wc({
6491
+ function _c({
6503
6492
  entries: e,
6504
6493
  open: t,
6505
6494
  onClose: n,
@@ -6511,25 +6500,25 @@ function wc({
6511
6500
  labelGo: d = "Go",
6512
6501
  labelClose: c = "Close"
6513
6502
  }) {
6514
- const [u, p] = I(""), [b, w] = I(0), S = z(null), g = z(null), h = u.trim() ? e.map((m) => ({ entry: m, s: Ai(m, u.trim()) })).filter((m) => m.s > 0).sort((m, x) => x.s - m.s).map((m) => m.entry) : e;
6515
- $(() => {
6503
+ const [u, p] = I(""), [b, w] = I(0), S = B(null), g = B(null), h = u.trim() ? e.map((m) => ({ entry: m, s: Ai(m, u.trim()) })).filter((m) => m.s > 0).sort((m, x) => x.s - m.s).map((m) => m.entry) : e;
6504
+ z(() => {
6516
6505
  t && (p(""), w(0), setTimeout(() => {
6517
6506
  var m;
6518
6507
  return (m = S.current) == null ? void 0 : m.focus();
6519
6508
  }, 30));
6520
- }, [t]), $(() => {
6509
+ }, [t]), z(() => {
6521
6510
  w(0);
6522
- }, [u]), $(() => {
6511
+ }, [u]), z(() => {
6523
6512
  var x;
6524
6513
  const m = (x = g.current) == null ? void 0 : x.children[b];
6525
6514
  m == null || m.scrollIntoView({ block: "nearest" });
6526
6515
  }, [b]);
6527
- const y = q(
6516
+ const y = Y(
6528
6517
  (m) => {
6529
6518
  r(m), n();
6530
6519
  },
6531
6520
  [r, n]
6532
- ), v = q(
6521
+ ), v = Y(
6533
6522
  (m) => {
6534
6523
  m.key === "ArrowDown" ? (m.preventDefault(), w((x) => Math.min(x + 1, h.length - 1))) : m.key === "ArrowUp" ? (m.preventDefault(), w((x) => Math.max(x - 1, 0))) : m.key === "Enter" ? (m.preventDefault(), h[b] && y(h[b].key)) : m.key === "Escape" && n();
6535
6524
  },
@@ -6573,13 +6562,13 @@ function wc({
6573
6562
  ] }),
6574
6563
  /* @__PURE__ */ a("ul", { className: "vx-cmd__list", ref: g, role: "listbox", children: h.length === 0 ? /* @__PURE__ */ a("li", { className: "vx-cmd__empty", children: l(u) }) : f.map(
6575
6564
  (m) => m.items.map((x, N) => {
6576
- const E = h.indexOf(x), T = E === b;
6565
+ const E = h.indexOf(x), C = E === b;
6577
6566
  return /* @__PURE__ */ k(
6578
6567
  "li",
6579
6568
  {
6580
6569
  role: "option",
6581
- "aria-selected": T,
6582
- className: `vx-cmd__item${T ? " vx-cmd__item--active" : ""}`,
6570
+ "aria-selected": C,
6571
+ className: `vx-cmd__item${C ? " vx-cmd__item--active" : ""}`,
6583
6572
  onMouseEnter: () => w(E),
6584
6573
  onMouseDown: () => y(x.key),
6585
6574
  children: [
@@ -6588,7 +6577,7 @@ function wc({
6588
6577
  /* @__PURE__ */ a("span", { className: "vx-cmd__item-title", children: ln(x.title, u) }),
6589
6578
  /* @__PURE__ */ a("span", { className: "vx-cmd__item-sub", children: ln(x.section, u) })
6590
6579
  ] }),
6591
- T && /* @__PURE__ */ a("kbd", { className: "vx-cmd__enter", children: "↵" })
6580
+ C && /* @__PURE__ */ a("kbd", { className: "vx-cmd__enter", children: "↵" })
6592
6581
  ]
6593
6582
  },
6594
6583
  x.key
@@ -6747,8 +6736,8 @@ function Ri() {
6747
6736
  case "Array":
6748
6737
  return N = i.util.objId(f), m[N] ? m[N] : (x = [], m[N] = x, /** @type {Array} */
6749
6738
  /** @type {any} */
6750
- f.forEach(function(T, A) {
6751
- x[A] = v(T, m);
6739
+ f.forEach(function(C, A) {
6740
+ x[A] = v(C, m);
6752
6741
  }), /** @type {any} */
6753
6742
  x);
6754
6743
  default:
@@ -6969,27 +6958,27 @@ function Ri() {
6969
6958
  x = x || /** @type {any} */
6970
6959
  i.languages;
6971
6960
  var N = x[v], E = {};
6972
- for (var T in N)
6973
- if (N.hasOwnProperty(T)) {
6974
- if (T == f)
6961
+ for (var C in N)
6962
+ if (N.hasOwnProperty(C)) {
6963
+ if (C == f)
6975
6964
  for (var A in m)
6976
6965
  m.hasOwnProperty(A) && (E[A] = m[A]);
6977
- m.hasOwnProperty(T) || (E[T] = N[T]);
6966
+ m.hasOwnProperty(C) || (E[C] = N[C]);
6978
6967
  }
6979
- var P = x[v];
6980
- return x[v] = E, i.languages.DFS(i.languages, function(R, L) {
6981
- L === P && R != v && (this[R] = E);
6968
+ var R = x[v];
6969
+ return x[v] = E, i.languages.DFS(i.languages, function(P, L) {
6970
+ L === R && P != v && (this[P] = E);
6982
6971
  }), E;
6983
6972
  },
6984
6973
  // Traverse a language definition with Depth First Search
6985
6974
  DFS: function v(f, m, x, N) {
6986
6975
  N = N || {};
6987
6976
  var E = i.util.objId;
6988
- for (var T in f)
6989
- if (f.hasOwnProperty(T)) {
6990
- m.call(f, T, f[T], x || T);
6991
- var A = f[T], P = i.util.type(A);
6992
- P === "Object" && !N[E(A)] ? (N[E(A)] = !0, v(A, m, null, N)) : P === "Array" && !N[E(A)] && (N[E(A)] = !0, v(A, m, T, N));
6977
+ for (var C in f)
6978
+ if (f.hasOwnProperty(C)) {
6979
+ m.call(f, C, f[C], x || C);
6980
+ var A = f[C], R = i.util.type(A);
6981
+ R === "Object" && !N[E(A)] ? (N[E(A)] = !0, v(A, m, null, N)) : R === "Array" && !N[E(A)] && (N[E(A)] = !0, v(A, m, C, N));
6993
6982
  }
6994
6983
  }
6995
6984
  },
@@ -7067,13 +7056,13 @@ function Ri() {
7067
7056
  i.util.setLanguage(v, x);
7068
7057
  var E = v.parentElement;
7069
7058
  E && E.nodeName.toLowerCase() === "pre" && i.util.setLanguage(E, x);
7070
- var T = v.textContent, A = {
7059
+ var C = v.textContent, A = {
7071
7060
  element: v,
7072
7061
  language: x,
7073
7062
  grammar: N,
7074
- code: T
7063
+ code: C
7075
7064
  };
7076
- function P(L) {
7065
+ function R(L) {
7077
7066
  A.highlightedCode = L, i.hooks.run("before-insert", A), A.element.innerHTML = A.highlightedCode, i.hooks.run("after-highlight", A), i.hooks.run("complete", A), m && m.call(A.element);
7078
7067
  }
7079
7068
  if (i.hooks.run("before-sanity-check", A), E = A.element.parentElement, E && E.nodeName.toLowerCase() === "pre" && !E.hasAttribute("tabindex") && E.setAttribute("tabindex", "0"), !A.code) {
@@ -7081,20 +7070,20 @@ function Ri() {
7081
7070
  return;
7082
7071
  }
7083
7072
  if (i.hooks.run("before-highlight", A), !A.grammar) {
7084
- P(i.util.encode(A.code));
7073
+ R(i.util.encode(A.code));
7085
7074
  return;
7086
7075
  }
7087
7076
  if (f && r.Worker) {
7088
- var R = new Worker(i.filename);
7089
- R.onmessage = function(L) {
7090
- P(L.data);
7091
- }, R.postMessage(JSON.stringify({
7077
+ var P = new Worker(i.filename);
7078
+ P.onmessage = function(L) {
7079
+ R(L.data);
7080
+ }, P.postMessage(JSON.stringify({
7092
7081
  language: A.language,
7093
7082
  code: A.code,
7094
7083
  immediateClose: !0
7095
7084
  }));
7096
7085
  } else
7097
- P(i.highlight(A.code, A.grammar, A.language));
7086
+ R(i.highlight(A.code, A.grammar, A.language));
7098
7087
  },
7099
7088
  /**
7100
7089
  * Low-level function, only use if you know what you’re doing. It accepts a string of text as input
@@ -7210,8 +7199,8 @@ function Ri() {
7210
7199
  return f;
7211
7200
  if (Array.isArray(f)) {
7212
7201
  var x = "";
7213
- return f.forEach(function(P) {
7214
- x += v(P, m);
7202
+ return f.forEach(function(R) {
7203
+ x += v(R, m);
7215
7204
  }), x;
7216
7205
  }
7217
7206
  var N = {
@@ -7223,10 +7212,10 @@ function Ri() {
7223
7212
  language: m
7224
7213
  }, E = f.alias;
7225
7214
  E && (Array.isArray(E) ? Array.prototype.push.apply(N.classes, E) : N.classes.push(E)), i.hooks.run("wrap", N);
7226
- var T = "";
7215
+ var C = "";
7227
7216
  for (var A in N.attributes)
7228
- T += " " + A + '="' + (N.attributes[A] || "").replace(/"/g, "&quot;") + '"';
7229
- return "<" + N.tag + ' class="' + N.classes.join(" ") + '"' + T + ">" + N.content + "</" + N.tag + ">";
7217
+ C += " " + A + '="' + (N.attributes[A] || "").replace(/"/g, "&quot;") + '"';
7218
+ return "<" + N.tag + ' class="' + N.classes.join(" ") + '"' + C + ">" + N.content + "</" + N.tag + ">";
7230
7219
  };
7231
7220
  function c(v, f, m, x) {
7232
7221
  v.lastIndex = f;
@@ -7238,48 +7227,48 @@ function Ri() {
7238
7227
  return N;
7239
7228
  }
7240
7229
  function u(v, f, m, x, N, E) {
7241
- for (var T in m)
7242
- if (!(!m.hasOwnProperty(T) || !m[T])) {
7243
- var A = m[T];
7230
+ for (var C in m)
7231
+ if (!(!m.hasOwnProperty(C) || !m[C])) {
7232
+ var A = m[C];
7244
7233
  A = Array.isArray(A) ? A : [A];
7245
- for (var P = 0; P < A.length; ++P) {
7246
- if (E && E.cause == T + "," + P)
7234
+ for (var R = 0; R < A.length; ++R) {
7235
+ if (E && E.cause == C + "," + R)
7247
7236
  return;
7248
- var R = A[P], L = R.inside, B = !!R.lookbehind, D = !!R.greedy, W = R.alias;
7249
- if (D && !R.pattern.global) {
7250
- var G = R.pattern.toString().match(/[imsuy]*$/)[0];
7251
- R.pattern = RegExp(R.pattern.source, G + "g");
7237
+ var P = A[R], L = P.inside, $ = !!P.lookbehind, D = !!P.greedy, U = P.alias;
7238
+ if (D && !P.pattern.global) {
7239
+ var H = P.pattern.toString().match(/[imsuy]*$/)[0];
7240
+ P.pattern = RegExp(P.pattern.source, H + "g");
7252
7241
  }
7253
- for (var X = R.pattern || R, K = x.next, Y = N; K !== f.tail && !(E && Y >= E.reach); Y += K.value.length, K = K.next) {
7254
- var M = K.value;
7242
+ for (var Z = P.pattern || P, j = x.next, X = N; j !== f.tail && !(E && X >= E.reach); X += j.value.length, j = j.next) {
7243
+ var M = j.value;
7255
7244
  if (f.length > v.length)
7256
7245
  return;
7257
7246
  if (!(M instanceof d)) {
7258
- var H = 1, F;
7247
+ var q = 1, F;
7259
7248
  if (D) {
7260
- if (F = c(X, Y, v, B), !F || F.index >= v.length)
7249
+ if (F = c(Z, X, v, $), !F || F.index >= v.length)
7261
7250
  break;
7262
- var te = F.index, O = F.index + F[0].length, U = Y;
7263
- for (U += K.value.length; te >= U; )
7264
- K = K.next, U += K.value.length;
7265
- if (U -= K.value.length, Y = U, K.value instanceof d)
7251
+ var Q = F.index, O = F.index + F[0].length, W = X;
7252
+ for (W += j.value.length; Q >= W; )
7253
+ j = j.next, W += j.value.length;
7254
+ if (W -= j.value.length, X = W, j.value instanceof d)
7266
7255
  continue;
7267
- for (var Z = K; Z !== f.tail && (U < O || typeof Z.value == "string"); Z = Z.next)
7268
- H++, U += Z.value.length;
7269
- H--, M = v.slice(Y, U), F.index -= Y;
7270
- } else if (F = c(X, 0, M, B), !F)
7256
+ for (var K = j; K !== f.tail && (W < O || typeof K.value == "string"); K = K.next)
7257
+ q++, W += K.value.length;
7258
+ q--, M = v.slice(X, W), F.index -= X;
7259
+ } else if (F = c(Z, 0, M, $), !F)
7271
7260
  continue;
7272
- var te = F.index, de = F[0], fe = M.slice(0, te), $t = M.slice(te + de.length), Qe = Y + M.length;
7261
+ var Q = F.index, de = F[0], fe = M.slice(0, Q), Ot = M.slice(Q + de.length), Qe = X + M.length;
7273
7262
  E && Qe > E.reach && (E.reach = Qe);
7274
- var Re = K.prev;
7275
- fe && (Re = b(f, Re, fe), Y += fe.length), w(f, Re, H);
7276
- var Gr = new d(T, L ? i.tokenize(de, L) : de, W, de);
7277
- if (K = b(f, Re, Gr), $t && b(f, K, $t), H > 1) {
7263
+ var Re = j.prev;
7264
+ fe && (Re = b(f, Re, fe), X += fe.length), w(f, Re, q);
7265
+ var Gr = new d(C, L ? i.tokenize(de, L) : de, U, de);
7266
+ if (j = b(f, Re, Gr), Ot && b(f, j, Ot), q > 1) {
7278
7267
  var Je = {
7279
- cause: T + "," + P,
7268
+ cause: C + "," + R,
7280
7269
  reach: Qe
7281
7270
  };
7282
- u(v, f, m, K.prev, Y, Je), E && Je.reach > E.reach && (E.reach = Je.reach);
7271
+ u(v, f, m, j.prev, X, Je), E && Je.reach > E.reach && (E.reach = Je.reach);
7283
7272
  }
7284
7273
  }
7285
7274
  }
@@ -7748,8 +7737,8 @@ function Ri() {
7748
7737
  h.setAttribute(i, c);
7749
7738
  var E = w(h.getAttribute("data-range"));
7750
7739
  if (E) {
7751
- var T = N.split(/\r\n?|\n/g), A = E[0], P = E[1] == null ? T.length : E[1];
7752
- A < 0 && (A += T.length), A = Math.max(0, Math.min(A - 1, T.length)), P < 0 && (P += T.length), P = Math.max(0, Math.min(P, T.length)), N = T.slice(A, P).join(`
7740
+ var C = N.split(/\r\n?|\n/g), A = E[0], R = E[1] == null ? C.length : E[1];
7741
+ A < 0 && (A += C.length), A = Math.max(0, Math.min(A - 1, C.length)), R < 0 && (R += C.length), R = Math.max(0, Math.min(R, C.length)), N = C.slice(A, R).join(`
7753
7742
  `), h.hasAttribute("data-start") || h.setAttribute("data-start", String(A + 1));
7754
7743
  }
7755
7744
  y.textContent = N, n.highlightElement(y);
@@ -8472,18 +8461,18 @@ Prism.languages.json = {
8472
8461
  }
8473
8462
  };
8474
8463
  Prism.languages.webmanifest = Prism.languages.json;
8475
- function kc({
8464
+ function wc({
8476
8465
  code: e,
8477
8466
  language: t = "tsx",
8478
8467
  copyLabel: n,
8479
8468
  copiedLabel: r,
8480
8469
  onCopy: o
8481
8470
  }) {
8482
- const [s, l] = I(!1), i = z(null), d = Ne(() => {
8471
+ const [s, l] = I(!1), i = B(null), d = Ne(() => {
8483
8472
  const u = Be.languages[t] ?? Be.languages.tsx ?? Be.languages.typescript;
8484
8473
  return u ? Be.highlight(e, u, t) : e;
8485
8474
  }, [e, t]);
8486
- $(() => () => {
8475
+ z(() => () => {
8487
8476
  i.current && clearTimeout(i.current);
8488
8477
  }, []);
8489
8478
  async function c() {
@@ -8515,7 +8504,7 @@ function kc({
8515
8504
  ) })
8516
8505
  ] });
8517
8506
  }
8518
- const Li = "1.2.6", Ii = {
8507
+ const Li = "1.2.7", Ii = {
8519
8508
  version: Li
8520
8509
  }, je = `v${Ii.version}`, Hr = {
8521
8510
  locale: "en",
@@ -8800,10 +8789,10 @@ const Li = "1.2.6", Ii = {
8800
8789
  "form-controls": {
8801
8790
  section: "Components",
8802
8791
  title: "Form Controls",
8803
- description: "A complete set of form primitives: single-line inputs, multi-line textarea, native select, searchable single-select (Combobox), multi-select with tag display (MultiSelect), and time selection (TimePicker). All share the same label / hint / error layout system.",
8792
+ description: "A complete set of form primitives: single-line inputs, multi-line textarea, searchable single-select (Select), multi-select with tag display (MultiSelect), and time selection (TimePicker). All share the same label / hint / error layout system.",
8804
8793
  guidance: [
8805
8794
  "Always pair form controls with visible labels in admin surfaces.",
8806
- "Use Combobox for single-select with optional search; set `searchable={N}` to show the search input only when options exceed N.",
8795
+ "Use Select for single-select with optional search; set `searchable={N}` to show the search input only when options exceed N.",
8807
8796
  "Use MultiSelect when users need to pick several values from a bounded list.",
8808
8797
  "TimePicker supports 24-hour format and an optional seconds column via the `seconds` prop.",
8809
8798
  "Short helper text is better than placeholder-only instruction."
@@ -9283,10 +9272,10 @@ const Li = "1.2.6", Ii = {
9283
9272
  "form-controls": {
9284
9273
  section: "组件",
9285
9274
  title: "表单控件",
9286
- description: "完整的表单原语集:单行输入框、多行文本域、原生选择框、可搜索单选下拉(Combobox)、带标签显示的多选下拉(MultiSelect)和时间选择器(TimePicker)。所有组件共享统一的 label / hint / error 布局体系。",
9275
+ description: "完整的表单原语集:单行输入框、多行文本域、可搜索单选下拉(Select)、带标签显示的多选下拉(MultiSelect)和时间选择器(TimePicker)。所有组件共享统一的 label / hint / error 布局体系。",
9287
9276
  guidance: [
9288
9277
  "在管理界面中,表单控件始终应配有可见标签。",
9289
- "使用 Combobox 实现单选下拉;通过 `searchable={N}` 可设为仅当选项超过 N 条时显示搜索框。",
9278
+ "使用 Select 实现单选下拉;通过 `searchable={N}` 可设为仅当选项超过 N 条时显示搜索框。",
9290
9279
  "当用户需要从有限列表中选择多个值时,使用 MultiSelect。",
9291
9280
  "TimePicker 支持 24 小时制,通过 `seconds` prop 可启用秒选择列。",
9292
9281
  "简短的辅助文本优于仅依赖 placeholder 的说明。"
@@ -9483,24 +9472,24 @@ const Li = "1.2.6", Ii = {
9483
9472
  ]
9484
9473
  }
9485
9474
  }
9486
- }, vn = { en: Hr, zh: Mi }, Oi = _e({
9475
+ }, vn = { en: Hr, zh: Mi }, $i = _e({
9487
9476
  t: Hr,
9488
9477
  locale: "en",
9489
9478
  setLocale: () => {
9490
9479
  }
9491
9480
  });
9492
- function $i() {
9493
- return ye(Oi);
9481
+ function Oi() {
9482
+ return ye($i);
9494
9483
  }
9495
- function Nc({ variant: e = "inline", className: t }) {
9496
- const { locale: n, setLocale: r } = $i(), o = Object.entries(vn), s = vn[n], [l, i] = I(!1), d = z(null);
9497
- return $(() => {
9484
+ function kc({ variant: e = "inline", className: t }) {
9485
+ const { locale: n, setLocale: r } = Oi(), o = Object.entries(vn), s = vn[n], [l, i] = I(!1), d = B(null);
9486
+ return z(() => {
9498
9487
  if (!l) return;
9499
9488
  const u = (p) => {
9500
9489
  d.current && !d.current.contains(p.target) && i(!1);
9501
9490
  };
9502
9491
  return document.addEventListener("mousedown", u), () => document.removeEventListener("mousedown", u);
9503
- }, [l]), $(() => {
9492
+ }, [l]), z(() => {
9504
9493
  if (!l) return;
9505
9494
  const u = (p) => {
9506
9495
  p.key === "Escape" && i(!1);
@@ -9510,7 +9499,7 @@ function Nc({ variant: e = "inline", className: t }) {
9510
9499
  "div",
9511
9500
  {
9512
9501
  ref: d,
9513
- className: C(
9502
+ className: T(
9514
9503
  "vx-lang-drop",
9515
9504
  e === "sidebar" && "vx-lang-drop--sidebar",
9516
9505
  l && "vx-lang-drop--open",
@@ -9539,7 +9528,7 @@ function Nc({ variant: e = "inline", className: t }) {
9539
9528
  "button",
9540
9529
  {
9541
9530
  type: "button",
9542
- className: C("vx-lang-drop__item", n === u && "vx-lang-drop__item--active"),
9531
+ className: T("vx-lang-drop__item", n === u && "vx-lang-drop__item--active"),
9543
9532
  onClick: () => {
9544
9533
  r(u), i(!1);
9545
9534
  },
@@ -9554,9 +9543,9 @@ function Nc({ variant: e = "inline", className: t }) {
9554
9543
  );
9555
9544
  }
9556
9545
  export {
9557
- Tl as Accordion,
9546
+ Cl as Accordion,
9558
9547
  Ml as ActionSheet,
9559
- Ol as ActionSheetItem,
9548
+ $l as ActionSheetItem,
9560
9549
  _l as Alert,
9561
9550
  Xl as AlertDialog,
9562
9551
  Gi as AppShell,
@@ -9571,86 +9560,85 @@ export {
9571
9560
  Yi as CardDescription,
9572
9561
  Vi as CardHeader,
9573
9562
  qi as CardTitle,
9574
- fc as Carousel,
9563
+ vc as Carousel,
9575
9564
  vl as Checkbox,
9576
- kc as CodeBlock,
9577
- bc as ColorPicker,
9578
- Jl as Combobox,
9579
- wc as CommandPalette,
9580
- ic as ContextMenu,
9565
+ wc as CodeBlock,
9566
+ gc as ColorPicker,
9567
+ _c as CommandPalette,
9568
+ sc as ContextMenu,
9581
9569
  Ql as DatePicker,
9582
9570
  Qi as Dialog,
9583
9571
  Wl as DrawerNavItem,
9584
9572
  Hl as DrawerNavSection,
9585
9573
  Sl as DropdownMenu,
9586
- vc as EmptyState,
9587
- nc as FileUpload,
9574
+ pc as EmptyState,
9575
+ tc as FileUpload,
9588
9576
  jl as Form,
9589
9577
  ql as FormDescription,
9590
9578
  Kl as FormField,
9591
9579
  Vl as FormLabel,
9592
9580
  Yl as FormMessage,
9593
9581
  ul as Heading,
9594
- lc as HoverCard,
9582
+ ic as HoverCard,
9595
9583
  Ji as Input,
9596
9584
  Gl as Label,
9597
- Nc as LanguageSwitcher,
9598
- cc as Menubar,
9585
+ kc as LanguageSwitcher,
9586
+ lc as Menubar,
9599
9587
  Ul as MobileDrawer,
9600
9588
  Ll as MobileIconButton,
9601
- $l as MobileList,
9589
+ Ol as MobileList,
9602
9590
  zl as MobileListItem,
9603
9591
  Bl as MobileListSection,
9604
9592
  Dl as MobileShell,
9605
9593
  Fl as MobileTopBar,
9606
- ec as MultiSelect,
9607
- dc as NavigationMenu,
9594
+ Jl as MultiSelect,
9595
+ cc as NavigationMenu,
9608
9596
  Zl as NumberInput,
9609
- Cl as Pagination,
9597
+ Tl as Pagination,
9610
9598
  Nl as Popover,
9611
9599
  yl as Progress,
9612
9600
  ml as Radio,
9613
9601
  hl as RadioGroup,
9614
- mc as Rating,
9615
- _c as ResizableHandle,
9616
- yc as ResizablePanel,
9617
- xc as ResizablePanelGroup,
9602
+ fc as Rating,
9603
+ yc as ResizableHandle,
9604
+ xc as ResizablePanel,
9605
+ bc as ResizablePanelGroup,
9618
9606
  Hi as Responsive,
9619
- ac as ScrollArea,
9607
+ rc as ScrollArea,
9620
9608
  fl as SegmentedControl,
9621
9609
  pl as Select,
9622
9610
  Al as Separator,
9623
- rc as Sheet,
9611
+ nc as Sheet,
9624
9612
  wa as Shell,
9625
9613
  Pa as ShellContent,
9626
- Ta as ShellMain,
9614
+ Ca as ShellMain,
9627
9615
  Na as ShellNav,
9628
9616
  Ea as ShellNavItem,
9629
9617
  Sa as ShellNavSection,
9630
- Ca as ShellOverlay,
9618
+ Ta as ShellOverlay,
9631
9619
  ka as ShellSidebar,
9632
9620
  Aa as ShellTopbar,
9633
9621
  wl as Skeleton,
9634
9622
  bl as Slider,
9635
9623
  xl as Spinner,
9636
- uc as Stepper,
9624
+ dc as Stepper,
9637
9625
  el as Switch,
9638
9626
  Rl as Table,
9639
9627
  tl as Tabs,
9640
9628
  al as TabsContent,
9641
9629
  nl as TabsList,
9642
9630
  rl as TabsTrigger,
9643
- gc as TagInput,
9631
+ hc as TagInput,
9644
9632
  dl as Text,
9645
9633
  gl as Textarea,
9646
9634
  sl as ThemeProvider,
9647
- tc as TimePicker,
9648
- pc as Timeline,
9635
+ ec as TimePicker,
9636
+ uc as Timeline,
9649
9637
  ll as ToastProvider,
9650
- oc as Toggle,
9651
- sc as ToggleGroup,
9638
+ ac as Toggle,
9639
+ oc as ToggleGroup,
9652
9640
  kl as Tooltip,
9653
- hc as TreeView,
9641
+ mc as TreeView,
9654
9642
  Wi as ViewportProvider,
9655
9643
  ne as createTheme,
9656
9644
  ol as themePresets,