ynotsoft-dynamic-form 1.0.49 → 1.0.50

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.
@@ -1,4 +1,4 @@
1
- import { jsx as u, jsxs as O, Fragment as Ve } from "react/jsx-runtime";
1
+ import { jsx as u, jsxs as I, Fragment as Ve } from "react/jsx-runtime";
2
2
  import * as d from "react";
3
3
  import Ke, { useLayoutEffect as Na, useState as be, forwardRef as os, createElement as uo, useRef as rs, useEffect as fo, useMemo as Ra } from "react";
4
4
  import { toast as fn } from "react-hot-toast";
@@ -294,8 +294,8 @@ var Ha = "DismissableLayer", po = "dismissableLayer.update", Va = "dismissableLa
294
294
  onDismiss: a,
295
295
  ...l
296
296
  } = e, c = d.useContext(as), [f, p] = d.useState(null), g = f?.ownerDocument ?? globalThis?.document, [, m] = d.useState({}), w = le(t, (k) => p(k)), h = Array.from(c.layers), [v] = [...c.layersWithOutsidePointerEventsDisabled].slice(-1), x = h.indexOf(v), S = f ? h.indexOf(f) : -1, C = c.layersWithOutsidePointerEventsDisabled.size > 0, y = S >= x, E = Ka((k) => {
297
- const A = k.target, G = [...c.branches].some((X) => X.contains(A));
298
- !y || G || (r?.(k), i?.(k), k.defaultPrevented || a?.());
297
+ const A = k.target, Y = [...c.branches].some((X) => X.contains(A));
298
+ !y || Y || (r?.(k), i?.(k), k.defaultPrevented || a?.());
299
299
  }, g), F = Xa((k) => {
300
300
  const A = k.target;
301
301
  [...c.branches].some((X) => X.contains(A)) || (s?.(k), i?.(k), k.defaultPrevented || a?.());
@@ -853,14 +853,14 @@ const yl = (e) => ({
853
853
  }, m = Do(r), w = Mo(m), h = await i.getDimensions(c), v = m === "y", x = v ? "top" : "left", S = v ? "bottom" : "right", C = v ? "clientHeight" : "clientWidth", y = s.reference[w] + s.reference[m] - g[m] - s.floating[w], E = g[m] - s.reference[m], F = await (i.getOffsetParent == null ? void 0 : i.getOffsetParent(c));
854
854
  let k = F ? F[C] : 0;
855
855
  (!k || !await (i.isElement == null ? void 0 : i.isElement(F))) && (k = a.floating[C] || s.floating[w]);
856
- const A = y / 2 - E / 2, G = k / 2 - h[w] / 2 - 1, X = Ze(p[x], G), j = Ze(p[S], G), q = X, R = k - h[w] - j, $ = k / 2 - h[w] / 2 + A, W = mo(q, $, R), L = !l.arrow && Et(r) != null && $ !== W && s.reference[w] / 2 - ($ < q ? X : j) - h[w] / 2 < 0, Y = L ? $ < q ? $ - q : $ - R : 0;
856
+ const A = y / 2 - E / 2, Y = k / 2 - h[w] / 2 - 1, X = Ze(p[x], Y), j = Ze(p[S], Y), q = X, T = k - h[w] - j, $ = k / 2 - h[w] / 2 + A, U = mo(q, $, T), L = !l.arrow && Et(r) != null && $ !== U && s.reference[w] / 2 - ($ < q ? X : j) - h[w] / 2 < 0, K = L ? $ < q ? $ - q : $ - T : 0;
857
857
  return {
858
- [m]: g[m] + Y,
858
+ [m]: g[m] + K,
859
859
  data: {
860
- [m]: W,
861
- centerOffset: $ - W - Y,
860
+ [m]: U,
861
+ centerOffset: $ - U - K,
862
862
  ...L && {
863
- alignmentOffset: Y
863
+ alignmentOffset: K
864
864
  }
865
865
  },
866
866
  reset: L
@@ -892,45 +892,45 @@ const yl = (e) => ({
892
892
  return {};
893
893
  const x = Ge(r), S = Me(a), C = Ge(a) === a, y = await (l.isRTL == null ? void 0 : l.isRTL(c.floating)), E = g || (C || !h ? [mn(a)] : fl(a)), F = w !== "none";
894
894
  !g && F && E.push(...gl(a, h, w, y));
895
- const k = [a, ...E], A = await $t(t, v), G = [];
895
+ const k = [a, ...E], A = await $t(t, v), Y = [];
896
896
  let X = ((o = s.flip) == null ? void 0 : o.overflows) || [];
897
- if (f && G.push(A[x]), p) {
897
+ if (f && Y.push(A[x]), p) {
898
898
  const $ = dl(r, i, y);
899
- G.push(A[$[0]], A[$[1]]);
899
+ Y.push(A[$[0]], A[$[1]]);
900
900
  }
901
901
  if (X = [...X, {
902
902
  placement: r,
903
- overflows: G
904
- }], !G.every(($) => $ <= 0)) {
903
+ overflows: Y
904
+ }], !Y.every(($) => $ <= 0)) {
905
905
  var j, q;
906
- const $ = (((j = s.flip) == null ? void 0 : j.index) || 0) + 1, W = k[$];
907
- if (W && (!(p === "alignment" ? S !== Me(W) : !1) || // We leave the current main axis only if every placement on that axis
906
+ const $ = (((j = s.flip) == null ? void 0 : j.index) || 0) + 1, U = k[$];
907
+ if (U && (!(p === "alignment" ? S !== Me(U) : !1) || // We leave the current main axis only if every placement on that axis
908
908
  // overflows the main axis.
909
- X.every((N) => Me(N.placement) === S ? N.overflows[0] > 0 : !0)))
909
+ X.every((R) => Me(R.placement) === S ? R.overflows[0] > 0 : !0)))
910
910
  return {
911
911
  data: {
912
912
  index: $,
913
913
  overflows: X
914
914
  },
915
915
  reset: {
916
- placement: W
916
+ placement: U
917
917
  }
918
918
  };
919
- let L = (q = X.filter((Y) => Y.overflows[0] <= 0).sort((Y, N) => Y.overflows[1] - N.overflows[1])[0]) == null ? void 0 : q.placement;
919
+ let L = (q = X.filter((K) => K.overflows[0] <= 0).sort((K, R) => K.overflows[1] - R.overflows[1])[0]) == null ? void 0 : q.placement;
920
920
  if (!L)
921
921
  switch (m) {
922
922
  case "bestFit": {
923
- var R;
924
- const Y = (R = X.filter((N) => {
923
+ var T;
924
+ const K = (T = X.filter((R) => {
925
925
  if (F) {
926
- const ne = Me(N.placement);
926
+ const ne = Me(R.placement);
927
927
  return ne === S || // Create a bias to the `y` side axis due to horizontal
928
928
  // reading directions favoring greater width.
929
929
  ne === "y";
930
930
  }
931
931
  return !0;
932
- }).map((N) => [N.placement, N.overflows.filter((ne) => ne > 0).reduce((ne, T) => ne + T, 0)]).sort((N, ne) => N[1] - ne[1])[0]) == null ? void 0 : R[0];
933
- Y && (L = Y);
932
+ }).map((R) => [R.placement, R.overflows.filter((ne) => ne > 0).reduce((ne, N) => ne + N, 0)]).sort((R, ne) => R[1] - ne[1])[0]) == null ? void 0 : T[0];
933
+ K && (L = K);
934
934
  break;
935
935
  }
936
936
  case "initialPlacement":
@@ -1172,16 +1172,16 @@ const Cl = function(e) {
1172
1172
  const S = h - f.top - f.bottom, C = w - f.left - f.right, y = Ze(h - f[v], S), E = Ze(w - f[x], C), F = !t.middlewareData.shift;
1173
1173
  let k = y, A = E;
1174
1174
  if ((n = t.middlewareData.shift) != null && n.enabled.x && (A = C), (o = t.middlewareData.shift) != null && o.enabled.y && (k = S), F && !g) {
1175
- const X = Se(f.left, 0), j = Se(f.right, 0), q = Se(f.top, 0), R = Se(f.bottom, 0);
1176
- m ? A = w - 2 * (X !== 0 || j !== 0 ? X + j : Se(f.left, f.right)) : k = h - 2 * (q !== 0 || R !== 0 ? q + R : Se(f.top, f.bottom));
1175
+ const X = Se(f.left, 0), j = Se(f.right, 0), q = Se(f.top, 0), T = Se(f.bottom, 0);
1176
+ m ? A = w - 2 * (X !== 0 || j !== 0 ? X + j : Se(f.left, f.right)) : k = h - 2 * (q !== 0 || T !== 0 ? q + T : Se(f.top, f.bottom));
1177
1177
  }
1178
1178
  await l({
1179
1179
  ...t,
1180
1180
  availableWidth: A,
1181
1181
  availableHeight: k
1182
1182
  });
1183
- const G = await i.getDimensions(a.floating);
1184
- return w !== G.width || h !== G.height ? {
1183
+ const Y = await i.getDimensions(a.floating);
1184
+ return w !== Y.width || h !== Y.height ? {
1185
1185
  reset: {
1186
1186
  rects: !0
1187
1187
  }
@@ -1757,20 +1757,20 @@ function lc(e) {
1757
1757
  isPositioned: !1
1758
1758
  }), [g, m] = d.useState(o);
1759
1759
  gn(g, o) || m(o);
1760
- const [w, h] = d.useState(null), [v, x] = d.useState(null), S = d.useCallback((N) => {
1761
- N !== F.current && (F.current = N, h(N));
1762
- }, []), C = d.useCallback((N) => {
1763
- N !== k.current && (k.current = N, x(N));
1764
- }, []), y = s || w, E = i || v, F = d.useRef(null), k = d.useRef(null), A = d.useRef(f), G = l != null, X = Xn(l), j = Xn(r), q = Xn(c), R = d.useCallback(() => {
1760
+ const [w, h] = d.useState(null), [v, x] = d.useState(null), S = d.useCallback((R) => {
1761
+ R !== F.current && (F.current = R, h(R));
1762
+ }, []), C = d.useCallback((R) => {
1763
+ R !== k.current && (k.current = R, x(R));
1764
+ }, []), y = s || w, E = i || v, F = d.useRef(null), k = d.useRef(null), A = d.useRef(f), Y = l != null, X = Xn(l), j = Xn(r), q = Xn(c), T = d.useCallback(() => {
1765
1765
  if (!F.current || !k.current)
1766
1766
  return;
1767
- const N = {
1767
+ const R = {
1768
1768
  placement: t,
1769
1769
  strategy: n,
1770
1770
  middleware: g
1771
1771
  };
1772
- j.current && (N.platform = j.current), sc(F.current, k.current, N).then((ne) => {
1773
- const T = {
1772
+ j.current && (R.platform = j.current), sc(F.current, k.current, R).then((ne) => {
1773
+ const N = {
1774
1774
  ...ne,
1775
1775
  // The floating element's position may be recomputed while it's closed
1776
1776
  // but still mounted (such as when transitioning out). To ensure
@@ -1778,14 +1778,14 @@ function lc(e) {
1778
1778
  // setting it to `true` when `open === false` (must be specified).
1779
1779
  isPositioned: q.current !== !1
1780
1780
  };
1781
- $.current && !gn(A.current, T) && (A.current = T, wn.flushSync(() => {
1782
- p(T);
1781
+ $.current && !gn(A.current, N) && (A.current = N, wn.flushSync(() => {
1782
+ p(N);
1783
1783
  }));
1784
1784
  });
1785
1785
  }, [g, t, n, j, q]);
1786
1786
  ln(() => {
1787
- c === !1 && A.current.isPositioned && (A.current.isPositioned = !1, p((N) => ({
1788
- ...N,
1787
+ c === !1 && A.current.isPositioned && (A.current.isPositioned = !1, p((R) => ({
1788
+ ...R,
1789
1789
  isPositioned: !1
1790
1790
  })));
1791
1791
  }, [c]);
@@ -1795,11 +1795,11 @@ function lc(e) {
1795
1795
  }), []), ln(() => {
1796
1796
  if (y && (F.current = y), E && (k.current = E), y && E) {
1797
1797
  if (X.current)
1798
- return X.current(y, E, R);
1799
- R();
1798
+ return X.current(y, E, T);
1799
+ T();
1800
1800
  }
1801
- }, [y, E, R, X, G]);
1802
- const W = d.useMemo(() => ({
1801
+ }, [y, E, T, X, Y]);
1802
+ const U = d.useMemo(() => ({
1803
1803
  reference: F,
1804
1804
  floating: k,
1805
1805
  setReference: S,
@@ -1807,34 +1807,34 @@ function lc(e) {
1807
1807
  }), [S, C]), L = d.useMemo(() => ({
1808
1808
  reference: y,
1809
1809
  floating: E
1810
- }), [y, E]), Y = d.useMemo(() => {
1811
- const N = {
1810
+ }), [y, E]), K = d.useMemo(() => {
1811
+ const R = {
1812
1812
  position: n,
1813
1813
  left: 0,
1814
1814
  top: 0
1815
1815
  };
1816
1816
  if (!L.floating)
1817
- return N;
1818
- const ne = Or(L.floating, f.x), T = Or(L.floating, f.y);
1817
+ return R;
1818
+ const ne = Or(L.floating, f.x), N = Or(L.floating, f.y);
1819
1819
  return a ? {
1820
- ...N,
1821
- transform: "translate(" + ne + "px, " + T + "px)",
1820
+ ...R,
1821
+ transform: "translate(" + ne + "px, " + N + "px)",
1822
1822
  ...xs(L.floating) >= 1.5 && {
1823
1823
  willChange: "transform"
1824
1824
  }
1825
1825
  } : {
1826
1826
  position: n,
1827
1827
  left: ne,
1828
- top: T
1828
+ top: N
1829
1829
  };
1830
1830
  }, [n, a, L.floating, f.x, f.y]);
1831
1831
  return d.useMemo(() => ({
1832
1832
  ...f,
1833
- update: R,
1834
- refs: W,
1833
+ update: T,
1834
+ refs: U,
1835
1835
  elements: L,
1836
- floatingStyles: Y
1837
- }), [f, R, W, L, Y]);
1836
+ floatingStyles: K
1837
+ }), [f, T, U, L, K]);
1838
1838
  }
1839
1839
  const cc = (e) => {
1840
1840
  function t(n) {
@@ -1998,15 +1998,15 @@ var Bo = "PopperContent", [Cc, Ec] = As(Bo), Ps = d.forwardRef(
1998
1998
  updatePositionStrategy: m = "optimized",
1999
1999
  onPlaced: w,
2000
2000
  ...h
2001
- } = e, v = Ns(Bo, n), [x, S] = d.useState(null), C = le(t, (D) => S(D)), [y, E] = d.useState(null), F = Es(y), k = F?.width ?? 0, A = F?.height ?? 0, G = o + (s !== "center" ? "-" + s : ""), X = typeof f == "number" ? f : { top: 0, right: 0, bottom: 0, left: 0, ...f }, j = Array.isArray(c) ? c : [c], q = j.length > 0, R = {
2001
+ } = e, v = Ns(Bo, n), [x, S] = d.useState(null), C = le(t, (D) => S(D)), [y, E] = d.useState(null), F = Es(y), k = F?.width ?? 0, A = F?.height ?? 0, Y = o + (s !== "center" ? "-" + s : ""), X = typeof f == "number" ? f : { top: 0, right: 0, bottom: 0, left: 0, ...f }, j = Array.isArray(c) ? c : [c], q = j.length > 0, T = {
2002
2002
  padding: X,
2003
2003
  boundary: j.filter(Nc),
2004
2004
  // with `strategy: 'fixed'`, this is the only way to get it to respect boundaries
2005
2005
  altBoundary: q
2006
- }, { refs: $, floatingStyles: W, placement: L, isPositioned: Y, middlewareData: N } = lc({
2006
+ }, { refs: $, floatingStyles: U, placement: L, isPositioned: K, middlewareData: R } = lc({
2007
2007
  // default to `fixed` strategy so users don't have to pick and we also avoid focus scroll issues
2008
2008
  strategy: "fixed",
2009
- placement: G,
2009
+ placement: Y,
2010
2010
  whileElementsMounted: (...D) => Ql(...D, {
2011
2011
  animationFrame: m === "always"
2012
2012
  }),
@@ -2019,11 +2019,11 @@ var Bo = "PopperContent", [Cc, Ec] = As(Bo), Ps = d.forwardRef(
2019
2019
  mainAxis: !0,
2020
2020
  crossAxis: !1,
2021
2021
  limiter: p === "partial" ? fc() : void 0,
2022
- ...R
2022
+ ...T
2023
2023
  }),
2024
- l && pc({ ...R }),
2024
+ l && pc({ ...T }),
2025
2025
  mc({
2026
- ...R,
2026
+ ...T,
2027
2027
  apply: ({ elements: D, rects: ee, availableWidth: ie, availableHeight: Q }) => {
2028
2028
  const { width: oe, height: se } = ee.reference, ue = D.floating.style;
2029
2029
  ue.setProperty("--radix-popper-available-width", `${ie}px`), ue.setProperty("--radix-popper-available-height", `${Q}px`), ue.setProperty("--radix-popper-anchor-width", `${oe}px`), ue.setProperty("--radix-popper-anchor-height", `${se}px`);
@@ -2031,13 +2031,13 @@ var Bo = "PopperContent", [Cc, Ec] = As(Bo), Ps = d.forwardRef(
2031
2031
  }),
2032
2032
  y && gc({ element: y, padding: a }),
2033
2033
  Rc({ arrowWidth: k, arrowHeight: A }),
2034
- g && hc({ strategy: "referenceHidden", ...R })
2034
+ g && hc({ strategy: "referenceHidden", ...T })
2035
2035
  ]
2036
- }), [ne, T] = Is(L), _ = qe(w);
2036
+ }), [ne, N] = Is(L), _ = qe(w);
2037
2037
  he(() => {
2038
- Y && _?.();
2039
- }, [Y, _]);
2040
- const V = N.arrow?.x, I = N.arrow?.y, K = N.arrow?.centerOffset !== 0, [M, re] = d.useState();
2038
+ K && _?.();
2039
+ }, [K, _]);
2040
+ const V = R.arrow?.x, O = R.arrow?.y, G = R.arrow?.centerOffset !== 0, [M, re] = d.useState();
2041
2041
  return he(() => {
2042
2042
  x && re(window.getComputedStyle(x).zIndex);
2043
2043
  }, [x]), /* @__PURE__ */ u(
@@ -2046,19 +2046,19 @@ var Bo = "PopperContent", [Cc, Ec] = As(Bo), Ps = d.forwardRef(
2046
2046
  ref: $.setFloating,
2047
2047
  "data-radix-popper-content-wrapper": "",
2048
2048
  style: {
2049
- ...W,
2050
- transform: Y ? W.transform : "translate(0, -200%)",
2049
+ ...U,
2050
+ transform: K ? U.transform : "translate(0, -200%)",
2051
2051
  // keep off the page when measuring
2052
2052
  minWidth: "max-content",
2053
2053
  zIndex: M,
2054
2054
  "--radix-popper-transform-origin": [
2055
- N.transformOrigin?.x,
2056
- N.transformOrigin?.y
2055
+ R.transformOrigin?.x,
2056
+ R.transformOrigin?.y
2057
2057
  ].join(" "),
2058
2058
  // hide the content if using the hide middleware and should be hidden
2059
2059
  // set visibility to hidden and disable pointer events so the UI behaves
2060
2060
  // as if the PopperContent isn't there at all
2061
- ...N.hide?.referenceHidden && {
2061
+ ...R.hide?.referenceHidden && {
2062
2062
  visibility: "hidden",
2063
2063
  pointerEvents: "none"
2064
2064
  }
@@ -2071,20 +2071,20 @@ var Bo = "PopperContent", [Cc, Ec] = As(Bo), Ps = d.forwardRef(
2071
2071
  placedSide: ne,
2072
2072
  onArrowChange: E,
2073
2073
  arrowX: V,
2074
- arrowY: I,
2075
- shouldHideArrow: K,
2074
+ arrowY: O,
2075
+ shouldHideArrow: G,
2076
2076
  children: /* @__PURE__ */ u(
2077
2077
  Cs.div,
2078
2078
  {
2079
2079
  "data-side": ne,
2080
- "data-align": T,
2080
+ "data-align": N,
2081
2081
  ...h,
2082
2082
  ref: C,
2083
2083
  style: {
2084
2084
  ...h.style,
2085
2085
  // if the PopperContent hasn't been placed yet (not all measurements done)
2086
2086
  // we prevent animations so that users's animation don't kick in too early referring wrong sides
2087
- animation: Y ? void 0 : "none"
2087
+ animation: K ? void 0 : "none"
2088
2088
  }
2089
2089
  }
2090
2090
  )
@@ -2773,8 +2773,8 @@ function xu(e) {
2773
2773
  return !1;
2774
2774
  if (!o.current && "changedTouches" in h && (C || y) && (o.current = E), !E)
2775
2775
  return !0;
2776
- var G = o.current || E;
2777
- return bu(G, v, h, G === "h" ? C : y);
2776
+ var Y = o.current || E;
2777
+ return bu(Y, v, h, Y === "h" ? C : y);
2778
2778
  }, []), l = d.useCallback(function(h) {
2779
2779
  var v = h;
2780
2780
  if (!(!vt.length || vt[vt.length - 1] !== s)) {
@@ -2859,13 +2859,13 @@ var Eu = [" ", "Enter", "ArrowUp", "ArrowDown"], Au = [" ", "Enter"], at = "Sele
2859
2859
  defaultProp: r ?? !1,
2860
2860
  onChange: s,
2861
2861
  caller: at
2862
- }), [G, X] = Bt({
2862
+ }), [Y, X] = Bt({
2863
2863
  prop: i,
2864
2864
  defaultProp: a,
2865
2865
  onChange: l,
2866
2866
  caller: at
2867
- }), j = d.useRef(null), q = v ? w || !!v.closest("form") : !0, [R, $] = d.useState(/* @__PURE__ */ new Set()), W = Array.from(R).map((L) => L.props.value).join(";");
2868
- return /* @__PURE__ */ u(Ms, { ...h, children: /* @__PURE__ */ O(
2867
+ }), j = d.useRef(null), q = v ? w || !!v.closest("form") : !0, [T, $] = d.useState(/* @__PURE__ */ new Set()), U = Array.from(T).map((L) => L.props.value).join(";");
2868
+ return /* @__PURE__ */ u(Ms, { ...h, children: /* @__PURE__ */ I(
2869
2869
  Ru,
2870
2870
  {
2871
2871
  required: m,
@@ -2877,7 +2877,7 @@ var Eu = [" ", "Enter", "ArrowUp", "ArrowDown"], Au = [" ", "Enter"], at = "Sele
2877
2877
  valueNodeHasChildren: y,
2878
2878
  onValueNodeHasChildrenChange: E,
2879
2879
  contentId: Ut(),
2880
- value: G,
2880
+ value: Y,
2881
2881
  onValueChange: X,
2882
2882
  open: k,
2883
2883
  onOpenChange: A,
@@ -2890,18 +2890,18 @@ var Eu = [" ", "Enter", "ArrowUp", "ArrowDown"], Au = [" ", "Enter"], at = "Sele
2890
2890
  {
2891
2891
  scope: e.__scopeSelect,
2892
2892
  onNativeOptionAdd: d.useCallback((L) => {
2893
- $((Y) => new Set(Y).add(L));
2893
+ $((K) => new Set(K).add(L));
2894
2894
  }, []),
2895
2895
  onNativeOptionRemove: d.useCallback((L) => {
2896
- $((Y) => {
2897
- const N = new Set(Y);
2898
- return N.delete(L), N;
2896
+ $((K) => {
2897
+ const R = new Set(K);
2898
+ return R.delete(L), R;
2899
2899
  });
2900
2900
  }, []),
2901
2901
  children: n
2902
2902
  }
2903
2903
  ) }),
2904
- q ? /* @__PURE__ */ O(
2904
+ q ? /* @__PURE__ */ I(
2905
2905
  vi,
2906
2906
  {
2907
2907
  "aria-hidden": !0,
@@ -2909,16 +2909,16 @@ var Eu = [" ", "Enter", "ArrowUp", "ArrowDown"], Au = [" ", "Enter"], at = "Sele
2909
2909
  tabIndex: -1,
2910
2910
  name: f,
2911
2911
  autoComplete: p,
2912
- value: G,
2912
+ value: Y,
2913
2913
  onChange: (L) => X(L.target.value),
2914
2914
  disabled: g,
2915
2915
  form: w,
2916
2916
  children: [
2917
- G === void 0 ? /* @__PURE__ */ u("option", { value: "" }) : null,
2918
- Array.from(R)
2917
+ Y === void 0 ? /* @__PURE__ */ u("option", { value: "" }) : null,
2918
+ Array.from(T)
2919
2919
  ]
2920
2920
  },
2921
- W
2921
+ U
2922
2922
  ) : null
2923
2923
  ]
2924
2924
  }
@@ -3033,9 +3033,9 @@ var Te = 10, [ni, et] = Nt(lt), Ou = "SelectContentImpl", Iu = /* @__PURE__ */ x
3033
3033
  avoidCollisions: v,
3034
3034
  //
3035
3035
  ...x
3036
- } = e, S = Je(lt, n), [C, y] = d.useState(null), [E, F] = d.useState(null), k = le(t, (D) => y(D)), [A, G] = d.useState(null), [X, j] = d.useState(
3036
+ } = e, S = Je(lt, n), [C, y] = d.useState(null), [E, F] = d.useState(null), k = le(t, (D) => y(D)), [A, Y] = d.useState(null), [X, j] = d.useState(
3037
3037
  null
3038
- ), q = Tn(n), [R, $] = d.useState(!1), W = d.useRef(!1);
3038
+ ), q = Tn(n), [T, $] = d.useState(!1), U = d.useRef(!1);
3039
3039
  d.useEffect(() => {
3040
3040
  if (C) return Bs(C);
3041
3041
  }, [C]), cs();
@@ -3046,14 +3046,14 @@ var Te = 10, [ni, et] = Nt(lt), Ou = "SelectContentImpl", Iu = /* @__PURE__ */ x
3046
3046
  if (se === oe || (se?.scrollIntoView({ block: "nearest" }), se === ee && E && (E.scrollTop = 0), se === Q && E && (E.scrollTop = E.scrollHeight), se?.focus(), document.activeElement !== oe)) return;
3047
3047
  },
3048
3048
  [q, E]
3049
- ), Y = d.useCallback(
3049
+ ), K = d.useCallback(
3050
3050
  () => L([A, C]),
3051
3051
  [L, A, C]
3052
3052
  );
3053
3053
  d.useEffect(() => {
3054
- R && Y();
3055
- }, [R, Y]);
3056
- const { onOpenChange: N, triggerPointerDownPosRef: ne } = S;
3054
+ T && K();
3055
+ }, [T, K]);
3056
+ const { onOpenChange: R, triggerPointerDownPosRef: ne } = S;
3057
3057
  d.useEffect(() => {
3058
3058
  if (C) {
3059
3059
  let D = { x: 0, y: 0 };
@@ -3063,30 +3063,30 @@ var Te = 10, [ni, et] = Nt(lt), Ou = "SelectContentImpl", Iu = /* @__PURE__ */ x
3063
3063
  y: Math.abs(Math.round(Q.pageY) - (ne.current?.y ?? 0))
3064
3064
  };
3065
3065
  }, ie = (Q) => {
3066
- D.x <= 10 && D.y <= 10 ? Q.preventDefault() : C.contains(Q.target) || N(!1), document.removeEventListener("pointermove", ee), ne.current = null;
3066
+ D.x <= 10 && D.y <= 10 ? Q.preventDefault() : C.contains(Q.target) || R(!1), document.removeEventListener("pointermove", ee), ne.current = null;
3067
3067
  };
3068
3068
  return ne.current !== null && (document.addEventListener("pointermove", ee), document.addEventListener("pointerup", ie, { capture: !0, once: !0 })), () => {
3069
3069
  document.removeEventListener("pointermove", ee), document.removeEventListener("pointerup", ie, { capture: !0 });
3070
3070
  };
3071
3071
  }
3072
- }, [C, N, ne]), d.useEffect(() => {
3073
- const D = () => N(!1);
3072
+ }, [C, R, ne]), d.useEffect(() => {
3073
+ const D = () => R(!1);
3074
3074
  return window.addEventListener("blur", D), window.addEventListener("resize", D), () => {
3075
3075
  window.removeEventListener("blur", D), window.removeEventListener("resize", D);
3076
3076
  };
3077
- }, [N]);
3078
- const [T, _] = wi((D) => {
3077
+ }, [R]);
3078
+ const [N, _] = wi((D) => {
3079
3079
  const ee = q().filter((oe) => !oe.disabled), ie = ee.find((oe) => oe.ref.current === document.activeElement), Q = xi(ee, D, ie);
3080
3080
  Q && setTimeout(() => Q.ref.current.focus());
3081
3081
  }), V = d.useCallback(
3082
3082
  (D, ee, ie) => {
3083
- const Q = !W.current && !ie;
3084
- (S.value !== void 0 && S.value === ee || Q) && (G(D), Q && (W.current = !0));
3083
+ const Q = !U.current && !ie;
3084
+ (S.value !== void 0 && S.value === ee || Q) && (Y(D), Q && (U.current = !0));
3085
3085
  },
3086
3086
  [S.value]
3087
- ), I = d.useCallback(() => C?.focus(), [C]), K = d.useCallback(
3087
+ ), O = d.useCallback(() => C?.focus(), [C]), G = d.useCallback(
3088
3088
  (D, ee, ie) => {
3089
- const Q = !W.current && !ie;
3089
+ const Q = !U.current && !ie;
3090
3090
  (S.value !== void 0 && S.value === ee || Q) && j(D);
3091
3091
  },
3092
3092
  [S.value]
@@ -3111,13 +3111,13 @@ var Te = 10, [ni, et] = Nt(lt), Ou = "SelectContentImpl", Iu = /* @__PURE__ */ x
3111
3111
  onViewportChange: F,
3112
3112
  itemRefCallback: V,
3113
3113
  selectedItem: A,
3114
- onItemLeave: I,
3115
- itemTextRefCallback: K,
3116
- focusSelectedItem: Y,
3114
+ onItemLeave: O,
3115
+ itemTextRefCallback: G,
3116
+ focusSelectedItem: K,
3117
3117
  selectedItemText: X,
3118
3118
  position: o,
3119
- isPositioned: R,
3120
- searchRef: T,
3119
+ isPositioned: T,
3120
+ searchRef: N,
3121
3121
  children: /* @__PURE__ */ u(Ho, { as: Iu, allowPinchZoom: !0, children: /* @__PURE__ */ u(
3122
3122
  Oo,
3123
3123
  {
@@ -3183,9 +3183,9 @@ oi.displayName = Ou;
3183
3183
  var Mu = "SelectItemAlignedPosition", ri = d.forwardRef((e, t) => {
3184
3184
  const { __scopeSelect: n, onPlaced: o, ...r } = e, s = Je(lt, n), i = et(lt, n), [a, l] = d.useState(null), [c, f] = d.useState(null), p = le(t, (k) => f(k)), g = Tn(n), m = d.useRef(!1), w = d.useRef(!0), { viewport: h, selectedItem: v, selectedItemText: x, focusSelectedItem: S } = i, C = d.useCallback(() => {
3185
3185
  if (s.trigger && s.valueNode && a && c && h && v && x) {
3186
- const k = s.trigger.getBoundingClientRect(), A = c.getBoundingClientRect(), G = s.valueNode.getBoundingClientRect(), X = x.getBoundingClientRect();
3186
+ const k = s.trigger.getBoundingClientRect(), A = c.getBoundingClientRect(), Y = s.valueNode.getBoundingClientRect(), X = x.getBoundingClientRect();
3187
3187
  if (s.dir !== "rtl") {
3188
- const oe = X.left - A.left, se = G.left - oe, ue = k.left - se, Ae = k.width + ue, Re = Math.max(Ae, A.width), nt = window.innerWidth - Te, ot = pr(se, [
3188
+ const oe = X.left - A.left, se = Y.left - oe, ue = k.left - se, Ae = k.width + ue, Re = Math.max(Ae, A.width), nt = window.innerWidth - Te, ot = pr(se, [
3189
3189
  Te,
3190
3190
  // Prevents the content from going off the starting edge of the
3191
3191
  // viewport. It may still go off the ending edge, but this can be
@@ -3196,33 +3196,33 @@ var Mu = "SelectItemAlignedPosition", ri = d.forwardRef((e, t) => {
3196
3196
  ]);
3197
3197
  a.style.minWidth = Ae + "px", a.style.left = ot + "px";
3198
3198
  } else {
3199
- const oe = A.right - X.right, se = window.innerWidth - G.right - oe, ue = window.innerWidth - k.right - se, Ae = k.width + ue, Re = Math.max(Ae, A.width), nt = window.innerWidth - Te, ot = pr(se, [
3199
+ const oe = A.right - X.right, se = window.innerWidth - Y.right - oe, ue = window.innerWidth - k.right - se, Ae = k.width + ue, Re = Math.max(Ae, A.width), nt = window.innerWidth - Te, ot = pr(se, [
3200
3200
  Te,
3201
3201
  Math.max(Te, nt - Re)
3202
3202
  ]);
3203
3203
  a.style.minWidth = Ae + "px", a.style.right = ot + "px";
3204
3204
  }
3205
- const j = g(), q = window.innerHeight - Te * 2, R = h.scrollHeight, $ = window.getComputedStyle(c), W = parseInt($.borderTopWidth, 10), L = parseInt($.paddingTop, 10), Y = parseInt($.borderBottomWidth, 10), N = parseInt($.paddingBottom, 10), ne = W + L + R + N + Y, T = Math.min(v.offsetHeight * 5, ne), _ = window.getComputedStyle(h), V = parseInt(_.paddingTop, 10), I = parseInt(_.paddingBottom, 10), K = k.top + k.height / 2 - Te, M = q - K, re = v.offsetHeight / 2, D = v.offsetTop + re, ee = W + L + D, ie = ne - ee;
3206
- if (ee <= K) {
3205
+ const j = g(), q = window.innerHeight - Te * 2, T = h.scrollHeight, $ = window.getComputedStyle(c), U = parseInt($.borderTopWidth, 10), L = parseInt($.paddingTop, 10), K = parseInt($.borderBottomWidth, 10), R = parseInt($.paddingBottom, 10), ne = U + L + T + R + K, N = Math.min(v.offsetHeight * 5, ne), _ = window.getComputedStyle(h), V = parseInt(_.paddingTop, 10), O = parseInt(_.paddingBottom, 10), G = k.top + k.height / 2 - Te, M = q - G, re = v.offsetHeight / 2, D = v.offsetTop + re, ee = U + L + D, ie = ne - ee;
3206
+ if (ee <= G) {
3207
3207
  const oe = j.length > 0 && v === j[j.length - 1].ref.current;
3208
3208
  a.style.bottom = "0px";
3209
3209
  const se = c.clientHeight - h.offsetTop - h.offsetHeight, ue = Math.max(
3210
3210
  M,
3211
3211
  re + // viewport might have padding bottom, include it to avoid a scrollable viewport
3212
- (oe ? I : 0) + se + Y
3212
+ (oe ? O : 0) + se + K
3213
3213
  ), Ae = ee + ue;
3214
3214
  a.style.height = Ae + "px";
3215
3215
  } else {
3216
3216
  const oe = j.length > 0 && v === j[0].ref.current;
3217
3217
  a.style.top = "0px";
3218
3218
  const ue = Math.max(
3219
- K,
3220
- W + h.offsetTop + // viewport might have padding top, include it to avoid a scrollable viewport
3219
+ G,
3220
+ U + h.offsetTop + // viewport might have padding top, include it to avoid a scrollable viewport
3221
3221
  (oe ? V : 0) + re
3222
3222
  ) + ie;
3223
- a.style.height = ue + "px", h.scrollTop = ee - K + h.offsetTop;
3223
+ a.style.height = ue + "px", h.scrollTop = ee - G + h.offsetTop;
3224
3224
  }
3225
- a.style.margin = `${Te}px 0`, a.style.minHeight = T + "px", a.style.maxHeight = q + "px", o?.(), requestAnimationFrame(() => m.current = !0);
3225
+ a.style.margin = `${Te}px 0`, a.style.minHeight = N + "px", a.style.maxHeight = q + "px", o?.(), requestAnimationFrame(() => m.current = !0);
3226
3226
  }
3227
3227
  }, [
3228
3228
  g,
@@ -3317,7 +3317,7 @@ vo.displayName = Du;
3317
3317
  var [Lu, Vo] = Nt(lt, {}), yo = "SelectViewport", si = d.forwardRef(
3318
3318
  (e, t) => {
3319
3319
  const { __scopeSelect: n, nonce: o, ...r } = e, s = et(yo, n), i = Vo(yo, n), a = le(t, s.onViewportChange), l = d.useRef(0);
3320
- return /* @__PURE__ */ O(Ve, { children: [
3320
+ return /* @__PURE__ */ I(Ve, { children: [
3321
3321
  /* @__PURE__ */ u(
3322
3322
  "style",
3323
3323
  {
@@ -3470,7 +3470,7 @@ var Ft = "SelectItemText", fi = d.forwardRef(
3470
3470
  () => /* @__PURE__ */ u("option", { value: l.value, disabled: l.disabled, children: m }, l.value),
3471
3471
  [l.disabled, l.value, m]
3472
3472
  ), { onNativeOptionAdd: h, onNativeOptionRemove: v } = c;
3473
- return he(() => (h(w), () => v(w)), [h, v, w]), /* @__PURE__ */ O(Ve, { children: [
3473
+ return he(() => (h(w), () => v(w)), [h, v, w]), /* @__PURE__ */ I(Ve, { children: [
3474
3474
  /* @__PURE__ */ u(Ee.span, { id: l.textId, ...s, ref: g }),
3475
3475
  l.isSelected && i.valueNode && !i.valueNodeHasChildren ? wn.createPortal(s.children, i.valueNode) : null
3476
3476
  ] });
@@ -3732,15 +3732,15 @@ const Rd = [
3732
3732
  ], Td = $e("x", Rd);
3733
3733
  function kd({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r }) {
3734
3734
  const s = t[e.name] || "", i = typeof e.disabled == "function" ? e.disabled(t) : e.disabled, a = e.options || [];
3735
- return /* @__PURE__ */ O(Ve, { children: [
3736
- /* @__PURE__ */ O(
3735
+ return /* @__PURE__ */ I(Ve, { children: [
3736
+ /* @__PURE__ */ I(
3737
3737
  ju,
3738
3738
  {
3739
3739
  value: s,
3740
3740
  onValueChange: (l) => n(e.name, l),
3741
3741
  disabled: i,
3742
3742
  children: [
3743
- /* @__PURE__ */ O(
3743
+ /* @__PURE__ */ I(
3744
3744
  Gu,
3745
3745
  {
3746
3746
  id: e.name,
@@ -3760,7 +3760,7 @@ function kd({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
3760
3760
  ]
3761
3761
  }
3762
3762
  ),
3763
- /* @__PURE__ */ u(Xu, { children: /* @__PURE__ */ O(
3763
+ /* @__PURE__ */ u(Xu, { children: /* @__PURE__ */ I(
3764
3764
  qu,
3765
3765
  {
3766
3766
  className: "bg-white border border-gray-200 rounded-md shadow-lg z-50 min-w-[var(--radix-select-trigger-width)]",
@@ -3768,7 +3768,7 @@ function kd({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
3768
3768
  sideOffset: 5,
3769
3769
  children: [
3770
3770
  /* @__PURE__ */ u(nd, { className: "flex items-center justify-center h-6 text-gray-500 bg-gray-50", children: /* @__PURE__ */ u($r, { className: "fill-white stroke-gray-200" }) }),
3771
- /* @__PURE__ */ O(Zu, { className: "p-1", children: [
3771
+ /* @__PURE__ */ I(Zu, { className: "p-1", children: [
3772
3772
  e.groupLabel && /* @__PURE__ */ u(Qu, { children: /* @__PURE__ */ u(Ju, { className: "px-2 py-1 text-xs text-gray-500 uppercase tracking-wide", children: e.groupLabel }) }),
3773
3773
  a.map((l) => /* @__PURE__ */ u(
3774
3774
  ed,
@@ -3828,7 +3828,7 @@ function Br({
3828
3828
  disabled: s
3829
3829
  }) {
3830
3830
  const i = s;
3831
- return /* @__PURE__ */ O(Ve, { children: [
3831
+ return /* @__PURE__ */ I(Ve, { children: [
3832
3832
  " ",
3833
3833
  /* @__PURE__ */ u(
3834
3834
  "input",
@@ -4026,7 +4026,7 @@ function Ni() {
4026
4026
  implementation: F,
4027
4027
  createNodeIterator: k,
4028
4028
  createDocumentFragment: A,
4029
- getElementsByTagName: G
4029
+ getElementsByTagName: Y
4030
4030
  } = n, {
4031
4031
  importNode: X
4032
4032
  } = o;
@@ -4034,20 +4034,20 @@ function Ni() {
4034
4034
  t.isSupported = typeof Ci == "function" && typeof C == "function" && F && F.createHTMLDocument !== void 0;
4035
4035
  const {
4036
4036
  MUSTACHE_EXPR: q,
4037
- ERB_EXPR: R,
4037
+ ERB_EXPR: T,
4038
4038
  TMPLIT_EXPR: $,
4039
- DATA_ATTR: W,
4039
+ DATA_ATTR: U,
4040
4040
  ARIA_ATTR: L,
4041
- IS_SCRIPT_OR_DATA: Y,
4042
- ATTR_WHITESPACE: N,
4041
+ IS_SCRIPT_OR_DATA: K,
4042
+ ATTR_WHITESPACE: R,
4043
4043
  CUSTOM_ELEMENT: ne
4044
4044
  } = Yr;
4045
4045
  let {
4046
- IS_ALLOWED_URI: T
4046
+ IS_ALLOWED_URI: N
4047
4047
  } = Yr, _ = null;
4048
4048
  const V = J({}, [...Hr, ...no, ...oo, ...ro, ...Vr]);
4049
- let I = null;
4050
- const K = J({}, [...jr, ...so, ...Gr, ...on]);
4049
+ let O = null;
4050
+ const G = J({}, [...jr, ...so, ...Gr, ...on]);
4051
4051
  let M = Object.seal(Co(null, {
4052
4052
  tagNameCheck: {
4053
4053
  writable: !0,
@@ -4103,7 +4103,7 @@ function Ni() {
4103
4103
  let b = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
4104
4104
  if (!(mt && mt === b)) {
4105
4105
  if ((!b || typeof b != "object") && (b = {}), b = He(b), Pt = // eslint-disable-next-line unicorn/prefer-includes
4106
- xa.indexOf(b.PARSER_MEDIA_TYPE) === -1 ? Sa : b.PARSER_MEDIA_TYPE, fe = Pt === "application/xhtml+xml" ? eo : dn, _ = ke(b, "ALLOWED_TAGS") ? J({}, b.ALLOWED_TAGS, fe) : V, I = ke(b, "ALLOWED_ATTR") ? J({}, b.ALLOWED_ATTR, fe) : K, Un = ke(b, "ALLOWED_NAMESPACES") ? J({}, b.ALLOWED_NAMESPACES, eo) : ya, zn = ke(b, "ADD_URI_SAFE_ATTR") ? J(He(Jo), b.ADD_URI_SAFE_ATTR, fe) : Jo, Zo = ke(b, "ADD_DATA_URI_TAGS") ? J(He(Qo), b.ADD_DATA_URI_TAGS, fe) : Qo, ft = ke(b, "FORBID_CONTENTS") ? J({}, b.FORBID_CONTENTS, fe) : qo, re = ke(b, "FORBID_TAGS") ? J({}, b.FORBID_TAGS, fe) : He({}), D = ke(b, "FORBID_ATTR") ? J({}, b.FORBID_ATTR, fe) : He({}), dt = ke(b, "USE_PROFILES") ? b.USE_PROFILES : !1, ie = b.ALLOW_ARIA_ATTR !== !1, Q = b.ALLOW_DATA_ATTR !== !1, oe = b.ALLOW_UNKNOWN_PROTOCOLS || !1, se = b.ALLOW_SELF_CLOSE_IN_ATTR !== !1, ue = b.SAFE_FOR_TEMPLATES || !1, Ae = b.SAFE_FOR_XML !== !1, Re = b.WHOLE_DOCUMENT || !1, ut = b.RETURN_DOM || !1, jt = b.RETURN_DOM_FRAGMENT || !1, Gt = b.RETURN_TRUSTED_TYPE || !1, ot = b.FORCE_BODY || !1, Ko = b.SANITIZE_DOM !== !1, Xo = b.SANITIZE_NAMED_PROPS || !1, $n = b.KEEP_CONTENT !== !1, kt = b.IN_PLACE || !1, T = b.ALLOWED_URI_REGEXP || Ei, pt = b.NAMESPACE || ze, Xt = b.MATHML_TEXT_INTEGRATION_POINTS || Xt, qt = b.HTML_INTEGRATION_POINTS || qt, M = b.CUSTOM_ELEMENT_HANDLING || {}, b.CUSTOM_ELEMENT_HANDLING && er(b.CUSTOM_ELEMENT_HANDLING.tagNameCheck) && (M.tagNameCheck = b.CUSTOM_ELEMENT_HANDLING.tagNameCheck), b.CUSTOM_ELEMENT_HANDLING && er(b.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) && (M.attributeNameCheck = b.CUSTOM_ELEMENT_HANDLING.attributeNameCheck), b.CUSTOM_ELEMENT_HANDLING && typeof b.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements == "boolean" && (M.allowCustomizedBuiltInElements = b.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements), ue && (Q = !1), jt && (ut = !0), dt && (_ = J({}, Vr), I = [], dt.html === !0 && (J(_, Hr), J(I, jr)), dt.svg === !0 && (J(_, no), J(I, so), J(I, on)), dt.svgFilters === !0 && (J(_, oo), J(I, so), J(I, on)), dt.mathMl === !0 && (J(_, ro), J(I, Gr), J(I, on))), b.ADD_TAGS && (typeof b.ADD_TAGS == "function" ? ee.tagCheck = b.ADD_TAGS : (_ === V && (_ = He(_)), J(_, b.ADD_TAGS, fe))), b.ADD_ATTR && (typeof b.ADD_ATTR == "function" ? ee.attributeCheck = b.ADD_ATTR : (I === K && (I = He(I)), J(I, b.ADD_ATTR, fe))), b.ADD_URI_SAFE_ATTR && J(zn, b.ADD_URI_SAFE_ATTR, fe), b.FORBID_CONTENTS && (ft === qo && (ft = He(ft)), J(ft, b.FORBID_CONTENTS, fe)), $n && (_["#text"] = !0), Re && J(_, ["html", "head", "body"]), _.table && (J(_, ["tbody"]), delete re.tbody), b.TRUSTED_TYPES_POLICY) {
4106
+ xa.indexOf(b.PARSER_MEDIA_TYPE) === -1 ? Sa : b.PARSER_MEDIA_TYPE, fe = Pt === "application/xhtml+xml" ? eo : dn, _ = ke(b, "ALLOWED_TAGS") ? J({}, b.ALLOWED_TAGS, fe) : V, O = ke(b, "ALLOWED_ATTR") ? J({}, b.ALLOWED_ATTR, fe) : G, Un = ke(b, "ALLOWED_NAMESPACES") ? J({}, b.ALLOWED_NAMESPACES, eo) : ya, zn = ke(b, "ADD_URI_SAFE_ATTR") ? J(He(Jo), b.ADD_URI_SAFE_ATTR, fe) : Jo, Zo = ke(b, "ADD_DATA_URI_TAGS") ? J(He(Qo), b.ADD_DATA_URI_TAGS, fe) : Qo, ft = ke(b, "FORBID_CONTENTS") ? J({}, b.FORBID_CONTENTS, fe) : qo, re = ke(b, "FORBID_TAGS") ? J({}, b.FORBID_TAGS, fe) : He({}), D = ke(b, "FORBID_ATTR") ? J({}, b.FORBID_ATTR, fe) : He({}), dt = ke(b, "USE_PROFILES") ? b.USE_PROFILES : !1, ie = b.ALLOW_ARIA_ATTR !== !1, Q = b.ALLOW_DATA_ATTR !== !1, oe = b.ALLOW_UNKNOWN_PROTOCOLS || !1, se = b.ALLOW_SELF_CLOSE_IN_ATTR !== !1, ue = b.SAFE_FOR_TEMPLATES || !1, Ae = b.SAFE_FOR_XML !== !1, Re = b.WHOLE_DOCUMENT || !1, ut = b.RETURN_DOM || !1, jt = b.RETURN_DOM_FRAGMENT || !1, Gt = b.RETURN_TRUSTED_TYPE || !1, ot = b.FORCE_BODY || !1, Ko = b.SANITIZE_DOM !== !1, Xo = b.SANITIZE_NAMED_PROPS || !1, $n = b.KEEP_CONTENT !== !1, kt = b.IN_PLACE || !1, N = b.ALLOWED_URI_REGEXP || Ei, pt = b.NAMESPACE || ze, Xt = b.MATHML_TEXT_INTEGRATION_POINTS || Xt, qt = b.HTML_INTEGRATION_POINTS || qt, M = b.CUSTOM_ELEMENT_HANDLING || {}, b.CUSTOM_ELEMENT_HANDLING && er(b.CUSTOM_ELEMENT_HANDLING.tagNameCheck) && (M.tagNameCheck = b.CUSTOM_ELEMENT_HANDLING.tagNameCheck), b.CUSTOM_ELEMENT_HANDLING && er(b.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) && (M.attributeNameCheck = b.CUSTOM_ELEMENT_HANDLING.attributeNameCheck), b.CUSTOM_ELEMENT_HANDLING && typeof b.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements == "boolean" && (M.allowCustomizedBuiltInElements = b.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements), ue && (Q = !1), jt && (ut = !0), dt && (_ = J({}, Vr), O = [], dt.html === !0 && (J(_, Hr), J(O, jr)), dt.svg === !0 && (J(_, no), J(O, so), J(O, on)), dt.svgFilters === !0 && (J(_, oo), J(O, so), J(O, on)), dt.mathMl === !0 && (J(_, ro), J(O, Gr), J(O, on))), b.ADD_TAGS && (typeof b.ADD_TAGS == "function" ? ee.tagCheck = b.ADD_TAGS : (_ === V && (_ = He(_)), J(_, b.ADD_TAGS, fe))), b.ADD_ATTR && (typeof b.ADD_ATTR == "function" ? ee.attributeCheck = b.ADD_ATTR : (O === G && (O = He(O)), J(O, b.ADD_ATTR, fe))), b.ADD_URI_SAFE_ATTR && J(zn, b.ADD_URI_SAFE_ATTR, fe), b.FORBID_CONTENTS && (ft === qo && (ft = He(ft)), J(ft, b.FORBID_CONTENTS, fe)), $n && (_["#text"] = !0), Re && J(_, ["html", "head", "body"]), _.table && (J(_, ["tbody"]), delete re.tbody), b.TRUSTED_TYPES_POLICY) {
4107
4107
  if (typeof b.TRUSTED_TYPES_POLICY.createHTML != "function")
4108
4108
  throw It('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');
4109
4109
  if (typeof b.TRUSTED_TYPES_POLICY.createScriptURL != "function")
@@ -4119,8 +4119,8 @@ function Ni() {
4119
4119
  namespaceURI: pt,
4120
4120
  tagName: "template"
4121
4121
  });
4122
- const U = dn(b.tagName), ae = dn(P.tagName);
4123
- return Un[b.namespaceURI] ? b.namespaceURI === Kt ? P.namespaceURI === ze ? U === "svg" : P.namespaceURI === Yt ? U === "svg" && (ae === "annotation-xml" || Xt[ae]) : !!tr[U] : b.namespaceURI === Yt ? P.namespaceURI === ze ? U === "math" : P.namespaceURI === Kt ? U === "math" && qt[ae] : !!nr[U] : b.namespaceURI === ze ? P.namespaceURI === Kt && !qt[ae] || P.namespaceURI === Yt && !Xt[ae] ? !1 : !nr[U] && (wa[U] || !tr[U]) : !!(Pt === "application/xhtml+xml" && Un[b.namespaceURI]) : !1;
4122
+ const W = dn(b.tagName), ae = dn(P.tagName);
4123
+ return Un[b.namespaceURI] ? b.namespaceURI === Kt ? P.namespaceURI === ze ? W === "svg" : P.namespaceURI === Yt ? W === "svg" && (ae === "annotation-xml" || Xt[ae]) : !!tr[W] : b.namespaceURI === Yt ? P.namespaceURI === ze ? W === "math" : P.namespaceURI === Kt ? W === "math" && qt[ae] : !!nr[W] : b.namespaceURI === ze ? P.namespaceURI === Kt && !qt[ae] || P.namespaceURI === Yt && !Xt[ae] ? !1 : !nr[W] && (wa[W] || !tr[W]) : !!(Pt === "application/xhtml+xml" && Un[b.namespaceURI]) : !1;
4124
4124
  }, Oe = function(b) {
4125
4125
  _t(t.removed, {
4126
4126
  element: b
@@ -4154,12 +4154,12 @@ function Ni() {
4154
4154
  } catch {
4155
4155
  }
4156
4156
  }, or = function(b) {
4157
- let P = null, U = null;
4157
+ let P = null, W = null;
4158
4158
  if (ot)
4159
4159
  b = "<remove></remove>" + b;
4160
4160
  else {
4161
4161
  const ce = to(b, /^[\r\n\t ]+/);
4162
- U = ce && ce[0];
4162
+ W = ce && ce[0];
4163
4163
  }
4164
4164
  Pt === "application/xhtml+xml" && pt === ze && (b = '<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>' + b + "</body></html>");
4165
4165
  const ae = y ? y.createHTML(b) : b;
@@ -4176,7 +4176,7 @@ function Ni() {
4176
4176
  }
4177
4177
  }
4178
4178
  const me = P.body || P.documentElement;
4179
- return b && U && me.insertBefore(n.createTextNode(U), me.childNodes[0] || null), pt === ze ? G.call(P, Re ? "html" : "body")[0] : Re ? P.documentElement : me;
4179
+ return b && W && me.insertBefore(n.createTextNode(W), me.childNodes[0] || null), pt === ze ? Y.call(P, Re ? "html" : "body")[0] : Re ? P.documentElement : me;
4180
4180
  }, rr = function(b) {
4181
4181
  return k.call(
4182
4182
  b.ownerDocument || b,
@@ -4191,24 +4191,24 @@ function Ni() {
4191
4191
  return typeof a == "function" && b instanceof a;
4192
4192
  };
4193
4193
  function Be(H, b, P) {
4194
- nn(H, (U) => {
4195
- U.call(t, b, P, mt);
4194
+ nn(H, (W) => {
4195
+ W.call(t, b, P, mt);
4196
4196
  });
4197
4197
  }
4198
4198
  const ir = function(b) {
4199
4199
  let P = null;
4200
4200
  if (Be(j.beforeSanitizeElements, b, null), Hn(b))
4201
4201
  return Oe(b), !0;
4202
- const U = fe(b.nodeName);
4202
+ const W = fe(b.nodeName);
4203
4203
  if (Be(j.uponSanitizeElement, b, {
4204
- tagName: U,
4204
+ tagName: W,
4205
4205
  allowedTags: _
4206
4206
  }), Ae && b.hasChildNodes() && !sr(b.firstElementChild) && ge(/<[/\w!]/g, b.innerHTML) && ge(/<[/\w!]/g, b.textContent) || b.nodeType === Dt.progressingInstruction || Ae && b.nodeType === Dt.comment && ge(/<[/\w]/g, b.data))
4207
4207
  return Oe(b), !0;
4208
- if (!(ee.tagCheck instanceof Function && ee.tagCheck(U)) && (!_[U] || re[U])) {
4209
- if (!re[U] && lr(U) && (M.tagNameCheck instanceof RegExp && ge(M.tagNameCheck, U) || M.tagNameCheck instanceof Function && M.tagNameCheck(U)))
4208
+ if (!(ee.tagCheck instanceof Function && ee.tagCheck(W)) && (!_[W] || re[W])) {
4209
+ if (!re[W] && lr(W) && (M.tagNameCheck instanceof RegExp && ge(M.tagNameCheck, W) || M.tagNameCheck instanceof Function && M.tagNameCheck(W)))
4210
4210
  return !1;
4211
- if ($n && !ft[U]) {
4211
+ if ($n && !ft[W]) {
4212
4212
  const ae = C(b) || b.parentNode, me = S(b) || b.childNodes;
4213
4213
  if (me && ae) {
4214
4214
  const ce = me.length;
@@ -4220,31 +4220,31 @@ function Ni() {
4220
4220
  }
4221
4221
  return Oe(b), !0;
4222
4222
  }
4223
- return b instanceof l && !Ea(b) || (U === "noscript" || U === "noembed" || U === "noframes") && ge(/<\/no(script|embed|frames)/i, b.innerHTML) ? (Oe(b), !0) : (ue && b.nodeType === Dt.text && (P = b.textContent, nn([q, R, $], (ae) => {
4223
+ return b instanceof l && !Ea(b) || (W === "noscript" || W === "noembed" || W === "noframes") && ge(/<\/no(script|embed|frames)/i, b.innerHTML) ? (Oe(b), !0) : (ue && b.nodeType === Dt.text && (P = b.textContent, nn([q, T, $], (ae) => {
4224
4224
  P = Ot(P, ae, " ");
4225
4225
  }), b.textContent !== P && (_t(t.removed, {
4226
4226
  element: b.cloneNode()
4227
4227
  }), b.textContent = P)), Be(j.afterSanitizeElements, b, null), !1);
4228
- }, ar = function(b, P, U) {
4229
- if (Ko && (P === "id" || P === "name") && (U in n || U in Ca))
4228
+ }, ar = function(b, P, W) {
4229
+ if (Ko && (P === "id" || P === "name") && (W in n || W in Ca))
4230
4230
  return !1;
4231
- if (!(Q && !D[P] && ge(W, P))) {
4231
+ if (!(Q && !D[P] && ge(U, P))) {
4232
4232
  if (!(ie && ge(L, P))) {
4233
4233
  if (!(ee.attributeCheck instanceof Function && ee.attributeCheck(P, b))) {
4234
- if (!I[P] || D[P]) {
4234
+ if (!O[P] || D[P]) {
4235
4235
  if (
4236
4236
  // First condition does a very basic check if a) it's basically a valid custom element tagname AND
4237
4237
  // b) if the tagName passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
4238
4238
  // and c) if the attribute name passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.attributeNameCheck
4239
4239
  !(lr(b) && (M.tagNameCheck instanceof RegExp && ge(M.tagNameCheck, b) || M.tagNameCheck instanceof Function && M.tagNameCheck(b)) && (M.attributeNameCheck instanceof RegExp && ge(M.attributeNameCheck, P) || M.attributeNameCheck instanceof Function && M.attributeNameCheck(P, b)) || // Alternative, second condition checks if it's an `is`-attribute, AND
4240
4240
  // the value passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
4241
- P === "is" && M.allowCustomizedBuiltInElements && (M.tagNameCheck instanceof RegExp && ge(M.tagNameCheck, U) || M.tagNameCheck instanceof Function && M.tagNameCheck(U)))
4241
+ P === "is" && M.allowCustomizedBuiltInElements && (M.tagNameCheck instanceof RegExp && ge(M.tagNameCheck, W) || M.tagNameCheck instanceof Function && M.tagNameCheck(W)))
4242
4242
  ) return !1;
4243
4243
  } else if (!zn[P]) {
4244
- if (!ge(T, Ot(U, N, ""))) {
4245
- if (!((P === "src" || P === "xlink:href" || P === "href") && b !== "script" && Ld(U, "data:") === 0 && Zo[b])) {
4246
- if (!(oe && !ge(Y, Ot(U, N, "")))) {
4247
- if (U)
4244
+ if (!ge(N, Ot(W, R, ""))) {
4245
+ if (!((P === "src" || P === "xlink:href" || P === "href") && b !== "script" && Ld(W, "data:") === 0 && Zo[b])) {
4246
+ if (!(oe && !ge(K, Ot(W, R, "")))) {
4247
+ if (W)
4248
4248
  return !1;
4249
4249
  }
4250
4250
  }
@@ -4263,11 +4263,11 @@ function Ni() {
4263
4263
  } = b;
4264
4264
  if (!P || Hn(b))
4265
4265
  return;
4266
- const U = {
4266
+ const W = {
4267
4267
  attrName: "",
4268
4268
  attrValue: "",
4269
4269
  keepAttr: !0,
4270
- allowedAttributes: I,
4270
+ allowedAttributes: O,
4271
4271
  forceKeepAttr: void 0
4272
4272
  };
4273
4273
  let ae = P.length;
@@ -4278,7 +4278,7 @@ function Ni() {
4278
4278
  value: Ue
4279
4279
  } = me, ht = fe(ce), Vn = Ue;
4280
4280
  let pe = ce === "value" ? Vn : Fd(Vn);
4281
- if (U.attrName = ht, U.attrValue = pe, U.keepAttr = !0, U.forceKeepAttr = void 0, Be(j.uponSanitizeAttribute, b, U), pe = U.attrValue, Xo && (ht === "id" || ht === "name") && (rt(ce, b), pe = va + pe), Ae && ge(/((--!?|])>)|<\/(style|title|textarea)/i, pe)) {
4281
+ if (W.attrName = ht, W.attrValue = pe, W.keepAttr = !0, W.forceKeepAttr = void 0, Be(j.uponSanitizeAttribute, b, W), pe = W.attrValue, Xo && (ht === "id" || ht === "name") && (rt(ce, b), pe = va + pe), Ae && ge(/((--!?|])>)|<\/(style|title|textarea)/i, pe)) {
4282
4282
  rt(ce, b);
4283
4283
  continue;
4284
4284
  }
@@ -4286,9 +4286,9 @@ function Ni() {
4286
4286
  rt(ce, b);
4287
4287
  continue;
4288
4288
  }
4289
- if (U.forceKeepAttr)
4289
+ if (W.forceKeepAttr)
4290
4290
  continue;
4291
- if (!U.keepAttr) {
4291
+ if (!W.keepAttr) {
4292
4292
  rt(ce, b);
4293
4293
  continue;
4294
4294
  }
@@ -4296,7 +4296,7 @@ function Ni() {
4296
4296
  rt(ce, b);
4297
4297
  continue;
4298
4298
  }
4299
- ue && nn([q, R, $], (dr) => {
4299
+ ue && nn([q, T, $], (dr) => {
4300
4300
  pe = Ot(pe, dr, " ");
4301
4301
  });
4302
4302
  const ur = fe(b.nodeName);
@@ -4325,13 +4325,13 @@ function Ni() {
4325
4325
  Be(j.afterSanitizeAttributes, b, null);
4326
4326
  }, Aa = function H(b) {
4327
4327
  let P = null;
4328
- const U = rr(b);
4329
- for (Be(j.beforeSanitizeShadowDOM, b, null); P = U.nextNode(); )
4328
+ const W = rr(b);
4329
+ for (Be(j.beforeSanitizeShadowDOM, b, null); P = W.nextNode(); )
4330
4330
  Be(j.uponSanitizeShadowNode, P, null), ir(P), cr(P), P.content instanceof s && H(P.content);
4331
4331
  Be(j.afterSanitizeShadowDOM, b, null);
4332
4332
  };
4333
4333
  return t.sanitize = function(H) {
4334
- let b = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, P = null, U = null, ae = null, me = null;
4334
+ let b = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, P = null, W = null, ae = null, me = null;
4335
4335
  if (Bn = !H, Bn && (H = "<!-->"), typeof H != "string" && !sr(H))
4336
4336
  if (typeof H.toString == "function") {
4337
4337
  if (H = H.toString(), typeof H != "string")
@@ -4347,7 +4347,7 @@ function Ni() {
4347
4347
  throw It("root node is forbidden and cannot be sanitized in-place");
4348
4348
  }
4349
4349
  } else if (H instanceof a)
4350
- P = or("<!---->"), U = P.ownerDocument.importNode(H, !0), U.nodeType === Dt.element && U.nodeName === "BODY" || U.nodeName === "HTML" ? P = U : P.appendChild(U);
4350
+ P = or("<!---->"), W = P.ownerDocument.importNode(H, !0), W.nodeType === Dt.element && W.nodeName === "BODY" || W.nodeName === "HTML" ? P = W : P.appendChild(W);
4351
4351
  else {
4352
4352
  if (!ut && !ue && !Re && // eslint-disable-next-line unicorn/prefer-includes
4353
4353
  H.indexOf("<") === -1)
@@ -4367,11 +4367,11 @@ function Ni() {
4367
4367
  me.appendChild(P.firstChild);
4368
4368
  else
4369
4369
  me = P;
4370
- return (I.shadowroot || I.shadowrootmode) && (me = X.call(o, me, !0)), me;
4370
+ return (O.shadowroot || O.shadowrootmode) && (me = X.call(o, me, !0)), me;
4371
4371
  }
4372
4372
  let we = Re ? P.outerHTML : P.innerHTML;
4373
4373
  return Re && _["!doctype"] && P.ownerDocument && P.ownerDocument.doctype && P.ownerDocument.doctype.name && ge(Ai, P.ownerDocument.doctype.name) && (we = "<!DOCTYPE " + P.ownerDocument.doctype.name + `>
4374
- ` + we), ue && nn([q, R, $], (Ue) => {
4374
+ ` + we), ue && nn([q, T, $], (Ue) => {
4375
4375
  we = Ot(we, Ue, " ");
4376
4376
  }), y && Gt ? y.createHTML(we) : we;
4377
4377
  }, t.setConfig = function() {
@@ -4381,8 +4381,8 @@ function Ni() {
4381
4381
  mt = null, nt = !1;
4382
4382
  }, t.isValidAttribute = function(H, b, P) {
4383
4383
  mt || Wn({});
4384
- const U = fe(H), ae = fe(b);
4385
- return ar(U, ae, P);
4384
+ const W = fe(H), ae = fe(b);
4385
+ return ar(W, ae, P);
4386
4386
  }, t.addHook = function(H, b) {
4387
4387
  typeof b == "function" && _t(j[H], b);
4388
4388
  }, t.removeHook = function(H, b) {
@@ -4404,7 +4404,7 @@ function ef({ field: e, formValues: t, disabled: n }) {
4404
4404
  w-full px-3 py-2 border rounded-md overflow-y-auto max-h-40 prose prose-sm max-w-none shadow-inner transition duration-150
4405
4405
  ${o ? "bg-gray-100 text-gray-500 border-gray-300 cursor-not-allowed" : "bg-white text-gray-800 border-gray-200 hover:border-gray-300"}
4406
4406
  `.trim();
4407
- return /* @__PURE__ */ O("div", { className: s, id: `${e.name}_id`, children: [
4407
+ return /* @__PURE__ */ I("div", { className: s, id: `${e.name}_id`, children: [
4408
4408
  /* @__PURE__ */ u("label", { htmlFor: e.name, className: "block text-sm font-medium mb-1", children: e.label }),
4409
4409
  /* @__PURE__ */ u(
4410
4410
  "div",
@@ -4428,7 +4428,7 @@ function tf({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
4428
4428
  className: a ? "grid grid-cols-4 gap-3 mt-3" : "space-y-3 mt-3",
4429
4429
  children: i.map((p) => {
4430
4430
  const g = typeof p == "object" ? p.value : p, m = typeof p == "object" ? p.label : p, w = typeof p == "object" ? p.description : null, h = `${e.name}-${g}`, v = l.includes(g);
4431
- return /* @__PURE__ */ O("div", { className: "relative flex items-start", children: [
4431
+ return /* @__PURE__ */ I("div", { className: "relative flex items-start", children: [
4432
4432
  /* @__PURE__ */ u("div", { className: "flex h-6 items-center", children: /* @__PURE__ */ u(
4433
4433
  "input",
4434
4434
  {
@@ -4447,8 +4447,8 @@ function tf({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
4447
4447
  `
4448
4448
  }
4449
4449
  ) }),
4450
- /* @__PURE__ */ O("div", { className: "ml-3 text-sm", children: [
4451
- /* @__PURE__ */ O(
4450
+ /* @__PURE__ */ I("div", { className: "ml-3 text-sm", children: [
4451
+ /* @__PURE__ */ I(
4452
4452
  "label",
4453
4453
  {
4454
4454
  htmlFor: h,
@@ -4472,7 +4472,7 @@ function tf({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
4472
4472
  }
4473
4473
  ) });
4474
4474
  }
4475
- return /* @__PURE__ */ u("div", { className: "mt-1", children: /* @__PURE__ */ O("div", { className: "space-x-2", children: [
4475
+ return /* @__PURE__ */ u("div", { className: "mt-1", children: /* @__PURE__ */ I("div", { className: "space-x-2", children: [
4476
4476
  /* @__PURE__ */ u(
4477
4477
  "input",
4478
4478
  {
@@ -4486,7 +4486,7 @@ function tf({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
4486
4486
  className: `rounded border-gray-300 ${s ? "opacity-50 cursor-not-allowed" : ""} ${r ? "border-red-500" : ""}`
4487
4487
  }
4488
4488
  ),
4489
- /* @__PURE__ */ O("label", { className: "", htmlFor: "id_" + e.name, children: [
4489
+ /* @__PURE__ */ I("label", { className: "", htmlFor: "id_" + e.name, children: [
4490
4490
  e.label,
4491
4491
  e.required && /* @__PURE__ */ u("span", { className: "text-red-500", children: "*" })
4492
4492
  ] })
@@ -5106,15 +5106,15 @@ const Sf = (e, t) => {
5106
5106
  "bottom-left",
5107
5107
  // Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378
5108
5108
  "left-bottom"
5109
- ], E = () => [...y(), B, z], F = () => ["auto", "hidden", "clip", "visible", "scroll"], k = () => ["auto", "contain", "none"], A = () => [B, z, l], G = () => [yt, "full", "auto", ...A()], X = () => [Ye, "none", "subgrid", B, z], j = () => ["auto", {
5109
+ ], E = () => [...y(), B, z], F = () => ["auto", "hidden", "clip", "visible", "scroll"], k = () => ["auto", "contain", "none"], A = () => [B, z, l], Y = () => [yt, "full", "auto", ...A()], X = () => [Ye, "none", "subgrid", B, z], j = () => ["auto", {
5110
5110
  span: ["full", Ye, B, z]
5111
- }, Ye, B, z], q = () => [Ye, "auto", B, z], R = () => ["auto", "min", "max", "fr", B, z], $ = () => ["start", "end", "center", "between", "around", "evenly", "stretch", "baseline", "center-safe", "end-safe"], W = () => ["start", "end", "center", "stretch", "center-safe", "end-safe"], L = () => ["auto", ...A()], Y = () => [yt, "auto", "full", "dvw", "dvh", "lvw", "lvh", "svw", "svh", "min", "max", "fit", ...A()], N = () => [e, B, z], ne = () => [...y(), Jr, Qr, {
5111
+ }, Ye, B, z], q = () => [Ye, "auto", B, z], T = () => ["auto", "min", "max", "fr", B, z], $ = () => ["start", "end", "center", "between", "around", "evenly", "stretch", "baseline", "center-safe", "end-safe"], U = () => ["start", "end", "center", "stretch", "center-safe", "end-safe"], L = () => ["auto", ...A()], K = () => [yt, "auto", "full", "dvw", "dvh", "lvw", "lvh", "svw", "svh", "min", "max", "fit", ...A()], R = () => [e, B, z], ne = () => [...y(), Jr, Qr, {
5112
5112
  position: [B, z]
5113
- }], T = () => ["no-repeat", {
5113
+ }], N = () => ["no-repeat", {
5114
5114
  repeat: ["", "x", "y", "space", "round"]
5115
5115
  }], _ = () => ["auto", "cover", "contain", rp, tp, {
5116
5116
  size: [B, z]
5117
- }], V = () => [io, Lt, st], I = () => [
5117
+ }], V = () => [io, Lt, st], O = () => [
5118
5118
  // Deprecated since Tailwind CSS v4.0.0
5119
5119
  "",
5120
5120
  "none",
@@ -5122,7 +5122,7 @@ const Sf = (e, t) => {
5122
5122
  c,
5123
5123
  B,
5124
5124
  z
5125
- ], K = () => ["", Z, Lt, st], M = () => ["solid", "dashed", "dotted", "double"], re = () => ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"], D = () => [Z, io, Jr, Qr], ee = () => [
5125
+ ], G = () => ["", Z, Lt, st], M = () => ["solid", "dashed", "dotted", "double"], re = () => ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"], D = () => [Z, io, Jr, Qr], ee = () => [
5126
5126
  // Deprecated since Tailwind CSS v4.0.0
5127
5127
  "",
5128
5128
  "none",
@@ -5307,63 +5307,63 @@ const Sf = (e, t) => {
5307
5307
  * @see https://tailwindcss.com/docs/top-right-bottom-left
5308
5308
  */
5309
5309
  inset: [{
5310
- inset: G()
5310
+ inset: Y()
5311
5311
  }],
5312
5312
  /**
5313
5313
  * Right / Left
5314
5314
  * @see https://tailwindcss.com/docs/top-right-bottom-left
5315
5315
  */
5316
5316
  "inset-x": [{
5317
- "inset-x": G()
5317
+ "inset-x": Y()
5318
5318
  }],
5319
5319
  /**
5320
5320
  * Top / Bottom
5321
5321
  * @see https://tailwindcss.com/docs/top-right-bottom-left
5322
5322
  */
5323
5323
  "inset-y": [{
5324
- "inset-y": G()
5324
+ "inset-y": Y()
5325
5325
  }],
5326
5326
  /**
5327
5327
  * Start
5328
5328
  * @see https://tailwindcss.com/docs/top-right-bottom-left
5329
5329
  */
5330
5330
  start: [{
5331
- start: G()
5331
+ start: Y()
5332
5332
  }],
5333
5333
  /**
5334
5334
  * End
5335
5335
  * @see https://tailwindcss.com/docs/top-right-bottom-left
5336
5336
  */
5337
5337
  end: [{
5338
- end: G()
5338
+ end: Y()
5339
5339
  }],
5340
5340
  /**
5341
5341
  * Top
5342
5342
  * @see https://tailwindcss.com/docs/top-right-bottom-left
5343
5343
  */
5344
5344
  top: [{
5345
- top: G()
5345
+ top: Y()
5346
5346
  }],
5347
5347
  /**
5348
5348
  * Right
5349
5349
  * @see https://tailwindcss.com/docs/top-right-bottom-left
5350
5350
  */
5351
5351
  right: [{
5352
- right: G()
5352
+ right: Y()
5353
5353
  }],
5354
5354
  /**
5355
5355
  * Bottom
5356
5356
  * @see https://tailwindcss.com/docs/top-right-bottom-left
5357
5357
  */
5358
5358
  bottom: [{
5359
- bottom: G()
5359
+ bottom: Y()
5360
5360
  }],
5361
5361
  /**
5362
5362
  * Left
5363
5363
  * @see https://tailwindcss.com/docs/top-right-bottom-left
5364
5364
  */
5365
5365
  left: [{
5366
- left: G()
5366
+ left: Y()
5367
5367
  }],
5368
5368
  /**
5369
5369
  * Visibility
@@ -5497,14 +5497,14 @@ const Sf = (e, t) => {
5497
5497
  * @see https://tailwindcss.com/docs/grid-auto-columns
5498
5498
  */
5499
5499
  "auto-cols": [{
5500
- "auto-cols": R()
5500
+ "auto-cols": T()
5501
5501
  }],
5502
5502
  /**
5503
5503
  * Grid Auto Rows
5504
5504
  * @see https://tailwindcss.com/docs/grid-auto-rows
5505
5505
  */
5506
5506
  "auto-rows": [{
5507
- "auto-rows": R()
5507
+ "auto-rows": T()
5508
5508
  }],
5509
5509
  /**
5510
5510
  * Gap
@@ -5539,14 +5539,14 @@ const Sf = (e, t) => {
5539
5539
  * @see https://tailwindcss.com/docs/justify-items
5540
5540
  */
5541
5541
  "justify-items": [{
5542
- "justify-items": [...W(), "normal"]
5542
+ "justify-items": [...U(), "normal"]
5543
5543
  }],
5544
5544
  /**
5545
5545
  * Justify Self
5546
5546
  * @see https://tailwindcss.com/docs/justify-self
5547
5547
  */
5548
5548
  "justify-self": [{
5549
- "justify-self": ["auto", ...W()]
5549
+ "justify-self": ["auto", ...U()]
5550
5550
  }],
5551
5551
  /**
5552
5552
  * Align Content
@@ -5560,7 +5560,7 @@ const Sf = (e, t) => {
5560
5560
  * @see https://tailwindcss.com/docs/align-items
5561
5561
  */
5562
5562
  "align-items": [{
5563
- items: [...W(), {
5563
+ items: [...U(), {
5564
5564
  baseline: ["", "last"]
5565
5565
  }]
5566
5566
  }],
@@ -5569,7 +5569,7 @@ const Sf = (e, t) => {
5569
5569
  * @see https://tailwindcss.com/docs/align-self
5570
5570
  */
5571
5571
  "align-self": [{
5572
- self: ["auto", ...W(), {
5572
+ self: ["auto", ...U(), {
5573
5573
  baseline: ["", "last"]
5574
5574
  }]
5575
5575
  }],
@@ -5585,14 +5585,14 @@ const Sf = (e, t) => {
5585
5585
  * @see https://tailwindcss.com/docs/place-items
5586
5586
  */
5587
5587
  "place-items": [{
5588
- "place-items": [...W(), "baseline"]
5588
+ "place-items": [...U(), "baseline"]
5589
5589
  }],
5590
5590
  /**
5591
5591
  * Place Self
5592
5592
  * @see https://tailwindcss.com/docs/place-self
5593
5593
  */
5594
5594
  "place-self": [{
5595
- "place-self": ["auto", ...W()]
5595
+ "place-self": ["auto", ...U()]
5596
5596
  }],
5597
5597
  // Spacing
5598
5598
  /**
@@ -5753,14 +5753,14 @@ const Sf = (e, t) => {
5753
5753
  * @see https://tailwindcss.com/docs/width#setting-both-width-and-height
5754
5754
  */
5755
5755
  size: [{
5756
- size: Y()
5756
+ size: K()
5757
5757
  }],
5758
5758
  /**
5759
5759
  * Width
5760
5760
  * @see https://tailwindcss.com/docs/width
5761
5761
  */
5762
5762
  w: [{
5763
- w: [a, "screen", ...Y()]
5763
+ w: [a, "screen", ...K()]
5764
5764
  }],
5765
5765
  /**
5766
5766
  * Min-Width
@@ -5772,7 +5772,7 @@ const Sf = (e, t) => {
5772
5772
  "screen",
5773
5773
  /** Deprecated. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */
5774
5774
  "none",
5775
- ...Y()
5775
+ ...K()
5776
5776
  ]
5777
5777
  }],
5778
5778
  /**
@@ -5790,7 +5790,7 @@ const Sf = (e, t) => {
5790
5790
  {
5791
5791
  screen: [i]
5792
5792
  },
5793
- ...Y()
5793
+ ...K()
5794
5794
  ]
5795
5795
  }],
5796
5796
  /**
@@ -5798,21 +5798,21 @@ const Sf = (e, t) => {
5798
5798
  * @see https://tailwindcss.com/docs/height
5799
5799
  */
5800
5800
  h: [{
5801
- h: ["screen", "lh", ...Y()]
5801
+ h: ["screen", "lh", ...K()]
5802
5802
  }],
5803
5803
  /**
5804
5804
  * Min-Height
5805
5805
  * @see https://tailwindcss.com/docs/min-height
5806
5806
  */
5807
5807
  "min-h": [{
5808
- "min-h": ["screen", "lh", "none", ...Y()]
5808
+ "min-h": ["screen", "lh", "none", ...K()]
5809
5809
  }],
5810
5810
  /**
5811
5811
  * Max-Height
5812
5812
  * @see https://tailwindcss.com/docs/max-height
5813
5813
  */
5814
5814
  "max-h": [{
5815
- "max-h": ["screen", "lh", ...Y()]
5815
+ "max-h": ["screen", "lh", ...K()]
5816
5816
  }],
5817
5817
  // ------------------
5818
5818
  // --- Typography ---
@@ -5944,14 +5944,14 @@ const Sf = (e, t) => {
5944
5944
  * @see https://v3.tailwindcss.com/docs/placeholder-color
5945
5945
  */
5946
5946
  "placeholder-color": [{
5947
- placeholder: N()
5947
+ placeholder: R()
5948
5948
  }],
5949
5949
  /**
5950
5950
  * Text Color
5951
5951
  * @see https://tailwindcss.com/docs/text-color
5952
5952
  */
5953
5953
  "text-color": [{
5954
- text: N()
5954
+ text: R()
5955
5955
  }],
5956
5956
  /**
5957
5957
  * Text Decoration
@@ -5977,7 +5977,7 @@ const Sf = (e, t) => {
5977
5977
  * @see https://tailwindcss.com/docs/text-decoration-color
5978
5978
  */
5979
5979
  "text-decoration-color": [{
5980
- decoration: N()
5980
+ decoration: R()
5981
5981
  }],
5982
5982
  /**
5983
5983
  * Text Underline Offset
@@ -6088,7 +6088,7 @@ const Sf = (e, t) => {
6088
6088
  * @see https://tailwindcss.com/docs/background-repeat
6089
6089
  */
6090
6090
  "bg-repeat": [{
6091
- bg: T()
6091
+ bg: N()
6092
6092
  }],
6093
6093
  /**
6094
6094
  * Background Size
@@ -6115,7 +6115,7 @@ const Sf = (e, t) => {
6115
6115
  * @see https://tailwindcss.com/docs/background-color
6116
6116
  */
6117
6117
  "bg-color": [{
6118
- bg: N()
6118
+ bg: R()
6119
6119
  }],
6120
6120
  /**
6121
6121
  * Gradient Color Stops From Position
@@ -6143,21 +6143,21 @@ const Sf = (e, t) => {
6143
6143
  * @see https://tailwindcss.com/docs/gradient-color-stops
6144
6144
  */
6145
6145
  "gradient-from": [{
6146
- from: N()
6146
+ from: R()
6147
6147
  }],
6148
6148
  /**
6149
6149
  * Gradient Color Stops Via
6150
6150
  * @see https://tailwindcss.com/docs/gradient-color-stops
6151
6151
  */
6152
6152
  "gradient-via": [{
6153
- via: N()
6153
+ via: R()
6154
6154
  }],
6155
6155
  /**
6156
6156
  * Gradient Color Stops To
6157
6157
  * @see https://tailwindcss.com/docs/gradient-color-stops
6158
6158
  */
6159
6159
  "gradient-to": [{
6160
- to: N()
6160
+ to: R()
6161
6161
  }],
6162
6162
  // ---------------
6163
6163
  // --- Borders ---
@@ -6167,175 +6167,175 @@ const Sf = (e, t) => {
6167
6167
  * @see https://tailwindcss.com/docs/border-radius
6168
6168
  */
6169
6169
  rounded: [{
6170
- rounded: I()
6170
+ rounded: O()
6171
6171
  }],
6172
6172
  /**
6173
6173
  * Border Radius Start
6174
6174
  * @see https://tailwindcss.com/docs/border-radius
6175
6175
  */
6176
6176
  "rounded-s": [{
6177
- "rounded-s": I()
6177
+ "rounded-s": O()
6178
6178
  }],
6179
6179
  /**
6180
6180
  * Border Radius End
6181
6181
  * @see https://tailwindcss.com/docs/border-radius
6182
6182
  */
6183
6183
  "rounded-e": [{
6184
- "rounded-e": I()
6184
+ "rounded-e": O()
6185
6185
  }],
6186
6186
  /**
6187
6187
  * Border Radius Top
6188
6188
  * @see https://tailwindcss.com/docs/border-radius
6189
6189
  */
6190
6190
  "rounded-t": [{
6191
- "rounded-t": I()
6191
+ "rounded-t": O()
6192
6192
  }],
6193
6193
  /**
6194
6194
  * Border Radius Right
6195
6195
  * @see https://tailwindcss.com/docs/border-radius
6196
6196
  */
6197
6197
  "rounded-r": [{
6198
- "rounded-r": I()
6198
+ "rounded-r": O()
6199
6199
  }],
6200
6200
  /**
6201
6201
  * Border Radius Bottom
6202
6202
  * @see https://tailwindcss.com/docs/border-radius
6203
6203
  */
6204
6204
  "rounded-b": [{
6205
- "rounded-b": I()
6205
+ "rounded-b": O()
6206
6206
  }],
6207
6207
  /**
6208
6208
  * Border Radius Left
6209
6209
  * @see https://tailwindcss.com/docs/border-radius
6210
6210
  */
6211
6211
  "rounded-l": [{
6212
- "rounded-l": I()
6212
+ "rounded-l": O()
6213
6213
  }],
6214
6214
  /**
6215
6215
  * Border Radius Start Start
6216
6216
  * @see https://tailwindcss.com/docs/border-radius
6217
6217
  */
6218
6218
  "rounded-ss": [{
6219
- "rounded-ss": I()
6219
+ "rounded-ss": O()
6220
6220
  }],
6221
6221
  /**
6222
6222
  * Border Radius Start End
6223
6223
  * @see https://tailwindcss.com/docs/border-radius
6224
6224
  */
6225
6225
  "rounded-se": [{
6226
- "rounded-se": I()
6226
+ "rounded-se": O()
6227
6227
  }],
6228
6228
  /**
6229
6229
  * Border Radius End End
6230
6230
  * @see https://tailwindcss.com/docs/border-radius
6231
6231
  */
6232
6232
  "rounded-ee": [{
6233
- "rounded-ee": I()
6233
+ "rounded-ee": O()
6234
6234
  }],
6235
6235
  /**
6236
6236
  * Border Radius End Start
6237
6237
  * @see https://tailwindcss.com/docs/border-radius
6238
6238
  */
6239
6239
  "rounded-es": [{
6240
- "rounded-es": I()
6240
+ "rounded-es": O()
6241
6241
  }],
6242
6242
  /**
6243
6243
  * Border Radius Top Left
6244
6244
  * @see https://tailwindcss.com/docs/border-radius
6245
6245
  */
6246
6246
  "rounded-tl": [{
6247
- "rounded-tl": I()
6247
+ "rounded-tl": O()
6248
6248
  }],
6249
6249
  /**
6250
6250
  * Border Radius Top Right
6251
6251
  * @see https://tailwindcss.com/docs/border-radius
6252
6252
  */
6253
6253
  "rounded-tr": [{
6254
- "rounded-tr": I()
6254
+ "rounded-tr": O()
6255
6255
  }],
6256
6256
  /**
6257
6257
  * Border Radius Bottom Right
6258
6258
  * @see https://tailwindcss.com/docs/border-radius
6259
6259
  */
6260
6260
  "rounded-br": [{
6261
- "rounded-br": I()
6261
+ "rounded-br": O()
6262
6262
  }],
6263
6263
  /**
6264
6264
  * Border Radius Bottom Left
6265
6265
  * @see https://tailwindcss.com/docs/border-radius
6266
6266
  */
6267
6267
  "rounded-bl": [{
6268
- "rounded-bl": I()
6268
+ "rounded-bl": O()
6269
6269
  }],
6270
6270
  /**
6271
6271
  * Border Width
6272
6272
  * @see https://tailwindcss.com/docs/border-width
6273
6273
  */
6274
6274
  "border-w": [{
6275
- border: K()
6275
+ border: G()
6276
6276
  }],
6277
6277
  /**
6278
6278
  * Border Width X
6279
6279
  * @see https://tailwindcss.com/docs/border-width
6280
6280
  */
6281
6281
  "border-w-x": [{
6282
- "border-x": K()
6282
+ "border-x": G()
6283
6283
  }],
6284
6284
  /**
6285
6285
  * Border Width Y
6286
6286
  * @see https://tailwindcss.com/docs/border-width
6287
6287
  */
6288
6288
  "border-w-y": [{
6289
- "border-y": K()
6289
+ "border-y": G()
6290
6290
  }],
6291
6291
  /**
6292
6292
  * Border Width Start
6293
6293
  * @see https://tailwindcss.com/docs/border-width
6294
6294
  */
6295
6295
  "border-w-s": [{
6296
- "border-s": K()
6296
+ "border-s": G()
6297
6297
  }],
6298
6298
  /**
6299
6299
  * Border Width End
6300
6300
  * @see https://tailwindcss.com/docs/border-width
6301
6301
  */
6302
6302
  "border-w-e": [{
6303
- "border-e": K()
6303
+ "border-e": G()
6304
6304
  }],
6305
6305
  /**
6306
6306
  * Border Width Top
6307
6307
  * @see https://tailwindcss.com/docs/border-width
6308
6308
  */
6309
6309
  "border-w-t": [{
6310
- "border-t": K()
6310
+ "border-t": G()
6311
6311
  }],
6312
6312
  /**
6313
6313
  * Border Width Right
6314
6314
  * @see https://tailwindcss.com/docs/border-width
6315
6315
  */
6316
6316
  "border-w-r": [{
6317
- "border-r": K()
6317
+ "border-r": G()
6318
6318
  }],
6319
6319
  /**
6320
6320
  * Border Width Bottom
6321
6321
  * @see https://tailwindcss.com/docs/border-width
6322
6322
  */
6323
6323
  "border-w-b": [{
6324
- "border-b": K()
6324
+ "border-b": G()
6325
6325
  }],
6326
6326
  /**
6327
6327
  * Border Width Left
6328
6328
  * @see https://tailwindcss.com/docs/border-width
6329
6329
  */
6330
6330
  "border-w-l": [{
6331
- "border-l": K()
6331
+ "border-l": G()
6332
6332
  }],
6333
6333
  /**
6334
6334
  * Divide Width X
6335
6335
  * @see https://tailwindcss.com/docs/border-width#between-children
6336
6336
  */
6337
6337
  "divide-x": [{
6338
- "divide-x": K()
6338
+ "divide-x": G()
6339
6339
  }],
6340
6340
  /**
6341
6341
  * Divide Width X Reverse
@@ -6347,7 +6347,7 @@ const Sf = (e, t) => {
6347
6347
  * @see https://tailwindcss.com/docs/border-width#between-children
6348
6348
  */
6349
6349
  "divide-y": [{
6350
- "divide-y": K()
6350
+ "divide-y": G()
6351
6351
  }],
6352
6352
  /**
6353
6353
  * Divide Width Y Reverse
@@ -6373,70 +6373,70 @@ const Sf = (e, t) => {
6373
6373
  * @see https://tailwindcss.com/docs/border-color
6374
6374
  */
6375
6375
  "border-color": [{
6376
- border: N()
6376
+ border: R()
6377
6377
  }],
6378
6378
  /**
6379
6379
  * Border Color X
6380
6380
  * @see https://tailwindcss.com/docs/border-color
6381
6381
  */
6382
6382
  "border-color-x": [{
6383
- "border-x": N()
6383
+ "border-x": R()
6384
6384
  }],
6385
6385
  /**
6386
6386
  * Border Color Y
6387
6387
  * @see https://tailwindcss.com/docs/border-color
6388
6388
  */
6389
6389
  "border-color-y": [{
6390
- "border-y": N()
6390
+ "border-y": R()
6391
6391
  }],
6392
6392
  /**
6393
6393
  * Border Color S
6394
6394
  * @see https://tailwindcss.com/docs/border-color
6395
6395
  */
6396
6396
  "border-color-s": [{
6397
- "border-s": N()
6397
+ "border-s": R()
6398
6398
  }],
6399
6399
  /**
6400
6400
  * Border Color E
6401
6401
  * @see https://tailwindcss.com/docs/border-color
6402
6402
  */
6403
6403
  "border-color-e": [{
6404
- "border-e": N()
6404
+ "border-e": R()
6405
6405
  }],
6406
6406
  /**
6407
6407
  * Border Color Top
6408
6408
  * @see https://tailwindcss.com/docs/border-color
6409
6409
  */
6410
6410
  "border-color-t": [{
6411
- "border-t": N()
6411
+ "border-t": R()
6412
6412
  }],
6413
6413
  /**
6414
6414
  * Border Color Right
6415
6415
  * @see https://tailwindcss.com/docs/border-color
6416
6416
  */
6417
6417
  "border-color-r": [{
6418
- "border-r": N()
6418
+ "border-r": R()
6419
6419
  }],
6420
6420
  /**
6421
6421
  * Border Color Bottom
6422
6422
  * @see https://tailwindcss.com/docs/border-color
6423
6423
  */
6424
6424
  "border-color-b": [{
6425
- "border-b": N()
6425
+ "border-b": R()
6426
6426
  }],
6427
6427
  /**
6428
6428
  * Border Color Left
6429
6429
  * @see https://tailwindcss.com/docs/border-color
6430
6430
  */
6431
6431
  "border-color-l": [{
6432
- "border-l": N()
6432
+ "border-l": R()
6433
6433
  }],
6434
6434
  /**
6435
6435
  * Divide Color
6436
6436
  * @see https://tailwindcss.com/docs/divide-color
6437
6437
  */
6438
6438
  "divide-color": [{
6439
- divide: N()
6439
+ divide: R()
6440
6440
  }],
6441
6441
  /**
6442
6442
  * Outline Style
@@ -6464,7 +6464,7 @@ const Sf = (e, t) => {
6464
6464
  * @see https://tailwindcss.com/docs/outline-color
6465
6465
  */
6466
6466
  "outline-color": [{
6467
- outline: N()
6467
+ outline: R()
6468
6468
  }],
6469
6469
  // ---------------
6470
6470
  // --- Effects ---
@@ -6488,7 +6488,7 @@ const Sf = (e, t) => {
6488
6488
  * @see https://tailwindcss.com/docs/box-shadow#setting-the-shadow-color
6489
6489
  */
6490
6490
  "shadow-color": [{
6491
- shadow: N()
6491
+ shadow: R()
6492
6492
  }],
6493
6493
  /**
6494
6494
  * Inset Box Shadow
@@ -6502,14 +6502,14 @@ const Sf = (e, t) => {
6502
6502
  * @see https://tailwindcss.com/docs/box-shadow#setting-the-inset-shadow-color
6503
6503
  */
6504
6504
  "inset-shadow-color": [{
6505
- "inset-shadow": N()
6505
+ "inset-shadow": R()
6506
6506
  }],
6507
6507
  /**
6508
6508
  * Ring Width
6509
6509
  * @see https://tailwindcss.com/docs/box-shadow#adding-a-ring
6510
6510
  */
6511
6511
  "ring-w": [{
6512
- ring: K()
6512
+ ring: G()
6513
6513
  }],
6514
6514
  /**
6515
6515
  * Ring Width Inset
@@ -6523,7 +6523,7 @@ const Sf = (e, t) => {
6523
6523
  * @see https://tailwindcss.com/docs/box-shadow#setting-the-ring-color
6524
6524
  */
6525
6525
  "ring-color": [{
6526
- ring: N()
6526
+ ring: R()
6527
6527
  }],
6528
6528
  /**
6529
6529
  * Ring Offset Width
@@ -6541,21 +6541,21 @@ const Sf = (e, t) => {
6541
6541
  * @see https://github.com/tailwindlabs/tailwindcss/blob/v4.0.0/packages/tailwindcss/src/utilities.ts#L4158
6542
6542
  */
6543
6543
  "ring-offset-color": [{
6544
- "ring-offset": N()
6544
+ "ring-offset": R()
6545
6545
  }],
6546
6546
  /**
6547
6547
  * Inset Ring Width
6548
6548
  * @see https://tailwindcss.com/docs/box-shadow#adding-an-inset-ring
6549
6549
  */
6550
6550
  "inset-ring-w": [{
6551
- "inset-ring": K()
6551
+ "inset-ring": G()
6552
6552
  }],
6553
6553
  /**
6554
6554
  * Inset Ring Color
6555
6555
  * @see https://tailwindcss.com/docs/box-shadow#setting-the-inset-ring-color
6556
6556
  */
6557
6557
  "inset-ring-color": [{
6558
- "inset-ring": N()
6558
+ "inset-ring": R()
6559
6559
  }],
6560
6560
  /**
6561
6561
  * Text Shadow
@@ -6569,7 +6569,7 @@ const Sf = (e, t) => {
6569
6569
  * @see https://tailwindcss.com/docs/text-shadow#setting-the-shadow-color
6570
6570
  */
6571
6571
  "text-shadow-color": [{
6572
- "text-shadow": N()
6572
+ "text-shadow": R()
6573
6573
  }],
6574
6574
  /**
6575
6575
  * Opacity
@@ -6620,10 +6620,10 @@ const Sf = (e, t) => {
6620
6620
  "mask-linear-to": D()
6621
6621
  }],
6622
6622
  "mask-image-linear-from-color": [{
6623
- "mask-linear-from": N()
6623
+ "mask-linear-from": R()
6624
6624
  }],
6625
6625
  "mask-image-linear-to-color": [{
6626
- "mask-linear-to": N()
6626
+ "mask-linear-to": R()
6627
6627
  }],
6628
6628
  "mask-image-t-from-pos": [{
6629
6629
  "mask-t-from": D()
@@ -6632,10 +6632,10 @@ const Sf = (e, t) => {
6632
6632
  "mask-t-to": D()
6633
6633
  }],
6634
6634
  "mask-image-t-from-color": [{
6635
- "mask-t-from": N()
6635
+ "mask-t-from": R()
6636
6636
  }],
6637
6637
  "mask-image-t-to-color": [{
6638
- "mask-t-to": N()
6638
+ "mask-t-to": R()
6639
6639
  }],
6640
6640
  "mask-image-r-from-pos": [{
6641
6641
  "mask-r-from": D()
@@ -6644,10 +6644,10 @@ const Sf = (e, t) => {
6644
6644
  "mask-r-to": D()
6645
6645
  }],
6646
6646
  "mask-image-r-from-color": [{
6647
- "mask-r-from": N()
6647
+ "mask-r-from": R()
6648
6648
  }],
6649
6649
  "mask-image-r-to-color": [{
6650
- "mask-r-to": N()
6650
+ "mask-r-to": R()
6651
6651
  }],
6652
6652
  "mask-image-b-from-pos": [{
6653
6653
  "mask-b-from": D()
@@ -6656,10 +6656,10 @@ const Sf = (e, t) => {
6656
6656
  "mask-b-to": D()
6657
6657
  }],
6658
6658
  "mask-image-b-from-color": [{
6659
- "mask-b-from": N()
6659
+ "mask-b-from": R()
6660
6660
  }],
6661
6661
  "mask-image-b-to-color": [{
6662
- "mask-b-to": N()
6662
+ "mask-b-to": R()
6663
6663
  }],
6664
6664
  "mask-image-l-from-pos": [{
6665
6665
  "mask-l-from": D()
@@ -6668,10 +6668,10 @@ const Sf = (e, t) => {
6668
6668
  "mask-l-to": D()
6669
6669
  }],
6670
6670
  "mask-image-l-from-color": [{
6671
- "mask-l-from": N()
6671
+ "mask-l-from": R()
6672
6672
  }],
6673
6673
  "mask-image-l-to-color": [{
6674
- "mask-l-to": N()
6674
+ "mask-l-to": R()
6675
6675
  }],
6676
6676
  "mask-image-x-from-pos": [{
6677
6677
  "mask-x-from": D()
@@ -6680,10 +6680,10 @@ const Sf = (e, t) => {
6680
6680
  "mask-x-to": D()
6681
6681
  }],
6682
6682
  "mask-image-x-from-color": [{
6683
- "mask-x-from": N()
6683
+ "mask-x-from": R()
6684
6684
  }],
6685
6685
  "mask-image-x-to-color": [{
6686
- "mask-x-to": N()
6686
+ "mask-x-to": R()
6687
6687
  }],
6688
6688
  "mask-image-y-from-pos": [{
6689
6689
  "mask-y-from": D()
@@ -6692,10 +6692,10 @@ const Sf = (e, t) => {
6692
6692
  "mask-y-to": D()
6693
6693
  }],
6694
6694
  "mask-image-y-from-color": [{
6695
- "mask-y-from": N()
6695
+ "mask-y-from": R()
6696
6696
  }],
6697
6697
  "mask-image-y-to-color": [{
6698
- "mask-y-to": N()
6698
+ "mask-y-to": R()
6699
6699
  }],
6700
6700
  "mask-image-radial": [{
6701
6701
  "mask-radial": [B, z]
@@ -6707,10 +6707,10 @@ const Sf = (e, t) => {
6707
6707
  "mask-radial-to": D()
6708
6708
  }],
6709
6709
  "mask-image-radial-from-color": [{
6710
- "mask-radial-from": N()
6710
+ "mask-radial-from": R()
6711
6711
  }],
6712
6712
  "mask-image-radial-to-color": [{
6713
- "mask-radial-to": N()
6713
+ "mask-radial-to": R()
6714
6714
  }],
6715
6715
  "mask-image-radial-shape": [{
6716
6716
  "mask-radial": ["circle", "ellipse"]
@@ -6734,10 +6734,10 @@ const Sf = (e, t) => {
6734
6734
  "mask-conic-to": D()
6735
6735
  }],
6736
6736
  "mask-image-conic-from-color": [{
6737
- "mask-conic-from": N()
6737
+ "mask-conic-from": R()
6738
6738
  }],
6739
6739
  "mask-image-conic-to-color": [{
6740
- "mask-conic-to": N()
6740
+ "mask-conic-to": R()
6741
6741
  }],
6742
6742
  /**
6743
6743
  * Mask Mode
@@ -6765,7 +6765,7 @@ const Sf = (e, t) => {
6765
6765
  * @see https://tailwindcss.com/docs/mask-repeat
6766
6766
  */
6767
6767
  "mask-repeat": [{
6768
- mask: T()
6768
+ mask: N()
6769
6769
  }],
6770
6770
  /**
6771
6771
  * Mask Size
@@ -6844,7 +6844,7 @@ const Sf = (e, t) => {
6844
6844
  * @see https://tailwindcss.com/docs/filter-drop-shadow#setting-the-shadow-color
6845
6845
  */
6846
6846
  "drop-shadow-color": [{
6847
- "drop-shadow": N()
6847
+ "drop-shadow": R()
6848
6848
  }],
6849
6849
  /**
6850
6850
  * Grayscale
@@ -7215,7 +7215,7 @@ const Sf = (e, t) => {
7215
7215
  * @see https://tailwindcss.com/docs/accent-color
7216
7216
  */
7217
7217
  accent: [{
7218
- accent: N()
7218
+ accent: R()
7219
7219
  }],
7220
7220
  /**
7221
7221
  * Appearance
@@ -7229,7 +7229,7 @@ const Sf = (e, t) => {
7229
7229
  * @see https://tailwindcss.com/docs/just-in-time-mode#caret-color-utilities
7230
7230
  */
7231
7231
  "caret-color": [{
7232
- caret: N()
7232
+ caret: R()
7233
7233
  }],
7234
7234
  /**
7235
7235
  * Color Scheme
@@ -7475,7 +7475,7 @@ const Sf = (e, t) => {
7475
7475
  * @see https://tailwindcss.com/docs/fill
7476
7476
  */
7477
7477
  fill: [{
7478
- fill: ["none", ...N()]
7478
+ fill: ["none", ...R()]
7479
7479
  }],
7480
7480
  /**
7481
7481
  * Stroke Width
@@ -7489,7 +7489,7 @@ const Sf = (e, t) => {
7489
7489
  * @see https://tailwindcss.com/docs/stroke
7490
7490
  */
7491
7491
  stroke: [{
7492
- stroke: ["none", ...N()]
7492
+ stroke: ["none", ...R()]
7493
7493
  }],
7494
7494
  // ---------------------
7495
7495
  // --- Accessibility ---
@@ -7599,8 +7599,8 @@ function up({
7599
7599
  error: r
7600
7600
  }) {
7601
7601
  const [s, i] = be(!1), a = t[e.name] ?? { from: null, to: null }, l = (f) => n(e.name, f), c = () => n(e.name, { from: null, to: null });
7602
- return /* @__PURE__ */ u("div", { children: /* @__PURE__ */ O(In, { open: s, onOpenChange: i, children: [
7603
- /* @__PURE__ */ u(Mn, { asChild: !0, children: /* @__PURE__ */ O(
7602
+ return /* @__PURE__ */ u("div", { children: /* @__PURE__ */ I(In, { open: s, onOpenChange: i, children: [
7603
+ /* @__PURE__ */ u(Mn, { asChild: !0, children: /* @__PURE__ */ I(
7604
7604
  "button",
7605
7605
  {
7606
7606
  type: "button",
@@ -7619,7 +7619,7 @@ function up({
7619
7619
  ${r ? "border-red-500 focus-visible:ring-red-500" : "border-gray-300 focus-visible:ring-blue-500"}
7620
7620
  `,
7621
7621
  children: [
7622
- a.from ? a.to ? /* @__PURE__ */ O("span", { children: [
7622
+ a.from ? a.to ? /* @__PURE__ */ I("span", { children: [
7623
7623
  a.from.toLocaleDateString(),
7624
7624
  " –",
7625
7625
  " ",
@@ -7644,7 +7644,7 @@ function up({
7644
7644
  ]
7645
7645
  }
7646
7646
  ) }),
7647
- /* @__PURE__ */ O(
7647
+ /* @__PURE__ */ I(
7648
7648
  Dn,
7649
7649
  {
7650
7650
  align: "start",
@@ -7661,7 +7661,7 @@ function up({
7661
7661
  className: "rounded-md bg-white p-3 text-xs"
7662
7662
  }
7663
7663
  ),
7664
- /* @__PURE__ */ O("div", { className: "flex items-center justify-between gap-2 border-t border-gray-200 p-3", children: [
7664
+ /* @__PURE__ */ I("div", { className: "flex items-center justify-between gap-2 border-t border-gray-200 p-3", children: [
7665
7665
  /* @__PURE__ */ u(
7666
7666
  "button",
7667
7667
  {
@@ -7703,62 +7703,62 @@ function es({
7703
7703
  !v && e.uploadEndpoint && console.error(
7704
7704
  `api_URL prop is required when using FileField with upload functionality for field "${e.name}"`
7705
7705
  );
7706
- const x = (R) => {
7707
- if (R === 0) return "0 Bytes";
7708
- const $ = 1024, W = ["Bytes", "KB", "MB", "GB"], L = Math.floor(Math.log(R) / Math.log($));
7709
- return `${parseFloat((R / $ ** L).toFixed(2))} ${W[L]}`;
7710
- }, S = async (R) => {
7706
+ const x = (T) => {
7707
+ if (T === 0) return "0 Bytes";
7708
+ const $ = 1024, U = ["Bytes", "KB", "MB", "GB"], L = Math.floor(Math.log(T) / Math.log($));
7709
+ return `${parseFloat((T / $ ** L).toFixed(2))} ${U[L]}`;
7710
+ }, S = async (T) => {
7711
7711
  const $ = new FormData();
7712
- $.append("file", R);
7713
- const W = await fetch(`${v}`, {
7712
+ $.append("file", T);
7713
+ const U = await fetch(`${v}`, {
7714
7714
  method: "POST",
7715
7715
  body: $
7716
7716
  });
7717
- if (!W.ok)
7717
+ if (!U.ok)
7718
7718
  throw fn.error("Upload failed"), new Error("Upload failed");
7719
- return await W.json();
7720
- }, C = async (R, $) => {
7719
+ return await U.json();
7720
+ }, C = async (T, $) => {
7721
7721
  if (!$) return;
7722
- if (R.maxSize && $.size > R.maxSize)
7722
+ if (T.maxSize && $.size > T.maxSize)
7723
7723
  throw new Error(
7724
- `File size must not exceed ${x(R.maxSize)}`
7724
+ `File size must not exceed ${x(T.maxSize)}`
7725
7725
  );
7726
- const W = await S($), L = { ...t, [R.name]: W };
7727
- s(R.name, W), i(L);
7728
- }, y = async (R, $) => {
7729
- const W = t[R.name] || [];
7730
- if (R.maxFiles && W.length + $.length > R.maxFiles)
7731
- throw new Error(`Maximum ${R.maxFiles} files allowed`);
7732
- $.forEach((N) => {
7733
- if (R.maxSize && N.size > R.maxSize)
7726
+ const U = await S($), L = { ...t, [T.name]: U };
7727
+ s(T.name, U), i(L);
7728
+ }, y = async (T, $) => {
7729
+ const U = t[T.name] || [];
7730
+ if (T.maxFiles && U.length + $.length > T.maxFiles)
7731
+ throw new Error(`Maximum ${T.maxFiles} files allowed`);
7732
+ $.forEach((R) => {
7733
+ if (T.maxSize && R.size > T.maxSize)
7734
7734
  throw new Error(
7735
- `Each file must not exceed ${x(R.maxSize)}`
7735
+ `Each file must not exceed ${x(T.maxSize)}`
7736
7736
  );
7737
7737
  });
7738
7738
  const L = await Promise.all(
7739
- $.map((N) => S(N))
7739
+ $.map((R) => S(R))
7740
7740
  // Updated call
7741
- ), Y = [...W, ...L];
7742
- s(R.name, Y), i({ ...t, [R.name]: Y });
7743
- }, E = async (R, $) => {
7741
+ ), K = [...U, ...L];
7742
+ s(T.name, K), i({ ...t, [T.name]: K });
7743
+ }, E = async (T, $) => {
7744
7744
  if (c) return;
7745
- const W = Array.from($);
7745
+ const U = Array.from($);
7746
7746
  try {
7747
- e.type === "multifile" ? await y(e, W) : await C(e, W[0]), r.current?.[R] && (r.current[R].value = "");
7747
+ e.type === "multifile" ? await y(e, U) : await C(e, U[0]), r.current?.[T] && (r.current[T].value = "");
7748
7748
  } catch (L) {
7749
7749
  fn.error(`Upload failed: ${L.message}`);
7750
7750
  }
7751
- }, F = async (R, $) => {
7751
+ }, F = async (T, $) => {
7752
7752
  if (c) return;
7753
- let W;
7754
- e.type === "file" ? W = "" : W = (t[R] || []).filter((Y) => Y !== $), s(R, W), i({ ...t, [R]: W }), r.current?.[R] && (r.current[R].value = "");
7755
- }, k = (R) => {
7756
- R.preventDefault(), c || h(!0);
7757
- }, A = (R) => {
7758
- R.preventDefault(), c || h(!1);
7759
- }, G = (R) => {
7760
- R.preventDefault(), h(!1), !c && R.dataTransfer.files && R.dataTransfer.files.length > 0 && E(e.name, R.dataTransfer.files);
7761
- }, X = e.accept ? e.accept.split(",").map((R) => R.split("/")[1] || R.split(".")[1] || R).join(", ").toUpperCase() : "PNG, JPG, PDF", j = e.maxSize ? `, up to ${x(e.maxSize)}` : "", q = `
7753
+ let U;
7754
+ e.type === "file" ? U = "" : U = (t[T] || []).filter((K) => K !== $), s(T, U), i({ ...t, [T]: U }), r.current?.[T] && (r.current[T].value = "");
7755
+ }, k = (T) => {
7756
+ T.preventDefault(), c || h(!0);
7757
+ }, A = (T) => {
7758
+ T.preventDefault(), c || h(!1);
7759
+ }, Y = (T) => {
7760
+ T.preventDefault(), h(!1), !c && T.dataTransfer.files && T.dataTransfer.files.length > 0 && E(e.name, T.dataTransfer.files);
7761
+ }, X = e.accept ? e.accept.split(",").map((T) => T.split("/")[1] || T.split(".")[1] || T).join(", ").toUpperCase() : "PNG, JPG, PDF", j = e.maxSize ? `, up to ${x(e.maxSize)}` : "", q = `
7762
7762
  w-full flex flex-col items-center justify-center p-6 border-2 border-dashed rounded-lg transition-all duration-200
7763
7763
  // Ensure focus styling is handled correctly for the button element
7764
7764
  focus:outline-none focus:ring-2 focus:ring-blue-500 focus:ring-opacity-50
@@ -7768,8 +7768,8 @@ function es({
7768
7768
  "div",
7769
7769
  {
7770
7770
  className: `mb-4 ${e.fieldClass || "col-span-full"}`,
7771
- children: /* @__PURE__ */ O("div", { className: "space-y-3", children: [
7772
- /* @__PURE__ */ O(
7771
+ children: /* @__PURE__ */ I("div", { className: "space-y-3", children: [
7772
+ /* @__PURE__ */ I(
7773
7773
  "button",
7774
7774
  {
7775
7775
  type: "button",
@@ -7780,12 +7780,12 @@ function es({
7780
7780
  onDragOver: k,
7781
7781
  onDragEnter: k,
7782
7782
  onDragLeave: A,
7783
- onDrop: G,
7783
+ onDrop: Y,
7784
7784
  disabled: c,
7785
7785
  children: [
7786
7786
  /* @__PURE__ */ u("div", { className: "border-gray-400 border p-1 mb-3 rounded-md bg-gray-100 shadow-md ", children: /* @__PURE__ */ u(wd, { size: 24, className: "m-1" }) }),
7787
- /* @__PURE__ */ O("p", { className: "text-sm font-normal", children: [
7788
- /* @__PURE__ */ O(
7787
+ /* @__PURE__ */ I("p", { className: "text-sm font-normal", children: [
7788
+ /* @__PURE__ */ I(
7789
7789
  "span",
7790
7790
  {
7791
7791
  className: c ? "text-gray-400" : "text-blue-600 hover:text-blue-700 underline",
@@ -7797,7 +7797,7 @@ function es({
7797
7797
  ),
7798
7798
  /* @__PURE__ */ u("span", { className: "font-light", children: " or drag and drop" })
7799
7799
  ] }),
7800
- /* @__PURE__ */ O("p", { className: "text-xs mt-1 text-gray-500", children: [
7800
+ /* @__PURE__ */ I("p", { className: "text-xs mt-1 text-gray-500", children: [
7801
7801
  X,
7802
7802
  j,
7803
7803
  f && e.maxFiles && `, Max ${e.maxFiles} files`
@@ -7808,28 +7808,28 @@ function es({
7808
7808
  /* @__PURE__ */ u(
7809
7809
  "input",
7810
7810
  {
7811
- ref: (R) => {
7812
- R && r && r.current && (r.current[e.name] = R);
7811
+ ref: (T) => {
7812
+ T && r && r.current && (r.current[e.name] = T);
7813
7813
  },
7814
7814
  id: e.name,
7815
7815
  type: "file",
7816
7816
  accept: e.accept,
7817
7817
  multiple: f,
7818
7818
  className: "sr-only",
7819
- onChange: (R) => E(e.name, R.target.files),
7819
+ onChange: (T) => E(e.name, T.target.files),
7820
7820
  disabled: c
7821
7821
  }
7822
7822
  ),
7823
- m.length > 0 && /* @__PURE__ */ u("div", { className: "space-y-2 pt-2 border-t border-gray-200", children: m.map((R, $) => {
7824
- const W = R.original_name || R.name || "File", L = R.size || null;
7825
- return /* @__PURE__ */ O(
7823
+ m.length > 0 && /* @__PURE__ */ u("div", { className: "space-y-2 pt-2 border-t border-gray-200", children: m.map((T, $) => {
7824
+ const U = T.original_name || T.name || "File", L = T.size || null;
7825
+ return /* @__PURE__ */ I(
7826
7826
  "div",
7827
7827
  {
7828
7828
  className: "flex items-center justify-between p-2 bg-gray-50 rounded",
7829
7829
  children: [
7830
- /* @__PURE__ */ O("div", { className: "flex items-center space-x-2 min-w-0", children: [
7831
- /* @__PURE__ */ u("span", { className: "text-sm truncate", children: W }),
7832
- L && /* @__PURE__ */ O("span", { className: "text-xs text-gray-500 flex-shrink-0", children: [
7830
+ /* @__PURE__ */ I("div", { className: "flex items-center space-x-2 min-w-0", children: [
7831
+ /* @__PURE__ */ u("span", { className: "text-sm truncate", children: U }),
7832
+ L && /* @__PURE__ */ I("span", { className: "text-xs text-gray-500 flex-shrink-0", children: [
7833
7833
  "(",
7834
7834
  x(L),
7835
7835
  ")"
@@ -7839,7 +7839,7 @@ function es({
7839
7839
  "button",
7840
7840
  {
7841
7841
  type: "button",
7842
- onClick: () => F(e.name, R),
7842
+ onClick: () => F(e.name, T),
7843
7843
  className: `text-red-500 hover:text-red-700 ml-3 flex-shrink-0 ${c ? "cursor-not-allowed opacity-50" : ""}`,
7844
7844
  disabled: c,
7845
7845
  children: "Remove"
@@ -7847,16 +7847,16 @@ function es({
7847
7847
  )
7848
7848
  ]
7849
7849
  },
7850
- R.url || R.original_name || $
7850
+ T.url || T.original_name || $
7851
7851
  );
7852
7852
  }) }),
7853
- Object.entries(p).map(([R, $]) => $.status === "uploading" ? /* @__PURE__ */ O("div", { className: "relative pt-1", children: [
7854
- /* @__PURE__ */ O("div", { className: "flex items-center justify-between", children: [
7855
- /* @__PURE__ */ O("span", { className: "text-xs font-semibold inline-block text-blue-600", children: [
7853
+ Object.entries(p).map(([T, $]) => $.status === "uploading" ? /* @__PURE__ */ I("div", { className: "relative pt-1", children: [
7854
+ /* @__PURE__ */ I("div", { className: "flex items-center justify-between", children: [
7855
+ /* @__PURE__ */ I("span", { className: "text-xs font-semibold inline-block text-blue-600", children: [
7856
7856
  "Uploading ",
7857
- R
7857
+ T
7858
7858
  ] }),
7859
- /* @__PURE__ */ O("span", { className: "text-xs font-semibold inline-block text-blue-600", children: [
7859
+ /* @__PURE__ */ I("span", { className: "text-xs font-semibold inline-block text-blue-600", children: [
7860
7860
  $.progress,
7861
7861
  "%"
7862
7862
  ] })
@@ -7868,7 +7868,7 @@ function es({
7868
7868
  style: { width: `${$.progress}%` }
7869
7869
  }
7870
7870
  ) })
7871
- ] }, R) : null)
7871
+ ] }, T) : null)
7872
7872
  ] })
7873
7873
  },
7874
7874
  e.name
@@ -7896,7 +7896,7 @@ function dp({
7896
7896
  [e.name]: g.target.value.length
7897
7897
  }));
7898
7898
  };
7899
- return /* @__PURE__ */ O("div", { className: "space-y-2", children: [
7899
+ return /* @__PURE__ */ I("div", { className: "space-y-2", children: [
7900
7900
  /* @__PURE__ */ u(
7901
7901
  "textarea",
7902
7902
  {
@@ -7918,7 +7918,7 @@ function dp({
7918
7918
  }
7919
7919
  }
7920
7920
  ),
7921
- /* @__PURE__ */ u("div", { className: "flex justify-between items-center", children: e.maxLength && !e.readOnly && /* @__PURE__ */ O("span", { className: "text-xs text-gray-500", children: [
7921
+ /* @__PURE__ */ u("div", { className: "flex justify-between items-center", children: e.maxLength && !e.readOnly && /* @__PURE__ */ I("span", { className: "text-xs text-gray-500", children: [
7922
7922
  s || 0,
7923
7923
  "/",
7924
7924
  e.maxLength,
@@ -7954,9 +7954,9 @@ function fp({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
7954
7954
  }, S = () => {
7955
7955
  m(c, f, p === "AM" ? "PM" : "AM");
7956
7956
  }, C = () => n(e.name, null);
7957
- return /* @__PURE__ */ O("div", { className: "relative", children: [
7958
- /* @__PURE__ */ O(In, { open: s, onOpenChange: i, children: [
7959
- /* @__PURE__ */ u(Mn, { asChild: !0, children: /* @__PURE__ */ O(
7957
+ return /* @__PURE__ */ I("div", { className: "relative", children: [
7958
+ /* @__PURE__ */ I(In, { open: s, onOpenChange: i, children: [
7959
+ /* @__PURE__ */ u(Mn, { asChild: !0, children: /* @__PURE__ */ I(
7960
7960
  "button",
7961
7961
  {
7962
7962
  type: "button",
@@ -7975,8 +7975,8 @@ function fp({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
7975
7975
  ${r ? "border-red-500 focus-visible:ring-red-500" : "border-slate-200 focus-visible:ring-blue-500"}
7976
7976
  `,
7977
7977
  children: [
7978
- l ? /* @__PURE__ */ u("span", { className: "text-slate-900 font-medium", children: l.toLocaleString() }) : /* @__PURE__ */ u("span", { className: "text-slate-400", children: e.placeholder || "Select date and time" }),
7979
- /* @__PURE__ */ O(
7978
+ l ? /* @__PURE__ */ u("span", { className: "text-slate-900 ", children: l.toLocaleString() }) : /* @__PURE__ */ u("span", { className: "text-slate-400", children: e.placeholder || "Select date and time" }),
7979
+ /* @__PURE__ */ I(
7980
7980
  "svg",
7981
7981
  {
7982
7982
  xmlns: "http://www.w3.org/2000/svg",
@@ -8000,7 +8000,7 @@ function fp({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
8000
8000
  ]
8001
8001
  }
8002
8002
  ) }),
8003
- /* @__PURE__ */ O(
8003
+ /* @__PURE__ */ I(
8004
8004
  Dn,
8005
8005
  {
8006
8006
  align: "start",
@@ -8023,21 +8023,21 @@ function fp({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
8023
8023
  }
8024
8024
  }
8025
8025
  ) }),
8026
- /* @__PURE__ */ u("div", { className: "border-t border-slate-100 p-4 bg-slate-50/50", children: /* @__PURE__ */ O("div", { className: "flex items-center justify-center gap-4", children: [
8027
- /* @__PURE__ */ O("div", { className: "flex items-center gap-2", children: [
8028
- /* @__PURE__ */ O("div", { className: "flex flex-col items-center gap-1", children: [
8026
+ /* @__PURE__ */ u("div", { className: "border-t border-slate-100 p-4 bg-slate-50/50", children: /* @__PURE__ */ I("div", { className: "flex items-center justify-center gap-4", children: [
8027
+ /* @__PURE__ */ I("div", { className: "flex items-center gap-2", children: [
8028
+ /* @__PURE__ */ I("div", { className: "flex flex-col items-center gap-1", children: [
8029
8029
  /* @__PURE__ */ u("button", { type: "button", onClick: w, className: "p-1 h-6 w-6 flex items-center justify-center text-slate-400 hover:text-slate-700 hover:bg-slate-200 rounded-full transition-all", children: /* @__PURE__ */ u("svg", { xmlns: "http://www.w3.org/2000/svg", width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: /* @__PURE__ */ u("path", { d: "m18 15-6-6-6 6" }) }) }),
8030
8030
  /* @__PURE__ */ u("div", { className: "w-12 h-10 flex items-center justify-center bg-white border border-slate-200 rounded-lg text-lg font-semibold shadow-sm text-slate-700", children: c }),
8031
8031
  /* @__PURE__ */ u("button", { type: "button", onClick: h, className: "p-1 h-6 w-6 flex items-center justify-center text-slate-400 hover:text-slate-700 hover:bg-slate-200 rounded-full transition-all", children: /* @__PURE__ */ u("svg", { xmlns: "http://www.w3.org/2000/svg", width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: /* @__PURE__ */ u("path", { d: "m6 9 6 6 6-6" }) }) })
8032
8032
  ] }),
8033
8033
  /* @__PURE__ */ u("span", { className: "text-xl font-medium text-slate-300 pb-1", children: ":" }),
8034
- /* @__PURE__ */ O("div", { className: "flex flex-col items-center gap-1", children: [
8034
+ /* @__PURE__ */ I("div", { className: "flex flex-col items-center gap-1", children: [
8035
8035
  /* @__PURE__ */ u("button", { type: "button", onClick: v, className: "p-1 h-6 w-6 flex items-center justify-center text-slate-400 hover:text-slate-700 hover:bg-slate-200 rounded-full transition-all", children: /* @__PURE__ */ u("svg", { xmlns: "http://www.w3.org/2000/svg", width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: /* @__PURE__ */ u("path", { d: "m18 15-6-6-6 6" }) }) }),
8036
8036
  /* @__PURE__ */ u("div", { className: "w-12 h-10 flex items-center justify-center bg-white border border-slate-200 rounded-lg text-lg font-semibold shadow-sm text-slate-700", children: f }),
8037
8037
  /* @__PURE__ */ u("button", { type: "button", onClick: x, className: "p-1 h-6 w-6 flex items-center justify-center text-slate-400 hover:text-slate-700 hover:bg-slate-200 rounded-full transition-all", children: /* @__PURE__ */ u("svg", { xmlns: "http://www.w3.org/2000/svg", width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: /* @__PURE__ */ u("path", { d: "m6 9 6 6 6-6" }) }) })
8038
8038
  ] })
8039
8039
  ] }),
8040
- /* @__PURE__ */ O("div", { className: "flex flex-col gap-1 bg-white p-1 rounded-lg border border-slate-200 shadow-sm", children: [
8040
+ /* @__PURE__ */ I("div", { className: "flex flex-col gap-1 bg-white p-1 rounded-lg border border-slate-200 shadow-sm", children: [
8041
8041
  /* @__PURE__ */ u(
8042
8042
  "button",
8043
8043
  {
@@ -8058,7 +8058,7 @@ function fp({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
8058
8058
  )
8059
8059
  ] })
8060
8060
  ] }) }),
8061
- /* @__PURE__ */ O("div", { className: "flex items-center justify-between gap-2 border-t border-slate-100 p-3 bg-white rounded-b-xl", children: [
8061
+ /* @__PURE__ */ I("div", { className: "flex items-center justify-between gap-2 border-t border-slate-100 p-3 bg-white rounded-b-xl", children: [
8062
8062
  /* @__PURE__ */ u(
8063
8063
  "button",
8064
8064
  {
@@ -8199,7 +8199,7 @@ function lo({
8199
8199
  );
8200
8200
  }
8201
8201
  function Rp({ field: e }) {
8202
- return e?.label ? /* @__PURE__ */ O("div", { className: "relative flex items-center py-4", children: [
8202
+ return e?.label ? /* @__PURE__ */ I("div", { className: "relative flex items-center py-4", children: [
8203
8203
  /* @__PURE__ */ u(lo, { className: "flex-1 h-px bg-gray-300" }),
8204
8204
  /* @__PURE__ */ u("span", { className: "px-3 font-medium text-gray-600 bg-white", children: e.label }),
8205
8205
  /* @__PURE__ */ u(lo, { className: "flex-1 h-px bg-gray-300" })
@@ -8315,14 +8315,14 @@ var Dp = d.forwardRef((e, t) => {
8315
8315
  E.current = !0;
8316
8316
  }),
8317
8317
  onFocus: te(e.onFocus, (A) => {
8318
- const G = !E.current;
8319
- if (A.target === A.currentTarget && G && !x) {
8318
+ const Y = !E.current;
8319
+ if (A.target === A.currentTarget && Y && !x) {
8320
8320
  const X = new CustomEvent(co, Pp);
8321
8321
  if (A.currentTarget.dispatchEvent(X), !X.defaultPrevented) {
8322
- const j = y().filter((L) => L.focusable), q = j.find((L) => L.active), R = j.find((L) => L.id === h), W = [q, R, ...j].filter(
8322
+ const j = y().filter((L) => L.focusable), q = j.find((L) => L.active), T = j.find((L) => L.id === h), U = [q, T, ...j].filter(
8323
8323
  Boolean
8324
8324
  ).map((L) => L.ref.current);
8325
- sa(W, f);
8325
+ sa(U, f);
8326
8326
  }
8327
8327
  }
8328
8328
  E.current = !1;
@@ -8430,7 +8430,7 @@ var Bp = na, Up = ra, Yo = "Radio", [Wp, ia] = ct(Yo), [Hp, Vp] = Wp(Yo), aa = d
8430
8430
  form: c,
8431
8431
  ...f
8432
8432
  } = e, [p, g] = d.useState(null), m = le(t, (v) => g(v)), w = d.useRef(!1), h = p ? c || !!p.closest("form") : !0;
8433
- return /* @__PURE__ */ O(Hp, { scope: n, checked: r, disabled: i, children: [
8433
+ return /* @__PURE__ */ I(Hp, { scope: n, checked: r, disabled: i, children: [
8434
8434
  /* @__PURE__ */ u(
8435
8435
  Ln.button,
8436
8436
  {
@@ -8686,7 +8686,7 @@ function tm({
8686
8686
  // Accept effective disabled state (handles global and override status)
8687
8687
  }) {
8688
8688
  const i = t[e.name] || "", a = s, l = e.options || [], c = e.inline || !1, f = e.renderType === "segment", p = f ? "mt-2 inline-flex w-full md:w-auto p-1 rounded-md bg-gray-50 border border-gray-200 shadow-inner" : c ? "flex flex-wrap gap-4" : "space-y-3";
8689
- return /* @__PURE__ */ O(
8689
+ return /* @__PURE__ */ I(
8690
8690
  "div",
8691
8691
  {
8692
8692
  className: `mb-4 ${e.fieldClass ? e.fieldClass : "col-span-full"}`,
@@ -8702,7 +8702,7 @@ function tm({
8702
8702
  "aria-label": e.label || e.name,
8703
8703
  children: l.map((g) => {
8704
8704
  const m = typeof g == "object" ? g.value : g, w = typeof g == "object" ? g.label : g, h = typeof g == "object" ? g.description : null, v = `${e.name}-${m}`, x = i === m;
8705
- return f ? /* @__PURE__ */ O(
8705
+ return f ? /* @__PURE__ */ I(
8706
8706
  "label",
8707
8707
  {
8708
8708
  htmlFor: v,
@@ -8724,7 +8724,7 @@ function tm({
8724
8724
  ]
8725
8725
  },
8726
8726
  m
8727
- ) : /* @__PURE__ */ O("div", { className: "relative flex items-start", children: [
8727
+ ) : /* @__PURE__ */ I("div", { className: "relative flex items-start", children: [
8728
8728
  /* @__PURE__ */ u("div", { className: "flex h-6 items-center", children: /* @__PURE__ */ u(
8729
8729
  ns,
8730
8730
  {
@@ -8738,7 +8738,7 @@ function tm({
8738
8738
                    `
8739
8739
  }
8740
8740
  ) }),
8741
- /* @__PURE__ */ O("div", { className: "ml-3 text-sm", children: [
8741
+ /* @__PURE__ */ I("div", { className: "ml-3 text-sm", children: [
8742
8742
  /* @__PURE__ */ u(
8743
8743
  "label",
8744
8744
  {
@@ -8790,7 +8790,7 @@ function nm({ field: e }) {
8790
8790
  `.trim();
8791
8791
  return (
8792
8792
  // Wrapper div ensures the component spans the full width of the container
8793
- /* @__PURE__ */ O(
8793
+ /* @__PURE__ */ I(
8794
8794
  "div",
8795
8795
  {
8796
8796
  className: `my-6 col-span-full w-full border-b border-gray-300 pb-2 ${c[r] || c.false}`,
@@ -8810,8 +8810,8 @@ function om({
8810
8810
  error: r
8811
8811
  }) {
8812
8812
  const [s, i] = be(!1), a = t[e.name] ?? null, l = (f) => n(e.name, f), c = () => n(e.name, null);
8813
- return /* @__PURE__ */ u("div", { children: /* @__PURE__ */ O(In, { open: s, onOpenChange: i, children: [
8814
- /* @__PURE__ */ u(Mn, { asChild: !0, children: /* @__PURE__ */ O(
8813
+ return /* @__PURE__ */ u("div", { children: /* @__PURE__ */ I(In, { open: s, onOpenChange: i, children: [
8814
+ /* @__PURE__ */ u(Mn, { asChild: !0, children: /* @__PURE__ */ I(
8815
8815
  "button",
8816
8816
  {
8817
8817
  type: "button",
@@ -8850,7 +8850,7 @@ function om({
8850
8850
  ]
8851
8851
  }
8852
8852
  ) }),
8853
- /* @__PURE__ */ O(
8853
+ /* @__PURE__ */ I(
8854
8854
  Dn,
8855
8855
  {
8856
8856
  align: "start",
@@ -8867,7 +8867,7 @@ function om({
8867
8867
  className: "rounded-md bg-white p-3 text-xs"
8868
8868
  }
8869
8869
  ),
8870
- /* @__PURE__ */ O("div", { className: "flex items-center justify-between gap-2 border-t border-gray-200 p-3", children: [
8870
+ /* @__PURE__ */ I("div", { className: "flex items-center justify-between gap-2 border-t border-gray-200 p-3", children: [
8871
8871
  /* @__PURE__ */ u(
8872
8872
  "button",
8873
8873
  {
@@ -8918,9 +8918,9 @@ function rm({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
8918
8918
  const y = parseInt(c);
8919
8919
  f((y === 0 ? 55 : y - 5).toString().padStart(2, "0"));
8920
8920
  };
8921
- return /* @__PURE__ */ O("div", { children: [
8922
- /* @__PURE__ */ O(In, { open: s, onOpenChange: i, children: [
8923
- /* @__PURE__ */ u(Mn, { asChild: !0, children: /* @__PURE__ */ O(
8921
+ return /* @__PURE__ */ I("div", { children: [
8922
+ /* @__PURE__ */ I(In, { open: s, onOpenChange: i, children: [
8923
+ /* @__PURE__ */ u(Mn, { asChild: !0, children: /* @__PURE__ */ I(
8924
8924
  "button",
8925
8925
  {
8926
8926
  type: "button",
@@ -8939,7 +8939,7 @@ function rm({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
8939
8939
  `,
8940
8940
  children: [
8941
8941
  m ? /* @__PURE__ */ u("span", { children: m }) : /* @__PURE__ */ u("span", { className: "text-gray-400", children: e.placeholder || "Select time" }),
8942
- /* @__PURE__ */ O(
8942
+ /* @__PURE__ */ I(
8943
8943
  "svg",
8944
8944
  {
8945
8945
  xmlns: "http://www.w3.org/2000/svg",
@@ -8967,9 +8967,9 @@ function rm({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
8967
8967
  align: "start",
8968
8968
  sideOffset: 2,
8969
8969
  className: "z-50 rounded-md border border-gray-200 bg-white p-4 shadow-md w-64",
8970
- children: /* @__PURE__ */ O("div", { className: "flex flex-col gap-4", children: [
8971
- /* @__PURE__ */ O("div", { className: "flex items-center justify-center gap-2", children: [
8972
- /* @__PURE__ */ O("div", { className: "flex flex-col items-center", children: [
8970
+ children: /* @__PURE__ */ I("div", { className: "flex flex-col gap-4", children: [
8971
+ /* @__PURE__ */ I("div", { className: "flex items-center justify-center gap-2", children: [
8972
+ /* @__PURE__ */ I("div", { className: "flex flex-col items-center", children: [
8973
8973
  /* @__PURE__ */ u(
8974
8974
  "button",
8975
8975
  {
@@ -9027,7 +9027,7 @@ function rm({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
9027
9027
  )
9028
9028
  ] }),
9029
9029
  /* @__PURE__ */ u("span", { className: "text-2xl font-semibold", children: ":" }),
9030
- /* @__PURE__ */ O("div", { className: "flex flex-col items-center", children: [
9030
+ /* @__PURE__ */ I("div", { className: "flex flex-col items-center", children: [
9031
9031
  /* @__PURE__ */ u(
9032
9032
  "button",
9033
9033
  {
@@ -9084,7 +9084,7 @@ function rm({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
9084
9084
  }
9085
9085
  )
9086
9086
  ] }),
9087
- /* @__PURE__ */ O("div", { className: "flex flex-col gap-1 ml-2", children: [
9087
+ /* @__PURE__ */ I("div", { className: "flex flex-col gap-1 ml-2", children: [
9088
9088
  /* @__PURE__ */ u(
9089
9089
  "button",
9090
9090
  {
@@ -9111,7 +9111,7 @@ function rm({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
9111
9111
  )
9112
9112
  ] })
9113
9113
  ] }),
9114
- /* @__PURE__ */ O("div", { className: "flex items-center justify-between gap-2 border-t border-gray-200 pt-3", children: [
9114
+ /* @__PURE__ */ I("div", { className: "flex items-center justify-between gap-2 border-t border-gray-200 pt-3", children: [
9115
9115
  /* @__PURE__ */ u(
9116
9116
  "button",
9117
9117
  {
@@ -9139,13 +9139,13 @@ function rm({ field: e, formValues: t, handleChange: n, handleBlur: o, error: r
9139
9139
  ] });
9140
9140
  }
9141
9141
  function sm({ message: e }) {
9142
- return /* @__PURE__ */ u("div", { className: "rounded-lg bg-red-50 border border-red-100 p-4 shadow-sm", children: /* @__PURE__ */ O("div", { className: "flex items-center gap-3", children: [
9142
+ return /* @__PURE__ */ u("div", { className: "rounded-lg bg-red-50 border border-red-100 p-4 shadow-sm", children: /* @__PURE__ */ I("div", { className: "flex items-center gap-3", children: [
9143
9143
  /* @__PURE__ */ u(gd, { "aria-hidden": "true", className: "size-5 text-red-500 shrink-0" }),
9144
9144
  /* @__PURE__ */ u("span", { className: "text-sm font-medium text-red-900", children: e })
9145
9145
  ] }) });
9146
9146
  }
9147
9147
  function im({ message: e }) {
9148
- return /* @__PURE__ */ u("div", { className: "rounded-lg bg-amber-50 border border-amber-100 p-4 shadow-sm", children: /* @__PURE__ */ O("div", { className: "flex items-center gap-3", children: [
9148
+ return /* @__PURE__ */ u("div", { className: "rounded-lg bg-amber-50 border border-amber-100 p-4 shadow-sm", children: /* @__PURE__ */ I("div", { className: "flex items-center gap-3", children: [
9149
9149
  /* @__PURE__ */ u(
9150
9150
  fd,
9151
9151
  {
@@ -9157,7 +9157,7 @@ function im({ message: e }) {
9157
9157
  ] }) });
9158
9158
  }
9159
9159
  function am({ message: e }) {
9160
- return /* @__PURE__ */ u("div", { className: "rounded-lg bg-green-50 border border-green-100 p-4 shadow-sm", children: /* @__PURE__ */ O("div", { className: "flex items-center gap-3", children: [
9160
+ return /* @__PURE__ */ u("div", { className: "rounded-lg bg-green-50 border border-green-100 p-4 shadow-sm", children: /* @__PURE__ */ I("div", { className: "flex items-center gap-3", children: [
9161
9161
  /* @__PURE__ */ u(
9162
9162
  md,
9163
9163
  {
@@ -9169,7 +9169,7 @@ function am({ message: e }) {
9169
9169
  ] }) });
9170
9170
  }
9171
9171
  function lm({ message: e }) {
9172
- return /* @__PURE__ */ u("div", { className: "rounded-lg bg-blue-50 border border-blue-100 p-4 shadow-sm", children: /* @__PURE__ */ O("div", { className: "flex items-center gap-3", children: [
9172
+ return /* @__PURE__ */ u("div", { className: "rounded-lg bg-blue-50 border border-blue-100 p-4 shadow-sm", children: /* @__PURE__ */ I("div", { className: "flex items-center gap-3", children: [
9173
9173
  /* @__PURE__ */ u(Sd, { "aria-hidden": "true", className: "size-5 text-blue-600 shrink-0" }),
9174
9174
  /* @__PURE__ */ u("span", { className: "text-sm font-medium text-blue-900", children: e })
9175
9175
  ] }) });
@@ -9235,28 +9235,28 @@ const ym = ({
9235
9235
  linebreak: Rp
9236
9236
  }),
9237
9237
  []
9238
- ), A = async (T, _ = null) => {
9238
+ ), A = async (N, _ = null) => {
9239
9239
  if (!e) {
9240
- const V = `apiClient prop is required when using fields with optionsUrl. Field "${T.name}" requires optionsUrl but no apiClient was provided.`;
9240
+ const V = `apiClient prop is required when using fields with optionsUrl. Field "${N.name}" requires optionsUrl but no apiClient was provided.`;
9241
9241
  l && console.error(V), fn.error(V);
9242
9242
  return;
9243
9243
  }
9244
9244
  try {
9245
- const V = await e(`/${T.optionsUrl}`);
9246
- let I = [];
9247
- T.type === "select" ? I = [
9248
- { value: "", label: `Select ${T.label.toLowerCase()}` },
9245
+ const V = await e(`/${N.optionsUrl}`);
9246
+ let O = [];
9247
+ N.type === "select" ? O = [
9248
+ { value: "", label: `Select ${N.label.toLowerCase()}` },
9249
9249
  ...V.data
9250
- ] : I = [
9251
- ...V.data.map((K) => ({
9252
- value: K.value,
9253
- label: K.label
9250
+ ] : O = [
9251
+ ...V.data.map((G) => ({
9252
+ value: G.value,
9253
+ label: G.label
9254
9254
  }))
9255
- ], o.fields.forEach((K) => {
9256
- K.name === T.name && (K.options = I);
9255
+ ], o.fields.forEach((G) => {
9256
+ G.name === N.name && (G.options = O);
9257
9257
  });
9258
9258
  } catch (V) {
9259
- l && console.error(`Failed to load options for ${T.name}:`, V);
9259
+ l && console.error(`Failed to load options for ${N.name}:`, V);
9260
9260
  } finally {
9261
9261
  }
9262
9262
  };
@@ -9269,81 +9269,90 @@ const ym = ({
9269
9269
  const _ = {};
9270
9270
  o.fields.forEach((V) => {
9271
9271
  if (!V.name) return;
9272
- const I = V.type === "multiselect" || V.type === "checkbox" && V.options && V.options.length > 0;
9273
- _[V.name] = i[V.name] ?? V.value ?? (I ? [] : "");
9272
+ const O = V.type === "multiselect" || V.type === "checkbox" && V.options && V.options.length > 0;
9273
+ _[V.name] = i[V.name] ?? V.value ?? (O ? [] : "");
9274
9274
  }), f(_);
9275
9275
  }
9276
9276
  }, [o]);
9277
- const G = (T, _, V) => {
9278
- const I = typeof _ == "object" && _ !== null && !Array.isArray(_) && !(_ instanceof Date), K = _ == null || typeof _ == "string" && _.trim() === "" || Array.isArray(_) && _.length === 0 || T.type === "checkbox" && _ === !1 || I && Object.keys(_).length === 0;
9279
- if (T.required && K)
9280
- return l && console.warn(`VALIDATION FAILED (REQUIRED): ${T.name} is empty.`), `${T.label} is required`;
9281
- if (K && !T.required)
9277
+ const Y = (N, _, V) => {
9278
+ const O = typeof _ == "object" && _ !== null && !Array.isArray(_) && !(_ instanceof Date), G = _ == null || typeof _ == "string" && _.trim() === "" || Array.isArray(_) && _.length === 0 || N.type === "checkbox" && _ === !1 || O && Object.keys(_).length === 0;
9279
+ if (N.required && G)
9280
+ return l && console.warn(`VALIDATION FAILED (REQUIRED): ${N.name} is empty.`), `${N.label} is required`;
9281
+ if (G && !N.required)
9282
9282
  return null;
9283
- if (T.validate) {
9284
- const M = T.validate(_, V);
9283
+ if (N.validate) {
9284
+ const M = N.validate(_, V);
9285
9285
  if (M) return M;
9286
9286
  }
9287
- if (T.type === "email" && _ && !/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(_))
9287
+ if (N.type === "email" && _ && !/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(_))
9288
9288
  return "Please enter a valid email address";
9289
- if (T.type === "number") {
9290
- if (T.min !== void 0 && _ < T.min)
9291
- return `${T.label} must be at least ${T.min}`;
9292
- if (T.max !== void 0 && _ > T.max)
9293
- return `${T.label} must be no more than ${T.max}`;
9289
+ if (N.type === "number") {
9290
+ if (N.min !== void 0 && _ < N.min)
9291
+ return `${N.label} must be at least ${N.min}`;
9292
+ if (N.max !== void 0 && _ > N.max)
9293
+ return `${N.label} must be no more than ${N.max}`;
9294
9294
  }
9295
- return T.type === "date" && _ && !fr(_).isValid() ? `${T.label} must be a valid date` : T.maxLength && _ && _.length > T.maxLength ? `${T.label} must not exceed ${T.maxLength} characters` : null;
9296
- }, X = (T, _) => {
9297
- const V = o.fields.find((M) => M.name === T);
9295
+ return N.type === "date" && _ && !fr(_).isValid() ? `${N.label} must be a valid date` : N.maxLength && _ && _.length > N.maxLength ? `${N.label} must not exceed ${N.maxLength} characters` : null;
9296
+ }, X = (N, _) => {
9297
+ const V = o.fields.find((M) => M.name === N);
9298
9298
  if (!V) return;
9299
- const I = { ...c };
9300
- V.type === "multiselect" ? I[T] = Array.isArray(_) ? _ : Array.from(_.target.selectedOptions).map(
9299
+ const O = { ...c };
9300
+ V.type === "multiselect" ? O[N] = Array.isArray(_) ? _ : Array.from(_.target.selectedOptions).map(
9301
9301
  (M) => M.value
9302
- ) : V.type === "dateRange" ? I[T] = [
9302
+ ) : V.type === "dateRange" ? O[N] = [
9303
9303
  {
9304
9304
  startDate: _[0].from,
9305
9305
  endDate: _[0].to,
9306
9306
  key: "selection"
9307
9307
  }
9308
- ] : V.type === "dayTimePicker" ? I[T] = _ ? fr(_).format("YYYY-MM-DD HH:mm:ss") : "" : I[T] = _, V.type === "select" && o.fields.forEach((M) => {
9309
- if (M.showIf && !M.showIf(I)) {
9308
+ ] : V.type === "dayTimePicker" ? O[N] = _ ? fr(_).format("YYYY-MM-DD HH:mm:ss") : "" : O[N] = _, V.type === "select" && o.fields.forEach((M) => {
9309
+ if (M.showIf && !M.showIf(O)) {
9310
9310
  const re = M.type === "multiselect" || M.type === "checkbox" && M.options && M.options.length > 0;
9311
- I[M.name] = re ? [] : "";
9311
+ O[M.name] = re ? [] : "";
9312
9312
  }
9313
9313
  }), o.fields.forEach((M) => {
9314
- if (typeof M.disabled == "function" && M.disabled(I)) {
9314
+ if (typeof M.disabled == "function" && M.disabled(O)) {
9315
9315
  const re = M.type === "multiselect" || M.type === "checkbox" && M.options && M.options.length > 0;
9316
- I[M.name] = re ? [] : "";
9316
+ O[M.name] = re ? [] : "";
9317
9317
  }
9318
- }), f(I);
9319
- const K = {};
9318
+ }), f(O);
9319
+ const G = {};
9320
9320
  o.fields.forEach((M) => {
9321
- if (M.name && (typeof M.disabled == "function" ? M.disabled(I) : M.disabled, x[M.name], // Only check if the field is shown
9322
- !M.showIf || M.showIf(I))) {
9323
- const re = G(M, I[M.name], I);
9324
- re && (K[M.name] = re);
9321
+ if (M.name && (typeof M.disabled == "function" ? M.disabled(O) : M.disabled, x[M.name], // Only check if the field is shown
9322
+ !M.showIf || M.showIf(O))) {
9323
+ const re = Y(M, O[M.name], O);
9324
+ re && (G[M.name] = re);
9325
9325
  }
9326
- }), g(K);
9327
- }, j = (T) => {
9328
- w({ ...m, [T]: !0 });
9329
- }, q = (T) => {
9330
- T.preventDefault();
9326
+ }), g(G);
9327
+ }, j = (N) => {
9328
+ w({ ...m, [N]: !0 });
9329
+ }, q = (N) => {
9330
+ N.preventDefault();
9331
9331
  const _ = {};
9332
- o.fields.forEach((I) => {
9333
- _[I.name] = !0;
9332
+ o.fields.forEach((O) => {
9333
+ _[O.name] = !0;
9334
9334
  }), w(_);
9335
9335
  const V = {};
9336
- o.fields.forEach((I) => {
9337
- if (I.name && (typeof I.disabled == "function" ? I.disabled(c) : I.disabled, x[I.name], !I.showIf || I.showIf(c))) {
9338
- const K = G(I, c[I.name], c);
9339
- K && (V[I.name] = K);
9336
+ if (o.fields.forEach((O) => {
9337
+ if (O.name && (typeof O.disabled == "function" ? O.disabled(c) : O.disabled, x[O.name], !O.showIf || O.showIf(c))) {
9338
+ const G = Y(O, c[O.name], c);
9339
+ G && (V[O.name] = G);
9340
9340
  }
9341
- }), g(V), Object.keys(V).length === 0 ? l ? console.log("Form submitted with values:", c) : r(c) : fn.error("Please correct the errors in the form");
9341
+ }), g(V), Object.keys(V).length === 0) {
9342
+ const O = {};
9343
+ o.fields.forEach((G) => {
9344
+ G.name && (O[G.name] = {
9345
+ value: c[G.name],
9346
+ fieldType: G.fieldType || "string"
9347
+ });
9348
+ }), l ? console.log("Form submitted with values:", O) : r(O);
9349
+ } else
9350
+ fn.error("Please correct the errors in the form");
9342
9351
  };
9343
9352
  fo(() => {
9344
9353
  a(c);
9345
9354
  }, [c, a]);
9346
- const R = {
9355
+ const T = {
9347
9356
  green: "border-green-500 bg-green-50",
9348
9357
  blue: "border-blue-500 bg-blue-50",
9349
9358
  red: "border-red-500 bg-red-50",
@@ -9354,21 +9363,21 @@ const ym = ({
9354
9363
  pink: "border-pink-500 bg-pink-50",
9355
9364
  orange: "border-orange-500 bg-orange-50"
9356
9365
  }, $ = () => {
9357
- C.fieldName && S((T) => ({
9358
- ...T,
9366
+ C.fieldName && S((N) => ({
9367
+ ...N,
9359
9368
  [C.fieldName]: !0
9360
9369
  })), y({ isOpen: !1, fieldName: null });
9361
- }, W = () => {
9370
+ }, U = () => {
9362
9371
  y({ isOpen: !1, fieldName: null });
9363
9372
  };
9364
- function L(T, _, V) {
9373
+ function L(N, _, V) {
9365
9374
  if (l && (V ? console.log(
9366
9375
  `[fieldFormat RENDER] Rendering error for ${_.name}: ${V}`
9367
9376
  ) : p[_.name] && console.log(
9368
9377
  `[fieldFormat RENDER] Error exists in state for ${_.name} but not passed in props!`
9369
9378
  )), F.includes(_.type))
9370
- return /* @__PURE__ */ u("div", { className: _.fieldClass || "col-span-full", children: T });
9371
- const I = _.containerStyle, K = _.color || "blue", M = I === "card" ? `rounded-lg border text-card-foreground shadow-sm p-4 ${_.containerClassName || R[K] || R.blue}` : "", re = x[_.name] === !0, D = _.disabled === !0 && _.override === !0, ee = () => {
9379
+ return /* @__PURE__ */ u("div", { className: _.fieldClass || "col-span-full", children: N });
9380
+ const O = _.containerStyle, G = _.color || "blue", M = O === "card" ? `rounded-lg border text-card-foreground shadow-sm p-4 ${_.containerClassName || T[G] || T.blue}` : "", re = x[_.name] === !0, D = _.disabled === !0 && _.override === !0, ee = () => {
9372
9381
  const Q = _.name;
9373
9382
  !re ? y({
9374
9383
  isOpen: !0,
@@ -9378,8 +9387,8 @@ const ym = ({
9378
9387
  [Q]: !1
9379
9388
  // Lock it back (set override to false)
9380
9389
  }));
9381
- }, ie = /* @__PURE__ */ O(Ve, { children: [
9382
- _.label && /* @__PURE__ */ O(
9390
+ }, ie = /* @__PURE__ */ I(Ve, { children: [
9391
+ _.label && /* @__PURE__ */ I(
9383
9392
  "label",
9384
9393
  {
9385
9394
  htmlFor: _.name,
@@ -9401,48 +9410,48 @@ const ym = ({
9401
9410
  ]
9402
9411
  }
9403
9412
  ),
9404
- /* @__PURE__ */ u("div", { children: T }),
9413
+ /* @__PURE__ */ u("div", { children: N }),
9405
9414
  V && /* @__PURE__ */ u("p", { className: "text-sm text-red-500 mt-1", children: V })
9406
9415
  ] });
9407
- return /* @__PURE__ */ u("div", { className: `mb-4 ${_.fieldClass || "col-span-8"}`, children: I === "card" ? /* @__PURE__ */ u("div", { className: M, children: ie }) : ie });
9416
+ return /* @__PURE__ */ u("div", { className: `mb-4 ${_.fieldClass || "col-span-8"}`, children: O === "card" ? /* @__PURE__ */ u("div", { className: M, children: ie }) : ie });
9408
9417
  }
9409
- const Y = (T) => {
9410
- if (T.showIf && !T.showIf(c)) return null;
9411
- const _ = k[T.type] || Br;
9412
- if (c[T.name] === void 0) {
9413
- const re = T.type === "multiselect" || T.type === "checkbox" && T.options && T.options.length > 0;
9414
- c[T.name] = T.value !== void 0 ? T.value : re ? [] : "";
9418
+ const K = (N) => {
9419
+ if (N.showIf && !N.showIf(c)) return null;
9420
+ const _ = k[N.type] || Br;
9421
+ if (c[N.name] === void 0) {
9422
+ const re = N.type === "multiselect" || N.type === "checkbox" && N.options && N.options.length > 0;
9423
+ c[N.name] = N.value !== void 0 ? N.value : re ? [] : "";
9415
9424
  }
9416
- const V = p[T.name] ? p[T.name] : null, I = typeof T.disabled == "function" ? T.disabled(c) : !!T.disabled, K = x[T.name] === !0, M = I && !K;
9425
+ const V = p[N.name] ? p[N.name] : null, O = typeof N.disabled == "function" ? N.disabled(c) : !!N.disabled, G = x[N.name] === !0, M = O && !G;
9417
9426
  return L(
9418
9427
  /* @__PURE__ */ u(
9419
9428
  _,
9420
9429
  {
9421
- field: T,
9430
+ field: N,
9422
9431
  formValues: c,
9423
9432
  handleChange: X,
9424
- handleBlur: () => j(T.name),
9433
+ handleBlur: () => j(N.name),
9425
9434
  setCharCounts: v,
9426
- charCount: h[T.name] || 0,
9435
+ charCount: h[N.name] || 0,
9427
9436
  api_URL: t,
9428
9437
  error: V,
9429
9438
  fileInputRefs: E,
9430
9439
  disabled: M
9431
9440
  }
9432
9441
  ),
9433
- T,
9442
+ N,
9434
9443
  V
9435
9444
  );
9436
9445
  }, ne = o?.fields?.find(
9437
- (T) => T.name === C.fieldName
9446
+ (N) => N.name === C.fieldName
9438
9447
  )?.label || C.fieldName;
9439
- return /* @__PURE__ */ O(
9448
+ return /* @__PURE__ */ I(
9440
9449
  "form",
9441
9450
  {
9442
9451
  onSubmit: q,
9443
9452
  className: "grid grid-cols-12 gap-x-4 mx-auto w-full  ",
9444
9453
  children: [
9445
- o ? o.fields.map((T) => /* @__PURE__ */ u("div", { className: "col-span-full", children: Y(T) }, T.name + T.type)) : /* @__PURE__ */ u("div", { children: "Loading..." }),
9454
+ o ? o.fields.map((N) => /* @__PURE__ */ u("div", { className: "col-span-full", children: K(N) }, N.name + N.type)) : /* @__PURE__ */ u("div", { children: "Loading..." }),
9446
9455
  /* @__PURE__ */ u(
9447
9456
  "div",
9448
9457
  {
@@ -9450,76 +9459,84 @@ const ym = ({
9450
9459
  children: s
9451
9460
  }
9452
9461
  ),
9453
- C.isOpen && /* @__PURE__ */ O(Ve, { children: [
9454
- /* @__PURE__ */ u("div", { className: "fixed inset-0 z-[99] bg-black opacity-40" }),
9462
+ C.isOpen && /* @__PURE__ */ I(Ve, { children: [
9455
9463
  /* @__PURE__ */ u(
9456
- "button",
9464
+ "div",
9457
9465
  {
9458
- type: "button",
9459
- className: "fixed inset-0 z-[100] flex items-center justify-center p-4",
9460
- onClick: W,
9461
- children: /* @__PURE__ */ O(
9462
- "button",
9463
- {
9464
- type: "button",
9465
- className: "bg-white rounded-xl shadow-2xl w-full max-w-sm transform transition-all",
9466
- onClick: (T) => T.stopPropagation(),
9467
- children: [
9468
- /* @__PURE__ */ O("div", { className: "flex justify-between items-center border-b p-4", children: [
9469
- /* @__PURE__ */ u("h3", { className: "text-xl font-bold text-gray-900", children: "Confirm Field Unlock" }),
9470
- /* @__PURE__ */ u(
9471
- "button",
9472
- {
9473
- type: "button",
9474
- onClick: W,
9475
- className: "text-gray-400 hover:text-gray-600 p-1 rounded-full hover:bg-gray-100 transition",
9476
- "aria-label": "Close",
9477
- children: /* @__PURE__ */ u(Td, { size: 20 })
9478
- }
9479
- )
9466
+ className: "fixed inset-0 z-30 bg-black opacity-40",
9467
+ onClick: U,
9468
+ tabIndex: 0,
9469
+ role: "button",
9470
+ onKeyDown: (N) => {
9471
+ (N.key === "Enter" || N.key === " ") && U();
9472
+ }
9473
+ }
9474
+ ),
9475
+ /* @__PURE__ */ u("div", { className: "fixed inset-0 z-50 flex items-center justify-center p-4", children: /* @__PURE__ */ I(
9476
+ "div",
9477
+ {
9478
+ className: "bg-white rounded-xl shadow-2xl w-full max-w-sm transform transition-all",
9479
+ onClick: (N) => N.stopPropagation(),
9480
+ tabIndex: -1,
9481
+ role: "dialog",
9482
+ "aria-modal": "true",
9483
+ onKeyDown: (N) => {
9484
+ N.key === "Escape" && U();
9485
+ },
9486
+ children: [
9487
+ /* @__PURE__ */ I("div", { className: "flex justify-between items-center border-b p-4", children: [
9488
+ /* @__PURE__ */ u("h3", { className: "text-xl font-bold text-gray-900", children: "Confirm Field Unlock" }),
9489
+ /* @__PURE__ */ u(
9490
+ "button",
9491
+ {
9492
+ type: "button",
9493
+ onClick: U,
9494
+ className: "text-gray-400 hover:text-gray-600 p-1 rounded-full hover:bg-gray-100 transition",
9495
+ "aria-label": "Close",
9496
+ children: /* @__PURE__ */ u(Td, { size: 20 })
9497
+ }
9498
+ )
9499
+ ] }),
9500
+ /* @__PURE__ */ I("div", { className: "p-6 flex flex-col gap-2", children: [
9501
+ /* @__PURE__ */ I("p", { className: "text-gray-700 text-sm leading-relaxed ", children: [
9502
+ "Are you sure you want to",
9503
+ " ",
9504
+ /* @__PURE__ */ I("span", { className: "font-extrabold text-destructive", children: [
9505
+ "unlock",
9506
+ " "
9480
9507
  ] }),
9481
- /* @__PURE__ */ O("div", { className: "p-6 flex flex-col gap-2", children: [
9482
- /* @__PURE__ */ O("p", { className: "text-gray-700 text-sm leading-relaxed ", children: [
9483
- "Are you sure you want to",
9484
- " ",
9485
- /* @__PURE__ */ O("span", { className: "font-extrabold text-destructive", children: [
9486
- "unlock",
9487
- " "
9488
- ] }),
9489
- "the field"
9490
- ] }),
9491
- /* @__PURE__ */ O("p", { className: "font-bold", children: [
9492
- '"',
9493
- ne,
9494
- '"'
9495
- ] }),
9496
- /* @__PURE__ */ u("div", { className: "italic text-sm   text-gray-500 mb-2", children: "This action allows editing of a protected value." }),
9497
- /* @__PURE__ */ O("div", { className: "flex justify-end gap-3 ", children: [
9498
- /* @__PURE__ */ u(
9499
- "button",
9500
- {
9501
- type: "button",
9502
- onClick: W,
9503
- className: "px-4 py-2 text-sm font-medium text-gray-700 bg-gray-200 rounded-lg hover:bg-gray-300 transition",
9504
- children: "Cancel"
9505
- }
9506
- ),
9507
- /* @__PURE__ */ u(
9508
- "button",
9509
- {
9510
- type: "button",
9511
- onClick: $,
9512
- className: "px-4 py-2 text-sm font-medium text-white bg-destructive rounded-lg hover:bg-red-700 transition shadow-md",
9513
- children: "Unlock Field"
9514
- }
9515
- )
9516
- ] })
9517
- ] })
9518
- ]
9519
- }
9520
- )
9508
+ "the field"
9509
+ ] }),
9510
+ /* @__PURE__ */ I("p", { className: "font-bold", children: [
9511
+ '"',
9512
+ ne,
9513
+ '"'
9514
+ ] }),
9515
+ /* @__PURE__ */ u("div", { className: "italic text-sm text-gray-500 mb-2", children: "This action allows editing of a protected value." }),
9516
+ /* @__PURE__ */ I("div", { className: "flex justify-end gap-3 ", children: [
9517
+ /* @__PURE__ */ u(
9518
+ "button",
9519
+ {
9520
+ type: "button",
9521
+ onClick: U,
9522
+ className: "px-4 py-2 text-sm font-medium text-gray-700 bg-gray-200 rounded-lg hover:bg-gray-300 transition",
9523
+ children: "Cancel"
9524
+ }
9525
+ ),
9526
+ /* @__PURE__ */ u(
9527
+ "button",
9528
+ {
9529
+ type: "button",
9530
+ onClick: $,
9531
+ className: "px-4 py-2 text-sm font-medium text-white bg-destructive rounded-lg hover:bg-red-700 transition shadow-md",
9532
+ children: "Unlock Field"
9533
+ }
9534
+ )
9535
+ ] })
9536
+ ] })
9537
+ ]
9521
9538
  }
9522
- )
9539
+ ) })
9523
9540
  ] })
9524
9541
  ]
9525
9542
  }