tailwind-ux-kit 1.0.96 → 1.0.100

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,6 +1,6 @@
1
1
  "use client";
2
2
  import { jsxs as k, jsx as i } from "react/jsx-runtime";
3
- import T, { forwardRef as ae, useState as M, useMemo as z, useId as be, useRef as K, useCallback as A, useEffect as R, createContext as le, useContext as ie } from "react";
3
+ import T, { forwardRef as ae, useState as M, useMemo as z, useId as be, useRef as _, useCallback as A, useEffect as R, createContext as le, useContext as ie } from "react";
4
4
  const ee = {
5
5
  xs: "text-xs px-2 py-1",
6
6
  sm: "text-sm px-3 py-1.5",
@@ -49,22 +49,22 @@ const ee = {
49
49
  isValid: x,
50
50
  isInvalid: g,
51
51
  feedback: b,
52
- iconClasses: $,
52
+ iconClasses: C,
53
53
  feedbackType: S = "invalid",
54
54
  labelClasses: N = "",
55
55
  inputType: h = "",
56
56
  inputPattern: v,
57
57
  ...m
58
- } = e, [y, D] = M("default"), E = T.useCallback(
58
+ } = e, [w, D] = M("default"), E = T.useCallback(
59
59
  (j) => {
60
60
  const O = j.target.value, Z = (p == null ? void 0 : p(O)) ?? "default";
61
61
  D(Z), u == null || u(j, Z), f == null || f(j);
62
62
  },
63
63
  [p, u, f]
64
- ), w = z(() => r || (typeof t == "string" ? `input-${t.toLowerCase().replace(/\s+/g, "-")}` : `input-${Math.random().toString(36).slice(2)}`), [r, t]), L = !!l, C = ee[s] || ee.md, P = te[c] || te.flat, I = z(
65
- () => he(y, x, g),
66
- [y, x, g]
67
- ), B = z(() => o === "start" || o === "left" ? "left-0 ps-3.5" : "right-0 pe-3.5", [o]), _ = z(() => a ? o === "start" || o === "left" ? "ps-10" : "pe-10" : "", [a, o]), F = (j) => {
64
+ ), y = z(() => r || (typeof t == "string" ? `input-${t.toLowerCase().replace(/\s+/g, "-")}` : `input-${Math.random().toString(36).slice(2)}`), [r, t]), L = !!l, $ = ee[s] || ee.md, P = te[c] || te.flat, I = z(
65
+ () => he(w, x, g),
66
+ [w, x, g]
67
+ ), B = z(() => o === "start" || o === "left" ? "left-0 ps-3.5" : "right-0 pe-3.5", [o]), F = z(() => a ? o === "start" || o === "left" ? "ps-10" : "pe-10" : "", [a, o]), K = (j) => {
68
68
  var H;
69
69
  const O = j.key;
70
70
  !(j.ctrlKey || j.metaKey || O.length !== 1 || ["Backspace", "ArrowLeft", "ArrowRight", "Delete", "Tab"].includes(O)) && (() => {
@@ -113,7 +113,7 @@ const ee = {
113
113
  !L && t && /* @__PURE__ */ i(
114
114
  "label",
115
115
  {
116
- htmlFor: w,
116
+ htmlFor: y,
117
117
  className: `block mb-1 text-sm ${x ? "text-green-700 dark:text-green-500" : g ? "text-red-700 dark:text-red-500" : "text-gray-700"} ${N}`,
118
118
  children: t
119
119
  }
@@ -122,7 +122,7 @@ const ee = {
122
122
  a && /* @__PURE__ */ i(
123
123
  "div",
124
124
  {
125
- className: `absolute inset-y-0 flex items-center ${B} ${$}`,
125
+ className: `absolute inset-y-0 flex items-center ${B} ${C}`,
126
126
  "aria-hidden": "true",
127
127
  children: a
128
128
  }
@@ -131,22 +131,22 @@ const ee = {
131
131
  "input",
132
132
  {
133
133
  ...m,
134
- id: w,
134
+ id: y,
135
135
  ref: n,
136
136
  placeholder: L ? " " : m.placeholder,
137
137
  onChange: E,
138
- onKeyDown: F,
138
+ onKeyDown: K,
139
139
  onPaste: U,
140
140
  className: `border peer w-full block font-normal appearance-none focus:outline-none focus:ring-0 transition text-gray-900 placeholder-gray-600 border-gray-400
141
- ${C}
141
+ ${$}
142
142
  ${L && l && me[l]}
143
- ${_} ${P} ${I} ${d}`
143
+ ${F} ${P} ${I} ${d}`
144
144
  }
145
145
  ),
146
146
  L && t && l && /* @__PURE__ */ i(
147
147
  "label",
148
148
  {
149
- htmlFor: w,
149
+ htmlFor: y,
150
150
  className: `ms-1 ${xe[l]} ${d}`,
151
151
  children: t
152
152
  }
@@ -214,18 +214,18 @@ const we = {
214
214
  isValid: x,
215
215
  isInvalid: g,
216
216
  feedback: b,
217
- feedbackType: $ = "invalid",
217
+ feedbackType: C = "invalid",
218
218
  children: S,
219
219
  ...N
220
- } = e, [h, v] = M("default"), m = be(), y = z(() => r || (typeof t == "string" ? `select-${t.toLowerCase().replace(/\s+/g, "-")}` : m), [r, t, m]), D = (B) => {
221
- const _ = B.target.value, F = (p == null ? void 0 : p(_)) ?? "default";
222
- v(F), u == null || u(B, F), f == null || f(B);
223
- }, E = !!l, w = we[s], L = ve[c], C = ke(h, x, g);
220
+ } = e, [h, v] = M("default"), m = be(), w = z(() => r || (typeof t == "string" ? `select-${t.toLowerCase().replace(/\s+/g, "-")}` : m), [r, t, m]), D = (B) => {
221
+ const F = B.target.value, K = (p == null ? void 0 : p(F)) ?? "default";
222
+ v(K), u == null || u(B, K), f == null || f(B);
223
+ }, E = !!l, y = we[s], L = ve[c], $ = ke(h, x, g);
224
224
  return /* @__PURE__ */ k("div", { className: `w-full relative ${E ? "z-0" : ""}`, children: [
225
225
  !E && t && /* @__PURE__ */ i(
226
226
  "label",
227
227
  {
228
- htmlFor: y,
228
+ htmlFor: w,
229
229
  className: `block mb-1 text-sm ${x ? "text-green-700" : g ? "text-red-700" : "text-gray-700"}`,
230
230
  children: t
231
231
  }
@@ -242,20 +242,20 @@ const we = {
242
242
  "select",
243
243
  {
244
244
  ...N,
245
- id: y,
245
+ id: w,
246
246
  ref: n,
247
247
  onChange: D,
248
248
  className: `border peer w-full block font-normal appearance-none focus:outline-none focus:ring-0 transition text-gray-600 placeholder-[#798ba5] border-gray-400
249
- ${w} ${a && (o === "start" || o === "left") ? "ps-10" : a ? "pe-10" : ""}
249
+ ${y} ${a && (o === "start" || o === "left") ? "ps-10" : a ? "pe-10" : ""}
250
250
  ${E && l && Ce[l]}
251
- ${L} ${C} ${d}`,
251
+ ${L} ${$} ${d}`,
252
252
  children: S
253
253
  }
254
254
  ),
255
255
  E && t && l && /* @__PURE__ */ i(
256
256
  "label",
257
257
  {
258
- htmlFor: y,
258
+ htmlFor: w,
259
259
  className: `ms-1 ${$e[l]} ${d}`,
260
260
  children: t
261
261
  }
@@ -264,7 +264,7 @@ const we = {
264
264
  b && /* @__PURE__ */ i(
265
265
  "p",
266
266
  {
267
- className: `mt-1 text-xs ${$ === "invalid" ? "text-red-600" : "text-green-600"}`,
267
+ className: `mt-1 text-xs ${C === "invalid" ? "text-red-600" : "text-green-600"}`,
268
268
  children: b
269
269
  }
270
270
  )
@@ -521,9 +521,9 @@ const Te = {
521
521
  checked: l,
522
522
  ...f
523
523
  }, x) => {
524
- const g = (w) => {
525
- !c && s && s(w.target.checked), f.onChange && f.onChange(w);
526
- }, b = "mr-2 border flex items-center justify-center transition-all", $ = Te[n], S = Re[t], N = Be[r] ?? "", h = r.startsWith("outline"), v = r.startsWith("soft"), D = `${b} ${$} ${S} ${N} ${l && (h || v || r === "link") ? "peer-checked:bg-current peer-checked:text-white" : l ? "peer-checked:bg-current" : ""}`, E = {
524
+ const g = (y) => {
525
+ !c && s && s(y.target.checked), f.onChange && f.onChange(y);
526
+ }, b = "mr-2 border flex items-center justify-center transition-all", C = Te[n], S = Re[t], N = Be[r] ?? "", h = r.startsWith("outline"), v = r.startsWith("soft"), D = `${b} ${C} ${S} ${N} ${l && (h || v || r === "link") ? "peer-checked:bg-current peer-checked:text-white" : l ? "peer-checked:bg-current" : ""}`, E = {
527
527
  xs: "w-2 h-2",
528
528
  sm: "w-2.5 h-2.5",
529
529
  md: "w-3 h-3",
@@ -572,47 +572,47 @@ const Ve = ({
572
572
  forceCloseDropdown: f,
573
573
  ...x
574
574
  }) => {
575
- const [g, b] = M(!1), [$, S] = M(!1), N = K(null), h = K(null), v = z(() => ({
575
+ const [g, b] = M(!1), [C, S] = M(!1), N = _(null), h = _(null), v = z(() => ({
576
576
  left: "left-0",
577
577
  center: "left-1/2 transform -translate-x-1/2",
578
578
  right: "right-0"
579
579
  })[c], [c]), m = A(() => {
580
- const C = h.current, P = N.current;
581
- if (!C || !P) return;
582
- const { top: I, bottom: B } = C.getBoundingClientRect(), _ = P.offsetHeight, F = window.innerHeight - B, U = I;
583
- S(F < _ && U > _);
584
- }, []), y = A((C) => {
580
+ const $ = h.current, P = N.current;
581
+ if (!$ || !P) return;
582
+ const { top: I, bottom: B } = $.getBoundingClientRect(), F = P.offsetHeight, K = window.innerHeight - B, U = I;
583
+ S(K < F && U > F);
584
+ }, []), w = A(($) => {
585
585
  var P, I;
586
- !((P = N.current) != null && P.contains(C.target)) && !((I = h.current) != null && I.contains(C.target)) && b(!1);
587
- }, []), D = A(() => b((C) => !C), []), E = A(() => b(!1), []);
586
+ !((P = N.current) != null && P.contains($.target)) && !((I = h.current) != null && I.contains($.target)) && b(!1);
587
+ }, []), D = A(() => b(($) => !$), []), E = A(() => b(!1), []);
588
588
  R(() => {
589
589
  if (g)
590
590
  return m(), window.addEventListener("resize", m), window.addEventListener("scroll", m, !0), () => {
591
591
  window.removeEventListener("resize", m), window.removeEventListener("scroll", m, !0);
592
592
  };
593
593
  }, [g, m]);
594
- const w = K(g);
594
+ const y = _(g);
595
595
  R(() => {
596
- w.current = g;
596
+ y.current = g;
597
597
  }, [g]), R(() => {
598
- const C = (P) => {
598
+ const $ = (P) => {
599
599
  var I;
600
- P.key === "Escape" && w.current && (b(!1), (I = h.current) == null || I.focus());
600
+ P.key === "Escape" && y.current && (b(!1), (I = h.current) == null || I.focus());
601
601
  };
602
- return document.addEventListener("keydown", C), () => {
603
- document.removeEventListener("keydown", C);
602
+ return document.addEventListener("keydown", $), () => {
603
+ document.removeEventListener("keydown", $);
604
604
  };
605
- }, []), R(() => (document.addEventListener("mousedown", y), () => document.removeEventListener("mousedown", y)), [y]);
605
+ }, []), R(() => (document.addEventListener("mousedown", w), () => document.removeEventListener("mousedown", w)), [w]);
606
606
  const L = z(
607
607
  () => [
608
608
  "absolute z-50 bg-white rounded shadow-lg overflow-hidden w-auto",
609
- $ ? "bottom-full mb-2" : "top-full mt-2",
609
+ C ? "bottom-full mb-2" : "top-full mt-2",
610
610
  v,
611
611
  d,
612
612
  o && "transition-all duration-200 ease-out",
613
613
  u
614
614
  ].filter(Boolean).join(" "),
615
- [$, v, d, o, u]
615
+ [C, v, d, o, u]
616
616
  );
617
617
  return /* @__PURE__ */ k("div", { className: `relative inline-block ${p}`, ...x, children: [
618
618
  /* @__PURE__ */ i(
@@ -629,17 +629,17 @@ const Ve = ({
629
629
  ),
630
630
  g && /* @__PURE__ */ k("div", { ref: N, role: "menu", className: L, children: [
631
631
  n && n,
632
- t.map((C, P) => {
632
+ t.map(($, P) => {
633
633
  const I = () => {
634
- r && r(C), a && E();
634
+ r && r($), a && E();
635
635
  };
636
- return /* @__PURE__ */ i("div", { children: s ? s(C, I) : /* @__PURE__ */ i(
636
+ return /* @__PURE__ */ i("div", { children: s ? s($, I) : /* @__PURE__ */ i(
637
637
  "div",
638
638
  {
639
639
  onClick: I,
640
640
  className: "px-4 py-2 text-sm text-gray-800 hover:bg-gray-100 cursor-pointer",
641
641
  role: "menuitem",
642
- children: C.label
642
+ children: $.label
643
643
  }
644
644
  ) }, P);
645
645
  })
@@ -653,7 +653,7 @@ const Ve = ({
653
653
  tooltipClass: s = "",
654
654
  tooltipStyle: c = {}
655
655
  }) => {
656
- const p = K(null), u = K(null);
656
+ const p = _(null), u = _(null);
657
657
  R(() => {
658
658
  const a = p.current, o = u.current;
659
659
  if (!a || !o) return;
@@ -827,16 +827,16 @@ function nt({
827
827
  name: l,
828
828
  renderOption: f
829
829
  }) {
830
- const x = se[c] || se.rounded, g = oe[u] || oe.md, b = K(null), [$, S] = M({});
830
+ const x = se[c] || se.rounded, g = oe[u] || oe.md, b = _(null), [C, S] = M({});
831
831
  R(() => {
832
832
  if (!b.current) return;
833
- const h = e.findIndex((y) => y.value === n);
833
+ const h = e.findIndex((w) => w.value === n);
834
834
  if (h === -1) return;
835
835
  const m = b.current.querySelectorAll("button")[h];
836
836
  if (m) {
837
- const { offsetLeft: y, offsetWidth: D, offsetHeight: E } = m;
837
+ const { offsetLeft: w, offsetWidth: D, offsetHeight: E } = m;
838
838
  S({
839
- transform: `translateX(${y}px)`,
839
+ transform: `translateX(${w}px)`,
840
840
  width: D,
841
841
  height: E
842
842
  });
@@ -869,7 +869,7 @@ function nt({
869
869
  {
870
870
  className: `absolute top-0 left-0 transition-transform duration-300 ease-in-out ${x} ${N}`,
871
871
  style: {
872
- ...$,
872
+ ...C,
873
873
  zIndex: 0
874
874
  },
875
875
  "aria-hidden": "true"
@@ -885,8 +885,8 @@ function nt({
885
885
  "aria-checked": v,
886
886
  disabled: m,
887
887
  onClick: () => !m && t(h.value),
888
- onKeyDown: (y) => {
889
- (y.key === "Enter" || y.key === " ") && !m && (y.preventDefault(), t(h.value));
888
+ onKeyDown: (w) => {
889
+ (w.key === "Enter" || w.key === " ") && !m && (w.preventDefault(), t(h.value));
890
890
  },
891
891
  className: `
892
892
  relative z-10
@@ -937,7 +937,7 @@ const rt = ({
937
937
  role: "region",
938
938
  "aria-multiselectable": n,
939
939
  children: e.map((g) => {
940
- const b = f.has(g.id), $ = `accordion-heading-${g.id}`, S = `accordion-panel-${g.id}`;
940
+ const b = f.has(g.id), C = `accordion-heading-${g.id}`, S = `accordion-panel-${g.id}`;
941
941
  return /* @__PURE__ */ k(
942
942
  "div",
943
943
  {
@@ -946,7 +946,7 @@ const rt = ({
946
946
  /* @__PURE__ */ k(
947
947
  "button",
948
948
  {
949
- id: $,
949
+ id: C,
950
950
  type: "button",
951
951
  "aria-expanded": b,
952
952
  "aria-controls": S,
@@ -963,7 +963,7 @@ const rt = ({
963
963
  {
964
964
  id: S,
965
965
  role: "region",
966
- "aria-labelledby": $,
966
+ "aria-labelledby": C,
967
967
  hidden: !b,
968
968
  className: `p-4 border-t border-gray-200 dark:border-gray-700 text-gray-600 dark:text-gray-400 ${a}`,
969
969
  children: u ? u(g, b) : g.content
@@ -997,40 +997,42 @@ function st({
997
997
  disableEscapeClose: a = !1,
998
998
  closeBtnStyle: o
999
999
  }) {
1000
- const l = ge(), f = fe(), x = !r && !!l && !!f, [g, b] = M(!1), $ = x ? l.isOpen(e) : g, S = x ? l.getModalData(e) : null, N = A(() => {
1000
+ const l = ge(), f = fe(), x = !r && !!l && !!f, [g, b] = M(!1), C = x ? l.isOpen(e) : g, S = x ? l.getModalData(e) : null, N = A(() => {
1001
1001
  x ? f.closeModal(e) : b(!1), d == null || d();
1002
- }, [x, f, e, d]);
1002
+ }, [x, f, e, d]), h = _(null);
1003
1003
  return R(() => {
1004
- const h = document.activeElement, v = document.getElementById(e), m = [
1004
+ C && (h.current = document.activeElement);
1005
+ const v = document.getElementById(e), m = [
1005
1006
  "a[href]",
1006
1007
  "button:not([disabled])",
1007
1008
  "textarea:not([disabled])",
1008
1009
  "input:not([disabled])",
1009
1010
  "select:not([disabled])",
1010
1011
  '[tabindex]:not([tabindex="-1"])'
1011
- ], y = () => {
1012
+ ], w = () => {
1012
1013
  if (!v) return [];
1013
- const w = v.querySelectorAll(
1014
+ const y = v.querySelectorAll(
1014
1015
  m.join(",")
1015
1016
  );
1016
- return Array.from(w).filter((L) => L.offsetParent !== null);
1017
- }, D = (w) => {
1018
- if (w.key === "Tab") {
1019
- const L = y();
1017
+ return Array.from(y).filter((L) => L.offsetParent !== null);
1018
+ }, D = (y) => {
1019
+ if (y.key === "Tab") {
1020
+ const L = w();
1020
1021
  if (L.length === 0) return;
1021
- const C = L[0], P = L[L.length - 1];
1022
- w.shiftKey ? document.activeElement === C && (w.preventDefault(), P.focus()) : document.activeElement === P && (w.preventDefault(), C.focus());
1022
+ const $ = L[0], P = L[L.length - 1];
1023
+ y.shiftKey ? document.activeElement === $ && (y.preventDefault(), P.focus()) : document.activeElement === P && (y.preventDefault(), $.focus());
1023
1024
  }
1024
- }, E = (w) => {
1025
- w.key === "Escape" && !a && N(), D(w);
1025
+ }, E = (y) => {
1026
+ y.key === "Escape" && !a && N(), D(y);
1026
1027
  };
1027
- return $ && (document.body.style.overflow = "hidden", setTimeout(() => {
1028
- const w = y();
1029
- w.length && w[0].focus();
1028
+ return C && (document.body.style.overflow = "hidden", setTimeout(() => {
1029
+ const y = w();
1030
+ y.length && y[0].focus();
1030
1031
  }, 0), window.addEventListener("keydown", E)), () => {
1031
- document.body.style.overflow = "", h && h.focus(), window.removeEventListener("keydown", E);
1032
+ var y;
1033
+ document.body.style.overflow = "", (y = h.current) == null || y.focus(), window.removeEventListener("keydown", E);
1032
1034
  };
1033
- }, [$, a, N, e]), $ ? /* @__PURE__ */ i(
1035
+ }, [C, a, N, e]), C ? /* @__PURE__ */ i(
1034
1036
  "div",
1035
1037
  {
1036
1038
  className: "fixed inset-0 z-50 flex items-center justify-center bg-black/60 backdrop-blur-[2px]",
@@ -1131,8 +1133,8 @@ const Ue = () => "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, functio
1131
1133
  {
1132
1134
  className: `fixed top-5 right-5 z-9999 flex flex-col gap-2 ${e}`,
1133
1135
  children: n.map((s) => {
1134
- var a, o, l, f, x, g, b, $, S, N, h, v, m, y;
1135
- const c = ((a = s.config) == null ? void 0 : a.icon) || ((o = r.icons) == null ? void 0 : o[s.type]) || Xe(s.type), p = ((l = s.config) == null ? void 0 : l.bgColor) || ((x = (f = r.colors) == null ? void 0 : f[s.type]) == null ? void 0 : x.bg) || "bg-white dark:bg-gray-800", u = ((g = s.config) == null ? void 0 : g.textColor) || (($ = (b = r.colors) == null ? void 0 : b[s.type]) == null ? void 0 : $.text) || "text-gray-700 dark:text-gray-300", d = `w-8 h-8 mr-3 text-xl flex items-center justify-center ${(S = s.config) == null ? void 0 : S.iconContainerClass}`;
1136
+ var a, o, l, f, x, g, b, C, S, N, h, v, m, w;
1137
+ const c = ((a = s.config) == null ? void 0 : a.icon) || ((o = r.icons) == null ? void 0 : o[s.type]) || Xe(s.type), p = ((l = s.config) == null ? void 0 : l.bgColor) || ((x = (f = r.colors) == null ? void 0 : f[s.type]) == null ? void 0 : x.bg) || "bg-white dark:bg-gray-800", u = ((g = s.config) == null ? void 0 : g.textColor) || ((C = (b = r.colors) == null ? void 0 : b[s.type]) == null ? void 0 : C.text) || "text-gray-700 dark:text-gray-300", d = `w-8 h-8 mr-3 text-xl flex items-center justify-center ${(S = s.config) == null ? void 0 : S.iconContainerClass}`;
1136
1138
  return /* @__PURE__ */ k(
1137
1139
  "div",
1138
1140
  {
@@ -1150,7 +1152,7 @@ const Ue = () => "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, functio
1150
1152
  ((m = s.config) == null ? void 0 : m.description) && /* @__PURE__ */ i(
1151
1153
  "div",
1152
1154
  {
1153
- className: `text-sm text-gray-500 ${(y = s.config) == null ? void 0 : y.subTitleClass}`,
1155
+ className: `text-sm text-gray-500 ${(w = s.config) == null ? void 0 : w.subTitleClass}`,
1154
1156
  children: s.config.description
1155
1157
  }
1156
1158
  )
@@ -1,15 +1,15 @@
1
- (function(m,l){typeof exports=="object"&&typeof module<"u"?l(exports,require("react/jsx-runtime"),require("react")):typeof define=="function"&&define.amd?define(["exports","react/jsx-runtime","react"],l):(m=typeof globalThis<"u"?globalThis:m||self,l(m.TailwindUiKit={},m.jsxRuntime,m.React))})(this,(function(m,l,a){"use strict";"use client";var Q=document.createElement("style");Q.textContent=`@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style:solid;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000}}}.btn-primary{background-color:var(--color-blue-600,oklch(54.6% .245 262.881));color:var(--color-white,#fff)}@media(hover:hover){.btn-primary:hover{background-color:var(--color-blue-700,oklch(48.8% .243 264.376))}}.btn-outline-primary{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-blue-600,oklch(54.6% .245 262.881));color:var(--color-blue-600,oklch(54.6% .245 262.881))}@media(hover:hover){.btn-outline-primary:hover{background-color:var(--color-blue-50,oklch(97% .014 254.604))}}.btn-soft-primary{background-color:var(--color-blue-100,oklch(93.2% .032 255.585));color:var(--color-blue-700,oklch(48.8% .243 264.376))}@media(hover:hover){.btn-soft-primary:hover{background-color:var(--color-blue-200,oklch(88.2% .059 254.128))}}.btn-secondary{background-color:var(--color-gray-600,oklch(44.6% .03 256.802));color:var(--color-white,#fff)}@media(hover:hover){.btn-secondary:hover{background-color:var(--color-gray-700,oklch(37.3% .034 259.733))}}.btn-outline-secondary{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-gray-600,oklch(44.6% .03 256.802));color:var(--color-gray-600,oklch(44.6% .03 256.802))}@media(hover:hover){.btn-outline-secondary:hover{background-color:var(--color-gray-50,oklch(98.5% .002 247.839))}}.btn-soft-secondary{background-color:var(--color-gray-100,oklch(96.7% .003 264.542));color:var(--color-gray-700,oklch(37.3% .034 259.733))}@media(hover:hover){.btn-soft-secondary:hover{background-color:var(--color-gray-200,oklch(92.8% .006 264.531))}}.btn-success{background-color:var(--color-green-600,oklch(62.7% .194 149.214));color:var(--color-white,#fff)}@media(hover:hover){.btn-success:hover{background-color:var(--color-green-700,oklch(52.7% .154 150.069))}}.btn-outline-success{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-green-600,oklch(62.7% .194 149.214));color:var(--color-green-600,oklch(62.7% .194 149.214))}@media(hover:hover){.btn-outline-success:hover{background-color:var(--color-green-50,oklch(98.2% .018 155.826))}}.btn-soft-success{background-color:var(--color-green-100,oklch(96.2% .044 156.743));color:var(--color-green-700,oklch(52.7% .154 150.069))}@media(hover:hover){.btn-soft-success:hover{background-color:var(--color-green-200,oklch(92.5% .084 155.995))}}.btn-danger{background-color:var(--color-red-600,oklch(57.7% .245 27.325));color:var(--color-white,#fff)}@media(hover:hover){.btn-danger:hover{background-color:var(--color-red-700,oklch(50.5% .213 27.518))}}.btn-outline-danger{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-red-600,oklch(57.7% .245 27.325));color:var(--color-red-600,oklch(57.7% .245 27.325))}@media(hover:hover){.btn-outline-danger:hover{background-color:var(--color-red-50,oklch(97.1% .013 17.38))}}.btn-soft-danger{background-color:var(--color-red-100,oklch(93.6% .032 17.717));color:var(--color-red-700,oklch(50.5% .213 27.518))}@media(hover:hover){.btn-soft-danger:hover{background-color:var(--color-red-200,oklch(88.5% .062 18.334))}}.btn-warning{background-color:var(--color-yellow-500,oklch(79.5% .184 86.047));color:var(--color-white,#fff)}@media(hover:hover){.btn-warning:hover{background-color:var(--color-yellow-600,oklch(68.1% .162 75.834))}}.btn-outline-warning{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-yellow-500,oklch(79.5% .184 86.047));color:var(--color-yellow-600,oklch(68.1% .162 75.834))}@media(hover:hover){.btn-outline-warning:hover{background-color:var(--color-yellow-50,oklch(98.7% .026 102.212))}}.btn-soft-warning{background-color:var(--color-yellow-100,oklch(97.3% .071 103.193));color:var(--color-yellow-700,oklch(55.4% .135 66.442))}@media(hover:hover){.btn-soft-warning:hover{background-color:var(--color-yellow-200,oklch(94.5% .129 101.54))}}.btn-info{background-color:var(--color-cyan-600,oklch(60.9% .126 221.723));color:var(--color-white,#fff)}@media(hover:hover){.btn-info:hover{background-color:var(--color-cyan-700,oklch(52% .105 223.128))}}.btn-outline-info{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-cyan-600,oklch(60.9% .126 221.723));color:var(--color-cyan-600,oklch(60.9% .126 221.723))}@media(hover:hover){.btn-outline-info:hover{background-color:var(--color-cyan-50,oklch(98.4% .019 200.873))}}.btn-soft-info{background-color:var(--color-cyan-100,oklch(95.6% .045 203.388));color:var(--color-cyan-700,oklch(52% .105 223.128))}@media(hover:hover){.btn-soft-info:hover{background-color:var(--color-cyan-200,oklch(91.7% .08 205.041))}}.btn-dark{background-color:var(--color-gray-900,oklch(21% .034 264.665));color:var(--color-white,#fff)}@media(hover:hover){.btn-dark:hover{background-color:var(--color-black,#000)}}.btn-outline-dark{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-gray-900,oklch(21% .034 264.665));color:var(--color-gray-900,oklch(21% .034 264.665))}@media(hover:hover){.btn-outline-dark:hover{background-color:var(--color-gray-100,oklch(96.7% .003 264.542))}}.btn-soft-dark{background-color:var(--color-gray-200,oklch(92.8% .006 264.531));color:var(--color-gray-900,oklch(21% .034 264.665))}@media(hover:hover){.btn-soft-dark:hover{background-color:var(--color-gray-300,oklch(87.2% .01 258.338))}}.btn-light{background-color:var(--color-gray-100,oklch(96.7% .003 264.542));color:var(--color-gray-800,oklch(27.8% .033 256.848))}@media(hover:hover){.btn-light:hover{background-color:var(--color-gray-200,oklch(92.8% .006 264.531))}}.btn-outline-light{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-gray-100,oklch(96.7% .003 264.542));color:var(--color-gray-600,oklch(44.6% .03 256.802))}@media(hover:hover){.btn-outline-light:hover{background-color:var(--color-gray-50,oklch(98.5% .002 247.839))}}.btn-soft-light{background-color:var(--color-gray-50,oklch(98.5% .002 247.839));color:var(--color-gray-700,oklch(37.3% .034 259.733))}@media(hover:hover){.btn-soft-light:hover{background-color:var(--color-gray-100,oklch(96.7% .003 264.542))}}.btn-link{padding:calc(var(--spacing,.25rem)*0);color:var(--color-blue-600,oklch(54.6% .245 262.881));--tw-shadow:0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);background-color:#0000}@media(hover:hover){.btn-link:hover{text-decoration-line:underline}}@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style:solid;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000}}}.primary{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-blue-600,oklch(54.6% .245 262.881));background-color:var(--color-white,#fff)}.primary:is(:where(.peer):checked~*){border-color:var(--color-blue-600,oklch(54.6% .245 262.881));background-color:var(--color-blue-600,oklch(54.6% .245 262.881));color:var(--color-white,#fff)}@media(hover:hover){.primary:hover{background-color:var(--color-blue-300,oklch(80.9% .105 251.813))}.primary:is(:where(.peer):checked~*):hover{background-color:var(--color-blue-700,oklch(48.8% .243 264.376))}}.outline-primary{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-blue-600,oklch(54.6% .245 262.881));background-color:var(--color-white,#fff)}.outline-primary:is(:where(.peer):checked~*){color:var(--color-blue-600,oklch(54.6% .245 262.881))}@media(hover:hover){.outline-primary:hover{background-color:var(--color-blue-300,oklch(80.9% .105 251.813))}}.soft-primary{border-color:var(--color-blue-600,oklch(54.6% .245 262.881));background-color:var(--color-blue-200,oklch(88.2% .059 254.128));color:var(--color-blue-600,oklch(54.6% .245 262.881))}.soft-primary:is(:where(.peer):checked~*){border-color:var(--color-blue-600,oklch(54.6% .245 262.881));color:var(--color-blue-600,oklch(54.6% .245 262.881))}@media(hover:hover){.soft-primary:hover{background-color:var(--color-blue-300,oklch(80.9% .105 251.813))}}.secondary{background-color:var(--color-gray-600,oklch(44.6% .03 256.802));color:var(--color-white,#fff)}@media(hover:hover){.secondary:hover{background-color:var(--color-gray-700,oklch(37.3% .034 259.733))}}.outline-secondary{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-gray-600,oklch(44.6% .03 256.802));color:var(--color-gray-600,oklch(44.6% .03 256.802))}@media(hover:hover){.outline-secondary:hover{background-color:var(--color-gray-50,oklch(98.5% .002 247.839))}}.soft-secondary{background-color:var(--color-gray-100,oklch(96.7% .003 264.542));color:var(--color-gray-700,oklch(37.3% .034 259.733))}@media(hover:hover){.soft-secondary:hover{background-color:var(--color-gray-200,oklch(92.8% .006 264.531))}}.success{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-green-600,oklch(62.7% .194 149.214));background-color:var(--color-white,#fff)}.success:is(:where(.peer):checked~*){border-color:var(--color-green-600,oklch(62.7% .194 149.214));background-color:var(--color-green-600,oklch(62.7% .194 149.214));color:var(--color-white,#fff)}@media(hover:hover){.success:hover{background-color:var(--color-green-300,oklch(87.1% .15 154.449))}.success:is(:where(.peer):checked~*):hover{background-color:var(--color-green-700,oklch(52.7% .154 150.069))}}.outline-success{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-green-600,oklch(62.7% .194 149.214));background-color:var(--color-white,#fff)}.outline-success:is(:where(.peer):checked~*){color:var(--color-green-600,oklch(62.7% .194 149.214))}@media(hover:hover){.outline-success:hover{background-color:var(--color-green-300,oklch(87.1% .15 154.449))}}.soft-success{border-color:var(--color-green-600,oklch(62.7% .194 149.214));background-color:var(--color-green-200,oklch(92.5% .084 155.995));color:var(--color-green-600,oklch(62.7% .194 149.214))}.soft-success:is(:where(.peer):checked~*){border-color:var(--color-green-600,oklch(62.7% .194 149.214));color:var(--color-green-600,oklch(62.7% .194 149.214))}@media(hover:hover){.soft-success:hover{background-color:var(--color-red-300,oklch(80.8% .114 19.571))}}.danger{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-red-600,oklch(57.7% .245 27.325));background-color:var(--color-white,#fff)}.danger:is(:where(.peer):checked~*){border-color:var(--color-red-600,oklch(57.7% .245 27.325));background-color:var(--color-red-600,oklch(57.7% .245 27.325));color:var(--color-white,#fff)}@media(hover:hover){.danger:hover{background-color:var(--color-red-300,oklch(80.8% .114 19.571))}.danger:is(:where(.peer):checked~*):hover{background-color:var(--color-red-700,oklch(50.5% .213 27.518))}}.outline-danger{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-red-600,oklch(57.7% .245 27.325));background-color:var(--color-white,#fff)}.outline-danger:is(:where(.peer):checked~*){color:var(--color-red-600,oklch(57.7% .245 27.325))}@media(hover:hover){.outline-danger:hover{background-color:var(--color-red-300,oklch(80.8% .114 19.571))}}.soft-danger{border-color:var(--color-red-600,oklch(57.7% .245 27.325));background-color:var(--color-red-200,oklch(88.5% .062 18.334));color:var(--color-red-600,oklch(57.7% .245 27.325))}.soft-danger:is(:where(.peer):checked~*){border-color:var(--color-red-600,oklch(57.7% .245 27.325));color:var(--color-red-600,oklch(57.7% .245 27.325))}@media(hover:hover){.soft-danger:hover{background-color:var(--color-red-300,oklch(80.8% .114 19.571))}}.warning{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-yellow-600,oklch(68.1% .162 75.834));background-color:var(--color-white,#fff)}.warning:is(:where(.peer):checked~*){border-color:var(--color-yellow-600,oklch(68.1% .162 75.834));background-color:var(--color-yellow-600,oklch(68.1% .162 75.834));color:var(--color-white,#fff)}@media(hover:hover){.warning:hover{background-color:var(--color-yellow-300,oklch(90.5% .182 98.111))}.warning:is(:where(.peer):checked~*):hover{background-color:var(--color-yellow-700,oklch(55.4% .135 66.442))}}.outline-warning{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-yellow-600,oklch(68.1% .162 75.834));background-color:var(--color-white,#fff)}.outline-warning:is(:where(.peer):checked~*){color:var(--color-yellow-600,oklch(68.1% .162 75.834))}@media(hover:hover){.outline-warning:hover{background-color:var(--color-yellow-300,oklch(90.5% .182 98.111))}}.soft-warning{border-color:var(--color-yellow-600,oklch(68.1% .162 75.834));background-color:var(--color-yellow-200,oklch(94.5% .129 101.54));color:var(--color-yellow-600,oklch(68.1% .162 75.834))}.soft-warning:is(:where(.peer):checked~*){border-color:var(--color-yellow-600,oklch(68.1% .162 75.834));color:var(--color-yellow-600,oklch(68.1% .162 75.834))}@media(hover:hover){.soft-warning:hover{background-color:var(--color-yellow-300,oklch(90.5% .182 98.111))}}.info{background-color:var(--color-cyan-600,oklch(60.9% .126 221.723));color:var(--color-white,#fff)}@media(hover:hover){.info:hover{background-color:var(--color-cyan-700,oklch(52% .105 223.128))}}.outline-info{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-cyan-600,oklch(60.9% .126 221.723));color:var(--color-cyan-600,oklch(60.9% .126 221.723))}@media(hover:hover){.outline-info:hover{background-color:var(--color-cyan-50,oklch(98.4% .019 200.873))}}.soft-info{background-color:var(--color-cyan-100,oklch(95.6% .045 203.388));color:var(--color-cyan-700,oklch(52% .105 223.128))}@media(hover:hover){.soft-info:hover{background-color:var(--color-cyan-200,oklch(91.7% .08 205.041))}}.dark{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-gray-700,oklch(37.3% .034 259.733));background-color:var(--color-white,#fff)}.dark:is(:where(.peer):checked~*){border-color:var(--color-black,#000);background-color:var(--color-black,#000);color:var(--color-white,#fff)}@media(hover:hover){.dark:hover{background-color:#00000080}@supports (color:color-mix(in lab,red,red)){.dark:hover{background-color:color-mix(in oklab,var(--color-black,#000)50%,transparent)}}}.outline-dark{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-gray-900,oklch(21% .034 264.665));background-color:var(--color-white,#fff)}.outline-dark:is(:where(.peer):checked~*){color:var(--color-black,#000)}@media(hover:hover){.outline-dark:hover{background-color:var(--color-gray-100,oklch(96.7% .003 264.542))}}.soft-dark{border-color:var(--color-gray-600,oklch(44.6% .03 256.802));background-color:var(--color-gray-500,oklch(55.1% .027 264.364));color:var(--color-black,#000)}.soft-dark:is(:where(.peer):checked~*){border-color:var(--color-gray-900,oklch(21% .034 264.665));color:var(--color-black,#000)}@media(hover:hover){.soft-dark:hover{background-color:var(--color-gray-300,oklch(87.2% .01 258.338))}}.light{background-color:var(--color-gray-100,oklch(96.7% .003 264.542));color:var(--color-gray-800,oklch(27.8% .033 256.848))}@media(hover:hover){.light:hover{background-color:var(--color-gray-200,oklch(92.8% .006 264.531))}}.outline-light{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-gray-100,oklch(96.7% .003 264.542));color:var(--color-gray-600,oklch(44.6% .03 256.802))}@media(hover:hover){.outline-light:hover{background-color:var(--color-gray-50,oklch(98.5% .002 247.839))}}.soft-light{background-color:var(--color-gray-50,oklch(98.5% .002 247.839));color:var(--color-gray-700,oklch(37.3% .034 259.733))}@media(hover:hover){.soft-light:hover{background-color:var(--color-gray-100,oklch(96.7% .003 264.542))}}.link{padding:calc(var(--spacing,.25rem)*0);color:var(--color-blue-600,oklch(54.6% .245 262.881));--tw-shadow:0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);background-color:#0000}@media(hover:hover){.link:hover{text-decoration-line:underline}}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}/*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */.toggler-primary{background-color:var(--color-blue-600,oklch(54.6% .245 262.881))}@media(hover:hover){.toggler-primary:hover{background-color:var(--color-blue-700,oklch(48.8% .243 264.376))}}.toggler-secondary{background-color:var(--color-gray-600,oklch(44.6% .03 256.802))}@media(hover:hover){.toggler-secondary:hover{background-color:var(--color-gray-700,oklch(37.3% .034 259.733))}}.toggler-success{background-color:var(--color-green-600,oklch(62.7% .194 149.214))}@media(hover:hover){.toggler-success:hover{background-color:var(--color-green-700,oklch(52.7% .154 150.069))}}.toggler-danger{background-color:var(--color-red-600,oklch(57.7% .245 27.325))}@media(hover:hover){.toggler-danger:hover{background-color:var(--color-red-700,oklch(50.5% .213 27.518))}}.toggler-warning{background-color:var(--color-yellow-500,oklch(79.5% .184 86.047))}@media(hover:hover){.toggler-warning:hover{background-color:var(--color-yellow-600,oklch(68.1% .162 75.834))}}.toggler-info{background-color:var(--color-cyan-600,oklch(60.9% .126 221.723))}@media(hover:hover){.toggler-info:hover{background-color:var(--color-cyan-700,oklch(52% .105 223.128))}}.toggler-dark{background-color:var(--color-gray-900,oklch(21% .034 264.665))}@media(hover:hover){.toggler-dark:hover{background-color:var(--color-black,#000)}}.toggler-light{background-color:var(--color-gray-100,oklch(96.7% .003 264.542))}@media(hover:hover){.toggler-light:hover{background-color:var(--color-gray-200,oklch(92.8% .006 264.531))}}
2
- /*$vite$:1*/`,document.head.appendChild(Q);const V={xs:"text-xs px-2 py-1",sm:"text-sm px-3 py-1.5",md:"text-sm px-3 py-3",lg:"text-lg px-5 py-3"},R={flat:"rounded-none",rounded:"rounded-sm",pill:"rounded-full"},ur={filled:"rounded-t-lg px-2.5 pb-2.5 pt-5 bg-gray-50 border-b-2",outlined:"rounded-lg px-2.5 pb-2.5 pt-4 bg-transparent border",standard:"px-0 py-2.5 bg-transparent border-0 border-b-2"},hr={filled:"absolute duration-300 transform -translate-y-4 scale-75 top-4 z-10 origin-[0] start-2.5 peer-placeholder-shown:translate-y-0 peer-placeholder-shown:scale-100 peer-focus:scale-75 peer-focus:-translate-y-4 peer-focus:text-blue-600",outlined:"absolute duration-300 transform -translate-y-4 scale-75 top-2 z-10 origin-[0] bg-white px-2 peer-placeholder-shown:scale-100 peer-placeholder-shown:top-1/2 peer-placeholder-shown:-translate-y-1/2 peer-focus:top-2 peer-focus:scale-75 peer-focus:-translate-y-4 peer-focus:text-blue-600",standard:"absolute duration-300 transform -translate-y-6 scale-75 top-3 origin-[0] peer-placeholder-shown:scale-100 peer-placeholder-shown:translate-y-0 peer-focus:scale-75 peer-focus:-translate-y-6 peer-focus:text-blue-600"},gr=(r,e,o)=>{if(o)return"border-red-500 bg-red-50 text-red-900 placeholder-red-700 focus:ring-red-500 focus:border-red-500";if(e)return"border-green-500 bg-green-50 text-green-900 placeholder-green-700 focus:ring-green-500 focus:border-green-500";switch(r){case"error":return"border-red-500 bg-red-50 focus:ring-red-500";case"warning":return"border-yellow-500 bg-yellow-50 focus:ring-yellow-500";case"success":return"border-green-500 bg-green-50 focus:ring-green-500";default:return"border-gray-300 focus:ring-blue-500"}},rr=a.forwardRef((r,e)=>{const{label:o,id:t,inputSize:n="md",shape:d="rounded",validate:b,onValidatedChange:h,className:u="",icon:s,iconPosition:c="left",floatingLabelStyle:i,onChange:g,isValid:y,isInvalid:f,feedback:v,iconClasses:S,feedbackType:N="invalid",labelClasses:E="",inputType:k="",inputPattern:C,...p}=r,[w,j]=a.useState("default"),L=a.useCallback(D=>{const P=D.target.value,F=(b==null?void 0:b(P))??"default";j(F),h==null||h(D,F),g==null||g(D)},[b,h,g]),x=a.useMemo(()=>t||(typeof o=="string"?`input-${o.toLowerCase().replace(/\s+/g,"-")}`:`input-${Math.random().toString(36).slice(2)}`),[t,o]),O=!!i,$=V[n]||V.md,M=R[d]||R.flat,I=a.useMemo(()=>gr(w,y,f),[w,y,f]),T=a.useMemo(()=>c==="start"||c==="left"?"left-0 ps-3.5":"right-0 pe-3.5",[c]),z=a.useMemo(()=>s?c==="start"||c==="left"?"ps-10":"pe-10":"",[s,c]),A=D=>{var K;const P=D.key;!(D.ctrlKey||D.metaKey||P.length!==1||["Backspace","ArrowLeft","ArrowRight","Delete","Tab"].includes(P))&&(()=>{const Z=/^\d$/,J=/^[a-zA-Z]$/;switch(k){case"numeric":case"number":case"integer":return!Z.test(P);case"decimal":return!Z.test(P)&&P!=="."&&P!=="Backspace"&&P!=="Tab";case"alphabetic":return!J.test(P);case"custom":return C?!C.test(P):!1;default:return!1}})()&&D.preventDefault(),(K=p.onKeyDown)==null||K.call(p,D)},X=D=>{var Y;const P=D.clipboardData.getData("Text");(()=>{const K=/^\d+$/,Z=/^\d*\.?\d*$/,J=/^[a-zA-Z]+$/;switch(k){case"numeric":case"number":case"integer":return!K.test(P);case"decimal":return!Z.test(P);case"alphabetic":return!J.test(P);case"custom":return C?!C.test(P):!1;default:return!1}})()&&D.preventDefault(),(Y=p.onPaste)==null||Y.call(p,D)};return l.jsxs("div",{className:`w-full relative ${O?"z-0":""} tailwind-ux-input`,children:[!O&&o&&l.jsx("label",{htmlFor:x,className:`block mb-1 text-sm ${y?"text-green-700 dark:text-green-500":f?"text-red-700 dark:text-red-500":"text-gray-700"} ${E}`,children:o}),l.jsxs("div",{className:"relative w-full",children:[s&&l.jsx("div",{className:`absolute inset-y-0 flex items-center ${T} ${S}`,"aria-hidden":"true",children:s}),l.jsx("input",{...p,id:x,ref:e,placeholder:O?" ":p.placeholder,onChange:L,onKeyDown:A,onPaste:X,className:`border peer w-full block font-normal appearance-none focus:outline-none focus:ring-0 transition text-gray-900 placeholder-gray-600 border-gray-400
3
- ${$}
1
+ (function(x,l){typeof exports=="object"&&typeof module<"u"?l(exports,require("react/jsx-runtime"),require("react")):typeof define=="function"&&define.amd?define(["exports","react/jsx-runtime","react"],l):(x=typeof globalThis<"u"?globalThis:x||self,l(x.TailwindUiKit={},x.jsxRuntime,x.React))})(this,(function(x,l,a){"use strict";"use client";var Q=document.createElement("style");Q.textContent=`@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style:solid;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000}}}.btn-primary{background-color:var(--color-blue-600,oklch(54.6% .245 262.881));color:var(--color-white,#fff)}@media(hover:hover){.btn-primary:hover{background-color:var(--color-blue-700,oklch(48.8% .243 264.376))}}.btn-outline-primary{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-blue-600,oklch(54.6% .245 262.881));color:var(--color-blue-600,oklch(54.6% .245 262.881))}@media(hover:hover){.btn-outline-primary:hover{background-color:var(--color-blue-50,oklch(97% .014 254.604))}}.btn-soft-primary{background-color:var(--color-blue-100,oklch(93.2% .032 255.585));color:var(--color-blue-700,oklch(48.8% .243 264.376))}@media(hover:hover){.btn-soft-primary:hover{background-color:var(--color-blue-200,oklch(88.2% .059 254.128))}}.btn-secondary{background-color:var(--color-gray-600,oklch(44.6% .03 256.802));color:var(--color-white,#fff)}@media(hover:hover){.btn-secondary:hover{background-color:var(--color-gray-700,oklch(37.3% .034 259.733))}}.btn-outline-secondary{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-gray-600,oklch(44.6% .03 256.802));color:var(--color-gray-600,oklch(44.6% .03 256.802))}@media(hover:hover){.btn-outline-secondary:hover{background-color:var(--color-gray-50,oklch(98.5% .002 247.839))}}.btn-soft-secondary{background-color:var(--color-gray-100,oklch(96.7% .003 264.542));color:var(--color-gray-700,oklch(37.3% .034 259.733))}@media(hover:hover){.btn-soft-secondary:hover{background-color:var(--color-gray-200,oklch(92.8% .006 264.531))}}.btn-success{background-color:var(--color-green-600,oklch(62.7% .194 149.214));color:var(--color-white,#fff)}@media(hover:hover){.btn-success:hover{background-color:var(--color-green-700,oklch(52.7% .154 150.069))}}.btn-outline-success{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-green-600,oklch(62.7% .194 149.214));color:var(--color-green-600,oklch(62.7% .194 149.214))}@media(hover:hover){.btn-outline-success:hover{background-color:var(--color-green-50,oklch(98.2% .018 155.826))}}.btn-soft-success{background-color:var(--color-green-100,oklch(96.2% .044 156.743));color:var(--color-green-700,oklch(52.7% .154 150.069))}@media(hover:hover){.btn-soft-success:hover{background-color:var(--color-green-200,oklch(92.5% .084 155.995))}}.btn-danger{background-color:var(--color-red-600,oklch(57.7% .245 27.325));color:var(--color-white,#fff)}@media(hover:hover){.btn-danger:hover{background-color:var(--color-red-700,oklch(50.5% .213 27.518))}}.btn-outline-danger{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-red-600,oklch(57.7% .245 27.325));color:var(--color-red-600,oklch(57.7% .245 27.325))}@media(hover:hover){.btn-outline-danger:hover{background-color:var(--color-red-50,oklch(97.1% .013 17.38))}}.btn-soft-danger{background-color:var(--color-red-100,oklch(93.6% .032 17.717));color:var(--color-red-700,oklch(50.5% .213 27.518))}@media(hover:hover){.btn-soft-danger:hover{background-color:var(--color-red-200,oklch(88.5% .062 18.334))}}.btn-warning{background-color:var(--color-yellow-500,oklch(79.5% .184 86.047));color:var(--color-white,#fff)}@media(hover:hover){.btn-warning:hover{background-color:var(--color-yellow-600,oklch(68.1% .162 75.834))}}.btn-outline-warning{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-yellow-500,oklch(79.5% .184 86.047));color:var(--color-yellow-600,oklch(68.1% .162 75.834))}@media(hover:hover){.btn-outline-warning:hover{background-color:var(--color-yellow-50,oklch(98.7% .026 102.212))}}.btn-soft-warning{background-color:var(--color-yellow-100,oklch(97.3% .071 103.193));color:var(--color-yellow-700,oklch(55.4% .135 66.442))}@media(hover:hover){.btn-soft-warning:hover{background-color:var(--color-yellow-200,oklch(94.5% .129 101.54))}}.btn-info{background-color:var(--color-cyan-600,oklch(60.9% .126 221.723));color:var(--color-white,#fff)}@media(hover:hover){.btn-info:hover{background-color:var(--color-cyan-700,oklch(52% .105 223.128))}}.btn-outline-info{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-cyan-600,oklch(60.9% .126 221.723));color:var(--color-cyan-600,oklch(60.9% .126 221.723))}@media(hover:hover){.btn-outline-info:hover{background-color:var(--color-cyan-50,oklch(98.4% .019 200.873))}}.btn-soft-info{background-color:var(--color-cyan-100,oklch(95.6% .045 203.388));color:var(--color-cyan-700,oklch(52% .105 223.128))}@media(hover:hover){.btn-soft-info:hover{background-color:var(--color-cyan-200,oklch(91.7% .08 205.041))}}.btn-dark{background-color:var(--color-gray-900,oklch(21% .034 264.665));color:var(--color-white,#fff)}@media(hover:hover){.btn-dark:hover{background-color:var(--color-black,#000)}}.btn-outline-dark{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-gray-900,oklch(21% .034 264.665));color:var(--color-gray-900,oklch(21% .034 264.665))}@media(hover:hover){.btn-outline-dark:hover{background-color:var(--color-gray-100,oklch(96.7% .003 264.542))}}.btn-soft-dark{background-color:var(--color-gray-200,oklch(92.8% .006 264.531));color:var(--color-gray-900,oklch(21% .034 264.665))}@media(hover:hover){.btn-soft-dark:hover{background-color:var(--color-gray-300,oklch(87.2% .01 258.338))}}.btn-light{background-color:var(--color-gray-100,oklch(96.7% .003 264.542));color:var(--color-gray-800,oklch(27.8% .033 256.848))}@media(hover:hover){.btn-light:hover{background-color:var(--color-gray-200,oklch(92.8% .006 264.531))}}.btn-outline-light{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-gray-100,oklch(96.7% .003 264.542));color:var(--color-gray-600,oklch(44.6% .03 256.802))}@media(hover:hover){.btn-outline-light:hover{background-color:var(--color-gray-50,oklch(98.5% .002 247.839))}}.btn-soft-light{background-color:var(--color-gray-50,oklch(98.5% .002 247.839));color:var(--color-gray-700,oklch(37.3% .034 259.733))}@media(hover:hover){.btn-soft-light:hover{background-color:var(--color-gray-100,oklch(96.7% .003 264.542))}}.btn-link{padding:calc(var(--spacing,.25rem)*0);color:var(--color-blue-600,oklch(54.6% .245 262.881));--tw-shadow:0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);background-color:#0000}@media(hover:hover){.btn-link:hover{text-decoration-line:underline}}@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style:solid;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000}}}.primary{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-blue-600,oklch(54.6% .245 262.881));background-color:var(--color-white,#fff)}.primary:is(:where(.peer):checked~*){border-color:var(--color-blue-600,oklch(54.6% .245 262.881));background-color:var(--color-blue-600,oklch(54.6% .245 262.881));color:var(--color-white,#fff)}@media(hover:hover){.primary:hover{background-color:var(--color-blue-300,oklch(80.9% .105 251.813))}.primary:is(:where(.peer):checked~*):hover{background-color:var(--color-blue-700,oklch(48.8% .243 264.376))}}.outline-primary{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-blue-600,oklch(54.6% .245 262.881));background-color:var(--color-white,#fff)}.outline-primary:is(:where(.peer):checked~*){color:var(--color-blue-600,oklch(54.6% .245 262.881))}@media(hover:hover){.outline-primary:hover{background-color:var(--color-blue-300,oklch(80.9% .105 251.813))}}.soft-primary{border-color:var(--color-blue-600,oklch(54.6% .245 262.881));background-color:var(--color-blue-200,oklch(88.2% .059 254.128));color:var(--color-blue-600,oklch(54.6% .245 262.881))}.soft-primary:is(:where(.peer):checked~*){border-color:var(--color-blue-600,oklch(54.6% .245 262.881));color:var(--color-blue-600,oklch(54.6% .245 262.881))}@media(hover:hover){.soft-primary:hover{background-color:var(--color-blue-300,oklch(80.9% .105 251.813))}}.secondary{background-color:var(--color-gray-600,oklch(44.6% .03 256.802));color:var(--color-white,#fff)}@media(hover:hover){.secondary:hover{background-color:var(--color-gray-700,oklch(37.3% .034 259.733))}}.outline-secondary{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-gray-600,oklch(44.6% .03 256.802));color:var(--color-gray-600,oklch(44.6% .03 256.802))}@media(hover:hover){.outline-secondary:hover{background-color:var(--color-gray-50,oklch(98.5% .002 247.839))}}.soft-secondary{background-color:var(--color-gray-100,oklch(96.7% .003 264.542));color:var(--color-gray-700,oklch(37.3% .034 259.733))}@media(hover:hover){.soft-secondary:hover{background-color:var(--color-gray-200,oklch(92.8% .006 264.531))}}.success{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-green-600,oklch(62.7% .194 149.214));background-color:var(--color-white,#fff)}.success:is(:where(.peer):checked~*){border-color:var(--color-green-600,oklch(62.7% .194 149.214));background-color:var(--color-green-600,oklch(62.7% .194 149.214));color:var(--color-white,#fff)}@media(hover:hover){.success:hover{background-color:var(--color-green-300,oklch(87.1% .15 154.449))}.success:is(:where(.peer):checked~*):hover{background-color:var(--color-green-700,oklch(52.7% .154 150.069))}}.outline-success{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-green-600,oklch(62.7% .194 149.214));background-color:var(--color-white,#fff)}.outline-success:is(:where(.peer):checked~*){color:var(--color-green-600,oklch(62.7% .194 149.214))}@media(hover:hover){.outline-success:hover{background-color:var(--color-green-300,oklch(87.1% .15 154.449))}}.soft-success{border-color:var(--color-green-600,oklch(62.7% .194 149.214));background-color:var(--color-green-200,oklch(92.5% .084 155.995));color:var(--color-green-600,oklch(62.7% .194 149.214))}.soft-success:is(:where(.peer):checked~*){border-color:var(--color-green-600,oklch(62.7% .194 149.214));color:var(--color-green-600,oklch(62.7% .194 149.214))}@media(hover:hover){.soft-success:hover{background-color:var(--color-red-300,oklch(80.8% .114 19.571))}}.danger{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-red-600,oklch(57.7% .245 27.325));background-color:var(--color-white,#fff)}.danger:is(:where(.peer):checked~*){border-color:var(--color-red-600,oklch(57.7% .245 27.325));background-color:var(--color-red-600,oklch(57.7% .245 27.325));color:var(--color-white,#fff)}@media(hover:hover){.danger:hover{background-color:var(--color-red-300,oklch(80.8% .114 19.571))}.danger:is(:where(.peer):checked~*):hover{background-color:var(--color-red-700,oklch(50.5% .213 27.518))}}.outline-danger{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-red-600,oklch(57.7% .245 27.325));background-color:var(--color-white,#fff)}.outline-danger:is(:where(.peer):checked~*){color:var(--color-red-600,oklch(57.7% .245 27.325))}@media(hover:hover){.outline-danger:hover{background-color:var(--color-red-300,oklch(80.8% .114 19.571))}}.soft-danger{border-color:var(--color-red-600,oklch(57.7% .245 27.325));background-color:var(--color-red-200,oklch(88.5% .062 18.334));color:var(--color-red-600,oklch(57.7% .245 27.325))}.soft-danger:is(:where(.peer):checked~*){border-color:var(--color-red-600,oklch(57.7% .245 27.325));color:var(--color-red-600,oklch(57.7% .245 27.325))}@media(hover:hover){.soft-danger:hover{background-color:var(--color-red-300,oklch(80.8% .114 19.571))}}.warning{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-yellow-600,oklch(68.1% .162 75.834));background-color:var(--color-white,#fff)}.warning:is(:where(.peer):checked~*){border-color:var(--color-yellow-600,oklch(68.1% .162 75.834));background-color:var(--color-yellow-600,oklch(68.1% .162 75.834));color:var(--color-white,#fff)}@media(hover:hover){.warning:hover{background-color:var(--color-yellow-300,oklch(90.5% .182 98.111))}.warning:is(:where(.peer):checked~*):hover{background-color:var(--color-yellow-700,oklch(55.4% .135 66.442))}}.outline-warning{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-yellow-600,oklch(68.1% .162 75.834));background-color:var(--color-white,#fff)}.outline-warning:is(:where(.peer):checked~*){color:var(--color-yellow-600,oklch(68.1% .162 75.834))}@media(hover:hover){.outline-warning:hover{background-color:var(--color-yellow-300,oklch(90.5% .182 98.111))}}.soft-warning{border-color:var(--color-yellow-600,oklch(68.1% .162 75.834));background-color:var(--color-yellow-200,oklch(94.5% .129 101.54));color:var(--color-yellow-600,oklch(68.1% .162 75.834))}.soft-warning:is(:where(.peer):checked~*){border-color:var(--color-yellow-600,oklch(68.1% .162 75.834));color:var(--color-yellow-600,oklch(68.1% .162 75.834))}@media(hover:hover){.soft-warning:hover{background-color:var(--color-yellow-300,oklch(90.5% .182 98.111))}}.info{background-color:var(--color-cyan-600,oklch(60.9% .126 221.723));color:var(--color-white,#fff)}@media(hover:hover){.info:hover{background-color:var(--color-cyan-700,oklch(52% .105 223.128))}}.outline-info{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-cyan-600,oklch(60.9% .126 221.723));color:var(--color-cyan-600,oklch(60.9% .126 221.723))}@media(hover:hover){.outline-info:hover{background-color:var(--color-cyan-50,oklch(98.4% .019 200.873))}}.soft-info{background-color:var(--color-cyan-100,oklch(95.6% .045 203.388));color:var(--color-cyan-700,oklch(52% .105 223.128))}@media(hover:hover){.soft-info:hover{background-color:var(--color-cyan-200,oklch(91.7% .08 205.041))}}.dark{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-gray-700,oklch(37.3% .034 259.733));background-color:var(--color-white,#fff)}.dark:is(:where(.peer):checked~*){border-color:var(--color-black,#000);background-color:var(--color-black,#000);color:var(--color-white,#fff)}@media(hover:hover){.dark:hover{background-color:#00000080}@supports (color:color-mix(in lab,red,red)){.dark:hover{background-color:color-mix(in oklab,var(--color-black,#000)50%,transparent)}}}.outline-dark{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-gray-900,oklch(21% .034 264.665));background-color:var(--color-white,#fff)}.outline-dark:is(:where(.peer):checked~*){color:var(--color-black,#000)}@media(hover:hover){.outline-dark:hover{background-color:var(--color-gray-100,oklch(96.7% .003 264.542))}}.soft-dark{border-color:var(--color-gray-600,oklch(44.6% .03 256.802));background-color:var(--color-gray-500,oklch(55.1% .027 264.364));color:var(--color-black,#000)}.soft-dark:is(:where(.peer):checked~*){border-color:var(--color-gray-900,oklch(21% .034 264.665));color:var(--color-black,#000)}@media(hover:hover){.soft-dark:hover{background-color:var(--color-gray-300,oklch(87.2% .01 258.338))}}.light{background-color:var(--color-gray-100,oklch(96.7% .003 264.542));color:var(--color-gray-800,oklch(27.8% .033 256.848))}@media(hover:hover){.light:hover{background-color:var(--color-gray-200,oklch(92.8% .006 264.531))}}.outline-light{border-style:var(--tw-border-style);border-width:1px;border-color:var(--color-gray-100,oklch(96.7% .003 264.542));color:var(--color-gray-600,oklch(44.6% .03 256.802))}@media(hover:hover){.outline-light:hover{background-color:var(--color-gray-50,oklch(98.5% .002 247.839))}}.soft-light{background-color:var(--color-gray-50,oklch(98.5% .002 247.839));color:var(--color-gray-700,oklch(37.3% .034 259.733))}@media(hover:hover){.soft-light:hover{background-color:var(--color-gray-100,oklch(96.7% .003 264.542))}}.link{padding:calc(var(--spacing,.25rem)*0);color:var(--color-blue-600,oklch(54.6% .245 262.881));--tw-shadow:0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);background-color:#0000}@media(hover:hover){.link:hover{text-decoration-line:underline}}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}/*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */.toggler-primary{background-color:var(--color-blue-600,oklch(54.6% .245 262.881))}@media(hover:hover){.toggler-primary:hover{background-color:var(--color-blue-700,oklch(48.8% .243 264.376))}}.toggler-secondary{background-color:var(--color-gray-600,oklch(44.6% .03 256.802))}@media(hover:hover){.toggler-secondary:hover{background-color:var(--color-gray-700,oklch(37.3% .034 259.733))}}.toggler-success{background-color:var(--color-green-600,oklch(62.7% .194 149.214))}@media(hover:hover){.toggler-success:hover{background-color:var(--color-green-700,oklch(52.7% .154 150.069))}}.toggler-danger{background-color:var(--color-red-600,oklch(57.7% .245 27.325))}@media(hover:hover){.toggler-danger:hover{background-color:var(--color-red-700,oklch(50.5% .213 27.518))}}.toggler-warning{background-color:var(--color-yellow-500,oklch(79.5% .184 86.047))}@media(hover:hover){.toggler-warning:hover{background-color:var(--color-yellow-600,oklch(68.1% .162 75.834))}}.toggler-info{background-color:var(--color-cyan-600,oklch(60.9% .126 221.723))}@media(hover:hover){.toggler-info:hover{background-color:var(--color-cyan-700,oklch(52% .105 223.128))}}.toggler-dark{background-color:var(--color-gray-900,oklch(21% .034 264.665))}@media(hover:hover){.toggler-dark:hover{background-color:var(--color-black,#000)}}.toggler-light{background-color:var(--color-gray-100,oklch(96.7% .003 264.542))}@media(hover:hover){.toggler-light:hover{background-color:var(--color-gray-200,oklch(92.8% .006 264.531))}}
2
+ /*$vite$:1*/`,document.head.appendChild(Q);const V={xs:"text-xs px-2 py-1",sm:"text-sm px-3 py-1.5",md:"text-sm px-3 py-3",lg:"text-lg px-5 py-3"},R={flat:"rounded-none",rounded:"rounded-sm",pill:"rounded-full"},ur={filled:"rounded-t-lg px-2.5 pb-2.5 pt-5 bg-gray-50 border-b-2",outlined:"rounded-lg px-2.5 pb-2.5 pt-4 bg-transparent border",standard:"px-0 py-2.5 bg-transparent border-0 border-b-2"},hr={filled:"absolute duration-300 transform -translate-y-4 scale-75 top-4 z-10 origin-[0] start-2.5 peer-placeholder-shown:translate-y-0 peer-placeholder-shown:scale-100 peer-focus:scale-75 peer-focus:-translate-y-4 peer-focus:text-blue-600",outlined:"absolute duration-300 transform -translate-y-4 scale-75 top-2 z-10 origin-[0] bg-white px-2 peer-placeholder-shown:scale-100 peer-placeholder-shown:top-1/2 peer-placeholder-shown:-translate-y-1/2 peer-focus:top-2 peer-focus:scale-75 peer-focus:-translate-y-4 peer-focus:text-blue-600",standard:"absolute duration-300 transform -translate-y-6 scale-75 top-3 origin-[0] peer-placeholder-shown:scale-100 peer-placeholder-shown:translate-y-0 peer-focus:scale-75 peer-focus:-translate-y-6 peer-focus:text-blue-600"},gr=(r,e,o)=>{if(o)return"border-red-500 bg-red-50 text-red-900 placeholder-red-700 focus:ring-red-500 focus:border-red-500";if(e)return"border-green-500 bg-green-50 text-green-900 placeholder-green-700 focus:ring-green-500 focus:border-green-500";switch(r){case"error":return"border-red-500 bg-red-50 focus:ring-red-500";case"warning":return"border-yellow-500 bg-yellow-50 focus:ring-yellow-500";case"success":return"border-green-500 bg-green-50 focus:ring-green-500";default:return"border-gray-300 focus:ring-blue-500"}},rr=a.forwardRef((r,e)=>{const{label:o,id:t,inputSize:n="md",shape:d="rounded",validate:b,onValidatedChange:h,className:u="",icon:s,iconPosition:c="left",floatingLabelStyle:i,onChange:g,isValid:y,isInvalid:f,feedback:v,iconClasses:$,feedbackType:N="invalid",labelClasses:E="",inputType:k="",inputPattern:C,...p}=r,[m,j]=a.useState("default"),L=a.useCallback(D=>{const P=D.target.value,F=(b==null?void 0:b(P))??"default";j(F),h==null||h(D,F),g==null||g(D)},[b,h,g]),w=a.useMemo(()=>t||(typeof o=="string"?`input-${o.toLowerCase().replace(/\s+/g,"-")}`:`input-${Math.random().toString(36).slice(2)}`),[t,o]),O=!!i,S=V[n]||V.md,M=R[d]||R.flat,I=a.useMemo(()=>gr(m,y,f),[m,y,f]),T=a.useMemo(()=>c==="start"||c==="left"?"left-0 ps-3.5":"right-0 pe-3.5",[c]),z=a.useMemo(()=>s?c==="start"||c==="left"?"ps-10":"pe-10":"",[s,c]),A=D=>{var K;const P=D.key;!(D.ctrlKey||D.metaKey||P.length!==1||["Backspace","ArrowLeft","ArrowRight","Delete","Tab"].includes(P))&&(()=>{const Z=/^\d$/,J=/^[a-zA-Z]$/;switch(k){case"numeric":case"number":case"integer":return!Z.test(P);case"decimal":return!Z.test(P)&&P!=="."&&P!=="Backspace"&&P!=="Tab";case"alphabetic":return!J.test(P);case"custom":return C?!C.test(P):!1;default:return!1}})()&&D.preventDefault(),(K=p.onKeyDown)==null||K.call(p,D)},X=D=>{var Y;const P=D.clipboardData.getData("Text");(()=>{const K=/^\d+$/,Z=/^\d*\.?\d*$/,J=/^[a-zA-Z]+$/;switch(k){case"numeric":case"number":case"integer":return!K.test(P);case"decimal":return!Z.test(P);case"alphabetic":return!J.test(P);case"custom":return C?!C.test(P):!1;default:return!1}})()&&D.preventDefault(),(Y=p.onPaste)==null||Y.call(p,D)};return l.jsxs("div",{className:`w-full relative ${O?"z-0":""} tailwind-ux-input`,children:[!O&&o&&l.jsx("label",{htmlFor:w,className:`block mb-1 text-sm ${y?"text-green-700 dark:text-green-500":f?"text-red-700 dark:text-red-500":"text-gray-700"} ${E}`,children:o}),l.jsxs("div",{className:"relative w-full",children:[s&&l.jsx("div",{className:`absolute inset-y-0 flex items-center ${T} ${$}`,"aria-hidden":"true",children:s}),l.jsx("input",{...p,id:w,ref:e,placeholder:O?" ":p.placeholder,onChange:L,onKeyDown:A,onPaste:X,className:`border peer w-full block font-normal appearance-none focus:outline-none focus:ring-0 transition text-gray-900 placeholder-gray-600 border-gray-400
3
+ ${S}
4
4
  ${O&&i&&ur[i]}
5
- ${z} ${M} ${I} ${u}`}),O&&o&&i&&l.jsx("label",{htmlFor:x,className:`ms-1 ${hr[i]} ${u}`,children:o})]}),v&&l.jsx("p",{className:`mt-1 text-xs ${N==="invalid"?"text-red-600 dark:text-red-500":"text-green-600 dark:text-green-500"}`,role:N==="invalid"?"alert":void 0,children:v})]})});rr.displayName="Input";const br={xs:"text-xs px-2 py-1",sm:"text-sm px-3 py-1.5",md:"text-sm px-3 py-3",lg:"text-lg px-5 py-3"},fr={flat:"rounded-none",rounded:"rounded-sm",pill:"rounded-full"},vr={filled:"rounded-t-lg px-2.5 pb-2.5 pt-5 bg-gray-50 border-b-2",outlined:"rounded-lg px-2.5 pb-2.5 pt-4 bg-transparent border",standard:"px-0 py-2.5 bg-transparent border-0 border-b-2"},pr={filled:"absolute duration-300 transform -translate-y-4 scale-75 top-4 z-10 origin-[0] start-2.5 peer-placeholder-shown:translate-y-0 peer-placeholder-shown:scale-100 peer-focus:scale-75 peer-focus:-translate-y-4 peer-focus:text-blue-600",outlined:"absolute duration-300 transform -translate-y-4 scale-75 top-2 z-10 origin-[0] bg-white px-2 peer-placeholder-shown:scale-100 peer-placeholder-shown:top-1/2 peer-placeholder-shown:-translate-y-1/2 peer-focus:top-2 peer-focus:scale-75 peer-focus:-translate-y-4 peer-focus:text-blue-600",standard:"absolute duration-300 transform -translate-y-6 scale-75 top-3 origin-[0] peer-placeholder-shown:scale-100 peer-placeholder-shown:translate-y-0 peer-focus:scale-75 peer-focus:-translate-y-6 peer-focus:text-blue-600"},yr=(r,e,o)=>{if(o)return"border-red-500 bg-red-50 text-red-900 focus:ring-red-500 focus:border-red-500";if(e)return"border-green-500 bg-green-50 text-green-900 focus:ring-green-500 focus:border-green-500";const t="focus:ring focus:border";switch(r){case"error":return`${t}-red-500 border-red-500 bg-red-50`;case"warning":return`${t}-yellow-500 border-yellow-500 bg-yellow-50`;case"success":return`${t}-green-500 border-green-500 bg-green-50`;default:return"border-gray-300 focus:ring-blue-500"}},or=a.forwardRef((r,e)=>{const{label:o,id:t,inputSize:n="md",shape:d="rounded",validate:b,onValidatedChange:h,className:u="",icon:s,iconPosition:c="left",floatingLabelStyle:i,onChange:g,isValid:y,isInvalid:f,feedback:v,feedbackType:S="invalid",children:N,...E}=r,[k,C]=a.useState("default"),p=a.useId(),w=a.useMemo(()=>t||(typeof o=="string"?`select-${o.toLowerCase().replace(/\s+/g,"-")}`:p),[t,o,p]),j=T=>{const z=T.target.value,A=(b==null?void 0:b(z))??"default";C(A),h==null||h(T,A),g==null||g(T)},L=!!i,x=br[n],O=fr[d],$=yr(k,y,f),M=s&&(c==="start"||c==="left")?"ps-10":s?"pe-10":"",I=c==="start"||c==="left"?"left-0 ps-3.5":"right-0 pe-3.5";return l.jsxs("div",{className:`w-full relative ${L?"z-0":""}`,children:[!L&&o&&l.jsx("label",{htmlFor:w,className:`block mb-1 text-sm ${y?"text-green-700":f?"text-red-700":"text-gray-700"}`,children:o}),l.jsxs("div",{className:"relative w-full",children:[s&&l.jsx("div",{className:`absolute inset-y-0 flex items-center ${I}`,children:l.jsx("span",{className:"text-gray-500",children:s})}),l.jsx("select",{...E,id:w,ref:e,onChange:j,className:`border peer w-full block font-normal appearance-none focus:outline-none focus:ring-0 transition text-gray-600 placeholder-[#798ba5] border-gray-400
6
- ${x} ${M}
5
+ ${z} ${M} ${I} ${u}`}),O&&o&&i&&l.jsx("label",{htmlFor:w,className:`ms-1 ${hr[i]} ${u}`,children:o})]}),v&&l.jsx("p",{className:`mt-1 text-xs ${N==="invalid"?"text-red-600 dark:text-red-500":"text-green-600 dark:text-green-500"}`,role:N==="invalid"?"alert":void 0,children:v})]})});rr.displayName="Input";const br={xs:"text-xs px-2 py-1",sm:"text-sm px-3 py-1.5",md:"text-sm px-3 py-3",lg:"text-lg px-5 py-3"},fr={flat:"rounded-none",rounded:"rounded-sm",pill:"rounded-full"},vr={filled:"rounded-t-lg px-2.5 pb-2.5 pt-5 bg-gray-50 border-b-2",outlined:"rounded-lg px-2.5 pb-2.5 pt-4 bg-transparent border",standard:"px-0 py-2.5 bg-transparent border-0 border-b-2"},pr={filled:"absolute duration-300 transform -translate-y-4 scale-75 top-4 z-10 origin-[0] start-2.5 peer-placeholder-shown:translate-y-0 peer-placeholder-shown:scale-100 peer-focus:scale-75 peer-focus:-translate-y-4 peer-focus:text-blue-600",outlined:"absolute duration-300 transform -translate-y-4 scale-75 top-2 z-10 origin-[0] bg-white px-2 peer-placeholder-shown:scale-100 peer-placeholder-shown:top-1/2 peer-placeholder-shown:-translate-y-1/2 peer-focus:top-2 peer-focus:scale-75 peer-focus:-translate-y-4 peer-focus:text-blue-600",standard:"absolute duration-300 transform -translate-y-6 scale-75 top-3 origin-[0] peer-placeholder-shown:scale-100 peer-placeholder-shown:translate-y-0 peer-focus:scale-75 peer-focus:-translate-y-6 peer-focus:text-blue-600"},yr=(r,e,o)=>{if(o)return"border-red-500 bg-red-50 text-red-900 focus:ring-red-500 focus:border-red-500";if(e)return"border-green-500 bg-green-50 text-green-900 focus:ring-green-500 focus:border-green-500";const t="focus:ring focus:border";switch(r){case"error":return`${t}-red-500 border-red-500 bg-red-50`;case"warning":return`${t}-yellow-500 border-yellow-500 bg-yellow-50`;case"success":return`${t}-green-500 border-green-500 bg-green-50`;default:return"border-gray-300 focus:ring-blue-500"}},or=a.forwardRef((r,e)=>{const{label:o,id:t,inputSize:n="md",shape:d="rounded",validate:b,onValidatedChange:h,className:u="",icon:s,iconPosition:c="left",floatingLabelStyle:i,onChange:g,isValid:y,isInvalid:f,feedback:v,feedbackType:$="invalid",children:N,...E}=r,[k,C]=a.useState("default"),p=a.useId(),m=a.useMemo(()=>t||(typeof o=="string"?`select-${o.toLowerCase().replace(/\s+/g,"-")}`:p),[t,o,p]),j=T=>{const z=T.target.value,A=(b==null?void 0:b(z))??"default";C(A),h==null||h(T,A),g==null||g(T)},L=!!i,w=br[n],O=fr[d],S=yr(k,y,f),M=s&&(c==="start"||c==="left")?"ps-10":s?"pe-10":"",I=c==="start"||c==="left"?"left-0 ps-3.5":"right-0 pe-3.5";return l.jsxs("div",{className:`w-full relative ${L?"z-0":""}`,children:[!L&&o&&l.jsx("label",{htmlFor:m,className:`block mb-1 text-sm ${y?"text-green-700":f?"text-red-700":"text-gray-700"}`,children:o}),l.jsxs("div",{className:"relative w-full",children:[s&&l.jsx("div",{className:`absolute inset-y-0 flex items-center ${I}`,children:l.jsx("span",{className:"text-gray-500",children:s})}),l.jsx("select",{...E,id:m,ref:e,onChange:j,className:`border peer w-full block font-normal appearance-none focus:outline-none focus:ring-0 transition text-gray-600 placeholder-[#798ba5] border-gray-400
6
+ ${w} ${M}
7
7
  ${L&&i&&vr[i]}
8
- ${O} ${$} ${u}`,children:N}),L&&o&&i&&l.jsx("label",{htmlFor:w,className:`ms-1 ${pr[i]} ${u}`,children:o})]}),v&&l.jsx("p",{className:`mt-1 text-xs ${S==="invalid"?"text-red-600":"text-green-600"}`,children:v})]})});or.displayName="Select";const kr={primary:"btn-primary",secondary:"btn-secondary",success:"btn-success",danger:"btn-danger",warning:"btn-warning",info:"btn-info",dark:"btn-dark",light:"btn-light",link:"btn-link","outline-primary":"btn-outline-primary","outline-secondary":"btn-outline-secondary","outline-success":"btn-outline-success","outline-danger":"btn-outline-danger","outline-warning":"btn-outline-warning","outline-info":"btn-outline-info","outline-dark":"btn-outline-dark","outline-light":"btn-outline-light","soft-primary":"btn-soft-primary","soft-secondary":"btn-soft-secondary","soft-success":"btn-soft-success","soft-danger":"btn-soft-danger","soft-warning":"btn-soft-warning","soft-info":"btn-soft-info","soft-dark":"btn-soft-dark","soft-light":"btn-soft-light"},wr={xs:"px-3 py-2 text-xs",sm:"px-3 py-2 text-sm",md:"px-5 py-2.5 text-sm",lg:"px-5 py-3 text-base",xl:"px-6 py-3.5 text-base"},mr={flat:"shadow-none",rounded:"rounded-sm",pill:"rounded-full",circle:"rounded-full w-10 h-10 p-0 flex items-center justify-center"},xr=({children:r,variant:e="primary",size:o="md",type:t="button",shape:n="rounded",className:d="",isLoading:b=!1,disabled:h=!1,...u})=>{const s=h||b,c=["inline-flex items-center justify-center font-normal transition duration-150",kr[e],wr[o],mr[n],n==="flat"?"shadow-none":"shadow-sm",s?"opacity-50 cursor-not-allowed":"cursor-pointer",d].filter(Boolean).join(" ");return l.jsxs("button",{type:t,className:c,disabled:s,...u,children:[b&&l.jsxs("svg",{"aria-hidden":"true",role:"status",className:"inline w-4 h-4 me-3 text-gray-200 animate-spin dark:text-gray-600",viewBox:"0 0 100 101",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[l.jsx("path",{d:"M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z",fill:"currentColor"}),l.jsx("path",{d:"M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z",fill:"#1C64F2"})]}),r]})};var er={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},tr=a.createContext&&a.createContext(er),Cr=["attr","size","title"];function $r(r,e){if(r==null)return{};var o=Sr(r,e),t,n;if(Object.getOwnPropertySymbols){var d=Object.getOwnPropertySymbols(r);for(n=0;n<d.length;n++)t=d[n],!(e.indexOf(t)>=0)&&Object.prototype.propertyIsEnumerable.call(r,t)&&(o[t]=r[t])}return o}function Sr(r,e){if(r==null)return{};var o={};for(var t in r)if(Object.prototype.hasOwnProperty.call(r,t)){if(e.indexOf(t)>=0)continue;o[t]=r[t]}return o}function _(){return _=Object.assign?Object.assign.bind():function(r){for(var e=1;e<arguments.length;e++){var o=arguments[e];for(var t in o)Object.prototype.hasOwnProperty.call(o,t)&&(r[t]=o[t])}return r},_.apply(this,arguments)}function lr(r,e){var o=Object.keys(r);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(r);e&&(t=t.filter(function(n){return Object.getOwnPropertyDescriptor(r,n).enumerable})),o.push.apply(o,t)}return o}function B(r){for(var e=1;e<arguments.length;e++){var o=arguments[e]!=null?arguments[e]:{};e%2?lr(Object(o),!0).forEach(function(t){Nr(r,t,o[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(o)):lr(Object(o)).forEach(function(t){Object.defineProperty(r,t,Object.getOwnPropertyDescriptor(o,t))})}return r}function Nr(r,e,o){return e=Er(e),e in r?Object.defineProperty(r,e,{value:o,enumerable:!0,configurable:!0,writable:!0}):r[e]=o,r}function Er(r){var e=Lr(r,"string");return typeof e=="symbol"?e:e+""}function Lr(r,e){if(typeof r!="object"||!r)return r;var o=r[Symbol.toPrimitive];if(o!==void 0){var t=o.call(r,e);if(typeof t!="object")return t;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}function nr(r){return r&&r.map((e,o)=>a.createElement(e.tag,B({key:o},e.attr),nr(e.child)))}function H(r){return e=>a.createElement(Or,_({attr:B({},r.attr)},e),nr(r.child))}function Or(r){var e=o=>{var{attr:t,size:n,title:d}=r,b=$r(r,Cr),h=n||o.size||"1em",u;return o.className&&(u=o.className),r.className&&(u=(u?u+" ":"")+r.className),a.createElement("svg",_({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},o.attr,t,b,{className:u,style:B(B({color:r.color||o.color},o.style),r.style),height:h,width:h,xmlns:"http://www.w3.org/2000/svg"}),d&&a.createElement("title",null,d),r.children)};return tr!==void 0?a.createElement(tr.Consumer,null,o=>e(o)):e(er)}function Mr(r){return H({attr:{viewBox:"0 0 448 512"},child:[{tag:"path",attr:{d:"M438.6 105.4c12.5 12.5 12.5 32.8 0 45.3l-256 256c-12.5 12.5-32.8 12.5-45.3 0l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0L160 338.7 393.4 105.4c12.5-12.5 32.8-12.5 45.3 0z"},child:[]}]})(r)}const Pr={xs:"w-3 h-3 text-[10px]",sm:"w-4 h-4 text-xs",md:"w-5 h-5 text-sm",lg:"w-6 h-6 text-base"},Ir={flat:"rounded-none",rounded:"rounded-sm",pill:"rounded-full"},jr={primary:"primary",secondary:"secondary",success:"success",danger:"danger",warning:"warning",info:"info",dark:"dark",light:"light",link:"link","outline-primary":"outline-primary","outline-secondary":"outline-secondary","outline-success":"outline-success","outline-danger":"outline-danger","outline-warning":"outline-warning","outline-info":"outline-info","outline-dark":"outline-dark","outline-light":"outline-light","soft-primary":"soft-primary","soft-secondary":"soft-secondary","soft-success":"soft-success","soft-danger":"soft-danger","soft-warning":"soft-warning","soft-info":"soft-info","soft-dark":"soft-dark","soft-light":"soft-light"},ar=a.forwardRef(({label:r,boxSize:e="md",shape:o="rounded",variant:t="success",onSelectionChange:n,disabled:d=!1,className:b="",id:h,value:u,icon:s,children:c,checked:i,...g},y)=>{const f=x=>{!d&&n&&n(x.target.checked),g.onChange&&g.onChange(x)},v="mr-2 border flex items-center justify-center transition-all",S=Pr[e],N=Ir[o],E=jr[t]??"",k=t.startsWith("outline"),C=t.startsWith("soft"),j=`${v} ${S} ${N} ${E} ${i&&(k||C||t==="link")?"peer-checked:bg-current peer-checked:text-white":i?"peer-checked:bg-current":""}`,L={xs:"w-2 h-2",sm:"w-2.5 h-2.5",md:"w-3 h-3",lg:"w-3.5 h-3.5"};return l.jsxs("label",{className:`flex items-center ${d?"opacity-50 cursor-not-allowed":"cursor-pointer"} me-4 ${b}`,children:[l.jsx("input",{type:"checkbox",className:"peer hidden",checked:i,onChange:f,disabled:d,id:h,value:u,ref:y,...g}),l.jsx("span",{className:j.trim(),children:(i||g.defaultChecked)&&(s??l.jsx(Mr,{className:`${L[e]}`}))}),r||c?l.jsx("span",{className:"text-sm font-medium text-gray-900 dark:text-gray-300",children:r??c}):null]})});ar.displayName="Checkbox";const Dr=({label:r,header:e,items:o=[],onSelect:t,renderItem:n,position:d="right",className:b="",menuClassName:h="",width:u="w-48",closeOnSelect:s=!1,transition:c=!0,ariaLabel:i="Dropdown menu",forceCloseDropdown:g,...y})=>{const[f,v]=a.useState(!1),[S,N]=a.useState(!1),E=a.useRef(null),k=a.useRef(null),C=a.useMemo(()=>({left:"left-0",center:"left-1/2 transform -translate-x-1/2",right:"right-0"})[d],[d]),p=a.useCallback(()=>{const $=k.current,M=E.current;if(!$||!M)return;const{top:I,bottom:T}=$.getBoundingClientRect(),z=M.offsetHeight,A=window.innerHeight-T,X=I;N(A<z&&X>z)},[]),w=a.useCallback($=>{var M,I;!((M=E.current)!=null&&M.contains($.target))&&!((I=k.current)!=null&&I.contains($.target))&&v(!1)},[]),j=a.useCallback(()=>v($=>!$),[]),L=a.useCallback(()=>v(!1),[]);a.useEffect(()=>{if(f)return p(),window.addEventListener("resize",p),window.addEventListener("scroll",p,!0),()=>{window.removeEventListener("resize",p),window.removeEventListener("scroll",p,!0)}},[f,p]);const x=a.useRef(f);a.useEffect(()=>{x.current=f},[f]),a.useEffect(()=>{const $=M=>{var I;M.key==="Escape"&&x.current&&(v(!1),(I=k.current)==null||I.focus())};return document.addEventListener("keydown",$),()=>{document.removeEventListener("keydown",$)}},[]),a.useEffect(()=>(document.addEventListener("mousedown",w),()=>document.removeEventListener("mousedown",w)),[w]);const O=a.useMemo(()=>["absolute z-50 bg-white rounded shadow-lg overflow-hidden w-auto",S?"bottom-full mb-2":"top-full mt-2",C,u,c&&"transition-all duration-200 ease-out",h].filter(Boolean).join(" "),[S,C,u,c,h]);return l.jsxs("div",{className:`relative inline-block ${b}`,...y,children:[l.jsx("button",{type:"button",ref:k,onClick:j,"aria-expanded":f,"aria-label":i,className:"focus:outline-none",children:r}),f&&l.jsxs("div",{ref:E,role:"menu",className:O,children:[e&&e,o.map(($,M)=>{const I=()=>{t&&t($),s&&L()};return l.jsx("div",{children:n?n($,I):l.jsx("div",{onClick:I,className:"px-4 py-2 text-sm text-gray-800 hover:bg-gray-100 cursor-pointer",role:"menuitem",children:$.label})},M)})]})]})},Tr=({children:r,content:e,position:o="top",className:t="",tooltipClass:n="",tooltipStyle:d={}})=>{const b=a.useRef(null),h=a.useRef(null);a.useEffect(()=>{const s=b.current,c=h.current;if(!s||!c)return;const i=()=>{c.style.opacity="1",c.style.visibility="visible"},g=()=>{c.style.opacity="0",c.style.visibility="hidden"};return s.addEventListener("mouseenter",i),s.addEventListener("mouseleave",g),()=>{s.removeEventListener("mouseenter",i),s.removeEventListener("mouseleave",g)}},[]);const u=s=>{const c={position:"absolute",opacity:0,visibility:"hidden",transition:"opacity 0.2s ease",maxWidth:"240px",whiteSpace:"normal",wordBreak:"break-word",padding:"8px 12px",fontSize:"0.875rem",backgroundColor:"black",color:"white",borderRadius:"4px",boxShadow:"0px 4px 12px rgba(0, 0, 0, 0.15)",zIndex:9999,width:"max-content"};switch(s){case"top":return{...c,bottom:"100%",left:"50%",transform:"translateX(-50%)",marginBottom:"8px"};case"bottom":return{...c,top:"100%",left:"50%",transform:"translateX(-50%)",marginTop:"8px"};case"left":return{...c,right:"100%",top:"50%",transform:"translateY(-50%)",marginRight:"8px"};case"right":return{...c,left:"100%",top:"50%",transform:"translateY(-50%)",marginLeft:"8px"};default:return c}};return l.jsxs("div",{ref:b,className:`relative inline-block ${t}`,children:[r,l.jsx("div",{ref:h,role:"tooltip",className:n,style:{...u(o),...d},children:e})]})},zr={primary:"bg-blue-500 text-white",secondary:"bg-gray-500 text-white",success:"bg-green-500 text-white",danger:"bg-red-500 text-white",warning:"bg-yellow-400 text-black",info:"bg-cyan-500 text-white",dark:"bg-black text-white",light:"bg-gray-100 text-gray-800",link:"bg-transparent text-blue-500 underline","outline-primary":"border border-blue-500 text-blue-500 bg-transparent","outline-secondary":"border border-gray-500 text-gray-500 bg-transparent","outline-success":"border border-green-500 text-green-500 bg-transparent","outline-danger":"border border-red-500 text-red-500 bg-transparent","outline-warning":"border border-yellow-400 text-yellow-500 bg-transparent","outline-info":"border border-cyan-500 text-cyan-500 bg-transparent","outline-dark":"border border-black text-black bg-transparent","outline-light":"border border-gray-100 text-gray-800 bg-transparent"},Ar={xs:"text-xs px-2 py-0.5",sm:"text-sm px-2.5 py-0.5",md:"text-base px-3 py-1",lg:"text-lg px-3.5 py-1.5",xl:"text-xl px-4 py-2"},_r={flat:"rounded-none",rounded:"rounded-sm",pill:"rounded-full",circle:"rounded-full p-2 w-8 h-8 justify-center"},Br=({label:r,variant:e="primary",size:o="sm",shape:t="rounded",icon:n,dismissible:d,onDismiss:b,className:h="",...u})=>{const s=!r&&!!n,c=`inline-flex items-center font-medium ${zr[e]||""} ${Ar[o]||""} ${_r[t]||""} ${s?"justify-center p-2 w-8 h-8":""} `+h;return l.jsxs("span",{className:c.trim(),...u,children:[n&&l.jsx("span",{className:r?"mr-1":"",children:n}),r,d&&l.jsx("button",{type:"button",onClick:b,className:"ml-2 text-xs font-bold leading-none focus:outline-none",children:"×"})]})},cr={rounded:"rounded-md",pill:"rounded-full",flat:"rounded-none"},sr={xs:{button:"px-2 py-1 text-xs"},sm:{button:"px-3 py-1.5 text-sm"},md:{button:"px-4 py-2 text-sm"},lg:{button:"px-5 py-3 text-base"},xl:{button:"px-6 py-4 text-lg"}};function Fr({options:r,selected:e,onChange:o,label:t,disabled:n=!1,shape:d="rounded",variant:b="primary",size:h="md",className:u="",classNames:s={},id:c,name:i,renderOption:g}){const y=cr[d]||cr.rounded,f=sr[h]||sr.md,v=a.useRef(null),[S,N]=a.useState({});a.useEffect(()=>{if(!v.current)return;const k=r.findIndex(w=>w.value===e);if(k===-1)return;const p=v.current.querySelectorAll("button")[k];if(p){const{offsetLeft:w,offsetWidth:j,offsetHeight:L}=p;N({transform:`translateX(${w}px)`,width:j,height:L})}},[e,r,h]);const E=`toggler-${b}`;return l.jsxs("div",{className:`flex flex-col gap-2 w-fit ${u} ${s.root??""}`,id:c,children:[t&&l.jsx("span",{className:`text-sm font-medium select-none ${s.label??""}`,children:t}),l.jsxs("div",{ref:v,role:"radiogroup","aria-disabled":n,className:`relative inline-flex overflow-hidden border border-gray-300 bg-gray-100 ${y} ${n?"opacity-50 cursor-not-allowed":""} ${s.group??""}`,children:[l.jsx("div",{className:`absolute top-0 left-0 transition-transform duration-300 ease-in-out ${y} ${E}`,style:{...S,zIndex:0},"aria-hidden":"true"}),r.map(k=>{const C=e===k.value,p=n||k.disabled;return l.jsx("button",{role:"radio",name:i,"aria-checked":C,disabled:p,onClick:()=>!p&&o(k.value),onKeyDown:w=>{(w.key==="Enter"||w.key===" ")&&!p&&(w.preventDefault(),o(k.value))},className:`
8
+ ${O} ${S} ${u}`,children:N}),L&&o&&i&&l.jsx("label",{htmlFor:m,className:`ms-1 ${pr[i]} ${u}`,children:o})]}),v&&l.jsx("p",{className:`mt-1 text-xs ${$==="invalid"?"text-red-600":"text-green-600"}`,children:v})]})});or.displayName="Select";const kr={primary:"btn-primary",secondary:"btn-secondary",success:"btn-success",danger:"btn-danger",warning:"btn-warning",info:"btn-info",dark:"btn-dark",light:"btn-light",link:"btn-link","outline-primary":"btn-outline-primary","outline-secondary":"btn-outline-secondary","outline-success":"btn-outline-success","outline-danger":"btn-outline-danger","outline-warning":"btn-outline-warning","outline-info":"btn-outline-info","outline-dark":"btn-outline-dark","outline-light":"btn-outline-light","soft-primary":"btn-soft-primary","soft-secondary":"btn-soft-secondary","soft-success":"btn-soft-success","soft-danger":"btn-soft-danger","soft-warning":"btn-soft-warning","soft-info":"btn-soft-info","soft-dark":"btn-soft-dark","soft-light":"btn-soft-light"},wr={xs:"px-3 py-2 text-xs",sm:"px-3 py-2 text-sm",md:"px-5 py-2.5 text-sm",lg:"px-5 py-3 text-base",xl:"px-6 py-3.5 text-base"},mr={flat:"shadow-none",rounded:"rounded-sm",pill:"rounded-full",circle:"rounded-full w-10 h-10 p-0 flex items-center justify-center"},xr=({children:r,variant:e="primary",size:o="md",type:t="button",shape:n="rounded",className:d="",isLoading:b=!1,disabled:h=!1,...u})=>{const s=h||b,c=["inline-flex items-center justify-center font-normal transition duration-150",kr[e],wr[o],mr[n],n==="flat"?"shadow-none":"shadow-sm",s?"opacity-50 cursor-not-allowed":"cursor-pointer",d].filter(Boolean).join(" ");return l.jsxs("button",{type:t,className:c,disabled:s,...u,children:[b&&l.jsxs("svg",{"aria-hidden":"true",role:"status",className:"inline w-4 h-4 me-3 text-gray-200 animate-spin dark:text-gray-600",viewBox:"0 0 100 101",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[l.jsx("path",{d:"M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z",fill:"currentColor"}),l.jsx("path",{d:"M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z",fill:"#1C64F2"})]}),r]})};var er={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},tr=a.createContext&&a.createContext(er),Cr=["attr","size","title"];function $r(r,e){if(r==null)return{};var o=Sr(r,e),t,n;if(Object.getOwnPropertySymbols){var d=Object.getOwnPropertySymbols(r);for(n=0;n<d.length;n++)t=d[n],!(e.indexOf(t)>=0)&&Object.prototype.propertyIsEnumerable.call(r,t)&&(o[t]=r[t])}return o}function Sr(r,e){if(r==null)return{};var o={};for(var t in r)if(Object.prototype.hasOwnProperty.call(r,t)){if(e.indexOf(t)>=0)continue;o[t]=r[t]}return o}function _(){return _=Object.assign?Object.assign.bind():function(r){for(var e=1;e<arguments.length;e++){var o=arguments[e];for(var t in o)Object.prototype.hasOwnProperty.call(o,t)&&(r[t]=o[t])}return r},_.apply(this,arguments)}function lr(r,e){var o=Object.keys(r);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(r);e&&(t=t.filter(function(n){return Object.getOwnPropertyDescriptor(r,n).enumerable})),o.push.apply(o,t)}return o}function B(r){for(var e=1;e<arguments.length;e++){var o=arguments[e]!=null?arguments[e]:{};e%2?lr(Object(o),!0).forEach(function(t){Nr(r,t,o[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(o)):lr(Object(o)).forEach(function(t){Object.defineProperty(r,t,Object.getOwnPropertyDescriptor(o,t))})}return r}function Nr(r,e,o){return e=Er(e),e in r?Object.defineProperty(r,e,{value:o,enumerable:!0,configurable:!0,writable:!0}):r[e]=o,r}function Er(r){var e=Lr(r,"string");return typeof e=="symbol"?e:e+""}function Lr(r,e){if(typeof r!="object"||!r)return r;var o=r[Symbol.toPrimitive];if(o!==void 0){var t=o.call(r,e);if(typeof t!="object")return t;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}function nr(r){return r&&r.map((e,o)=>a.createElement(e.tag,B({key:o},e.attr),nr(e.child)))}function H(r){return e=>a.createElement(Or,_({attr:B({},r.attr)},e),nr(r.child))}function Or(r){var e=o=>{var{attr:t,size:n,title:d}=r,b=$r(r,Cr),h=n||o.size||"1em",u;return o.className&&(u=o.className),r.className&&(u=(u?u+" ":"")+r.className),a.createElement("svg",_({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},o.attr,t,b,{className:u,style:B(B({color:r.color||o.color},o.style),r.style),height:h,width:h,xmlns:"http://www.w3.org/2000/svg"}),d&&a.createElement("title",null,d),r.children)};return tr!==void 0?a.createElement(tr.Consumer,null,o=>e(o)):e(er)}function Mr(r){return H({attr:{viewBox:"0 0 448 512"},child:[{tag:"path",attr:{d:"M438.6 105.4c12.5 12.5 12.5 32.8 0 45.3l-256 256c-12.5 12.5-32.8 12.5-45.3 0l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0L160 338.7 393.4 105.4c12.5-12.5 32.8-12.5 45.3 0z"},child:[]}]})(r)}const Pr={xs:"w-3 h-3 text-[10px]",sm:"w-4 h-4 text-xs",md:"w-5 h-5 text-sm",lg:"w-6 h-6 text-base"},Ir={flat:"rounded-none",rounded:"rounded-sm",pill:"rounded-full"},jr={primary:"primary",secondary:"secondary",success:"success",danger:"danger",warning:"warning",info:"info",dark:"dark",light:"light",link:"link","outline-primary":"outline-primary","outline-secondary":"outline-secondary","outline-success":"outline-success","outline-danger":"outline-danger","outline-warning":"outline-warning","outline-info":"outline-info","outline-dark":"outline-dark","outline-light":"outline-light","soft-primary":"soft-primary","soft-secondary":"soft-secondary","soft-success":"soft-success","soft-danger":"soft-danger","soft-warning":"soft-warning","soft-info":"soft-info","soft-dark":"soft-dark","soft-light":"soft-light"},ar=a.forwardRef(({label:r,boxSize:e="md",shape:o="rounded",variant:t="success",onSelectionChange:n,disabled:d=!1,className:b="",id:h,value:u,icon:s,children:c,checked:i,...g},y)=>{const f=w=>{!d&&n&&n(w.target.checked),g.onChange&&g.onChange(w)},v="mr-2 border flex items-center justify-center transition-all",$=Pr[e],N=Ir[o],E=jr[t]??"",k=t.startsWith("outline"),C=t.startsWith("soft"),j=`${v} ${$} ${N} ${E} ${i&&(k||C||t==="link")?"peer-checked:bg-current peer-checked:text-white":i?"peer-checked:bg-current":""}`,L={xs:"w-2 h-2",sm:"w-2.5 h-2.5",md:"w-3 h-3",lg:"w-3.5 h-3.5"};return l.jsxs("label",{className:`flex items-center ${d?"opacity-50 cursor-not-allowed":"cursor-pointer"} me-4 ${b}`,children:[l.jsx("input",{type:"checkbox",className:"peer hidden",checked:i,onChange:f,disabled:d,id:h,value:u,ref:y,...g}),l.jsx("span",{className:j.trim(),children:(i||g.defaultChecked)&&(s??l.jsx(Mr,{className:`${L[e]}`}))}),r||c?l.jsx("span",{className:"text-sm font-medium text-gray-900 dark:text-gray-300",children:r??c}):null]})});ar.displayName="Checkbox";const Dr=({label:r,header:e,items:o=[],onSelect:t,renderItem:n,position:d="right",className:b="",menuClassName:h="",width:u="w-48",closeOnSelect:s=!1,transition:c=!0,ariaLabel:i="Dropdown menu",forceCloseDropdown:g,...y})=>{const[f,v]=a.useState(!1),[$,N]=a.useState(!1),E=a.useRef(null),k=a.useRef(null),C=a.useMemo(()=>({left:"left-0",center:"left-1/2 transform -translate-x-1/2",right:"right-0"})[d],[d]),p=a.useCallback(()=>{const S=k.current,M=E.current;if(!S||!M)return;const{top:I,bottom:T}=S.getBoundingClientRect(),z=M.offsetHeight,A=window.innerHeight-T,X=I;N(A<z&&X>z)},[]),m=a.useCallback(S=>{var M,I;!((M=E.current)!=null&&M.contains(S.target))&&!((I=k.current)!=null&&I.contains(S.target))&&v(!1)},[]),j=a.useCallback(()=>v(S=>!S),[]),L=a.useCallback(()=>v(!1),[]);a.useEffect(()=>{if(f)return p(),window.addEventListener("resize",p),window.addEventListener("scroll",p,!0),()=>{window.removeEventListener("resize",p),window.removeEventListener("scroll",p,!0)}},[f,p]);const w=a.useRef(f);a.useEffect(()=>{w.current=f},[f]),a.useEffect(()=>{const S=M=>{var I;M.key==="Escape"&&w.current&&(v(!1),(I=k.current)==null||I.focus())};return document.addEventListener("keydown",S),()=>{document.removeEventListener("keydown",S)}},[]),a.useEffect(()=>(document.addEventListener("mousedown",m),()=>document.removeEventListener("mousedown",m)),[m]);const O=a.useMemo(()=>["absolute z-50 bg-white rounded shadow-lg overflow-hidden w-auto",$?"bottom-full mb-2":"top-full mt-2",C,u,c&&"transition-all duration-200 ease-out",h].filter(Boolean).join(" "),[$,C,u,c,h]);return l.jsxs("div",{className:`relative inline-block ${b}`,...y,children:[l.jsx("button",{type:"button",ref:k,onClick:j,"aria-expanded":f,"aria-label":i,className:"focus:outline-none",children:r}),f&&l.jsxs("div",{ref:E,role:"menu",className:O,children:[e&&e,o.map((S,M)=>{const I=()=>{t&&t(S),s&&L()};return l.jsx("div",{children:n?n(S,I):l.jsx("div",{onClick:I,className:"px-4 py-2 text-sm text-gray-800 hover:bg-gray-100 cursor-pointer",role:"menuitem",children:S.label})},M)})]})]})},Tr=({children:r,content:e,position:o="top",className:t="",tooltipClass:n="",tooltipStyle:d={}})=>{const b=a.useRef(null),h=a.useRef(null);a.useEffect(()=>{const s=b.current,c=h.current;if(!s||!c)return;const i=()=>{c.style.opacity="1",c.style.visibility="visible"},g=()=>{c.style.opacity="0",c.style.visibility="hidden"};return s.addEventListener("mouseenter",i),s.addEventListener("mouseleave",g),()=>{s.removeEventListener("mouseenter",i),s.removeEventListener("mouseleave",g)}},[]);const u=s=>{const c={position:"absolute",opacity:0,visibility:"hidden",transition:"opacity 0.2s ease",maxWidth:"240px",whiteSpace:"normal",wordBreak:"break-word",padding:"8px 12px",fontSize:"0.875rem",backgroundColor:"black",color:"white",borderRadius:"4px",boxShadow:"0px 4px 12px rgba(0, 0, 0, 0.15)",zIndex:9999,width:"max-content"};switch(s){case"top":return{...c,bottom:"100%",left:"50%",transform:"translateX(-50%)",marginBottom:"8px"};case"bottom":return{...c,top:"100%",left:"50%",transform:"translateX(-50%)",marginTop:"8px"};case"left":return{...c,right:"100%",top:"50%",transform:"translateY(-50%)",marginRight:"8px"};case"right":return{...c,left:"100%",top:"50%",transform:"translateY(-50%)",marginLeft:"8px"};default:return c}};return l.jsxs("div",{ref:b,className:`relative inline-block ${t}`,children:[r,l.jsx("div",{ref:h,role:"tooltip",className:n,style:{...u(o),...d},children:e})]})},zr={primary:"bg-blue-500 text-white",secondary:"bg-gray-500 text-white",success:"bg-green-500 text-white",danger:"bg-red-500 text-white",warning:"bg-yellow-400 text-black",info:"bg-cyan-500 text-white",dark:"bg-black text-white",light:"bg-gray-100 text-gray-800",link:"bg-transparent text-blue-500 underline","outline-primary":"border border-blue-500 text-blue-500 bg-transparent","outline-secondary":"border border-gray-500 text-gray-500 bg-transparent","outline-success":"border border-green-500 text-green-500 bg-transparent","outline-danger":"border border-red-500 text-red-500 bg-transparent","outline-warning":"border border-yellow-400 text-yellow-500 bg-transparent","outline-info":"border border-cyan-500 text-cyan-500 bg-transparent","outline-dark":"border border-black text-black bg-transparent","outline-light":"border border-gray-100 text-gray-800 bg-transparent"},Ar={xs:"text-xs px-2 py-0.5",sm:"text-sm px-2.5 py-0.5",md:"text-base px-3 py-1",lg:"text-lg px-3.5 py-1.5",xl:"text-xl px-4 py-2"},_r={flat:"rounded-none",rounded:"rounded-sm",pill:"rounded-full",circle:"rounded-full p-2 w-8 h-8 justify-center"},Br=({label:r,variant:e="primary",size:o="sm",shape:t="rounded",icon:n,dismissible:d,onDismiss:b,className:h="",...u})=>{const s=!r&&!!n,c=`inline-flex items-center font-medium ${zr[e]||""} ${Ar[o]||""} ${_r[t]||""} ${s?"justify-center p-2 w-8 h-8":""} `+h;return l.jsxs("span",{className:c.trim(),...u,children:[n&&l.jsx("span",{className:r?"mr-1":"",children:n}),r,d&&l.jsx("button",{type:"button",onClick:b,className:"ml-2 text-xs font-bold leading-none focus:outline-none",children:"×"})]})},cr={rounded:"rounded-md",pill:"rounded-full",flat:"rounded-none"},sr={xs:{button:"px-2 py-1 text-xs"},sm:{button:"px-3 py-1.5 text-sm"},md:{button:"px-4 py-2 text-sm"},lg:{button:"px-5 py-3 text-base"},xl:{button:"px-6 py-4 text-lg"}};function Fr({options:r,selected:e,onChange:o,label:t,disabled:n=!1,shape:d="rounded",variant:b="primary",size:h="md",className:u="",classNames:s={},id:c,name:i,renderOption:g}){const y=cr[d]||cr.rounded,f=sr[h]||sr.md,v=a.useRef(null),[$,N]=a.useState({});a.useEffect(()=>{if(!v.current)return;const k=r.findIndex(m=>m.value===e);if(k===-1)return;const p=v.current.querySelectorAll("button")[k];if(p){const{offsetLeft:m,offsetWidth:j,offsetHeight:L}=p;N({transform:`translateX(${m}px)`,width:j,height:L})}},[e,r,h]);const E=`toggler-${b}`;return l.jsxs("div",{className:`flex flex-col gap-2 w-fit ${u} ${s.root??""}`,id:c,children:[t&&l.jsx("span",{className:`text-sm font-medium select-none ${s.label??""}`,children:t}),l.jsxs("div",{ref:v,role:"radiogroup","aria-disabled":n,className:`relative inline-flex overflow-hidden border border-gray-300 bg-gray-100 ${y} ${n?"opacity-50 cursor-not-allowed":""} ${s.group??""}`,children:[l.jsx("div",{className:`absolute top-0 left-0 transition-transform duration-300 ease-in-out ${y} ${E}`,style:{...$,zIndex:0},"aria-hidden":"true"}),r.map(k=>{const C=e===k.value,p=n||k.disabled;return l.jsx("button",{role:"radio",name:i,"aria-checked":C,disabled:p,onClick:()=>!p&&o(k.value),onKeyDown:m=>{(m.key==="Enter"||m.key===" ")&&!p&&(m.preventDefault(),o(k.value))},className:`
9
9
  relative z-10
10
10
  transition-colors duration-200 focus:outline-none
11
11
  ${f.button}
12
12
  ${C?`text-white toggler-text-${b}`:"text-gray-700 hover:bg-gray-200"}
13
13
  ${s.option??""}
14
14
  ${C?s.selectedOption??"":""}
15
- `,children:g?g(k,C):k.label},String(k.value))})]})]})}function Kr(r){return H({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M256 294.1L383 167c9.4-9.4 24.6-9.4 33.9 0s9.3 24.6 0 34L273 345c-9.1 9.1-23.7 9.3-33.1.7L95 201.1c-4.7-4.7-7-10.9-7-17s2.3-12.3 7-17c9.4-9.4 24.6-9.4 33.9 0l127.1 127z"},child:[]}]})(r)}const Zr=({items:r,allowMultipleOpen:e=!1,className:o="",tileClasses:t="",open:n,onChange:d,renderTitle:b,renderContent:h,showArrowIcon:u=!0,panelClasses:s=""})=>{const[c,i]=a.useState(new Set),g=a.useMemo(()=>n?new Set(n):c,[n,c]),y=a.useCallback(f=>{const v=new Set(g);v.has(f)?v.delete(f):(e||v.clear(),v.add(f)),n&&d?d(Array.from(v)):i(v)},[g,n,d,e]);return l.jsx("div",{className:"accordion",role:"region","aria-multiselectable":e,children:r.map(f=>{const v=g.has(f.id),S=`accordion-heading-${f.id}`,N=`accordion-panel-${f.id}`;return l.jsxs("div",{className:`accordion-item border rounded border-gray-300 dark:border-gray-700 ${o}`,children:[l.jsxs("button",{id:S,type:"button","aria-expanded":v,"aria-controls":N,onClick:()=>y(f.id),className:`flex justify-between items-center w-full p-1.5 text-left text-gray-700 dark:text-gray-300 hover:bg-gray-100 dark:hover:bg-gray-800 focus:outline-none gap-3 ${t}`,children:[b?b(f,v):f.title,u?l.jsx(Kr,{}):null]}),l.jsx("div",{id:N,role:"region","aria-labelledby":S,hidden:!v,className:`p-4 border-t border-gray-200 dark:border-gray-700 text-gray-600 dark:text-gray-400 ${s}`,children:h?h(f,v):f.content})]},f.id)})})},ir=a.createContext(null),W=()=>{const r=a.useContext(ir);if(!r)throw new Error("useModalActions must be used within a ModalActionProvider");return r},dr=a.createContext(null),q=()=>a.useContext(dr);function Hr({id:r,title:e,children:o,standalone:t=!1,showFloatingClose:n=!1,containerClasses:d="",headerClasses:b="",bodyClasses:h="",onClose:u,disableEscapeClose:s=!1,closeBtnStyle:c}){const i=q(),g=W(),y=!t&&!!i&&!!g,[f,v]=a.useState(!1),S=y?i.isOpen(r):f,N=y?i.getModalData(r):null,E=a.useCallback(()=>{y?g.closeModal(r):v(!1),u==null||u()},[y,g,r,u]);return a.useEffect(()=>{const k=document.activeElement,C=document.getElementById(r),p=["a[href]","button:not([disabled])","textarea:not([disabled])","input:not([disabled])","select:not([disabled])",'[tabindex]:not([tabindex="-1"])'],w=()=>{if(!C)return[];const x=C.querySelectorAll(p.join(","));return Array.from(x).filter(O=>O.offsetParent!==null)},j=x=>{if(x.key==="Tab"){const O=w();if(O.length===0)return;const $=O[0],M=O[O.length-1];x.shiftKey?document.activeElement===$&&(x.preventDefault(),M.focus()):document.activeElement===M&&(x.preventDefault(),$.focus())}},L=x=>{x.key==="Escape"&&!s&&E(),j(x)};return S&&(document.body.style.overflow="hidden",setTimeout(()=>{const x=w();x.length&&x[0].focus()},0),window.addEventListener("keydown",L)),()=>{document.body.style.overflow="",k&&k.focus(),window.removeEventListener("keydown",L)}},[S,s,E,r]),S?l.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/60 backdrop-blur-[2px]",id:r,children:l.jsxs("div",{className:`bg-white rounded-lg shadow-lg w-full max-w-md p-4 transform transition-all duration-300 scale-100 ${d}`,children:[l.jsxs("div",{className:`flex justify-between items-center relative ${b}`,children:[e&&l.jsx("h2",{className:"text-lg font-semibold",children:e}),n&&l.jsx("button",{onClick:E,className:`text-gray-500 hover:text-black absolute top-0 right-3 hover:bg-gray-200 rounded-full aspect-square w-8 ${c}`,"aria-label":"Close modal",children:"✕"})]}),l.jsx("div",{className:h,children:typeof o=="function"?o({modalData:N}):o})]})}):null}function Wr({children:r}){const[e,o]=a.useState({}),[t,n]=a.useState({}),d=a.useCallback((i,g)=>{o(y=>({...y,[i]:!0})),g&&n(y=>({...y,[i]:g}))},[]),b=a.useCallback(i=>{o(g=>({...g,[i]:!1})),n(g=>{const y={...g};return delete y[i],y})},[]),h=a.useCallback(i=>!!e[i],[e]),u=a.useCallback(i=>t[i],[t]),s=a.useMemo(()=>({openModal:d,closeModal:b}),[d,b]),c=a.useMemo(()=>({isOpen:h,getModalData:u}),[h,u]);return l.jsx(ir.Provider,{value:s,children:l.jsx(dr.Provider,{value:c,children:r})})}function qr(r){const{openModal:e,closeModal:o}=W(),{isOpen:t,getModalData:n}=q();return{open:d=>e(r,d),close:()=>o(r),isOpen:t(r),data:n(r)}}let G=null,U={};function Gr(r){G=r}function Ur(r){U={...U,...r}}function Xr(){return U}function Yr(r,e,o=3e3,t){G?G(r,e,o,t):console.warn("Toast system is not mounted")}function Jr(r){return H({attr:{viewBox:"0 0 15 15",fill:"none"},child:[{tag:"path",attr:{fillRule:"evenodd",clipRule:"evenodd",d:"M11.7816 4.03157C12.0062 3.80702 12.0062 3.44295 11.7816 3.2184C11.5571 2.99385 11.193 2.99385 10.9685 3.2184L7.50005 6.68682L4.03164 3.2184C3.80708 2.99385 3.44301 2.99385 3.21846 3.2184C2.99391 3.44295 2.99391 3.80702 3.21846 4.03157L6.68688 7.49999L3.21846 10.9684C2.99391 11.193 2.99391 11.557 3.21846 11.7816C3.44301 12.0061 3.80708 12.0061 4.03164 11.7816L7.50005 8.31316L10.9685 11.7816C11.193 12.0061 11.5571 12.0061 11.7816 11.7816C12.0062 11.557 12.0062 11.193 11.7816 10.9684L8.31322 7.49999L11.7816 4.03157Z",fill:"currentColor"},child:[]}]})(r)}const Qr=()=>"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(r){const e=Math.random()*16|0;return(r==="x"?e:e&3|8).toString(16)}),Vr=({containerStyle:r=""})=>{const[e,o]=a.useState([]);a.useEffect(()=>{Gr((n,d,b,h)=>{const u=Qr();o(s=>[...s,{id:u,type:n,message:d,config:h}]),setTimeout(()=>{o(s=>s.filter(c=>c.id!==u))},b)})},[]);const t=Xr();return l.jsx("div",{className:`fixed top-5 right-5 z-9999 flex flex-col gap-2 ${r}`,children:e.map(n=>{var s,c,i,g,y,f,v,S,N,E,k,C,p,w;const d=((s=n.config)==null?void 0:s.icon)||((c=t.icons)==null?void 0:c[n.type])||Rr(n.type),b=((i=n.config)==null?void 0:i.bgColor)||((y=(g=t.colors)==null?void 0:g[n.type])==null?void 0:y.bg)||"bg-white dark:bg-gray-800",h=((f=n.config)==null?void 0:f.textColor)||((S=(v=t.colors)==null?void 0:v[n.type])==null?void 0:S.text)||"text-gray-700 dark:text-gray-300",u=`w-8 h-8 mr-3 text-xl flex items-center justify-center ${(N=n.config)==null?void 0:N.iconContainerClass}`;return l.jsxs("div",{className:`flex items-center w-full max-w-xs p-4 text-sm rounded-lg shadow ${b} ${h} ${(E=n.config)==null?void 0:E.containerBody}`,children:[d&&l.jsx("div",{className:u,children:d}),l.jsxs("div",{className:"flex-1",children:[((k=n.config)==null?void 0:k.title)&&l.jsx("div",{className:`font-semibold text-black ${(C=n.config)==null?void 0:C.titleClass}`,children:n.config.title}),((p=n.config)==null?void 0:p.description)&&l.jsx("div",{className:`text-sm text-gray-500 ${(w=n.config)==null?void 0:w.subTitleClass}`,children:n.config.description})]}),l.jsx("button",{onClick:()=>o(j=>j.filter(L=>L.id!==n.id)),className:"ml-auto text-gray-400 hover:text-gray-700 dark:text-gray-500 dark:hover:text-white","aria-label":"Close",children:l.jsx(Jr,{size:18})})]},n.id)})})};function Rr(r){switch(r){case"success":return"✅";case"error":return"❌";case"warning":return"⚠️";case"info":return"ℹ️"}}m.Accordion=Zr,m.Badge=Br,m.Button=xr,m.Checkbox=ar,m.Dropdown=Dr,m.Input=rr,m.Modal=Hr,m.ModalProvider=Wr,m.Select=or,m.Toast=Vr,m.Toggler=Fr,m.Tooltip=Tr,m.setToastDefaults=Ur,m.showToast=Yr,m.useModalActions=W,m.useModalInstance=qr,m.useModalState=q,Object.defineProperty(m,Symbol.toStringTag,{value:"Module"})}));
15
+ `,children:g?g(k,C):k.label},String(k.value))})]})]})}function Kr(r){return H({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M256 294.1L383 167c9.4-9.4 24.6-9.4 33.9 0s9.3 24.6 0 34L273 345c-9.1 9.1-23.7 9.3-33.1.7L95 201.1c-4.7-4.7-7-10.9-7-17s2.3-12.3 7-17c9.4-9.4 24.6-9.4 33.9 0l127.1 127z"},child:[]}]})(r)}const Zr=({items:r,allowMultipleOpen:e=!1,className:o="",tileClasses:t="",open:n,onChange:d,renderTitle:b,renderContent:h,showArrowIcon:u=!0,panelClasses:s=""})=>{const[c,i]=a.useState(new Set),g=a.useMemo(()=>n?new Set(n):c,[n,c]),y=a.useCallback(f=>{const v=new Set(g);v.has(f)?v.delete(f):(e||v.clear(),v.add(f)),n&&d?d(Array.from(v)):i(v)},[g,n,d,e]);return l.jsx("div",{className:"accordion",role:"region","aria-multiselectable":e,children:r.map(f=>{const v=g.has(f.id),$=`accordion-heading-${f.id}`,N=`accordion-panel-${f.id}`;return l.jsxs("div",{className:`accordion-item border rounded border-gray-300 dark:border-gray-700 ${o}`,children:[l.jsxs("button",{id:$,type:"button","aria-expanded":v,"aria-controls":N,onClick:()=>y(f.id),className:`flex justify-between items-center w-full p-1.5 text-left text-gray-700 dark:text-gray-300 hover:bg-gray-100 dark:hover:bg-gray-800 focus:outline-none gap-3 ${t}`,children:[b?b(f,v):f.title,u?l.jsx(Kr,{}):null]}),l.jsx("div",{id:N,role:"region","aria-labelledby":$,hidden:!v,className:`p-4 border-t border-gray-200 dark:border-gray-700 text-gray-600 dark:text-gray-400 ${s}`,children:h?h(f,v):f.content})]},f.id)})})},ir=a.createContext(null),W=()=>{const r=a.useContext(ir);if(!r)throw new Error("useModalActions must be used within a ModalActionProvider");return r},dr=a.createContext(null),q=()=>a.useContext(dr);function Hr({id:r,title:e,children:o,standalone:t=!1,showFloatingClose:n=!1,containerClasses:d="",headerClasses:b="",bodyClasses:h="",onClose:u,disableEscapeClose:s=!1,closeBtnStyle:c}){const i=q(),g=W(),y=!t&&!!i&&!!g,[f,v]=a.useState(!1),$=y?i.isOpen(r):f,N=y?i.getModalData(r):null,E=a.useCallback(()=>{y?g.closeModal(r):v(!1),u==null||u()},[y,g,r,u]),k=a.useRef(null);return a.useEffect(()=>{$&&(k.current=document.activeElement);const C=document.getElementById(r),p=["a[href]","button:not([disabled])","textarea:not([disabled])","input:not([disabled])","select:not([disabled])",'[tabindex]:not([tabindex="-1"])'],m=()=>{if(!C)return[];const w=C.querySelectorAll(p.join(","));return Array.from(w).filter(O=>O.offsetParent!==null)},j=w=>{if(w.key==="Tab"){const O=m();if(O.length===0)return;const S=O[0],M=O[O.length-1];w.shiftKey?document.activeElement===S&&(w.preventDefault(),M.focus()):document.activeElement===M&&(w.preventDefault(),S.focus())}},L=w=>{w.key==="Escape"&&!s&&E(),j(w)};return $&&(document.body.style.overflow="hidden",setTimeout(()=>{const w=m();w.length&&w[0].focus()},0),window.addEventListener("keydown",L)),()=>{var w;document.body.style.overflow="",(w=k.current)==null||w.focus(),window.removeEventListener("keydown",L)}},[$,s,E,r]),$?l.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/60 backdrop-blur-[2px]",id:r,children:l.jsxs("div",{className:`bg-white rounded-lg shadow-lg w-full max-w-md p-4 transform transition-all duration-300 scale-100 ${d}`,children:[l.jsxs("div",{className:`flex justify-between items-center relative ${b}`,children:[e&&l.jsx("h2",{className:"text-lg font-semibold",children:e}),n&&l.jsx("button",{onClick:E,className:`text-gray-500 hover:text-black absolute top-0 right-3 hover:bg-gray-200 rounded-full aspect-square w-8 ${c}`,"aria-label":"Close modal",children:"✕"})]}),l.jsx("div",{className:h,children:typeof o=="function"?o({modalData:N}):o})]})}):null}function Wr({children:r}){const[e,o]=a.useState({}),[t,n]=a.useState({}),d=a.useCallback((i,g)=>{o(y=>({...y,[i]:!0})),g&&n(y=>({...y,[i]:g}))},[]),b=a.useCallback(i=>{o(g=>({...g,[i]:!1})),n(g=>{const y={...g};return delete y[i],y})},[]),h=a.useCallback(i=>!!e[i],[e]),u=a.useCallback(i=>t[i],[t]),s=a.useMemo(()=>({openModal:d,closeModal:b}),[d,b]),c=a.useMemo(()=>({isOpen:h,getModalData:u}),[h,u]);return l.jsx(ir.Provider,{value:s,children:l.jsx(dr.Provider,{value:c,children:r})})}function qr(r){const{openModal:e,closeModal:o}=W(),{isOpen:t,getModalData:n}=q();return{open:d=>e(r,d),close:()=>o(r),isOpen:t(r),data:n(r)}}let G=null,U={};function Gr(r){G=r}function Ur(r){U={...U,...r}}function Xr(){return U}function Yr(r,e,o=3e3,t){G?G(r,e,o,t):console.warn("Toast system is not mounted")}function Jr(r){return H({attr:{viewBox:"0 0 15 15",fill:"none"},child:[{tag:"path",attr:{fillRule:"evenodd",clipRule:"evenodd",d:"M11.7816 4.03157C12.0062 3.80702 12.0062 3.44295 11.7816 3.2184C11.5571 2.99385 11.193 2.99385 10.9685 3.2184L7.50005 6.68682L4.03164 3.2184C3.80708 2.99385 3.44301 2.99385 3.21846 3.2184C2.99391 3.44295 2.99391 3.80702 3.21846 4.03157L6.68688 7.49999L3.21846 10.9684C2.99391 11.193 2.99391 11.557 3.21846 11.7816C3.44301 12.0061 3.80708 12.0061 4.03164 11.7816L7.50005 8.31316L10.9685 11.7816C11.193 12.0061 11.5571 12.0061 11.7816 11.7816C12.0062 11.557 12.0062 11.193 11.7816 10.9684L8.31322 7.49999L11.7816 4.03157Z",fill:"currentColor"},child:[]}]})(r)}const Qr=()=>"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(r){const e=Math.random()*16|0;return(r==="x"?e:e&3|8).toString(16)}),Vr=({containerStyle:r=""})=>{const[e,o]=a.useState([]);a.useEffect(()=>{Gr((n,d,b,h)=>{const u=Qr();o(s=>[...s,{id:u,type:n,message:d,config:h}]),setTimeout(()=>{o(s=>s.filter(c=>c.id!==u))},b)})},[]);const t=Xr();return l.jsx("div",{className:`fixed top-5 right-5 z-9999 flex flex-col gap-2 ${r}`,children:e.map(n=>{var s,c,i,g,y,f,v,$,N,E,k,C,p,m;const d=((s=n.config)==null?void 0:s.icon)||((c=t.icons)==null?void 0:c[n.type])||Rr(n.type),b=((i=n.config)==null?void 0:i.bgColor)||((y=(g=t.colors)==null?void 0:g[n.type])==null?void 0:y.bg)||"bg-white dark:bg-gray-800",h=((f=n.config)==null?void 0:f.textColor)||(($=(v=t.colors)==null?void 0:v[n.type])==null?void 0:$.text)||"text-gray-700 dark:text-gray-300",u=`w-8 h-8 mr-3 text-xl flex items-center justify-center ${(N=n.config)==null?void 0:N.iconContainerClass}`;return l.jsxs("div",{className:`flex items-center w-full max-w-xs p-4 text-sm rounded-lg shadow ${b} ${h} ${(E=n.config)==null?void 0:E.containerBody}`,children:[d&&l.jsx("div",{className:u,children:d}),l.jsxs("div",{className:"flex-1",children:[((k=n.config)==null?void 0:k.title)&&l.jsx("div",{className:`font-semibold text-black ${(C=n.config)==null?void 0:C.titleClass}`,children:n.config.title}),((p=n.config)==null?void 0:p.description)&&l.jsx("div",{className:`text-sm text-gray-500 ${(m=n.config)==null?void 0:m.subTitleClass}`,children:n.config.description})]}),l.jsx("button",{onClick:()=>o(j=>j.filter(L=>L.id!==n.id)),className:"ml-auto text-gray-400 hover:text-gray-700 dark:text-gray-500 dark:hover:text-white","aria-label":"Close",children:l.jsx(Jr,{size:18})})]},n.id)})})};function Rr(r){switch(r){case"success":return"✅";case"error":return"❌";case"warning":return"⚠️";case"info":return"ℹ️"}}x.Accordion=Zr,x.Badge=Br,x.Button=xr,x.Checkbox=ar,x.Dropdown=Dr,x.Input=rr,x.Modal=Hr,x.ModalProvider=Wr,x.Select=or,x.Toast=Vr,x.Toggler=Fr,x.Tooltip=Tr,x.setToastDefaults=Ur,x.showToast=Yr,x.useModalActions=W,x.useModalInstance=qr,x.useModalState=q,Object.defineProperty(x,Symbol.toStringTag,{value:"Module"})}));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tailwind-ux-kit",
3
- "version": "1.0.96",
3
+ "version": "1.0.100",
4
4
  "main": "lib/tailwind-ux-kit.es.js",
5
5
  "module": "lib/tailwind-ux-kit.umd.js",
6
6
  "types": "lib/tailwind-ux-kit.es.d.ts",