@stackloop/ui 2.3.0 → 2.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +29 -1
- package/dist/FloatingActionButton.d.ts +2 -0
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +364 -351
- package/dist/index.js.map +1 -1
- package/dist/stackloop-ui.css +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -6,13 +6,13 @@ function Be(e) {
|
|
|
6
6
|
var t, a, o = "";
|
|
7
7
|
if (typeof e == "string" || typeof e == "number") o += e;
|
|
8
8
|
else if (typeof e == "object") if (Array.isArray(e)) {
|
|
9
|
-
var
|
|
10
|
-
for (t = 0; t <
|
|
9
|
+
var s = e.length;
|
|
10
|
+
for (t = 0; t < s; t++) e[t] && (a = Be(e[t])) && (o && (o += " "), o += a);
|
|
11
11
|
} else for (a in e) e[a] && (o && (o += " "), o += a);
|
|
12
12
|
return o;
|
|
13
13
|
}
|
|
14
14
|
function Nr() {
|
|
15
|
-
for (var e, t, a = 0, o = "",
|
|
15
|
+
for (var e, t, a = 0, o = "", s = arguments.length; a < s; a++) (e = arguments[a]) && (t = Be(e)) && (o && (o += " "), o += t);
|
|
16
16
|
return o;
|
|
17
17
|
}
|
|
18
18
|
const kr = (e, t) => {
|
|
@@ -35,34 +35,34 @@ const kr = (e, t) => {
|
|
|
35
35
|
conflictingClassGroupModifiers: o
|
|
36
36
|
} = e;
|
|
37
37
|
return {
|
|
38
|
-
getClassGroupId: (
|
|
39
|
-
if (
|
|
40
|
-
return Tr(
|
|
41
|
-
const c =
|
|
38
|
+
getClassGroupId: (n) => {
|
|
39
|
+
if (n.startsWith("[") && n.endsWith("]"))
|
|
40
|
+
return Tr(n);
|
|
41
|
+
const c = n.split(ue), i = c[0] === "" && c.length > 1 ? 1 : 0;
|
|
42
42
|
return $e(c, i, t);
|
|
43
43
|
},
|
|
44
|
-
getConflictingClassGroupIds: (
|
|
44
|
+
getConflictingClassGroupIds: (n, c) => {
|
|
45
45
|
if (c) {
|
|
46
|
-
const i = o[
|
|
46
|
+
const i = o[n], m = a[n];
|
|
47
47
|
return i ? m ? kr(m, i) : i : m || Re;
|
|
48
48
|
}
|
|
49
|
-
return a[
|
|
49
|
+
return a[n] || Re;
|
|
50
50
|
}
|
|
51
51
|
};
|
|
52
52
|
}, $e = (e, t, a) => {
|
|
53
53
|
if (e.length - t === 0)
|
|
54
54
|
return a.classGroupId;
|
|
55
|
-
const
|
|
55
|
+
const s = e[t], l = a.nextPart.get(s);
|
|
56
56
|
if (l) {
|
|
57
57
|
const m = $e(e, t + 1, l);
|
|
58
58
|
if (m) return m;
|
|
59
59
|
}
|
|
60
|
-
const
|
|
61
|
-
if (
|
|
60
|
+
const n = a.validators;
|
|
61
|
+
if (n === null)
|
|
62
62
|
return;
|
|
63
|
-
const c = t === 0 ? e.join(ue) : e.slice(t).join(ue), i =
|
|
63
|
+
const c = t === 0 ? e.join(ue) : e.slice(t).join(ue), i = n.length;
|
|
64
64
|
for (let m = 0; m < i; m++) {
|
|
65
|
-
const x =
|
|
65
|
+
const x = n[m];
|
|
66
66
|
if (x.validator(c))
|
|
67
67
|
return x.classGroupId;
|
|
68
68
|
}
|
|
@@ -78,15 +78,15 @@ const kr = (e, t) => {
|
|
|
78
78
|
}, Rr = (e, t) => {
|
|
79
79
|
const a = Ue();
|
|
80
80
|
for (const o in e) {
|
|
81
|
-
const
|
|
82
|
-
we(
|
|
81
|
+
const s = e[o];
|
|
82
|
+
we(s, a, o, t);
|
|
83
83
|
}
|
|
84
84
|
return a;
|
|
85
85
|
}, we = (e, t, a, o) => {
|
|
86
|
-
const
|
|
87
|
-
for (let l = 0; l <
|
|
88
|
-
const
|
|
89
|
-
Ar(
|
|
86
|
+
const s = e.length;
|
|
87
|
+
for (let l = 0; l < s; l++) {
|
|
88
|
+
const n = e[l];
|
|
89
|
+
Ar(n, t, a, o);
|
|
90
90
|
}
|
|
91
91
|
}, Ar = (e, t, a, o) => {
|
|
92
92
|
if (typeof e == "string") {
|
|
@@ -108,18 +108,18 @@ const kr = (e, t) => {
|
|
|
108
108
|
}
|
|
109
109
|
t.validators === null && (t.validators = []), t.validators.push(Cr(a, e));
|
|
110
110
|
}, Dr = (e, t, a, o) => {
|
|
111
|
-
const
|
|
112
|
-
for (let
|
|
113
|
-
const [c, i] = n
|
|
111
|
+
const s = Object.entries(e), l = s.length;
|
|
112
|
+
for (let n = 0; n < l; n++) {
|
|
113
|
+
const [c, i] = s[n];
|
|
114
114
|
we(i, _e(t, c), a, o);
|
|
115
115
|
}
|
|
116
116
|
}, _e = (e, t) => {
|
|
117
117
|
let a = e;
|
|
118
|
-
const o = t.split(ue),
|
|
119
|
-
for (let l = 0; l <
|
|
120
|
-
const
|
|
121
|
-
let c = a.nextPart.get(
|
|
122
|
-
c || (c = Ue(), a.nextPart.set(
|
|
118
|
+
const o = t.split(ue), s = o.length;
|
|
119
|
+
for (let l = 0; l < s; l++) {
|
|
120
|
+
const n = o[l];
|
|
121
|
+
let c = a.nextPart.get(n);
|
|
122
|
+
c || (c = Ue(), a.nextPart.set(n, c)), a = c;
|
|
123
123
|
}
|
|
124
124
|
return a;
|
|
125
125
|
}, Lr = (e) => "isThemeGetter" in e && e.isThemeGetter === !0, Or = (e) => {
|
|
@@ -131,71 +131,71 @@ const kr = (e, t) => {
|
|
|
131
131
|
}
|
|
132
132
|
};
|
|
133
133
|
let t = 0, a = /* @__PURE__ */ Object.create(null), o = /* @__PURE__ */ Object.create(null);
|
|
134
|
-
const
|
|
135
|
-
a[l] =
|
|
134
|
+
const s = (l, n) => {
|
|
135
|
+
a[l] = n, t++, t > e && (t = 0, o = a, a = /* @__PURE__ */ Object.create(null));
|
|
136
136
|
};
|
|
137
137
|
return {
|
|
138
138
|
get(l) {
|
|
139
|
-
let
|
|
140
|
-
if (
|
|
141
|
-
return
|
|
142
|
-
if ((
|
|
143
|
-
return
|
|
139
|
+
let n = a[l];
|
|
140
|
+
if (n !== void 0)
|
|
141
|
+
return n;
|
|
142
|
+
if ((n = o[l]) !== void 0)
|
|
143
|
+
return s(l, n), n;
|
|
144
144
|
},
|
|
145
|
-
set(l,
|
|
146
|
-
l in a ? a[l] =
|
|
145
|
+
set(l, n) {
|
|
146
|
+
l in a ? a[l] = n : s(l, n);
|
|
147
147
|
}
|
|
148
148
|
};
|
|
149
|
-
}, ye = "!", Ae = ":", Er = [], Ie = (e, t, a, o,
|
|
149
|
+
}, ye = "!", Ae = ":", Er = [], Ie = (e, t, a, o, s) => ({
|
|
150
150
|
modifiers: e,
|
|
151
151
|
hasImportantModifier: t,
|
|
152
152
|
baseClassName: a,
|
|
153
153
|
maybePostfixModifierPosition: o,
|
|
154
|
-
isExternal:
|
|
154
|
+
isExternal: s
|
|
155
155
|
}), Fr = (e) => {
|
|
156
156
|
const {
|
|
157
157
|
prefix: t,
|
|
158
158
|
experimentalParseClassName: a
|
|
159
159
|
} = e;
|
|
160
|
-
let o = (
|
|
160
|
+
let o = (s) => {
|
|
161
161
|
const l = [];
|
|
162
|
-
let
|
|
163
|
-
const x =
|
|
164
|
-
for (let
|
|
165
|
-
const M =
|
|
166
|
-
if (
|
|
162
|
+
let n = 0, c = 0, i = 0, m;
|
|
163
|
+
const x = s.length;
|
|
164
|
+
for (let v = 0; v < x; v++) {
|
|
165
|
+
const M = s[v];
|
|
166
|
+
if (n === 0 && c === 0) {
|
|
167
167
|
if (M === Ae) {
|
|
168
|
-
l.push(
|
|
168
|
+
l.push(s.slice(i, v)), i = v + 1;
|
|
169
169
|
continue;
|
|
170
170
|
}
|
|
171
171
|
if (M === "/") {
|
|
172
|
-
m =
|
|
172
|
+
m = v;
|
|
173
173
|
continue;
|
|
174
174
|
}
|
|
175
175
|
}
|
|
176
|
-
M === "[" ?
|
|
176
|
+
M === "[" ? n++ : M === "]" ? n-- : M === "(" ? c++ : M === ")" && c--;
|
|
177
177
|
}
|
|
178
|
-
const y = l.length === 0 ?
|
|
179
|
-
let h = y,
|
|
180
|
-
y.endsWith(ye) ? (h = y.slice(0, -1),
|
|
178
|
+
const y = l.length === 0 ? s : s.slice(i);
|
|
179
|
+
let h = y, k = !1;
|
|
180
|
+
y.endsWith(ye) ? (h = y.slice(0, -1), k = !0) : (
|
|
181
181
|
/**
|
|
182
182
|
* In Tailwind CSS v3 the important modifier was at the start of the base class name. This is still supported for legacy reasons.
|
|
183
183
|
* @see https://github.com/dcastil/tailwind-merge/issues/513#issuecomment-2614029864
|
|
184
184
|
*/
|
|
185
|
-
y.startsWith(ye) && (h = y.slice(1),
|
|
185
|
+
y.startsWith(ye) && (h = y.slice(1), k = !0)
|
|
186
186
|
);
|
|
187
|
-
const
|
|
188
|
-
return Ie(l,
|
|
187
|
+
const w = m && m > i ? m - i : void 0;
|
|
188
|
+
return Ie(l, k, h, w);
|
|
189
189
|
};
|
|
190
190
|
if (t) {
|
|
191
|
-
const
|
|
192
|
-
o = (
|
|
191
|
+
const s = t + Ae, l = o;
|
|
192
|
+
o = (n) => n.startsWith(s) ? l(n.slice(s.length)) : Ie(Er, !1, n, void 0, !0);
|
|
193
193
|
}
|
|
194
194
|
if (a) {
|
|
195
|
-
const
|
|
195
|
+
const s = o;
|
|
196
196
|
o = (l) => a({
|
|
197
197
|
className: l,
|
|
198
|
-
parseClassName:
|
|
198
|
+
parseClassName: s
|
|
199
199
|
});
|
|
200
200
|
}
|
|
201
201
|
return o;
|
|
@@ -205,12 +205,12 @@ const kr = (e, t) => {
|
|
|
205
205
|
t.set(a, 1e6 + o);
|
|
206
206
|
}), (a) => {
|
|
207
207
|
const o = [];
|
|
208
|
-
let
|
|
208
|
+
let s = [];
|
|
209
209
|
for (let l = 0; l < a.length; l++) {
|
|
210
|
-
const
|
|
211
|
-
c || i ? (
|
|
210
|
+
const n = a[l], c = n[0] === "[", i = t.has(n);
|
|
211
|
+
c || i ? (s.length > 0 && (s.sort(), o.push(...s), s = []), o.push(n)) : s.push(n);
|
|
212
212
|
}
|
|
213
|
-
return
|
|
213
|
+
return s.length > 0 && (s.sort(), o.push(...s)), o;
|
|
214
214
|
};
|
|
215
215
|
}, Gr = (e) => ({
|
|
216
216
|
cache: Or(e.cacheSize),
|
|
@@ -221,51 +221,51 @@ const kr = (e, t) => {
|
|
|
221
221
|
const {
|
|
222
222
|
parseClassName: a,
|
|
223
223
|
getClassGroupId: o,
|
|
224
|
-
getConflictingClassGroupIds:
|
|
224
|
+
getConflictingClassGroupIds: s,
|
|
225
225
|
sortModifiers: l
|
|
226
|
-
} = t,
|
|
226
|
+
} = t, n = [], c = e.trim().split(Br);
|
|
227
227
|
let i = "";
|
|
228
228
|
for (let m = c.length - 1; m >= 0; m -= 1) {
|
|
229
229
|
const x = c[m], {
|
|
230
230
|
isExternal: y,
|
|
231
231
|
modifiers: h,
|
|
232
|
-
hasImportantModifier:
|
|
233
|
-
baseClassName:
|
|
234
|
-
maybePostfixModifierPosition:
|
|
232
|
+
hasImportantModifier: k,
|
|
233
|
+
baseClassName: w,
|
|
234
|
+
maybePostfixModifierPosition: v
|
|
235
235
|
} = a(x);
|
|
236
236
|
if (y) {
|
|
237
237
|
i = x + (i.length > 0 ? " " + i : i);
|
|
238
238
|
continue;
|
|
239
239
|
}
|
|
240
|
-
let M = !!
|
|
240
|
+
let M = !!v, j = o(M ? w.substring(0, v) : w);
|
|
241
241
|
if (!j) {
|
|
242
242
|
if (!M) {
|
|
243
243
|
i = x + (i.length > 0 ? " " + i : i);
|
|
244
244
|
continue;
|
|
245
245
|
}
|
|
246
|
-
if (j = o(
|
|
246
|
+
if (j = o(w), !j) {
|
|
247
247
|
i = x + (i.length > 0 ? " " + i : i);
|
|
248
248
|
continue;
|
|
249
249
|
}
|
|
250
250
|
M = !1;
|
|
251
251
|
}
|
|
252
|
-
const L = h.length === 0 ? "" : h.length === 1 ? h[0] : l(h).join(":"), T =
|
|
253
|
-
if (
|
|
252
|
+
const L = h.length === 0 ? "" : h.length === 1 ? h[0] : l(h).join(":"), T = k ? L + ye : L, F = T + j;
|
|
253
|
+
if (n.indexOf(F) > -1)
|
|
254
254
|
continue;
|
|
255
|
-
|
|
256
|
-
const P =
|
|
255
|
+
n.push(F);
|
|
256
|
+
const P = s(j, M);
|
|
257
257
|
for (let S = 0; S < P.length; ++S) {
|
|
258
258
|
const O = P[S];
|
|
259
|
-
|
|
259
|
+
n.push(T + O);
|
|
260
260
|
}
|
|
261
261
|
i = x + (i.length > 0 ? " " + i : i);
|
|
262
262
|
}
|
|
263
263
|
return i;
|
|
264
264
|
}, $r = (...e) => {
|
|
265
|
-
let t = 0, a, o,
|
|
265
|
+
let t = 0, a, o, s = "";
|
|
266
266
|
for (; t < e.length; )
|
|
267
|
-
(a = e[t++]) && (o = Ve(a)) && (
|
|
268
|
-
return
|
|
267
|
+
(a = e[t++]) && (o = Ve(a)) && (s && (s += " "), s += o);
|
|
268
|
+
return s;
|
|
269
269
|
}, Ve = (e) => {
|
|
270
270
|
if (typeof e == "string")
|
|
271
271
|
return e;
|
|
@@ -274,18 +274,18 @@ const kr = (e, t) => {
|
|
|
274
274
|
e[o] && (t = Ve(e[o])) && (a && (a += " "), a += t);
|
|
275
275
|
return a;
|
|
276
276
|
}, _r = (e, ...t) => {
|
|
277
|
-
let a, o,
|
|
278
|
-
const
|
|
277
|
+
let a, o, s, l;
|
|
278
|
+
const n = (i) => {
|
|
279
279
|
const m = t.reduce((x, y) => y(x), e());
|
|
280
|
-
return a = Gr(m), o = a.cache.get,
|
|
280
|
+
return a = Gr(m), o = a.cache.get, s = a.cache.set, l = c, c(i);
|
|
281
281
|
}, c = (i) => {
|
|
282
282
|
const m = o(i);
|
|
283
283
|
if (m)
|
|
284
284
|
return m;
|
|
285
285
|
const x = Ur(i, a);
|
|
286
|
-
return
|
|
286
|
+
return s(i, x), x;
|
|
287
287
|
};
|
|
288
|
-
return l =
|
|
288
|
+
return l = n, (...i) => l($r(...i));
|
|
289
289
|
}, Vr = [], R = (e) => {
|
|
290
290
|
const t = (a) => a[e] || Vr;
|
|
291
291
|
return t.isThemeGetter = !0, t;
|
|
@@ -301,7 +301,7 @@ const kr = (e, t) => {
|
|
|
301
301
|
const o = Ye.exec(e);
|
|
302
302
|
return o ? o[1] ? t(o[1]) : a : !1;
|
|
303
303
|
}, qe = (e) => e === "position" || e === "percentage", Je = (e) => e === "image" || e === "url", Qe = (e) => e === "length" || e === "size" || e === "bg-size", Ke = (e) => e === "length", it = (e) => e === "number", lt = (e) => e === "family-name", Xe = (e) => e === "shadow", ct = () => {
|
|
304
|
-
const e = R("color"), t = R("font"), a = R("text"), o = R("font-weight"),
|
|
304
|
+
const e = R("color"), t = R("font"), a = R("text"), o = R("font-weight"), s = R("tracking"), l = R("leading"), n = R("breakpoint"), c = R("container"), i = R("spacing"), m = R("radius"), x = R("shadow"), y = R("inset-shadow"), h = R("text-shadow"), k = R("drop-shadow"), w = R("blur"), v = R("perspective"), M = R("aspect"), j = R("ease"), L = R("animate"), T = () => ["auto", "avoid", "all", "avoid-page", "page", "left", "right", "column"], F = () => [
|
|
305
305
|
"center",
|
|
306
306
|
"top",
|
|
307
307
|
"bottom",
|
|
@@ -321,7 +321,7 @@ const kr = (e, t) => {
|
|
|
321
321
|
"left-bottom"
|
|
322
322
|
], P = () => [...F(), b, p], S = () => ["auto", "hidden", "clip", "visible", "scroll"], O = () => ["auto", "contain", "none"], f = () => [b, p, i], C = () => [X, "full", "auto", ...f()], A = () => [J, "none", "subgrid", b, p], _ = () => ["auto", {
|
|
323
323
|
span: ["full", J, b, p]
|
|
324
|
-
}, J, b, p], V = () => [J, "auto", b, p], W = () => ["auto", "min", "max", "fr", b, p], te = () => ["start", "end", "center", "between", "around", "evenly", "stretch", "baseline", "center-safe", "end-safe"], q = () => ["start", "end", "center", "stretch", "center-safe", "end-safe"], B = () => ["auto", ...f()], G = () => [X, "auto", "full", "dvw", "dvh", "lvw", "lvh", "svw", "svh", "min", "max", "fit", ...f()],
|
|
324
|
+
}, J, b, p], V = () => [J, "auto", b, p], W = () => ["auto", "min", "max", "fr", b, p], te = () => ["start", "end", "center", "between", "around", "evenly", "stretch", "baseline", "center-safe", "end-safe"], q = () => ["start", "end", "center", "stretch", "center-safe", "end-safe"], B = () => ["auto", ...f()], G = () => [X, "auto", "full", "dvw", "dvh", "lvw", "lvh", "svw", "svh", "min", "max", "fit", ...f()], N = () => [e, b, p], ve = () => [...F(), De, je, {
|
|
325
325
|
position: [b, p]
|
|
326
326
|
}], Ne = () => ["no-repeat", {
|
|
327
327
|
repeat: ["", "x", "y", "space", "round"]
|
|
@@ -339,7 +339,7 @@ const kr = (e, t) => {
|
|
|
339
339
|
// Deprecated since Tailwind CSS v4.0.0
|
|
340
340
|
"",
|
|
341
341
|
"none",
|
|
342
|
-
|
|
342
|
+
w,
|
|
343
343
|
b,
|
|
344
344
|
p
|
|
345
345
|
], ie = () => ["none", z, b, p], le = () => ["none", z, b, p], be = () => [z, b, p], ce = () => [X, "full", ...f()];
|
|
@@ -1001,7 +1001,7 @@ const kr = (e, t) => {
|
|
|
1001
1001
|
"prose",
|
|
1002
1002
|
/** Deprecated since Tailwind CSS v4.0.0. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */
|
|
1003
1003
|
{
|
|
1004
|
-
screen: [
|
|
1004
|
+
screen: [n]
|
|
1005
1005
|
},
|
|
1006
1006
|
...G()
|
|
1007
1007
|
]
|
|
@@ -1103,7 +1103,7 @@ const kr = (e, t) => {
|
|
|
1103
1103
|
* @see https://tailwindcss.com/docs/letter-spacing
|
|
1104
1104
|
*/
|
|
1105
1105
|
tracking: [{
|
|
1106
|
-
tracking: [
|
|
1106
|
+
tracking: [s, b, p]
|
|
1107
1107
|
}],
|
|
1108
1108
|
/**
|
|
1109
1109
|
* Line Clamp
|
|
@@ -1157,14 +1157,14 @@ const kr = (e, t) => {
|
|
|
1157
1157
|
* @see https://v3.tailwindcss.com/docs/placeholder-color
|
|
1158
1158
|
*/
|
|
1159
1159
|
"placeholder-color": [{
|
|
1160
|
-
placeholder:
|
|
1160
|
+
placeholder: N()
|
|
1161
1161
|
}],
|
|
1162
1162
|
/**
|
|
1163
1163
|
* Text Color
|
|
1164
1164
|
* @see https://tailwindcss.com/docs/text-color
|
|
1165
1165
|
*/
|
|
1166
1166
|
"text-color": [{
|
|
1167
|
-
text:
|
|
1167
|
+
text: N()
|
|
1168
1168
|
}],
|
|
1169
1169
|
/**
|
|
1170
1170
|
* Text Decoration
|
|
@@ -1190,7 +1190,7 @@ const kr = (e, t) => {
|
|
|
1190
1190
|
* @see https://tailwindcss.com/docs/text-decoration-color
|
|
1191
1191
|
*/
|
|
1192
1192
|
"text-decoration-color": [{
|
|
1193
|
-
decoration:
|
|
1193
|
+
decoration: N()
|
|
1194
1194
|
}],
|
|
1195
1195
|
/**
|
|
1196
1196
|
* Text Underline Offset
|
|
@@ -1328,7 +1328,7 @@ const kr = (e, t) => {
|
|
|
1328
1328
|
* @see https://tailwindcss.com/docs/background-color
|
|
1329
1329
|
*/
|
|
1330
1330
|
"bg-color": [{
|
|
1331
|
-
bg:
|
|
1331
|
+
bg: N()
|
|
1332
1332
|
}],
|
|
1333
1333
|
/**
|
|
1334
1334
|
* Gradient Color Stops From Position
|
|
@@ -1356,21 +1356,21 @@ const kr = (e, t) => {
|
|
|
1356
1356
|
* @see https://tailwindcss.com/docs/gradient-color-stops
|
|
1357
1357
|
*/
|
|
1358
1358
|
"gradient-from": [{
|
|
1359
|
-
from:
|
|
1359
|
+
from: N()
|
|
1360
1360
|
}],
|
|
1361
1361
|
/**
|
|
1362
1362
|
* Gradient Color Stops Via
|
|
1363
1363
|
* @see https://tailwindcss.com/docs/gradient-color-stops
|
|
1364
1364
|
*/
|
|
1365
1365
|
"gradient-via": [{
|
|
1366
|
-
via:
|
|
1366
|
+
via: N()
|
|
1367
1367
|
}],
|
|
1368
1368
|
/**
|
|
1369
1369
|
* Gradient Color Stops To
|
|
1370
1370
|
* @see https://tailwindcss.com/docs/gradient-color-stops
|
|
1371
1371
|
*/
|
|
1372
1372
|
"gradient-to": [{
|
|
1373
|
-
to:
|
|
1373
|
+
to: N()
|
|
1374
1374
|
}],
|
|
1375
1375
|
// ---------------
|
|
1376
1376
|
// --- Borders ---
|
|
@@ -1586,70 +1586,70 @@ const kr = (e, t) => {
|
|
|
1586
1586
|
* @see https://tailwindcss.com/docs/border-color
|
|
1587
1587
|
*/
|
|
1588
1588
|
"border-color": [{
|
|
1589
|
-
border:
|
|
1589
|
+
border: N()
|
|
1590
1590
|
}],
|
|
1591
1591
|
/**
|
|
1592
1592
|
* Border Color X
|
|
1593
1593
|
* @see https://tailwindcss.com/docs/border-color
|
|
1594
1594
|
*/
|
|
1595
1595
|
"border-color-x": [{
|
|
1596
|
-
"border-x":
|
|
1596
|
+
"border-x": N()
|
|
1597
1597
|
}],
|
|
1598
1598
|
/**
|
|
1599
1599
|
* Border Color Y
|
|
1600
1600
|
* @see https://tailwindcss.com/docs/border-color
|
|
1601
1601
|
*/
|
|
1602
1602
|
"border-color-y": [{
|
|
1603
|
-
"border-y":
|
|
1603
|
+
"border-y": N()
|
|
1604
1604
|
}],
|
|
1605
1605
|
/**
|
|
1606
1606
|
* Border Color S
|
|
1607
1607
|
* @see https://tailwindcss.com/docs/border-color
|
|
1608
1608
|
*/
|
|
1609
1609
|
"border-color-s": [{
|
|
1610
|
-
"border-s":
|
|
1610
|
+
"border-s": N()
|
|
1611
1611
|
}],
|
|
1612
1612
|
/**
|
|
1613
1613
|
* Border Color E
|
|
1614
1614
|
* @see https://tailwindcss.com/docs/border-color
|
|
1615
1615
|
*/
|
|
1616
1616
|
"border-color-e": [{
|
|
1617
|
-
"border-e":
|
|
1617
|
+
"border-e": N()
|
|
1618
1618
|
}],
|
|
1619
1619
|
/**
|
|
1620
1620
|
* Border Color Top
|
|
1621
1621
|
* @see https://tailwindcss.com/docs/border-color
|
|
1622
1622
|
*/
|
|
1623
1623
|
"border-color-t": [{
|
|
1624
|
-
"border-t":
|
|
1624
|
+
"border-t": N()
|
|
1625
1625
|
}],
|
|
1626
1626
|
/**
|
|
1627
1627
|
* Border Color Right
|
|
1628
1628
|
* @see https://tailwindcss.com/docs/border-color
|
|
1629
1629
|
*/
|
|
1630
1630
|
"border-color-r": [{
|
|
1631
|
-
"border-r":
|
|
1631
|
+
"border-r": N()
|
|
1632
1632
|
}],
|
|
1633
1633
|
/**
|
|
1634
1634
|
* Border Color Bottom
|
|
1635
1635
|
* @see https://tailwindcss.com/docs/border-color
|
|
1636
1636
|
*/
|
|
1637
1637
|
"border-color-b": [{
|
|
1638
|
-
"border-b":
|
|
1638
|
+
"border-b": N()
|
|
1639
1639
|
}],
|
|
1640
1640
|
/**
|
|
1641
1641
|
* Border Color Left
|
|
1642
1642
|
* @see https://tailwindcss.com/docs/border-color
|
|
1643
1643
|
*/
|
|
1644
1644
|
"border-color-l": [{
|
|
1645
|
-
"border-l":
|
|
1645
|
+
"border-l": N()
|
|
1646
1646
|
}],
|
|
1647
1647
|
/**
|
|
1648
1648
|
* Divide Color
|
|
1649
1649
|
* @see https://tailwindcss.com/docs/divide-color
|
|
1650
1650
|
*/
|
|
1651
1651
|
"divide-color": [{
|
|
1652
|
-
divide:
|
|
1652
|
+
divide: N()
|
|
1653
1653
|
}],
|
|
1654
1654
|
/**
|
|
1655
1655
|
* Outline Style
|
|
@@ -1677,7 +1677,7 @@ const kr = (e, t) => {
|
|
|
1677
1677
|
* @see https://tailwindcss.com/docs/outline-color
|
|
1678
1678
|
*/
|
|
1679
1679
|
"outline-color": [{
|
|
1680
|
-
outline:
|
|
1680
|
+
outline: N()
|
|
1681
1681
|
}],
|
|
1682
1682
|
// ---------------
|
|
1683
1683
|
// --- Effects ---
|
|
@@ -1701,7 +1701,7 @@ const kr = (e, t) => {
|
|
|
1701
1701
|
* @see https://tailwindcss.com/docs/box-shadow#setting-the-shadow-color
|
|
1702
1702
|
*/
|
|
1703
1703
|
"shadow-color": [{
|
|
1704
|
-
shadow:
|
|
1704
|
+
shadow: N()
|
|
1705
1705
|
}],
|
|
1706
1706
|
/**
|
|
1707
1707
|
* Inset Box Shadow
|
|
@@ -1715,7 +1715,7 @@ const kr = (e, t) => {
|
|
|
1715
1715
|
* @see https://tailwindcss.com/docs/box-shadow#setting-the-inset-shadow-color
|
|
1716
1716
|
*/
|
|
1717
1717
|
"inset-shadow-color": [{
|
|
1718
|
-
"inset-shadow":
|
|
1718
|
+
"inset-shadow": N()
|
|
1719
1719
|
}],
|
|
1720
1720
|
/**
|
|
1721
1721
|
* Ring Width
|
|
@@ -1736,7 +1736,7 @@ const kr = (e, t) => {
|
|
|
1736
1736
|
* @see https://tailwindcss.com/docs/box-shadow#setting-the-ring-color
|
|
1737
1737
|
*/
|
|
1738
1738
|
"ring-color": [{
|
|
1739
|
-
ring:
|
|
1739
|
+
ring: N()
|
|
1740
1740
|
}],
|
|
1741
1741
|
/**
|
|
1742
1742
|
* Ring Offset Width
|
|
@@ -1754,7 +1754,7 @@ const kr = (e, t) => {
|
|
|
1754
1754
|
* @see https://github.com/tailwindlabs/tailwindcss/blob/v4.0.0/packages/tailwindcss/src/utilities.ts#L4158
|
|
1755
1755
|
*/
|
|
1756
1756
|
"ring-offset-color": [{
|
|
1757
|
-
"ring-offset":
|
|
1757
|
+
"ring-offset": N()
|
|
1758
1758
|
}],
|
|
1759
1759
|
/**
|
|
1760
1760
|
* Inset Ring Width
|
|
@@ -1768,7 +1768,7 @@ const kr = (e, t) => {
|
|
|
1768
1768
|
* @see https://tailwindcss.com/docs/box-shadow#setting-the-inset-ring-color
|
|
1769
1769
|
*/
|
|
1770
1770
|
"inset-ring-color": [{
|
|
1771
|
-
"inset-ring":
|
|
1771
|
+
"inset-ring": N()
|
|
1772
1772
|
}],
|
|
1773
1773
|
/**
|
|
1774
1774
|
* Text Shadow
|
|
@@ -1782,7 +1782,7 @@ const kr = (e, t) => {
|
|
|
1782
1782
|
* @see https://tailwindcss.com/docs/text-shadow#setting-the-shadow-color
|
|
1783
1783
|
*/
|
|
1784
1784
|
"text-shadow-color": [{
|
|
1785
|
-
"text-shadow":
|
|
1785
|
+
"text-shadow": N()
|
|
1786
1786
|
}],
|
|
1787
1787
|
/**
|
|
1788
1788
|
* Opacity
|
|
@@ -1833,10 +1833,10 @@ const kr = (e, t) => {
|
|
|
1833
1833
|
"mask-linear-to": I()
|
|
1834
1834
|
}],
|
|
1835
1835
|
"mask-image-linear-from-color": [{
|
|
1836
|
-
"mask-linear-from":
|
|
1836
|
+
"mask-linear-from": N()
|
|
1837
1837
|
}],
|
|
1838
1838
|
"mask-image-linear-to-color": [{
|
|
1839
|
-
"mask-linear-to":
|
|
1839
|
+
"mask-linear-to": N()
|
|
1840
1840
|
}],
|
|
1841
1841
|
"mask-image-t-from-pos": [{
|
|
1842
1842
|
"mask-t-from": I()
|
|
@@ -1845,10 +1845,10 @@ const kr = (e, t) => {
|
|
|
1845
1845
|
"mask-t-to": I()
|
|
1846
1846
|
}],
|
|
1847
1847
|
"mask-image-t-from-color": [{
|
|
1848
|
-
"mask-t-from":
|
|
1848
|
+
"mask-t-from": N()
|
|
1849
1849
|
}],
|
|
1850
1850
|
"mask-image-t-to-color": [{
|
|
1851
|
-
"mask-t-to":
|
|
1851
|
+
"mask-t-to": N()
|
|
1852
1852
|
}],
|
|
1853
1853
|
"mask-image-r-from-pos": [{
|
|
1854
1854
|
"mask-r-from": I()
|
|
@@ -1857,10 +1857,10 @@ const kr = (e, t) => {
|
|
|
1857
1857
|
"mask-r-to": I()
|
|
1858
1858
|
}],
|
|
1859
1859
|
"mask-image-r-from-color": [{
|
|
1860
|
-
"mask-r-from":
|
|
1860
|
+
"mask-r-from": N()
|
|
1861
1861
|
}],
|
|
1862
1862
|
"mask-image-r-to-color": [{
|
|
1863
|
-
"mask-r-to":
|
|
1863
|
+
"mask-r-to": N()
|
|
1864
1864
|
}],
|
|
1865
1865
|
"mask-image-b-from-pos": [{
|
|
1866
1866
|
"mask-b-from": I()
|
|
@@ -1869,10 +1869,10 @@ const kr = (e, t) => {
|
|
|
1869
1869
|
"mask-b-to": I()
|
|
1870
1870
|
}],
|
|
1871
1871
|
"mask-image-b-from-color": [{
|
|
1872
|
-
"mask-b-from":
|
|
1872
|
+
"mask-b-from": N()
|
|
1873
1873
|
}],
|
|
1874
1874
|
"mask-image-b-to-color": [{
|
|
1875
|
-
"mask-b-to":
|
|
1875
|
+
"mask-b-to": N()
|
|
1876
1876
|
}],
|
|
1877
1877
|
"mask-image-l-from-pos": [{
|
|
1878
1878
|
"mask-l-from": I()
|
|
@@ -1881,10 +1881,10 @@ const kr = (e, t) => {
|
|
|
1881
1881
|
"mask-l-to": I()
|
|
1882
1882
|
}],
|
|
1883
1883
|
"mask-image-l-from-color": [{
|
|
1884
|
-
"mask-l-from":
|
|
1884
|
+
"mask-l-from": N()
|
|
1885
1885
|
}],
|
|
1886
1886
|
"mask-image-l-to-color": [{
|
|
1887
|
-
"mask-l-to":
|
|
1887
|
+
"mask-l-to": N()
|
|
1888
1888
|
}],
|
|
1889
1889
|
"mask-image-x-from-pos": [{
|
|
1890
1890
|
"mask-x-from": I()
|
|
@@ -1893,10 +1893,10 @@ const kr = (e, t) => {
|
|
|
1893
1893
|
"mask-x-to": I()
|
|
1894
1894
|
}],
|
|
1895
1895
|
"mask-image-x-from-color": [{
|
|
1896
|
-
"mask-x-from":
|
|
1896
|
+
"mask-x-from": N()
|
|
1897
1897
|
}],
|
|
1898
1898
|
"mask-image-x-to-color": [{
|
|
1899
|
-
"mask-x-to":
|
|
1899
|
+
"mask-x-to": N()
|
|
1900
1900
|
}],
|
|
1901
1901
|
"mask-image-y-from-pos": [{
|
|
1902
1902
|
"mask-y-from": I()
|
|
@@ -1905,10 +1905,10 @@ const kr = (e, t) => {
|
|
|
1905
1905
|
"mask-y-to": I()
|
|
1906
1906
|
}],
|
|
1907
1907
|
"mask-image-y-from-color": [{
|
|
1908
|
-
"mask-y-from":
|
|
1908
|
+
"mask-y-from": N()
|
|
1909
1909
|
}],
|
|
1910
1910
|
"mask-image-y-to-color": [{
|
|
1911
|
-
"mask-y-to":
|
|
1911
|
+
"mask-y-to": N()
|
|
1912
1912
|
}],
|
|
1913
1913
|
"mask-image-radial": [{
|
|
1914
1914
|
"mask-radial": [b, p]
|
|
@@ -1920,10 +1920,10 @@ const kr = (e, t) => {
|
|
|
1920
1920
|
"mask-radial-to": I()
|
|
1921
1921
|
}],
|
|
1922
1922
|
"mask-image-radial-from-color": [{
|
|
1923
|
-
"mask-radial-from":
|
|
1923
|
+
"mask-radial-from": N()
|
|
1924
1924
|
}],
|
|
1925
1925
|
"mask-image-radial-to-color": [{
|
|
1926
|
-
"mask-radial-to":
|
|
1926
|
+
"mask-radial-to": N()
|
|
1927
1927
|
}],
|
|
1928
1928
|
"mask-image-radial-shape": [{
|
|
1929
1929
|
"mask-radial": ["circle", "ellipse"]
|
|
@@ -1947,10 +1947,10 @@ const kr = (e, t) => {
|
|
|
1947
1947
|
"mask-conic-to": I()
|
|
1948
1948
|
}],
|
|
1949
1949
|
"mask-image-conic-from-color": [{
|
|
1950
|
-
"mask-conic-from":
|
|
1950
|
+
"mask-conic-from": N()
|
|
1951
1951
|
}],
|
|
1952
1952
|
"mask-image-conic-to-color": [{
|
|
1953
|
-
"mask-conic-to":
|
|
1953
|
+
"mask-conic-to": N()
|
|
1954
1954
|
}],
|
|
1955
1955
|
/**
|
|
1956
1956
|
* Mask Mode
|
|
@@ -2047,7 +2047,7 @@ const kr = (e, t) => {
|
|
|
2047
2047
|
// Deprecated since Tailwind CSS v4.0.0
|
|
2048
2048
|
"",
|
|
2049
2049
|
"none",
|
|
2050
|
-
|
|
2050
|
+
k,
|
|
2051
2051
|
me,
|
|
2052
2052
|
de
|
|
2053
2053
|
]
|
|
@@ -2057,7 +2057,7 @@ const kr = (e, t) => {
|
|
|
2057
2057
|
* @see https://tailwindcss.com/docs/filter-drop-shadow#setting-the-shadow-color
|
|
2058
2058
|
*/
|
|
2059
2059
|
"drop-shadow-color": [{
|
|
2060
|
-
"drop-shadow":
|
|
2060
|
+
"drop-shadow": N()
|
|
2061
2061
|
}],
|
|
2062
2062
|
/**
|
|
2063
2063
|
* Grayscale
|
|
@@ -2275,7 +2275,7 @@ const kr = (e, t) => {
|
|
|
2275
2275
|
* @see https://tailwindcss.com/docs/perspective
|
|
2276
2276
|
*/
|
|
2277
2277
|
perspective: [{
|
|
2278
|
-
perspective: [
|
|
2278
|
+
perspective: [v, b, p]
|
|
2279
2279
|
}],
|
|
2280
2280
|
/**
|
|
2281
2281
|
* Perspective Origin
|
|
@@ -2428,7 +2428,7 @@ const kr = (e, t) => {
|
|
|
2428
2428
|
* @see https://tailwindcss.com/docs/accent-color
|
|
2429
2429
|
*/
|
|
2430
2430
|
accent: [{
|
|
2431
|
-
accent:
|
|
2431
|
+
accent: N()
|
|
2432
2432
|
}],
|
|
2433
2433
|
/**
|
|
2434
2434
|
* Appearance
|
|
@@ -2442,7 +2442,7 @@ const kr = (e, t) => {
|
|
|
2442
2442
|
* @see https://tailwindcss.com/docs/just-in-time-mode#caret-color-utilities
|
|
2443
2443
|
*/
|
|
2444
2444
|
"caret-color": [{
|
|
2445
|
-
caret:
|
|
2445
|
+
caret: N()
|
|
2446
2446
|
}],
|
|
2447
2447
|
/**
|
|
2448
2448
|
* Color Scheme
|
|
@@ -2688,7 +2688,7 @@ const kr = (e, t) => {
|
|
|
2688
2688
|
* @see https://tailwindcss.com/docs/fill
|
|
2689
2689
|
*/
|
|
2690
2690
|
fill: [{
|
|
2691
|
-
fill: ["none", ...
|
|
2691
|
+
fill: ["none", ...N()]
|
|
2692
2692
|
}],
|
|
2693
2693
|
/**
|
|
2694
2694
|
* Stroke Width
|
|
@@ -2702,7 +2702,7 @@ const kr = (e, t) => {
|
|
|
2702
2702
|
* @see https://tailwindcss.com/docs/stroke
|
|
2703
2703
|
*/
|
|
2704
2704
|
stroke: [{
|
|
2705
|
-
stroke: ["none", ...
|
|
2705
|
+
stroke: ["none", ...N()]
|
|
2706
2706
|
}],
|
|
2707
2707
|
// ---------------------
|
|
2708
2708
|
// --- Accessibility ---
|
|
@@ -2775,7 +2775,7 @@ function u(...e) {
|
|
|
2775
2775
|
return dt(Nr(e));
|
|
2776
2776
|
}
|
|
2777
2777
|
const xe = Le.forwardRef(
|
|
2778
|
-
({ variant: e = "primary", size: t = "md", loading: a, icon: o, className:
|
|
2778
|
+
({ variant: e = "primary", size: t = "md", loading: a, icon: o, className: s, children: l, disabled: n, ...c }, i) => {
|
|
2779
2779
|
const m = "inline-flex items-center justify-center gap-2 font-medium rounded-md transition-all duration-200 touch-target disabled:opacity-50 disabled:cursor-not-allowed active:scale-[0.98] flex-shrink-0 whitespace-nowrap", x = {
|
|
2780
2780
|
primary: "bg-primary text-white hover:bg-primary-dark active:bg-primary-dark/90 shadow-sm",
|
|
2781
2781
|
secondary: "bg-secondary text-foreground hover:bg-border active:bg-border-dark",
|
|
@@ -2791,9 +2791,9 @@ const xe = Le.forwardRef(
|
|
|
2791
2791
|
g.button,
|
|
2792
2792
|
{
|
|
2793
2793
|
ref: i,
|
|
2794
|
-
whileTap: { scale:
|
|
2795
|
-
className: u(m, x[e], y[t],
|
|
2796
|
-
disabled:
|
|
2794
|
+
whileTap: { scale: n || a ? 1 : 0.98 },
|
|
2795
|
+
className: u(m, x[e], y[t], s),
|
|
2796
|
+
disabled: n || a,
|
|
2797
2797
|
...c,
|
|
2798
2798
|
children: [
|
|
2799
2799
|
a ? /* @__PURE__ */ r(tr, { className: "h-5 w-5 animate-spin" }) : o ? /* @__PURE__ */ r("span", { className: "flex-shrink-0", children: o }) : null,
|
|
@@ -2805,8 +2805,8 @@ const xe = Le.forwardRef(
|
|
|
2805
2805
|
);
|
|
2806
2806
|
xe.displayName = "Button";
|
|
2807
2807
|
const mt = se(
|
|
2808
|
-
({ label: e, error: t, hint: a, leftIcon: o, rightIcon:
|
|
2809
|
-
const [m, x] = D(!1), y =
|
|
2808
|
+
({ label: e, error: t, hint: a, leftIcon: o, rightIcon: s, className: l, type: n, ...c }, i) => {
|
|
2809
|
+
const [m, x] = D(!1), y = n === "password", h = y && m ? "text" : n;
|
|
2810
2810
|
return /* @__PURE__ */ d("div", { className: "w-full space-y-1.5", children: [
|
|
2811
2811
|
e && /* @__PURE__ */ d("label", { className: "block text-sm font-medium text-foreground", children: [
|
|
2812
2812
|
e,
|
|
@@ -2833,7 +2833,7 @@ const mt = se(
|
|
|
2833
2833
|
paddingTop: "12px",
|
|
2834
2834
|
paddingBottom: "12px",
|
|
2835
2835
|
paddingLeft: o ? "44px" : "16px",
|
|
2836
|
-
paddingRight:
|
|
2836
|
+
paddingRight: s || y ? "44px" : "16px"
|
|
2837
2837
|
},
|
|
2838
2838
|
...c
|
|
2839
2839
|
}
|
|
@@ -2858,7 +2858,7 @@ const mt = se(
|
|
|
2858
2858
|
children: m ? /* @__PURE__ */ r(or, { className: "w-5 h-5" }) : /* @__PURE__ */ r(ar, { className: "w-5 h-5" })
|
|
2859
2859
|
}
|
|
2860
2860
|
),
|
|
2861
|
-
|
|
2861
|
+
s && !y && /* @__PURE__ */ r("div", { className: "absolute flex items-center pointer-events-none text-primary", style: { right: "14px", top: "50%", transform: "translateY(-50%)" }, children: s })
|
|
2862
2862
|
] }),
|
|
2863
2863
|
t && /* @__PURE__ */ r(
|
|
2864
2864
|
g.p,
|
|
@@ -2875,7 +2875,7 @@ const mt = se(
|
|
|
2875
2875
|
);
|
|
2876
2876
|
mt.displayName = "Input";
|
|
2877
2877
|
const ut = se(
|
|
2878
|
-
({ label: e, error: t, helperText: a, className: o, required:
|
|
2878
|
+
({ label: e, error: t, helperText: a, className: o, required: s, ...l }, n) => /* @__PURE__ */ d(
|
|
2879
2879
|
g.div,
|
|
2880
2880
|
{
|
|
2881
2881
|
initial: { opacity: 0, y: 10 },
|
|
@@ -2885,12 +2885,12 @@ const ut = se(
|
|
|
2885
2885
|
children: [
|
|
2886
2886
|
e && /* @__PURE__ */ d("label", { className: "block text-sm font-medium text-foreground mb-1.5", children: [
|
|
2887
2887
|
e,
|
|
2888
|
-
|
|
2888
|
+
s && /* @__PURE__ */ r("span", { className: "text-error ml-1", children: "*" })
|
|
2889
2889
|
] }),
|
|
2890
2890
|
/* @__PURE__ */ r(
|
|
2891
2891
|
"textarea",
|
|
2892
2892
|
{
|
|
2893
|
-
ref:
|
|
2893
|
+
ref: n,
|
|
2894
2894
|
className: u(
|
|
2895
2895
|
"w-full px-4 py-3 bg-background border border-border rounded-md",
|
|
2896
2896
|
"text-foreground placeholder:text-foreground/50",
|
|
@@ -2920,8 +2920,8 @@ const ut = se(
|
|
|
2920
2920
|
);
|
|
2921
2921
|
ut.displayName = "Textarea";
|
|
2922
2922
|
const pt = se(
|
|
2923
|
-
({ label: e, description: t, className: a, checked: o, defaultChecked:
|
|
2924
|
-
const [i, m] = D(
|
|
2923
|
+
({ label: e, description: t, className: a, checked: o, defaultChecked: s, onChange: l, ...n }, c) => {
|
|
2924
|
+
const [i, m] = D(s || !1), x = o !== void 0 ? o : i;
|
|
2925
2925
|
return /* @__PURE__ */ d("label", { className: "flex items-start gap-3 cursor-pointer group", children: [
|
|
2926
2926
|
/* @__PURE__ */ d("div", { className: "relative flex-shrink-0 mt-0.5", children: [
|
|
2927
2927
|
/* @__PURE__ */ r(
|
|
@@ -2934,7 +2934,7 @@ const pt = se(
|
|
|
2934
2934
|
onChange: (h) => {
|
|
2935
2935
|
o === void 0 && m(h.target.checked), l?.(h.target.checked);
|
|
2936
2936
|
},
|
|
2937
|
-
...
|
|
2937
|
+
...n
|
|
2938
2938
|
}
|
|
2939
2939
|
),
|
|
2940
2940
|
/* @__PURE__ */ r(
|
|
@@ -2969,27 +2969,27 @@ const Rt = ({
|
|
|
2969
2969
|
value: t,
|
|
2970
2970
|
onChange: a,
|
|
2971
2971
|
name: o,
|
|
2972
|
-
disabled:
|
|
2972
|
+
disabled: s,
|
|
2973
2973
|
className: l
|
|
2974
|
-
}) => /* @__PURE__ */ r("div", { className: u("flex flex-wrap gap-2", l), children: e.map((
|
|
2975
|
-
const c = t ===
|
|
2974
|
+
}) => /* @__PURE__ */ r("div", { className: u("flex flex-wrap gap-2", l), children: e.map((n) => {
|
|
2975
|
+
const c = t === n.value;
|
|
2976
2976
|
return /* @__PURE__ */ d("label", { className: "relative cursor-pointer", children: [
|
|
2977
2977
|
/* @__PURE__ */ r(
|
|
2978
2978
|
"input",
|
|
2979
2979
|
{
|
|
2980
2980
|
type: "radio",
|
|
2981
2981
|
name: o,
|
|
2982
|
-
value:
|
|
2982
|
+
value: n.value,
|
|
2983
2983
|
checked: c,
|
|
2984
2984
|
onChange: (i) => a?.(i.target.value),
|
|
2985
|
-
disabled:
|
|
2985
|
+
disabled: s,
|
|
2986
2986
|
className: "sr-only peer"
|
|
2987
2987
|
}
|
|
2988
2988
|
),
|
|
2989
2989
|
/* @__PURE__ */ d(
|
|
2990
2990
|
g.div,
|
|
2991
2991
|
{
|
|
2992
|
-
whileTap: { scale:
|
|
2992
|
+
whileTap: { scale: s ? 1 : 0.95 },
|
|
2993
2993
|
className: u(
|
|
2994
2994
|
"px-4 py-2.5 rounded-full border-2 transition-all duration-200",
|
|
2995
2995
|
"flex items-center gap-2 min-h-[2.75rem]",
|
|
@@ -2998,14 +2998,14 @@ const Rt = ({
|
|
|
2998
2998
|
c ? "bg-primary border-primary text-white" : "bg-background border-border text-primary hover:border-border-dark"
|
|
2999
2999
|
),
|
|
3000
3000
|
children: [
|
|
3001
|
-
|
|
3002
|
-
/* @__PURE__ */ r("span", { className: "font-medium text-base", children:
|
|
3001
|
+
n.icon && /* @__PURE__ */ r("span", { className: "flex-shrink-0", children: n.icon }),
|
|
3002
|
+
/* @__PURE__ */ r("span", { className: "font-medium text-base", children: n.label })
|
|
3003
3003
|
]
|
|
3004
3004
|
}
|
|
3005
3005
|
)
|
|
3006
|
-
] },
|
|
3006
|
+
] }, n.value);
|
|
3007
3007
|
}) }), bt = se(
|
|
3008
|
-
({ label: e, description: t, className: a, checked: o, onChange:
|
|
3008
|
+
({ label: e, description: t, className: a, checked: o, onChange: s, ...l }, n) => /* @__PURE__ */ d("label", { className: "flex items-center justify-between gap-4 cursor-pointer group", children: [
|
|
3009
3009
|
(e || t) && /* @__PURE__ */ d("div", { className: "flex-1 space-y-0.5", children: [
|
|
3010
3010
|
e && /* @__PURE__ */ r("div", { className: "text-base font-medium text-foreground", children: e }),
|
|
3011
3011
|
t && /* @__PURE__ */ r("div", { className: "text-sm text-primary/70", children: t })
|
|
@@ -3014,10 +3014,10 @@ const Rt = ({
|
|
|
3014
3014
|
/* @__PURE__ */ r(
|
|
3015
3015
|
"input",
|
|
3016
3016
|
{
|
|
3017
|
-
ref:
|
|
3017
|
+
ref: n,
|
|
3018
3018
|
type: "checkbox",
|
|
3019
3019
|
onChange: (i) => {
|
|
3020
|
-
|
|
3020
|
+
s?.(i.target.checked);
|
|
3021
3021
|
},
|
|
3022
3022
|
className: "sr-only peer",
|
|
3023
3023
|
checked: o,
|
|
@@ -3053,18 +3053,18 @@ const At = ({
|
|
|
3053
3053
|
onChange: t,
|
|
3054
3054
|
min: a = 0,
|
|
3055
3055
|
max: o = 100,
|
|
3056
|
-
step:
|
|
3056
|
+
step: s = 1,
|
|
3057
3057
|
label: l,
|
|
3058
|
-
showValue:
|
|
3058
|
+
showValue: n = !0,
|
|
3059
3059
|
unit: c = "%",
|
|
3060
3060
|
disabled: i,
|
|
3061
3061
|
className: m
|
|
3062
3062
|
}) => {
|
|
3063
3063
|
const [x, y] = D(!1), h = (e - a) / (o - a) * 100;
|
|
3064
3064
|
return /* @__PURE__ */ d("div", { className: u("w-full space-y-2", m), children: [
|
|
3065
|
-
(l ||
|
|
3065
|
+
(l || n) && /* @__PURE__ */ d("div", { className: "flex items-center justify-between", children: [
|
|
3066
3066
|
l && /* @__PURE__ */ r("label", { className: "text-sm font-medium text-primary", children: l }),
|
|
3067
|
-
|
|
3067
|
+
n && /* @__PURE__ */ d("span", { className: "text-sm font-semibold text-primary", children: [
|
|
3068
3068
|
e,
|
|
3069
3069
|
c
|
|
3070
3070
|
] })
|
|
@@ -3086,9 +3086,9 @@ const At = ({
|
|
|
3086
3086
|
type: "range",
|
|
3087
3087
|
min: a,
|
|
3088
3088
|
max: o,
|
|
3089
|
-
step:
|
|
3089
|
+
step: s,
|
|
3090
3090
|
value: e,
|
|
3091
|
-
onChange: (
|
|
3091
|
+
onChange: (k) => t(Number(k.target.value)),
|
|
3092
3092
|
onMouseDown: () => y(!0),
|
|
3093
3093
|
onMouseUp: () => y(!1),
|
|
3094
3094
|
onTouchStart: () => y(!0),
|
|
@@ -3118,17 +3118,17 @@ const At = ({
|
|
|
3118
3118
|
value2: t,
|
|
3119
3119
|
onChange: a,
|
|
3120
3120
|
label1: o,
|
|
3121
|
-
label2:
|
|
3121
|
+
label2: s,
|
|
3122
3122
|
min: l = 0,
|
|
3123
|
-
max:
|
|
3123
|
+
max: n = 100,
|
|
3124
3124
|
step: c = 1,
|
|
3125
3125
|
unit: i = "%",
|
|
3126
3126
|
disabled: m,
|
|
3127
3127
|
className: x
|
|
3128
3128
|
}) => {
|
|
3129
|
-
const y = e + t, h = y > 0 ? e / y * 100 : 50,
|
|
3130
|
-
const M =
|
|
3131
|
-
a(
|
|
3129
|
+
const y = e + t, h = y > 0 ? e / y * 100 : 50, k = y > 0 ? t / y * 100 : 50, w = (v) => {
|
|
3130
|
+
const M = n - v;
|
|
3131
|
+
a(v, Math.max(l, Math.min(n, M)));
|
|
3132
3132
|
};
|
|
3133
3133
|
return /* @__PURE__ */ d("div", { className: u("w-full space-y-3", x), children: [
|
|
3134
3134
|
/* @__PURE__ */ d("div", { className: "space-y-2", children: [
|
|
@@ -3154,10 +3154,10 @@ const At = ({
|
|
|
3154
3154
|
{
|
|
3155
3155
|
type: "range",
|
|
3156
3156
|
min: l,
|
|
3157
|
-
max:
|
|
3157
|
+
max: n,
|
|
3158
3158
|
step: c,
|
|
3159
3159
|
value: e,
|
|
3160
|
-
onChange: (
|
|
3160
|
+
onChange: (v) => w(Number(v.target.value)),
|
|
3161
3161
|
disabled: m,
|
|
3162
3162
|
className: "absolute inset-0 w-full opacity-0 cursor-pointer disabled:cursor-not-allowed"
|
|
3163
3163
|
}
|
|
@@ -3166,7 +3166,7 @@ const At = ({
|
|
|
3166
3166
|
] }),
|
|
3167
3167
|
/* @__PURE__ */ d("div", { className: "space-y-2", children: [
|
|
3168
3168
|
/* @__PURE__ */ d("div", { className: "flex items-center justify-between", children: [
|
|
3169
|
-
/* @__PURE__ */ r("label", { className: "text-sm font-medium text-primary", children:
|
|
3169
|
+
/* @__PURE__ */ r("label", { className: "text-sm font-medium text-primary", children: s }),
|
|
3170
3170
|
/* @__PURE__ */ d("span", { className: "text-sm font-semibold text-success", children: [
|
|
3171
3171
|
t,
|
|
3172
3172
|
i
|
|
@@ -3178,7 +3178,7 @@ const At = ({
|
|
|
3178
3178
|
{
|
|
3179
3179
|
className: "h-full bg-success",
|
|
3180
3180
|
initial: !1,
|
|
3181
|
-
animate: { width: `${
|
|
3181
|
+
animate: { width: `${k}%` },
|
|
3182
3182
|
transition: { type: "spring", stiffness: 300, damping: 30 }
|
|
3183
3183
|
}
|
|
3184
3184
|
) }),
|
|
@@ -3187,10 +3187,10 @@ const At = ({
|
|
|
3187
3187
|
{
|
|
3188
3188
|
type: "range",
|
|
3189
3189
|
min: l,
|
|
3190
|
-
max:
|
|
3190
|
+
max: n,
|
|
3191
3191
|
step: c,
|
|
3192
3192
|
value: t,
|
|
3193
|
-
onChange: (
|
|
3193
|
+
onChange: (v) => w(n - Number(v.target.value)),
|
|
3194
3194
|
disabled: m,
|
|
3195
3195
|
className: "absolute inset-0 w-full opacity-0 cursor-pointer disabled:cursor-not-allowed"
|
|
3196
3196
|
}
|
|
@@ -3208,29 +3208,29 @@ const At = ({
|
|
|
3208
3208
|
value: t,
|
|
3209
3209
|
onChange: a,
|
|
3210
3210
|
placeholder: o = "Select an option",
|
|
3211
|
-
label:
|
|
3211
|
+
label: s,
|
|
3212
3212
|
error: l,
|
|
3213
|
-
searchable:
|
|
3213
|
+
searchable: n = !1,
|
|
3214
3214
|
clearable: c = !0,
|
|
3215
3215
|
disabled: i,
|
|
3216
3216
|
className: m
|
|
3217
3217
|
}) => {
|
|
3218
|
-
const [x, y] = D(!1), [h,
|
|
3218
|
+
const [x, y] = D(!1), [h, k] = D(""), w = H(null), v = e.find((T) => T.value === t), M = n ? e.filter(
|
|
3219
3219
|
(T) => T.label.toLowerCase().includes(h.toLowerCase())
|
|
3220
3220
|
) : e;
|
|
3221
3221
|
Z(() => {
|
|
3222
3222
|
const T = (F) => {
|
|
3223
|
-
|
|
3223
|
+
w.current && !w.current.contains(F.target) && (y(!1), k(""));
|
|
3224
3224
|
};
|
|
3225
3225
|
return document.addEventListener("mousedown", T), () => document.removeEventListener("mousedown", T);
|
|
3226
3226
|
}, []);
|
|
3227
3227
|
const j = (T) => {
|
|
3228
|
-
a(T), y(!1),
|
|
3228
|
+
a(T), y(!1), k("");
|
|
3229
3229
|
}, L = (T) => {
|
|
3230
3230
|
T.stopPropagation(), a("");
|
|
3231
3231
|
};
|
|
3232
|
-
return /* @__PURE__ */ d("div", { ref:
|
|
3233
|
-
|
|
3232
|
+
return /* @__PURE__ */ d("div", { ref: w, className: u("relative w-full", m), children: [
|
|
3233
|
+
s && /* @__PURE__ */ r("label", { className: "block mb-1.5 text-sm font-medium text-foreground", children: s }),
|
|
3234
3234
|
/* @__PURE__ */ d(
|
|
3235
3235
|
"button",
|
|
3236
3236
|
{
|
|
@@ -3249,11 +3249,11 @@ const At = ({
|
|
|
3249
3249
|
),
|
|
3250
3250
|
children: [
|
|
3251
3251
|
/* @__PURE__ */ d("div", { className: "flex items-center gap-2 flex-1 min-w-0", children: [
|
|
3252
|
-
|
|
3253
|
-
/* @__PURE__ */ r("span", { className: u("truncate", !
|
|
3252
|
+
v?.icon && /* @__PURE__ */ r("span", { className: "flex-shrink-0", children: v.icon }),
|
|
3253
|
+
/* @__PURE__ */ r("span", { className: u("truncate", !v && "text-foreground/50"), children: v?.label || o })
|
|
3254
3254
|
] }),
|
|
3255
3255
|
/* @__PURE__ */ d("div", { className: "flex items-center gap-1 flex-shrink-0", children: [
|
|
3256
|
-
c &&
|
|
3256
|
+
c && v && /* @__PURE__ */ r(
|
|
3257
3257
|
"button",
|
|
3258
3258
|
{
|
|
3259
3259
|
type: "button",
|
|
@@ -3284,7 +3284,7 @@ const At = ({
|
|
|
3284
3284
|
transition: { duration: 0.2 },
|
|
3285
3285
|
className: "absolute z-50 w-full mt-2 bg-background rounded-md border border-border shadow-lg max-h-80 overflow-hidden",
|
|
3286
3286
|
children: [
|
|
3287
|
-
|
|
3287
|
+
n && /* @__PURE__ */ r("div", { className: "p-2 border-b border-border", children: /* @__PURE__ */ d("div", { className: "relative", children: [
|
|
3288
3288
|
/* @__PURE__ */ r(Fe, { className: "absolute left-3 top-1/2 -translate-y-1/2 w-4 h-4 text-primary/50" }),
|
|
3289
3289
|
/* @__PURE__ */ r(
|
|
3290
3290
|
"input",
|
|
@@ -3292,14 +3292,14 @@ const At = ({
|
|
|
3292
3292
|
type: "text",
|
|
3293
3293
|
placeholder: "Search...",
|
|
3294
3294
|
value: h,
|
|
3295
|
-
onChange: (T) =>
|
|
3295
|
+
onChange: (T) => k(T.target.value),
|
|
3296
3296
|
className: "w-full pl-10 pr-8 py-2 text-sm border border-border rounded-md focus:outline-none focus:ring-2 focus:ring-primary"
|
|
3297
3297
|
}
|
|
3298
3298
|
),
|
|
3299
3299
|
h && /* @__PURE__ */ r(
|
|
3300
3300
|
"button",
|
|
3301
3301
|
{
|
|
3302
|
-
onClick: () =>
|
|
3302
|
+
onClick: () => k(""),
|
|
3303
3303
|
className: "absolute right-2 top-1/2 -translate-y-1/2",
|
|
3304
3304
|
children: /* @__PURE__ */ r($, { className: "w-4 h-4 text-primary/50 hover:text-primary" })
|
|
3305
3305
|
}
|
|
@@ -3340,32 +3340,32 @@ const At = ({
|
|
|
3340
3340
|
value: t,
|
|
3341
3341
|
onChange: a,
|
|
3342
3342
|
placeholder: o = "Select an option",
|
|
3343
|
-
label:
|
|
3343
|
+
label: s,
|
|
3344
3344
|
error: l,
|
|
3345
|
-
hint:
|
|
3345
|
+
hint: n,
|
|
3346
3346
|
searchable: c = !1,
|
|
3347
3347
|
clearable: i = !0,
|
|
3348
3348
|
disabled: m,
|
|
3349
3349
|
required: x,
|
|
3350
3350
|
className: y
|
|
3351
3351
|
}, h) => {
|
|
3352
|
-
const [
|
|
3353
|
-
(S) => S.label.toLowerCase().includes(
|
|
3352
|
+
const [k, w] = D(!1), [v, M] = D(""), j = H(null), L = e.find((S) => S.value === t), T = c ? e.filter(
|
|
3353
|
+
(S) => S.label.toLowerCase().includes(v.toLowerCase())
|
|
3354
3354
|
) : e;
|
|
3355
3355
|
Z(() => {
|
|
3356
3356
|
const S = (O) => {
|
|
3357
|
-
j.current && !j.current.contains(O.target) && (
|
|
3357
|
+
j.current && !j.current.contains(O.target) && (w(!1), M(""));
|
|
3358
3358
|
};
|
|
3359
3359
|
return document.addEventListener("mousedown", S), () => document.removeEventListener("mousedown", S);
|
|
3360
3360
|
}, []);
|
|
3361
3361
|
const F = (S) => {
|
|
3362
|
-
a(S),
|
|
3362
|
+
a(S), w(!1), M("");
|
|
3363
3363
|
}, P = (S) => {
|
|
3364
3364
|
S.stopPropagation(), a("");
|
|
3365
3365
|
};
|
|
3366
3366
|
return /* @__PURE__ */ d("div", { ref: h, className: u("w-full space-y-1.5", y), children: [
|
|
3367
|
-
|
|
3368
|
-
|
|
3367
|
+
s && /* @__PURE__ */ d("label", { className: "block text-sm font-medium text-foreground", children: [
|
|
3368
|
+
s,
|
|
3369
3369
|
x && /* @__PURE__ */ r("span", { className: "text-error ml-1", children: "*" })
|
|
3370
3370
|
] }),
|
|
3371
3371
|
/* @__PURE__ */ d("div", { ref: j, className: "relative", children: [
|
|
@@ -3373,10 +3373,10 @@ const At = ({
|
|
|
3373
3373
|
"button",
|
|
3374
3374
|
{
|
|
3375
3375
|
type: "button",
|
|
3376
|
-
onClick: () => !m &&
|
|
3376
|
+
onClick: () => !m && w(!k),
|
|
3377
3377
|
disabled: m,
|
|
3378
3378
|
"aria-haspopup": "listbox",
|
|
3379
|
-
"aria-expanded":
|
|
3379
|
+
"aria-expanded": k,
|
|
3380
3380
|
"aria-required": x,
|
|
3381
3381
|
className: u(
|
|
3382
3382
|
"w-full px-4 py-3 rounded-md border transition-all duration-200",
|
|
@@ -3386,7 +3386,7 @@ const At = ({
|
|
|
3386
3386
|
"touch-target text-base",
|
|
3387
3387
|
l && "border-error focus:ring-error",
|
|
3388
3388
|
!l && "border-border",
|
|
3389
|
-
|
|
3389
|
+
k && "ring-2 ring-primary"
|
|
3390
3390
|
),
|
|
3391
3391
|
children: [
|
|
3392
3392
|
/* @__PURE__ */ d("div", { className: "flex items-center gap-2 flex-1 min-w-0", children: [
|
|
@@ -3409,7 +3409,7 @@ const At = ({
|
|
|
3409
3409
|
{
|
|
3410
3410
|
className: u(
|
|
3411
3411
|
"w-5 h-5 text-primary transition-transform",
|
|
3412
|
-
|
|
3412
|
+
k && "rotate-180"
|
|
3413
3413
|
)
|
|
3414
3414
|
}
|
|
3415
3415
|
)
|
|
@@ -3417,7 +3417,7 @@ const At = ({
|
|
|
3417
3417
|
]
|
|
3418
3418
|
}
|
|
3419
3419
|
),
|
|
3420
|
-
/* @__PURE__ */ r(Q, { children:
|
|
3420
|
+
/* @__PURE__ */ r(Q, { children: k && /* @__PURE__ */ d(
|
|
3421
3421
|
g.div,
|
|
3422
3422
|
{
|
|
3423
3423
|
initial: { opacity: 0, y: -10 },
|
|
@@ -3434,13 +3434,13 @@ const At = ({
|
|
|
3434
3434
|
{
|
|
3435
3435
|
type: "text",
|
|
3436
3436
|
placeholder: "Search...",
|
|
3437
|
-
value:
|
|
3437
|
+
value: v,
|
|
3438
3438
|
onChange: (S) => M(S.target.value),
|
|
3439
3439
|
className: "w-full pl-10 pr-8 py-2 text-sm border border-border rounded-md bg-background text-foreground focus:outline-none focus:ring-2 focus:ring-primary",
|
|
3440
3440
|
"aria-label": "Search options"
|
|
3441
3441
|
}
|
|
3442
3442
|
),
|
|
3443
|
-
|
|
3443
|
+
v && /* @__PURE__ */ r(
|
|
3444
3444
|
"button",
|
|
3445
3445
|
{
|
|
3446
3446
|
type: "button",
|
|
@@ -3485,7 +3485,7 @@ const At = ({
|
|
|
3485
3485
|
children: l
|
|
3486
3486
|
}
|
|
3487
3487
|
),
|
|
3488
|
-
|
|
3488
|
+
n && !l && /* @__PURE__ */ r("p", { className: "text-sm text-primary/70", children: n })
|
|
3489
3489
|
] });
|
|
3490
3490
|
}
|
|
3491
3491
|
);
|
|
@@ -3495,22 +3495,22 @@ const Dt = ({
|
|
|
3495
3495
|
onChange: t,
|
|
3496
3496
|
label: a,
|
|
3497
3497
|
placeholder: o = "Select date",
|
|
3498
|
-
error:
|
|
3498
|
+
error: s,
|
|
3499
3499
|
disabled: l,
|
|
3500
|
-
minDate:
|
|
3500
|
+
minDate: n,
|
|
3501
3501
|
maxDate: c,
|
|
3502
3502
|
className: i
|
|
3503
3503
|
}) => {
|
|
3504
|
-
const [m, x] = D(!1), [y, h] = D(e || /* @__PURE__ */ new Date()),
|
|
3504
|
+
const [m, x] = D(!1), [y, h] = D(e || /* @__PURE__ */ new Date()), k = H(null);
|
|
3505
3505
|
Z(() => {
|
|
3506
3506
|
const C = (A) => {
|
|
3507
|
-
|
|
3507
|
+
k.current && !k.current.contains(A.target) && x(!1);
|
|
3508
3508
|
};
|
|
3509
3509
|
return m && document.addEventListener("mousedown", C), () => {
|
|
3510
3510
|
document.removeEventListener("mousedown", C);
|
|
3511
3511
|
};
|
|
3512
3512
|
}, [m]);
|
|
3513
|
-
const
|
|
3513
|
+
const w = [
|
|
3514
3514
|
"January",
|
|
3515
3515
|
"February",
|
|
3516
3516
|
"March",
|
|
@@ -3523,7 +3523,7 @@ const Dt = ({
|
|
|
3523
3523
|
"October",
|
|
3524
3524
|
"November",
|
|
3525
3525
|
"December"
|
|
3526
|
-
],
|
|
3526
|
+
], v = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], M = (C) => {
|
|
3527
3527
|
const A = C.getFullYear(), _ = C.getMonth(), V = new Date(A, _, 1), te = new Date(A, _ + 1, 0).getDate(), q = V.getDay(), B = [];
|
|
3528
3528
|
for (let G = 0; G < q; G++)
|
|
3529
3529
|
B.push(null);
|
|
@@ -3536,12 +3536,12 @@ const Dt = ({
|
|
|
3536
3536
|
h(new Date(y.getFullYear(), y.getMonth() + 1, 1));
|
|
3537
3537
|
}, T = (C) => {
|
|
3538
3538
|
t(C), x(!1);
|
|
3539
|
-
}, F = (C) => !!(
|
|
3539
|
+
}, F = (C) => !!(n && C < n || c && C > c), P = (C, A) => !C || !A ? !1 : C.getDate() === A.getDate() && C.getMonth() === A.getMonth() && C.getFullYear() === A.getFullYear(), S = (C) => C ? P(C, /* @__PURE__ */ new Date()) : !1, O = (C) => C ? C.toLocaleDateString("en-US", {
|
|
3540
3540
|
year: "numeric",
|
|
3541
3541
|
month: "short",
|
|
3542
3542
|
day: "numeric"
|
|
3543
3543
|
}) : "", f = M(y);
|
|
3544
|
-
return /* @__PURE__ */ d("div", { ref:
|
|
3544
|
+
return /* @__PURE__ */ d("div", { ref: k, className: u("relative w-full", i), children: [
|
|
3545
3545
|
a && /* @__PURE__ */ r("label", { className: "block mb-1.5 text-sm font-medium text-foreground", children: a }),
|
|
3546
3546
|
/* @__PURE__ */ d(
|
|
3547
3547
|
"button",
|
|
@@ -3555,8 +3555,8 @@ const Dt = ({
|
|
|
3555
3555
|
"focus:outline-none focus:ring-2 focus:ring-primary",
|
|
3556
3556
|
"disabled:bg-secondary disabled:cursor-not-allowed",
|
|
3557
3557
|
"touch-target",
|
|
3558
|
-
|
|
3559
|
-
!
|
|
3558
|
+
s && "border-error",
|
|
3559
|
+
!s && "border-border",
|
|
3560
3560
|
m && "ring-2 ring-primary"
|
|
3561
3561
|
),
|
|
3562
3562
|
children: [
|
|
@@ -3585,7 +3585,7 @@ const Dt = ({
|
|
|
3585
3585
|
}
|
|
3586
3586
|
),
|
|
3587
3587
|
/* @__PURE__ */ d("div", { className: "font-semibold text-foreground", children: [
|
|
3588
|
-
|
|
3588
|
+
w[y.getMonth()],
|
|
3589
3589
|
" ",
|
|
3590
3590
|
y.getFullYear()
|
|
3591
3591
|
] }),
|
|
@@ -3599,7 +3599,7 @@ const Dt = ({
|
|
|
3599
3599
|
}
|
|
3600
3600
|
)
|
|
3601
3601
|
] }),
|
|
3602
|
-
/* @__PURE__ */ r("div", { className: "grid grid-cols-7 gap-1 mb-2", children:
|
|
3602
|
+
/* @__PURE__ */ r("div", { className: "grid grid-cols-7 gap-1 mb-2", children: v.map((C) => /* @__PURE__ */ r(
|
|
3603
3603
|
"div",
|
|
3604
3604
|
{
|
|
3605
3605
|
className: "text-center text-xs font-medium text-primary/70 py-2",
|
|
@@ -3644,13 +3644,13 @@ const Dt = ({
|
|
|
3644
3644
|
]
|
|
3645
3645
|
}
|
|
3646
3646
|
) }),
|
|
3647
|
-
|
|
3647
|
+
s && /* @__PURE__ */ r(
|
|
3648
3648
|
g.p,
|
|
3649
3649
|
{
|
|
3650
3650
|
initial: { opacity: 0, y: -5 },
|
|
3651
3651
|
animate: { opacity: 1, y: 0 },
|
|
3652
3652
|
className: "mt-1.5 text-sm text-error",
|
|
3653
|
-
children:
|
|
3653
|
+
children: s
|
|
3654
3654
|
}
|
|
3655
3655
|
)
|
|
3656
3656
|
] });
|
|
@@ -3659,10 +3659,10 @@ const Dt = ({
|
|
|
3659
3659
|
variant: t = "default",
|
|
3660
3660
|
padding: a = "md",
|
|
3661
3661
|
className: o,
|
|
3662
|
-
onClick:
|
|
3662
|
+
onClick: s,
|
|
3663
3663
|
hover: l = !1
|
|
3664
3664
|
}) => {
|
|
3665
|
-
const
|
|
3665
|
+
const n = {
|
|
3666
3666
|
default: "bg-background border border-border",
|
|
3667
3667
|
outlined: "bg-transparent border-2 border-border-dark",
|
|
3668
3668
|
elevated: "bg-background border-2 border-border shadow-card"
|
|
@@ -3671,23 +3671,23 @@ const Dt = ({
|
|
|
3671
3671
|
sm: "p-3",
|
|
3672
3672
|
md: "p-4 sm:p-6",
|
|
3673
3673
|
lg: "p-6 sm:p-8"
|
|
3674
|
-
}, i =
|
|
3674
|
+
}, i = s ? g.button : g.div;
|
|
3675
3675
|
return /* @__PURE__ */ r(
|
|
3676
3676
|
i,
|
|
3677
3677
|
{
|
|
3678
3678
|
initial: { opacity: 0, y: 20 },
|
|
3679
3679
|
animate: { opacity: 1, y: 0 },
|
|
3680
3680
|
transition: { duration: 0.3 },
|
|
3681
|
-
whileHover: l ||
|
|
3682
|
-
whileTap:
|
|
3681
|
+
whileHover: l || s ? { y: -2, boxShadow: "0 10px 15px -3px rgb(0 0 0 / 0.1)" } : void 0,
|
|
3682
|
+
whileTap: s ? { scale: 0.98 } : void 0,
|
|
3683
3683
|
className: u(
|
|
3684
3684
|
"rounded-lg transition-all duration-200",
|
|
3685
|
-
|
|
3685
|
+
n[t],
|
|
3686
3686
|
c[a],
|
|
3687
|
-
|
|
3687
|
+
s && "cursor-pointer w-full text-left",
|
|
3688
3688
|
o
|
|
3689
3689
|
),
|
|
3690
|
-
onClick:
|
|
3690
|
+
onClick: s,
|
|
3691
3691
|
children: e
|
|
3692
3692
|
}
|
|
3693
3693
|
);
|
|
@@ -3696,14 +3696,14 @@ const Dt = ({
|
|
|
3696
3696
|
onClose: t,
|
|
3697
3697
|
children: a,
|
|
3698
3698
|
title: o,
|
|
3699
|
-
position:
|
|
3699
|
+
position: s = "right",
|
|
3700
3700
|
className: l
|
|
3701
3701
|
}) => (Z(() => {
|
|
3702
|
-
const
|
|
3702
|
+
const n = (c) => {
|
|
3703
3703
|
c.key === "Escape" && t();
|
|
3704
3704
|
};
|
|
3705
|
-
return e && (document.addEventListener("keydown",
|
|
3706
|
-
document.removeEventListener("keydown",
|
|
3705
|
+
return e && (document.addEventListener("keydown", n), document.body.style.overflow = "hidden"), () => {
|
|
3706
|
+
document.removeEventListener("keydown", n), document.body.style.overflow = "unset";
|
|
3707
3707
|
};
|
|
3708
3708
|
}, [e, t]), /* @__PURE__ */ r(Q, { children: e && /* @__PURE__ */ d(ae, { children: [
|
|
3709
3709
|
/* @__PURE__ */ r(
|
|
@@ -3720,13 +3720,13 @@ const Dt = ({
|
|
|
3720
3720
|
/* @__PURE__ */ d(
|
|
3721
3721
|
g.div,
|
|
3722
3722
|
{
|
|
3723
|
-
initial: { x:
|
|
3723
|
+
initial: { x: s === "left" ? "-100%" : "100%" },
|
|
3724
3724
|
animate: { x: 0 },
|
|
3725
|
-
exit: { x:
|
|
3725
|
+
exit: { x: s === "left" ? "-100%" : "100%" },
|
|
3726
3726
|
transition: { type: "spring", damping: 30, stiffness: 300 },
|
|
3727
3727
|
className: u(
|
|
3728
3728
|
"fixed top-0 z-50 h-full w-[400px] sm:w-[480px] bg-background shadow-xl",
|
|
3729
|
-
|
|
3729
|
+
s === "left" ? "left-0 border-r" : "right-0 border-l",
|
|
3730
3730
|
"border-border",
|
|
3731
3731
|
l
|
|
3732
3732
|
),
|
|
@@ -3752,10 +3752,10 @@ const Dt = ({
|
|
|
3752
3752
|
onClose: t,
|
|
3753
3753
|
children: a,
|
|
3754
3754
|
title: o,
|
|
3755
|
-
size:
|
|
3755
|
+
size: s = "md",
|
|
3756
3756
|
className: l
|
|
3757
3757
|
}) => {
|
|
3758
|
-
const
|
|
3758
|
+
const n = H(null);
|
|
3759
3759
|
Z(() => {
|
|
3760
3760
|
const i = (m) => {
|
|
3761
3761
|
m.key === "Escape" && t();
|
|
@@ -3781,14 +3781,14 @@ const Dt = ({
|
|
|
3781
3781
|
children: /* @__PURE__ */ d(
|
|
3782
3782
|
g.div,
|
|
3783
3783
|
{
|
|
3784
|
-
ref:
|
|
3784
|
+
ref: n,
|
|
3785
3785
|
initial: { opacity: 0, scale: 0.95 },
|
|
3786
3786
|
animate: { opacity: 1, scale: 1 },
|
|
3787
3787
|
exit: { opacity: 0, scale: 0.95 },
|
|
3788
3788
|
transition: { duration: 0.2 },
|
|
3789
3789
|
className: u(
|
|
3790
3790
|
"bg-background border border-border rounded-lg shadow-2xl w-full max-h-[90vh] overflow-hidden flex flex-col",
|
|
3791
|
-
c[
|
|
3791
|
+
c[s],
|
|
3792
3792
|
l
|
|
3793
3793
|
),
|
|
3794
3794
|
children: [
|
|
@@ -3821,7 +3821,7 @@ const Dt = ({
|
|
|
3821
3821
|
onClose: t,
|
|
3822
3822
|
title: a,
|
|
3823
3823
|
children: o,
|
|
3824
|
-
showCloseButton:
|
|
3824
|
+
showCloseButton: s = !0,
|
|
3825
3825
|
className: l
|
|
3826
3826
|
}) => (Z(() => (e ? document.body.style.overflow = "hidden" : document.body.style.overflow = "unset", () => {
|
|
3827
3827
|
document.body.style.overflow = "unset";
|
|
@@ -3851,9 +3851,9 @@ const Dt = ({
|
|
|
3851
3851
|
),
|
|
3852
3852
|
children: [
|
|
3853
3853
|
/* @__PURE__ */ r("div", { className: "flex justify-center pt-3 pb-2", children: /* @__PURE__ */ r("div", { className: "w-12 h-1.5 bg-border-dark rounded-full" }) }),
|
|
3854
|
-
(a ||
|
|
3854
|
+
(a || s) && /* @__PURE__ */ d("div", { className: "flex items-center justify-between px-6 py-4 border-b border-border", children: [
|
|
3855
3855
|
a && /* @__PURE__ */ r("h2", { className: "text-lg font-semibold text-foreground", children: a }),
|
|
3856
|
-
|
|
3856
|
+
s && /* @__PURE__ */ r(
|
|
3857
3857
|
"button",
|
|
3858
3858
|
{
|
|
3859
3859
|
onClick: t,
|
|
@@ -3872,18 +3872,18 @@ function Vt({
|
|
|
3872
3872
|
columns: t,
|
|
3873
3873
|
loading: a = !1,
|
|
3874
3874
|
onRowClick: o,
|
|
3875
|
-
keyExtractor:
|
|
3875
|
+
keyExtractor: s,
|
|
3876
3876
|
className: l
|
|
3877
3877
|
}) {
|
|
3878
|
-
const [
|
|
3879
|
-
|
|
3880
|
-
}, y =
|
|
3881
|
-
const
|
|
3882
|
-
return
|
|
3878
|
+
const [n, c] = D(null), [i, m] = D("asc"), x = (h) => {
|
|
3879
|
+
n === h ? m(i === "asc" ? "desc" : "asc") : (c(h), m("asc"));
|
|
3880
|
+
}, y = n ? [...e].sort((h, k) => {
|
|
3881
|
+
const w = h[n], v = k[n];
|
|
3882
|
+
return w < v ? i === "asc" ? -1 : 1 : w > v ? i === "asc" ? 1 : -1 : 0;
|
|
3883
3883
|
}) : e;
|
|
3884
3884
|
return a ? /* @__PURE__ */ r("div", { className: u("border border-border rounded-lg overflow-hidden", l), children: /* @__PURE__ */ r("div", { className: "overflow-x-auto", children: /* @__PURE__ */ d("table", { className: "w-full", children: [
|
|
3885
|
-
/* @__PURE__ */ r("thead", { className: "border-b border-border", children: /* @__PURE__ */ r("tr", { children: t.map((h,
|
|
3886
|
-
/* @__PURE__ */ r("tbody", { children: [...Array(5)].map((h,
|
|
3885
|
+
/* @__PURE__ */ r("thead", { className: "border-b border-border", children: /* @__PURE__ */ r("tr", { children: t.map((h, k) => /* @__PURE__ */ r("th", { className: "px-6 py-4 text-left", children: /* @__PURE__ */ r("div", { className: "h-4 bg-border rounded w-24 animate-pulse" }) }, k)) }) }),
|
|
3886
|
+
/* @__PURE__ */ r("tbody", { children: [...Array(5)].map((h, k) => /* @__PURE__ */ r("tr", { className: "border-b border-border", children: t.map((w, v) => /* @__PURE__ */ r("td", { className: "px-6 py-4", children: /* @__PURE__ */ r("div", { className: "h-4 bg-secondary rounded animate-pulse" }) }, v)) }, k)) })
|
|
3887
3887
|
] }) }) }) : /* @__PURE__ */ r(
|
|
3888
3888
|
g.div,
|
|
3889
3889
|
{
|
|
@@ -3892,7 +3892,7 @@ function Vt({
|
|
|
3892
3892
|
transition: { duration: 0.3 },
|
|
3893
3893
|
className: u("border border-border rounded-lg overflow-hidden", l),
|
|
3894
3894
|
children: /* @__PURE__ */ r("div", { className: "overflow-x-auto", children: /* @__PURE__ */ d("table", { className: "w-full", children: [
|
|
3895
|
-
/* @__PURE__ */ r("thead", { className: "border-b border-border", children: /* @__PURE__ */ r("tr", { children: t.map((h,
|
|
3895
|
+
/* @__PURE__ */ r("thead", { className: "border-b border-border", children: /* @__PURE__ */ r("tr", { children: t.map((h, k) => /* @__PURE__ */ r(
|
|
3896
3896
|
"th",
|
|
3897
3897
|
{
|
|
3898
3898
|
className: u(
|
|
@@ -3903,37 +3903,37 @@ function Vt({
|
|
|
3903
3903
|
onClick: () => h.sortable && x(h.key),
|
|
3904
3904
|
children: /* @__PURE__ */ d("div", { className: "flex items-center gap-2", children: [
|
|
3905
3905
|
h.header,
|
|
3906
|
-
h.sortable && /* @__PURE__ */ r("span", { className: "text-primary/50 hover:text-primary transition-colors", children:
|
|
3906
|
+
h.sortable && /* @__PURE__ */ r("span", { className: "text-primary/50 hover:text-primary transition-colors", children: n === h.key ? i === "asc" ? /* @__PURE__ */ r(nr, { className: "w-4 h-4" }) : /* @__PURE__ */ r(ir, { className: "w-4 h-4" }) : /* @__PURE__ */ r(lr, { className: "w-4 h-4" }) })
|
|
3907
3907
|
] })
|
|
3908
3908
|
},
|
|
3909
|
-
|
|
3909
|
+
k
|
|
3910
3910
|
)) }) }),
|
|
3911
|
-
/* @__PURE__ */ r("tbody", { children: y.map((h,
|
|
3911
|
+
/* @__PURE__ */ r("tbody", { children: y.map((h, k) => /* @__PURE__ */ r(
|
|
3912
3912
|
g.tr,
|
|
3913
3913
|
{
|
|
3914
3914
|
initial: { opacity: 0, y: 10 },
|
|
3915
3915
|
animate: { opacity: 1, y: 0 },
|
|
3916
|
-
transition: { duration: 0.2, delay:
|
|
3916
|
+
transition: { duration: 0.2, delay: k * 0.05 },
|
|
3917
3917
|
onClick: () => o && o(h),
|
|
3918
3918
|
className: u(
|
|
3919
3919
|
"border-b border-border transition-colors",
|
|
3920
3920
|
o && "cursor-pointer hover:bg-secondary"
|
|
3921
3921
|
),
|
|
3922
|
-
children: t.map((
|
|
3922
|
+
children: t.map((w, v) => /* @__PURE__ */ r(
|
|
3923
3923
|
"td",
|
|
3924
3924
|
{
|
|
3925
3925
|
className: u(
|
|
3926
3926
|
"px-6 py-4 text-sm text-foreground/70",
|
|
3927
|
-
|
|
3927
|
+
w.width
|
|
3928
3928
|
),
|
|
3929
|
-
style:
|
|
3930
|
-
title:
|
|
3931
|
-
children:
|
|
3929
|
+
style: w.width ? { width: w.width } : void 0,
|
|
3930
|
+
title: w.truncate && !w.render ? String(h[w.key] ?? "") : void 0,
|
|
3931
|
+
children: w.truncate && !w.render ? /* @__PURE__ */ r("div", { className: "truncate", children: String(h[w.key] ?? "") }) : w.render ? w.render(h) : String(h[w.key] ?? "")
|
|
3932
3932
|
},
|
|
3933
|
-
|
|
3933
|
+
v
|
|
3934
3934
|
))
|
|
3935
3935
|
},
|
|
3936
|
-
|
|
3936
|
+
s(h)
|
|
3937
3937
|
)) })
|
|
3938
3938
|
] }) })
|
|
3939
3939
|
}
|
|
@@ -3944,7 +3944,7 @@ const Wt = ({
|
|
|
3944
3944
|
totalPages: t,
|
|
3945
3945
|
onPageChange: a,
|
|
3946
3946
|
totalItems: o,
|
|
3947
|
-
itemsPerPage:
|
|
3947
|
+
itemsPerPage: s,
|
|
3948
3948
|
className: l
|
|
3949
3949
|
}) => {
|
|
3950
3950
|
const c = Array.from({ length: t }, (i, m) => m + 1).slice(
|
|
@@ -3959,12 +3959,12 @@ const Wt = ({
|
|
|
3959
3959
|
transition: { duration: 0.3 },
|
|
3960
3960
|
className: u("flex items-center justify-between gap-4 flex-wrap", l),
|
|
3961
3961
|
children: [
|
|
3962
|
-
/* @__PURE__ */ r("div", { className: "text-sm text-foreground/70", children: o &&
|
|
3962
|
+
/* @__PURE__ */ r("div", { className: "text-sm text-foreground/70", children: o && s && /* @__PURE__ */ d("span", { children: [
|
|
3963
3963
|
"Showing ",
|
|
3964
|
-
Math.min((e - 1) *
|
|
3964
|
+
Math.min((e - 1) * s + 1, o),
|
|
3965
3965
|
" to",
|
|
3966
3966
|
" ",
|
|
3967
|
-
Math.min(e *
|
|
3967
|
+
Math.min(e * s, o),
|
|
3968
3968
|
" of ",
|
|
3969
3969
|
o,
|
|
3970
3970
|
" results"
|
|
@@ -4043,9 +4043,9 @@ const Wt = ({
|
|
|
4043
4043
|
onClick: t,
|
|
4044
4044
|
label: a,
|
|
4045
4045
|
actions: o,
|
|
4046
|
-
variant:
|
|
4046
|
+
variant: s = "primary",
|
|
4047
4047
|
position: l = "bottom-right",
|
|
4048
|
-
disabled:
|
|
4048
|
+
disabled: n,
|
|
4049
4049
|
className: c
|
|
4050
4050
|
}) => {
|
|
4051
4051
|
const [i, m] = D(!1), x = {
|
|
@@ -4060,7 +4060,7 @@ const Wt = ({
|
|
|
4060
4060
|
success: "bg-success text-white",
|
|
4061
4061
|
danger: "bg-error text-white",
|
|
4062
4062
|
warning: "bg-warning text-white"
|
|
4063
|
-
},
|
|
4063
|
+
}, k = () => {
|
|
4064
4064
|
o && o.length > 0 ? m(!i) : t && t();
|
|
4065
4065
|
};
|
|
4066
4066
|
return /* @__PURE__ */ d("div", { className: u(x[l], "z-50", c), children: [
|
|
@@ -4071,49 +4071,59 @@ const Wt = ({
|
|
|
4071
4071
|
animate: { opacity: 1 },
|
|
4072
4072
|
exit: { opacity: 0 },
|
|
4073
4073
|
className: "absolute bottom-20 right-0 flex flex-col gap-3 mb-2",
|
|
4074
|
-
children: o.map((
|
|
4074
|
+
children: o.map((w, v) => /* @__PURE__ */ d(
|
|
4075
4075
|
g.div,
|
|
4076
4076
|
{
|
|
4077
4077
|
initial: { opacity: 0, y: 20, scale: 0.8 },
|
|
4078
4078
|
animate: { opacity: 1, y: 0, scale: 1 },
|
|
4079
4079
|
exit: { opacity: 0, y: 20, scale: 0.8 },
|
|
4080
|
-
transition: { delay:
|
|
4080
|
+
transition: { delay: v * 0.05 },
|
|
4081
4081
|
className: "flex items-center gap-3",
|
|
4082
4082
|
children: [
|
|
4083
|
-
/* @__PURE__ */ r(
|
|
4083
|
+
/* @__PURE__ */ r(
|
|
4084
|
+
"span",
|
|
4085
|
+
{
|
|
4086
|
+
className: u(
|
|
4087
|
+
"bg-background border border-border rounded-md px-3 py-1.5 text-sm font-medium whitespace-nowrap shadow-lg",
|
|
4088
|
+
w.labelClassName
|
|
4089
|
+
),
|
|
4090
|
+
style: w.labelStyle,
|
|
4091
|
+
children: w.label
|
|
4092
|
+
}
|
|
4093
|
+
),
|
|
4084
4094
|
/* @__PURE__ */ r(
|
|
4085
4095
|
g.button,
|
|
4086
4096
|
{
|
|
4087
4097
|
whileHover: { scale: 1.1 },
|
|
4088
4098
|
whileTap: { scale: 0.9 },
|
|
4089
4099
|
onClick: () => {
|
|
4090
|
-
|
|
4100
|
+
w.onClick(), m(!1);
|
|
4091
4101
|
},
|
|
4092
4102
|
className: u(
|
|
4093
4103
|
"w-12 h-12 rounded-full shadow-lg flex items-center justify-center transition-all",
|
|
4094
|
-
h[
|
|
4104
|
+
h[w.variant || "primary"]
|
|
4095
4105
|
),
|
|
4096
|
-
children:
|
|
4106
|
+
children: w.icon
|
|
4097
4107
|
}
|
|
4098
4108
|
)
|
|
4099
4109
|
]
|
|
4100
4110
|
},
|
|
4101
|
-
|
|
4111
|
+
v
|
|
4102
4112
|
))
|
|
4103
4113
|
}
|
|
4104
4114
|
) }),
|
|
4105
4115
|
/* @__PURE__ */ d(
|
|
4106
4116
|
g.button,
|
|
4107
4117
|
{
|
|
4108
|
-
whileTap: { scale:
|
|
4109
|
-
whileHover: { scale:
|
|
4110
|
-
onClick:
|
|
4111
|
-
disabled:
|
|
4118
|
+
whileTap: { scale: n ? 1 : 0.9 },
|
|
4119
|
+
whileHover: { scale: n ? 1 : 1.05 },
|
|
4120
|
+
onClick: k,
|
|
4121
|
+
disabled: n,
|
|
4112
4122
|
className: u(
|
|
4113
4123
|
"z-30 rounded-full p-4 transition-all duration-200",
|
|
4114
4124
|
"disabled:opacity-50 disabled:cursor-not-allowed",
|
|
4115
4125
|
"flex items-center gap-2",
|
|
4116
|
-
y[
|
|
4126
|
+
y[s],
|
|
4117
4127
|
a ? "px-6" : "w-16 h-16 justify-center",
|
|
4118
4128
|
i && "rotate-45"
|
|
4119
4129
|
),
|
|
@@ -4131,8 +4141,8 @@ const Wt = ({
|
|
|
4131
4141
|
}) => {
|
|
4132
4142
|
const o = e[t];
|
|
4133
4143
|
return /* @__PURE__ */ d("div", { className: u("w-full", a), children: [
|
|
4134
|
-
/* @__PURE__ */ r("div", { className: "hidden md:block", children: /* @__PURE__ */ r("div", { className: "relative flex items-center mb-2", children: e.map((
|
|
4135
|
-
const
|
|
4144
|
+
/* @__PURE__ */ r("div", { className: "hidden md:block", children: /* @__PURE__ */ r("div", { className: "relative flex items-center mb-2", children: e.map((s, l) => {
|
|
4145
|
+
const n = l < t, c = l === t, i = l > t;
|
|
4136
4146
|
return /* @__PURE__ */ d(Le.Fragment, { children: [
|
|
4137
4147
|
/* @__PURE__ */ d("div", { className: "flex flex-col items-center relative z-10", children: [
|
|
4138
4148
|
/* @__PURE__ */ r(
|
|
@@ -4140,17 +4150,16 @@ const Wt = ({
|
|
|
4140
4150
|
{
|
|
4141
4151
|
initial: !1,
|
|
4142
4152
|
animate: {
|
|
4143
|
-
scale: c ? 1.05 : 1
|
|
4144
|
-
backgroundColor: s || c ? "var(--color-primary)" : "var(--color-border)"
|
|
4153
|
+
scale: c ? 1.05 : 1
|
|
4145
4154
|
},
|
|
4146
4155
|
className: u(
|
|
4147
4156
|
"w-12 h-12 rounded-full flex items-center justify-center",
|
|
4148
4157
|
"font-semibold text-base transition-all duration-300",
|
|
4149
|
-
|
|
4150
|
-
|
|
4151
|
-
"
|
|
4158
|
+
"ring-4 ring-white",
|
|
4159
|
+
(n || c) && "bg-primary text-white shadow-lg",
|
|
4160
|
+
i && "bg-border text-muted-foreground"
|
|
4152
4161
|
),
|
|
4153
|
-
children:
|
|
4162
|
+
children: n ? /* @__PURE__ */ r(Oe, { className: "w-6 h-6 stroke-[3]" }) : /* @__PURE__ */ r("span", { children: l + 1 })
|
|
4154
4163
|
}
|
|
4155
4164
|
),
|
|
4156
4165
|
/* @__PURE__ */ d("div", { className: "mt-3 text-center max-w-[120px]", children: [
|
|
@@ -4160,22 +4169,22 @@ const Wt = ({
|
|
|
4160
4169
|
className: u(
|
|
4161
4170
|
"text-sm font-semibold block",
|
|
4162
4171
|
c && "text-primary",
|
|
4163
|
-
|
|
4172
|
+
n && "text-primary",
|
|
4164
4173
|
i && "text-primary/50"
|
|
4165
4174
|
),
|
|
4166
|
-
children:
|
|
4175
|
+
children: s.label
|
|
4167
4176
|
}
|
|
4168
4177
|
),
|
|
4169
|
-
|
|
4178
|
+
s.description && /* @__PURE__ */ r(
|
|
4170
4179
|
"p",
|
|
4171
4180
|
{
|
|
4172
4181
|
className: u(
|
|
4173
4182
|
"text-xs mt-1 leading-tight",
|
|
4174
4183
|
c && "text-primary",
|
|
4175
|
-
|
|
4184
|
+
n && "text-primary/70",
|
|
4176
4185
|
i && "text-primary/50"
|
|
4177
4186
|
),
|
|
4178
|
-
children:
|
|
4187
|
+
children: s.description
|
|
4179
4188
|
}
|
|
4180
4189
|
)
|
|
4181
4190
|
] })
|
|
@@ -4194,20 +4203,20 @@ const Wt = ({
|
|
|
4194
4203
|
] }, l);
|
|
4195
4204
|
}) }) }),
|
|
4196
4205
|
/* @__PURE__ */ d("div", { className: "md:hidden", children: [
|
|
4197
|
-
/* @__PURE__ */ r("div", { className: "flex items-center justify-center gap-2 mb-3", children: e.map((
|
|
4198
|
-
const
|
|
4206
|
+
/* @__PURE__ */ r("div", { className: "flex items-center justify-center gap-2 mb-3", children: e.map((s, l) => {
|
|
4207
|
+
const n = l < t, c = l === t;
|
|
4199
4208
|
return /* @__PURE__ */ r(
|
|
4200
4209
|
g.div,
|
|
4201
4210
|
{
|
|
4202
4211
|
initial: !1,
|
|
4203
4212
|
animate: {
|
|
4204
4213
|
scale: c ? 1.2 : 1,
|
|
4205
|
-
backgroundColor:
|
|
4214
|
+
backgroundColor: n || c ? "var(--color-primary)" : "var(--color-border-dark)"
|
|
4206
4215
|
},
|
|
4207
4216
|
className: u(
|
|
4208
4217
|
"rounded-full transition-all duration-300",
|
|
4209
4218
|
c ? "w-3 h-3" : "w-2 h-2",
|
|
4210
|
-
(
|
|
4219
|
+
(n || c) && "shadow-sm"
|
|
4211
4220
|
)
|
|
4212
4221
|
},
|
|
4213
4222
|
l
|
|
@@ -4231,7 +4240,7 @@ const Wt = ({
|
|
|
4231
4240
|
variant: t = "default",
|
|
4232
4241
|
size: a = "md",
|
|
4233
4242
|
className: o,
|
|
4234
|
-
dot:
|
|
4243
|
+
dot: s = !1
|
|
4235
4244
|
}) => {
|
|
4236
4245
|
const l = {
|
|
4237
4246
|
default: "bg-secondary text-primary border border-border",
|
|
@@ -4240,7 +4249,7 @@ const Wt = ({
|
|
|
4240
4249
|
warning: "bg-warning/10 text-warning border border-warning/20",
|
|
4241
4250
|
danger: "bg-error/10 text-error border border-error/20",
|
|
4242
4251
|
info: "bg-info/10 text-info border border-info/20"
|
|
4243
|
-
},
|
|
4252
|
+
}, n = {
|
|
4244
4253
|
sm: "px-2 py-0.5 text-xs",
|
|
4245
4254
|
md: "px-2.5 py-1 text-sm",
|
|
4246
4255
|
lg: "px-3 py-1.5 text-base"
|
|
@@ -4261,11 +4270,11 @@ const Wt = ({
|
|
|
4261
4270
|
className: u(
|
|
4262
4271
|
"inline-flex items-center gap-1.5 rounded-lg font-medium",
|
|
4263
4272
|
l[t],
|
|
4264
|
-
|
|
4273
|
+
n[a],
|
|
4265
4274
|
o
|
|
4266
4275
|
),
|
|
4267
4276
|
children: [
|
|
4268
|
-
|
|
4277
|
+
s && /* @__PURE__ */ r("span", { className: u("w-1.5 h-1.5 rounded-full", c[t]) }),
|
|
4269
4278
|
e
|
|
4270
4279
|
]
|
|
4271
4280
|
}
|
|
@@ -4294,7 +4303,7 @@ const Wt = ({
|
|
|
4294
4303
|
count: t,
|
|
4295
4304
|
className: a
|
|
4296
4305
|
}) => {
|
|
4297
|
-
const
|
|
4306
|
+
const s = {
|
|
4298
4307
|
synced: {
|
|
4299
4308
|
icon: /* @__PURE__ */ r(Te, { className: "w-4 h-4" }),
|
|
4300
4309
|
label: "Synced",
|
|
@@ -4324,12 +4333,12 @@ const Wt = ({
|
|
|
4324
4333
|
className: u(
|
|
4325
4334
|
"inline-flex items-center gap-2 px-3 py-1.5 rounded-full",
|
|
4326
4335
|
"text-sm font-medium shadow-sm",
|
|
4327
|
-
|
|
4336
|
+
s.color,
|
|
4328
4337
|
a
|
|
4329
4338
|
),
|
|
4330
4339
|
children: [
|
|
4331
|
-
|
|
4332
|
-
/* @__PURE__ */ r("span", { children:
|
|
4340
|
+
s.icon,
|
|
4341
|
+
/* @__PURE__ */ r("span", { children: s.label })
|
|
4333
4342
|
]
|
|
4334
4343
|
}
|
|
4335
4344
|
);
|
|
@@ -4394,7 +4403,7 @@ const Ze = er(void 0), Kt = () => {
|
|
|
4394
4403
|
"bottom-center": "bottom-4 left-1/2 -translate-x-1/2",
|
|
4395
4404
|
"bottom-right": "bottom-4 right-4"
|
|
4396
4405
|
}, kt = ({ toast: e, onRemove: t }) => {
|
|
4397
|
-
const a = e.variant || "default", o = vt[a];
|
|
4406
|
+
const a = e.variant || "default", o = vt[a], s = typeof e.message == "string" ? e.message : String(e.message);
|
|
4398
4407
|
return /* @__PURE__ */ d(
|
|
4399
4408
|
g.div,
|
|
4400
4409
|
{
|
|
@@ -4410,7 +4419,7 @@ const Ze = er(void 0), Kt = () => {
|
|
|
4410
4419
|
children: [
|
|
4411
4420
|
o && /* @__PURE__ */ r(o, { className: "w-5 h-5 flex-shrink-0 mt-0.5" }),
|
|
4412
4421
|
/* @__PURE__ */ d("div", { className: "flex-1 min-w-0", children: [
|
|
4413
|
-
/* @__PURE__ */ r("p", { className: "text-sm font-medium leading-relaxed", children:
|
|
4422
|
+
/* @__PURE__ */ r("p", { className: "text-sm font-medium leading-relaxed", children: s }),
|
|
4414
4423
|
e.action && /* @__PURE__ */ r(
|
|
4415
4424
|
"button",
|
|
4416
4425
|
{
|
|
@@ -4437,20 +4446,24 @@ const Ze = er(void 0), Kt = () => {
|
|
|
4437
4446
|
position: t = "top-right",
|
|
4438
4447
|
maxToasts: a = 5
|
|
4439
4448
|
}) => {
|
|
4440
|
-
const [o,
|
|
4449
|
+
const [o, s] = D([]), l = ze((c) => {
|
|
4450
|
+
s((i) => i.filter((m) => m.id !== c));
|
|
4451
|
+
}, []), n = ze(
|
|
4441
4452
|
(c) => {
|
|
4453
|
+
if (typeof c.message != "string") {
|
|
4454
|
+
console.error("Toast message must be a string, received:", c.message);
|
|
4455
|
+
return;
|
|
4456
|
+
}
|
|
4442
4457
|
const i = Math.random().toString(36).substring(2, 9), m = c.duration ?? 5e3;
|
|
4443
|
-
|
|
4444
|
-
|
|
4458
|
+
s((x) => [...x, { ...c, id: i }].slice(-a)), m > 0 && setTimeout(() => {
|
|
4459
|
+
l(i);
|
|
4445
4460
|
}, m);
|
|
4446
4461
|
},
|
|
4447
|
-
[a]
|
|
4448
|
-
)
|
|
4449
|
-
|
|
4450
|
-
}, []);
|
|
4451
|
-
return /* @__PURE__ */ d(Ze.Provider, { value: { toasts: o, addToast: l, removeToast: s }, children: [
|
|
4462
|
+
[a, l]
|
|
4463
|
+
);
|
|
4464
|
+
return /* @__PURE__ */ d(Ze.Provider, { value: { toasts: o, addToast: n, removeToast: l }, children: [
|
|
4452
4465
|
e,
|
|
4453
|
-
/* @__PURE__ */ r("div", { className: u("fixed z-[100] flex flex-col gap-2", Nt[t]), children: /* @__PURE__ */ r(Q, { mode: "popLayout", children: o.map((c) => /* @__PURE__ */ r(kt, { toast: c, onRemove:
|
|
4466
|
+
/* @__PURE__ */ r("div", { className: u("fixed z-[100] flex flex-col gap-2", Nt[t]), children: /* @__PURE__ */ r(Q, { mode: "popLayout", children: o.map((c) => /* @__PURE__ */ r(kt, { toast: c, onRemove: l }, c.id)) }) })
|
|
4454
4467
|
] });
|
|
4455
4468
|
};
|
|
4456
4469
|
Ct.displayName = "ToastProvider";
|
|
@@ -4459,10 +4472,10 @@ const Xt = ({
|
|
|
4459
4472
|
onRemove: t,
|
|
4460
4473
|
preview: a,
|
|
4461
4474
|
label: o = "Take Photo",
|
|
4462
|
-
disabled:
|
|
4475
|
+
disabled: s,
|
|
4463
4476
|
className: l
|
|
4464
4477
|
}) => {
|
|
4465
|
-
const
|
|
4478
|
+
const n = H(null), c = (i) => {
|
|
4466
4479
|
const m = i.target.files?.[0];
|
|
4467
4480
|
m && e(m);
|
|
4468
4481
|
};
|
|
@@ -4489,9 +4502,9 @@ const Xt = ({
|
|
|
4489
4502
|
g.button,
|
|
4490
4503
|
{
|
|
4491
4504
|
type: "button",
|
|
4492
|
-
whileTap: { scale:
|
|
4493
|
-
onClick: () =>
|
|
4494
|
-
disabled:
|
|
4505
|
+
whileTap: { scale: s ? 1 : 0.98 },
|
|
4506
|
+
onClick: () => n.current?.click(),
|
|
4507
|
+
disabled: s,
|
|
4495
4508
|
className: u(
|
|
4496
4509
|
"w-full p-4 rounded-lg border-2 border-border",
|
|
4497
4510
|
"flex items-center justify-center gap-3",
|
|
@@ -4508,13 +4521,13 @@ const Xt = ({
|
|
|
4508
4521
|
/* @__PURE__ */ r(
|
|
4509
4522
|
"input",
|
|
4510
4523
|
{
|
|
4511
|
-
ref:
|
|
4524
|
+
ref: n,
|
|
4512
4525
|
type: "file",
|
|
4513
4526
|
accept: "image/*",
|
|
4514
4527
|
capture: "environment",
|
|
4515
4528
|
onChange: c,
|
|
4516
4529
|
className: "hidden",
|
|
4517
|
-
disabled:
|
|
4530
|
+
disabled: s
|
|
4518
4531
|
}
|
|
4519
4532
|
)
|
|
4520
4533
|
] });
|
|
@@ -4523,10 +4536,10 @@ const Xt = ({
|
|
|
4523
4536
|
accept: t = "*/*",
|
|
4524
4537
|
multiple: a = !1,
|
|
4525
4538
|
label: o = "Upload Files",
|
|
4526
|
-
disabled:
|
|
4539
|
+
disabled: s,
|
|
4527
4540
|
className: l
|
|
4528
4541
|
}) => {
|
|
4529
|
-
const
|
|
4542
|
+
const n = H(null), c = (i) => {
|
|
4530
4543
|
i && e(Array.from(i));
|
|
4531
4544
|
};
|
|
4532
4545
|
return /* @__PURE__ */ d("div", { className: u("w-full", l), children: [
|
|
@@ -4535,9 +4548,9 @@ const Xt = ({
|
|
|
4535
4548
|
g.button,
|
|
4536
4549
|
{
|
|
4537
4550
|
type: "button",
|
|
4538
|
-
whileTap: { scale:
|
|
4539
|
-
onClick: () => !
|
|
4540
|
-
disabled:
|
|
4551
|
+
whileTap: { scale: s ? 1 : 0.98 },
|
|
4552
|
+
onClick: () => !s && n.current?.click(),
|
|
4553
|
+
disabled: s,
|
|
4541
4554
|
className: u(
|
|
4542
4555
|
"w-full p-4 rounded-lg border-2 border-border",
|
|
4543
4556
|
"flex items-center justify-center gap-3",
|
|
@@ -4554,13 +4567,13 @@ const Xt = ({
|
|
|
4554
4567
|
/* @__PURE__ */ r(
|
|
4555
4568
|
"input",
|
|
4556
4569
|
{
|
|
4557
|
-
ref:
|
|
4570
|
+
ref: n,
|
|
4558
4571
|
type: "file",
|
|
4559
4572
|
accept: t,
|
|
4560
4573
|
multiple: a,
|
|
4561
4574
|
onChange: (i) => c(i.target.files),
|
|
4562
4575
|
className: "hidden",
|
|
4563
|
-
disabled:
|
|
4576
|
+
disabled: s
|
|
4564
4577
|
}
|
|
4565
4578
|
)
|
|
4566
4579
|
] });
|
|
@@ -4570,37 +4583,37 @@ const Xt = ({
|
|
|
4570
4583
|
maxDuration: a = 300,
|
|
4571
4584
|
// 5 minutes default
|
|
4572
4585
|
disabled: o,
|
|
4573
|
-
className:
|
|
4586
|
+
className: s
|
|
4574
4587
|
}) => {
|
|
4575
|
-
const [l,
|
|
4588
|
+
const [l, n] = D(!1), [c, i] = D(!1), [m, x] = D(0), [y, h] = D(null), k = H(null), w = H([]), v = H(null), M = async () => {
|
|
4576
4589
|
try {
|
|
4577
4590
|
const S = await navigator.mediaDevices.getUserMedia({ audio: !0 }), O = new MediaRecorder(S);
|
|
4578
|
-
|
|
4579
|
-
f.data.size > 0 &&
|
|
4591
|
+
k.current = O, w.current = [], O.ondataavailable = (f) => {
|
|
4592
|
+
f.data.size > 0 && w.current.push(f.data);
|
|
4580
4593
|
}, O.onstop = () => {
|
|
4581
|
-
const f = new Blob(
|
|
4594
|
+
const f = new Blob(w.current, { type: "audio/webm" }), C = URL.createObjectURL(f);
|
|
4582
4595
|
h(C), e(f), S.getTracks().forEach((A) => A.stop());
|
|
4583
|
-
}, O.start(),
|
|
4596
|
+
}, O.start(), n(!0), x(0), v.current = setInterval(() => {
|
|
4584
4597
|
x((f) => f >= a ? (T(), f) : f + 1);
|
|
4585
4598
|
}, 1e3);
|
|
4586
4599
|
} catch (S) {
|
|
4587
4600
|
console.error("Error accessing microphone:", S);
|
|
4588
4601
|
}
|
|
4589
4602
|
}, j = () => {
|
|
4590
|
-
|
|
4603
|
+
k.current?.state === "recording" && (k.current.pause(), i(!0), v.current && clearInterval(v.current));
|
|
4591
4604
|
}, L = () => {
|
|
4592
|
-
|
|
4605
|
+
k.current?.state === "paused" && (k.current.resume(), i(!1), v.current = setInterval(() => {
|
|
4593
4606
|
x((S) => Math.min(S + 1, a));
|
|
4594
4607
|
}, 1e3));
|
|
4595
4608
|
}, T = () => {
|
|
4596
|
-
|
|
4609
|
+
k.current && (k.current.stop(), n(!1), i(!1), v.current && (clearInterval(v.current), v.current = null));
|
|
4597
4610
|
}, F = () => {
|
|
4598
4611
|
h(null), x(0);
|
|
4599
4612
|
}, P = (S) => {
|
|
4600
4613
|
const O = Math.floor(S / 60), f = S % 60;
|
|
4601
4614
|
return `${O.toString().padStart(2, "0")}:${f.toString().padStart(2, "0")}`;
|
|
4602
4615
|
};
|
|
4603
|
-
return /* @__PURE__ */ d("div", { className: u("w-full",
|
|
4616
|
+
return /* @__PURE__ */ d("div", { className: u("w-full", s), children: [
|
|
4604
4617
|
t && /* @__PURE__ */ r("label", { className: "block mb-2 text-sm font-medium text-primary", children: t }),
|
|
4605
4618
|
/* @__PURE__ */ d("div", { className: "p-4 md:p-6 bg-background rounded-lg border-2 border-border space-y-4", children: [
|
|
4606
4619
|
!y && /* @__PURE__ */ d("div", { className: "flex flex-col items-center gap-4", children: [
|
|
@@ -4685,13 +4698,13 @@ const Xt = ({
|
|
|
4685
4698
|
onRemove: t,
|
|
4686
4699
|
onView: a,
|
|
4687
4700
|
columns: o = 3,
|
|
4688
|
-
className:
|
|
4701
|
+
className: s
|
|
4689
4702
|
}) => {
|
|
4690
4703
|
const l = {
|
|
4691
4704
|
2: "grid-cols-2",
|
|
4692
4705
|
3: "grid-cols-3",
|
|
4693
4706
|
4: "grid-cols-4"
|
|
4694
|
-
},
|
|
4707
|
+
}, n = (i) => {
|
|
4695
4708
|
if (!i) return "";
|
|
4696
4709
|
const m = i / 1024;
|
|
4697
4710
|
return m < 1024 ? `${m.toFixed(1)} KB` : `${(m / 1024).toFixed(1)} MB`;
|
|
@@ -4705,7 +4718,7 @@ const Xt = ({
|
|
|
4705
4718
|
return /* @__PURE__ */ r(vr, { className: "w-8 h-8 text-primary" });
|
|
4706
4719
|
}
|
|
4707
4720
|
};
|
|
4708
|
-
return e.length === 0 ? null : /* @__PURE__ */ r("div", { className: u("w-full",
|
|
4721
|
+
return e.length === 0 ? null : /* @__PURE__ */ r("div", { className: u("w-full", s), children: /* @__PURE__ */ r("div", { className: u("grid gap-3", l[o]), children: e.map((i) => /* @__PURE__ */ d(
|
|
4709
4722
|
g.div,
|
|
4710
4723
|
{
|
|
4711
4724
|
initial: { opacity: 0, scale: 0.8 },
|
|
@@ -4750,7 +4763,7 @@ const Xt = ({
|
|
|
4750
4763
|
),
|
|
4751
4764
|
i.size && /* @__PURE__ */ d("div", { className: "absolute bottom-0 left-0 right-0 bg-black/60 text-white text-xs p-1.5 backdrop-blur-sm", children: [
|
|
4752
4765
|
/* @__PURE__ */ r("p", { className: "truncate", children: i.name }),
|
|
4753
|
-
/* @__PURE__ */ r("p", { className: "text-white/70", children:
|
|
4766
|
+
/* @__PURE__ */ r("p", { className: "text-white/70", children: n(i.size) })
|
|
4754
4767
|
] })
|
|
4755
4768
|
]
|
|
4756
4769
|
},
|
|
@@ -4761,9 +4774,9 @@ const Xt = ({
|
|
|
4761
4774
|
showHeart: t = !0,
|
|
4762
4775
|
href: a,
|
|
4763
4776
|
position: o = "fixed",
|
|
4764
|
-
backgroundColor:
|
|
4777
|
+
backgroundColor: s = "bg-gray-900",
|
|
4765
4778
|
textColor: l = "text-gray-400",
|
|
4766
|
-
className:
|
|
4779
|
+
className: n = ""
|
|
4767
4780
|
}) => {
|
|
4768
4781
|
const c = t ? /* @__PURE__ */ d(ae, { children: [
|
|
4769
4782
|
"Built with ",
|
|
@@ -4783,7 +4796,7 @@ const Xt = ({
|
|
|
4783
4796
|
return /* @__PURE__ */ r(
|
|
4784
4797
|
"div",
|
|
4785
4798
|
{
|
|
4786
|
-
className: `${o} bottom-0 left-0 right-0 ${
|
|
4799
|
+
className: `${o} bottom-0 left-0 right-0 ${s} ${n}`,
|
|
4787
4800
|
style: { zIndex: 40 },
|
|
4788
4801
|
children: /* @__PURE__ */ r("div", { className: "flex items-center justify-center py-2 px-4", children: i })
|
|
4789
4802
|
}
|