tailwind-ux-kit 1.0.52 → 1.0.54

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.
@@ -10,6 +10,7 @@ interface AccordionProps<T extends AccordionItemBase> {
10
10
  allowMultipleOpen?: boolean;
11
11
  className?: string;
12
12
  tileClasses?: string;
13
+ panelClasses?: string;
13
14
  open?: (string | number)[];
14
15
  showArrowIcon?: boolean;
15
16
  onChange?: (openItems: (string | number)[]) => void;
@@ -22,5 +23,5 @@ interface AccordionProps<T extends AccordionItemBase> {
22
23
  */
23
24
  renderContent?: (item: T, isOpen: boolean) => React.ReactNode;
24
25
  }
25
- declare const Accordion: <T extends AccordionItemBase>({ items, allowMultipleOpen, className, tileClasses, open: controlledOpen, onChange, renderTitle, renderContent, showArrowIcon, }: AccordionProps<T>) => import("react/jsx-runtime").JSX.Element;
26
+ declare const Accordion: <T extends AccordionItemBase>({ items, allowMultipleOpen, className, tileClasses, open: controlledOpen, onChange, renderTitle, renderContent, showArrowIcon, panelClasses, }: AccordionProps<T>) => import("react/jsx-runtime").JSX.Element;
26
27
  export default Accordion;
package/lib/index.css CHANGED
@@ -1 +1 @@
1
- /*! tailwindcss v4.1.10 | MIT License | https://tailwindcss.com */@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-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-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}}@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}
1
+ /*! tailwindcss v4.1.10 | MIT License | https://tailwindcss.com */@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}}@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}
@@ -1,5 +1,5 @@
1
1
  "use client";
2
- import { jsxs as y, jsx as f } from "react/jsx-runtime";
2
+ import { jsxs as y, jsx as u } from "react/jsx-runtime";
3
3
  import P, { forwardRef as q, useState as L, useMemo as $, useId as se, useRef as M, useCallback as E, useEffect as A, createContext as X, useContext as Y } from "react";
4
4
  const H = {
5
5
  xs: "text-xs px-2 py-1",
@@ -38,80 +38,80 @@ const H = {
38
38
  label: t,
39
39
  id: r,
40
40
  inputSize: s = "md",
41
- shape: p = "rounded",
42
- validate: u,
43
- onValidatedChange: c,
44
- className: i = "",
45
- icon: d,
41
+ shape: f = "rounded",
42
+ validate: d,
43
+ onValidatedChange: l,
44
+ className: a = "",
45
+ icon: c,
46
46
  iconPosition: o = "left",
47
- floatingLabelStyle: l,
48
- onChange: b,
49
- isValid: a,
50
- isInvalid: g,
51
- feedback: x,
47
+ floatingLabelStyle: i,
48
+ onChange: g,
49
+ isValid: b,
50
+ isInvalid: p,
51
+ feedback: m,
52
52
  feedbackType: h = "invalid",
53
53
  ...w
54
54
  } = e, [S, N] = L("default"), O = P.useCallback(
55
55
  (z) => {
56
- const Z = z.target.value, I = (u == null ? void 0 : u(Z)) ?? "default";
57
- N(I), c == null || c(z, I), b == null || b(z);
56
+ const Z = z.target.value, I = (d == null ? void 0 : d(Z)) ?? "default";
57
+ N(I), l == null || l(z, I), g == null || g(z);
58
58
  },
59
- [u, c, b]
60
- ), v = $(() => r || (typeof t == "string" ? `input-${t.toLowerCase().replace(/\s+/g, "-")}` : `input-${Math.random().toString(36).slice(2)}`), [r, t]), m = !!l, C = H[s] || H.md, k = W[p] || W.flat, j = $(
61
- () => ie(S, a, g),
62
- [S, a, g]
63
- ), _ = $(() => o === "start" || o === "left" ? "left-0 ps-3.5" : "right-0 pe-3.5", [o]), B = $(() => d ? o === "start" || o === "left" ? "ps-10" : "pe-10" : "", [d, o]);
59
+ [d, l, g]
60
+ ), v = $(() => r || (typeof t == "string" ? `input-${t.toLowerCase().replace(/\s+/g, "-")}` : `input-${Math.random().toString(36).slice(2)}`), [r, t]), x = !!i, C = H[s] || H.md, k = W[f] || W.flat, j = $(
61
+ () => ie(S, b, p),
62
+ [S, b, p]
63
+ ), _ = $(() => o === "start" || o === "left" ? "left-0 ps-3.5" : "right-0 pe-3.5", [o]), B = $(() => c ? o === "start" || o === "left" ? "ps-10" : "pe-10" : "", [c, o]);
64
64
  return /* @__PURE__ */ y(
65
65
  "div",
66
66
  {
67
- className: `w-full relative ${m ? "z-0" : ""} tailwind-ux-input`,
67
+ className: `w-full relative ${x ? "z-0" : ""} tailwind-ux-input`,
68
68
  children: [
69
- !m && t && /* @__PURE__ */ f(
69
+ !x && t && /* @__PURE__ */ u(
70
70
  "label",
71
71
  {
72
72
  htmlFor: v,
73
- className: `block mb-1 text-sm ${a ? "text-green-700 dark:text-green-500" : g ? "text-red-700 dark:text-red-500" : "text-gray-700"}`,
73
+ className: `block mb-1 text-sm ${b ? "text-green-700 dark:text-green-500" : p ? "text-red-700 dark:text-red-500" : "text-gray-700"}`,
74
74
  children: t
75
75
  }
76
76
  ),
77
77
  /* @__PURE__ */ y("div", { className: "relative w-full", children: [
78
- d && /* @__PURE__ */ f(
78
+ c && /* @__PURE__ */ u(
79
79
  "div",
80
80
  {
81
81
  className: `absolute inset-y-0 flex items-center ${_}`,
82
82
  "aria-hidden": "true",
83
- children: /* @__PURE__ */ f("span", { className: "text-gray-500", children: d })
83
+ children: /* @__PURE__ */ u("span", { className: "text-gray-500", children: c })
84
84
  }
85
85
  ),
86
- /* @__PURE__ */ f(
86
+ /* @__PURE__ */ u(
87
87
  "input",
88
88
  {
89
89
  ...w,
90
90
  id: v,
91
91
  ref: n,
92
- placeholder: m ? " " : w.placeholder,
92
+ placeholder: x ? " " : w.placeholder,
93
93
  onChange: O,
94
94
  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
95
95
  ${C}
96
- ${m && l && ae[l]}
97
- ${B} ${k} ${j} ${i}`
96
+ ${x && i && ae[i]}
97
+ ${B} ${k} ${j} ${a}`
98
98
  }
99
99
  ),
100
- m && t && l && /* @__PURE__ */ f(
100
+ x && t && i && /* @__PURE__ */ u(
101
101
  "label",
102
102
  {
103
103
  htmlFor: v,
104
- className: `ms-1 ${le[l]} ${i}`,
104
+ className: `ms-1 ${le[i]} ${a}`,
105
105
  children: t
106
106
  }
107
107
  )
108
108
  ] }),
109
- x && /* @__PURE__ */ f(
109
+ m && /* @__PURE__ */ u(
110
110
  "p",
111
111
  {
112
112
  className: `mt-1 text-xs ${h === "invalid" ? "text-red-600 dark:text-red-500" : "text-green-600 dark:text-green-500"}`,
113
113
  role: h === "invalid" ? "alert" : void 0,
114
- children: x
114
+ children: m
115
115
  }
116
116
  )
117
117
  ]
@@ -157,69 +157,69 @@ const de = {
157
157
  label: t,
158
158
  id: r,
159
159
  inputSize: s = "md",
160
- shape: p = "rounded",
161
- validate: u,
162
- onValidatedChange: c,
163
- className: i = "",
164
- icon: d,
160
+ shape: f = "rounded",
161
+ validate: d,
162
+ onValidatedChange: l,
163
+ className: a = "",
164
+ icon: c,
165
165
  iconPosition: o = "left",
166
- floatingLabelStyle: l,
167
- onChange: b,
168
- isValid: a,
169
- isInvalid: g,
170
- feedback: x,
166
+ floatingLabelStyle: i,
167
+ onChange: g,
168
+ isValid: b,
169
+ isInvalid: p,
170
+ feedback: m,
171
171
  feedbackType: h = "invalid",
172
172
  children: w,
173
173
  ...S
174
- } = e, [N, O] = L("default"), v = se(), m = $(() => r || (typeof t == "string" ? `select-${t.toLowerCase().replace(/\s+/g, "-")}` : v), [r, t, v]), C = (I) => {
175
- const oe = I.target.value, G = (u == null ? void 0 : u(oe)) ?? "default";
176
- O(G), c == null || c(I, G), b == null || b(I);
177
- }, k = !!l, j = de[s], _ = ue[p], B = ge(N, a, g);
174
+ } = e, [N, O] = L("default"), v = se(), x = $(() => r || (typeof t == "string" ? `select-${t.toLowerCase().replace(/\s+/g, "-")}` : v), [r, t, v]), C = (I) => {
175
+ const oe = I.target.value, G = (d == null ? void 0 : d(oe)) ?? "default";
176
+ O(G), l == null || l(I, G), g == null || g(I);
177
+ }, k = !!i, j = de[s], _ = ue[f], B = ge(N, b, p);
178
178
  return /* @__PURE__ */ y("div", { className: `w-full relative ${k ? "z-0" : ""}`, children: [
179
- !k && t && /* @__PURE__ */ f(
179
+ !k && t && /* @__PURE__ */ u(
180
180
  "label",
181
181
  {
182
- htmlFor: m,
183
- className: `block mb-1 text-sm ${a ? "text-green-700" : g ? "text-red-700" : "text-gray-700"}`,
182
+ htmlFor: x,
183
+ className: `block mb-1 text-sm ${b ? "text-green-700" : p ? "text-red-700" : "text-gray-700"}`,
184
184
  children: t
185
185
  }
186
186
  ),
187
187
  /* @__PURE__ */ y("div", { className: "relative w-full", children: [
188
- d && /* @__PURE__ */ f(
188
+ c && /* @__PURE__ */ u(
189
189
  "div",
190
190
  {
191
191
  className: `absolute inset-y-0 flex items-center ${o === "start" || o === "left" ? "left-0 ps-3.5" : "right-0 pe-3.5"}`,
192
- children: /* @__PURE__ */ f("span", { className: "text-gray-500", children: d })
192
+ children: /* @__PURE__ */ u("span", { className: "text-gray-500", children: c })
193
193
  }
194
194
  ),
195
- /* @__PURE__ */ f(
195
+ /* @__PURE__ */ u(
196
196
  "select",
197
197
  {
198
198
  ...S,
199
- id: m,
199
+ id: x,
200
200
  ref: n,
201
201
  onChange: C,
202
202
  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
203
- ${j} ${d && (o === "start" || o === "left") ? "ps-10" : d ? "pe-10" : ""}
204
- ${k && l && fe[l]}
205
- ${_} ${B} ${i}`,
203
+ ${j} ${c && (o === "start" || o === "left") ? "ps-10" : c ? "pe-10" : ""}
204
+ ${k && i && fe[i]}
205
+ ${_} ${B} ${a}`,
206
206
  children: w
207
207
  }
208
208
  ),
209
- k && t && l && /* @__PURE__ */ f(
209
+ k && t && i && /* @__PURE__ */ u(
210
210
  "label",
211
211
  {
212
- htmlFor: m,
213
- className: `ms-1 ${pe[l]} ${i}`,
212
+ htmlFor: x,
213
+ className: `ms-1 ${pe[i]} ${a}`,
214
214
  children: t
215
215
  }
216
216
  )
217
217
  ] }),
218
- x && /* @__PURE__ */ f(
218
+ m && /* @__PURE__ */ u(
219
219
  "p",
220
220
  {
221
221
  className: `mt-1 text-xs ${h === "invalid" ? "text-red-600" : "text-green-600"}`,
222
- children: x
222
+ children: m
223
223
  }
224
224
  )
225
225
  ] });
@@ -268,22 +268,22 @@ const me = {
268
268
  size: t = "md",
269
269
  type: r = "button",
270
270
  shape: s = "rounded",
271
- className: p = "",
272
- isLoading: u = !1,
273
- disabled: c = !1,
274
- ...i
271
+ className: f = "",
272
+ isLoading: d = !1,
273
+ disabled: l = !1,
274
+ ...a
275
275
  }) => {
276
- const d = c || u, o = [
276
+ const c = l || d, o = [
277
277
  "inline-flex items-center justify-center font-normal transition duration-150",
278
278
  me[n],
279
279
  xe[t],
280
280
  he[s],
281
281
  s === "flat" ? "shadow-none" : "shadow-sm",
282
- d ? "opacity-50 cursor-not-allowed" : "cursor-pointer",
283
- p
282
+ c ? "opacity-50 cursor-not-allowed" : "cursor-pointer",
283
+ f
284
284
  ].filter(Boolean).join(" ");
285
- return /* @__PURE__ */ y("button", { type: r, className: o, disabled: d, ...i, children: [
286
- u && /* @__PURE__ */ y(
285
+ return /* @__PURE__ */ y("button", { type: r, className: o, disabled: c, ...a, children: [
286
+ d && /* @__PURE__ */ y(
287
287
  "svg",
288
288
  {
289
289
  "aria-hidden": "true",
@@ -293,14 +293,14 @@ const me = {
293
293
  fill: "none",
294
294
  xmlns: "http://www.w3.org/2000/svg",
295
295
  children: [
296
- /* @__PURE__ */ f(
296
+ /* @__PURE__ */ u(
297
297
  "path",
298
298
  {
299
299
  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",
300
300
  fill: "currentColor"
301
301
  }
302
302
  ),
303
- /* @__PURE__ */ f(
303
+ /* @__PURE__ */ u(
304
304
  "path",
305
305
  {
306
306
  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",
@@ -317,7 +317,7 @@ const me = {
317
317
  children: n,
318
318
  position: t = "right"
319
319
  }) => {
320
- const [r, s] = L(!1), [p, u] = L(!1), c = M(null), i = M(null), d = $(() => {
320
+ const [r, s] = L(!1), [f, d] = L(!1), l = M(null), a = M(null), c = $(() => {
321
321
  switch (t) {
322
322
  case "left":
323
323
  return "left-0";
@@ -327,32 +327,32 @@ const me = {
327
327
  default:
328
328
  return "right-0";
329
329
  }
330
- }, [t]), o = E((a) => {
331
- const g = a.target;
332
- c.current && !c.current.contains(g) && i.current && !i.current.contains(g) && s(!1);
333
- }, []), l = E(() => {
334
- if (!i.current || !c.current) return;
335
- const a = i.current.getBoundingClientRect(), g = c.current.getBoundingClientRect(), x = window.innerHeight - a.bottom, h = a.top;
336
- u(
337
- x < g.height && h > g.height
330
+ }, [t]), o = E((b) => {
331
+ const p = b.target;
332
+ l.current && !l.current.contains(p) && a.current && !a.current.contains(p) && s(!1);
333
+ }, []), i = E(() => {
334
+ if (!a.current || !l.current) return;
335
+ const b = a.current.getBoundingClientRect(), p = l.current.getBoundingClientRect(), m = window.innerHeight - b.bottom, h = b.top;
336
+ d(
337
+ m < p.height && h > p.height
338
338
  );
339
339
  }, []);
340
340
  A(() => {
341
341
  if (r)
342
- return l(), window.addEventListener("resize", l), window.addEventListener("scroll", l, !0), () => {
343
- window.removeEventListener("resize", l), window.removeEventListener("scroll", l, !0);
342
+ return i(), window.addEventListener("resize", i), window.addEventListener("scroll", i, !0), () => {
343
+ window.removeEventListener("resize", i), window.removeEventListener("scroll", i, !0);
344
344
  };
345
- }, [r, l]), A(() => (document.addEventListener("mousedown", o), () => document.removeEventListener("mousedown", o)), [o]);
346
- const b = E(() => s((a) => !a), []);
345
+ }, [r, i]), A(() => (document.addEventListener("mousedown", o), () => document.removeEventListener("mousedown", o)), [o]);
346
+ const g = E(() => s((b) => !b), []);
347
347
  return /* @__PURE__ */ y("div", { className: "relative flex items-center", children: [
348
- /* @__PURE__ */ f("button", { ref: i, onClick: b, children: e }),
349
- r && /* @__PURE__ */ f(
348
+ /* @__PURE__ */ u("button", { ref: a, onClick: g, children: e }),
349
+ r && /* @__PURE__ */ u(
350
350
  "div",
351
351
  {
352
- ref: c,
352
+ ref: l,
353
353
  className: `absolute z-10 bg-white rounded-sm shadow-md overflow-hidden
354
- ${p ? "bottom-full mb-2" : "top-full mt-2"}
355
- ${d}`,
354
+ ${f ? "bottom-full mb-2" : "top-full mt-2"}
355
+ ${c}`,
356
356
  children: n
357
357
  }
358
358
  )
@@ -363,22 +363,22 @@ const me = {
363
363
  position: t = "top",
364
364
  className: r = "",
365
365
  tooltipClass: s = "",
366
- tooltipStyle: p = {}
366
+ tooltipStyle: f = {}
367
367
  }) => {
368
- const u = M(null), c = M(null);
368
+ const d = M(null), l = M(null);
369
369
  A(() => {
370
- const d = u.current, o = c.current;
371
- if (!d || !o) return;
372
- const l = () => {
370
+ const c = d.current, o = l.current;
371
+ if (!c || !o) return;
372
+ const i = () => {
373
373
  o.style.opacity = "1", o.style.visibility = "visible";
374
- }, b = () => {
374
+ }, g = () => {
375
375
  o.style.opacity = "0", o.style.visibility = "hidden";
376
376
  };
377
- return d.addEventListener("mouseenter", l), d.addEventListener("mouseleave", b), () => {
378
- d.removeEventListener("mouseenter", l), d.removeEventListener("mouseleave", b);
377
+ return c.addEventListener("mouseenter", i), c.addEventListener("mouseleave", g), () => {
378
+ c.removeEventListener("mouseenter", i), c.removeEventListener("mouseleave", g);
379
379
  };
380
380
  }, []);
381
- const i = (d) => {
381
+ const a = (c) => {
382
382
  const o = {
383
383
  position: "absolute",
384
384
  opacity: 0,
@@ -396,7 +396,7 @@ const me = {
396
396
  zIndex: 9999,
397
397
  width: "max-content"
398
398
  };
399
- switch (d) {
399
+ switch (c) {
400
400
  case "top":
401
401
  return {
402
402
  ...o,
@@ -433,17 +433,17 @@ const me = {
433
433
  return o;
434
434
  }
435
435
  };
436
- return /* @__PURE__ */ y("div", { ref: u, className: `relative inline-block ${r}`, children: [
436
+ return /* @__PURE__ */ y("div", { ref: d, className: `relative inline-block ${r}`, children: [
437
437
  e,
438
- /* @__PURE__ */ f(
438
+ /* @__PURE__ */ u(
439
439
  "div",
440
440
  {
441
- ref: c,
441
+ ref: l,
442
442
  role: "tooltip",
443
443
  className: s,
444
444
  style: {
445
- ...i(t),
446
- ...p
445
+ ...a(t),
446
+ ...f
447
447
  },
448
448
  children: n
449
449
  }
@@ -484,20 +484,20 @@ const me = {
484
484
  size: t = "sm",
485
485
  shape: r = "rounded",
486
486
  icon: s,
487
- dismissible: p,
488
- onDismiss: u,
489
- className: c = "",
490
- ...i
487
+ dismissible: f,
488
+ onDismiss: d,
489
+ className: l = "",
490
+ ...a
491
491
  }) => {
492
- const d = !e && !!s, o = `inline-flex items-center font-medium ${ye[n] || ""} ${we[t] || ""} ${ve[r] || ""} ${d ? "justify-center p-2 w-8 h-8" : ""} ` + c;
493
- return /* @__PURE__ */ y("span", { className: o.trim(), ...i, children: [
494
- s && /* @__PURE__ */ f("span", { className: e ? "mr-1" : "", children: s }),
492
+ const c = !e && !!s, o = `inline-flex items-center font-medium ${ye[n] || ""} ${we[t] || ""} ${ve[r] || ""} ${c ? "justify-center p-2 w-8 h-8" : ""} ` + l;
493
+ return /* @__PURE__ */ y("span", { className: o.trim(), ...a, children: [
494
+ s && /* @__PURE__ */ u("span", { className: e ? "mr-1" : "", children: s }),
495
495
  e,
496
- p && /* @__PURE__ */ f(
496
+ f && /* @__PURE__ */ u(
497
497
  "button",
498
498
  {
499
499
  type: "button",
500
- onClick: u,
500
+ onClick: d,
501
501
  className: "ml-2 text-xs font-bold leading-none focus:outline-none",
502
502
  children: "×"
503
503
  }
@@ -515,9 +515,9 @@ function Se(e, n) {
515
515
  if (e == null) return {};
516
516
  var t = Ne(e, n), r, s;
517
517
  if (Object.getOwnPropertySymbols) {
518
- var p = Object.getOwnPropertySymbols(e);
519
- for (s = 0; s < p.length; s++)
520
- r = p[s], !(n.indexOf(r) >= 0) && Object.prototype.propertyIsEnumerable.call(e, r) && (t[r] = e[r]);
518
+ var f = Object.getOwnPropertySymbols(e);
519
+ for (s = 0; s < f.length; s++)
520
+ r = f[s], !(n.indexOf(r) >= 0) && Object.prototype.propertyIsEnumerable.call(e, r) && (t[r] = e[r]);
521
521
  }
522
522
  return t;
523
523
  }
@@ -594,21 +594,21 @@ function Le(e) {
594
594
  var {
595
595
  attr: r,
596
596
  size: s,
597
- title: p
598
- } = e, u = Se(e, Ce), c = s || t.size || "1em", i;
599
- return t.className && (i = t.className), e.className && (i = (i ? i + " " : "") + e.className), /* @__PURE__ */ P.createElement("svg", D({
597
+ title: f
598
+ } = e, d = Se(e, Ce), l = s || t.size || "1em", a;
599
+ return t.className && (a = t.className), e.className && (a = (a ? a + " " : "") + e.className), /* @__PURE__ */ P.createElement("svg", D({
600
600
  stroke: "currentColor",
601
601
  fill: "currentColor",
602
602
  strokeWidth: "0"
603
- }, t.attr, r, u, {
604
- className: i,
603
+ }, t.attr, r, d, {
604
+ className: a,
605
605
  style: T(T({
606
606
  color: e.color || t.color
607
607
  }, t.style), e.style),
608
- height: c,
609
- width: c,
608
+ height: l,
609
+ width: l,
610
610
  xmlns: "http://www.w3.org/2000/svg"
611
- }), p && /* @__PURE__ */ P.createElement("title", null, p), e.children);
611
+ }), f && /* @__PURE__ */ P.createElement("title", null, f), e.children);
612
612
  };
613
613
  return K !== void 0 ? /* @__PURE__ */ P.createElement(K.Consumer, null, (t) => n(t)) : n(J);
614
614
  }
@@ -621,26 +621,27 @@ const Fe = ({
621
621
  className: t = "",
622
622
  tileClasses: r = "",
623
623
  open: s,
624
- onChange: p,
625
- renderTitle: u,
626
- renderContent: c,
627
- showArrowIcon: i = !0
624
+ onChange: f,
625
+ renderTitle: d,
626
+ renderContent: l,
627
+ showArrowIcon: a = !0,
628
+ panelClasses: c = ""
628
629
  }) => {
629
- const [d, o] = L(/* @__PURE__ */ new Set()), l = $(() => s ? new Set(s) : d, [s, d]), b = E(
630
- (a) => {
631
- const g = new Set(l);
632
- g.has(a) ? g.delete(a) : (n || g.clear(), g.add(a)), s && p ? p(Array.from(g)) : o(g);
630
+ const [o, i] = L(/* @__PURE__ */ new Set()), g = $(() => s ? new Set(s) : o, [s, o]), b = E(
631
+ (p) => {
632
+ const m = new Set(g);
633
+ m.has(p) ? m.delete(p) : (n || m.clear(), m.add(p)), s && f ? f(Array.from(m)) : i(m);
633
634
  },
634
- [l, s, p, n]
635
+ [g, s, f, n]
635
636
  );
636
- return /* @__PURE__ */ f(
637
+ return /* @__PURE__ */ u(
637
638
  "div",
638
639
  {
639
640
  className: "accordion",
640
641
  role: "region",
641
642
  "aria-multiselectable": n,
642
- children: e.map((a) => {
643
- const g = l.has(a.id), x = `accordion-heading-${a.id}`, h = `accordion-panel-${a.id}`;
643
+ children: e.map((p) => {
644
+ const m = g.has(p.id), h = `accordion-heading-${p.id}`, w = `accordion-panel-${p.id}`;
644
645
  return /* @__PURE__ */ y(
645
646
  "div",
646
647
  {
@@ -649,32 +650,32 @@ const Fe = ({
649
650
  /* @__PURE__ */ y(
650
651
  "button",
651
652
  {
652
- id: x,
653
+ id: h,
653
654
  type: "button",
654
- "aria-expanded": g,
655
- "aria-controls": h,
656
- onClick: () => b(a.id),
655
+ "aria-expanded": m,
656
+ "aria-controls": w,
657
+ onClick: () => b(p.id),
657
658
  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 ${r}`,
658
659
  children: [
659
- u ? u(a, g) : a.title,
660
- i ? /* @__PURE__ */ f(Oe, {}) : null
660
+ d ? d(p, m) : p.title,
661
+ a ? /* @__PURE__ */ u(Oe, {}) : null
661
662
  ]
662
663
  }
663
664
  ),
664
- /* @__PURE__ */ f(
665
+ /* @__PURE__ */ u(
665
666
  "div",
666
667
  {
667
- id: h,
668
+ id: w,
668
669
  role: "region",
669
- "aria-labelledby": x,
670
- hidden: !g,
671
- className: "p-4 border-t border-gray-200 dark:border-gray-700 text-gray-600 dark:text-gray-400",
672
- children: c ? c(a, g) : a.content
670
+ "aria-labelledby": h,
671
+ hidden: !m,
672
+ className: `p-4 border-t border-gray-200 dark:border-gray-700 text-gray-600 dark:text-gray-400 ${c}`,
673
+ children: l ? l(p, m) : p.content
673
674
  }
674
675
  )
675
676
  ]
676
677
  },
677
- a.id
678
+ p.id
678
679
  );
679
680
  })
680
681
  }
@@ -693,13 +694,13 @@ function Ze({
693
694
  children: t,
694
695
  standalone: r = !1,
695
696
  showFloatingClose: s = !1,
696
- containerClasses: p = "",
697
- onClose: u,
698
- disableEscapeClose: c = !1
697
+ containerClasses: f = "",
698
+ onClose: d,
699
+ disableEscapeClose: l = !1
699
700
  }) {
700
- const i = ne(), d = te(), o = !r && !!i && !!d, [l, b] = L(!1), a = o ? i.isOpen(e) : l, g = o ? i.getModalData(e) : null, x = E(() => {
701
- o ? d.closeModal(e) : b(!1), u == null || u();
702
- }, [o, d, e, u]);
701
+ const a = ne(), c = te(), o = !r && !!a && !!c, [i, g] = L(!1), b = o ? a.isOpen(e) : i, p = o ? a.getModalData(e) : null, m = E(() => {
702
+ o ? c.closeModal(e) : g(!1), d == null || d();
703
+ }, [o, c, e, d]);
703
704
  return A(() => {
704
705
  const h = document.activeElement;
705
706
  console.log(e);
@@ -714,27 +715,27 @@ function Ze({
714
715
  '[tabindex]:not([tabindex="-1"])'
715
716
  ], N = () => {
716
717
  if (!w) return [];
717
- const m = w.querySelectorAll(
718
+ const x = w.querySelectorAll(
718
719
  S.join(",")
719
720
  );
720
- return Array.from(m).filter((C) => C.offsetParent !== null);
721
- }, O = (m) => {
722
- if (m.key === "Tab") {
721
+ return Array.from(x).filter((C) => C.offsetParent !== null);
722
+ }, O = (x) => {
723
+ if (x.key === "Tab") {
723
724
  const C = N();
724
725
  if (C.length === 0) return;
725
726
  const k = C[0], j = C[C.length - 1];
726
- m.shiftKey ? document.activeElement === k && (m.preventDefault(), j.focus()) : document.activeElement === j && (m.preventDefault(), k.focus());
727
+ x.shiftKey ? document.activeElement === k && (x.preventDefault(), j.focus()) : document.activeElement === j && (x.preventDefault(), k.focus());
727
728
  }
728
- }, v = (m) => {
729
- m.key === "Escape" && !c && x(), O(m);
729
+ }, v = (x) => {
730
+ x.key === "Escape" && !l && m(), O(x);
730
731
  };
731
- return a && (document.body.style.overflow = "hidden", setTimeout(() => {
732
- const m = N();
733
- m.length && m[0].focus();
732
+ return b && (document.body.style.overflow = "hidden", setTimeout(() => {
733
+ const x = N();
734
+ x.length && x[0].focus();
734
735
  }, 0), window.addEventListener("keydown", v)), () => {
735
736
  document.body.style.overflow = "", h && h.focus(), window.removeEventListener("keydown", v);
736
737
  };
737
- }, [a, c, x, e]), a ? /* @__PURE__ */ f(
738
+ }, [b, l, m, e]), b ? /* @__PURE__ */ u(
738
739
  "div",
739
740
  {
740
741
  className: "fixed inset-0 z-50 flex items-center justify-center bg-black/60 backdrop-blur-[2px]",
@@ -742,21 +743,21 @@ function Ze({
742
743
  children: /* @__PURE__ */ y(
743
744
  "div",
744
745
  {
745
- className: `bg-white rounded-lg shadow-lg w-full max-w-md p-4 transform transition-all duration-300 scale-100 ${p}`,
746
+ className: `bg-white rounded-lg shadow-lg w-full max-w-md p-4 transform transition-all duration-300 scale-100 ${f}`,
746
747
  children: [
747
748
  /* @__PURE__ */ y("div", { className: "flex justify-between items-center relative", children: [
748
- n && /* @__PURE__ */ f("h2", { className: "text-lg font-semibold", children: n }),
749
- s && /* @__PURE__ */ f(
749
+ n && /* @__PURE__ */ u("h2", { className: "text-lg font-semibold", children: n }),
750
+ s && /* @__PURE__ */ u(
750
751
  "button",
751
752
  {
752
- onClick: x,
753
+ onClick: m,
753
754
  className: "text-gray-500 hover:text-black absolute top-2 right-3 hover:bg-gray-200 rounded-full aspect-square w-8",
754
755
  "aria-label": "Close modal",
755
756
  children: "✕"
756
757
  }
757
758
  )
758
759
  ] }),
759
- /* @__PURE__ */ f("div", { className: "mt-3 text-sm text-gray-700", children: typeof t == "function" ? t({ modalData: g }) : t })
760
+ /* @__PURE__ */ u("div", { className: "mt-3 text-sm text-gray-700", children: typeof t == "function" ? t({ modalData: p }) : t })
760
761
  ]
761
762
  }
762
763
  )
@@ -766,29 +767,29 @@ function Ze({
766
767
  function Ge({
767
768
  children: e
768
769
  }) {
769
- const [n, t] = L({}), [r, s] = L({}), p = E((l, b) => {
770
- t((a) => ({ ...a, [l]: !0 })), b && s((a) => ({ ...a, [l]: b }));
771
- }, []), u = E((l) => {
772
- t((b) => ({ ...b, [l]: !1 })), s((b) => {
773
- const a = { ...b };
774
- return delete a[l], a;
770
+ const [n, t] = L({}), [r, s] = L({}), f = E((i, g) => {
771
+ t((b) => ({ ...b, [i]: !0 })), g && s((b) => ({ ...b, [i]: g }));
772
+ }, []), d = E((i) => {
773
+ t((g) => ({ ...g, [i]: !1 })), s((g) => {
774
+ const b = { ...g };
775
+ return delete b[i], b;
775
776
  });
776
- }, []), c = E((l) => !!n[l], [n]), i = E(
777
- (l) => r[l],
777
+ }, []), l = E((i) => !!n[i], [n]), a = E(
778
+ (i) => r[i],
778
779
  [r]
779
- ), d = $(
780
- () => ({ openModal: p, closeModal: u }),
781
- [p, u]
780
+ ), c = $(
781
+ () => ({ openModal: f, closeModal: d }),
782
+ [f, d]
782
783
  ), o = $(
783
- () => ({ isOpen: c, getModalData: i }),
784
- [c, i]
784
+ () => ({ isOpen: l, getModalData: a }),
785
+ [l, a]
785
786
  );
786
- return /* @__PURE__ */ f(ee.Provider, { value: d, children: /* @__PURE__ */ f(re.Provider, { value: o, children: e }) });
787
+ return /* @__PURE__ */ u(ee.Provider, { value: c, children: /* @__PURE__ */ u(re.Provider, { value: o, children: e }) });
787
788
  }
788
789
  function He(e) {
789
790
  const { openModal: n, closeModal: t } = te(), { isOpen: r, getModalData: s } = ne();
790
791
  return {
791
- open: (p) => n(e, p),
792
+ open: (f) => n(e, f),
792
793
  close: () => t(e),
793
794
  isOpen: r(e),
794
795
  data: s(e)
@@ -816,35 +817,35 @@ const Ae = () => "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, functio
816
817
  }), Ue = () => {
817
818
  const [e, n] = L([]);
818
819
  A(() => {
819
- Pe((r, s, p, u) => {
820
- const c = Ae();
821
- n((i) => [...i, { id: c, type: r, message: s, config: u }]), setTimeout(() => {
822
- n((i) => i.filter((d) => d.id !== c));
823
- }, p);
820
+ Pe((r, s, f, d) => {
821
+ const l = Ae();
822
+ n((a) => [...a, { id: l, type: r, message: s, config: d }]), setTimeout(() => {
823
+ n((a) => a.filter((c) => c.id !== l));
824
+ }, f);
824
825
  });
825
826
  }, []);
826
827
  const t = je();
827
- return /* @__PURE__ */ f("div", { className: "fixed top-5 right-5 z-[9999] flex flex-col gap-2", children: e.map((r) => {
828
- var i, d, o, l, b, a, g, x, h, w, S, N, O;
829
- const s = ((i = r.config) == null ? void 0 : i.icon) || ((d = t.icons) == null ? void 0 : d[r.type]) || ze(r.type), p = ((o = r.config) == null ? void 0 : o.bgColor) || ((b = (l = t.colors) == null ? void 0 : l[r.type]) == null ? void 0 : b.bg) || "bg-white dark:bg-gray-800", u = ((a = r.config) == null ? void 0 : a.textColor) || ((x = (g = t.colors) == null ? void 0 : g[r.type]) == null ? void 0 : x.text) || "text-gray-700 dark:text-gray-300", c = ((h = r.config) == null ? void 0 : h.iconContainerClass) || "w-8 h-8 mr-3 text-xl flex items-center justify-center";
828
+ return /* @__PURE__ */ u("div", { className: "fixed top-5 right-5 z-[9999] flex flex-col gap-2", children: e.map((r) => {
829
+ var a, c, o, i, g, b, p, m, h, w, S, N, O;
830
+ const s = ((a = r.config) == null ? void 0 : a.icon) || ((c = t.icons) == null ? void 0 : c[r.type]) || ze(r.type), f = ((o = r.config) == null ? void 0 : o.bgColor) || ((g = (i = t.colors) == null ? void 0 : i[r.type]) == null ? void 0 : g.bg) || "bg-white dark:bg-gray-800", d = ((b = r.config) == null ? void 0 : b.textColor) || ((m = (p = t.colors) == null ? void 0 : p[r.type]) == null ? void 0 : m.text) || "text-gray-700 dark:text-gray-300", l = ((h = r.config) == null ? void 0 : h.iconContainerClass) || "w-8 h-8 mr-3 text-xl flex items-center justify-center";
830
831
  return /* @__PURE__ */ y(
831
832
  "div",
832
833
  {
833
- className: `flex items-center w-full max-w-xs p-4 text-sm rounded-lg shadow ${p} ${u}`,
834
+ className: `flex items-center w-full max-w-xs p-4 text-sm rounded-lg shadow ${f} ${d}`,
834
835
  children: [
835
- /* @__PURE__ */ f("div", { className: c, children: s }),
836
+ /* @__PURE__ */ u("div", { className: l, children: s }),
836
837
  /* @__PURE__ */ y("div", { className: "flex-1 me-3", children: [
837
- ((w = r.config) == null ? void 0 : w.title) && /* @__PURE__ */ f("div", { className: "font-semibold text-black", children: r.config.title }),
838
- ((S = r.config) == null ? void 0 : S.description) && /* @__PURE__ */ f("div", { className: "text-sm text-gray-500", children: r.config.description }),
839
- !((N = r.config) != null && N.title) && !((O = r.config) != null && O.description) && /* @__PURE__ */ f("div", { className: "text-sm", children: r.message })
838
+ ((w = r.config) == null ? void 0 : w.title) && /* @__PURE__ */ u("div", { className: "font-semibold text-black", children: r.config.title }),
839
+ ((S = r.config) == null ? void 0 : S.description) && /* @__PURE__ */ u("div", { className: "text-sm text-gray-500", children: r.config.description }),
840
+ !((N = r.config) != null && N.title) && !((O = r.config) != null && O.description) && /* @__PURE__ */ u("div", { className: "text-sm", children: r.message })
840
841
  ] }),
841
- /* @__PURE__ */ f(
842
+ /* @__PURE__ */ u(
842
843
  "button",
843
844
  {
844
- onClick: () => n((v) => v.filter((m) => m.id !== r.id)),
845
+ onClick: () => n((v) => v.filter((x) => x.id !== r.id)),
845
846
  className: "ml-auto text-gray-400 hover:text-gray-700 dark:text-gray-500 dark:hover:text-white",
846
847
  "aria-label": "Close",
847
- children: /* @__PURE__ */ f(Ie, { size: 18 })
848
+ children: /* @__PURE__ */ u(Ie, { size: 18 })
848
849
  }
849
850
  )
850
851
  ]
@@ -1,10 +1,10 @@
1
- (function(x,n){typeof exports=="object"&&typeof module<"u"?n(exports,require("react/jsx-runtime"),require("react")):typeof define=="function"&&define.amd?define(["exports","react/jsx-runtime","react"],n):(x=typeof globalThis<"u"?globalThis:x||self,n(x.TailwindUiKit={},x.jsxRuntime,x.React))})(this,function(x,n,s){"use strict";"use client";var F=document.createElement("style");F.textContent=`/*! tailwindcss v4.1.10 | MIT License | https://tailwindcss.com */@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-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-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}}@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}
2
- /*$vite$:1*/`,document.head.appendChild(F);const Z={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"},G={flat:"rounded-none",rounded:"rounded-sm",pill:"rounded-full"},R={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"},ee={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"},te=(e,o,t)=>{if(t)return"border-red-500 bg-red-50 text-red-900 placeholder-red-700 focus:ring-red-500 focus:border-red-500";if(o)return"border-green-500 bg-green-50 text-green-900 placeholder-green-700 focus:ring-green-500 focus:border-green-500";switch(e){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"}},q=s.forwardRef((e,o)=>{const{label:t,id:r,inputSize:l="md",shape:b="rounded",validate:p,onValidatedChange:u,className:d="",icon:f,iconPosition:a="left",floatingLabelStyle:c,onChange:h,isValid:i,isInvalid:g,feedback:m,feedbackType:w="invalid",...v}=e,[S,N]=s.useState("default"),$=s.useCallback(M=>{const B=M.target.value,O=(p==null?void 0:p(B))??"default";N(O),u==null||u(M,O),h==null||h(M)},[p,u,h]),k=s.useMemo(()=>r||(typeof t=="string"?`input-${t.toLowerCase().replace(/\s+/g,"-")}`:`input-${Math.random().toString(36).slice(2)}`),[r,t]),y=!!c,C=Z[l]||Z.md,E=G[b]||G.flat,L=s.useMemo(()=>te(S,i,g),[S,i,g]),_=s.useMemo(()=>a==="start"||a==="left"?"left-0 ps-3.5":"right-0 pe-3.5",[a]),D=s.useMemo(()=>f?a==="start"||a==="left"?"ps-10":"pe-10":"",[f,a]);return n.jsxs("div",{className:`w-full relative ${y?"z-0":""} tailwind-ux-input`,children:[!y&&t&&n.jsx("label",{htmlFor:k,className:`block mb-1 text-sm ${i?"text-green-700 dark:text-green-500":g?"text-red-700 dark:text-red-500":"text-gray-700"}`,children:t}),n.jsxs("div",{className:"relative w-full",children:[f&&n.jsx("div",{className:`absolute inset-y-0 flex items-center ${_}`,"aria-hidden":"true",children:n.jsx("span",{className:"text-gray-500",children:f})}),n.jsx("input",{...v,id:k,ref:o,placeholder:y?" ":v.placeholder,onChange:$,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
1
+ (function(w,n){typeof exports=="object"&&typeof module<"u"?n(exports,require("react/jsx-runtime"),require("react")):typeof define=="function"&&define.amd?define(["exports","react/jsx-runtime","react"],n):(w=typeof globalThis<"u"?globalThis:w||self,n(w.TailwindUiKit={},w.jsxRuntime,w.React))})(this,function(w,n,l){"use strict";"use client";var F=document.createElement("style");F.textContent=`/*! tailwindcss v4.1.10 | MIT License | https://tailwindcss.com */@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}}@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}
2
+ /*$vite$:1*/`,document.head.appendChild(F);const Z={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"},G={flat:"rounded-none",rounded:"rounded-sm",pill:"rounded-full"},R={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"},ee={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"},re=(e,t,r)=>{if(r)return"border-red-500 bg-red-50 text-red-900 placeholder-red-700 focus:ring-red-500 focus:border-red-500";if(t)return"border-green-500 bg-green-50 text-green-900 placeholder-green-700 focus:ring-green-500 focus:border-green-500";switch(e){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"}},q=l.forwardRef((e,t)=>{const{label:r,id:o,inputSize:s="md",shape:b="rounded",validate:f,onValidatedChange:i,className:c="",icon:u,iconPosition:a="left",floatingLabelStyle:d,onChange:g,isValid:p,isInvalid:h,feedback:v,feedbackType:m="invalid",...x}=e,[S,N]=l.useState("default"),E=l.useCallback(M=>{const B=M.target.value,O=(f==null?void 0:f(B))??"default";N(O),i==null||i(M,O),g==null||g(M)},[f,i,g]),k=l.useMemo(()=>o||(typeof r=="string"?`input-${r.toLowerCase().replace(/\s+/g,"-")}`:`input-${Math.random().toString(36).slice(2)}`),[o,r]),y=!!d,C=Z[s]||Z.md,$=G[b]||G.flat,L=l.useMemo(()=>re(S,p,h),[S,p,h]),_=l.useMemo(()=>a==="start"||a==="left"?"left-0 ps-3.5":"right-0 pe-3.5",[a]),D=l.useMemo(()=>u?a==="start"||a==="left"?"ps-10":"pe-10":"",[u,a]);return n.jsxs("div",{className:`w-full relative ${y?"z-0":""} tailwind-ux-input`,children:[!y&&r&&n.jsx("label",{htmlFor:k,className:`block mb-1 text-sm ${p?"text-green-700 dark:text-green-500":h?"text-red-700 dark:text-red-500":"text-gray-700"}`,children:r}),n.jsxs("div",{className:"relative w-full",children:[u&&n.jsx("div",{className:`absolute inset-y-0 flex items-center ${_}`,"aria-hidden":"true",children:n.jsx("span",{className:"text-gray-500",children:u})}),n.jsx("input",{...x,id:k,ref:t,placeholder:y?" ":x.placeholder,onChange:E,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
3
  ${C}
4
- ${y&&c&&R[c]}
5
- ${D} ${E} ${L} ${d}`}),y&&t&&c&&n.jsx("label",{htmlFor:k,className:`ms-1 ${ee[c]} ${d}`,children:t})]}),m&&n.jsx("p",{className:`mt-1 text-xs ${w==="invalid"?"text-red-600 dark:text-red-500":"text-green-600 dark:text-green-500"}`,role:w==="invalid"?"alert":void 0,children:m})]})});q.displayName="Input";const re={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"},oe={flat:"rounded-none",rounded:"rounded-sm",pill:"rounded-full"},ne={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"},se={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"},ae=(e,o,t)=>{if(t)return"border-red-500 bg-red-50 text-red-900 focus:ring-red-500 focus:border-red-500";if(o)return"border-green-500 bg-green-50 text-green-900 focus:ring-green-500 focus:border-green-500";const r="focus:ring focus:border";switch(e){case"error":return`${r}-red-500 border-red-500 bg-red-50`;case"warning":return`${r}-yellow-500 border-yellow-500 bg-yellow-50`;case"success":return`${r}-green-500 border-green-500 bg-green-50`;default:return"border-gray-300 focus:ring-blue-500"}},H=s.forwardRef((e,o)=>{const{label:t,id:r,inputSize:l="md",shape:b="rounded",validate:p,onValidatedChange:u,className:d="",icon:f,iconPosition:a="left",floatingLabelStyle:c,onChange:h,isValid:i,isInvalid:g,feedback:m,feedbackType:w="invalid",children:v,...S}=e,[N,$]=s.useState("default"),k=s.useId(),y=s.useMemo(()=>r||(typeof t=="string"?`select-${t.toLowerCase().replace(/\s+/g,"-")}`:k),[r,t,k]),C=O=>{const _e=O.target.value,V=(p==null?void 0:p(_e))??"default";$(V),u==null||u(O,V),h==null||h(O)},E=!!c,L=re[l],_=oe[b],D=ae(N,i,g),M=f&&(a==="start"||a==="left")?"ps-10":f?"pe-10":"",B=a==="start"||a==="left"?"left-0 ps-3.5":"right-0 pe-3.5";return n.jsxs("div",{className:`w-full relative ${E?"z-0":""}`,children:[!E&&t&&n.jsx("label",{htmlFor:y,className:`block mb-1 text-sm ${i?"text-green-700":g?"text-red-700":"text-gray-700"}`,children:t}),n.jsxs("div",{className:"relative w-full",children:[f&&n.jsx("div",{className:`absolute inset-y-0 flex items-center ${B}`,children:n.jsx("span",{className:"text-gray-500",children:f})}),n.jsx("select",{...S,id:y,ref:o,onChange:C,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
4
+ ${y&&d&&R[d]}
5
+ ${D} ${$} ${L} ${c}`}),y&&r&&d&&n.jsx("label",{htmlFor:k,className:`ms-1 ${ee[d]} ${c}`,children:r})]}),v&&n.jsx("p",{className:`mt-1 text-xs ${m==="invalid"?"text-red-600 dark:text-red-500":"text-green-600 dark:text-green-500"}`,role:m==="invalid"?"alert":void 0,children:v})]})});q.displayName="Input";const oe={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"},te={flat:"rounded-none",rounded:"rounded-sm",pill:"rounded-full"},ne={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"},le={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"},ae=(e,t,r)=>{if(r)return"border-red-500 bg-red-50 text-red-900 focus:ring-red-500 focus:border-red-500";if(t)return"border-green-500 bg-green-50 text-green-900 focus:ring-green-500 focus:border-green-500";const o="focus:ring focus:border";switch(e){case"error":return`${o}-red-500 border-red-500 bg-red-50`;case"warning":return`${o}-yellow-500 border-yellow-500 bg-yellow-50`;case"success":return`${o}-green-500 border-green-500 bg-green-50`;default:return"border-gray-300 focus:ring-blue-500"}},H=l.forwardRef((e,t)=>{const{label:r,id:o,inputSize:s="md",shape:b="rounded",validate:f,onValidatedChange:i,className:c="",icon:u,iconPosition:a="left",floatingLabelStyle:d,onChange:g,isValid:p,isInvalid:h,feedback:v,feedbackType:m="invalid",children:x,...S}=e,[N,E]=l.useState("default"),k=l.useId(),y=l.useMemo(()=>o||(typeof r=="string"?`select-${r.toLowerCase().replace(/\s+/g,"-")}`:k),[o,r,k]),C=O=>{const _e=O.target.value,V=(f==null?void 0:f(_e))??"default";E(V),i==null||i(O,V),g==null||g(O)},$=!!d,L=oe[s],_=te[b],D=ae(N,p,h),M=u&&(a==="start"||a==="left")?"ps-10":u?"pe-10":"",B=a==="start"||a==="left"?"left-0 ps-3.5":"right-0 pe-3.5";return n.jsxs("div",{className:`w-full relative ${$?"z-0":""}`,children:[!$&&r&&n.jsx("label",{htmlFor:y,className:`block mb-1 text-sm ${p?"text-green-700":h?"text-red-700":"text-gray-700"}`,children:r}),n.jsxs("div",{className:"relative w-full",children:[u&&n.jsx("div",{className:`absolute inset-y-0 flex items-center ${B}`,children:n.jsx("span",{className:"text-gray-500",children:u})}),n.jsx("select",{...S,id:y,ref:t,onChange:C,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
6
  ${L} ${M}
7
- ${E&&c&&ne[c]}
8
- ${_} ${D} ${d}`,children:v}),E&&t&&c&&n.jsx("label",{htmlFor:y,className:`ms-1 ${se[c]} ${d}`,children:t})]}),m&&n.jsx("p",{className:`mt-1 text-xs ${w==="invalid"?"text-red-600":"text-green-600"}`,children:m})]})});H.displayName="Select";const le={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"},ie={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"},ce={flat:"shadow-none",rounded:"rounded-sm",pill:"rounded-full",circle:"rounded-full w-10 h-10 p-0 flex items-center justify-center"},de=({children:e,variant:o="primary",size:t="md",type:r="button",shape:l="rounded",className:b="",isLoading:p=!1,disabled:u=!1,...d})=>{const f=u||p,a=["inline-flex items-center justify-center font-normal transition duration-150",le[o],ie[t],ce[l],l==="flat"?"shadow-none":"shadow-sm",f?"opacity-50 cursor-not-allowed":"cursor-pointer",b].filter(Boolean).join(" ");return n.jsxs("button",{type:r,className:a,disabled:f,...d,children:[p&&n.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:[n.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"}),n.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"})]}),e]})},ue=({label:e,children:o,position:t="right"})=>{const[r,l]=s.useState(!1),[b,p]=s.useState(!1),u=s.useRef(null),d=s.useRef(null),f=s.useMemo(()=>{switch(t){case"left":return"left-0";case"center":return"left-1/2 transform -translate-x-1/2";case"right":default:return"right-0"}},[t]),a=s.useCallback(i=>{const g=i.target;u.current&&!u.current.contains(g)&&d.current&&!d.current.contains(g)&&l(!1)},[]),c=s.useCallback(()=>{if(!d.current||!u.current)return;const i=d.current.getBoundingClientRect(),g=u.current.getBoundingClientRect(),m=window.innerHeight-i.bottom,w=i.top;p(m<g.height&&w>g.height)},[]);s.useEffect(()=>{if(r)return c(),window.addEventListener("resize",c),window.addEventListener("scroll",c,!0),()=>{window.removeEventListener("resize",c),window.removeEventListener("scroll",c,!0)}},[r,c]),s.useEffect(()=>(document.addEventListener("mousedown",a),()=>document.removeEventListener("mousedown",a)),[a]);const h=s.useCallback(()=>l(i=>!i),[]);return n.jsxs("div",{className:"relative flex items-center",children:[n.jsx("button",{ref:d,onClick:h,children:e}),r&&n.jsx("div",{ref:u,className:`absolute z-10 bg-white rounded-sm shadow-md overflow-hidden
7
+ ${$&&d&&ne[d]}
8
+ ${_} ${D} ${c}`,children:x}),$&&r&&d&&n.jsx("label",{htmlFor:y,className:`ms-1 ${le[d]} ${c}`,children:r})]}),v&&n.jsx("p",{className:`mt-1 text-xs ${m==="invalid"?"text-red-600":"text-green-600"}`,children:v})]})});H.displayName="Select";const se={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"},ce={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"},ie={flat:"shadow-none",rounded:"rounded-sm",pill:"rounded-full",circle:"rounded-full w-10 h-10 p-0 flex items-center justify-center"},de=({children:e,variant:t="primary",size:r="md",type:o="button",shape:s="rounded",className:b="",isLoading:f=!1,disabled:i=!1,...c})=>{const u=i||f,a=["inline-flex items-center justify-center font-normal transition duration-150",se[t],ce[r],ie[s],s==="flat"?"shadow-none":"shadow-sm",u?"opacity-50 cursor-not-allowed":"cursor-pointer",b].filter(Boolean).join(" ");return n.jsxs("button",{type:o,className:a,disabled:u,...c,children:[f&&n.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:[n.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"}),n.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"})]}),e]})},ue=({label:e,children:t,position:r="right"})=>{const[o,s]=l.useState(!1),[b,f]=l.useState(!1),i=l.useRef(null),c=l.useRef(null),u=l.useMemo(()=>{switch(r){case"left":return"left-0";case"center":return"left-1/2 transform -translate-x-1/2";case"right":default:return"right-0"}},[r]),a=l.useCallback(p=>{const h=p.target;i.current&&!i.current.contains(h)&&c.current&&!c.current.contains(h)&&s(!1)},[]),d=l.useCallback(()=>{if(!c.current||!i.current)return;const p=c.current.getBoundingClientRect(),h=i.current.getBoundingClientRect(),v=window.innerHeight-p.bottom,m=p.top;f(v<h.height&&m>h.height)},[]);l.useEffect(()=>{if(o)return d(),window.addEventListener("resize",d),window.addEventListener("scroll",d,!0),()=>{window.removeEventListener("resize",d),window.removeEventListener("scroll",d,!0)}},[o,d]),l.useEffect(()=>(document.addEventListener("mousedown",a),()=>document.removeEventListener("mousedown",a)),[a]);const g=l.useCallback(()=>s(p=>!p),[]);return n.jsxs("div",{className:"relative flex items-center",children:[n.jsx("button",{ref:c,onClick:g,children:e}),o&&n.jsx("div",{ref:i,className:`absolute z-10 bg-white rounded-sm shadow-md overflow-hidden
9
9
  ${b?"bottom-full mb-2":"top-full mt-2"}
10
- ${f}`,children:o})]})},fe=({children:e,content:o,position:t="top",className:r="",tooltipClass:l="",tooltipStyle:b={}})=>{const p=s.useRef(null),u=s.useRef(null);s.useEffect(()=>{const f=p.current,a=u.current;if(!f||!a)return;const c=()=>{a.style.opacity="1",a.style.visibility="visible"},h=()=>{a.style.opacity="0",a.style.visibility="hidden"};return f.addEventListener("mouseenter",c),f.addEventListener("mouseleave",h),()=>{f.removeEventListener("mouseenter",c),f.removeEventListener("mouseleave",h)}},[]);const d=f=>{const a={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(f){case"top":return{...a,bottom:"100%",left:"50%",transform:"translateX(-50%)",marginBottom:"8px"};case"bottom":return{...a,top:"100%",left:"50%",transform:"translateX(-50%)",marginTop:"8px"};case"left":return{...a,right:"100%",top:"50%",transform:"translateY(-50%)",marginRight:"8px"};case"right":return{...a,left:"100%",top:"50%",transform:"translateY(-50%)",marginLeft:"8px"};default:return a}};return n.jsxs("div",{ref:p,className:`relative inline-block ${r}`,children:[e,n.jsx("div",{ref:u,role:"tooltip",className:l,style:{...d(t),...b},children:o})]})},pe={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"},be={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"},ge={flat:"rounded-none",rounded:"rounded-sm",pill:"rounded-full",circle:"rounded-full p-2 w-8 h-8 justify-center"},he=({label:e,variant:o="primary",size:t="sm",shape:r="rounded",icon:l,dismissible:b,onDismiss:p,className:u="",...d})=>{const f=!e&&!!l,a=`inline-flex items-center font-medium ${pe[o]||""} ${be[t]||""} ${ge[r]||""} ${f?"justify-center p-2 w-8 h-8":""} `+u;return n.jsxs("span",{className:a.trim(),...d,children:[l&&n.jsx("span",{className:e?"mr-1":"",children:l}),e,b&&n.jsx("button",{type:"button",onClick:p,className:"ml-2 text-xs font-bold leading-none focus:outline-none",children:"×"})]})};var K={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},U=s.createContext&&s.createContext(K),ye=["attr","size","title"];function xe(e,o){if(e==null)return{};var t=me(e,o),r,l;if(Object.getOwnPropertySymbols){var b=Object.getOwnPropertySymbols(e);for(l=0;l<b.length;l++)r=b[l],!(o.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(t[r]=e[r])}return t}function me(e,o){if(e==null)return{};var t={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(o.indexOf(r)>=0)continue;t[r]=e[r]}return t}function P(){return P=Object.assign?Object.assign.bind():function(e){for(var o=1;o<arguments.length;o++){var t=arguments[o];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},P.apply(this,arguments)}function W(e,o){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);o&&(r=r.filter(function(l){return Object.getOwnPropertyDescriptor(e,l).enumerable})),t.push.apply(t,r)}return t}function j(e){for(var o=1;o<arguments.length;o++){var t=arguments[o]!=null?arguments[o]:{};o%2?W(Object(t),!0).forEach(function(r){we(e,r,t[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):W(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))})}return e}function we(e,o,t){return o=ve(o),o in e?Object.defineProperty(e,o,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[o]=t,e}function ve(e){var o=ke(e,"string");return typeof o=="symbol"?o:o+""}function ke(e,o){if(typeof e!="object"||!e)return e;var t=e[Symbol.toPrimitive];if(t!==void 0){var r=t.call(e,o);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(o==="string"?String:Number)(e)}function X(e){return e&&e.map((o,t)=>s.createElement(o.tag,j({key:t},o.attr),X(o.child)))}function Y(e){return o=>s.createElement(Ce,P({attr:j({},e.attr)},o),X(e.child))}function Ce(e){var o=t=>{var{attr:r,size:l,title:b}=e,p=xe(e,ye),u=l||t.size||"1em",d;return t.className&&(d=t.className),e.className&&(d=(d?d+" ":"")+e.className),s.createElement("svg",P({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},t.attr,r,p,{className:d,style:j(j({color:e.color||t.color},t.style),e.style),height:u,width:u,xmlns:"http://www.w3.org/2000/svg"}),b&&s.createElement("title",null,b),e.children)};return U!==void 0?s.createElement(U.Consumer,null,t=>o(t)):o(K)}function Se(e){return Y({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:[]}]})(e)}const Ne=({items:e,allowMultipleOpen:o=!1,className:t="",tileClasses:r="",open:l,onChange:b,renderTitle:p,renderContent:u,showArrowIcon:d=!0})=>{const[f,a]=s.useState(new Set),c=s.useMemo(()=>l?new Set(l):f,[l,f]),h=s.useCallback(i=>{const g=new Set(c);g.has(i)?g.delete(i):(o||g.clear(),g.add(i)),l&&b?b(Array.from(g)):a(g)},[c,l,b,o]);return n.jsx("div",{className:"accordion",role:"region","aria-multiselectable":o,children:e.map(i=>{const g=c.has(i.id),m=`accordion-heading-${i.id}`,w=`accordion-panel-${i.id}`;return n.jsxs("div",{className:`accordion-item border rounded border-gray-300 dark:border-gray-700 ${t}`,children:[n.jsxs("button",{id:m,type:"button","aria-expanded":g,"aria-controls":w,onClick:()=>h(i.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 ${r}`,children:[p?p(i,g):i.title,d?n.jsx(Se,{}):null]}),n.jsx("div",{id:w,role:"region","aria-labelledby":m,hidden:!g,className:"p-4 border-t border-gray-200 dark:border-gray-700 text-gray-600 dark:text-gray-400",children:u?u(i,g):i.content})]},i.id)})})},J=s.createContext(null),I=()=>{const e=s.useContext(J);if(!e)throw new Error("useModalActions must be used within a ModalActionProvider");return e},Q=s.createContext(null),T=()=>s.useContext(Q);function Ee({id:e,title:o,children:t,standalone:r=!1,showFloatingClose:l=!1,containerClasses:b="",onClose:p,disableEscapeClose:u=!1}){const d=T(),f=I(),a=!r&&!!d&&!!f,[c,h]=s.useState(!1),i=a?d.isOpen(e):c,g=a?d.getModalData(e):null,m=s.useCallback(()=>{a?f.closeModal(e):h(!1),p==null||p()},[a,f,e,p]);return s.useEffect(()=>{const w=document.activeElement;console.log(e);const v=document.getElementById(e);console.log("modalEl=",v);const S=["a[href]","button:not([disabled])","textarea:not([disabled])","input:not([disabled])","select:not([disabled])",'[tabindex]:not([tabindex="-1"])'],N=()=>{if(!v)return[];const y=v.querySelectorAll(S.join(","));return Array.from(y).filter(C=>C.offsetParent!==null)},$=y=>{if(y.key==="Tab"){const C=N();if(C.length===0)return;const E=C[0],L=C[C.length-1];y.shiftKey?document.activeElement===E&&(y.preventDefault(),L.focus()):document.activeElement===L&&(y.preventDefault(),E.focus())}},k=y=>{y.key==="Escape"&&!u&&m(),$(y)};return i&&(document.body.style.overflow="hidden",setTimeout(()=>{const y=N();y.length&&y[0].focus()},0),window.addEventListener("keydown",k)),()=>{document.body.style.overflow="",w&&w.focus(),window.removeEventListener("keydown",k)}},[i,u,m,e]),i?n.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/60 backdrop-blur-[2px]",id:e,children:n.jsxs("div",{className:`bg-white rounded-lg shadow-lg w-full max-w-md p-4 transform transition-all duration-300 scale-100 ${b}`,children:[n.jsxs("div",{className:"flex justify-between items-center relative",children:[o&&n.jsx("h2",{className:"text-lg font-semibold",children:o}),l&&n.jsx("button",{onClick:m,className:"text-gray-500 hover:text-black absolute top-2 right-3 hover:bg-gray-200 rounded-full aspect-square w-8","aria-label":"Close modal",children:"✕"})]}),n.jsx("div",{className:"mt-3 text-sm text-gray-700",children:typeof t=="function"?t({modalData:g}):t})]})}):null}function $e({children:e}){const[o,t]=s.useState({}),[r,l]=s.useState({}),b=s.useCallback((c,h)=>{t(i=>({...i,[c]:!0})),h&&l(i=>({...i,[c]:h}))},[]),p=s.useCallback(c=>{t(h=>({...h,[c]:!1})),l(h=>{const i={...h};return delete i[c],i})},[]),u=s.useCallback(c=>!!o[c],[o]),d=s.useCallback(c=>r[c],[r]),f=s.useMemo(()=>({openModal:b,closeModal:p}),[b,p]),a=s.useMemo(()=>({isOpen:u,getModalData:d}),[u,d]);return n.jsx(J.Provider,{value:f,children:n.jsx(Q.Provider,{value:a,children:e})})}function Le(e){const{openModal:o,closeModal:t}=I(),{isOpen:r,getModalData:l}=T();return{open:b=>o(e,b),close:()=>t(e),isOpen:r(e),data:l(e)}}let A=null,z={};function Oe(e){A=e}function Me(e){z={...z,...e}}function Pe(){return z}function je(e,o,t=3e3,r){A?A(e,o,t,r):console.warn("Toast system is not mounted")}function Ie(e){return Y({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:[]}]})(e)}const Te=()=>"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){const o=Math.random()*16|0;return(e==="x"?o:o&3|8).toString(16)}),Ae=()=>{const[e,o]=s.useState([]);s.useEffect(()=>{Oe((r,l,b,p)=>{const u=Te();o(d=>[...d,{id:u,type:r,message:l,config:p}]),setTimeout(()=>{o(d=>d.filter(f=>f.id!==u))},b)})},[]);const t=Pe();return n.jsx("div",{className:"fixed top-5 right-5 z-[9999] flex flex-col gap-2",children:e.map(r=>{var d,f,a,c,h,i,g,m,w,v,S,N,$;const l=((d=r.config)==null?void 0:d.icon)||((f=t.icons)==null?void 0:f[r.type])||ze(r.type),b=((a=r.config)==null?void 0:a.bgColor)||((h=(c=t.colors)==null?void 0:c[r.type])==null?void 0:h.bg)||"bg-white dark:bg-gray-800",p=((i=r.config)==null?void 0:i.textColor)||((m=(g=t.colors)==null?void 0:g[r.type])==null?void 0:m.text)||"text-gray-700 dark:text-gray-300",u=((w=r.config)==null?void 0:w.iconContainerClass)||"w-8 h-8 mr-3 text-xl flex items-center justify-center";return n.jsxs("div",{className:`flex items-center w-full max-w-xs p-4 text-sm rounded-lg shadow ${b} ${p}`,children:[n.jsx("div",{className:u,children:l}),n.jsxs("div",{className:"flex-1 me-3",children:[((v=r.config)==null?void 0:v.title)&&n.jsx("div",{className:"font-semibold text-black",children:r.config.title}),((S=r.config)==null?void 0:S.description)&&n.jsx("div",{className:"text-sm text-gray-500",children:r.config.description}),!((N=r.config)!=null&&N.title)&&!(($=r.config)!=null&&$.description)&&n.jsx("div",{className:"text-sm",children:r.message})]}),n.jsx("button",{onClick:()=>o(k=>k.filter(y=>y.id!==r.id)),className:"ml-auto text-gray-400 hover:text-gray-700 dark:text-gray-500 dark:hover:text-white","aria-label":"Close",children:n.jsx(Ie,{size:18})})]},r.id)})})};function ze(e){switch(e){case"success":return"✅";case"error":return"❌";case"warning":return"⚠️";case"info":return"ℹ️"}}x.Accordion=Ne,x.Badge=he,x.Button=de,x.Dropdown=ue,x.Input=q,x.Modal=Ee,x.ModalProvider=$e,x.Select=H,x.Toast=Ae,x.Tooltip=fe,x.setToastDefaults=Me,x.showToast=je,x.useModalActions=I,x.useModalInstance=Le,x.useModalState=T,Object.defineProperty(x,Symbol.toStringTag,{value:"Module"})});
10
+ ${u}`,children:t})]})},fe=({children:e,content:t,position:r="top",className:o="",tooltipClass:s="",tooltipStyle:b={}})=>{const f=l.useRef(null),i=l.useRef(null);l.useEffect(()=>{const u=f.current,a=i.current;if(!u||!a)return;const d=()=>{a.style.opacity="1",a.style.visibility="visible"},g=()=>{a.style.opacity="0",a.style.visibility="hidden"};return u.addEventListener("mouseenter",d),u.addEventListener("mouseleave",g),()=>{u.removeEventListener("mouseenter",d),u.removeEventListener("mouseleave",g)}},[]);const c=u=>{const a={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(u){case"top":return{...a,bottom:"100%",left:"50%",transform:"translateX(-50%)",marginBottom:"8px"};case"bottom":return{...a,top:"100%",left:"50%",transform:"translateX(-50%)",marginTop:"8px"};case"left":return{...a,right:"100%",top:"50%",transform:"translateY(-50%)",marginRight:"8px"};case"right":return{...a,left:"100%",top:"50%",transform:"translateY(-50%)",marginLeft:"8px"};default:return a}};return n.jsxs("div",{ref:f,className:`relative inline-block ${o}`,children:[e,n.jsx("div",{ref:i,role:"tooltip",className:s,style:{...c(r),...b},children:t})]})},be={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"},he={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"},ge={flat:"rounded-none",rounded:"rounded-sm",pill:"rounded-full",circle:"rounded-full p-2 w-8 h-8 justify-center"},pe=({label:e,variant:t="primary",size:r="sm",shape:o="rounded",icon:s,dismissible:b,onDismiss:f,className:i="",...c})=>{const u=!e&&!!s,a=`inline-flex items-center font-medium ${be[t]||""} ${he[r]||""} ${ge[o]||""} ${u?"justify-center p-2 w-8 h-8":""} `+i;return n.jsxs("span",{className:a.trim(),...c,children:[s&&n.jsx("span",{className:e?"mr-1":"",children:s}),e,b&&n.jsx("button",{type:"button",onClick:f,className:"ml-2 text-xs font-bold leading-none focus:outline-none",children:"×"})]})};var K={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},U=l.createContext&&l.createContext(K),ve=["attr","size","title"];function ye(e,t){if(e==null)return{};var r=we(e,t),o,s;if(Object.getOwnPropertySymbols){var b=Object.getOwnPropertySymbols(e);for(s=0;s<b.length;s++)o=b[s],!(t.indexOf(o)>=0)&&Object.prototype.propertyIsEnumerable.call(e,o)&&(r[o]=e[o])}return r}function we(e,t){if(e==null)return{};var r={};for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){if(t.indexOf(o)>=0)continue;r[o]=e[o]}return r}function P(){return P=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(e[o]=r[o])}return e},P.apply(this,arguments)}function W(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable})),r.push.apply(r,o)}return r}function j(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?W(Object(r),!0).forEach(function(o){me(e,o,r[o])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):W(Object(r)).forEach(function(o){Object.defineProperty(e,o,Object.getOwnPropertyDescriptor(r,o))})}return e}function me(e,t,r){return t=xe(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function xe(e){var t=ke(e,"string");return typeof t=="symbol"?t:t+""}function ke(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var o=r.call(e,t);if(typeof o!="object")return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function X(e){return e&&e.map((t,r)=>l.createElement(t.tag,j({key:r},t.attr),X(t.child)))}function Y(e){return t=>l.createElement(Ce,P({attr:j({},e.attr)},t),X(e.child))}function Ce(e){var t=r=>{var{attr:o,size:s,title:b}=e,f=ye(e,ve),i=s||r.size||"1em",c;return r.className&&(c=r.className),e.className&&(c=(c?c+" ":"")+e.className),l.createElement("svg",P({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},r.attr,o,f,{className:c,style:j(j({color:e.color||r.color},r.style),e.style),height:i,width:i,xmlns:"http://www.w3.org/2000/svg"}),b&&l.createElement("title",null,b),e.children)};return U!==void 0?l.createElement(U.Consumer,null,r=>t(r)):t(K)}function Se(e){return Y({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:[]}]})(e)}const Ne=({items:e,allowMultipleOpen:t=!1,className:r="",tileClasses:o="",open:s,onChange:b,renderTitle:f,renderContent:i,showArrowIcon:c=!0,panelClasses:u=""})=>{const[a,d]=l.useState(new Set),g=l.useMemo(()=>s?new Set(s):a,[s,a]),p=l.useCallback(h=>{const v=new Set(g);v.has(h)?v.delete(h):(t||v.clear(),v.add(h)),s&&b?b(Array.from(v)):d(v)},[g,s,b,t]);return n.jsx("div",{className:"accordion",role:"region","aria-multiselectable":t,children:e.map(h=>{const v=g.has(h.id),m=`accordion-heading-${h.id}`,x=`accordion-panel-${h.id}`;return n.jsxs("div",{className:`accordion-item border rounded border-gray-300 dark:border-gray-700 ${r}`,children:[n.jsxs("button",{id:m,type:"button","aria-expanded":v,"aria-controls":x,onClick:()=>p(h.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 ${o}`,children:[f?f(h,v):h.title,c?n.jsx(Se,{}):null]}),n.jsx("div",{id:x,role:"region","aria-labelledby":m,hidden:!v,className:`p-4 border-t border-gray-200 dark:border-gray-700 text-gray-600 dark:text-gray-400 ${u}`,children:i?i(h,v):h.content})]},h.id)})})},J=l.createContext(null),I=()=>{const e=l.useContext(J);if(!e)throw new Error("useModalActions must be used within a ModalActionProvider");return e},Q=l.createContext(null),T=()=>l.useContext(Q);function $e({id:e,title:t,children:r,standalone:o=!1,showFloatingClose:s=!1,containerClasses:b="",onClose:f,disableEscapeClose:i=!1}){const c=T(),u=I(),a=!o&&!!c&&!!u,[d,g]=l.useState(!1),p=a?c.isOpen(e):d,h=a?c.getModalData(e):null,v=l.useCallback(()=>{a?u.closeModal(e):g(!1),f==null||f()},[a,u,e,f]);return l.useEffect(()=>{const m=document.activeElement;console.log(e);const x=document.getElementById(e);console.log("modalEl=",x);const S=["a[href]","button:not([disabled])","textarea:not([disabled])","input:not([disabled])","select:not([disabled])",'[tabindex]:not([tabindex="-1"])'],N=()=>{if(!x)return[];const y=x.querySelectorAll(S.join(","));return Array.from(y).filter(C=>C.offsetParent!==null)},E=y=>{if(y.key==="Tab"){const C=N();if(C.length===0)return;const $=C[0],L=C[C.length-1];y.shiftKey?document.activeElement===$&&(y.preventDefault(),L.focus()):document.activeElement===L&&(y.preventDefault(),$.focus())}},k=y=>{y.key==="Escape"&&!i&&v(),E(y)};return p&&(document.body.style.overflow="hidden",setTimeout(()=>{const y=N();y.length&&y[0].focus()},0),window.addEventListener("keydown",k)),()=>{document.body.style.overflow="",m&&m.focus(),window.removeEventListener("keydown",k)}},[p,i,v,e]),p?n.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/60 backdrop-blur-[2px]",id:e,children:n.jsxs("div",{className:`bg-white rounded-lg shadow-lg w-full max-w-md p-4 transform transition-all duration-300 scale-100 ${b}`,children:[n.jsxs("div",{className:"flex justify-between items-center relative",children:[t&&n.jsx("h2",{className:"text-lg font-semibold",children:t}),s&&n.jsx("button",{onClick:v,className:"text-gray-500 hover:text-black absolute top-2 right-3 hover:bg-gray-200 rounded-full aspect-square w-8","aria-label":"Close modal",children:"✕"})]}),n.jsx("div",{className:"mt-3 text-sm text-gray-700",children:typeof r=="function"?r({modalData:h}):r})]})}):null}function Ee({children:e}){const[t,r]=l.useState({}),[o,s]=l.useState({}),b=l.useCallback((d,g)=>{r(p=>({...p,[d]:!0})),g&&s(p=>({...p,[d]:g}))},[]),f=l.useCallback(d=>{r(g=>({...g,[d]:!1})),s(g=>{const p={...g};return delete p[d],p})},[]),i=l.useCallback(d=>!!t[d],[t]),c=l.useCallback(d=>o[d],[o]),u=l.useMemo(()=>({openModal:b,closeModal:f}),[b,f]),a=l.useMemo(()=>({isOpen:i,getModalData:c}),[i,c]);return n.jsx(J.Provider,{value:u,children:n.jsx(Q.Provider,{value:a,children:e})})}function Le(e){const{openModal:t,closeModal:r}=I(),{isOpen:o,getModalData:s}=T();return{open:b=>t(e,b),close:()=>r(e),isOpen:o(e),data:s(e)}}let A=null,z={};function Oe(e){A=e}function Me(e){z={...z,...e}}function Pe(){return z}function je(e,t,r=3e3,o){A?A(e,t,r,o):console.warn("Toast system is not mounted")}function Ie(e){return Y({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:[]}]})(e)}const Te=()=>"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){const t=Math.random()*16|0;return(e==="x"?t:t&3|8).toString(16)}),Ae=()=>{const[e,t]=l.useState([]);l.useEffect(()=>{Oe((o,s,b,f)=>{const i=Te();t(c=>[...c,{id:i,type:o,message:s,config:f}]),setTimeout(()=>{t(c=>c.filter(u=>u.id!==i))},b)})},[]);const r=Pe();return n.jsx("div",{className:"fixed top-5 right-5 z-[9999] flex flex-col gap-2",children:e.map(o=>{var c,u,a,d,g,p,h,v,m,x,S,N,E;const s=((c=o.config)==null?void 0:c.icon)||((u=r.icons)==null?void 0:u[o.type])||ze(o.type),b=((a=o.config)==null?void 0:a.bgColor)||((g=(d=r.colors)==null?void 0:d[o.type])==null?void 0:g.bg)||"bg-white dark:bg-gray-800",f=((p=o.config)==null?void 0:p.textColor)||((v=(h=r.colors)==null?void 0:h[o.type])==null?void 0:v.text)||"text-gray-700 dark:text-gray-300",i=((m=o.config)==null?void 0:m.iconContainerClass)||"w-8 h-8 mr-3 text-xl flex items-center justify-center";return n.jsxs("div",{className:`flex items-center w-full max-w-xs p-4 text-sm rounded-lg shadow ${b} ${f}`,children:[n.jsx("div",{className:i,children:s}),n.jsxs("div",{className:"flex-1 me-3",children:[((x=o.config)==null?void 0:x.title)&&n.jsx("div",{className:"font-semibold text-black",children:o.config.title}),((S=o.config)==null?void 0:S.description)&&n.jsx("div",{className:"text-sm text-gray-500",children:o.config.description}),!((N=o.config)!=null&&N.title)&&!((E=o.config)!=null&&E.description)&&n.jsx("div",{className:"text-sm",children:o.message})]}),n.jsx("button",{onClick:()=>t(k=>k.filter(y=>y.id!==o.id)),className:"ml-auto text-gray-400 hover:text-gray-700 dark:text-gray-500 dark:hover:text-white","aria-label":"Close",children:n.jsx(Ie,{size:18})})]},o.id)})})};function ze(e){switch(e){case"success":return"✅";case"error":return"❌";case"warning":return"⚠️";case"info":return"ℹ️"}}w.Accordion=Ne,w.Badge=pe,w.Button=de,w.Dropdown=ue,w.Input=q,w.Modal=$e,w.ModalProvider=Ee,w.Select=H,w.Toast=Ae,w.Tooltip=fe,w.setToastDefaults=Me,w.showToast=je,w.useModalActions=I,w.useModalInstance=Le,w.useModalState=T,Object.defineProperty(w,Symbol.toStringTag,{value:"Module"})});
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tailwind-ux-kit",
3
- "version": "1.0.52",
3
+ "version": "1.0.54",
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",