@udixio/ui-react 2.9.16 → 2.9.17

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,9 +1,9 @@
1
1
  var Wt = Object.defineProperty;
2
2
  var At = (e, t, n) => t in e ? Wt(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
3
  var B = (e, t, n) => At(e, typeof t != "symbol" ? t + "" : t, n);
4
- import { jsx as d, jsxs as K, Fragment as me } from "react/jsx-runtime";
5
- import Q, { useState as V, useEffect as _, useMemo as we, useRef as j, useLayoutEffect as $e, useId as Me, useCallback as pe, isValidElement as ke, cloneElement as Re, createContext as Ft, useContext as Ze, Children as Bt, Fragment as Pt } from "react";
6
- import { AnimatePresence as he, motion as ne, useScroll as Ht, useMotionValueEvent as Ve, animate as Ot } from "motion/react";
4
+ import { jsx as d, jsxs as K, Fragment as ye } from "react/jsx-runtime";
5
+ import Q, { useState as V, useEffect as _, useMemo as be, useRef as j, useLayoutEffect as $e, useId as Ee, useCallback as me, isValidElement as Ie, cloneElement as Re, createContext as Ft, useContext as Ze, Children as Bt, Fragment as Ht } from "react";
6
+ import { AnimatePresence as pe, motion as ne, useScroll as Pt, useMotionValueEvent as Ve, animate as Ot } from "motion/react";
7
7
  import { clsx as Qe } from "clsx";
8
8
  import { extendTailwindMerge as zt } from "tailwind-merge";
9
9
  import { createPortal as et } from "react-dom";
@@ -66,7 +66,7 @@ const qt = ({
66
66
  background: `radial-gradient(ellipse at var(--x) var(--y), ${f} var(--r), transparent calc(var(--r) * 2))`,
67
67
  pointerEvents: "none"
68
68
  };
69
- return /* @__PURE__ */ d(he, { mode: "wait", children: (c || !c && !s) && /* @__PURE__ */ d(
69
+ return /* @__PURE__ */ d(pe, { mode: "wait", children: (c || !c && !s) && /* @__PURE__ */ d(
70
70
  ne.div,
71
71
  {
72
72
  style: p,
@@ -107,7 +107,7 @@ const qt = ({
107
107
  function jt(e) {
108
108
  return e.replace(/([a-z])([A-Z])/g, "$1-$2").toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g, "").replace(/[^a-z0-9]+/g, "-").replace(/^-+|-+$/g, "");
109
109
  }
110
- const Pe = (e) => {
110
+ const He = (e) => {
111
111
  const t = {};
112
112
  e.classNameList.forEach((s) => {
113
113
  var r;
@@ -127,12 +127,12 @@ const Pe = (e) => {
127
127
  let [r, c] = s;
128
128
  c = c.reverse(), r == e.default && c.unshift("relative"), c.unshift(jt(r)), n[r] = Ut(...c);
129
129
  }), n;
130
- }, oe = (e, t) => (n) => Pe({
130
+ }, oe = (e, t) => (n) => He({
131
131
  classNameList: [n.className, t],
132
132
  default: e,
133
133
  states: n
134
- }), re = (e, t) => (n) => we(
135
- () => Pe({
134
+ }), re = (e, t) => (n) => be(
135
+ () => He({
136
136
  classNameList: [n.className, t],
137
137
  default: e,
138
138
  states: n
@@ -140,8 +140,8 @@ const Pe = (e) => {
140
140
  [n]
141
141
  );
142
142
  function Sr(e, t, n) {
143
- return we(
144
- () => Pe({
143
+ return be(
144
+ () => He({
145
145
  classNameList: [n == null ? void 0 : n.className, t],
146
146
  default: e,
147
147
  states: n
@@ -211,10 +211,10 @@ const Jt = ({
211
211
  _(() => {
212
212
  if (!o.current) return;
213
213
  const k = new ResizeObserver((N) => {
214
- for (const W of N)
215
- W.target === o.current && f({
216
- width: W.contentRect.width,
217
- height: W.contentRect.height
214
+ for (const A of N)
215
+ A.target === o.current && f({
216
+ width: A.contentRect.width,
217
+ height: A.contentRect.height
218
218
  // On observe aussi la hauteur maintenant
219
219
  });
220
220
  });
@@ -235,7 +235,7 @@ const Jt = ({
235
235
  height: k.clientHeight
236
236
  // Correction ici pour retourner la bonne hauteur
237
237
  } : null;
238
- }, { scrollYProgress: M, scrollXProgress: b } = Ht({
238
+ }, { scrollYProgress: M, scrollXProgress: b } = Pt({
239
239
  container: o
240
240
  }), g = j(null);
241
241
  g.current || (g.current = Gt(
@@ -262,29 +262,29 @@ const Jt = ({
262
262
  }, [m]), _(() => {
263
263
  const k = o.current, N = u.current;
264
264
  if (!k || !N || typeof i != "number") return;
265
- const W = (H, X, q) => Math.min(q, Math.max(X, H));
265
+ const A = (P, X, q) => Math.min(q, Math.max(X, P));
266
266
  if (t === "horizontal") {
267
- const H = Math.max(0, (n ?? N.scrollWidth) - k.clientWidth);
268
- k.scrollLeft = W(i * H, 0, H);
267
+ const P = Math.max(0, (n ?? N.scrollWidth) - k.clientWidth);
268
+ k.scrollLeft = A(i * P, 0, P);
269
269
  } else {
270
- const H = Math.max(0, (n ?? N.scrollHeight) - k.clientHeight);
271
- k.scrollTop = W(i * H, 0, H);
270
+ const P = Math.max(0, (n ?? N.scrollHeight) - k.clientHeight);
271
+ k.scrollTop = A(i * P, 0, P);
272
272
  }
273
273
  }, [i, t, n]), Ve(b, "change", (k) => {
274
274
  O(k, "x");
275
275
  }), Ve(M, "change", (k) => {
276
276
  O(k, "y");
277
277
  });
278
- const [A, v] = V(!1);
278
+ const [R, v] = V(!1);
279
279
  $e(() => {
280
- A || !h.current || !p.current || !s || (s({
280
+ R || !h.current || !p.current || !s || (s({
281
281
  scrollProgress: 0,
282
282
  scroll: 0,
283
283
  scrollTotal: t == "vertical" ? p.current.height : p.current.width,
284
284
  scrollVisible: t == "vertical" ? h.current.height : h.current.width
285
285
  }), v(!0));
286
286
  }, [h, p, s]), p.current = x(), h.current = w();
287
- const [S, R] = V(!1), I = Kt({
287
+ const [S, $] = V(!1), I = Kt({
288
288
  isDragging: S,
289
289
  children: e,
290
290
  className: r,
@@ -297,17 +297,17 @@ const Jt = ({
297
297
  if (!c) return;
298
298
  const N = o.current;
299
299
  if (!N || F == null) return;
300
- const H = (k.pageX - N.offsetLeft - F) * 1.5;
301
- N.scrollLeft = Y - H;
302
- }, P = (k) => {
300
+ const P = (k.pageX - N.offsetLeft - F) * 1.5;
301
+ N.scrollLeft = Y - P;
302
+ }, H = (k) => {
303
303
  const N = o.current;
304
- N && (R(!0), E(k.pageX - N.offsetLeft), z(N.scrollLeft));
304
+ N && ($(!0), E(k.pageX - N.offsetLeft), z(N.scrollLeft));
305
305
  }, C = (k) => {
306
306
  S && (k.preventDefault(), te(k));
307
307
  }, D = () => {
308
- R(!1);
308
+ $(!1);
309
309
  }, T = () => {
310
- R(!1);
310
+ $(!1);
311
311
  }, J = (k) => {
312
312
  k.preventDefault();
313
313
  }, Z = j(null);
@@ -316,38 +316,38 @@ const Jt = ({
316
316
  }, []), _(() => {
317
317
  const k = o.current;
318
318
  if (!k) return;
319
- const N = (W) => {
320
- var ee, $, U, ie;
321
- const H = W.detail, X = o.current;
322
- if (!X || !H) return;
323
- const q = H.orientation ?? t;
324
- if (typeof H.progress == "number")
319
+ const N = (A) => {
320
+ var ee, W, U, ie;
321
+ const P = A.detail, X = o.current;
322
+ if (!X || !P) return;
323
+ const q = P.orientation ?? t;
324
+ if (typeof P.progress == "number")
325
325
  if (q === "horizontal") {
326
326
  const de = Math.max(
327
327
  0,
328
328
  (((ee = p.current) == null ? void 0 : ee.width) ?? 0) - X.clientWidth
329
329
  );
330
- X.scrollLeft = Math.min(de, Math.max(0, H.progress * de));
330
+ X.scrollLeft = Math.min(de, Math.max(0, P.progress * de));
331
331
  } else {
332
332
  const de = Math.max(
333
333
  0,
334
- ((($ = p.current) == null ? void 0 : $.height) ?? 0) - X.clientHeight
334
+ (((W = p.current) == null ? void 0 : W.height) ?? 0) - X.clientHeight
335
335
  );
336
- X.scrollTop = Math.min(de, Math.max(0, H.progress * de));
336
+ X.scrollTop = Math.min(de, Math.max(0, P.progress * de));
337
337
  }
338
- else if (typeof H.scroll == "number")
338
+ else if (typeof P.scroll == "number")
339
339
  if (q === "horizontal") {
340
340
  const de = Math.max(
341
341
  0,
342
342
  (((U = p.current) == null ? void 0 : U.width) ?? 0) - X.clientWidth
343
343
  );
344
- X.scrollLeft = Math.min(de, Math.max(0, H.scroll));
344
+ X.scrollLeft = Math.min(de, Math.max(0, P.scroll));
345
345
  } else {
346
346
  const de = Math.max(
347
347
  0,
348
348
  (((ie = p.current) == null ? void 0 : ie.height) ?? 0) - X.clientHeight
349
349
  );
350
- X.scrollTop = Math.min(de, Math.max(0, H.scroll));
350
+ X.scrollTop = Math.min(de, Math.max(0, P.scroll));
351
351
  }
352
352
  };
353
353
  return k.addEventListener("udx:customScroll:set", N), () => {
@@ -358,14 +358,14 @@ const Jt = ({
358
358
  {
359
359
  className: I.customScroll,
360
360
  ref: o,
361
- onMouseDown: P,
361
+ onMouseDown: H,
362
362
  onMouseMove: C,
363
363
  onMouseUp: D,
364
364
  onMouseLeave: T,
365
365
  onDragStart: J,
366
366
  onScroll: (k) => {
367
- S || (E(null), R(!0), Z.current && clearTimeout(Z.current), Z.current = setTimeout(() => {
368
- R(!1);
367
+ S || (E(null), $(!0), Z.current && clearTimeout(Z.current), Z.current = setTimeout(() => {
368
+ $(!1);
369
369
  }, 1e3));
370
370
  },
371
371
  children: [
@@ -378,7 +378,7 @@ const Jt = ({
378
378
  children: e
379
379
  }
380
380
  ),
381
- h.current && p.current && /* @__PURE__ */ K(me, { children: [
381
+ h.current && p.current && /* @__PURE__ */ K(ye, { children: [
382
382
  t === "vertical" && p.current.height > h.current.height && /* @__PURE__ */ d(
383
383
  ne.div,
384
384
  {
@@ -545,7 +545,7 @@ var sn = class {
545
545
  destroy() {
546
546
  this.events = {};
547
547
  }
548
- }, Ye = 100 / 6, xe = { passive: !1 }, on = class {
548
+ }, Ye = 100 / 6, Se = { passive: !1 }, on = class {
549
549
  constructor(e, t = { wheelMultiplier: 1, touchMultiplier: 1 }) {
550
550
  B(this, "touchStart", {
551
551
  x: 0,
@@ -607,15 +607,15 @@ var sn = class {
607
607
  height: window.innerHeight
608
608
  };
609
609
  });
610
- this.element = e, this.options = t, window.addEventListener("resize", this.onWindowResize, !1), this.onWindowResize(), this.element.addEventListener("wheel", this.onWheel, xe), this.element.addEventListener(
610
+ this.element = e, this.options = t, window.addEventListener("resize", this.onWindowResize, !1), this.onWindowResize(), this.element.addEventListener("wheel", this.onWheel, Se), this.element.addEventListener(
611
611
  "touchstart",
612
612
  this.onTouchStart,
613
- xe
613
+ Se
614
614
  ), this.element.addEventListener(
615
615
  "touchmove",
616
616
  this.onTouchMove,
617
- xe
618
- ), this.element.addEventListener("touchend", this.onTouchEnd, xe);
617
+ Se
618
+ ), this.element.addEventListener("touchend", this.onTouchEnd, Se);
619
619
  }
620
620
  /**
621
621
  * Add an event listener for the given event and callback
@@ -628,18 +628,18 @@ var sn = class {
628
628
  }
629
629
  /** Remove all event listeners and clean up */
630
630
  destroy() {
631
- this.emitter.destroy(), window.removeEventListener("resize", this.onWindowResize, !1), this.element.removeEventListener("wheel", this.onWheel, xe), this.element.removeEventListener(
631
+ this.emitter.destroy(), window.removeEventListener("resize", this.onWindowResize, !1), this.element.removeEventListener("wheel", this.onWheel, Se), this.element.removeEventListener(
632
632
  "touchstart",
633
633
  this.onTouchStart,
634
- xe
634
+ Se
635
635
  ), this.element.removeEventListener(
636
636
  "touchmove",
637
637
  this.onTouchMove,
638
- xe
638
+ Se
639
639
  ), this.element.removeEventListener(
640
640
  "touchend",
641
641
  this.onTouchEnd,
642
- xe
642
+ Se
643
643
  );
644
644
  }
645
645
  }, _e = (e) => Math.min(1, 1.001 - Math.pow(2, -10 * e)), ln = class {
@@ -668,12 +668,12 @@ var sn = class {
668
668
  overscroll: b = !0,
669
669
  autoRaf: g = !1,
670
670
  anchors: O = !1,
671
- autoToggle: A = !1,
671
+ autoToggle: R = !1,
672
672
  // https://caniuse.com/?search=transition-behavior
673
673
  allowNestedScroll: v = !1,
674
674
  // @ts-ignore: this will be deprecated in the future
675
675
  __experimental__naiveDimensions: S = !1,
676
- naiveDimensions: R = S,
676
+ naiveDimensions: $ = S,
677
677
  stopInertiaOnNavigate: I = !1
678
678
  } = {}) {
679
679
  B(this, "_isScrolling", !1);
@@ -870,9 +870,9 @@ var sn = class {
870
870
  overscroll: b,
871
871
  autoRaf: g,
872
872
  anchors: O,
873
- autoToggle: A,
873
+ autoToggle: R,
874
874
  allowNestedScroll: v,
875
- naiveDimensions: R,
875
+ naiveDimensions: $,
876
876
  stopInertiaOnNavigate: I
877
877
  }, this.dimensions = new sn(e, t, { autoResize: x }), this.updateClassName(), this.targetScroll = this.animatedScroll = this.actualScroll, this.options.wrapper.addEventListener("scroll", this.onNativeScroll, !1), this.options.wrapper.addEventListener("scrollend", this.onScrollEnd, {
878
878
  capture: !0
@@ -1066,9 +1066,9 @@ var sn = class {
1066
1066
  const p = this.options.gestureOrientation;
1067
1067
  if (s - (r.time ?? 0) > 2e3) {
1068
1068
  r.time = Date.now();
1069
- const A = window.getComputedStyle(e);
1070
- r.computedStyle = A;
1071
- const v = A.overflowX, S = A.overflowY;
1069
+ const R = window.getComputedStyle(e);
1070
+ r.computedStyle = R;
1071
+ const v = R.overflowX, S = R.overflowY;
1072
1072
  if (c = ["auto", "overlay", "scroll"].includes(v), a = ["auto", "overlay", "scroll"].includes(S), r.hasOverflowX = c, r.hasOverflowY = a, !c && !a || p === "vertical" && !a || p === "horizontal" && !c) return !1;
1073
1073
  o = e.scrollWidth, u = e.scrollHeight, m = e.clientWidth, f = e.clientHeight, i = o > m, l = u > f, r.isScrollableX = i, r.isScrollableY = l, r.scrollWidth = o, r.scrollHeight = u, r.clientWidth = m, r.clientHeight = f;
1074
1074
  } else
@@ -1081,8 +1081,8 @@ var sn = class {
1081
1081
  else if (p === "vertical")
1082
1082
  h = "y";
1083
1083
  else {
1084
- const A = t !== 0, v = n !== 0;
1085
- A && c && i && (h = "x"), v && a && l && (h = "y");
1084
+ const R = t !== 0, v = n !== 0;
1085
+ R && c && i && (h = "x"), v && a && l && (h = "y");
1086
1086
  }
1087
1087
  if (!h) return !1;
1088
1088
  let x, w, M, b, g;
@@ -1207,8 +1207,8 @@ const Nr = ({
1207
1207
  var m;
1208
1208
  i.current !== null && cancelAnimationFrame(i.current), (m = a.current) == null || m.destroy(), a.current = null;
1209
1209
  };
1210
- }, [e, t, n, s, r]), c ? /* @__PURE__ */ d(me, { children: c }) : null;
1211
- }, Se = ({
1210
+ }, [e, t, n, s, r]), c ? /* @__PURE__ */ d(ye, { children: c }) : null;
1211
+ }, Ne = ({
1212
1212
  style: e,
1213
1213
  colorName: t,
1214
1214
  stateClassName: n = "state-ripple-group",
@@ -1350,7 +1350,7 @@ function fn() {
1350
1350
  function hn() {
1351
1351
  return typeof window > "u" || !("matchMedia" in window) ? !1 : window.matchMedia("(prefers-reduced-motion: reduce)").matches;
1352
1352
  }
1353
- function He(e) {
1353
+ function Pe(e) {
1354
1354
  if (!(e instanceof HTMLElement)) return !1;
1355
1355
  const t = e.classList;
1356
1356
  return Array.from(t).some(
@@ -1363,7 +1363,7 @@ function Xe(e) {
1363
1363
  return Array.from(t).some((n) => n.startsWith("anim-"));
1364
1364
  }
1365
1365
  function We(e, t) {
1366
- if (!He(e)) return;
1366
+ if (!Pe(e)) return;
1367
1367
  if (e.hasAttribute(`data-${t}-scroll`)) {
1368
1368
  const a = (e.getAttribute(`data-${t}-scroll`) || "").trim().toLowerCase(), i = a === "x" || a === "inline" ? "inline" : a === "y" || a === "block" ? "block" : "auto";
1369
1369
  e.classList.contains(`${t}-timeline`) || e.classList.contains(`${t}-timeline-inline`) || e.classList.contains(`${t}-timeline-block`) || e.classList.contains(`${t}-timeline-x`) || e.classList.contains(`${t}-timeline-y`) || (i === "inline" ? e.classList.add(`${t}-timeline-inline`) : i === "block" ? e.classList.add(`${t}-timeline-block`) : e.classList.add(`${t}-scroll`));
@@ -1380,7 +1380,7 @@ function Ae(e = document, t) {
1380
1380
  e.querySelectorAll(
1381
1381
  `[class*="${t}-"][class*="-scroll"]`
1382
1382
  )
1383
- ).filter((s) => He(s));
1383
+ ).filter((s) => Pe(s));
1384
1384
  }
1385
1385
  function pn(e = document, t) {
1386
1386
  const n = Array.from(
@@ -1404,7 +1404,7 @@ function pn(e = document, t) {
1404
1404
  const c = r.classList;
1405
1405
  return c.contains(`${t}-in`) || c.contains(`${t}-out`) || Array.from(c).some(
1406
1406
  (l) => l.startsWith(`${t}-`) && !l.includes("scroll") && !s.has(l)
1407
- ) ? !0 : !He(r);
1407
+ ) ? !0 : !Pe(r);
1408
1408
  });
1409
1409
  }
1410
1410
  function mn(e, t) {
@@ -1512,7 +1512,7 @@ const kr = ot, Ir = ot, it = ({
1512
1512
  children: n,
1513
1513
  style: s
1514
1514
  }) => {
1515
- const c = `--anchor-${Me().replace(/:/g, "")}`, [a, i] = V(!1);
1515
+ const c = `--anchor-${Ee().replace(/:/g, "")}`, [a, i] = V(!1);
1516
1516
  if ($e(() => {
1517
1517
  typeof CSS < "u" && CSS.supports("anchor-name", "--a") && i(!0);
1518
1518
  }, []), $e(() => {
@@ -2039,7 +2039,7 @@ const kr = ot, Ir = ot, it = ({
2039
2039
  ],
2040
2040
  !!t && "text-on-surface/[0.38]"
2041
2041
  )
2042
- }), Pr = oe(
2042
+ }), Hr = oe(
2043
2043
  "iconButton",
2044
2044
  vt
2045
2045
  ), Mn = re(
@@ -2074,7 +2074,7 @@ const kr = ot, Ir = ot, it = ({
2074
2074
  "max-h-full": t
2075
2075
  }
2076
2076
  )
2077
- }), Hr = oe(
2077
+ }), Pr = oe(
2078
2078
  "progressIndicator",
2079
2079
  gt
2080
2080
  ), En = re(
@@ -2383,7 +2383,7 @@ const kr = ot, Ir = ot, it = ({
2383
2383
  }), Ur = oe(
2384
2384
  "textField",
2385
2385
  Mt
2386
- ), Pn = re(
2386
+ ), Hn = re(
2387
2387
  "textField",
2388
2388
  Mt
2389
2389
  ), Et = ({
@@ -2417,10 +2417,10 @@ const kr = ot, Ir = ot, it = ({
2417
2417
  }), jr = oe(
2418
2418
  "toolTip",
2419
2419
  Et
2420
- ), Hn = re(
2420
+ ), Pn = re(
2421
2421
  "toolTip",
2422
2422
  Et
2423
- ), fe = ({
2423
+ ), he = ({
2424
2424
  icon: e,
2425
2425
  colors: t = [],
2426
2426
  className: n,
@@ -2531,7 +2531,7 @@ const kr = ot, Ir = ot, it = ({
2531
2531
  transitionDuration: n,
2532
2532
  isVisible: m
2533
2533
  });
2534
- return /* @__PURE__ */ K(me, { children: [
2534
+ return /* @__PURE__ */ K(ye, { children: [
2535
2535
  (e === "linear-determinate" || e == "linear-indeterminate") && /* @__PURE__ */ K("div", { className: p.progressIndicator, ...r, children: [
2536
2536
  /* @__PURE__ */ d(
2537
2537
  "div",
@@ -2621,7 +2621,7 @@ function zn(e) {
2621
2621
  };
2622
2622
  return e && e in t ? t[e] : e || "filled";
2623
2623
  }
2624
- const Ne = ({
2624
+ const Le = ({
2625
2625
  variant: e = "filled",
2626
2626
  disabled: t = !1,
2627
2627
  icon: n,
@@ -2647,11 +2647,11 @@ const Ne = ({
2647
2647
  "Button component requires either a label prop or children content"
2648
2648
  );
2649
2649
  e = zn(e);
2650
- const g = s ? "a" : "button", O = j(null), A = p || O, [v, S] = Q.useState(f);
2650
+ const g = s ? "a" : "button", O = j(null), R = p || O, [v, S] = Q.useState(f);
2651
2651
  _(() => {
2652
2652
  S(f);
2653
2653
  }, [f]), w = { duration: 0.3, ...w };
2654
- const R = (E) => {
2654
+ const $ = (E) => {
2655
2655
  t && E.preventDefault(), m ? (S(!v), m(!v)) : u && u(E);
2656
2656
  }, I = vn({
2657
2657
  allowShapeTransformation: x,
@@ -2671,22 +2671,22 @@ const Ne = ({
2671
2671
  activated: v,
2672
2672
  label: r,
2673
2673
  children: r
2674
- }), F = n ? /* @__PURE__ */ d(fe, { icon: n, className: I.icon }) : /* @__PURE__ */ d(me, {});
2674
+ }), F = n ? /* @__PURE__ */ d(he, { icon: n, className: I.icon }) : /* @__PURE__ */ d(ye, {});
2675
2675
  return /* @__PURE__ */ K(
2676
2676
  g,
2677
2677
  {
2678
- ref: A,
2678
+ ref: R,
2679
2679
  href: s,
2680
2680
  className: I.button,
2681
2681
  ...b,
2682
- onClick: R,
2682
+ onClick: $,
2683
2683
  disabled: t,
2684
2684
  "aria-pressed": m ? v : void 0,
2685
2685
  style: { transition: w.duration + "s" },
2686
2686
  children: [
2687
2687
  /* @__PURE__ */ d("div", { className: I.touchTarget }),
2688
2688
  /* @__PURE__ */ d(
2689
- Se,
2689
+ Ne,
2690
2690
  {
2691
2691
  style: { transition: w.duration + "s" },
2692
2692
  className: I.stateLayer,
@@ -2771,7 +2771,7 @@ const Ne = ({
2771
2771
  }), i = j(null);
2772
2772
  return /* @__PURE__ */ K("div", { ...c, ref: r || i, className: a.card, children: [
2773
2773
  s && /* @__PURE__ */ d(
2774
- Se,
2774
+ Ne,
2775
2775
  {
2776
2776
  className: a.stateLayer,
2777
2777
  colorName: "on-surface",
@@ -2780,7 +2780,7 @@ const Ne = ({
2780
2780
  ),
2781
2781
  n
2782
2782
  ] });
2783
- }, Le = (e, t, n = [0, 1]) => {
2783
+ }, ke = (e, t, n = [0, 1]) => {
2784
2784
  const [s, r] = t, [c, a] = n, l = (Math.max(s, Math.min(e, r)) - s) / (r - s);
2785
2785
  return c + l * (a - c);
2786
2786
  }, Tn = ({
@@ -2847,36 +2847,36 @@ const Ne = ({
2847
2847
  onMetricsChange: o
2848
2848
  }), b = Q.Children.toArray(n).filter(
2849
2849
  (N) => Q.isValidElement(N) && N.type === Tn
2850
- ), g = j(null), [O, A] = V(
2850
+ ), g = j(null), [O, R] = V(
2851
2851
  {}
2852
- ), [v, S] = V(null), R = j(0), I = j(null), F = () => {
2853
- var be, ce;
2852
+ ), [v, S] = V(null), $ = j(0), I = j(null), F = () => {
2853
+ var xe, ce;
2854
2854
  if (!g.current || !h.current || (v == null ? void 0 : v.scrollProgress) === void 0)
2855
2855
  return [];
2856
- const N = (v == null ? void 0 : v.scrollVisible) ?? ((be = h.current) == null ? void 0 : be.clientWidth) ?? 0;
2857
- function W(G, ae) {
2858
- return G.map((le, ge) => {
2859
- const Ee = (le - ae) / Math.abs(G[1] - G[0]);
2856
+ const N = (v == null ? void 0 : v.scrollVisible) ?? ((xe = h.current) == null ? void 0 : xe.clientWidth) ?? 0;
2857
+ function A(G, ae) {
2858
+ return G.map((le, we) => {
2859
+ const Ce = (le - ae) / Math.abs(G[1] - G[0]);
2860
2860
  return {
2861
2861
  itemScrollXCenter: le,
2862
- relativeIndex: Ee,
2863
- index: ge,
2862
+ relativeIndex: Ce,
2863
+ index: we,
2864
2864
  width: 0
2865
2865
  };
2866
2866
  });
2867
2867
  }
2868
- const H = b.map((G, ae) => {
2868
+ const P = b.map((G, ae) => {
2869
2869
  if (!E[ae].current || !g.current) return 0;
2870
- const ge = ae / (b.length - 1);
2871
- return Le(ge, [0, 1], [0, 1]);
2872
- }), X = W(
2873
- H,
2870
+ const we = ae / (b.length - 1);
2871
+ return ke(we, [0, 1], [0, 1]);
2872
+ }), X = A(
2873
+ P,
2874
2874
  (v == null ? void 0 : v.scrollProgress) ?? 0
2875
2875
  ).sort((G, ae) => G.index - ae.index);
2876
2876
  let q = (((ce = h.current) == null ? void 0 : ce.clientWidth) ?? N) + i + a[0] + i;
2877
2877
  const ee = X.sort((G, ae) => Math.abs(G.relativeIndex) - Math.abs(ae.relativeIndex)).map((G, ae) => {
2878
2878
  if (!(q <= 0)) {
2879
- if (ae == 0 && z(G.index), G.width = Le(
2879
+ if (ae == 0 && z(G.index), G.width = ke(
2880
2880
  q - i,
2881
2881
  [a[0], a[1]],
2882
2882
  [a[0], a[1]]
@@ -2889,25 +2889,25 @@ const Ne = ({
2889
2889
  }
2890
2890
  return G;
2891
2891
  }
2892
- }).filter(Boolean), $ = ee.reverse(), U = [...ee].sort(
2892
+ }).filter(Boolean), W = ee.reverse(), U = [...ee].sort(
2893
2893
  (G, ae) => Math.abs(G.index) - Math.abs(ae.index)
2894
2894
  );
2895
- $.forEach((G, ae) => {
2896
- const le = $[ae + 1];
2895
+ W.forEach((G, ae) => {
2896
+ const le = W[ae + 1];
2897
2897
  if (!le) return;
2898
- const ge = 1 - (Math.abs(G.relativeIndex) - Math.abs(le == null ? void 0 : le.relativeIndex)), Ee = Le(
2899
- ge,
2898
+ const we = 1 - (Math.abs(G.relativeIndex) - Math.abs(le == null ? void 0 : le.relativeIndex)), Ce = ke(
2899
+ we,
2900
2900
  [0, 2],
2901
2901
  [G.width + q, le.width]
2902
2902
  );
2903
- q += G.width, G.width = Ee, q -= G.width;
2903
+ q += G.width, G.width = Ce, q -= G.width;
2904
2904
  });
2905
- const ie = ee.length / 2, de = Le(
2905
+ const ie = ee.length / 2, de = ke(
2906
2906
  Math.abs(U[0].relativeIndex),
2907
2907
  [U[0].index == 0 ? 0 : ie - 1, ie],
2908
2908
  [0, 1]
2909
- ), ye = Le(de, [0, 1], [0, 1]) * -(a[0] + i);
2910
- return w(ye), Object.fromEntries(
2909
+ ), ve = ke(de, [0, 1], [0, 1]) * -(a[0] + i);
2910
+ return w(ve), Object.fromEntries(
2911
2911
  ee.map((G) => [G.index, G.width])
2912
2912
  );
2913
2913
  }, E = j([]).current, [Y, z] = V(0);
@@ -2916,55 +2916,55 @@ const Ne = ({
2916
2916
  }, [Y]), _(() => {
2917
2917
  typeof u == "number" && b.length > 0 && u !== Y && C(u);
2918
2918
  }, [u, b.length]), _(() => {
2919
- P(Y);
2920
- }, [Y]), E.length !== b.length && b.forEach((N, W) => {
2921
- E[W] || (E[W] = Q.createRef());
2919
+ H(Y);
2920
+ }, [Y]), E.length !== b.length && b.forEach((N, A) => {
2921
+ E[A] || (E[A] = Q.createRef());
2922
2922
  });
2923
- const [te, P] = V(0), C = (N, W = {}) => {
2923
+ const [te, H] = V(0), C = (N, A = {}) => {
2924
2924
  if (!b.length) return 0;
2925
- const H = E[N];
2926
- if (!H || !H.current || !g.current) return 0;
2927
- const X = Le(
2925
+ const P = E[N];
2926
+ if (!P || !P.current || !g.current) return 0;
2927
+ const X = ke(
2928
2928
  N / Math.max(1, b.length - 1),
2929
2929
  [0, 1],
2930
2930
  [0, 1]
2931
2931
  );
2932
- return P(N), g.current.dispatchEvent(
2932
+ return H(N), g.current.dispatchEvent(
2933
2933
  new CustomEvent("udx:customScroll:set", {
2934
2934
  bubbles: !0,
2935
2935
  detail: {
2936
2936
  progress: X,
2937
2937
  orientation: "horizontal",
2938
- animate: W.animate !== !1
2938
+ animate: A.animate !== !1
2939
2939
  }
2940
2940
  })
2941
2941
  ), X;
2942
- }, D = b.map((N, W) => {
2942
+ }, D = b.map((N, A) => {
2943
2943
  var ee;
2944
- const H = (ee = N.props) == null ? void 0 : ee.onClick, X = ($) => {
2945
- H == null || H($);
2946
- }, q = () => P(W);
2944
+ const P = (ee = N.props) == null ? void 0 : ee.onClick, X = (W) => {
2945
+ P == null || P(W);
2946
+ }, q = () => H(A);
2947
2947
  return Q.cloneElement(
2948
2948
  N,
2949
2949
  {
2950
- width: O[W],
2950
+ width: O[A],
2951
2951
  outputRange: a,
2952
- ref: E[W],
2953
- key: W,
2954
- index: W,
2952
+ ref: E[A],
2953
+ key: A,
2954
+ index: A,
2955
2955
  role: "option",
2956
- "aria-selected": Y === W,
2957
- tabIndex: Y === W ? 0 : -1,
2956
+ "aria-selected": Y === A,
2957
+ tabIndex: Y === A ? 0 : -1,
2958
2958
  onClick: X,
2959
2959
  onFocus: q
2960
2960
  }
2961
2961
  );
2962
2962
  }), T = (N) => {
2963
- var W;
2963
+ var A;
2964
2964
  if (N.scrollTotal > 0) {
2965
- (W = I.current) == null || W.stop();
2966
- const H = R.current ?? 0, X = N.scrollProgress ?? 0;
2967
- I.current = Ot(H, X, {
2965
+ (A = I.current) == null || A.stop();
2966
+ const P = $.current ?? 0, X = N.scrollProgress ?? 0;
2967
+ I.current = Ot(P, X, {
2968
2968
  // Spring tuning to add a bit of inertia and smoothness
2969
2969
  type: "spring",
2970
2970
  stiffness: 260,
@@ -2972,14 +2972,14 @@ const Ne = ({
2972
2972
  mass: 0.6,
2973
2973
  restDelta: 5e-4,
2974
2974
  onUpdate: (q) => {
2975
- R.current = q, S({ ...N, scrollProgress: q });
2975
+ $.current = q, S({ ...N, scrollProgress: q });
2976
2976
  }
2977
2977
  });
2978
2978
  }
2979
2979
  };
2980
2980
  _(() => {
2981
2981
  const N = F();
2982
- A(N);
2982
+ R(N);
2983
2983
  }, [v]);
2984
2984
  const J = j(o);
2985
2985
  _(() => {
@@ -2990,33 +2990,33 @@ const Ne = ({
2990
2990
  var ae;
2991
2991
  const N = J.current;
2992
2992
  if (!N || !(h != null && h.current)) return;
2993
- const W = b.length;
2994
- if (W <= 0) return;
2995
- const H = ((ae = h.current) == null ? void 0 : ae.clientWidth) ?? 0, X = a[1], q = R.current ?? (v == null ? void 0 : v.scrollProgress) ?? 0, ee = (H + i) / (X + i), $ = Math.max(1, Math.floor(ee)), U = Math.max(1, Math.round($ * (2 / 3))), ie = Math.min(
2993
+ const A = b.length;
2994
+ if (A <= 0) return;
2995
+ const P = ((ae = h.current) == null ? void 0 : ae.clientWidth) ?? 0, X = a[1], q = $.current ?? (v == null ? void 0 : v.scrollProgress) ?? 0, ee = (P + i) / (X + i), W = Math.max(1, Math.floor(ee)), U = Math.max(1, Math.round(W * (2 / 3))), ie = Math.min(
2996
2996
  Math.max(0, Y),
2997
- Math.max(0, W - 1)
2998
- ), de = ie > 0, ye = ie < W - 1, be = {
2999
- total: W,
2997
+ Math.max(0, A - 1)
2998
+ ), de = ie > 0, ve = ie < A - 1, xe = {
2999
+ total: A,
3000
3000
  selectedIndex: ie,
3001
3001
  visibleApprox: ee,
3002
- visibleFull: $,
3002
+ visibleFull: W,
3003
3003
  stepHalf: U,
3004
3004
  canPrev: de,
3005
- canNext: ye,
3005
+ canNext: ve,
3006
3006
  scrollProgress: q,
3007
- viewportWidth: H,
3007
+ viewportWidth: P,
3008
3008
  itemMaxWidth: X,
3009
3009
  gap: i
3010
3010
  }, ce = Z.current;
3011
3011
  let G = !ce;
3012
3012
  if (!G) {
3013
- for (const le in be)
3014
- if (be[le] !== ce[le]) {
3013
+ for (const le in xe)
3014
+ if (xe[le] !== ce[le]) {
3015
3015
  G = !0;
3016
3016
  break;
3017
3017
  }
3018
3018
  }
3019
- G && (Z.current = be, N(be));
3019
+ G && (Z.current = xe, N(xe));
3020
3020
  }, [h, b.length, Y, v, i, a]), _(() => () => {
3021
3021
  var N;
3022
3022
  (N = I.current) == null || N.stop();
@@ -3025,18 +3025,18 @@ const Ne = ({
3025
3025
  $e(() => {
3026
3026
  let N = a[1];
3027
3027
  v && N > v.scrollVisible && (N = v.scrollVisible);
3028
- const W = (N + i) * D.length / m;
3029
- L(W);
3028
+ const A = (N + i) * D.length / m;
3029
+ L(A);
3030
3030
  }, [h, E, v]);
3031
3031
  const k = (N) => {
3032
3032
  if (!b.length) return;
3033
- const W = te ?? Y;
3033
+ const A = te ?? Y;
3034
3034
  switch (N.key) {
3035
3035
  case "ArrowLeft":
3036
- N.preventDefault(), C(Math.max(0, W - 1));
3036
+ N.preventDefault(), C(Math.max(0, A - 1));
3037
3037
  break;
3038
3038
  case "ArrowRight":
3039
- N.preventDefault(), C(Math.min(b.length - 1, W + 1));
3039
+ N.preventDefault(), C(Math.min(b.length - 1, A + 1));
3040
3040
  break;
3041
3041
  case "Home":
3042
3042
  N.preventDefault(), C(0);
@@ -3046,21 +3046,21 @@ const Ne = ({
3046
3046
  break;
3047
3047
  case "Enter":
3048
3048
  case " ":
3049
- N.preventDefault(), C(W);
3049
+ N.preventDefault(), C(A);
3050
3050
  break;
3051
3051
  }
3052
3052
  };
3053
3053
  return _(() => {
3054
3054
  const N = h.current;
3055
3055
  if (!N) return;
3056
- const W = (H) => {
3057
- const X = H.detail;
3056
+ const A = (P) => {
3057
+ const X = P.detail;
3058
3058
  X && typeof X.index == "number" && C(X.index);
3059
3059
  };
3060
- return N.addEventListener("udx:carousel:centerIndex", W), () => {
3060
+ return N.addEventListener("udx:carousel:centerIndex", A), () => {
3061
3061
  N.removeEventListener(
3062
3062
  "udx:carousel:centerIndex",
3063
- W
3063
+ A
3064
3064
  );
3065
3065
  };
3066
3066
  }, [h, b.length]), /* @__PURE__ */ d(
@@ -3153,13 +3153,13 @@ const Jr = ({
3153
3153
  className: u,
3154
3154
  ...m
3155
3155
  }) => {
3156
- const f = Me(), p = a || f, h = e !== void 0, [x, w] = V(
3156
+ const f = Ee(), p = a || f, h = e !== void 0, [x, w] = V(
3157
3157
  t ?? !1
3158
3158
  ), M = h ? e : x, [b, g] = V(!1), O = Q.useRef(null);
3159
3159
  _(() => {
3160
3160
  O.current && (O.current.indeterminate = n);
3161
3161
  }, [n]);
3162
- const A = (S) => {
3162
+ const R = (S) => {
3163
3163
  s || (h || w(S.target.checked), c && c(S));
3164
3164
  }, v = xn({
3165
3165
  isChecked: !!M,
@@ -3176,7 +3176,7 @@ const Jr = ({
3176
3176
  className: y(v.checkbox, u, "group/checkbox"),
3177
3177
  style: o,
3178
3178
  children: /* @__PURE__ */ K(
3179
- Se,
3179
+ Ne,
3180
3180
  {
3181
3181
  stateClassName: v.stateLayer,
3182
3182
  colorName: M || n ? "primary" : "on-surface",
@@ -3191,7 +3191,7 @@ const Jr = ({
3191
3191
  value: l,
3192
3192
  checked: M,
3193
3193
  disabled: s,
3194
- onChange: A,
3194
+ onChange: R,
3195
3195
  onFocus: () => g(!0),
3196
3196
  onBlur: () => g(!1),
3197
3197
  className: v.input,
@@ -3199,7 +3199,7 @@ const Jr = ({
3199
3199
  }
3200
3200
  ),
3201
3201
  /* @__PURE__ */ d("div", { className: v.box }),
3202
- /* @__PURE__ */ d(he, { children: (M || n) && /* @__PURE__ */ d(
3202
+ /* @__PURE__ */ d(pe, { children: (M || n) && /* @__PURE__ */ d(
3203
3203
  ne.div,
3204
3204
  {
3205
3205
  initial: { opacity: 0, scale: 0.5 },
@@ -3208,7 +3208,7 @@ const Jr = ({
3208
3208
  transition: { duration: 0.15 },
3209
3209
  className: v.icon,
3210
3210
  children: /* @__PURE__ */ d(
3211
- fe,
3211
+ he,
3212
3212
  {
3213
3213
  icon: n ? Vn : Ct,
3214
3214
  className: "size-3.5"
@@ -3247,33 +3247,33 @@ const Jr = ({
3247
3247
  throw new Error(
3248
3248
  "Chip component requires either a label prop or children content"
3249
3249
  );
3250
- const O = s ? "a" : "button", A = j(null), v = o || A, [S, R] = Q.useState(l), [I, F] = Q.useState(!1), [E, Y] = V(b && m), [z, te] = Q.useState(!1), [P, C] = Q.useState(
3250
+ const O = s ? "a" : "button", R = j(null), v = o || R, [S, $] = Q.useState(l), [I, F] = Q.useState(!1), [E, Y] = V(b && m), [z, te] = Q.useState(!1), [H, C] = Q.useState(
3251
3251
  typeof r == "string" ? r : ""
3252
3252
  ), D = Q.useRef(null);
3253
3253
  _(() => {
3254
- R(l);
3254
+ $(l);
3255
3255
  }, [l]), _(() => {
3256
3256
  if (b && Y(b), m && I) {
3257
- const $ = setTimeout(() => {
3257
+ const W = setTimeout(() => {
3258
3258
  g != null && g.draggable && z || Y(!0);
3259
3259
  }, 1e3);
3260
- return () => clearTimeout($);
3260
+ return () => clearTimeout(W);
3261
3261
  } else I || Y(!1);
3262
- }, [I, m, z, g, P]), _(() => {
3262
+ }, [I, m, z, g, H]), _(() => {
3263
3263
  if (E) {
3264
3264
  C(typeof r == "string" ? r : "");
3265
- const $ = q.current || D.current;
3266
- if ($) {
3267
- $.focus();
3265
+ const W = q.current || D.current;
3266
+ if (W) {
3267
+ W.focus();
3268
3268
  const U = document.createRange();
3269
- U.selectNodeContents($), U.collapse(!1);
3269
+ U.selectNodeContents(W), U.collapse(!1);
3270
3270
  const ie = window.getSelection();
3271
3271
  ie == null || ie.removeAllRanges(), ie == null || ie.addRange(U);
3272
3272
  }
3273
3273
  }
3274
3274
  }, [E]), w = { duration: 0.3, ...w };
3275
- const T = ($) => {
3276
- t && $.preventDefault(), i ? (R(!S), i(!S)) : a && a($);
3275
+ const T = (W) => {
3276
+ t && W.preventDefault(), i ? ($(!S), i(!S)) : a && a(W);
3277
3277
  }, J = !!i || !!u || !!a || !!s || !!m;
3278
3278
  l && (n = Ct);
3279
3279
  const {
@@ -3282,8 +3282,8 @@ const Jr = ({
3282
3282
  onKeyDown: L,
3283
3283
  onDragStart: k,
3284
3284
  onDragEnd: N,
3285
- onDoubleClick: W,
3286
- ...H
3285
+ onDoubleClick: A,
3286
+ ...P
3287
3287
  } = g ?? {}, X = Sn({
3288
3288
  href: s,
3289
3289
  disabled: t,
@@ -3302,12 +3302,12 @@ const Jr = ({
3302
3302
  onEditCommit: p,
3303
3303
  isEditing: E
3304
3304
  }), q = j(null), ee = () => {
3305
- const $ = (P ?? "").trim();
3306
- if (!$) {
3305
+ const W = (H ?? "").trim();
3306
+ if (!W) {
3307
3307
  u && u();
3308
3308
  return;
3309
3309
  }
3310
- p == null || p($);
3310
+ p == null || p(W);
3311
3311
  };
3312
3312
  return /* @__PURE__ */ K(
3313
3313
  O,
@@ -3316,52 +3316,52 @@ const Jr = ({
3316
3316
  ref: v,
3317
3317
  href: s,
3318
3318
  className: X.chip,
3319
- ...H,
3320
- onClick: ($) => {
3321
- E || T($);
3319
+ ...P,
3320
+ onClick: (W) => {
3321
+ E || T(W);
3322
3322
  },
3323
3323
  draggable: !t && !!(g != null && g.draggable),
3324
- onDragStart: ($) => {
3325
- !t && (g != null && g.draggable) && te(!0), k == null || k($);
3324
+ onDragStart: (W) => {
3325
+ !t && (g != null && g.draggable) && te(!0), k == null || k(W);
3326
3326
  },
3327
- onDragEnd: ($) => {
3328
- g != null && g.draggable && te(!1), N == null || N($);
3327
+ onDragEnd: (W) => {
3328
+ g != null && g.draggable && te(!1), N == null || N(W);
3329
3329
  },
3330
- onDoubleClick: ($) => {
3331
- !t && m && !E && (f == null || f(), $.preventDefault(), $.stopPropagation()), W == null || W($);
3330
+ onDoubleClick: (W) => {
3331
+ !t && m && !E && (f == null || f(), W.preventDefault(), W.stopPropagation()), A == null || A(W);
3332
3332
  },
3333
- onFocus: ($) => {
3334
- J && F(!0), Z == null || Z($);
3333
+ onFocus: (W) => {
3334
+ J && F(!0), Z == null || Z(W);
3335
3335
  },
3336
- onBlur: ($) => {
3337
- F(!1), se == null || se($);
3336
+ onBlur: (W) => {
3337
+ F(!1), se == null || se(W);
3338
3338
  },
3339
- onKeyDown: ($) => {
3340
- const U = $.key;
3339
+ onKeyDown: (W) => {
3340
+ const U = W.key;
3341
3341
  if (!t && E) {
3342
- U === "Enter" ? ($.preventDefault(), ee()) : U === "Escape" ? ($.preventDefault(), h == null || h()) : u && (P == null ? void 0 : P.trim()) === "" && (U === "Backspace" || U === "Delete" || U === "Del") && ($.preventDefault(), $.stopPropagation(), u());
3342
+ U === "Enter" ? (W.preventDefault(), ee()) : U === "Escape" ? (W.preventDefault(), h == null || h()) : u && (H == null ? void 0 : H.trim()) === "" && (U === "Backspace" || U === "Delete" || U === "Del") && (W.preventDefault(), W.stopPropagation(), u());
3343
3343
  return;
3344
3344
  }
3345
3345
  if (!t && I) {
3346
3346
  if (m && !i && (U === "F2" || U === "Enter")) {
3347
- $.preventDefault(), f == null || f();
3347
+ W.preventDefault(), f == null || f();
3348
3348
  return;
3349
3349
  }
3350
3350
  if (i && (U === "Enter" || U === " " || U === "Spacebar")) {
3351
- $.preventDefault();
3351
+ W.preventDefault();
3352
3352
  const ie = !S;
3353
- R(ie), i(ie);
3353
+ $(ie), i(ie);
3354
3354
  }
3355
- u && (U === "Backspace" || U === "Delete" || U === "Del") && ($.preventDefault(), $.stopPropagation(), u());
3355
+ u && (U === "Backspace" || U === "Delete" || U === "Del") && (W.preventDefault(), W.stopPropagation(), u());
3356
3356
  }
3357
- L == null || L($);
3357
+ L == null || L(W);
3358
3358
  },
3359
3359
  disabled: t,
3360
3360
  "aria-pressed": i ? S : void 0,
3361
3361
  style: { transition: w.duration + "s" },
3362
3362
  children: [
3363
3363
  J && !t && !E && /* @__PURE__ */ d(
3364
- Se,
3364
+ Ne,
3365
3365
  {
3366
3366
  style: { transition: w.duration + "s" },
3367
3367
  className: X.stateLayer,
@@ -3372,7 +3372,7 @@ const Jr = ({
3372
3372
  stateClassName: "state-ripple-group-[chip]"
3373
3373
  }
3374
3374
  ),
3375
- n && /* @__PURE__ */ d(fe, { icon: n, className: X.leadingIcon }),
3375
+ n && /* @__PURE__ */ d(he, { icon: n, className: X.leadingIcon }),
3376
3376
  /* @__PURE__ */ d(
3377
3377
  "span",
3378
3378
  {
@@ -3382,33 +3382,33 @@ const Jr = ({
3382
3382
  className: X.label,
3383
3383
  role: m ? "textbox" : void 0,
3384
3384
  spellCheck: !1,
3385
- onInput: ($) => {
3386
- const U = $.currentTarget.innerText;
3385
+ onInput: (W) => {
3386
+ const U = W.currentTarget.innerText;
3387
3387
  C(U), x == null || x(U);
3388
3388
  },
3389
- onBlur: ($) => {
3389
+ onBlur: (W) => {
3390
3390
  m && E && ee();
3391
3391
  },
3392
- onKeyDown: ($) => {
3393
- if (m && E && $.key === "Enter") {
3394
- $.preventDefault(), $.stopPropagation(), ee();
3392
+ onKeyDown: (W) => {
3393
+ if (m && E && W.key === "Enter") {
3394
+ W.preventDefault(), W.stopPropagation(), ee();
3395
3395
  return;
3396
3396
  }
3397
- m && E && $.key === "Escape" && ($.preventDefault(), $.stopPropagation(), h == null || h());
3397
+ m && E && W.key === "Escape" && (W.preventDefault(), W.stopPropagation(), h == null || h());
3398
3398
  },
3399
3399
  children: r
3400
3400
  }
3401
3401
  ),
3402
3402
  u && !E && /* @__PURE__ */ d(
3403
- fe,
3403
+ he,
3404
3404
  {
3405
3405
  icon: De,
3406
3406
  className: X.trailingIcon,
3407
- onMouseDown: ($) => {
3408
- $.preventDefault(), $.stopPropagation();
3407
+ onMouseDown: (W) => {
3408
+ W.preventDefault(), W.stopPropagation();
3409
3409
  },
3410
- onClick: ($) => {
3411
- $.stopPropagation(), t || u();
3410
+ onClick: (W) => {
3411
+ W.stopPropagation(), t || u();
3412
3412
  }
3413
3413
  }
3414
3414
  )
@@ -3459,8 +3459,8 @@ const Zr = ({
3459
3459
  }) => {
3460
3460
  const a = r ?? [], i = Q.useRef(null), [l, o] = Q.useState(!1), u = Q.useRef(/* @__PURE__ */ new WeakMap()), m = Q.useCallback((v) => {
3461
3461
  const S = u.current;
3462
- let R = S.get(v);
3463
- return R || (R = Rt(), S.set(v, R)), R;
3462
+ let $ = S.get(v);
3463
+ return $ || ($ = Rt(), S.set(v, $)), $;
3464
3464
  }, []);
3465
3465
  Q.useEffect(() => {
3466
3466
  var v, S;
@@ -3473,7 +3473,7 @@ const Zr = ({
3473
3473
  [c, a]
3474
3474
  ), x = Q.useCallback(
3475
3475
  (v) => {
3476
- h((S) => S.filter((R, I) => I !== v));
3476
+ h((S) => S.filter(($, I) => I !== v));
3477
3477
  },
3478
3478
  [h]
3479
3479
  ), w = Nn({
@@ -3486,9 +3486,9 @@ const Zr = ({
3486
3486
  p.current = !0;
3487
3487
  const S = {
3488
3488
  label: v
3489
- }, R = m(S), I = [...a, S];
3489
+ }, $ = m(S), I = [...a, S];
3490
3490
  c == null || c(I), requestAnimationFrame(() => {
3491
- g(R), p.current = !1;
3491
+ g($), p.current = !1;
3492
3492
  });
3493
3493
  },
3494
3494
  [e, c, a, m]
@@ -3497,17 +3497,17 @@ const Zr = ({
3497
3497
  var v;
3498
3498
  if (b) {
3499
3499
  const S = a.findIndex(
3500
- (R) => m(R) === b
3500
+ ($) => m($) === b
3501
3501
  );
3502
3502
  if (S !== -1) {
3503
- const R = f.current[S];
3504
- (v = R == null ? void 0 : R.focus) == null || v.call(R);
3505
- const I = i.current, F = R.offsetLeft + R.offsetWidth / 2 - I.offsetWidth / 2;
3503
+ const $ = f.current[S];
3504
+ (v = $ == null ? void 0 : $.focus) == null || v.call($);
3505
+ const I = i.current, F = $.offsetLeft + $.offsetWidth / 2 - I.offsetWidth / 2;
3506
3506
  I.scrollTo({ left: F, behavior: "smooth" });
3507
3507
  }
3508
3508
  }
3509
3509
  }, [b, a, m]);
3510
- const O = j(null), A = (l || a.length === 0) && e === "input";
3510
+ const O = j(null), R = (l || a.length === 0) && e === "input";
3511
3511
  return /* @__PURE__ */ K(
3512
3512
  "div",
3513
3513
  {
@@ -3564,9 +3564,9 @@ const Zr = ({
3564
3564
  },
3565
3565
  children: [
3566
3566
  a.map((v, S) => {
3567
- const R = m(v), I = e === "input", F = I ? {
3567
+ const $ = m(v), I = e === "input", F = I ? {
3568
3568
  editable: !0,
3569
- editing: b === R,
3569
+ editing: b === $,
3570
3570
  onEditCommit: (E) => {
3571
3571
  o(!0), h(
3572
3572
  (Y) => Y.map(
@@ -3604,16 +3604,16 @@ const Zr = ({
3604
3604
  )
3605
3605
  ),
3606
3606
  onBlur: () => {
3607
- b === R && g(null);
3607
+ b === $ && g(null);
3608
3608
  },
3609
3609
  onRemove: I ? () => {
3610
3610
  o(!0), x(S);
3611
3611
  } : void 0
3612
3612
  },
3613
- R
3613
+ $
3614
3614
  );
3615
3615
  }),
3616
- l && /* @__PURE__ */ K(me, { children: [
3616
+ l && /* @__PURE__ */ K(ye, { children: [
3617
3617
  /* @__PURE__ */ d(
3618
3618
  Dt,
3619
3619
  {
@@ -3631,7 +3631,7 @@ const Zr = ({
3631
3631
  }
3632
3632
  ` })
3633
3633
  ] }),
3634
- A && /* @__PURE__ */ d(
3634
+ R && /* @__PURE__ */ d(
3635
3635
  Ge,
3636
3636
  {
3637
3637
  ref: O,
@@ -3644,8 +3644,8 @@ const Zr = ({
3644
3644
  if (v = v.replace(/(&nbsp;)+/g, " ").trim(), console.log("Ghost chip onChange", v, !!v), v)
3645
3645
  M(v);
3646
3646
  else if (a.length > 0) {
3647
- const R = f.current[a.length - 1];
3648
- (S = R == null ? void 0 : R.focus) == null || S.call(R);
3647
+ const $ = f.current[a.length - 1];
3648
+ (S = $ == null ? void 0 : $.focus) == null || S.call($);
3649
3649
  }
3650
3650
  },
3651
3651
  onEditCommit: () => {
@@ -3672,13 +3672,13 @@ function er({
3672
3672
  closeDelay: c = 150,
3673
3673
  id: a
3674
3674
  } = {}) {
3675
- const i = Me(), l = a ?? `tooltip-${i}`, o = Array.isArray(e) ? e : [e], u = typeof t == "boolean", [m, f] = V(
3675
+ const i = Ee(), l = a ?? `tooltip-${i}`, o = Array.isArray(e) ? e : [e], u = typeof t == "boolean", [m, f] = V(
3676
3676
  n ? "hovered" : "hidden"
3677
- ), [p, h] = V(!1), x = j(null), w = j(null), M = pe(() => {
3677
+ ), [p, h] = V(!1), x = j(null), w = j(null), M = me(() => {
3678
3678
  x.current && (clearTimeout(x.current), x.current = null), w.current && (clearTimeout(w.current), w.current = null);
3679
3679
  }, []);
3680
3680
  _(() => () => M(), [M]);
3681
- const b = pe(
3681
+ const b = me(
3682
3682
  (C) => {
3683
3683
  if (u) {
3684
3684
  const D = C !== "hidden";
@@ -3690,7 +3690,7 @@ function er({
3690
3690
  }
3691
3691
  },
3692
3692
  [u, s]
3693
- ), g = u ? t ? "hovered" : "hidden" : m, O = g !== "hidden", A = (C) => {
3693
+ ), g = u ? t ? "hovered" : "hidden" : m, O = g !== "hidden", R = (C) => {
3694
3694
  switch (C) {
3695
3695
  case "hidden":
3696
3696
  return 0;
@@ -3703,27 +3703,27 @@ function er({
3703
3703
  default:
3704
3704
  return 0;
3705
3705
  }
3706
- }, v = pe(
3706
+ }, v = me(
3707
3707
  (C) => {
3708
- M(), !(A(C) <= A(g)) && (x.current = setTimeout(() => {
3708
+ M(), !(R(C) <= R(g)) && (x.current = setTimeout(() => {
3709
3709
  b(C);
3710
3710
  }, r));
3711
3711
  },
3712
3712
  [M, r, g, b]
3713
- ), S = pe(
3713
+ ), S = me(
3714
3714
  (C) => {
3715
3715
  M(), w.current = setTimeout(() => {
3716
- (!u && A(m) <= A(C) || u) && b("hidden");
3716
+ (!u && R(m) <= R(C) || u) && b("hidden");
3717
3717
  }, c);
3718
3718
  },
3719
3719
  [M, c, m, u, b]
3720
- ), R = pe(() => {
3720
+ ), $ = me(() => {
3721
3721
  o.includes("hover") && v("hovered");
3722
- }, [o, v]), I = pe(() => {
3722
+ }, [o, v]), I = me(() => {
3723
3723
  o.includes("hover") && (g === "focused" || g === "clicked" || p || S("hovered"));
3724
- }, [o, g, p, S]), F = pe(() => {
3724
+ }, [o, g, p, S]), F = me(() => {
3725
3725
  o.includes("focus") && (M(), b("focused"));
3726
- }, [o, M, b]), E = pe(() => {
3726
+ }, [o, M, b]), E = me(() => {
3727
3727
  if (o.includes("focus") && g !== "clicked") {
3728
3728
  if (o.includes("hover") && p) {
3729
3729
  b("hovered");
@@ -3731,22 +3731,22 @@ function er({
3731
3731
  }
3732
3732
  S("focused");
3733
3733
  }
3734
- }, [o, g, p, S, b]), Y = pe(() => {
3734
+ }, [o, g, p, S, b]), Y = me(() => {
3735
3735
  o.includes("click") && (M(), b(g === "clicked" ? "hidden" : "clicked"));
3736
- }, [o, g, M, b]), z = pe(
3736
+ }, [o, g, M, b]), z = me(
3737
3737
  (C) => {
3738
3738
  C.key === "Escape" && O && (M(), b("hidden"), C.preventDefault());
3739
3739
  },
3740
3740
  [O, M, b]
3741
- ), te = pe(() => {
3741
+ ), te = me(() => {
3742
3742
  h(!0), M();
3743
- }, [M]), P = pe(() => {
3743
+ }, [M]), H = me(() => {
3744
3744
  h(!1), o.includes("hover") && g === "hovered" && S("hovered");
3745
3745
  }, [o, g, S]);
3746
3746
  return {
3747
3747
  triggerProps: {
3748
3748
  "aria-describedby": O ? l : void 0,
3749
- onMouseEnter: R,
3749
+ onMouseEnter: $,
3750
3750
  onMouseLeave: I,
3751
3751
  onFocus: F,
3752
3752
  onBlur: E,
@@ -3758,7 +3758,7 @@ function er({
3758
3758
  role: "tooltip",
3759
3759
  "aria-hidden": !O,
3760
3760
  onMouseEnter: te,
3761
- onMouseLeave: P
3761
+ onMouseLeave: H
3762
3762
  },
3763
3763
  isOpen: O,
3764
3764
  state: g
@@ -3786,11 +3786,11 @@ const $t = ({
3786
3786
  anchorRef: b,
3787
3787
  ...g
3788
3788
  }) => {
3789
- const A = i || (e === "rich" ? "bottom-right" : "bottom");
3789
+ const R = i || (e === "rich" ? "bottom-right" : "bottom");
3790
3790
  if (m = { duration: 0.3, ...m }, !s && !l)
3791
3791
  throw new Error("Tooltip must have a child or a targetRef");
3792
3792
  t && !Array.isArray(t) && (t = [t]);
3793
- const v = j(null), R = b || (l || v), { triggerProps: I, tooltipProps: F, isOpen: E } = er({
3793
+ const v = j(null), $ = b || (l || v), { triggerProps: I, tooltipProps: F, isOpen: E } = er({
3794
3794
  trigger: u,
3795
3795
  isOpen: h,
3796
3796
  defaultOpen: x,
@@ -3798,54 +3798,54 @@ const $t = ({
3798
3798
  openDelay: f,
3799
3799
  closeDelay: p,
3800
3800
  id: M
3801
- }), Y = !l && ke(s) ? Re(s, {
3801
+ }), Y = !l && Ie(s) ? Re(s, {
3802
3802
  ref: v,
3803
3803
  ...I,
3804
3804
  // Merge event handlers if the child already has them
3805
- onMouseEnter: (P) => {
3805
+ onMouseEnter: (H) => {
3806
3806
  var C, D;
3807
- I.onMouseEnter(), (D = (C = s.props) == null ? void 0 : C.onMouseEnter) == null || D.call(C, P);
3807
+ I.onMouseEnter(), (D = (C = s.props) == null ? void 0 : C.onMouseEnter) == null || D.call(C, H);
3808
3808
  },
3809
- onMouseLeave: (P) => {
3809
+ onMouseLeave: (H) => {
3810
3810
  var C, D;
3811
- I.onMouseLeave(), (D = (C = s.props) == null ? void 0 : C.onMouseLeave) == null || D.call(C, P);
3811
+ I.onMouseLeave(), (D = (C = s.props) == null ? void 0 : C.onMouseLeave) == null || D.call(C, H);
3812
3812
  },
3813
- onFocus: (P) => {
3813
+ onFocus: (H) => {
3814
3814
  var C, D;
3815
- I.onFocus(), (D = (C = s.props) == null ? void 0 : C.onFocus) == null || D.call(C, P);
3815
+ I.onFocus(), (D = (C = s.props) == null ? void 0 : C.onFocus) == null || D.call(C, H);
3816
3816
  },
3817
- onBlur: (P) => {
3817
+ onBlur: (H) => {
3818
3818
  var C, D;
3819
- I.onBlur(), (D = (C = s.props) == null ? void 0 : C.onBlur) == null || D.call(C, P);
3819
+ I.onBlur(), (D = (C = s.props) == null ? void 0 : C.onBlur) == null || D.call(C, H);
3820
3820
  },
3821
- onClick: (P) => {
3821
+ onClick: (H) => {
3822
3822
  var C, D;
3823
- I.onClick(), (D = (C = s.props) == null ? void 0 : C.onClick) == null || D.call(C, P);
3823
+ I.onClick(), (D = (C = s.props) == null ? void 0 : C.onClick) == null || D.call(C, H);
3824
3824
  },
3825
- onKeyDown: (P) => {
3825
+ onKeyDown: (H) => {
3826
3826
  var C, D;
3827
- I.onKeyDown(P), (D = (C = s.props) == null ? void 0 : C.onKeyDown) == null || D.call(C, P);
3827
+ I.onKeyDown(H), (D = (C = s.props) == null ? void 0 : C.onKeyDown) == null || D.call(C, H);
3828
3828
  }
3829
3829
  }) : s;
3830
3830
  _(() => {
3831
3831
  if (!l) return;
3832
- const P = l.current;
3833
- if (!P) return;
3832
+ const H = l.current;
3833
+ if (!H) return;
3834
3834
  const C = () => I.onMouseEnter(), D = () => I.onMouseLeave(), T = () => I.onFocus(), J = () => I.onBlur(), Z = () => I.onClick(), se = (L) => I.onKeyDown(L);
3835
- return P.addEventListener("mouseenter", C), P.addEventListener("mouseleave", D), P.addEventListener("focus", T, !0), P.addEventListener("blur", J, !0), P.addEventListener("click", Z), P.addEventListener("keydown", se), I["aria-describedby"] ? P.setAttribute(
3835
+ return H.addEventListener("mouseenter", C), H.addEventListener("mouseleave", D), H.addEventListener("focus", T, !0), H.addEventListener("blur", J, !0), H.addEventListener("click", Z), H.addEventListener("keydown", se), I["aria-describedby"] ? H.setAttribute(
3836
3836
  "aria-describedby",
3837
3837
  I["aria-describedby"]
3838
- ) : P.removeAttribute("aria-describedby"), () => {
3839
- P.removeEventListener("mouseenter", C), P.removeEventListener("mouseleave", D), P.removeEventListener("focus", T, !0), P.removeEventListener("blur", J, !0), P.removeEventListener("click", Z), P.removeEventListener("keydown", se);
3838
+ ) : H.removeAttribute("aria-describedby"), () => {
3839
+ H.removeEventListener("mouseenter", C), H.removeEventListener("mouseleave", D), H.removeEventListener("focus", T, !0), H.removeEventListener("blur", J, !0), H.removeEventListener("click", Z), H.removeEventListener("keydown", se);
3840
3840
  };
3841
3841
  }, [l, I]);
3842
- const z = Hn({
3842
+ const z = Pn({
3843
3843
  variant: e,
3844
3844
  buttons: t,
3845
3845
  className: n,
3846
3846
  title: r,
3847
3847
  text: c,
3848
- position: A,
3848
+ position: R,
3849
3849
  trigger: u,
3850
3850
  targetRef: l,
3851
3851
  children: s
@@ -3859,13 +3859,13 @@ const $t = ({
3859
3859
  height: 16
3860
3860
  }
3861
3861
  };
3862
- return /* @__PURE__ */ K(me, { children: [
3862
+ return /* @__PURE__ */ K(ye, { children: [
3863
3863
  Y,
3864
- /* @__PURE__ */ d(he, { children: E && /* @__PURE__ */ d(
3864
+ /* @__PURE__ */ d(pe, { children: E && /* @__PURE__ */ d(
3865
3865
  it,
3866
3866
  {
3867
- anchorRef: R,
3868
- position: A,
3867
+ anchorRef: $,
3868
+ position: R,
3869
3869
  children: /* @__PURE__ */ d(
3870
3870
  ne.div,
3871
3871
  {
@@ -3877,15 +3877,15 @@ const $t = ({
3877
3877
  className: z.toolTip,
3878
3878
  ...g,
3879
3879
  ...F,
3880
- children: /* @__PURE__ */ d("div", { className: z.container, children: a ? /* @__PURE__ */ d("div", { className: z.content, children: a }) : /* @__PURE__ */ K(me, { children: [
3880
+ children: /* @__PURE__ */ d("div", { className: z.container, children: a ? /* @__PURE__ */ d("div", { className: z.content, children: a }) : /* @__PURE__ */ K(ye, { children: [
3881
3881
  r && /* @__PURE__ */ d("div", { className: z.subHead, children: r }),
3882
3882
  c && /* @__PURE__ */ d("div", { className: z.supportingText, children: c }),
3883
- t && /* @__PURE__ */ d("div", { className: z.actions, children: Array.isArray(t) && t.map((P, C) => /* @__PURE__ */ d(
3884
- Ne,
3883
+ t && /* @__PURE__ */ d("div", { className: z.actions, children: Array.isArray(t) && t.map((H, C) => /* @__PURE__ */ d(
3884
+ Le,
3885
3885
  {
3886
3886
  size: "small",
3887
3887
  variant: "text",
3888
- ...P
3888
+ ...H
3889
3889
  },
3890
3890
  C
3891
3891
  )) })
@@ -3969,7 +3969,7 @@ const $t = ({
3969
3969
  }
3970
3970
  ),
3971
3971
  /* @__PURE__ */ d(
3972
- Se,
3972
+ Ne,
3973
3973
  {
3974
3974
  style: { transition: o.duration + "s" },
3975
3975
  className: p.stateLayer,
@@ -3984,8 +3984,8 @@ const $t = ({
3984
3984
  stateClassName: "state-ripple-group-[fab]"
3985
3985
  }
3986
3986
  ),
3987
- /* @__PURE__ */ d(fe, { icon: a, className: p.icon }),
3988
- /* @__PURE__ */ d(he, { children: i && /* @__PURE__ */ d(
3987
+ /* @__PURE__ */ d(he, { icon: a, className: p.icon }),
3988
+ /* @__PURE__ */ d(pe, { children: i && /* @__PURE__ */ d(
3989
3989
  ne.span,
3990
3990
  {
3991
3991
  variants: w,
@@ -3999,7 +3999,7 @@ const $t = ({
3999
3999
  ]
4000
4000
  }
4001
4001
  );
4002
- }, Ie = ({
4002
+ }, Me = ({
4003
4003
  variant: e = "standard",
4004
4004
  href: t,
4005
4005
  disabled: n = !1,
@@ -4025,7 +4025,7 @@ const $t = ({
4025
4025
  "IconButton component requires either a label prop or children content to provide an accessible aria-label"
4026
4026
  );
4027
4027
  !s && s !== null && (s = r);
4028
- const [g, O] = Q.useState(a), A = (F) => {
4028
+ const [g, O] = Q.useState(a), R = (F) => {
4029
4029
  n && F.preventDefault(), c ? (O(!g), c(!g)) : i && i(F);
4030
4030
  };
4031
4031
  _(() => {
@@ -4049,7 +4049,7 @@ const $t = ({
4049
4049
  size: o,
4050
4050
  children: r,
4051
4051
  ...b
4052
- }), R = j(null), I = f || R;
4052
+ }), $ = j(null), I = f || $;
4053
4053
  return w = { duration: 0.3, ...w }, /* @__PURE__ */ K(
4054
4054
  v,
4055
4055
  {
@@ -4060,7 +4060,7 @@ const $t = ({
4060
4060
  "aria-label": r,
4061
4061
  ...b,
4062
4062
  title: void 0,
4063
- onClick: A,
4063
+ onClick: R,
4064
4064
  ref: I,
4065
4065
  children: [
4066
4066
  s !== null && /* @__PURE__ */ d(
@@ -4073,7 +4073,7 @@ const $t = ({
4073
4073
  ),
4074
4074
  /* @__PURE__ */ d("div", { className: S.touchTarget }),
4075
4075
  /* @__PURE__ */ d(
4076
- Se,
4076
+ Ne,
4077
4077
  {
4078
4078
  style: { transition: w.duration + "s" },
4079
4079
  className: S.stateLayer,
@@ -4098,7 +4098,7 @@ const $t = ({
4098
4098
  stateClassName: "state-ripple-group-[icon-button]"
4099
4099
  }
4100
4100
  ),
4101
- l ? /* @__PURE__ */ d(fe, { icon: l, className: S.icon }) : M
4101
+ l ? /* @__PURE__ */ d(he, { icon: l, className: S.icon }) : M
4102
4102
  ]
4103
4103
  }
4104
4104
  );
@@ -4121,8 +4121,8 @@ const $t = ({
4121
4121
  l = { duration: 0.3, ease: "easeInOut", ...l };
4122
4122
  const h = j(null), x = i || h, w = typeof u == "boolean", [M, b] = V(m), g = w ? u : M, O = (E) => {
4123
4123
  w || b(E), f == null || f(E);
4124
- }, A = Q.Children.toArray(o).filter(
4125
- (E) => Q.isValidElement(E) && E.type === Ne
4124
+ }, R = Q.Children.toArray(o).filter(
4125
+ (E) => Q.isValidElement(E) && E.type === Le
4126
4126
  ), v = In({
4127
4127
  href: r,
4128
4128
  icon: c,
@@ -4134,7 +4134,7 @@ const $t = ({
4134
4134
  transition: l,
4135
4135
  children: t,
4136
4136
  open: g
4137
- }), S = ne.create(Be), R = ne.create(Ie), I = (E) => /* @__PURE__ */ d(
4137
+ }), S = ne.create(Be), $ = ne.create(Me), I = (E) => /* @__PURE__ */ d(
4138
4138
  S,
4139
4139
  {
4140
4140
  icon: c,
@@ -4155,22 +4155,22 @@ const $t = ({
4155
4155
  },
4156
4156
  ...E
4157
4157
  }
4158
- ), F = Me();
4158
+ ), F = Ee();
4159
4159
  return /* @__PURE__ */ K("div", { className: v.fabMenu, ref: x, ...p, children: [
4160
- /* @__PURE__ */ d(he, { children: g && /* @__PURE__ */ d("div", { className: v.actions, role: "menu", "aria-hidden": !g, children: (() => {
4161
- const E = A.length;
4162
- return A.map((Y, z) => {
4160
+ /* @__PURE__ */ d(pe, { children: g && /* @__PURE__ */ d("div", { className: v.actions, role: "menu", "aria-hidden": !g, children: (() => {
4161
+ const E = R.length;
4162
+ return R.map((Y, z) => {
4163
4163
  Y.props;
4164
- const te = E - 1 - z, P = ((l == null ? void 0 : l.delay) ?? 0) + te * 0.06, C = {
4164
+ const te = E - 1 - z, H = ((l == null ? void 0 : l.delay) ?? 0) + te * 0.06, C = {
4165
4165
  open: {
4166
4166
  overflow: "visible",
4167
4167
  opacity: 1,
4168
4168
  width: "auto",
4169
4169
  transition: {
4170
4170
  ...l,
4171
- delay: P,
4171
+ delay: H,
4172
4172
  opacity: {
4173
- delay: (l == null ? void 0 : l.duration) / 2 + P
4173
+ delay: (l == null ? void 0 : l.duration) / 2 + H
4174
4174
  }
4175
4175
  }
4176
4176
  },
@@ -4180,7 +4180,7 @@ const $t = ({
4180
4180
  width: 0,
4181
4181
  transition: {
4182
4182
  ...l,
4183
- delay: P,
4183
+ delay: H,
4184
4184
  opacity: {
4185
4185
  duration: (l == null ? void 0 : l.duration) / 1.5
4186
4186
  }
@@ -4232,8 +4232,8 @@ const $t = ({
4232
4232
  layout: !0,
4233
4233
  layoutId: "fab-menu" + F
4234
4234
  }),
4235
- g && /* @__PURE__ */ d(me, { children: /* @__PURE__ */ d(
4236
- R,
4235
+ g && /* @__PURE__ */ d(ye, { children: /* @__PURE__ */ d(
4236
+ $,
4237
4237
  {
4238
4238
  layout: !0,
4239
4239
  layoutId: "fab-menu" + F,
@@ -4299,14 +4299,14 @@ const $t = ({
4299
4299
  }, f = (D = !1) => D ? a : a == 1 / 0 ? i[(i == null ? void 0 : i.length) - 1].value : a, p = (D = !1) => D ? c : c == -1 / 0 ? i[0].value : c, h = (D) => {
4300
4300
  const T = p(!1);
4301
4301
  return (f(!1) - T) * D / 100 + T;
4302
- }, [x, w] = V(!1), M = j(null), b = l || M, [g, O] = V(r), [A, v] = V(m(r)), [S, R] = V(!1);
4302
+ }, [x, w] = V(!1), M = j(null), b = l || M, [g, O] = V(r), [R, v] = V(m(r)), [S, $] = V(!1);
4303
4303
  _(() => {
4304
4304
  O(r), v(m(r));
4305
4305
  }, [r]);
4306
4306
  const I = (D) => {
4307
- R(!0), w(!0), Y(D);
4307
+ $(!0), w(!0), Y(D);
4308
4308
  }, F = () => {
4309
- R(!1), w(!1);
4309
+ $(!1), w(!1);
4310
4310
  };
4311
4311
  _(() => (S ? (window.addEventListener("mouseup", F), window.addEventListener("mousemove", Y), window.addEventListener("touchend", F), window.addEventListener("touchmove", Y)) : (window.removeEventListener("mouseup", F), window.removeEventListener("mousemove", Y), window.removeEventListener("touchend", F), window.removeEventListener("touchmove", Y)), () => {
4312
4312
  window.removeEventListener("mouseup", F), window.removeEventListener("mousemove", Y), window.removeEventListener("touchend", F), window.removeEventListener("touchmove", Y);
@@ -4358,10 +4358,10 @@ const $t = ({
4358
4358
  let L = Z.value === 1 / 0 ? f() : Z.value === -1 / 0 ? p() : Z.value, k = J.value === 1 / 0 ? f() : J.value === -1 / 0 ? p() : J.value;
4359
4359
  return L = Math.abs(L - T), k = Math.abs(k - T), L < k ? Z : J;
4360
4360
  }).value), T >= f() && (T = f(!0)), T <= p() && (T = p(!0)), D = m(T), O(T), v(D), o && o(T);
4361
- }, [te, P] = V(0);
4361
+ }, [te, H] = V(0);
4362
4362
  return _(() => {
4363
4363
  const D = () => {
4364
- b.current && P(b.current.offsetWidth);
4364
+ b.current && H(b.current.offsetWidth);
4365
4365
  };
4366
4366
  return D(), window.addEventListener("resize", D), () => {
4367
4367
  window.removeEventListener("resize", D);
@@ -4406,8 +4406,8 @@ const $t = ({
4406
4406
  ...u,
4407
4407
  children: [
4408
4408
  /* @__PURE__ */ d("input", { type: "hidden", name: s, value: g }),
4409
- /* @__PURE__ */ d("div", { className: E.activeTrack, style: { flex: A / 100 } }),
4410
- /* @__PURE__ */ d("div", { className: E.handle, children: /* @__PURE__ */ d(he, { children: x && /* @__PURE__ */ d(
4409
+ /* @__PURE__ */ d("div", { className: E.activeTrack, style: { flex: R / 100 } }),
4410
+ /* @__PURE__ */ d("div", { className: E.handle, children: /* @__PURE__ */ d(pe, { children: x && /* @__PURE__ */ d(
4411
4411
  ne.div,
4412
4412
  {
4413
4413
  className: E.valueIndicator,
@@ -4431,7 +4431,7 @@ const $t = ({
4431
4431
  "div",
4432
4432
  {
4433
4433
  className: E.inactiveTrack,
4434
- style: { flex: 1 - A / 100 }
4434
+ style: { flex: 1 - R / 100 }
4435
4435
  }
4436
4436
  ),
4437
4437
  /* @__PURE__ */ d(
@@ -4441,7 +4441,7 @@ const $t = ({
4441
4441
  children: i && i.map((D, T) => {
4442
4442
  let J = null;
4443
4443
  const Z = (x ? 9 : 10) / te * 100, se = m(D.value);
4444
- return se <= A - Z ? J = !0 : se >= A + Z && (J = !1), /* @__PURE__ */ d(
4444
+ return se <= R - Z ? J = !0 : se >= R + Z && (J = !1), /* @__PURE__ */ d(
4445
4445
  "div",
4446
4446
  {
4447
4447
  className: y(E.dot, {
@@ -4499,8 +4499,8 @@ const $t = ({
4499
4499
  open: {
4500
4500
  width: "auto"
4501
4501
  }
4502
- }, x = () => /* @__PURE__ */ K(me, { children: [
4503
- /* @__PURE__ */ d(he, { children: e == "modal" && m && /* @__PURE__ */ d(
4502
+ }, x = () => /* @__PURE__ */ K(ye, { children: [
4503
+ /* @__PURE__ */ d(pe, { children: e == "modal" && m && /* @__PURE__ */ d(
4504
4504
  ne.div,
4505
4505
  {
4506
4506
  initial: { opacity: 0 },
@@ -4511,7 +4511,7 @@ const $t = ({
4511
4511
  className: p.overlay
4512
4512
  }
4513
4513
  ) }),
4514
- /* @__PURE__ */ d(he, { children: m && /* @__PURE__ */ K(
4514
+ /* @__PURE__ */ d(pe, { children: m && /* @__PURE__ */ K(
4515
4515
  "div",
4516
4516
  {
4517
4517
  ...u,
@@ -4530,7 +4530,7 @@ const $t = ({
4530
4530
  /* @__PURE__ */ K("div", { className: p.header, children: [
4531
4531
  s && /* @__PURE__ */ d("p", { className: p.title, children: s }),
4532
4532
  /* @__PURE__ */ d(
4533
- Ie,
4533
+ Me,
4534
4534
  {
4535
4535
  size: "small",
4536
4536
  label: "close",
@@ -4581,7 +4581,7 @@ const $t = ({
4581
4581
  const o = () => {
4582
4582
  i(!1), r == null || r();
4583
4583
  };
4584
- return /* @__PURE__ */ d(he, { children: a && /* @__PURE__ */ d(
4584
+ return /* @__PURE__ */ d(pe, { children: a && /* @__PURE__ */ d(
4585
4585
  ne.div,
4586
4586
  {
4587
4587
  initial: { height: 0 },
@@ -4593,7 +4593,7 @@ const $t = ({
4593
4593
  children: /* @__PURE__ */ K("div", { className: l.container, children: [
4594
4594
  /* @__PURE__ */ d("p", { className: l.supportingText, children: e }),
4595
4595
  /* @__PURE__ */ d(
4596
- Ie,
4596
+ Me,
4597
4597
  {
4598
4598
  onClick: () => o(),
4599
4599
  className: l.icon,
@@ -4661,7 +4661,7 @@ const $t = ({
4661
4661
  className: x.handleContainer,
4662
4662
  children: [
4663
4663
  /* @__PURE__ */ d("div", { className: x.handle, children: (u ? n : r) && /* @__PURE__ */ d(
4664
- fe,
4664
+ he,
4665
4665
  {
4666
4666
  className: x.icon,
4667
4667
  icon: u ? n : r
@@ -4703,8 +4703,8 @@ const $t = ({
4703
4703
  icon: c
4704
4704
  });
4705
4705
  }, [a]);
4706
- const A = r ? "a" : "button", v = (R) => {
4707
- i && i(o ?? null), t && t(R);
4706
+ const R = r ? "a" : "button", v = ($) => {
4707
+ i && i(o ?? null), t && t($);
4708
4708
  }, S = Wn({
4709
4709
  className: e,
4710
4710
  onTabSelected: u,
@@ -4721,7 +4721,7 @@ const $t = ({
4721
4721
  href: r
4722
4722
  });
4723
4723
  return /* @__PURE__ */ K(
4724
- A,
4724
+ R,
4725
4725
  {
4726
4726
  ...x,
4727
4727
  role: "tab",
@@ -4733,7 +4733,7 @@ const $t = ({
4733
4733
  ...x,
4734
4734
  children: [
4735
4735
  /* @__PURE__ */ d(
4736
- Se,
4736
+ Ne,
4737
4737
  {
4738
4738
  style: { transition: 0.3 + "s" },
4739
4739
  className: S.stateLayer,
@@ -4742,7 +4742,7 @@ const $t = ({
4742
4742
  }
4743
4743
  ),
4744
4744
  /* @__PURE__ */ K("span", { className: S.content, children: [
4745
- c && /* @__PURE__ */ d(fe, { icon: c, className: S.icon }),
4745
+ c && /* @__PURE__ */ d(he, { icon: c, className: S.icon }),
4746
4746
  /* @__PURE__ */ d("span", { className: S.label, children: b }),
4747
4747
  g && /* @__PURE__ */ d(
4748
4748
  ne.span,
@@ -4780,7 +4780,7 @@ const $t = ({
4780
4780
  b.scrollTo({ left: O, behavior: "smooth" });
4781
4781
  }
4782
4782
  }
4783
- }, x = we(
4783
+ }, x = be(
4784
4784
  () => (i == null ? void 0 : i.tabsId) ?? Rt(),
4785
4785
  [i == null ? void 0 : i.tabsId]
4786
4786
  ), w = An({
@@ -4812,7 +4812,7 @@ const $t = ({
4812
4812
  s
4813
4813
  ), a = j(null), i = t !== void 0 ? t : r, l = n ?? c, o = a.current !== null && i !== null ? i > a.current ? 1 : -1 : 0;
4814
4814
  i !== a.current && (a.current = i);
4815
- const u = Me(), m = we(
4815
+ const u = Ee(), m = be(
4816
4816
  () => ({
4817
4817
  selectedTab: i,
4818
4818
  setSelectedTab: l,
@@ -4847,7 +4847,7 @@ const $t = ({
4847
4847
  children: e,
4848
4848
  className: t
4849
4849
  });
4850
- return /* @__PURE__ */ d("div", { className: i.tabPanels, children: /* @__PURE__ */ d(he, { initial: !1, custom: r, mode: "popLayout", children: a.map(
4850
+ return /* @__PURE__ */ d("div", { className: i.tabPanels, children: /* @__PURE__ */ d(pe, { initial: !1, custom: r, mode: "popLayout", children: a.map(
4851
4851
  (l, o) => s === o && /* @__PURE__ */ d(
4852
4852
  ne.div,
4853
4853
  {
@@ -4921,27 +4921,27 @@ const $t = ({
4921
4921
  return new Date(k.getFullYear(), k.getMonth(), 1);
4922
4922
  }), [h, x] = V(0), [w, M] = V("day"), b = e !== void 0, [g, O] = V(
4923
4923
  t || null
4924
- ), A = b ? e || null : g, v = (L, k) => new Date(L, k + 1, 0).getDate(), S = we(() => {
4925
- const L = f.getFullYear(), k = f.getMonth(), N = v(L, k), H = (new Date(L, k, 1).getDay() - i + 7) % 7, X = [], q = v(L, k - 1);
4926
- for (let U = H - 1; U >= 0; U--)
4924
+ ), R = b ? e || null : g, v = (L, k) => new Date(L, k + 1, 0).getDate(), S = be(() => {
4925
+ const L = f.getFullYear(), k = f.getMonth(), N = v(L, k), P = (new Date(L, k, 1).getDay() - i + 7) % 7, X = [], q = v(L, k - 1);
4926
+ for (let U = P - 1; U >= 0; U--)
4927
4927
  X.push({
4928
4928
  date: new Date(L, k - 1, q - U),
4929
4929
  isCurrentMonth: !1
4930
4930
  });
4931
4931
  for (let U = 1; U <= N; U++)
4932
4932
  X.push({ date: new Date(L, k, U), isCurrentMonth: !0 });
4933
- const $ = 42 - X.length;
4934
- for (let U = 1; U <= $; U++)
4933
+ const W = 42 - X.length;
4934
+ for (let U = 1; U <= W; U++)
4935
4935
  X.push({
4936
4936
  date: new Date(L, k + 1, U),
4937
4937
  isCurrentMonth: !1
4938
4938
  });
4939
4939
  return X;
4940
- }, [f, i]), R = we(() => {
4941
- const L = (/* @__PURE__ */ new Date()).getFullYear(), k = L - 100, N = L + 100, W = [];
4942
- for (let H = k; H <= N; H++)
4943
- W.push(H);
4944
- return W;
4940
+ }, [f, i]), $ = be(() => {
4941
+ const L = (/* @__PURE__ */ new Date()).getFullYear(), k = L - 100, N = L + 100, A = [];
4942
+ for (let P = k; P <= N; P++)
4943
+ A.push(P);
4944
+ return A;
4945
4945
  }, []), I = j(null);
4946
4946
  _(() => {
4947
4947
  if (w === "year" && I.current) {
@@ -4951,62 +4951,62 @@ const $t = ({
4951
4951
  L && L.scrollIntoView({ block: "center" });
4952
4952
  }
4953
4953
  }, [w]);
4954
- const F = we(
4954
+ const F = be(
4955
4955
  () => new Intl.DateTimeFormat(a, { month: "long", year: "numeric" }),
4956
4956
  [a]
4957
- ), E = we(
4957
+ ), E = be(
4958
4958
  () => new Intl.DateTimeFormat(a, { weekday: "narrow" }),
4959
4959
  [a]
4960
- ), Y = we(() => {
4960
+ ), Y = be(() => {
4961
4961
  const L = new Date(2023, 0, 1 + i);
4962
4962
  return Array.from({ length: 7 }).map((k, N) => {
4963
- const W = new Date(L);
4964
- return W.setDate(L.getDate() + N), E.format(W).charAt(0).toUpperCase();
4963
+ const A = new Date(L);
4964
+ return A.setDate(L.getDate() + N), E.format(A).charAt(0).toUpperCase();
4965
4965
  });
4966
4966
  }, [E, i]), z = () => {
4967
4967
  x(-1), p((L) => new Date(L.getFullYear(), L.getMonth() - 1, 1));
4968
4968
  }, te = () => {
4969
4969
  x(1), p((L) => new Date(L.getFullYear(), L.getMonth() + 1, 1));
4970
- }, P = (L) => {
4970
+ }, H = (L) => {
4971
4971
  p((k) => new Date(L, k.getMonth(), 1)), M("day");
4972
4972
  }, C = (L, k) => L ? L.getDate() === k.getDate() && L.getMonth() === k.getMonth() && L.getFullYear() === k.getFullYear() : !1, D = (L) => C(/* @__PURE__ */ new Date(), L), T = (L) => {
4973
4973
  let k = L;
4974
4974
  if (u === "single")
4975
4975
  k = L;
4976
4976
  else {
4977
- const N = A, [W, H] = Array.isArray(N) ? N : [null, null];
4978
- !W || W && H ? k = [L, null] : L < W ? k = [L, W] : k = [W, L];
4977
+ const N = R, [A, P] = Array.isArray(N) ? N : [null, null];
4978
+ !A || A && P ? k = [L, null] : L < A ? k = [L, A] : k = [A, L];
4979
4979
  }
4980
4980
  b || O(k), n && n(k);
4981
4981
  }, J = (L) => {
4982
4982
  if (u === "single")
4983
4983
  return {
4984
- isSelected: C(A, L),
4984
+ isSelected: C(R, L),
4985
4985
  isStart: !1,
4986
4986
  isEnd: !1,
4987
4987
  isInRange: !1
4988
4988
  };
4989
- const k = Array.isArray(A) ? A : [A, null], [N, W] = k, H = C(N, L), X = C(W, L);
4989
+ const k = Array.isArray(R) ? R : [R, null], [N, A] = k, P = C(N, L), X = C(A, L);
4990
4990
  let q = !1;
4991
- if (N && W) {
4991
+ if (N && A) {
4992
4992
  const ee = new Date(
4993
4993
  N.getFullYear(),
4994
4994
  N.getMonth(),
4995
4995
  N.getDate()
4996
- ).getTime(), $ = new Date(
4997
- W.getFullYear(),
4998
- W.getMonth(),
4999
- W.getDate()
4996
+ ).getTime(), W = new Date(
4997
+ A.getFullYear(),
4998
+ A.getMonth(),
4999
+ A.getDate()
5000
5000
  ).getTime(), U = new Date(
5001
5001
  L.getFullYear(),
5002
5002
  L.getMonth(),
5003
5003
  L.getDate()
5004
5004
  ).getTime();
5005
- q = U > ee && U < $;
5005
+ q = U > ee && U < W;
5006
5006
  }
5007
- return { isSelected: H || X, isStart: H, isEnd: X, isInRange: q };
5007
+ return { isSelected: P || X, isStart: P, isEnd: X, isInRange: q };
5008
5008
  }, Z = sr({
5009
- hasSelected: !!A
5009
+ hasSelected: !!R
5010
5010
  }), se = {
5011
5011
  enter: (L) => ({
5012
5012
  x: L > 0 ? "100%" : "-100%",
@@ -5030,7 +5030,7 @@ const $t = ({
5030
5030
  children: [
5031
5031
  /* @__PURE__ */ K("div", { className: Z.header, children: [
5032
5032
  /* @__PURE__ */ K(
5033
- Ne,
5033
+ Le,
5034
5034
  {
5035
5035
  variant: "text",
5036
5036
  disableTextMargins: !0,
@@ -5040,7 +5040,7 @@ const $t = ({
5040
5040
  children: [
5041
5041
  /* @__PURE__ */ d("span", { className: "mr-2", children: w === "day" ? F.format(f) : f.getFullYear() }),
5042
5042
  /* @__PURE__ */ d(
5043
- fe,
5043
+ he,
5044
5044
  {
5045
5045
  icon: Un,
5046
5046
  className: y(
@@ -5054,7 +5054,7 @@ const $t = ({
5054
5054
  ),
5055
5055
  w === "day" && /* @__PURE__ */ K("div", { className: "flex items-center", children: [
5056
5056
  /* @__PURE__ */ d(
5057
- Ie,
5057
+ Me,
5058
5058
  {
5059
5059
  size: "xSmall",
5060
5060
  allowShapeTransformation: !1,
@@ -5065,7 +5065,7 @@ const $t = ({
5065
5065
  }
5066
5066
  ),
5067
5067
  /* @__PURE__ */ d(
5068
- Ie,
5068
+ Me,
5069
5069
  {
5070
5070
  size: "xSmall",
5071
5071
  allowShapeTransformation: !1,
@@ -5082,12 +5082,12 @@ const $t = ({
5082
5082
  {
5083
5083
  className: "h-[280px] overflow-y-auto grid grid-cols-3 gap-2 p-2 scrollbar-hide",
5084
5084
  ref: I,
5085
- children: R.map((L) => /* @__PURE__ */ d(
5086
- Ne,
5085
+ children: $.map((L) => /* @__PURE__ */ d(
5086
+ Le,
5087
5087
  {
5088
5088
  size: "small",
5089
5089
  variant: L === f.getFullYear() ? "filled" : "text",
5090
- onClick: () => P(L),
5090
+ onClick: () => H(L),
5091
5091
  "data-selected": L === f.getFullYear(),
5092
5092
  className: y("w-full", {
5093
5093
  "text-on-surface": L !== f.getFullYear()
@@ -5098,10 +5098,10 @@ const $t = ({
5098
5098
  L
5099
5099
  ))
5100
5100
  }
5101
- ) : /* @__PURE__ */ K(me, { children: [
5101
+ ) : /* @__PURE__ */ K(ye, { children: [
5102
5102
  /* @__PURE__ */ d("div", { className: Z.weekDays, children: Y.map((L, k) => /* @__PURE__ */ d("div", { className: Z.weekDay, children: L }, k)) }),
5103
5103
  /* @__PURE__ */ d("div", { className: "overflow-hidden relative min-h-[240px]", children: /* @__PURE__ */ d(
5104
- he,
5104
+ pe,
5105
5105
  {
5106
5106
  mode: "popLayout",
5107
5107
  initial: !1,
@@ -5119,7 +5119,7 @@ const $t = ({
5119
5119
  children: S.map((L, k) => {
5120
5120
  if (!L.isCurrentMonth)
5121
5121
  return /* @__PURE__ */ d("div", { className: Z.dayCell }, k);
5122
- const { isSelected: N, isStart: W, isEnd: H, isInRange: X } = J(L.date), q = D(L.date), ee = s && L.date < s || r && L.date > r || (c == null ? void 0 : c(L.date));
5122
+ const { isSelected: N, isStart: A, isEnd: P, isInRange: X } = J(L.date), q = D(L.date), ee = s && L.date < s || r && L.date > r || (c == null ? void 0 : c(L.date));
5123
5123
  return /* @__PURE__ */ d(
5124
5124
  "div",
5125
5125
  {
@@ -5127,11 +5127,11 @@ const $t = ({
5127
5127
  Z.dayCell,
5128
5128
  // Range background styles applied to the cell wrapper
5129
5129
  X && "bg-primary/20",
5130
- W && (A == null ? void 0 : A[1]) && "bg-gradient-to-r from-transparent to-primary/20",
5131
- H && (A == null ? void 0 : A[0]) && "bg-gradient-to-l from-transparent to-primary/20"
5130
+ A && (R == null ? void 0 : R[1]) && "bg-gradient-to-r from-transparent to-primary/20",
5131
+ P && (R == null ? void 0 : R[0]) && "bg-gradient-to-l from-transparent to-primary/20"
5132
5132
  ),
5133
5133
  children: /* @__PURE__ */ d(
5134
- Ne,
5134
+ Le,
5135
5135
  {
5136
5136
  className: () => ({
5137
5137
  button: y("aspect-square h-[40px] p-0", {
@@ -5190,41 +5190,43 @@ const $t = ({
5190
5190
  id: b,
5191
5191
  style: g,
5192
5192
  ref: O,
5193
- ...A
5193
+ ...R
5194
5194
  }) => {
5195
- const v = Me(), S = b || v, R = `${S}-helper`, I = x !== void 0, [F, E] = V(w ?? ""), Y = I ? x : F, [z, te] = V(!1), [P, C] = V(!!(n != null && n.length)), D = j(null), T = O || D, J = j(null), Z = j(null), se = M ?? (!!(n != null && n.length) || !!(l != null && l.length));
5195
+ const v = Ee(), S = b || v, $ = `${S}-helper`, I = x !== void 0, [F, E] = V(w ?? ""), Y = I ? x : F, [z, te] = V(!1), [H, C] = V(!!(n != null && n.length)), D = j(null), T = O || D, J = j(null), Z = j(null), se = M ?? (!!(n != null && n.length) || !!(l != null && l.length));
5196
5196
  _(() => {
5197
5197
  C(!!(n != null && n.length));
5198
5198
  }, [n]);
5199
5199
  const L = () => {
5200
5200
  T.current && !z && T.current.focus();
5201
- }, k = () => {
5202
- te(!0), C(!1);
5203
- }, N = (ve) => {
5204
- const Ce = ve.target.value;
5205
- I || E(Ce), C(!1), h && h(ve);
5206
- }, W = () => {
5207
- te(!1), n != null && n.length && C(!0);
5208
- }, H = m === "date", [X, q] = V(!1), [ee, $] = V(null), U = we(() => {
5209
- const ve = String(Y);
5210
- if (!ve) return null;
5211
- const [Ce, ze, Te] = ve.split("-").map(Number);
5212
- return Ce && ze && Te ? new Date(Ce, ze - 1, Te) : null;
5201
+ }, k = (fe) => {
5202
+ var ge;
5203
+ te(!0), C(!1), (ge = R.onFocus) == null || ge.call(R, fe);
5204
+ }, N = (fe) => {
5205
+ const ge = fe.target.value;
5206
+ I || E(ge), C(!1), h && h(fe);
5207
+ }, A = (fe) => {
5208
+ var ge;
5209
+ te(!1), n != null && n.length && C(!0), (ge = R.onBlur) == null || ge.call(R, fe);
5210
+ }, P = m === "date", [X, q] = V(!1), [ee, W] = V(null), U = be(() => {
5211
+ const fe = String(Y);
5212
+ if (!fe) return null;
5213
+ const [ge, ze, Te] = fe.split("-").map(Number);
5214
+ return ge && ze && Te ? new Date(ge, ze - 1, Te) : null;
5213
5215
  }, [Y]), ie = () => {
5214
- t || ($(U), q(!0));
5216
+ t || (W(U), q(!0));
5215
5217
  }, de = () => {
5216
- const ve = ee ? ee.toLocaleDateString("en-CA") : "";
5217
- I || E(ve), h && h({
5218
+ const fe = ee ? ee.toLocaleDateString("en-CA") : "";
5219
+ I || E(fe), h && h({
5218
5220
  target: {
5219
- value: ve,
5221
+ value: fe,
5220
5222
  name: c,
5221
5223
  type: m
5222
5224
  }
5223
5225
  }), q(!1);
5224
- }, ye = H && !o ? Yn : o, be = H ? "[&::-webkit-calendar-picker-indicator]:hidden cursor-pointer" : "", ce = Pn({
5226
+ }, ve = P && !o ? Yn : o, xe = P ? "[&::-webkit-calendar-picker-indicator]:hidden cursor-pointer" : "", ce = Hn({
5225
5227
  showSupportingText: se,
5226
5228
  isFocused: z,
5227
- showErrorIcon: P,
5229
+ showErrorIcon: H,
5228
5230
  disabled: t,
5229
5231
  name: c,
5230
5232
  label: a,
@@ -5235,13 +5237,13 @@ const $t = ({
5235
5237
  supportingText: l,
5236
5238
  type: m,
5237
5239
  leadingIcon: u,
5238
- trailingIcon: ye,
5240
+ trailingIcon: ve,
5239
5241
  variant: e,
5240
5242
  errorText: n,
5241
5243
  value: String(Y),
5242
5244
  suffix: r,
5243
5245
  multiline: f
5244
- }), G = f ? Xt : "input", ae = f ? {} : { type: m }, le = z || typeof Y == "string" && Y.length > 0 || m == "date", ge = le && e === "outlined", Ee = !ge;
5246
+ }), G = f ? Xt : "input", ae = f ? {} : { type: m }, le = z || typeof Y == "string" && Y.length > 0 || m == "date", we = le && e === "outlined", Ce = !we;
5245
5247
  return /* @__PURE__ */ K("div", { ref: J, className: ce.textField, style: g, children: [
5246
5248
  /* @__PURE__ */ K(
5247
5249
  "fieldset",
@@ -5251,7 +5253,7 @@ const $t = ({
5251
5253
  role: "presentation",
5252
5254
  children: [
5253
5255
  /* @__PURE__ */ d("div", { className: ce.stateLayer }),
5254
- u && /* @__PURE__ */ d("div", { className: ce.leadingIcon, children: Q.isValidElement(u) ? u : /* @__PURE__ */ d(fe, { className: "w-5 h-5", icon: u }) }),
5256
+ u && /* @__PURE__ */ d("div", { className: ce.leadingIcon, children: Q.isValidElement(u) ? u : /* @__PURE__ */ d(he, { className: "w-5 h-5", icon: u }) }),
5255
5257
  /* @__PURE__ */ d(
5256
5258
  ne.legend,
5257
5259
  {
@@ -5260,15 +5262,15 @@ const $t = ({
5260
5262
  hidden: { width: 0, padding: 0 },
5261
5263
  visible: { width: "auto", padding: "0 8px" }
5262
5264
  },
5263
- initial: ge ? "visible" : "hidden",
5264
- animate: ge ? "visible" : "hidden",
5265
+ initial: we ? "visible" : "hidden",
5266
+ animate: we ? "visible" : "hidden",
5265
5267
  className: "max-w-full ml-2 px-2 text-body-small h-0 overflow-hidden whitespace-nowrap",
5266
5268
  transition: { duration: 0.2 },
5267
5269
  children: /* @__PURE__ */ d("span", { className: "transform inline-flex -translate-y-1/2 opacity-0", children: a })
5268
5270
  }
5269
5271
  ),
5270
5272
  /* @__PURE__ */ K("div", { className: "flex-1 relative", children: [
5271
- Ee && /* @__PURE__ */ d(
5273
+ Ce && /* @__PURE__ */ d(
5272
5274
  ne.label,
5273
5275
  {
5274
5276
  htmlFor: S,
@@ -5284,7 +5286,7 @@ const $t = ({
5284
5286
  children: /* @__PURE__ */ d("span", { className: ce.label, children: a })
5285
5287
  }
5286
5288
  ),
5287
- ge && /* @__PURE__ */ d(
5289
+ we && /* @__PURE__ */ d(
5288
5290
  ne.label,
5289
5291
  {
5290
5292
  htmlFor: S,
@@ -5300,58 +5302,56 @@ const $t = ({
5300
5302
  /* @__PURE__ */ d(
5301
5303
  G,
5302
5304
  {
5305
+ ...R,
5303
5306
  ref: T,
5304
5307
  value: Y,
5305
5308
  onChange: N,
5306
- className: y(ce.input, be),
5309
+ className: y(ce.input, xe),
5307
5310
  id: S,
5308
5311
  name: c,
5309
5312
  placeholder: z ? s ?? void 0 : "",
5310
- onFocus: (ve) => {
5311
- k();
5312
- },
5313
- onBlur: W,
5313
+ onFocus: k,
5314
+ onBlur: A,
5314
5315
  disabled: t,
5315
5316
  autoComplete: p,
5316
5317
  "aria-invalid": !!(n != null && n.length),
5317
- "aria-describedby": se ? R : void 0,
5318
- ...ae,
5319
- ...A
5318
+ "aria-describedby": se ? $ : void 0,
5319
+ ...ae
5320
5320
  }
5321
5321
  )
5322
5322
  ] }),
5323
5323
  /* @__PURE__ */ d("div", { className: ce.activeIndicator }),
5324
- !P && /* @__PURE__ */ K(me, { children: [
5325
- ye && /* @__PURE__ */ d(
5324
+ !H && /* @__PURE__ */ K(ye, { children: [
5325
+ ve && /* @__PURE__ */ d(
5326
5326
  "div",
5327
5327
  {
5328
- ref: H ? Z : void 0,
5329
- onClick: (ve) => {
5330
- ve.stopPropagation(), H && ie();
5328
+ ref: P ? Z : void 0,
5329
+ onClick: (fe) => {
5330
+ fe.stopPropagation(), P && ie();
5331
5331
  },
5332
5332
  className: y(
5333
5333
  ce.trailingIcon,
5334
- H && "cursor-pointer"
5334
+ P && "cursor-pointer"
5335
5335
  ),
5336
- children: /* @__PURE__ */ d("div", { className: "flex items-center justify-center w-full h-full", children: Q.isValidElement(ye) ? ye : /* @__PURE__ */ d(
5337
- fe,
5336
+ children: /* @__PURE__ */ d("div", { className: "flex items-center justify-center w-full h-full", children: Q.isValidElement(ve) ? ve : /* @__PURE__ */ d(
5337
+ he,
5338
5338
  {
5339
5339
  className: "h-5",
5340
- icon: ye
5340
+ icon: ve
5341
5341
  }
5342
5342
  ) })
5343
5343
  }
5344
5344
  ),
5345
- !ye && r && /* @__PURE__ */ d("span", { className: ce.suffix, children: r })
5345
+ !ve && r && /* @__PURE__ */ d("span", { className: ce.suffix, children: r })
5346
5346
  ] }),
5347
- P && /* @__PURE__ */ d(
5347
+ H && /* @__PURE__ */ d(
5348
5348
  "div",
5349
5349
  {
5350
5350
  className: y(ce.trailingIcon, {
5351
- " absolute right-0": !ye
5351
+ " absolute right-0": !ve
5352
5352
  }),
5353
5353
  children: /* @__PURE__ */ d(
5354
- fe,
5354
+ he,
5355
5355
  {
5356
5356
  className: "h-5 text-error",
5357
5357
  icon: Xn
@@ -5362,8 +5362,8 @@ const $t = ({
5362
5362
  ]
5363
5363
  }
5364
5364
  ),
5365
- se && /* @__PURE__ */ d("p", { className: ce.supportingText, id: R, children: n != null && n.length ? n : l != null && l.length ? l : " " }),
5366
- H && X && /* @__PURE__ */ K(me, { children: [
5365
+ se && /* @__PURE__ */ d("p", { className: ce.supportingText, id: $, children: n != null && n.length ? n : l != null && l.length ? l : " " }),
5366
+ P && X && /* @__PURE__ */ K(ye, { children: [
5367
5367
  /* @__PURE__ */ d(
5368
5368
  "div",
5369
5369
  {
@@ -5377,12 +5377,12 @@ const $t = ({
5377
5377
  {
5378
5378
  className: "",
5379
5379
  value: ee,
5380
- onChange: $
5380
+ onChange: W
5381
5381
  }
5382
5382
  ),
5383
5383
  /* @__PURE__ */ K("div", { className: "flex justify-end gap-2 p-4 pt-0", children: [
5384
5384
  /* @__PURE__ */ d(
5385
- Ne,
5385
+ Le,
5386
5386
  {
5387
5387
  variant: "text",
5388
5388
  size: "small",
@@ -5391,7 +5391,7 @@ const $t = ({
5391
5391
  }
5392
5392
  ),
5393
5393
  /* @__PURE__ */ d(
5394
- Ne,
5394
+ Le,
5395
5395
  {
5396
5396
  variant: "filled",
5397
5397
  size: "small",
@@ -5460,7 +5460,7 @@ const $t = ({
5460
5460
  ...b
5461
5461
  }) => {
5462
5462
  M && (n = M);
5463
- const g = j(null), O = m || g, [A, v] = V(u);
5463
+ const g = j(null), O = m || g, [R, v] = V(u);
5464
5464
  _(() => {
5465
5465
  u && a == null ? v(!0) : v(a == l && l != null);
5466
5466
  }, [a]), _(() => {
@@ -5471,7 +5471,7 @@ const $t = ({
5471
5471
  icon: c
5472
5472
  });
5473
5473
  }, [a]);
5474
- const S = r ? "a" : "button", R = (F) => {
5474
+ const S = r ? "a" : "button", $ = (F) => {
5475
5475
  i && i(l ?? null), t && t(F);
5476
5476
  }, I = lr({
5477
5477
  isExtended: p,
@@ -5481,11 +5481,11 @@ const $t = ({
5481
5481
  selectedItem: a,
5482
5482
  index: l,
5483
5483
  transition: f,
5484
- selected: A,
5484
+ selected: R,
5485
5485
  variant: s,
5486
5486
  icon: c,
5487
5487
  label: n,
5488
- isSelected: A,
5488
+ isSelected: R,
5489
5489
  setSelectedItem: i,
5490
5490
  href: r,
5491
5491
  children: n,
@@ -5499,11 +5499,11 @@ const $t = ({
5499
5499
  {
5500
5500
  ...b,
5501
5501
  role: "tab",
5502
- "aria-selected": A,
5502
+ "aria-selected": R,
5503
5503
  ref: O,
5504
5504
  href: r,
5505
5505
  className: I.navigationRailItem,
5506
- onClick: R,
5506
+ onClick: $,
5507
5507
  style: { transition: f.duration + "s", ...x },
5508
5508
  children: [
5509
5509
  /* @__PURE__ */ K(
@@ -5516,25 +5516,25 @@ const $t = ({
5516
5516
  className: I.container,
5517
5517
  children: [
5518
5518
  /* @__PURE__ */ d(
5519
- Se,
5519
+ Ne,
5520
5520
  {
5521
5521
  style: { transition: f.duration + "s" },
5522
5522
  className: I.stateLayer,
5523
5523
  colorName: y({
5524
- "on-surface": !A,
5525
- "on-secondary-container": A
5524
+ "on-surface": !R,
5525
+ "on-secondary-container": R
5526
5526
  }),
5527
5527
  stateClassName: "state-ripple-group-[navigation-rail-item]"
5528
5528
  }
5529
5529
  ),
5530
5530
  c && /* @__PURE__ */ d(
5531
- fe,
5531
+ he,
5532
5532
  {
5533
- icon: A ? h : c,
5533
+ icon: R ? h : c,
5534
5534
  className: I.icon
5535
5535
  }
5536
5536
  ),
5537
- /* @__PURE__ */ d(he, { children: s == "horizontal" && (() => {
5537
+ /* @__PURE__ */ d(pe, { children: s == "horizontal" && (() => {
5538
5538
  const F = {
5539
5539
  width: 0,
5540
5540
  opacity: 0,
@@ -5566,7 +5566,7 @@ const $t = ({
5566
5566
  ]
5567
5567
  }
5568
5568
  ),
5569
- /* @__PURE__ */ d(he, { children: s == "vertical" && (() => {
5569
+ /* @__PURE__ */ d(pe, { children: s == "vertical" && (() => {
5570
5570
  const F = {
5571
5571
  height: 0,
5572
5572
  opacity: 0,
@@ -5654,11 +5654,11 @@ const $t = ({
5654
5654
  function O(I) {
5655
5655
  const F = [];
5656
5656
  return Bt.forEach(I, (E) => {
5657
- ke(E) && E.type === Pt ? F.push(...O(E.props.children)) : F.push(E);
5657
+ Ie(E) && E.type === Ht ? F.push(...O(E.props.children)) : F.push(E);
5658
5658
  }), F;
5659
5659
  }
5660
- const A = O(n), v = A.filter(
5661
- (I) => ke(I) && I.type === Be
5660
+ const R = O(n), v = R.filter(
5661
+ (I) => Ie(I) && I.type === Be
5662
5662
  ), S = dr({
5663
5663
  children: n,
5664
5664
  onItemSelected: t,
@@ -5674,8 +5674,8 @@ const $t = ({
5674
5674
  onExtendedChange: o
5675
5675
  });
5676
5676
  u = { duration: 0.3, ...u };
5677
- const R = j(!1);
5678
- return R.current = !1, _(() => {
5677
+ const $ = j(!1);
5678
+ return $.current = !1, _(() => {
5679
5679
  o == null || o(h ?? !1);
5680
5680
  }, [h]), /* @__PURE__ */ K(
5681
5681
  "div",
@@ -5686,7 +5686,7 @@ const $t = ({
5686
5686
  children: [
5687
5687
  /* @__PURE__ */ K("div", { className: S.header, children: [
5688
5688
  /* @__PURE__ */ d(
5689
- Ie,
5689
+ Me,
5690
5690
  {
5691
5691
  onClick: () => x(!h),
5692
5692
  label: h ? i == null ? void 0 : i.opened.label : i == null ? void 0 : i.closed.label,
@@ -5702,7 +5702,7 @@ const $t = ({
5702
5702
  ] }),
5703
5703
  /* @__PURE__ */ d("div", { className: S.segments, children: (() => {
5704
5704
  let I = 0;
5705
- return A.map((F) => ke(F) && F.type === cr ? Re(
5705
+ return R.map((F) => Ie(F) && F.type === cr ? Re(
5706
5706
  F,
5707
5707
  {
5708
5708
  key: I,
@@ -5713,10 +5713,10 @@ const $t = ({
5713
5713
  setSelectedItem: M,
5714
5714
  onItemSelected: g,
5715
5715
  transition: u,
5716
- extendedOnly: R.current,
5716
+ extendedOnly: $.current,
5717
5717
  isExtended: h
5718
5718
  }
5719
- ) : ke(F) && F.type === Be ? null : ke(F) && F.type === ar ? (R.current = !0, h ? Re(F, {}) : null) : F);
5719
+ ) : Ie(F) && F.type === Be ? null : Ie(F) && F.type === ar ? ($.current = !0, h ? Re(F, {}) : null) : F);
5720
5720
  })() }),
5721
5721
  /* @__PURE__ */ d("div", { className: "flex-1 max-h-[160px]" })
5722
5722
  ]
@@ -5733,7 +5733,7 @@ function cs(e) {
5733
5733
  export {
5734
5734
  it as AnchorPositioner,
5735
5735
  kr as AnimateOnScrollInit,
5736
- Ne as Button,
5736
+ Le as Button,
5737
5737
  Kr as Card,
5738
5738
  Gr as Carousel,
5739
5739
  Tn as CarouselItem,
@@ -5745,8 +5745,8 @@ export {
5745
5745
  Dt as Divider,
5746
5746
  Be as Fab,
5747
5747
  Qr as FabMenu,
5748
- fe as Icon,
5749
- Ie as IconButton,
5748
+ he as Icon,
5749
+ Me as IconButton,
5750
5750
  as as NavigationRail,
5751
5751
  cr as NavigationRailItem,
5752
5752
  ar as NavigationRailSection,
@@ -5756,7 +5756,7 @@ export {
5756
5756
  es as Slider,
5757
5757
  Nr as SmoothScroll,
5758
5758
  ns as Snackbar,
5759
- Se as State,
5759
+ Ne as State,
5760
5760
  rs as Switch,
5761
5761
  un as SyncedFixedWrapper,
5762
5762
  tr as Tab,
@@ -5785,11 +5785,11 @@ export {
5785
5785
  Ar as dividerStyle,
5786
5786
  Br as fabMenuStyle,
5787
5787
  Fr as fabStyle,
5788
- Pe as getClassNames,
5789
- Pr as iconButtonStyle,
5788
+ He as getClassNames,
5789
+ Hr as iconButtonStyle,
5790
5790
  ot as initAnimateOnScroll,
5791
- Le as normalize,
5792
- Hr as progressIndicatorStyle,
5791
+ ke as normalize,
5792
+ Pr as progressIndicatorStyle,
5793
5793
  wt as sideSheetConfig,
5794
5794
  Cn as sideSheetStyle,
5795
5795
  bt as sliderConfig,
@@ -5824,7 +5824,7 @@ export {
5824
5824
  Fn as useTabPanelsStyle,
5825
5825
  Wn as useTabStyle,
5826
5826
  An as useTabsStyle,
5827
- Pn as useTextFieldStyle,
5828
- Hn as useToolTipStyle,
5827
+ Hn as useTextFieldStyle,
5828
+ Pn as useToolTipStyle,
5829
5829
  er as useTooltipTrigger
5830
5830
  };