sls-ui-library 1.0.1 → 1.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/sls-ui.es.js CHANGED
@@ -1,649 +1,24 @@
1
- import * as v from "react";
2
- import Je, { forwardRef as Ge, createElement as xe } from "react";
3
- import { createPortal as Xe } from "react-dom";
4
- var me = { exports: {} }, Z = {};
5
- /**
6
- * @license React
7
- * react-jsx-runtime.production.min.js
8
- *
9
- * Copyright (c) Facebook, Inc. and its affiliates.
10
- *
11
- * This source code is licensed under the MIT license found in the
12
- * LICENSE file in the root directory of this source tree.
13
- */
14
- var Ve;
15
- function Ft() {
16
- if (Ve) return Z;
17
- Ve = 1;
18
- var n = Je, r = Symbol.for("react.element"), s = Symbol.for("react.fragment"), a = Object.prototype.hasOwnProperty, i = n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, l = { key: !0, ref: !0, __self: !0, __source: !0 };
19
- function f(h, c, m) {
20
- var d, x = {}, y = null, D = null;
21
- m !== void 0 && (y = "" + m), c.key !== void 0 && (y = "" + c.key), c.ref !== void 0 && (D = c.ref);
22
- for (d in c) a.call(c, d) && !l.hasOwnProperty(d) && (x[d] = c[d]);
23
- if (h && h.defaultProps) for (d in c = h.defaultProps, c) x[d] === void 0 && (x[d] = c[d]);
24
- return { $$typeof: r, type: h, key: y, ref: D, props: x, _owner: i.current };
25
- }
26
- return Z.Fragment = s, Z.jsx = f, Z.jsxs = f, Z;
27
- }
28
- var Q = {};
29
- /**
30
- * @license React
31
- * react-jsx-runtime.development.js
32
- *
33
- * Copyright (c) Facebook, Inc. and its affiliates.
34
- *
35
- * This source code is licensed under the MIT license found in the
36
- * LICENSE file in the root directory of this source tree.
37
- */
38
- var qe;
39
- function It() {
40
- return qe || (qe = 1, process.env.NODE_ENV !== "production" && function() {
41
- var n = Je, r = Symbol.for("react.element"), s = Symbol.for("react.portal"), a = Symbol.for("react.fragment"), i = Symbol.for("react.strict_mode"), l = Symbol.for("react.profiler"), f = Symbol.for("react.provider"), h = Symbol.for("react.context"), c = Symbol.for("react.forward_ref"), m = Symbol.for("react.suspense"), d = Symbol.for("react.suspense_list"), x = Symbol.for("react.memo"), y = Symbol.for("react.lazy"), D = Symbol.for("react.offscreen"), O = Symbol.iterator, j = "@@iterator";
42
- function _(t) {
43
- if (t === null || typeof t != "object")
44
- return null;
45
- var o = O && t[O] || t[j];
46
- return typeof o == "function" ? o : null;
47
- }
48
- var C = n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
49
- function T(t) {
50
- {
51
- for (var o = arguments.length, u = new Array(o > 1 ? o - 1 : 0), p = 1; p < o; p++)
52
- u[p - 1] = arguments[p];
53
- H("error", t, u);
54
- }
55
- }
56
- function H(t, o, u) {
57
- {
58
- var p = C.ReactDebugCurrentFrame, R = p.getStackAddendum();
59
- R !== "" && (o += "%s", u = u.concat([R]));
60
- var E = u.map(function(w) {
61
- return String(w);
62
- });
63
- E.unshift("Warning: " + o), Function.prototype.apply.call(console[t], console, E);
64
- }
65
- }
66
- var J = !1, N = !1, k = !1, I = !1, lt = !1, ve;
67
- ve = Symbol.for("react.module.reference");
68
- function ct(t) {
69
- return !!(typeof t == "string" || typeof t == "function" || t === a || t === l || lt || t === i || t === m || t === d || I || t === D || J || N || k || typeof t == "object" && t !== null && (t.$$typeof === y || t.$$typeof === x || t.$$typeof === f || t.$$typeof === h || t.$$typeof === c || // This needs to include all possible module reference object
70
- // types supported by any Flight configuration anywhere since
71
- // we don't know which Flight build this will end up being used
72
- // with.
73
- t.$$typeof === ve || t.getModuleId !== void 0));
74
- }
75
- function dt(t, o, u) {
76
- var p = t.displayName;
77
- if (p)
78
- return p;
79
- var R = o.displayName || o.name || "";
80
- return R !== "" ? u + "(" + R + ")" : u;
81
- }
82
- function ge(t) {
83
- return t.displayName || "Context";
84
- }
85
- function $(t) {
86
- if (t == null)
87
- return null;
88
- if (typeof t.tag == "number" && T("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof t == "function")
89
- return t.displayName || t.name || null;
90
- if (typeof t == "string")
91
- return t;
92
- switch (t) {
93
- case a:
94
- return "Fragment";
95
- case s:
96
- return "Portal";
97
- case l:
98
- return "Profiler";
99
- case i:
100
- return "StrictMode";
101
- case m:
102
- return "Suspense";
103
- case d:
104
- return "SuspenseList";
105
- }
106
- if (typeof t == "object")
107
- switch (t.$$typeof) {
108
- case h:
109
- var o = t;
110
- return ge(o) + ".Consumer";
111
- case f:
112
- var u = t;
113
- return ge(u._context) + ".Provider";
114
- case c:
115
- return dt(t, t.render, "ForwardRef");
116
- case x:
117
- var p = t.displayName || null;
118
- return p !== null ? p : $(t.type) || "Memo";
119
- case y: {
120
- var R = t, E = R._payload, w = R._init;
121
- try {
122
- return $(w(E));
123
- } catch {
124
- return null;
125
- }
126
- }
127
- }
128
- return null;
129
- }
130
- var Y = Object.assign, G = 0, ye, je, ke, we, Ne, Ce, Re;
131
- function Ee() {
132
- }
133
- Ee.__reactDisabledLog = !0;
134
- function ut() {
135
- {
136
- if (G === 0) {
137
- ye = console.log, je = console.info, ke = console.warn, we = console.error, Ne = console.group, Ce = console.groupCollapsed, Re = console.groupEnd;
138
- var t = {
139
- configurable: !0,
140
- enumerable: !0,
141
- value: Ee,
142
- writable: !0
143
- };
144
- Object.defineProperties(console, {
145
- info: t,
146
- log: t,
147
- warn: t,
148
- error: t,
149
- group: t,
150
- groupCollapsed: t,
151
- groupEnd: t
152
- });
153
- }
154
- G++;
155
- }
156
- }
157
- function ft() {
158
- {
159
- if (G--, G === 0) {
160
- var t = {
161
- configurable: !0,
162
- enumerable: !0,
163
- writable: !0
164
- };
165
- Object.defineProperties(console, {
166
- log: Y({}, t, {
167
- value: ye
168
- }),
169
- info: Y({}, t, {
170
- value: je
171
- }),
172
- warn: Y({}, t, {
173
- value: ke
174
- }),
175
- error: Y({}, t, {
176
- value: we
177
- }),
178
- group: Y({}, t, {
179
- value: Ne
180
- }),
181
- groupCollapsed: Y({}, t, {
182
- value: Ce
183
- }),
184
- groupEnd: Y({}, t, {
185
- value: Re
186
- })
187
- });
188
- }
189
- G < 0 && T("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
190
- }
191
- }
192
- var ae = C.ReactCurrentDispatcher, ie;
193
- function K(t, o, u) {
194
- {
195
- if (ie === void 0)
196
- try {
197
- throw Error();
198
- } catch (R) {
199
- var p = R.stack.trim().match(/\n( *(at )?)/);
200
- ie = p && p[1] || "";
201
- }
202
- return `
203
- ` + ie + t;
204
- }
205
- }
206
- var oe = !1, ee;
207
- {
208
- var xt = typeof WeakMap == "function" ? WeakMap : Map;
209
- ee = new xt();
210
- }
211
- function Se(t, o) {
212
- if (!t || oe)
213
- return "";
214
- {
215
- var u = ee.get(t);
216
- if (u !== void 0)
217
- return u;
218
- }
219
- var p;
220
- oe = !0;
221
- var R = Error.prepareStackTrace;
222
- Error.prepareStackTrace = void 0;
223
- var E;
224
- E = ae.current, ae.current = null, ut();
225
- try {
226
- if (o) {
227
- var w = function() {
228
- throw Error();
229
- };
230
- if (Object.defineProperty(w.prototype, "props", {
231
- set: function() {
232
- throw Error();
233
- }
234
- }), typeof Reflect == "object" && Reflect.construct) {
235
- try {
236
- Reflect.construct(w, []);
237
- } catch (A) {
238
- p = A;
239
- }
240
- Reflect.construct(t, [], w);
241
- } else {
242
- try {
243
- w.call();
244
- } catch (A) {
245
- p = A;
246
- }
247
- t.call(w.prototype);
248
- }
249
- } else {
250
- try {
251
- throw Error();
252
- } catch (A) {
253
- p = A;
254
- }
255
- t();
256
- }
257
- } catch (A) {
258
- if (A && p && typeof A.stack == "string") {
259
- for (var g = A.stack.split(`
260
- `), z = p.stack.split(`
261
- `), M = g.length - 1, P = z.length - 1; M >= 1 && P >= 0 && g[M] !== z[P]; )
262
- P--;
263
- for (; M >= 1 && P >= 0; M--, P--)
264
- if (g[M] !== z[P]) {
265
- if (M !== 1 || P !== 1)
266
- do
267
- if (M--, P--, P < 0 || g[M] !== z[P]) {
268
- var L = `
269
- ` + g[M].replace(" at new ", " at ");
270
- return t.displayName && L.includes("<anonymous>") && (L = L.replace("<anonymous>", t.displayName)), typeof t == "function" && ee.set(t, L), L;
271
- }
272
- while (M >= 1 && P >= 0);
273
- break;
274
- }
275
- }
276
- } finally {
277
- oe = !1, ae.current = E, ft(), Error.prepareStackTrace = R;
278
- }
279
- var q = t ? t.displayName || t.name : "", W = q ? K(q) : "";
280
- return typeof t == "function" && ee.set(t, W), W;
281
- }
282
- function mt(t, o, u) {
283
- return Se(t, !1);
284
- }
285
- function ht(t) {
286
- var o = t.prototype;
287
- return !!(o && o.isReactComponent);
288
- }
289
- function te(t, o, u) {
290
- if (t == null)
291
- return "";
292
- if (typeof t == "function")
293
- return Se(t, ht(t));
294
- if (typeof t == "string")
295
- return K(t);
296
- switch (t) {
297
- case m:
298
- return K("Suspense");
299
- case d:
300
- return K("SuspenseList");
301
- }
302
- if (typeof t == "object")
303
- switch (t.$$typeof) {
304
- case c:
305
- return mt(t.render);
306
- case x:
307
- return te(t.type, o, u);
308
- case y: {
309
- var p = t, R = p._payload, E = p._init;
310
- try {
311
- return te(E(R), o, u);
312
- } catch {
313
- }
314
- }
315
- }
316
- return "";
317
- }
318
- var X = Object.prototype.hasOwnProperty, _e = {}, Te = C.ReactDebugCurrentFrame;
319
- function re(t) {
320
- if (t) {
321
- var o = t._owner, u = te(t.type, t._source, o ? o.type : null);
322
- Te.setExtraStackFrame(u);
323
- } else
324
- Te.setExtraStackFrame(null);
325
- }
326
- function bt(t, o, u, p, R) {
327
- {
328
- var E = Function.call.bind(X);
329
- for (var w in t)
330
- if (E(t, w)) {
331
- var g = void 0;
332
- try {
333
- if (typeof t[w] != "function") {
334
- var z = Error((p || "React class") + ": " + u + " type `" + w + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof t[w] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
335
- throw z.name = "Invariant Violation", z;
336
- }
337
- g = t[w](o, w, p, u, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
338
- } catch (M) {
339
- g = M;
340
- }
341
- g && !(g instanceof Error) && (re(R), T("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", p || "React class", u, w, typeof g), re(null)), g instanceof Error && !(g.message in _e) && (_e[g.message] = !0, re(R), T("Failed %s type: %s", u, g.message), re(null));
342
- }
343
- }
344
- }
345
- var pt = Array.isArray;
346
- function le(t) {
347
- return pt(t);
348
- }
349
- function vt(t) {
350
- {
351
- var o = typeof Symbol == "function" && Symbol.toStringTag, u = o && t[Symbol.toStringTag] || t.constructor.name || "Object";
352
- return u;
353
- }
354
- }
355
- function gt(t) {
356
- try {
357
- return Me(t), !1;
358
- } catch {
359
- return !0;
360
- }
361
- }
362
- function Me(t) {
363
- return "" + t;
364
- }
365
- function Pe(t) {
366
- if (gt(t))
367
- return T("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", vt(t)), Me(t);
368
- }
369
- var Oe = C.ReactCurrentOwner, yt = {
370
- key: !0,
371
- ref: !0,
372
- __self: !0,
373
- __source: !0
374
- }, De, ze;
375
- function jt(t) {
376
- if (X.call(t, "ref")) {
377
- var o = Object.getOwnPropertyDescriptor(t, "ref").get;
378
- if (o && o.isReactWarning)
379
- return !1;
380
- }
381
- return t.ref !== void 0;
382
- }
383
- function kt(t) {
384
- if (X.call(t, "key")) {
385
- var o = Object.getOwnPropertyDescriptor(t, "key").get;
386
- if (o && o.isReactWarning)
387
- return !1;
388
- }
389
- return t.key !== void 0;
390
- }
391
- function wt(t, o) {
392
- typeof t.ref == "string" && Oe.current;
393
- }
394
- function Nt(t, o) {
395
- {
396
- var u = function() {
397
- De || (De = !0, T("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", o));
398
- };
399
- u.isReactWarning = !0, Object.defineProperty(t, "key", {
400
- get: u,
401
- configurable: !0
402
- });
403
- }
404
- }
405
- function Ct(t, o) {
406
- {
407
- var u = function() {
408
- ze || (ze = !0, T("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", o));
409
- };
410
- u.isReactWarning = !0, Object.defineProperty(t, "ref", {
411
- get: u,
412
- configurable: !0
413
- });
414
- }
415
- }
416
- var Rt = function(t, o, u, p, R, E, w) {
417
- var g = {
418
- // This tag allows us to uniquely identify this as a React Element
419
- $$typeof: r,
420
- // Built-in properties that belong on the element
421
- type: t,
422
- key: o,
423
- ref: u,
424
- props: w,
425
- // Record the component responsible for creating this element.
426
- _owner: E
427
- };
428
- return g._store = {}, Object.defineProperty(g._store, "validated", {
429
- configurable: !1,
430
- enumerable: !1,
431
- writable: !0,
432
- value: !1
433
- }), Object.defineProperty(g, "_self", {
434
- configurable: !1,
435
- enumerable: !1,
436
- writable: !1,
437
- value: p
438
- }), Object.defineProperty(g, "_source", {
439
- configurable: !1,
440
- enumerable: !1,
441
- writable: !1,
442
- value: R
443
- }), Object.freeze && (Object.freeze(g.props), Object.freeze(g)), g;
444
- };
445
- function Et(t, o, u, p, R) {
446
- {
447
- var E, w = {}, g = null, z = null;
448
- u !== void 0 && (Pe(u), g = "" + u), kt(o) && (Pe(o.key), g = "" + o.key), jt(o) && (z = o.ref, wt(o, R));
449
- for (E in o)
450
- X.call(o, E) && !yt.hasOwnProperty(E) && (w[E] = o[E]);
451
- if (t && t.defaultProps) {
452
- var M = t.defaultProps;
453
- for (E in M)
454
- w[E] === void 0 && (w[E] = M[E]);
455
- }
456
- if (g || z) {
457
- var P = typeof t == "function" ? t.displayName || t.name || "Unknown" : t;
458
- g && Nt(w, P), z && Ct(w, P);
459
- }
460
- return Rt(t, g, z, R, p, Oe.current, w);
461
- }
462
- }
463
- var ce = C.ReactCurrentOwner, Ae = C.ReactDebugCurrentFrame;
464
- function V(t) {
465
- if (t) {
466
- var o = t._owner, u = te(t.type, t._source, o ? o.type : null);
467
- Ae.setExtraStackFrame(u);
468
- } else
469
- Ae.setExtraStackFrame(null);
470
- }
471
- var de;
472
- de = !1;
473
- function ue(t) {
474
- return typeof t == "object" && t !== null && t.$$typeof === r;
475
- }
476
- function Le() {
477
- {
478
- if (ce.current) {
479
- var t = $(ce.current.type);
480
- if (t)
481
- return `
482
-
483
- Check the render method of \`` + t + "`.";
484
- }
485
- return "";
486
- }
487
- }
488
- function St(t) {
489
- return "";
490
- }
491
- var Fe = {};
492
- function _t(t) {
493
- {
494
- var o = Le();
495
- if (!o) {
496
- var u = typeof t == "string" ? t : t.displayName || t.name;
497
- u && (o = `
498
-
499
- Check the top-level render call using <` + u + ">.");
500
- }
501
- return o;
502
- }
503
- }
504
- function Ie(t, o) {
505
- {
506
- if (!t._store || t._store.validated || t.key != null)
507
- return;
508
- t._store.validated = !0;
509
- var u = _t(o);
510
- if (Fe[u])
511
- return;
512
- Fe[u] = !0;
513
- var p = "";
514
- t && t._owner && t._owner !== ce.current && (p = " It was passed a child from " + $(t._owner.type) + "."), V(t), T('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', u, p), V(null);
515
- }
516
- }
517
- function $e(t, o) {
518
- {
519
- if (typeof t != "object")
520
- return;
521
- if (le(t))
522
- for (var u = 0; u < t.length; u++) {
523
- var p = t[u];
524
- ue(p) && Ie(p, o);
525
- }
526
- else if (ue(t))
527
- t._store && (t._store.validated = !0);
528
- else if (t) {
529
- var R = _(t);
530
- if (typeof R == "function" && R !== t.entries)
531
- for (var E = R.call(t), w; !(w = E.next()).done; )
532
- ue(w.value) && Ie(w.value, o);
533
- }
534
- }
535
- }
536
- function Tt(t) {
537
- {
538
- var o = t.type;
539
- if (o == null || typeof o == "string")
540
- return;
541
- var u;
542
- if (typeof o == "function")
543
- u = o.propTypes;
544
- else if (typeof o == "object" && (o.$$typeof === c || // Note: Memo only checks outer props here.
545
- // Inner props are checked in the reconciler.
546
- o.$$typeof === x))
547
- u = o.propTypes;
548
- else
549
- return;
550
- if (u) {
551
- var p = $(o);
552
- bt(u, t.props, "prop", p, t);
553
- } else if (o.PropTypes !== void 0 && !de) {
554
- de = !0;
555
- var R = $(o);
556
- T("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", R || "Unknown");
557
- }
558
- typeof o.getDefaultProps == "function" && !o.getDefaultProps.isReactClassApproved && T("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
559
- }
560
- }
561
- function Mt(t) {
562
- {
563
- for (var o = Object.keys(t.props), u = 0; u < o.length; u++) {
564
- var p = o[u];
565
- if (p !== "children" && p !== "key") {
566
- V(t), T("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", p), V(null);
567
- break;
568
- }
569
- }
570
- t.ref !== null && (V(t), T("Invalid attribute `ref` supplied to `React.Fragment`."), V(null));
571
- }
572
- }
573
- var Ye = {};
574
- function We(t, o, u, p, R, E) {
575
- {
576
- var w = ct(t);
577
- if (!w) {
578
- var g = "";
579
- (t === void 0 || typeof t == "object" && t !== null && Object.keys(t).length === 0) && (g += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
580
- var z = St();
581
- z ? g += z : g += Le();
582
- var M;
583
- t === null ? M = "null" : le(t) ? M = "array" : t !== void 0 && t.$$typeof === r ? (M = "<" + ($(t.type) || "Unknown") + " />", g = " Did you accidentally export a JSX literal instead of a component?") : M = typeof t, T("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", M, g);
584
- }
585
- var P = Et(t, o, u, R, E);
586
- if (P == null)
587
- return P;
588
- if (w) {
589
- var L = o.children;
590
- if (L !== void 0)
591
- if (p)
592
- if (le(L)) {
593
- for (var q = 0; q < L.length; q++)
594
- $e(L[q], t);
595
- Object.freeze && Object.freeze(L);
596
- } else
597
- T("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
598
- else
599
- $e(L, t);
600
- }
601
- if (X.call(o, "key")) {
602
- var W = $(t), A = Object.keys(o).filter(function(Lt) {
603
- return Lt !== "key";
604
- }), fe = A.length > 0 ? "{key: someKey, " + A.join(": ..., ") + ": ...}" : "{key: someKey}";
605
- if (!Ye[W + fe]) {
606
- var At = A.length > 0 ? "{" + A.join(": ..., ") + ": ...}" : "{}";
607
- T(`A props object containing a "key" prop is being spread into JSX:
608
- let props = %s;
609
- <%s {...props} />
610
- React keys must be passed directly to JSX without using spread:
611
- let props = %s;
612
- <%s key={someKey} {...props} />`, fe, W, At, W), Ye[W + fe] = !0;
613
- }
614
- }
615
- return t === a ? Mt(P) : Tt(P), P;
616
- }
617
- }
618
- function Pt(t, o, u) {
619
- return We(t, o, u, !0);
620
- }
621
- function Ot(t, o, u) {
622
- return We(t, o, u, !1);
623
- }
624
- var Dt = Ot, zt = Pt;
625
- Q.Fragment = a, Q.jsx = Dt, Q.jsxs = zt;
626
- }()), Q;
627
- }
628
- process.env.NODE_ENV === "production" ? me.exports = Ft() : me.exports = It();
629
- var e = me.exports;
630
- function Ze(n) {
631
- var r, s, a = "";
632
- if (typeof n == "string" || typeof n == "number") a += n;
633
- else if (typeof n == "object") if (Array.isArray(n)) {
634
- var i = n.length;
635
- for (r = 0; r < i; r++) n[r] && (s = Ze(n[r])) && (a && (a += " "), a += s);
636
- } else for (s in n) n[s] && (a && (a += " "), a += s);
1
+ import { jsx as e, jsxs as s, Fragment as $ } from "react/jsx-runtime";
2
+ import * as b from "react";
3
+ import { forwardRef as Y, createElement as O } from "react";
4
+ import { createPortal as H } from "react-dom";
5
+ function V(t) {
6
+ var r, n, a = "";
7
+ if (typeof t == "string" || typeof t == "number") a += t;
8
+ else if (typeof t == "object") if (Array.isArray(t)) {
9
+ var i = t.length;
10
+ for (r = 0; r < i; r++) t[r] && (n = V(t[r])) && (a && (a += " "), a += n);
11
+ } else for (n in t) t[n] && (a && (a += " "), a += n);
637
12
  return a;
638
13
  }
639
- function $t() {
640
- for (var n, r, s = 0, a = "", i = arguments.length; s < i; s++) (n = arguments[s]) && (r = Ze(n)) && (a && (a += " "), a += r);
14
+ function ae() {
15
+ for (var t, r, n = 0, a = "", i = arguments.length; n < i; n++) (t = arguments[n]) && (r = V(t)) && (a && (a += " "), a += r);
641
16
  return a;
642
17
  }
643
- function b(...n) {
644
- return $t(n);
18
+ function h(...t) {
19
+ return ae(t);
645
20
  }
646
- const Yt = {
21
+ const ie = {
647
22
  neutral: "bg-tag text-tag border border-tag-border",
648
23
  online: "bg-status-online-bg text-status-online",
649
24
  warn: "bg-status-warn-bg text-status-warn",
@@ -651,21 +26,21 @@ const Yt = {
651
26
  live: "bg-live-bg text-live-text",
652
27
  accent: "bg-accent-muted text-accent"
653
28
  };
654
- function Rr({ tone: n = "neutral", className: r, children: s, ...a }) {
655
- return /* @__PURE__ */ e.jsx(
29
+ function _e({ tone: t = "neutral", className: r, children: n, ...a }) {
30
+ return /* @__PURE__ */ e(
656
31
  "span",
657
32
  {
658
- className: b(
33
+ className: h(
659
34
  "inline-flex items-center gap-1 rounded-md px-2 py-0.5 text-xs font-medium",
660
- Yt[n],
35
+ ie[t],
661
36
  r
662
37
  ),
663
38
  ...a,
664
- children: s
39
+ children: n
665
40
  }
666
41
  );
667
42
  }
668
- const Wt = {
43
+ const se = {
669
44
  primary: "bg-accent text-white hover:brightness-110 focus-visible:ring-accent/50",
670
45
  secondary: "bg-accent-muted text-accent hover:brightness-105 focus-visible:ring-accent/40",
671
46
  outline: "border border-card-border text-ink-primary bg-transparent hover:bg-accent-muted focus-visible:ring-accent/30",
@@ -673,65 +48,65 @@ const Wt = {
673
48
  danger: "bg-status-offline text-white hover:brightness-110 focus-visible:ring-status-offline/50",
674
49
  add: "bg-status-online text-white hover:brightness-110 focus-visible:ring-status-online/50",
675
50
  cancel: "border border-card-border text-ink-secondary bg-transparent hover:bg-card focus-visible:ring-ink-muted/30"
676
- }, Vt = {
51
+ }, ce = {
677
52
  sm: "h-8 px-3 text-sm gap-1.5",
678
53
  md: "h-10 px-4 text-sm gap-2",
679
54
  lg: "h-12 px-6 text-base gap-2"
680
- }, F = v.forwardRef(
681
- ({ variant: n = "primary", size: r = "md", icon: s, trailingIcon: a, loading: i, fullWidth: l, disabled: f, className: h, children: c, ...m }, d) => /* @__PURE__ */ e.jsxs(
55
+ }, B = b.forwardRef(
56
+ ({ variant: t = "primary", size: r = "md", icon: n, trailingIcon: a, loading: i, fullWidth: c, disabled: l, className: f, children: o, ...d }, u) => /* @__PURE__ */ s(
682
57
  "button",
683
58
  {
684
- ref: d,
685
- disabled: f || i,
686
- className: b(
59
+ ref: u,
60
+ disabled: l || i,
61
+ className: h(
687
62
  "inline-flex items-center justify-center rounded-md font-primary font-medium",
688
63
  "transition-colors duration-150 focus-visible:outline-none focus-visible:ring-2",
689
64
  "disabled:opacity-50 disabled:cursor-not-allowed",
690
- Wt[n],
691
- Vt[r],
692
- l && "w-full",
693
- h
65
+ se[t],
66
+ ce[r],
67
+ c && "w-full",
68
+ f
694
69
  ),
695
- ...m,
70
+ ...d,
696
71
  children: [
697
- i ? /* @__PURE__ */ e.jsx("span", { className: "h-4 w-4 animate-spin rounded-full border-2 border-current border-t-transparent" }) : s && /* @__PURE__ */ e.jsx("span", { className: "inline-flex shrink-0", children: s }),
698
- c,
699
- !i && a && /* @__PURE__ */ e.jsx("span", { className: "inline-flex shrink-0", children: a })
72
+ i ? /* @__PURE__ */ e("span", { className: "h-4 w-4 animate-spin rounded-full border-2 border-current border-t-transparent" }) : n && /* @__PURE__ */ e("span", { className: "inline-flex shrink-0", children: n }),
73
+ o,
74
+ !i && a && /* @__PURE__ */ e("span", { className: "inline-flex shrink-0", children: a })
700
75
  ]
701
76
  }
702
77
  )
703
78
  );
704
- F.displayName = "Button";
705
- const qt = v.forwardRef(
706
- ({ padded: n = !0, className: r, children: s, ...a }, i) => /* @__PURE__ */ e.jsx(
79
+ B.displayName = "Button";
80
+ const le = b.forwardRef(
81
+ ({ padded: t = !0, className: r, children: n, ...a }, i) => /* @__PURE__ */ e(
707
82
  "div",
708
83
  {
709
84
  ref: i,
710
- className: b(
85
+ className: h(
711
86
  "rounded-lg border border-card-border bg-card shadow-md text-ink-primary",
712
- n && "p-4",
87
+ t && "p-4",
713
88
  r
714
89
  ),
715
90
  ...a,
716
- children: s
91
+ children: n
717
92
  }
718
93
  )
719
94
  );
720
- qt.displayName = "Card";
95
+ le.displayName = "Card";
721
96
  /**
722
97
  * @license lucide-react v0.400.0 - ISC
723
98
  *
724
99
  * This source code is licensed under the ISC license.
725
100
  * See the LICENSE file in the root directory of this source tree.
726
101
  */
727
- const Bt = (n) => n.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase(), Qe = (...n) => n.filter((r, s, a) => !!r && a.indexOf(r) === s).join(" ");
102
+ const oe = (t) => t.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase(), U = (...t) => t.filter((r, n, a) => !!r && a.indexOf(r) === n).join(" ");
728
103
  /**
729
104
  * @license lucide-react v0.400.0 - ISC
730
105
  *
731
106
  * This source code is licensed under the ISC license.
732
107
  * See the LICENSE file in the root directory of this source tree.
733
108
  */
734
- var Ut = {
109
+ var de = {
735
110
  xmlns: "http://www.w3.org/2000/svg",
736
111
  width: 24,
737
112
  height: 24,
@@ -748,31 +123,31 @@ var Ut = {
748
123
  * This source code is licensed under the ISC license.
749
124
  * See the LICENSE file in the root directory of this source tree.
750
125
  */
751
- const Ht = Ge(
126
+ const ue = Y(
752
127
  ({
753
- color: n = "currentColor",
128
+ color: t = "currentColor",
754
129
  size: r = 24,
755
- strokeWidth: s = 2,
130
+ strokeWidth: n = 2,
756
131
  absoluteStrokeWidth: a,
757
132
  className: i = "",
758
- children: l,
759
- iconNode: f,
760
- ...h
761
- }, c) => xe(
133
+ children: c,
134
+ iconNode: l,
135
+ ...f
136
+ }, o) => O(
762
137
  "svg",
763
138
  {
764
- ref: c,
765
- ...Ut,
139
+ ref: o,
140
+ ...de,
766
141
  width: r,
767
142
  height: r,
768
- stroke: n,
769
- strokeWidth: a ? Number(s) * 24 / Number(r) : s,
770
- className: Qe("lucide", i),
771
- ...h
143
+ stroke: t,
144
+ strokeWidth: a ? Number(n) * 24 / Number(r) : n,
145
+ className: U("lucide", i),
146
+ ...f
772
147
  },
773
148
  [
774
- ...f.map(([m, d]) => xe(m, d)),
775
- ...Array.isArray(l) ? l : [l]
149
+ ...l.map(([d, u]) => O(d, u)),
150
+ ...Array.isArray(c) ? c : [c]
776
151
  ]
777
152
  )
778
153
  );
@@ -782,16 +157,16 @@ const Ht = Ge(
782
157
  * This source code is licensed under the ISC license.
783
158
  * See the LICENSE file in the root directory of this source tree.
784
159
  */
785
- const S = (n, r) => {
786
- const s = Ge(
787
- ({ className: a, ...i }, l) => xe(Ht, {
788
- ref: l,
160
+ const k = (t, r) => {
161
+ const n = Y(
162
+ ({ className: a, ...i }, c) => O(ue, {
163
+ ref: c,
789
164
  iconNode: r,
790
- className: Qe(`lucide-${Bt(n)}`, a),
165
+ className: U(`lucide-${oe(t)}`, a),
791
166
  ...i
792
167
  })
793
168
  );
794
- return s.displayName = `${n}`, s;
169
+ return n.displayName = `${t}`, n;
795
170
  };
796
171
  /**
797
172
  * @license lucide-react v0.400.0 - ISC
@@ -799,7 +174,7 @@ const S = (n, r) => {
799
174
  * This source code is licensed under the ISC license.
800
175
  * See the LICENSE file in the root directory of this source tree.
801
176
  */
802
- const Jt = S("ArrowDown", [
177
+ const fe = k("ArrowDown", [
803
178
  ["path", { d: "M12 5v14", key: "s699le" }],
804
179
  ["path", { d: "m19 12-7 7-7-7", key: "1idqje" }]
805
180
  ]);
@@ -809,7 +184,7 @@ const Jt = S("ArrowDown", [
809
184
  * This source code is licensed under the ISC license.
810
185
  * See the LICENSE file in the root directory of this source tree.
811
186
  */
812
- const Be = S("ArrowUpDown", [
187
+ const F = k("ArrowUpDown", [
813
188
  ["path", { d: "m21 16-4 4-4-4", key: "f6ql7i" }],
814
189
  ["path", { d: "M17 20V4", key: "1ejh1v" }],
815
190
  ["path", { d: "m3 8 4-4 4 4", key: "11wl7u" }],
@@ -821,7 +196,7 @@ const Be = S("ArrowUpDown", [
821
196
  * This source code is licensed under the ISC license.
822
197
  * See the LICENSE file in the root directory of this source tree.
823
198
  */
824
- const Gt = S("ArrowUp", [
199
+ const me = k("ArrowUp", [
825
200
  ["path", { d: "m5 12 7-7 7 7", key: "hav0vg" }],
826
201
  ["path", { d: "M12 19V5", key: "x0mq9r" }]
827
202
  ]);
@@ -831,7 +206,7 @@ const Gt = S("ArrowUp", [
831
206
  * This source code is licensed under the ISC license.
832
207
  * See the LICENSE file in the root directory of this source tree.
833
208
  */
834
- const Xt = S("Bot", [
209
+ const he = k("Bot", [
835
210
  ["path", { d: "M12 8V4H8", key: "hb8ula" }],
836
211
  ["rect", { width: "16", height: "12", x: "4", y: "8", rx: "2", key: "enze0r" }],
837
212
  ["path", { d: "M2 14h2", key: "vft8re" }],
@@ -845,7 +220,7 @@ const Xt = S("Bot", [
845
220
  * This source code is licensed under the ISC license.
846
221
  * See the LICENSE file in the root directory of this source tree.
847
222
  */
848
- const Ke = S("Calendar", [
223
+ const G = k("Calendar", [
849
224
  ["path", { d: "M8 2v4", key: "1cmpym" }],
850
225
  ["path", { d: "M16 2v4", key: "4m81vk" }],
851
226
  ["rect", { width: "18", height: "18", x: "3", y: "4", rx: "2", key: "1hopcy" }],
@@ -857,14 +232,14 @@ const Ke = S("Calendar", [
857
232
  * This source code is licensed under the ISC license.
858
233
  * See the LICENSE file in the root directory of this source tree.
859
234
  */
860
- const et = S("Check", [["path", { d: "M20 6 9 17l-5-5", key: "1gmf2c" }]]);
235
+ const _ = k("Check", [["path", { d: "M20 6 9 17l-5-5", key: "1gmf2c" }]]);
861
236
  /**
862
237
  * @license lucide-react v0.400.0 - ISC
863
238
  *
864
239
  * This source code is licensed under the ISC license.
865
240
  * See the LICENSE file in the root directory of this source tree.
866
241
  */
867
- const tt = S("ChevronDown", [
242
+ const Q = k("ChevronDown", [
868
243
  ["path", { d: "m6 9 6 6 6-6", key: "qrunsl" }]
869
244
  ]);
870
245
  /**
@@ -873,7 +248,7 @@ const tt = S("ChevronDown", [
873
248
  * This source code is licensed under the ISC license.
874
249
  * See the LICENSE file in the root directory of this source tree.
875
250
  */
876
- const Zt = S("ChevronLeft", [
251
+ const be = k("ChevronLeft", [
877
252
  ["path", { d: "m15 18-6-6 6-6", key: "1wnfg3" }]
878
253
  ]);
879
254
  /**
@@ -882,7 +257,7 @@ const Zt = S("ChevronLeft", [
882
257
  * This source code is licensed under the ISC license.
883
258
  * See the LICENSE file in the root directory of this source tree.
884
259
  */
885
- const Qt = S("ChevronRight", [
260
+ const xe = k("ChevronRight", [
886
261
  ["path", { d: "m9 18 6-6-6-6", key: "mthhwq" }]
887
262
  ]);
888
263
  /**
@@ -891,7 +266,7 @@ const Qt = S("ChevronRight", [
891
266
  * This source code is licensed under the ISC license.
892
267
  * See the LICENSE file in the root directory of this source tree.
893
268
  */
894
- const rt = S("ChevronsLeft", [
269
+ const Z = k("ChevronsLeft", [
895
270
  ["path", { d: "m11 17-5-5 5-5", key: "13zhaf" }],
896
271
  ["path", { d: "m18 17-5-5 5-5", key: "h8a8et" }]
897
272
  ]);
@@ -901,7 +276,7 @@ const rt = S("ChevronsLeft", [
901
276
  * This source code is licensed under the ISC license.
902
277
  * See the LICENSE file in the root directory of this source tree.
903
278
  */
904
- const nt = S("ChevronsRight", [
279
+ const J = k("ChevronsRight", [
905
280
  ["path", { d: "m6 17 5-5-5-5", key: "xnjwq" }],
906
281
  ["path", { d: "m13 17 5-5-5-5", key: "17xmmf" }]
907
282
  ]);
@@ -911,7 +286,7 @@ const nt = S("ChevronsRight", [
911
286
  * This source code is licensed under the ISC license.
912
287
  * See the LICENSE file in the root directory of this source tree.
913
288
  */
914
- const Kt = S("CircleAlert", [
289
+ const pe = k("CircleAlert", [
915
290
  ["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
916
291
  ["line", { x1: "12", x2: "12", y1: "8", y2: "12", key: "1pkeuh" }],
917
292
  ["line", { x1: "12", x2: "12.01", y1: "16", y2: "16", key: "4dfq90" }]
@@ -922,7 +297,7 @@ const Kt = S("CircleAlert", [
922
297
  * This source code is licensed under the ISC license.
923
298
  * See the LICENSE file in the root directory of this source tree.
924
299
  */
925
- const er = S("Download", [
300
+ const ge = k("Download", [
926
301
  ["path", { d: "M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4", key: "ih7n3h" }],
927
302
  ["polyline", { points: "7 10 12 15 17 10", key: "2ggqvy" }],
928
303
  ["line", { x1: "12", x2: "12", y1: "15", y2: "3", key: "1vk2je" }]
@@ -933,7 +308,7 @@ const er = S("Download", [
933
308
  * This source code is licensed under the ISC license.
934
309
  * See the LICENSE file in the root directory of this source tree.
935
310
  */
936
- const tr = S("EyeOff", [
311
+ const ve = k("EyeOff", [
937
312
  ["path", { d: "M9.88 9.88a3 3 0 1 0 4.24 4.24", key: "1jxqfv" }],
938
313
  [
939
314
  "path",
@@ -954,7 +329,7 @@ const tr = S("EyeOff", [
954
329
  * This source code is licensed under the ISC license.
955
330
  * See the LICENSE file in the root directory of this source tree.
956
331
  */
957
- const rr = S("Eye", [
332
+ const ye = k("Eye", [
958
333
  ["path", { d: "M2 12s3-7 10-7 10 7 10 7-3 7-10 7-10-7-10-7Z", key: "rwhkz3" }],
959
334
  ["circle", { cx: "12", cy: "12", r: "3", key: "1v7zrd" }]
960
335
  ]);
@@ -964,7 +339,7 @@ const rr = S("Eye", [
964
339
  * This source code is licensed under the ISC license.
965
340
  * See the LICENSE file in the root directory of this source tree.
966
341
  */
967
- const nr = S("Grid3x3", [
342
+ const ke = k("Grid3x3", [
968
343
  ["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", key: "afitv7" }],
969
344
  ["path", { d: "M3 9h18", key: "1pudct" }],
970
345
  ["path", { d: "M3 15h18", key: "5xshup" }],
@@ -977,7 +352,7 @@ const nr = S("Grid3x3", [
977
352
  * This source code is licensed under the ISC license.
978
353
  * See the LICENSE file in the root directory of this source tree.
979
354
  */
980
- const sr = S("LogOut", [
355
+ const we = k("LogOut", [
981
356
  ["path", { d: "M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4", key: "1uf3rs" }],
982
357
  ["polyline", { points: "16 17 21 12 16 7", key: "1gabdz" }],
983
358
  ["line", { x1: "21", x2: "9", y1: "12", y2: "12", key: "1uyos4" }]
@@ -988,7 +363,7 @@ const sr = S("LogOut", [
988
363
  * This source code is licensed under the ISC license.
989
364
  * See the LICENSE file in the root directory of this source tree.
990
365
  */
991
- const ar = S("Mail", [
366
+ const Ne = k("Mail", [
992
367
  ["rect", { width: "20", height: "16", x: "2", y: "4", rx: "2", key: "18n3k1" }],
993
368
  ["path", { d: "m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7", key: "1ocrg3" }]
994
369
  ]);
@@ -998,7 +373,7 @@ const ar = S("Mail", [
998
373
  * This source code is licensed under the ISC license.
999
374
  * See the LICENSE file in the root directory of this source tree.
1000
375
  */
1001
- const st = S("Plus", [
376
+ const X = k("Plus", [
1002
377
  ["path", { d: "M5 12h14", key: "1ays0h" }],
1003
378
  ["path", { d: "M12 5v14", key: "s699le" }]
1004
379
  ]);
@@ -1008,7 +383,7 @@ const st = S("Plus", [
1008
383
  * This source code is licensed under the ISC license.
1009
384
  * See the LICENSE file in the root directory of this source tree.
1010
385
  */
1011
- const ir = S("RefreshCw", [
386
+ const Ce = k("RefreshCw", [
1012
387
  ["path", { d: "M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8", key: "v9h5vc" }],
1013
388
  ["path", { d: "M21 3v5h-5", key: "1q7to0" }],
1014
389
  ["path", { d: "M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16", key: "3uifl3" }],
@@ -1020,7 +395,7 @@ const ir = S("RefreshCw", [
1020
395
  * This source code is licensed under the ISC license.
1021
396
  * See the LICENSE file in the root directory of this source tree.
1022
397
  */
1023
- const he = S("Search", [
398
+ const P = k("Search", [
1024
399
  ["circle", { cx: "11", cy: "11", r: "8", key: "4ej97u" }],
1025
400
  ["path", { d: "m21 21-4.3-4.3", key: "1qie3q" }]
1026
401
  ]);
@@ -1030,7 +405,7 @@ const he = S("Search", [
1030
405
  * This source code is licensed under the ISC license.
1031
406
  * See the LICENSE file in the root directory of this source tree.
1032
407
  */
1033
- const at = S("SlidersHorizontal", [
408
+ const K = k("SlidersHorizontal", [
1034
409
  ["line", { x1: "21", x2: "14", y1: "4", y2: "4", key: "obuewd" }],
1035
410
  ["line", { x1: "10", x2: "3", y1: "4", y2: "4", key: "1q6298" }],
1036
411
  ["line", { x1: "21", x2: "12", y1: "12", y2: "12", key: "1iu8h1" }],
@@ -1047,7 +422,7 @@ const at = S("SlidersHorizontal", [
1047
422
  * This source code is licensed under the ISC license.
1048
423
  * See the LICENSE file in the root directory of this source tree.
1049
424
  */
1050
- const or = S("Trash2", [
425
+ const Be = k("Trash2", [
1051
426
  ["path", { d: "M3 6h18", key: "d0wm0j" }],
1052
427
  ["path", { d: "M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6", key: "4alrt4" }],
1053
428
  ["path", { d: "M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2", key: "v07s0e" }],
@@ -1060,7 +435,7 @@ const or = S("Trash2", [
1060
435
  * This source code is licensed under the ISC license.
1061
436
  * See the LICENSE file in the root directory of this source tree.
1062
437
  */
1063
- const lr = S("User", [
438
+ const Me = k("User", [
1064
439
  ["path", { d: "M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2", key: "975kel" }],
1065
440
  ["circle", { cx: "12", cy: "7", r: "4", key: "17ys0d" }]
1066
441
  ]);
@@ -1070,110 +445,110 @@ const lr = S("User", [
1070
445
  * This source code is licensed under the ISC license.
1071
446
  * See the LICENSE file in the root directory of this source tree.
1072
447
  */
1073
- const se = S("X", [
448
+ const D = k("X", [
1074
449
  ["path", { d: "M18 6 6 18", key: "1bl5f8" }],
1075
450
  ["path", { d: "m6 6 12 12", key: "d8bk6v" }]
1076
- ]), be = v.forwardRef(
1077
- ({ label: n, id: r, className: s, checked: a, ...i }, l) => {
1078
- const f = r ?? v.useId();
1079
- return /* @__PURE__ */ e.jsxs("label", { htmlFor: f, className: "inline-flex cursor-pointer items-center gap-2 select-none", children: [
1080
- /* @__PURE__ */ e.jsxs("span", { className: "relative inline-flex h-4 w-4 shrink-0 items-center justify-center", children: [
1081
- /* @__PURE__ */ e.jsx("input", { ref: l, id: f, type: "checkbox", checked: a, className: "peer sr-only", ...i }),
1082
- /* @__PURE__ */ e.jsx(
451
+ ]), E = b.forwardRef(
452
+ ({ label: t, id: r, className: n, checked: a, ...i }, c) => {
453
+ const l = r ?? b.useId();
454
+ return /* @__PURE__ */ s("label", { htmlFor: l, className: "inline-flex cursor-pointer items-center gap-2 select-none", children: [
455
+ /* @__PURE__ */ s("span", { className: "relative inline-flex h-4 w-4 shrink-0 items-center justify-center", children: [
456
+ /* @__PURE__ */ e("input", { ref: c, id: l, type: "checkbox", checked: a, className: "peer sr-only", ...i }),
457
+ /* @__PURE__ */ e(
1083
458
  "span",
1084
459
  {
1085
- className: b(
460
+ className: h(
1086
461
  "h-4 w-4 rounded border border-card-border bg-input transition-colors",
1087
462
  "peer-checked:border-accent peer-checked:bg-accent",
1088
463
  "peer-focus-visible:ring-2 peer-focus-visible:ring-accent/40",
1089
- s
464
+ n
1090
465
  )
1091
466
  }
1092
467
  ),
1093
- a && /* @__PURE__ */ e.jsx(et, { size: 12, strokeWidth: 3, className: "pointer-events-none absolute text-white" })
468
+ a && /* @__PURE__ */ e(_, { size: 12, strokeWidth: 3, className: "pointer-events-none absolute text-white" })
1094
469
  ] }),
1095
- n && /* @__PURE__ */ e.jsx("span", { className: "text-sm text-ink-primary", children: n })
470
+ t && /* @__PURE__ */ e("span", { className: "text-sm text-ink-primary", children: t })
1096
471
  ] });
1097
472
  }
1098
473
  );
1099
- be.displayName = "Checkbox";
1100
- const cr = {
474
+ E.displayName = "Checkbox";
475
+ const ze = {
1101
476
  idle: "text-icon-idle hover:text-icon-active hover:bg-accent-muted",
1102
477
  active: "text-icon-active bg-accent-muted",
1103
478
  danger: "text-status-offline hover:bg-status-offline-bg"
1104
- }, dr = { sm: "h-8 w-8", md: "h-10 w-10" }, B = v.forwardRef(
1105
- ({ icon: n, label: r, variant: s = "idle", size: a = "md", className: i, ...l }, f) => /* @__PURE__ */ e.jsx(
479
+ }, Se = { sm: "h-8 w-8", md: "h-10 w-10" }, S = b.forwardRef(
480
+ ({ icon: t, label: r, variant: n = "idle", size: a = "md", className: i, ...c }, l) => /* @__PURE__ */ e(
1106
481
  "button",
1107
482
  {
1108
- ref: f,
483
+ ref: l,
1109
484
  "aria-label": r,
1110
485
  title: r,
1111
- className: b(
486
+ className: h(
1112
487
  "inline-flex items-center justify-center rounded-full transition-colors duration-150",
1113
488
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-accent/40",
1114
489
  "disabled:opacity-40 disabled:cursor-not-allowed",
1115
- cr[s],
1116
- dr[a],
490
+ ze[n],
491
+ Se[a],
1117
492
  i
1118
493
  ),
1119
- ...l,
1120
- children: n
494
+ ...c,
495
+ children: t
1121
496
  }
1122
497
  )
1123
498
  );
1124
- B.displayName = "IconButton";
1125
- function Er({ columns: n, visible: r, onChange: s, className: a }) {
1126
- const [i, l] = v.useState(!1), f = v.useRef(null);
1127
- v.useEffect(() => {
1128
- function c(m) {
1129
- f.current && !f.current.contains(m.target) && l(!1);
1130
- }
1131
- return document.addEventListener("mousedown", c), () => document.removeEventListener("mousedown", c);
499
+ S.displayName = "IconButton";
500
+ function Qe({ columns: t, visible: r, onChange: n, className: a }) {
501
+ const [i, c] = b.useState(!1), l = b.useRef(null);
502
+ b.useEffect(() => {
503
+ function o(d) {
504
+ l.current && !l.current.contains(d.target) && c(!1);
505
+ }
506
+ return document.addEventListener("mousedown", o), () => document.removeEventListener("mousedown", o);
1132
507
  }, []);
1133
- function h(c) {
1134
- s(r.includes(c) ? r.filter((m) => m !== c) : [...r, c]);
508
+ function f(o) {
509
+ n(r.includes(o) ? r.filter((d) => d !== o) : [...r, o]);
1135
510
  }
1136
- return /* @__PURE__ */ e.jsxs("div", { ref: f, className: b("relative", a), children: [
1137
- /* @__PURE__ */ e.jsx(B, { icon: /* @__PURE__ */ e.jsx(nr, { size: 16 }), label: "Choose columns", onClick: () => l((c) => !c), variant: i ? "active" : "idle" }),
1138
- i && /* @__PURE__ */ e.jsx("div", { className: "absolute right-0 z-20 mt-1 w-52 rounded-md border border-card-border bg-card p-2 shadow-lg", children: n.map((c) => /* @__PURE__ */ e.jsxs("label", { className: "flex items-center gap-2 rounded px-2 py-1.5 text-sm hover:bg-accent-muted", children: [
1139
- /* @__PURE__ */ e.jsx(be, { checked: r.includes(c.key), onChange: () => h(c.key) }),
1140
- /* @__PURE__ */ e.jsx("span", { className: "text-ink-primary", children: c.label })
1141
- ] }, c.key)) })
511
+ return /* @__PURE__ */ s("div", { ref: l, className: h("relative", a), children: [
512
+ /* @__PURE__ */ e(S, { icon: /* @__PURE__ */ e(ke, { size: 16 }), label: "Choose columns", onClick: () => c((o) => !o), variant: i ? "active" : "idle" }),
513
+ i && /* @__PURE__ */ e("div", { className: "absolute right-0 z-20 mt-1 w-52 rounded-md border border-card-border bg-card p-2 shadow-lg", children: t.map((o) => /* @__PURE__ */ s("label", { className: "flex items-center gap-2 rounded px-2 py-1.5 text-sm hover:bg-accent-muted", children: [
514
+ /* @__PURE__ */ e(E, { checked: r.includes(o.key), onChange: () => f(o.key) }),
515
+ /* @__PURE__ */ e("span", { className: "text-ink-primary", children: o.label })
516
+ ] }, o.key)) })
1142
517
  ] });
1143
518
  }
1144
- const ur = {
519
+ const Le = {
1145
520
  sm: "max-w-sm",
1146
521
  md: "max-w-lg",
1147
522
  lg: "max-w-2xl",
1148
523
  xl: "max-w-4xl"
1149
524
  };
1150
- function pe({ open: n, onClose: r, title: s, footer: a, size: i = "md", children: l, className: f }) {
1151
- return v.useEffect(() => {
1152
- if (!n) return;
1153
- function h(c) {
1154
- c.key === "Escape" && r();
525
+ function R({ open: t, onClose: r, title: n, footer: a, size: i = "md", children: c, className: l }) {
526
+ return b.useEffect(() => {
527
+ if (!t) return;
528
+ function f(o) {
529
+ o.key === "Escape" && r();
1155
530
  }
1156
- return document.addEventListener("keydown", h), () => document.removeEventListener("keydown", h);
1157
- }, [n, r]), n ? Xe(
1158
- /* @__PURE__ */ e.jsxs("div", { className: "fixed inset-0 z-50 flex items-center justify-center p-4", children: [
1159
- /* @__PURE__ */ e.jsx("div", { className: "absolute inset-0 bg-black/50", onClick: r, "aria-hidden": !0 }),
1160
- /* @__PURE__ */ e.jsxs(
531
+ return document.addEventListener("keydown", f), () => document.removeEventListener("keydown", f);
532
+ }, [t, r]), t ? H(
533
+ /* @__PURE__ */ s("div", { className: "fixed inset-0 z-50 flex items-center justify-center p-4", children: [
534
+ /* @__PURE__ */ e("div", { className: "absolute inset-0 bg-black/50", onClick: r, "aria-hidden": !0 }),
535
+ /* @__PURE__ */ s(
1161
536
  "div",
1162
537
  {
1163
538
  role: "dialog",
1164
539
  "aria-modal": "true",
1165
- className: b(
540
+ className: h(
1166
541
  "relative z-10 flex max-h-[90vh] w-full flex-col rounded-lg border border-card-border bg-card shadow-xl",
1167
- ur[i],
1168
- f
542
+ Le[i],
543
+ l
1169
544
  ),
1170
545
  children: [
1171
- s && /* @__PURE__ */ e.jsxs("div", { className: "flex items-center justify-between border-b border-card-border px-5 py-4", children: [
1172
- /* @__PURE__ */ e.jsx("h2", { className: "font-secondary text-base font-semibold text-ink-primary", children: s }),
1173
- /* @__PURE__ */ e.jsx("button", { onClick: r, "aria-label": "Close", className: "text-ink-muted hover:text-ink-primary", children: /* @__PURE__ */ e.jsx(se, { size: 18 }) })
546
+ n && /* @__PURE__ */ s("div", { className: "flex items-center justify-between border-b border-card-border px-5 py-4", children: [
547
+ /* @__PURE__ */ e("h2", { className: "font-secondary text-base font-semibold text-ink-primary", children: n }),
548
+ /* @__PURE__ */ e("button", { onClick: r, "aria-label": "Close", className: "text-ink-muted hover:text-ink-primary", children: /* @__PURE__ */ e(D, { size: 18 }) })
1174
549
  ] }),
1175
- /* @__PURE__ */ e.jsx("div", { className: "flex-1 overflow-y-auto px-5 py-4", children: l }),
1176
- a && /* @__PURE__ */ e.jsx("div", { className: "flex items-center justify-end gap-2 border-t border-card-border px-5 py-4", children: a })
550
+ /* @__PURE__ */ e("div", { className: "flex-1 overflow-y-auto px-5 py-4", children: c }),
551
+ a && /* @__PURE__ */ e("div", { className: "flex items-center justify-end gap-2 border-t border-card-border px-5 py-4", children: a })
1177
552
  ]
1178
553
  }
1179
554
  )
@@ -1181,765 +556,765 @@ function pe({ open: n, onClose: r, title: s, footer: a, size: i = "md", children
1181
556
  document.body
1182
557
  ) : null;
1183
558
  }
1184
- function Sr({
1185
- open: n,
559
+ function Ze({
560
+ open: t,
1186
561
  title: r,
1187
- message: s,
562
+ message: n,
1188
563
  confirmLabel: a = "Ok",
1189
564
  cancelLabel: i = "Close",
1190
- tone: l = "default",
1191
- onConfirm: f,
1192
- onClose: h,
1193
- loading: c
565
+ tone: c = "default",
566
+ onConfirm: l,
567
+ onClose: f,
568
+ loading: o
1194
569
  }) {
1195
- return /* @__PURE__ */ e.jsx(
1196
- pe,
570
+ return /* @__PURE__ */ e(
571
+ R,
1197
572
  {
1198
- open: n,
1199
- onClose: h,
573
+ open: t,
574
+ onClose: f,
1200
575
  title: r,
1201
576
  size: "sm",
1202
- footer: /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
1203
- /* @__PURE__ */ e.jsx(F, { variant: "cancel", onClick: h, children: i }),
1204
- /* @__PURE__ */ e.jsx(F, { variant: l === "danger" ? "danger" : "primary", onClick: f, loading: c, children: a })
577
+ footer: /* @__PURE__ */ s($, { children: [
578
+ /* @__PURE__ */ e(B, { variant: "cancel", onClick: f, children: i }),
579
+ /* @__PURE__ */ e(B, { variant: c === "danger" ? "danger" : "primary", onClick: l, loading: o, children: a })
1205
580
  ] }),
1206
- children: /* @__PURE__ */ e.jsx("p", { className: "text-sm text-ink-secondary", children: s })
581
+ children: /* @__PURE__ */ e("p", { className: "text-sm text-ink-secondary", children: n })
1207
582
  }
1208
583
  );
1209
584
  }
1210
- function it({ fullPage: n, label: r = "Loading...", className: s }) {
1211
- const a = /* @__PURE__ */ e.jsxs("div", { className: b("flex flex-col items-center justify-center gap-3", s), children: [
1212
- /* @__PURE__ */ e.jsx("span", { className: "h-10 w-10 animate-spin rounded-full border-4 border-accent-muted border-t-accent" }),
1213
- r && /* @__PURE__ */ e.jsx("span", { className: "text-sm text-ink-secondary", children: r })
585
+ function ee({ fullPage: t, label: r = "Loading...", className: n }) {
586
+ const a = /* @__PURE__ */ s("div", { className: h("flex flex-col items-center justify-center gap-3", n), children: [
587
+ /* @__PURE__ */ e("span", { className: "h-10 w-10 animate-spin rounded-full border-4 border-accent-muted border-t-accent" }),
588
+ r && /* @__PURE__ */ e("span", { className: "text-sm text-ink-secondary", children: r })
1214
589
  ] });
1215
- return n ? /* @__PURE__ */ e.jsx("div", { className: "fixed inset-0 z-50 flex items-center justify-center bg-canvas/70 backdrop-blur-sm", children: a }) : a;
590
+ return t ? /* @__PURE__ */ e("div", { className: "fixed inset-0 z-50 flex items-center justify-center bg-canvas/70 backdrop-blur-sm", children: a }) : a;
1216
591
  }
1217
- function Ue({ checked: n, indeterminate: r, onChange: s, label: a = "Select row" }) {
1218
- const i = v.useRef(null);
1219
- return v.useEffect(() => {
592
+ function I({ checked: t, indeterminate: r, onChange: n, label: a = "Select row" }) {
593
+ const i = b.useRef(null);
594
+ return b.useEffect(() => {
1220
595
  i.current && (i.current.indeterminate = !!r);
1221
- }, [r]), /* @__PURE__ */ e.jsx(be, { ref: i, checked: n, onChange: (l) => s(l.target.checked), "aria-label": a });
596
+ }, [r]), /* @__PURE__ */ e(E, { ref: i, checked: t, onChange: (c) => n(c.target.checked), "aria-label": a });
1222
597
  }
1223
- function _r({
1224
- columns: n,
598
+ function Je({
599
+ columns: t,
1225
600
  data: r,
1226
- rowKey: s,
601
+ rowKey: n,
1227
602
  loading: a,
1228
603
  emptyMessage: i = "No records found.",
1229
- visibleColumns: l,
1230
- sortKey: f,
1231
- sortDirection: h,
1232
- onSortChange: c,
1233
- selectable: m,
1234
- selectedKeys: d = [],
1235
- onSelectedKeysChange: x,
1236
- onRowClick: y,
1237
- className: D
604
+ visibleColumns: c,
605
+ sortKey: l,
606
+ sortDirection: f,
607
+ onSortChange: o,
608
+ selectable: d,
609
+ selectedKeys: u = [],
610
+ onSelectedKeysChange: m,
611
+ onRowClick: v,
612
+ className: C
1238
613
  }) {
1239
- const O = l ? n.filter((N) => l.includes(N.key)) : n, j = r.map(s), _ = m && r.length > 0 && j.every((N) => d.includes(N)), C = m && j.some((N) => d.includes(N));
1240
- function T(N) {
1241
- if (!(!N.sortable || !c)) {
1242
- if (f !== N.key) return c(N.key, "asc");
1243
- if (h === "asc") return c(N.key, "desc");
1244
- c(N.key, null);
614
+ const N = c ? t.filter((g) => c.includes(g.key)) : t, x = r.map(n), w = d && r.length > 0 && x.every((g) => u.includes(g)), y = d && x.some((g) => u.includes(g));
615
+ function z(g) {
616
+ if (!(!g.sortable || !o)) {
617
+ if (l !== g.key) return o(g.key, "asc");
618
+ if (f === "asc") return o(g.key, "desc");
619
+ o(g.key, null);
1245
620
  }
1246
621
  }
1247
- function H() {
1248
- x && x(_ ? [] : j);
622
+ function T() {
623
+ m && m(w ? [] : x);
1249
624
  }
1250
- function J(N) {
1251
- x && x(d.includes(N) ? d.filter((k) => k !== N) : [...d, N]);
625
+ function j(g) {
626
+ m && m(u.includes(g) ? u.filter((p) => p !== g) : [...u, g]);
1252
627
  }
1253
- return /* @__PURE__ */ e.jsx("div", { className: b("overflow-x-auto rounded-lg border border-card-border bg-card", D), children: /* @__PURE__ */ e.jsxs("table", { className: "w-full text-left text-sm", children: [
1254
- /* @__PURE__ */ e.jsx("thead", { children: /* @__PURE__ */ e.jsxs("tr", { className: "border-b border-card-border bg-canvas", children: [
1255
- m && /* @__PURE__ */ e.jsx("th", { className: "w-10 px-4 py-3", children: /* @__PURE__ */ e.jsx(Ue, { checked: !!_, indeterminate: !_ && C, onChange: H, label: "Select all rows" }) }),
1256
- O.map((N) => /* @__PURE__ */ e.jsx(
628
+ return /* @__PURE__ */ e("div", { className: h("overflow-x-auto rounded-lg border border-card-border bg-card", C), children: /* @__PURE__ */ s("table", { className: "w-full text-left text-sm", children: [
629
+ /* @__PURE__ */ e("thead", { children: /* @__PURE__ */ s("tr", { className: "border-b border-card-border bg-canvas", children: [
630
+ d && /* @__PURE__ */ e("th", { className: "w-10 px-4 py-3", children: /* @__PURE__ */ e(I, { checked: !!w, indeterminate: !w && y, onChange: T, label: "Select all rows" }) }),
631
+ N.map((g) => /* @__PURE__ */ e(
1257
632
  "th",
1258
633
  {
1259
- style: { width: N.width },
1260
- className: b(
634
+ style: { width: g.width },
635
+ className: h(
1261
636
  "px-4 py-3 font-medium text-ink-secondary",
1262
- N.align === "right" && "text-right",
1263
- N.align === "center" && "text-center"
637
+ g.align === "right" && "text-right",
638
+ g.align === "center" && "text-center"
1264
639
  ),
1265
- children: N.sortable ? /* @__PURE__ */ e.jsxs("button", { onClick: () => T(N), className: "inline-flex items-center gap-1 hover:text-ink-primary", children: [
1266
- N.header,
1267
- f === N.key ? h === "asc" ? /* @__PURE__ */ e.jsx(Gt, { size: 12 }) : h === "desc" ? /* @__PURE__ */ e.jsx(Jt, { size: 12 }) : /* @__PURE__ */ e.jsx(Be, { size: 12, className: "opacity-40" }) : /* @__PURE__ */ e.jsx(Be, { size: 12, className: "opacity-40" })
1268
- ] }) : N.header
640
+ children: g.sortable ? /* @__PURE__ */ s("button", { onClick: () => z(g), className: "inline-flex items-center gap-1 hover:text-ink-primary", children: [
641
+ g.header,
642
+ l === g.key ? f === "asc" ? /* @__PURE__ */ e(me, { size: 12 }) : f === "desc" ? /* @__PURE__ */ e(fe, { size: 12 }) : /* @__PURE__ */ e(F, { size: 12, className: "opacity-40" }) : /* @__PURE__ */ e(F, { size: 12, className: "opacity-40" })
643
+ ] }) : g.header
1269
644
  },
1270
- N.key
645
+ g.key
1271
646
  ))
1272
647
  ] }) }),
1273
- /* @__PURE__ */ e.jsx("tbody", { children: a ? /* @__PURE__ */ e.jsx("tr", { children: /* @__PURE__ */ e.jsx("td", { colSpan: O.length + (m ? 1 : 0), className: "py-10", children: /* @__PURE__ */ e.jsx(it, { label: "Loading records..." }) }) }) : r.length === 0 ? /* @__PURE__ */ e.jsx("tr", { children: /* @__PURE__ */ e.jsx("td", { colSpan: O.length + (m ? 1 : 0), className: "py-10 text-center text-ink-muted", children: i }) }) : r.map((N) => {
1274
- const k = s(N);
1275
- return /* @__PURE__ */ e.jsxs(
648
+ /* @__PURE__ */ e("tbody", { children: a ? /* @__PURE__ */ e("tr", { children: /* @__PURE__ */ e("td", { colSpan: N.length + (d ? 1 : 0), className: "py-10", children: /* @__PURE__ */ e(ee, { label: "Loading records..." }) }) }) : r.length === 0 ? /* @__PURE__ */ e("tr", { children: /* @__PURE__ */ e("td", { colSpan: N.length + (d ? 1 : 0), className: "py-10 text-center text-ink-muted", children: i }) }) : r.map((g) => {
649
+ const p = n(g);
650
+ return /* @__PURE__ */ s(
1276
651
  "tr",
1277
652
  {
1278
- onClick: () => y == null ? void 0 : y(N),
1279
- className: b(
653
+ onClick: () => v == null ? void 0 : v(g),
654
+ className: h(
1280
655
  "border-b border-card-border last:border-0 hover:bg-accent-muted/60",
1281
- y && "cursor-pointer"
656
+ v && "cursor-pointer"
1282
657
  ),
1283
658
  children: [
1284
- m && /* @__PURE__ */ e.jsx("td", { className: "px-4 py-3", onClick: (I) => I.stopPropagation(), children: /* @__PURE__ */ e.jsx(Ue, { checked: d.includes(k), onChange: () => J(k) }) }),
1285
- O.map((I) => /* @__PURE__ */ e.jsx(
659
+ d && /* @__PURE__ */ e("td", { className: "px-4 py-3", onClick: (M) => M.stopPropagation(), children: /* @__PURE__ */ e(I, { checked: u.includes(p), onChange: () => j(p) }) }),
660
+ N.map((M) => /* @__PURE__ */ e(
1286
661
  "td",
1287
662
  {
1288
- className: b(
663
+ className: h(
1289
664
  "px-4 py-3 text-ink-primary",
1290
- I.align === "right" && "text-right",
1291
- I.align === "center" && "text-center"
665
+ M.align === "right" && "text-right",
666
+ M.align === "center" && "text-center"
1292
667
  ),
1293
- children: I.render(N)
668
+ children: M.render(g)
1294
669
  },
1295
- I.key
670
+ M.key
1296
671
  ))
1297
672
  ]
1298
673
  },
1299
- k
674
+ p
1300
675
  );
1301
676
  }) })
1302
677
  ] }) });
1303
678
  }
1304
- function fr({ children: n, className: r, ...s }) {
1305
- return n ? /* @__PURE__ */ e.jsxs("p", { className: b("mt-1 flex items-center gap-1 text-xs text-status-offline", r), ...s, children: [
1306
- /* @__PURE__ */ e.jsx(Kt, { size: 12, className: "shrink-0" }),
1307
- n
679
+ function Ae({ children: t, className: r, ...n }) {
680
+ return t ? /* @__PURE__ */ s("p", { className: h("mt-1 flex items-center gap-1 text-xs text-status-offline", r), ...n, children: [
681
+ /* @__PURE__ */ e(pe, { size: 12, className: "shrink-0" }),
682
+ t
1308
683
  ] }) : null;
1309
684
  }
1310
- function U({ label: n, htmlFor: r, required: s, error: a, hint: i, className: l, children: f, ...h }) {
1311
- return /* @__PURE__ */ e.jsxs("div", { className: b("flex flex-col", l), ...h, children: [
1312
- n && /* @__PURE__ */ e.jsxs("label", { htmlFor: r, className: "mb-1.5 text-sm font-medium text-ink-primary", children: [
1313
- n,
1314
- s && /* @__PURE__ */ e.jsx("span", { className: "ml-0.5 text-status-offline", children: "*" })
685
+ function L({ label: t, htmlFor: r, required: n, error: a, hint: i, className: c, children: l, ...f }) {
686
+ return /* @__PURE__ */ s("div", { className: h("flex flex-col", c), ...f, children: [
687
+ t && /* @__PURE__ */ s("label", { htmlFor: r, className: "mb-1.5 text-sm font-medium text-ink-primary", children: [
688
+ t,
689
+ n && /* @__PURE__ */ e("span", { className: "ml-0.5 text-status-offline", children: "*" })
1315
690
  ] }),
1316
- f,
1317
- i && !a && /* @__PURE__ */ e.jsx("p", { className: "mt-1 text-xs text-ink-muted", children: i }),
1318
- /* @__PURE__ */ e.jsx(fr, { children: a })
691
+ l,
692
+ i && !a && /* @__PURE__ */ e("p", { className: "mt-1 text-xs text-ink-muted", children: i }),
693
+ /* @__PURE__ */ e(Ae, { children: a })
1319
694
  ] });
1320
695
  }
1321
- function Tr({ label: n, required: r, error: s, value: a, onChange: i, min: l, max: f, disabled: h, className: c }) {
1322
- const m = v.useId();
1323
- return /* @__PURE__ */ e.jsx(U, { label: n, htmlFor: m, required: r, error: s, className: c, children: /* @__PURE__ */ e.jsxs("div", { className: "relative", children: [
1324
- /* @__PURE__ */ e.jsx(Ke, { size: 16, className: "pointer-events-none absolute left-3 top-1/2 -translate-y-1/2 text-ink-muted" }),
1325
- /* @__PURE__ */ e.jsx(
696
+ function Xe({ label: t, required: r, error: n, value: a, onChange: i, min: c, max: l, disabled: f, className: o }) {
697
+ const d = b.useId();
698
+ return /* @__PURE__ */ e(L, { label: t, htmlFor: d, required: r, error: n, className: o, children: /* @__PURE__ */ s("div", { className: "relative", children: [
699
+ /* @__PURE__ */ e(G, { size: 16, className: "pointer-events-none absolute left-3 top-1/2 -translate-y-1/2 text-ink-muted" }),
700
+ /* @__PURE__ */ e(
1326
701
  "input",
1327
702
  {
1328
- id: m,
703
+ id: d,
1329
704
  type: "date",
1330
705
  value: a ?? "",
1331
- min: l,
1332
- max: f,
1333
- disabled: h,
1334
- onChange: (d) => i(d.target.value),
1335
- className: b(
706
+ min: c,
707
+ max: l,
708
+ disabled: f,
709
+ onChange: (u) => i(u.target.value),
710
+ className: h(
1336
711
  "h-10 w-full rounded-md border bg-input pl-9 pr-3 text-sm text-ink-primary",
1337
712
  "focus:outline-none focus:ring-2 focus:ring-accent/40 disabled:opacity-50",
1338
- s ? "border-status-offline" : "border-card-border"
713
+ n ? "border-status-offline" : "border-card-border"
1339
714
  )
1340
715
  }
1341
716
  )
1342
717
  ] }) });
1343
718
  }
1344
- const ot = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"], xr = ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"], mr = ["This Financial Year", "This Month", "Last Month", "Next Month", "This Quarter", "This Year", "Last Year", "Custom Range"];
1345
- function ne(n) {
1346
- return n ? `${String(n.getDate()).padStart(2, "0")}-${ot[n.getMonth()]}-${n.getFullYear()}` : "";
719
+ const te = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"], De = ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"], Te = ["This Financial Year", "This Month", "Last Month", "Next Month", "This Quarter", "This Year", "Last Year", "Custom Range"];
720
+ function A(t) {
721
+ return t ? `${String(t.getDate()).padStart(2, "0")}-${te[t.getMonth()]}-${t.getFullYear()}` : "";
1347
722
  }
1348
- function hr(n, r = /* @__PURE__ */ new Date()) {
1349
- const s = r.getFullYear(), a = r.getMonth();
1350
- switch (n) {
723
+ function je(t, r = /* @__PURE__ */ new Date()) {
724
+ const n = r.getFullYear(), a = r.getMonth();
725
+ switch (t) {
1351
726
  case "This Financial Year": {
1352
- const i = a >= 3 ? s : s - 1;
727
+ const i = a >= 3 ? n : n - 1;
1353
728
  return { from: new Date(i, 3, 1), to: new Date(i + 1, 2, 31) };
1354
729
  }
1355
730
  case "This Month":
1356
- return { from: new Date(s, a, 1), to: new Date(s, a + 1, 0) };
731
+ return { from: new Date(n, a, 1), to: new Date(n, a + 1, 0) };
1357
732
  case "Last Month":
1358
- return { from: new Date(s, a - 1, 1), to: new Date(s, a, 0) };
733
+ return { from: new Date(n, a - 1, 1), to: new Date(n, a, 0) };
1359
734
  case "Next Month":
1360
- return { from: new Date(s, a + 1, 1), to: new Date(s, a + 2, 0) };
735
+ return { from: new Date(n, a + 1, 1), to: new Date(n, a + 2, 0) };
1361
736
  case "This Quarter": {
1362
737
  const i = Math.floor(a / 3) * 3;
1363
- return { from: new Date(s, i, 1), to: new Date(s, i + 3, 0) };
738
+ return { from: new Date(n, i, 1), to: new Date(n, i + 3, 0) };
1364
739
  }
1365
740
  case "This Year":
1366
- return { from: new Date(s, 0, 1), to: new Date(s, 11, 31) };
741
+ return { from: new Date(n, 0, 1), to: new Date(n, 11, 31) };
1367
742
  case "Last Year":
1368
- return { from: new Date(s - 1, 0, 1), to: new Date(s - 1, 11, 31) };
743
+ return { from: new Date(n - 1, 0, 1), to: new Date(n - 1, 11, 31) };
1369
744
  default:
1370
745
  return { from: null, to: null };
1371
746
  }
1372
747
  }
1373
- function He({ year: n, month: r, from: s, to: a, onPick: i }) {
1374
- const f = new Date(n, r, 1).getDay(), h = new Date(n, r + 1, 0).getDate(), c = [];
1375
- for (let x = 0; x < f; x++) c.push(null);
1376
- for (let x = 1; x <= h; x++) c.push(x);
1377
- function m(x) {
1378
- if (!x || !s || !a) return !1;
1379
- const y = new Date(n, r, x).getTime();
1380
- return y >= s.getTime() && y <= a.getTime();
748
+ function q({ year: t, month: r, from: n, to: a, onPick: i }) {
749
+ const l = new Date(t, r, 1).getDay(), f = new Date(t, r + 1, 0).getDate(), o = [];
750
+ for (let m = 0; m < l; m++) o.push(null);
751
+ for (let m = 1; m <= f; m++) o.push(m);
752
+ function d(m) {
753
+ if (!m || !n || !a) return !1;
754
+ const v = new Date(t, r, m).getTime();
755
+ return v >= n.getTime() && v <= a.getTime();
1381
756
  }
1382
- function d(x) {
1383
- if (!x) return !1;
1384
- const y = new Date(n, r, x).getTime();
1385
- return s && y === s.getTime() || a && y === a.getTime();
757
+ function u(m) {
758
+ if (!m) return !1;
759
+ const v = new Date(t, r, m).getTime();
760
+ return n && v === n.getTime() || a && v === a.getTime();
1386
761
  }
1387
- return /* @__PURE__ */ e.jsxs("div", { children: [
1388
- /* @__PURE__ */ e.jsxs("p", { className: "mb-2 text-center text-sm font-semibold text-ink-primary", children: [
1389
- ot[r],
762
+ return /* @__PURE__ */ s("div", { children: [
763
+ /* @__PURE__ */ s("p", { className: "mb-2 text-center text-sm font-semibold text-ink-primary", children: [
764
+ te[r],
1390
765
  " ",
1391
- n
766
+ t
1392
767
  ] }),
1393
- /* @__PURE__ */ e.jsxs("div", { className: "grid grid-cols-7 gap-y-1 text-center text-xs", children: [
1394
- xr.map((x) => /* @__PURE__ */ e.jsx("span", { className: "text-ink-muted", children: x }, x)),
1395
- c.map((x, y) => /* @__PURE__ */ e.jsx(
768
+ /* @__PURE__ */ s("div", { className: "grid grid-cols-7 gap-y-1 text-center text-xs", children: [
769
+ De.map((m) => /* @__PURE__ */ e("span", { className: "text-ink-muted", children: m }, m)),
770
+ o.map((m, v) => /* @__PURE__ */ e(
1396
771
  "button",
1397
772
  {
1398
773
  type: "button",
1399
- disabled: !x,
1400
- onClick: () => x && i(new Date(n, r, x)),
1401
- className: b(
774
+ disabled: !m,
775
+ onClick: () => m && i(new Date(t, r, m)),
776
+ className: h(
1402
777
  "h-7 w-7 rounded text-ink-primary",
1403
- !x && "invisible",
1404
- x && m(x) && "bg-accent-muted",
1405
- x && d(x) && "bg-accent text-white"
778
+ !m && "invisible",
779
+ m && d(m) && "bg-accent-muted",
780
+ m && u(m) && "bg-accent text-white"
1406
781
  ),
1407
- children: x
782
+ children: m
1408
783
  },
1409
- y
784
+ v
1410
785
  ))
1411
786
  ] })
1412
787
  ] });
1413
788
  }
1414
- function Mr({ label: n, required: r, error: s, value: a, onChange: i, className: l }) {
1415
- const [f, h] = v.useState(!1), [c, m] = v.useState("Custom Range"), [d, x] = v.useState(a), [y, D] = v.useState(() => (a.from ?? /* @__PURE__ */ new Date()).getMonth()), [O, j] = v.useState(() => (a.from ?? /* @__PURE__ */ new Date()).getFullYear()), _ = v.useRef(null);
1416
- v.useEffect(() => {
1417
- function k(I) {
1418
- _.current && !_.current.contains(I.target) && h(!1);
789
+ function Ke({ label: t, required: r, error: n, value: a, onChange: i, className: c }) {
790
+ const [l, f] = b.useState(!1), [o, d] = b.useState("Custom Range"), [u, m] = b.useState(a), [v, C] = b.useState(() => (a.from ?? /* @__PURE__ */ new Date()).getMonth()), [N, x] = b.useState(() => (a.from ?? /* @__PURE__ */ new Date()).getFullYear()), w = b.useRef(null);
791
+ b.useEffect(() => {
792
+ function p(M) {
793
+ w.current && !w.current.contains(M.target) && f(!1);
1419
794
  }
1420
- return document.addEventListener("mousedown", k), () => document.removeEventListener("mousedown", k);
795
+ return document.addEventListener("mousedown", p), () => document.removeEventListener("mousedown", p);
1421
796
  }, []);
1422
- function C(k) {
1423
- m(k), k !== "Custom Range" && x(hr(k));
797
+ function y(p) {
798
+ d(p), p !== "Custom Range" && m(je(p));
1424
799
  }
1425
- function T(k) {
1426
- m("Custom Range"), !d.from || d.from && d.to ? x({ from: k, to: null }) : k.getTime() < d.from.getTime() ? x({ from: k, to: d.from }) : x({ ...d, to: k });
800
+ function z(p) {
801
+ d("Custom Range"), !u.from || u.from && u.to ? m({ from: p, to: null }) : p.getTime() < u.from.getTime() ? m({ from: p, to: u.from }) : m({ ...u, to: p });
1427
802
  }
1428
- function H() {
1429
- y === 0 ? (D(11), j((k) => k - 1)) : D((k) => k - 1);
803
+ function T() {
804
+ v === 0 ? (C(11), x((p) => p - 1)) : C((p) => p - 1);
1430
805
  }
1431
- function J() {
1432
- y === 11 ? (D(0), j((k) => k + 1)) : D((k) => k + 1);
806
+ function j() {
807
+ v === 11 ? (C(0), x((p) => p + 1)) : C((p) => p + 1);
1433
808
  }
1434
- function N() {
1435
- i(d), h(!1);
809
+ function g() {
810
+ i(u), f(!1);
1436
811
  }
1437
- return /* @__PURE__ */ e.jsx(U, { label: n, required: r, error: s, className: l, children: /* @__PURE__ */ e.jsxs("div", { ref: _, className: "relative", children: [
1438
- /* @__PURE__ */ e.jsxs(
812
+ return /* @__PURE__ */ e(L, { label: t, required: r, error: n, className: c, children: /* @__PURE__ */ s("div", { ref: w, className: "relative", children: [
813
+ /* @__PURE__ */ s(
1439
814
  "button",
1440
815
  {
1441
816
  type: "button",
1442
- onClick: () => h((k) => !k),
1443
- className: b(
817
+ onClick: () => f((p) => !p),
818
+ className: h(
1444
819
  "flex h-10 w-full items-center gap-2 rounded-md border bg-input px-3 text-left text-sm",
1445
820
  "focus:outline-none focus:ring-2 focus:ring-accent/40",
1446
- s ? "border-status-offline" : "border-card-border"
821
+ n ? "border-status-offline" : "border-card-border"
1447
822
  ),
1448
823
  children: [
1449
- /* @__PURE__ */ e.jsx(Ke, { size: 16, className: "shrink-0 text-ink-muted" }),
1450
- /* @__PURE__ */ e.jsx("span", { className: a.from ? "text-ink-primary" : "text-ink-muted", children: a.from && a.to ? `${ne(a.from)} - ${ne(a.to)}` : "Select date range" })
824
+ /* @__PURE__ */ e(G, { size: 16, className: "shrink-0 text-ink-muted" }),
825
+ /* @__PURE__ */ e("span", { className: a.from ? "text-ink-primary" : "text-ink-muted", children: a.from && a.to ? `${A(a.from)} - ${A(a.to)}` : "Select date range" })
1451
826
  ]
1452
827
  }
1453
828
  ),
1454
- f && /* @__PURE__ */ e.jsxs("div", { className: "absolute z-20 mt-1 flex w-[560px] max-w-[90vw] overflow-hidden rounded-md border border-card-border bg-card shadow-xl", children: [
1455
- /* @__PURE__ */ e.jsx("div", { className: "w-40 shrink-0 border-r border-card-border py-2", children: mr.map((k) => /* @__PURE__ */ e.jsx(
829
+ l && /* @__PURE__ */ s("div", { className: "absolute z-20 mt-1 flex w-[560px] max-w-[90vw] overflow-hidden rounded-md border border-card-border bg-card shadow-xl", children: [
830
+ /* @__PURE__ */ e("div", { className: "w-40 shrink-0 border-r border-card-border py-2", children: Te.map((p) => /* @__PURE__ */ e(
1456
831
  "button",
1457
832
  {
1458
833
  type: "button",
1459
- onClick: () => C(k),
1460
- className: b(
834
+ onClick: () => y(p),
835
+ className: h(
1461
836
  "block w-full px-3 py-2 text-left text-sm",
1462
- c === k ? "bg-accent text-white" : "text-ink-primary hover:bg-accent-muted"
837
+ o === p ? "bg-accent text-white" : "text-ink-primary hover:bg-accent-muted"
1463
838
  ),
1464
- children: k
839
+ children: p
1465
840
  },
1466
- k
841
+ p
1467
842
  )) }),
1468
- /* @__PURE__ */ e.jsxs("div", { className: "flex-1 p-3", children: [
1469
- /* @__PURE__ */ e.jsxs("div", { className: "mb-2 flex items-center justify-between", children: [
1470
- /* @__PURE__ */ e.jsx("button", { type: "button", onClick: H, className: "text-ink-muted hover:text-ink-primary", children: /* @__PURE__ */ e.jsx(Zt, { size: 16 }) }),
1471
- /* @__PURE__ */ e.jsx("button", { type: "button", onClick: J, className: "text-ink-muted hover:text-ink-primary", children: /* @__PURE__ */ e.jsx(Qt, { size: 16 }) })
843
+ /* @__PURE__ */ s("div", { className: "flex-1 p-3", children: [
844
+ /* @__PURE__ */ s("div", { className: "mb-2 flex items-center justify-between", children: [
845
+ /* @__PURE__ */ e("button", { type: "button", onClick: T, className: "text-ink-muted hover:text-ink-primary", children: /* @__PURE__ */ e(be, { size: 16 }) }),
846
+ /* @__PURE__ */ e("button", { type: "button", onClick: j, className: "text-ink-muted hover:text-ink-primary", children: /* @__PURE__ */ e(xe, { size: 16 }) })
1472
847
  ] }),
1473
- /* @__PURE__ */ e.jsxs("div", { className: "grid grid-cols-2 gap-4", children: [
1474
- /* @__PURE__ */ e.jsx(He, { year: O, month: y, from: d.from, to: d.to, onPick: T }),
1475
- /* @__PURE__ */ e.jsx(
1476
- He,
848
+ /* @__PURE__ */ s("div", { className: "grid grid-cols-2 gap-4", children: [
849
+ /* @__PURE__ */ e(q, { year: N, month: v, from: u.from, to: u.to, onPick: z }),
850
+ /* @__PURE__ */ e(
851
+ q,
1477
852
  {
1478
- year: y === 11 ? O + 1 : O,
1479
- month: y === 11 ? 0 : y + 1,
1480
- from: d.from,
1481
- to: d.to,
1482
- onPick: T
853
+ year: v === 11 ? N + 1 : N,
854
+ month: v === 11 ? 0 : v + 1,
855
+ from: u.from,
856
+ to: u.to,
857
+ onPick: z
1483
858
  }
1484
859
  )
1485
860
  ] }),
1486
- /* @__PURE__ */ e.jsxs("div", { className: "mt-3 flex items-center justify-between border-t border-card-border pt-3", children: [
1487
- /* @__PURE__ */ e.jsx("span", { className: "text-sm text-ink-secondary", children: d.from && d.to ? `${ne(d.from)} - ${ne(d.to)}` : "Select a range" }),
1488
- /* @__PURE__ */ e.jsxs("div", { className: "flex gap-2", children: [
1489
- /* @__PURE__ */ e.jsx(F, { variant: "cancel", size: "sm", onClick: () => h(!1), children: "Cancel" }),
1490
- /* @__PURE__ */ e.jsx(F, { variant: "primary", size: "sm", onClick: N, disabled: !d.from || !d.to, children: "Apply" })
861
+ /* @__PURE__ */ s("div", { className: "mt-3 flex items-center justify-between border-t border-card-border pt-3", children: [
862
+ /* @__PURE__ */ e("span", { className: "text-sm text-ink-secondary", children: u.from && u.to ? `${A(u.from)} - ${A(u.to)}` : "Select a range" }),
863
+ /* @__PURE__ */ s("div", { className: "flex gap-2", children: [
864
+ /* @__PURE__ */ e(B, { variant: "cancel", size: "sm", onClick: () => f(!1), children: "Cancel" }),
865
+ /* @__PURE__ */ e(B, { variant: "primary", size: "sm", onClick: g, disabled: !u.from || !u.to, children: "Apply" })
1491
866
  ] })
1492
867
  ] })
1493
868
  ] })
1494
869
  ] })
1495
870
  ] }) });
1496
871
  }
1497
- function Pr({
1498
- label: n,
872
+ function et({
873
+ label: t,
1499
874
  required: r,
1500
- error: s,
875
+ error: n,
1501
876
  options: a,
1502
877
  value: i,
1503
- onChange: l,
1504
- placeholder: f = "Select...",
1505
- searchable: h = !0,
1506
- disabled: c,
1507
- className: m
878
+ onChange: c,
879
+ placeholder: l = "Select...",
880
+ searchable: f = !0,
881
+ disabled: o,
882
+ className: d
1508
883
  }) {
1509
- const [d, x] = v.useState(!1), [y, D] = v.useState(""), O = v.useRef(null);
1510
- v.useEffect(() => {
1511
- function C(T) {
1512
- O.current && !O.current.contains(T.target) && x(!1);
884
+ const [u, m] = b.useState(!1), [v, C] = b.useState(""), N = b.useRef(null);
885
+ b.useEffect(() => {
886
+ function y(z) {
887
+ N.current && !N.current.contains(z.target) && m(!1);
1513
888
  }
1514
- return document.addEventListener("mousedown", C), () => document.removeEventListener("mousedown", C);
889
+ return document.addEventListener("mousedown", y), () => document.removeEventListener("mousedown", y);
1515
890
  }, []);
1516
- const j = h && y ? a.filter((C) => C.label.toLowerCase().includes(y.toLowerCase())) : a, _ = a.find((C) => C.value === i);
1517
- return /* @__PURE__ */ e.jsx(U, { label: n, required: r, error: s, className: m, children: /* @__PURE__ */ e.jsxs("div", { ref: O, className: "relative", children: [
1518
- /* @__PURE__ */ e.jsxs(
891
+ const x = f && v ? a.filter((y) => y.label.toLowerCase().includes(v.toLowerCase())) : a, w = a.find((y) => y.value === i);
892
+ return /* @__PURE__ */ e(L, { label: t, required: r, error: n, className: d, children: /* @__PURE__ */ s("div", { ref: N, className: "relative", children: [
893
+ /* @__PURE__ */ s(
1519
894
  "button",
1520
895
  {
1521
896
  type: "button",
1522
- disabled: c,
1523
- onClick: () => x((C) => !C),
1524
- className: b(
897
+ disabled: o,
898
+ onClick: () => m((y) => !y),
899
+ className: h(
1525
900
  "flex h-10 w-full items-center justify-between rounded-md border bg-input px-3 text-sm text-left",
1526
901
  "focus:outline-none focus:ring-2 focus:ring-accent/40 disabled:opacity-50",
1527
- s ? "border-status-offline" : "border-card-border",
1528
- _ ? "text-ink-primary" : "text-ink-muted"
902
+ n ? "border-status-offline" : "border-card-border",
903
+ w ? "text-ink-primary" : "text-ink-muted"
1529
904
  ),
1530
905
  children: [
1531
- /* @__PURE__ */ e.jsx("span", { className: "truncate", children: (_ == null ? void 0 : _.label) ?? f }),
1532
- /* @__PURE__ */ e.jsx(tt, { size: 16, className: b("shrink-0 text-ink-muted transition-transform", d && "rotate-180") })
906
+ /* @__PURE__ */ e("span", { className: "truncate", children: (w == null ? void 0 : w.label) ?? l }),
907
+ /* @__PURE__ */ e(Q, { size: 16, className: h("shrink-0 text-ink-muted transition-transform", u && "rotate-180") })
1533
908
  ]
1534
909
  }
1535
910
  ),
1536
- d && /* @__PURE__ */ e.jsxs("div", { className: "absolute z-20 mt-1 w-full overflow-hidden rounded-md border border-card-border bg-card shadow-lg", children: [
1537
- h && /* @__PURE__ */ e.jsxs("div", { className: "flex items-center gap-2 border-b border-card-border px-3 py-2", children: [
1538
- /* @__PURE__ */ e.jsx(he, { size: 14, className: "text-ink-muted" }),
1539
- /* @__PURE__ */ e.jsx(
911
+ u && /* @__PURE__ */ s("div", { className: "absolute z-20 mt-1 w-full overflow-hidden rounded-md border border-card-border bg-card shadow-lg", children: [
912
+ f && /* @__PURE__ */ s("div", { className: "flex items-center gap-2 border-b border-card-border px-3 py-2", children: [
913
+ /* @__PURE__ */ e(P, { size: 14, className: "text-ink-muted" }),
914
+ /* @__PURE__ */ e(
1540
915
  "input",
1541
916
  {
1542
917
  autoFocus: !0,
1543
- value: y,
1544
- onChange: (C) => D(C.target.value),
918
+ value: v,
919
+ onChange: (y) => C(y.target.value),
1545
920
  placeholder: "Search...",
1546
921
  className: "w-full bg-transparent text-sm text-ink-primary placeholder:text-ink-muted focus:outline-none"
1547
922
  }
1548
923
  )
1549
924
  ] }),
1550
- /* @__PURE__ */ e.jsxs("ul", { className: "max-h-56 overflow-y-auto py-1", role: "listbox", children: [
1551
- j.length === 0 && /* @__PURE__ */ e.jsx("li", { className: "px-3 py-2 text-sm text-ink-muted", children: "No options" }),
1552
- j.map((C) => /* @__PURE__ */ e.jsx("li", { children: /* @__PURE__ */ e.jsxs(
925
+ /* @__PURE__ */ s("ul", { className: "max-h-56 overflow-y-auto py-1", role: "listbox", children: [
926
+ x.length === 0 && /* @__PURE__ */ e("li", { className: "px-3 py-2 text-sm text-ink-muted", children: "No options" }),
927
+ x.map((y) => /* @__PURE__ */ e("li", { children: /* @__PURE__ */ s(
1553
928
  "button",
1554
929
  {
1555
930
  type: "button",
1556
- disabled: C.disabled,
931
+ disabled: y.disabled,
1557
932
  onClick: () => {
1558
- l(C.value), x(!1), D("");
933
+ c(y.value), m(!1), C("");
1559
934
  },
1560
- className: b(
935
+ className: h(
1561
936
  "flex w-full items-center justify-between px-3 py-2 text-left text-sm hover:bg-accent-muted disabled:opacity-40",
1562
- C.value === i ? "text-accent" : "text-ink-primary"
937
+ y.value === i ? "text-accent" : "text-ink-primary"
1563
938
  ),
1564
939
  children: [
1565
- C.label,
1566
- C.value === i && /* @__PURE__ */ e.jsx(et, { size: 14 })
940
+ y.label,
941
+ y.value === i && /* @__PURE__ */ e(_, { size: 14 })
1567
942
  ]
1568
943
  }
1569
- ) }, C.value))
944
+ ) }, y.value))
1570
945
  ] })
1571
946
  ] })
1572
947
  ] }) });
1573
948
  }
1574
- function Or({
1575
- items: n,
949
+ function tt({
950
+ items: t,
1576
951
  onChange: r,
1577
- createItem: s,
952
+ createItem: n,
1578
953
  renderRow: a,
1579
954
  addLabel: i = "Add row",
1580
- minRows: l = 0,
1581
- className: f
955
+ minRows: c = 0,
956
+ className: l
1582
957
  }) {
1583
- function h(m, d) {
1584
- const x = n.slice();
1585
- x[m] = { ...x[m], ...d }, r(x);
958
+ function f(d, u) {
959
+ const m = t.slice();
960
+ m[d] = { ...m[d], ...u }, r(m);
1586
961
  }
1587
- function c(m) {
1588
- r(n.filter((d, x) => x !== m));
962
+ function o(d) {
963
+ r(t.filter((u, m) => m !== d));
1589
964
  }
1590
- return /* @__PURE__ */ e.jsxs("div", { className: b("flex flex-col gap-2", f), children: [
1591
- n.map((m, d) => /* @__PURE__ */ e.jsxs("div", { className: "flex items-center gap-2", children: [
1592
- /* @__PURE__ */ e.jsx("div", { className: "flex-1", children: a(m, d, (x) => h(d, x)) }),
1593
- /* @__PURE__ */ e.jsx(
1594
- B,
965
+ return /* @__PURE__ */ s("div", { className: h("flex flex-col gap-2", l), children: [
966
+ t.map((d, u) => /* @__PURE__ */ s("div", { className: "flex items-center gap-2", children: [
967
+ /* @__PURE__ */ e("div", { className: "flex-1", children: a(d, u, (m) => f(u, m)) }),
968
+ /* @__PURE__ */ e(
969
+ S,
1595
970
  {
1596
- icon: /* @__PURE__ */ e.jsx(or, { size: 16 }),
971
+ icon: /* @__PURE__ */ e(Be, { size: 16 }),
1597
972
  label: "Remove row",
1598
973
  variant: "danger",
1599
974
  size: "sm",
1600
- disabled: n.length <= l,
1601
- onClick: () => c(d)
975
+ disabled: t.length <= c,
976
+ onClick: () => o(u)
1602
977
  }
1603
978
  )
1604
- ] }, d)),
1605
- /* @__PURE__ */ e.jsx(F, { variant: "ghost", size: "sm", icon: /* @__PURE__ */ e.jsx(st, { size: 14 }), onClick: () => r([...n, s()]), className: "self-start", children: i })
979
+ ] }, u)),
980
+ /* @__PURE__ */ e(B, { variant: "ghost", size: "sm", icon: /* @__PURE__ */ e(X, { size: 14 }), onClick: () => r([...t, n()]), className: "self-start", children: i })
1606
981
  ] });
1607
982
  }
1608
- function Dr({ open: n, onSearch: r, onClear: s, children: a, className: i }) {
1609
- return n ? /* @__PURE__ */ e.jsxs(
983
+ function rt({ open: t, onSearch: r, onClear: n, children: a, className: i }) {
984
+ return t ? /* @__PURE__ */ s(
1610
985
  "div",
1611
986
  {
1612
- className: b(
987
+ className: h(
1613
988
  "z-20 w-full max-w-md rounded-lg border border-card-border bg-card p-4 shadow-lg",
1614
989
  i
1615
990
  ),
1616
991
  children: [
1617
- /* @__PURE__ */ e.jsx("div", { className: "grid grid-cols-1 gap-3 sm:grid-cols-2", children: a }),
1618
- /* @__PURE__ */ e.jsxs("div", { className: "mt-4 flex items-center justify-end gap-2 border-t border-card-border pt-3", children: [
1619
- /* @__PURE__ */ e.jsx(F, { variant: "cancel", size: "sm", onClick: s, children: "Clear filters" }),
1620
- /* @__PURE__ */ e.jsx(F, { variant: "primary", size: "sm", onClick: r, children: "Search" })
992
+ /* @__PURE__ */ e("div", { className: "grid grid-cols-1 gap-3 sm:grid-cols-2", children: a }),
993
+ /* @__PURE__ */ s("div", { className: "mt-4 flex items-center justify-end gap-2 border-t border-card-border pt-3", children: [
994
+ /* @__PURE__ */ e(B, { variant: "cancel", size: "sm", onClick: n, children: "Clear filters" }),
995
+ /* @__PURE__ */ e(B, { variant: "primary", size: "sm", onClick: r, children: "Search" })
1621
996
  ] })
1622
997
  ]
1623
998
  }
1624
999
  ) : null;
1625
1000
  }
1626
- const br = v.forwardRef(
1627
- ({ label: n = "Add", className: r, ...s }, a) => /* @__PURE__ */ e.jsx(
1001
+ const Oe = b.forwardRef(
1002
+ ({ label: t = "Add", className: r, ...n }, a) => /* @__PURE__ */ e(
1628
1003
  "button",
1629
1004
  {
1630
1005
  ref: a,
1631
- "aria-label": n,
1632
- title: n,
1633
- className: b(
1006
+ "aria-label": t,
1007
+ title: t,
1008
+ className: h(
1634
1009
  "fixed bottom-6 right-6 z-40 flex h-14 w-14 items-center justify-center rounded-full",
1635
1010
  "bg-accent text-white shadow-lg hover:brightness-110 active:scale-95",
1636
1011
  "transition-all duration-150 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-accent/50",
1637
1012
  r
1638
1013
  ),
1639
- ...s,
1640
- children: /* @__PURE__ */ e.jsx(st, { size: 24, strokeWidth: 2.5 })
1014
+ ...n,
1015
+ children: /* @__PURE__ */ e(X, { size: 24, strokeWidth: 2.5 })
1641
1016
  }
1642
1017
  )
1643
1018
  );
1644
- br.displayName = "FloatingAddButton";
1645
- function zr({
1646
- open: n,
1019
+ Oe.displayName = "FloatingAddButton";
1020
+ function nt({
1021
+ open: t,
1647
1022
  onClose: r,
1648
- onSubmit: s,
1023
+ onSubmit: n,
1649
1024
  title: a,
1650
1025
  size: i = "md",
1651
- submitLabel: l = "Ok",
1652
- cancelLabel: f = "Close",
1653
- submitting: h,
1654
- submitDisabled: c,
1655
- children: m
1026
+ submitLabel: c = "Ok",
1027
+ cancelLabel: l = "Close",
1028
+ submitting: f,
1029
+ submitDisabled: o,
1030
+ children: d
1656
1031
  }) {
1657
- return /* @__PURE__ */ e.jsx(
1658
- pe,
1032
+ return /* @__PURE__ */ e(
1033
+ R,
1659
1034
  {
1660
- open: n,
1035
+ open: t,
1661
1036
  onClose: r,
1662
1037
  title: a,
1663
1038
  size: i,
1664
- footer: /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
1665
- /* @__PURE__ */ e.jsx(F, { variant: "cancel", onClick: r, disabled: h, children: f }),
1666
- /* @__PURE__ */ e.jsx(F, { variant: "primary", onClick: s, loading: h, disabled: c, children: l })
1039
+ footer: /* @__PURE__ */ s($, { children: [
1040
+ /* @__PURE__ */ e(B, { variant: "cancel", onClick: r, disabled: f, children: l }),
1041
+ /* @__PURE__ */ e(B, { variant: "primary", onClick: n, loading: f, disabled: o, children: c })
1667
1042
  ] }),
1668
- children: /* @__PURE__ */ e.jsx(
1043
+ children: /* @__PURE__ */ e(
1669
1044
  "form",
1670
1045
  {
1671
- onSubmit: (d) => {
1672
- d.preventDefault(), s();
1046
+ onSubmit: (u) => {
1047
+ u.preventDefault(), n();
1673
1048
  },
1674
1049
  className: "flex flex-col gap-4",
1675
- children: m
1050
+ children: d
1676
1051
  }
1677
1052
  )
1678
1053
  }
1679
1054
  );
1680
1055
  }
1681
- const pr = v.forwardRef(
1682
- ({ label: n, required: r, error: s, hint: a, icon: i, id: l, className: f, ...h }, c) => {
1683
- const m = l ?? v.useId();
1684
- return /* @__PURE__ */ e.jsx(U, { label: n, htmlFor: m, required: r, error: s, hint: a, children: /* @__PURE__ */ e.jsxs("div", { className: "relative", children: [
1685
- i && /* @__PURE__ */ e.jsx("span", { className: "pointer-events-none absolute left-3 top-1/2 -translate-y-1/2 text-ink-muted", children: i }),
1686
- /* @__PURE__ */ e.jsx(
1056
+ const Pe = b.forwardRef(
1057
+ ({ label: t, required: r, error: n, hint: a, icon: i, id: c, className: l, ...f }, o) => {
1058
+ const d = c ?? b.useId();
1059
+ return /* @__PURE__ */ e(L, { label: t, htmlFor: d, required: r, error: n, hint: a, children: /* @__PURE__ */ s("div", { className: "relative", children: [
1060
+ i && /* @__PURE__ */ e("span", { className: "pointer-events-none absolute left-3 top-1/2 -translate-y-1/2 text-ink-muted", children: i }),
1061
+ /* @__PURE__ */ e(
1687
1062
  "input",
1688
1063
  {
1689
- ref: c,
1690
- id: m,
1691
- className: b(
1064
+ ref: o,
1065
+ id: d,
1066
+ className: h(
1692
1067
  "h-10 w-full rounded-md border bg-input px-3 text-sm text-ink-primary placeholder:text-ink-muted",
1693
1068
  "focus:outline-none focus:ring-2 focus:ring-accent/40",
1694
- s ? "border-status-offline" : "border-card-border",
1069
+ n ? "border-status-offline" : "border-card-border",
1695
1070
  i && "pl-9",
1696
- f
1071
+ l
1697
1072
  ),
1698
- "aria-invalid": !!s,
1699
- ...h
1073
+ "aria-invalid": !!n,
1074
+ ...f
1700
1075
  }
1701
1076
  )
1702
1077
  ] }) });
1703
1078
  }
1704
1079
  );
1705
- pr.displayName = "InputField";
1706
- function Ar({
1707
- label: n,
1080
+ Pe.displayName = "InputField";
1081
+ function at({
1082
+ label: t,
1708
1083
  required: r,
1709
- error: s,
1084
+ error: n,
1710
1085
  options: a,
1711
1086
  value: i,
1712
- onChange: l,
1713
- placeholder: f = "Select...",
1714
- className: h
1087
+ onChange: c,
1088
+ placeholder: l = "Select...",
1089
+ className: f
1715
1090
  }) {
1716
- const [c, m] = v.useState(!1), [d, x] = v.useState(""), y = v.useRef(null);
1717
- v.useEffect(() => {
1718
- function j(_) {
1719
- y.current && !y.current.contains(_.target) && m(!1);
1091
+ const [o, d] = b.useState(!1), [u, m] = b.useState(""), v = b.useRef(null);
1092
+ b.useEffect(() => {
1093
+ function x(w) {
1094
+ v.current && !v.current.contains(w.target) && d(!1);
1720
1095
  }
1721
- return document.addEventListener("mousedown", j), () => document.removeEventListener("mousedown", j);
1096
+ return document.addEventListener("mousedown", x), () => document.removeEventListener("mousedown", x);
1722
1097
  }, []);
1723
- const D = d ? a.filter((j) => j.label.toLowerCase().includes(d.toLowerCase())) : a;
1724
- function O(j) {
1725
- l(i.includes(j) ? i.filter((_) => _ !== j) : [...i, j]);
1098
+ const C = u ? a.filter((x) => x.label.toLowerCase().includes(u.toLowerCase())) : a;
1099
+ function N(x) {
1100
+ c(i.includes(x) ? i.filter((w) => w !== x) : [...i, x]);
1726
1101
  }
1727
- return /* @__PURE__ */ e.jsx(U, { label: n, required: r, error: s, className: h, children: /* @__PURE__ */ e.jsxs("div", { ref: y, className: "relative", children: [
1728
- /* @__PURE__ */ e.jsxs(
1102
+ return /* @__PURE__ */ e(L, { label: t, required: r, error: n, className: f, children: /* @__PURE__ */ s("div", { ref: v, className: "relative", children: [
1103
+ /* @__PURE__ */ s(
1729
1104
  "button",
1730
1105
  {
1731
1106
  type: "button",
1732
- onClick: () => m((j) => !j),
1733
- className: b(
1107
+ onClick: () => d((x) => !x),
1108
+ className: h(
1734
1109
  "flex min-h-10 w-full flex-wrap items-center gap-1.5 rounded-md border bg-input px-2 py-1.5 text-left",
1735
1110
  "focus:outline-none focus:ring-2 focus:ring-accent/40",
1736
- s ? "border-status-offline" : "border-card-border"
1111
+ n ? "border-status-offline" : "border-card-border"
1737
1112
  ),
1738
1113
  children: [
1739
- i.length === 0 && /* @__PURE__ */ e.jsx("span", { className: "px-1 text-sm text-ink-muted", children: f }),
1740
- i.map((j) => {
1741
- const _ = a.find((C) => C.value === j);
1742
- return /* @__PURE__ */ e.jsxs(
1114
+ i.length === 0 && /* @__PURE__ */ e("span", { className: "px-1 text-sm text-ink-muted", children: l }),
1115
+ i.map((x) => {
1116
+ const w = a.find((y) => y.value === x);
1117
+ return /* @__PURE__ */ s(
1743
1118
  "span",
1744
1119
  {
1745
1120
  className: "inline-flex items-center gap-1 rounded bg-tag px-2 py-0.5 text-xs text-tag border border-tag-border",
1746
1121
  children: [
1747
- (_ == null ? void 0 : _.label) ?? j,
1748
- /* @__PURE__ */ e.jsx(
1749
- se,
1122
+ (w == null ? void 0 : w.label) ?? x,
1123
+ /* @__PURE__ */ e(
1124
+ D,
1750
1125
  {
1751
1126
  size: 12,
1752
1127
  className: "cursor-pointer hover:text-status-offline",
1753
- onClick: (C) => {
1754
- C.stopPropagation(), O(j);
1128
+ onClick: (y) => {
1129
+ y.stopPropagation(), N(x);
1755
1130
  }
1756
1131
  }
1757
1132
  )
1758
1133
  ]
1759
1134
  },
1760
- j
1135
+ x
1761
1136
  );
1762
1137
  }),
1763
- /* @__PURE__ */ e.jsx(tt, { size: 16, className: b("ml-auto shrink-0 text-ink-muted transition-transform", c && "rotate-180") })
1138
+ /* @__PURE__ */ e(Q, { size: 16, className: h("ml-auto shrink-0 text-ink-muted transition-transform", o && "rotate-180") })
1764
1139
  ]
1765
1140
  }
1766
1141
  ),
1767
- c && /* @__PURE__ */ e.jsxs("div", { className: "absolute z-20 mt-1 w-full overflow-hidden rounded-md border border-card-border bg-card shadow-lg", children: [
1768
- /* @__PURE__ */ e.jsxs("div", { className: "flex items-center gap-2 border-b border-card-border px-3 py-2", children: [
1769
- /* @__PURE__ */ e.jsx(he, { size: 14, className: "text-ink-muted" }),
1770
- /* @__PURE__ */ e.jsx(
1142
+ o && /* @__PURE__ */ s("div", { className: "absolute z-20 mt-1 w-full overflow-hidden rounded-md border border-card-border bg-card shadow-lg", children: [
1143
+ /* @__PURE__ */ s("div", { className: "flex items-center gap-2 border-b border-card-border px-3 py-2", children: [
1144
+ /* @__PURE__ */ e(P, { size: 14, className: "text-ink-muted" }),
1145
+ /* @__PURE__ */ e(
1771
1146
  "input",
1772
1147
  {
1773
1148
  autoFocus: !0,
1774
- value: d,
1775
- onChange: (j) => x(j.target.value),
1149
+ value: u,
1150
+ onChange: (x) => m(x.target.value),
1776
1151
  placeholder: "Search...",
1777
1152
  className: "w-full bg-transparent text-sm text-ink-primary placeholder:text-ink-muted focus:outline-none"
1778
1153
  }
1779
1154
  )
1780
1155
  ] }),
1781
- /* @__PURE__ */ e.jsxs("ul", { className: "max-h-56 overflow-y-auto py-1", role: "listbox", children: [
1782
- D.length === 0 && /* @__PURE__ */ e.jsx("li", { className: "px-3 py-2 text-sm text-ink-muted", children: "No options" }),
1783
- D.map((j) => /* @__PURE__ */ e.jsx("li", { children: /* @__PURE__ */ e.jsxs("label", { className: "flex w-full cursor-pointer items-center gap-2 px-3 py-2 text-sm hover:bg-accent-muted", children: [
1784
- /* @__PURE__ */ e.jsx(
1156
+ /* @__PURE__ */ s("ul", { className: "max-h-56 overflow-y-auto py-1", role: "listbox", children: [
1157
+ C.length === 0 && /* @__PURE__ */ e("li", { className: "px-3 py-2 text-sm text-ink-muted", children: "No options" }),
1158
+ C.map((x) => /* @__PURE__ */ e("li", { children: /* @__PURE__ */ s("label", { className: "flex w-full cursor-pointer items-center gap-2 px-3 py-2 text-sm hover:bg-accent-muted", children: [
1159
+ /* @__PURE__ */ e(
1785
1160
  "input",
1786
1161
  {
1787
1162
  type: "checkbox",
1788
- checked: i.includes(j.value),
1789
- onChange: () => O(j.value),
1163
+ checked: i.includes(x.value),
1164
+ onChange: () => N(x.value),
1790
1165
  className: "h-3.5 w-3.5 rounded border-card-border accent-[var(--accent-primary)]"
1791
1166
  }
1792
1167
  ),
1793
- /* @__PURE__ */ e.jsx("span", { className: "text-ink-primary", children: j.label })
1794
- ] }) }, j.value))
1168
+ /* @__PURE__ */ e("span", { className: "text-ink-primary", children: x.label })
1169
+ ] }) }, x.value))
1795
1170
  ] })
1796
1171
  ] })
1797
1172
  ] }) });
1798
1173
  }
1799
- function Lr({ page: n, pageSize: r, total: s, onPageChange: a, className: i }) {
1800
- const l = Math.max(1, Math.ceil(s / r)), f = s === 0 ? 0 : (n - 1) * r + 1, h = Math.min(s, n * r);
1801
- return /* @__PURE__ */ e.jsxs("nav", { className: b("flex items-center gap-2 text-sm text-ink-secondary", i), "aria-label": "Pagination", children: [
1802
- /* @__PURE__ */ e.jsx(
1174
+ function it({ page: t, pageSize: r, total: n, onPageChange: a, className: i }) {
1175
+ const c = Math.max(1, Math.ceil(n / r)), l = n === 0 ? 0 : (t - 1) * r + 1, f = Math.min(n, t * r);
1176
+ return /* @__PURE__ */ s("nav", { className: h("flex items-center gap-2 text-sm text-ink-secondary", i), "aria-label": "Pagination", children: [
1177
+ /* @__PURE__ */ e(
1803
1178
  "button",
1804
1179
  {
1805
- onClick: () => a(Math.max(1, n - 1)),
1806
- disabled: n === 1,
1180
+ onClick: () => a(Math.max(1, t - 1)),
1181
+ disabled: t === 1,
1807
1182
  "aria-label": "Previous page",
1808
1183
  className: "flex h-7 w-7 items-center justify-center rounded text-ink-secondary hover:bg-accent-muted disabled:opacity-40",
1809
- children: /* @__PURE__ */ e.jsx(rt, { size: 16 })
1184
+ children: /* @__PURE__ */ e(Z, { size: 16 })
1810
1185
  }
1811
1186
  ),
1812
- /* @__PURE__ */ e.jsxs("span", { children: [
1813
- f,
1187
+ /* @__PURE__ */ s("span", { children: [
1188
+ l,
1814
1189
  "-",
1815
- h,
1190
+ f,
1816
1191
  " of ",
1817
- s
1192
+ n
1818
1193
  ] }),
1819
- /* @__PURE__ */ e.jsx(
1194
+ /* @__PURE__ */ e(
1820
1195
  "button",
1821
1196
  {
1822
- onClick: () => a(Math.min(l, n + 1)),
1823
- disabled: n >= l,
1197
+ onClick: () => a(Math.min(c, t + 1)),
1198
+ disabled: t >= c,
1824
1199
  "aria-label": "Next page",
1825
1200
  className: "flex h-7 w-7 items-center justify-center rounded text-ink-secondary hover:bg-accent-muted disabled:opacity-40",
1826
- children: /* @__PURE__ */ e.jsx(nt, { size: 16 })
1201
+ children: /* @__PURE__ */ e(J, { size: 16 })
1827
1202
  }
1828
1203
  )
1829
1204
  ] });
1830
1205
  }
1831
- function Fr({ title: n, actions: r, className: s, children: a, ...i }) {
1832
- return /* @__PURE__ */ e.jsxs("div", { className: b("rounded-lg border border-card-border bg-card", s), ...i, children: [
1833
- /* @__PURE__ */ e.jsxs("div", { className: "flex items-center justify-between border-b border-card-border px-4 py-3", children: [
1834
- /* @__PURE__ */ e.jsx("h3", { className: "font-secondary text-sm font-semibold text-ink-primary", children: n }),
1835
- r && /* @__PURE__ */ e.jsx("div", { className: "flex items-center gap-2", children: r })
1206
+ function st({ title: t, actions: r, className: n, children: a, ...i }) {
1207
+ return /* @__PURE__ */ s("div", { className: h("rounded-lg border border-card-border bg-card", n), ...i, children: [
1208
+ /* @__PURE__ */ s("div", { className: "flex items-center justify-between border-b border-card-border px-4 py-3", children: [
1209
+ /* @__PURE__ */ e("h3", { className: "font-secondary text-sm font-semibold text-ink-primary", children: t }),
1210
+ r && /* @__PURE__ */ e("div", { className: "flex items-center gap-2", children: r })
1836
1211
  ] }),
1837
- /* @__PURE__ */ e.jsx("div", { className: "p-4", children: a })
1212
+ /* @__PURE__ */ e("div", { className: "p-4", children: a })
1838
1213
  ] });
1839
1214
  }
1840
- const vr = v.forwardRef(
1841
- ({ label: n, required: r, error: s, hint: a, id: i, className: l, ...f }, h) => {
1842
- const [c, m] = v.useState(!1), d = i ?? v.useId();
1843
- return /* @__PURE__ */ e.jsx(U, { label: n, htmlFor: d, required: r, error: s, hint: a, children: /* @__PURE__ */ e.jsxs("div", { className: "relative", children: [
1844
- /* @__PURE__ */ e.jsx(
1215
+ const Ee = b.forwardRef(
1216
+ ({ label: t, required: r, error: n, hint: a, id: i, className: c, ...l }, f) => {
1217
+ const [o, d] = b.useState(!1), u = i ?? b.useId();
1218
+ return /* @__PURE__ */ e(L, { label: t, htmlFor: u, required: r, error: n, hint: a, children: /* @__PURE__ */ s("div", { className: "relative", children: [
1219
+ /* @__PURE__ */ e(
1845
1220
  "input",
1846
1221
  {
1847
- ref: h,
1848
- id: d,
1849
- type: c ? "text" : "password",
1850
- className: b(
1222
+ ref: f,
1223
+ id: u,
1224
+ type: o ? "text" : "password",
1225
+ className: h(
1851
1226
  "h-10 w-full rounded-md border bg-input pl-3 pr-10 text-sm text-ink-primary placeholder:text-ink-muted",
1852
1227
  "focus:outline-none focus:ring-2 focus:ring-accent/40",
1853
- s ? "border-status-offline" : "border-card-border",
1854
- l
1228
+ n ? "border-status-offline" : "border-card-border",
1229
+ c
1855
1230
  ),
1856
- "aria-invalid": !!s,
1857
- ...f
1231
+ "aria-invalid": !!n,
1232
+ ...l
1858
1233
  }
1859
1234
  ),
1860
- /* @__PURE__ */ e.jsx(
1235
+ /* @__PURE__ */ e(
1861
1236
  "button",
1862
1237
  {
1863
1238
  type: "button",
1864
- onClick: () => m((x) => !x),
1865
- "aria-label": c ? "Hide password" : "Show password",
1239
+ onClick: () => d((m) => !m),
1240
+ "aria-label": o ? "Hide password" : "Show password",
1866
1241
  className: "absolute right-3 top-1/2 -translate-y-1/2 text-ink-muted hover:text-ink-primary",
1867
- children: c ? /* @__PURE__ */ e.jsx(tr, { size: 16 }) : /* @__PURE__ */ e.jsx(rr, { size: 16 })
1242
+ children: o ? /* @__PURE__ */ e(ve, { size: 16 }) : /* @__PURE__ */ e(ye, { size: 16 })
1868
1243
  }
1869
1244
  )
1870
1245
  ] }) });
1871
1246
  }
1872
1247
  );
1873
- vr.displayName = "PasswordInput";
1874
- function gr(n) {
1248
+ Ee.displayName = "PasswordInput";
1249
+ function Re(t) {
1875
1250
  let r = 0;
1876
- return n.length >= 8 && r++, n.length >= 12 && r++, /[A-Z]/.test(n) && /[a-z]/.test(n) && r++, /\d/.test(n) && r++, /[^A-Za-z0-9]/.test(n) && r++, r <= 1 ? { score: r, label: "Weak", tone: "bg-status-offline" } : r <= 3 ? { score: r, label: "Medium", tone: "bg-status-warn" } : { score: r, label: "Strong", tone: "bg-status-online" };
1251
+ return t.length >= 8 && r++, t.length >= 12 && r++, /[A-Z]/.test(t) && /[a-z]/.test(t) && r++, /\d/.test(t) && r++, /[^A-Za-z0-9]/.test(t) && r++, r <= 1 ? { score: r, label: "Weak", tone: "bg-status-offline" } : r <= 3 ? { score: r, label: "Medium", tone: "bg-status-warn" } : { score: r, label: "Strong", tone: "bg-status-online" };
1877
1252
  }
1878
- function Ir({ password: n, className: r }) {
1879
- const { score: s, label: a, tone: i } = gr(n), l = Math.min(s / 5 * 100, 100);
1880
- return n ? /* @__PURE__ */ e.jsxs("div", { className: b("mt-2", r), children: [
1881
- /* @__PURE__ */ e.jsx("div", { className: "h-1.5 w-full overflow-hidden rounded-full bg-card-border", children: /* @__PURE__ */ e.jsx("div", { className: b("h-full rounded-full transition-all duration-200", i), style: { width: `${l}%` } }) }),
1882
- /* @__PURE__ */ e.jsxs("p", { className: "mt-1 text-xs text-ink-secondary", children: [
1253
+ function ct({ password: t, className: r }) {
1254
+ const { score: n, label: a, tone: i } = Re(t), c = Math.min(n / 5 * 100, 100);
1255
+ return t ? /* @__PURE__ */ s("div", { className: h("mt-2", r), children: [
1256
+ /* @__PURE__ */ e("div", { className: "h-1.5 w-full overflow-hidden rounded-full bg-card-border", children: /* @__PURE__ */ e("div", { className: h("h-full rounded-full transition-all duration-200", i), style: { width: `${c}%` } }) }),
1257
+ /* @__PURE__ */ s("p", { className: "mt-1 text-xs text-ink-secondary", children: [
1883
1258
  "Strength: ",
1884
1259
  a
1885
1260
  ] })
1886
1261
  ] }) : null;
1887
1262
  }
1888
- const yr = v.forwardRef(
1889
- ({ value: n, onChange: r, onFilterClick: s, placeholder: a = "Search Data", className: i, ...l }, f) => /* @__PURE__ */ e.jsxs(
1263
+ const Fe = b.forwardRef(
1264
+ ({ value: t, onChange: r, onFilterClick: n, placeholder: a = "Search Data", className: i, ...c }, l) => /* @__PURE__ */ s(
1890
1265
  "div",
1891
1266
  {
1892
- className: b(
1267
+ className: h(
1893
1268
  "flex h-10 w-full items-center gap-2 rounded-md border border-card-border bg-input px-3",
1894
1269
  "focus-within:ring-2 focus-within:ring-accent/40",
1895
1270
  i
1896
1271
  ),
1897
1272
  children: [
1898
- /* @__PURE__ */ e.jsx(he, { size: 16, className: "shrink-0 text-ink-muted" }),
1899
- /* @__PURE__ */ e.jsx(
1273
+ /* @__PURE__ */ e(P, { size: 16, className: "shrink-0 text-ink-muted" }),
1274
+ /* @__PURE__ */ e(
1900
1275
  "input",
1901
1276
  {
1902
- ref: f,
1903
- value: n,
1904
- onChange: (h) => r(h.target.value),
1277
+ ref: l,
1278
+ value: t,
1279
+ onChange: (f) => r(f.target.value),
1905
1280
  placeholder: a,
1906
1281
  className: "w-full bg-transparent text-sm text-ink-primary placeholder:text-ink-muted focus:outline-none",
1907
- ...l
1282
+ ...c
1908
1283
  }
1909
1284
  ),
1910
- n && /* @__PURE__ */ e.jsx("button", { type: "button", "aria-label": "Clear search", onClick: () => r(""), className: "text-ink-muted hover:text-ink-primary", children: /* @__PURE__ */ e.jsx(se, { size: 14 }) }),
1911
- s && /* @__PURE__ */ e.jsx("button", { type: "button", "aria-label": "Filters", onClick: s, className: "text-ink-muted hover:text-accent", children: /* @__PURE__ */ e.jsx(at, { size: 16 }) })
1285
+ t && /* @__PURE__ */ e("button", { type: "button", "aria-label": "Clear search", onClick: () => r(""), className: "text-ink-muted hover:text-ink-primary", children: /* @__PURE__ */ e(D, { size: 14 }) }),
1286
+ n && /* @__PURE__ */ e("button", { type: "button", "aria-label": "Filters", onClick: n, className: "text-ink-muted hover:text-accent", children: /* @__PURE__ */ e(K, { size: 16 }) })
1912
1287
  ]
1913
1288
  }
1914
1289
  )
1915
1290
  );
1916
- yr.displayName = "SearchBox";
1917
- function jr({ open: n, onClose: r, title: s, width: a = "480px", children: i, className: l }) {
1918
- return v.useEffect(() => {
1919
- if (!n) return;
1920
- function f(h) {
1921
- h.key === "Escape" && r();
1922
- }
1923
- return document.addEventListener("keydown", f), () => document.removeEventListener("keydown", f);
1924
- }, [n, r]), n ? Xe(
1925
- /* @__PURE__ */ e.jsxs("div", { className: "fixed inset-0 z-50", children: [
1926
- /* @__PURE__ */ e.jsx("div", { className: "absolute inset-0 bg-black/50", onClick: r, "aria-hidden": !0 }),
1927
- /* @__PURE__ */ e.jsxs(
1291
+ Fe.displayName = "SearchBox";
1292
+ function Ie({ open: t, onClose: r, title: n, width: a = "480px", children: i, className: c }) {
1293
+ return b.useEffect(() => {
1294
+ if (!t) return;
1295
+ function l(f) {
1296
+ f.key === "Escape" && r();
1297
+ }
1298
+ return document.addEventListener("keydown", l), () => document.removeEventListener("keydown", l);
1299
+ }, [t, r]), t ? H(
1300
+ /* @__PURE__ */ s("div", { className: "fixed inset-0 z-50", children: [
1301
+ /* @__PURE__ */ e("div", { className: "absolute inset-0 bg-black/50", onClick: r, "aria-hidden": !0 }),
1302
+ /* @__PURE__ */ s(
1928
1303
  "div",
1929
1304
  {
1930
1305
  role: "dialog",
1931
1306
  "aria-modal": "true",
1932
1307
  style: { width: a },
1933
- className: b(
1308
+ className: h(
1934
1309
  "absolute right-0 top-0 flex h-full max-w-full flex-col border-l border-card-border bg-card shadow-xl",
1935
- l
1310
+ c
1936
1311
  ),
1937
1312
  children: [
1938
- s && /* @__PURE__ */ e.jsxs("div", { className: "flex items-center justify-between border-b border-card-border px-5 py-4", children: [
1939
- /* @__PURE__ */ e.jsx("h2", { className: "font-secondary text-base font-semibold text-ink-primary", children: s }),
1940
- /* @__PURE__ */ e.jsx("button", { onClick: r, "aria-label": "Close", className: "text-ink-muted hover:text-ink-primary", children: /* @__PURE__ */ e.jsx(se, { size: 18 }) })
1313
+ n && /* @__PURE__ */ s("div", { className: "flex items-center justify-between border-b border-card-border px-5 py-4", children: [
1314
+ /* @__PURE__ */ e("h2", { className: "font-secondary text-base font-semibold text-ink-primary", children: n }),
1315
+ /* @__PURE__ */ e("button", { onClick: r, "aria-label": "Close", className: "text-ink-muted hover:text-ink-primary", children: /* @__PURE__ */ e(D, { size: 18 }) })
1941
1316
  ] }),
1942
- /* @__PURE__ */ e.jsx("div", { className: "flex-1 overflow-y-auto px-5 py-4", children: i })
1317
+ /* @__PURE__ */ e("div", { className: "flex-1 overflow-y-auto px-5 py-4", children: i })
1943
1318
  ]
1944
1319
  }
1945
1320
  )
@@ -1947,24 +1322,24 @@ function jr({ open: n, onClose: r, title: s, width: a = "480px", children: i, cl
1947
1322
  document.body
1948
1323
  ) : null;
1949
1324
  }
1950
- function $r({ start: n, end: r, className: s, ...a }) {
1951
- return /* @__PURE__ */ e.jsxs("div", { className: b("flex flex-wrap items-center justify-between gap-3 py-2", s), ...a, children: [
1952
- /* @__PURE__ */ e.jsx("div", { className: "flex flex-1 items-center gap-2", children: n }),
1953
- /* @__PURE__ */ e.jsx("div", { className: "flex items-center gap-1.5", children: r })
1325
+ function lt({ start: t, end: r, className: n, ...a }) {
1326
+ return /* @__PURE__ */ s("div", { className: h("flex flex-wrap items-center justify-between gap-3 py-2", n), ...a, children: [
1327
+ /* @__PURE__ */ e("div", { className: "flex flex-1 items-center gap-2", children: t }),
1328
+ /* @__PURE__ */ e("div", { className: "flex items-center gap-1.5", children: r })
1954
1329
  ] });
1955
1330
  }
1956
- function kr({ items: n, value: r, onChange: s, className: a }) {
1957
- return /* @__PURE__ */ e.jsx("div", { role: "tablist", className: b("flex items-center gap-1 border-b border-card-border", a), children: n.map((i) => {
1958
- const l = i.value === r;
1959
- return /* @__PURE__ */ e.jsxs(
1331
+ function qe({ items: t, value: r, onChange: n, className: a }) {
1332
+ return /* @__PURE__ */ e("div", { role: "tablist", className: h("flex items-center gap-1 border-b border-card-border", a), children: t.map((i) => {
1333
+ const c = i.value === r;
1334
+ return /* @__PURE__ */ s(
1960
1335
  "button",
1961
1336
  {
1962
1337
  role: "tab",
1963
- "aria-selected": l,
1964
- onClick: () => s(i.value),
1965
- className: b(
1338
+ "aria-selected": c,
1339
+ onClick: () => n(i.value),
1340
+ className: h(
1966
1341
  "flex items-center gap-1.5 border-b-2 px-4 py-2 text-sm font-medium transition-colors",
1967
- l ? "border-accent text-accent" : "border-transparent text-ink-secondary hover:text-ink-primary"
1342
+ c ? "border-accent text-accent" : "border-transparent text-ink-secondary hover:text-ink-primary"
1968
1343
  ),
1969
1344
  children: [
1970
1345
  i.icon,
@@ -1975,20 +1350,20 @@ function kr({ items: n, value: r, onChange: s, className: a }) {
1975
1350
  );
1976
1351
  }) });
1977
1352
  }
1978
- function Yr({ options: n, value: r, onChange: s, className: a }) {
1979
- return /* @__PURE__ */ e.jsx("div", { className: b("inline-flex overflow-hidden rounded-md border border-card-border", a), role: "tablist", children: n.map((i, l) => {
1980
- const f = i.value === r;
1981
- return /* @__PURE__ */ e.jsx(
1353
+ function ot({ options: t, value: r, onChange: n, className: a }) {
1354
+ return /* @__PURE__ */ e("div", { className: h("inline-flex overflow-hidden rounded-md border border-card-border", a), role: "tablist", children: t.map((i, c) => {
1355
+ const l = i.value === r;
1356
+ return /* @__PURE__ */ e(
1982
1357
  "button",
1983
1358
  {
1984
1359
  type: "button",
1985
1360
  role: "tab",
1986
- "aria-selected": f,
1987
- onClick: () => s(i.value),
1988
- className: b(
1361
+ "aria-selected": l,
1362
+ onClick: () => n(i.value),
1363
+ className: h(
1989
1364
  "h-9 px-4 text-sm font-medium transition-colors",
1990
- l === 0 ? "border-r border-card-border" : "",
1991
- f ? "bg-accent text-white" : "bg-input text-ink-secondary hover:bg-accent-muted"
1365
+ c === 0 ? "border-r border-card-border" : "",
1366
+ l ? "bg-accent text-white" : "bg-input text-ink-secondary hover:bg-accent-muted"
1992
1367
  ),
1993
1368
  children: i.label
1994
1369
  },
@@ -1996,82 +1371,82 @@ function Yr({ options: n, value: r, onChange: s, className: a }) {
1996
1371
  );
1997
1372
  }) });
1998
1373
  }
1999
- function Wr({ logo: n, children: r, className: s }) {
2000
- return /* @__PURE__ */ e.jsx("div", { className: b("flex min-h-screen items-center justify-center bg-canvas px-4", s), children: /* @__PURE__ */ e.jsxs("div", { className: "w-full max-w-md", children: [
2001
- n && /* @__PURE__ */ e.jsx("div", { className: "mb-8 flex justify-center", children: n }),
2002
- /* @__PURE__ */ e.jsx("div", { className: "rounded-lg border border-card-border bg-card p-8 shadow-lg", children: r })
1374
+ function dt({ logo: t, children: r, className: n }) {
1375
+ return /* @__PURE__ */ e("div", { className: h("flex min-h-screen items-center justify-center bg-canvas px-4", n), children: /* @__PURE__ */ s("div", { className: "w-full max-w-md", children: [
1376
+ t && /* @__PURE__ */ e("div", { className: "mb-8 flex justify-center", children: t }),
1377
+ /* @__PURE__ */ e("div", { className: "rounded-lg border border-card-border bg-card p-8 shadow-lg", children: r })
2003
1378
  ] }) });
2004
1379
  }
2005
- function Vr({ className: n, children: r, ...s }) {
2006
- return /* @__PURE__ */ e.jsx(
1380
+ function ut({ className: t, children: r, ...n }) {
1381
+ return /* @__PURE__ */ e(
2007
1382
  "footer",
2008
1383
  {
2009
- className: b("border-t border-card-border px-6 py-3 text-xs text-ink-muted", n),
2010
- ...s,
1384
+ className: h("border-t border-card-border px-6 py-3 text-xs text-ink-muted", t),
1385
+ ...n,
2011
1386
  children: r ?? `© ${(/* @__PURE__ */ new Date()).getFullYear()} SLS — Software License System`
2012
1387
  }
2013
1388
  );
2014
1389
  }
2015
- function qr({ title: n, search: r, profileMenu: s, actions: a, className: i }) {
2016
- return /* @__PURE__ */ e.jsxs(
1390
+ function ft({ title: t, search: r, profileMenu: n, actions: a, className: i }) {
1391
+ return /* @__PURE__ */ s(
2017
1392
  "header",
2018
1393
  {
2019
- className: b(
1394
+ className: h(
2020
1395
  "flex h-16 items-center justify-between gap-4 border-b border-topbar-border bg-chrome px-6",
2021
1396
  i
2022
1397
  ),
2023
1398
  children: [
2024
- /* @__PURE__ */ e.jsx("h1", { className: "font-secondary text-lg font-semibold text-ink-onchrome truncate", children: n }),
2025
- /* @__PURE__ */ e.jsxs("div", { className: "flex flex-1 items-center justify-end gap-4", children: [
2026
- r && /* @__PURE__ */ e.jsx("div", { className: "w-full max-w-sm", children: r }),
1399
+ /* @__PURE__ */ e("h1", { className: "font-secondary text-lg font-semibold text-ink-onchrome truncate", children: t }),
1400
+ /* @__PURE__ */ s("div", { className: "flex flex-1 items-center justify-end gap-4", children: [
1401
+ r && /* @__PURE__ */ e("div", { className: "w-full max-w-sm", children: r }),
2027
1402
  a,
2028
- s
1403
+ n
2029
1404
  ] })
2030
1405
  ]
2031
1406
  }
2032
1407
  );
2033
1408
  }
2034
- function Br({ sidebar: n, header: r, footer: s, children: a, className: i }) {
2035
- return /* @__PURE__ */ e.jsxs("div", { className: b("flex h-screen w-full overflow-hidden bg-canvas", i), children: [
2036
- n,
2037
- /* @__PURE__ */ e.jsxs("div", { className: "flex min-w-0 flex-1 flex-col", children: [
1409
+ function mt({ sidebar: t, header: r, footer: n, children: a, className: i }) {
1410
+ return /* @__PURE__ */ s("div", { className: h("flex h-screen w-full overflow-hidden bg-canvas", i), children: [
1411
+ t,
1412
+ /* @__PURE__ */ s("div", { className: "flex min-w-0 flex-1 flex-col", children: [
2038
1413
  r,
2039
- /* @__PURE__ */ e.jsx("main", { className: "flex-1 overflow-y-auto p-6", children: a }),
2040
- s
1414
+ /* @__PURE__ */ e("main", { className: "flex-1 overflow-y-auto p-6", children: a }),
1415
+ n
2041
1416
  ] })
2042
1417
  ] });
2043
1418
  }
2044
- function Ur({ name: n, role: r, avatarUrl: s, onSignOut: a, actions: i = [], className: l }) {
2045
- const [f, h] = v.useState(!1), c = v.useRef(null);
2046
- return v.useEffect(() => {
2047
- function m(d) {
2048
- c.current && !c.current.contains(d.target) && h(!1);
2049
- }
2050
- return document.addEventListener("mousedown", m), () => document.removeEventListener("mousedown", m);
2051
- }, []), /* @__PURE__ */ e.jsxs("div", { ref: c, className: b("relative", l), children: [
2052
- /* @__PURE__ */ e.jsx("button", { onClick: () => h((m) => !m), className: "flex items-center gap-2", "aria-label": "Open profile menu", children: s ? /* @__PURE__ */ e.jsx("img", { src: s, alt: "", className: "h-9 w-9 rounded-full object-cover" }) : /* @__PURE__ */ e.jsx("span", { className: "flex h-9 w-9 items-center justify-center rounded-full bg-accent-muted text-accent", children: /* @__PURE__ */ e.jsx(lr, { size: 16 }) }) }),
2053
- f && /* @__PURE__ */ e.jsxs("div", { className: "absolute right-0 z-30 mt-2 w-56 rounded-lg border border-card-border bg-card p-4 shadow-lg", children: [
2054
- /* @__PURE__ */ e.jsx("p", { className: "font-secondary text-sm font-semibold text-ink-primary", children: n }),
2055
- /* @__PURE__ */ e.jsx("p", { className: "text-xs text-ink-muted", children: r }),
2056
- i.length > 0 && /* @__PURE__ */ e.jsx("div", { className: "mt-3 flex flex-col gap-1 border-t border-card-border pt-3", children: i.map((m) => /* @__PURE__ */ e.jsxs(
1419
+ function ht({ name: t, role: r, avatarUrl: n, onSignOut: a, actions: i = [], className: c }) {
1420
+ const [l, f] = b.useState(!1), o = b.useRef(null);
1421
+ return b.useEffect(() => {
1422
+ function d(u) {
1423
+ o.current && !o.current.contains(u.target) && f(!1);
1424
+ }
1425
+ return document.addEventListener("mousedown", d), () => document.removeEventListener("mousedown", d);
1426
+ }, []), /* @__PURE__ */ s("div", { ref: o, className: h("relative", c), children: [
1427
+ /* @__PURE__ */ e("button", { onClick: () => f((d) => !d), className: "flex items-center gap-2", "aria-label": "Open profile menu", children: n ? /* @__PURE__ */ e("img", { src: n, alt: "", className: "h-9 w-9 rounded-full object-cover" }) : /* @__PURE__ */ e("span", { className: "flex h-9 w-9 items-center justify-center rounded-full bg-accent-muted text-accent", children: /* @__PURE__ */ e(Me, { size: 16 }) }) }),
1428
+ l && /* @__PURE__ */ s("div", { className: "absolute right-0 z-30 mt-2 w-56 rounded-lg border border-card-border bg-card p-4 shadow-lg", children: [
1429
+ /* @__PURE__ */ e("p", { className: "font-secondary text-sm font-semibold text-ink-primary", children: t }),
1430
+ /* @__PURE__ */ e("p", { className: "text-xs text-ink-muted", children: r }),
1431
+ i.length > 0 && /* @__PURE__ */ e("div", { className: "mt-3 flex flex-col gap-1 border-t border-card-border pt-3", children: i.map((d) => /* @__PURE__ */ s(
2057
1432
  "button",
2058
1433
  {
2059
- onClick: m.onClick,
1434
+ onClick: d.onClick,
2060
1435
  className: "flex items-center gap-2 rounded px-2 py-1.5 text-left text-sm text-ink-primary hover:bg-accent-muted",
2061
1436
  children: [
2062
- m.icon,
2063
- m.label
1437
+ d.icon,
1438
+ d.label
2064
1439
  ]
2065
1440
  },
2066
- m.label
1441
+ d.label
2067
1442
  )) }),
2068
- /* @__PURE__ */ e.jsxs(
1443
+ /* @__PURE__ */ s(
2069
1444
  "button",
2070
1445
  {
2071
1446
  onClick: a,
2072
1447
  className: "mt-2 flex w-full items-center gap-2 rounded px-2 py-1.5 text-left text-sm text-status-offline hover:bg-status-offline-bg",
2073
1448
  children: [
2074
- /* @__PURE__ */ e.jsx(sr, { size: 14 }),
1449
+ /* @__PURE__ */ e(we, { size: 14 }),
2075
1450
  "Sign out"
2076
1451
  ]
2077
1452
  }
@@ -2079,158 +1454,376 @@ function Ur({ name: n, role: r, avatarUrl: s, onSignOut: a, actions: i = [], cla
2079
1454
  ] })
2080
1455
  ] });
2081
1456
  }
2082
- function Hr({ items: n, collapsed: r, onCollapsedChange: s, logo: a, className: i }) {
2083
- return /* @__PURE__ */ e.jsxs(
1457
+ function bt({ items: t, collapsed: r, onCollapsedChange: n, logo: a, className: i }) {
1458
+ return /* @__PURE__ */ s(
2084
1459
  "aside",
2085
1460
  {
2086
- className: b(
1461
+ className: h(
2087
1462
  "flex h-full flex-col border-r border-sidebar-border bg-chrome-deep transition-all duration-200",
2088
1463
  r ? "w-16" : "w-56",
2089
1464
  i
2090
1465
  ),
2091
1466
  children: [
2092
- a && /* @__PURE__ */ e.jsx("div", { className: "flex h-16 items-center justify-center border-b border-sidebar-border", children: a }),
2093
- /* @__PURE__ */ e.jsx("nav", { className: "flex flex-1 flex-col gap-1 p-2", children: n.map((l) => /* @__PURE__ */ e.jsxs(
1467
+ a && /* @__PURE__ */ e("div", { className: "flex h-16 items-center justify-center border-b border-sidebar-border", children: a }),
1468
+ /* @__PURE__ */ e("nav", { className: "flex flex-1 flex-col gap-1 p-2", children: t.map((c) => /* @__PURE__ */ s(
2094
1469
  "button",
2095
1470
  {
2096
- onClick: l.onClick,
2097
- title: r ? l.label : void 0,
2098
- className: b(
1471
+ onClick: c.onClick,
1472
+ title: r ? c.label : void 0,
1473
+ className: h(
2099
1474
  "flex items-center gap-3 rounded-md px-3 py-2.5 text-sm font-medium transition-colors",
2100
- l.active ? "border-l-2 bg-nav-active-bg text-ink-onchrome" : "text-icon-idle hover:bg-nav-active-bg hover:text-icon-active"
1475
+ c.active ? "border-l-2 bg-nav-active-bg text-ink-onchrome" : "text-icon-idle hover:bg-nav-active-bg hover:text-icon-active"
2101
1476
  ),
2102
- style: l.active ? { borderColor: "var(--nav-active-border)" } : void 0,
1477
+ style: c.active ? { borderColor: "var(--nav-active-border)" } : void 0,
2103
1478
  children: [
2104
- /* @__PURE__ */ e.jsx("span", { className: "shrink-0", children: l.icon }),
2105
- !r && /* @__PURE__ */ e.jsx("span", { className: "truncate", children: l.label })
1479
+ /* @__PURE__ */ e("span", { className: "shrink-0", children: c.icon }),
1480
+ !r && /* @__PURE__ */ e("span", { className: "truncate", children: c.label })
2106
1481
  ]
2107
1482
  },
2108
- l.key
1483
+ c.key
2109
1484
  )) }),
2110
- s && /* @__PURE__ */ e.jsx(
1485
+ n && /* @__PURE__ */ e(
2111
1486
  "button",
2112
1487
  {
2113
- onClick: () => s(!r),
1488
+ onClick: () => n(!r),
2114
1489
  className: "flex items-center justify-center border-t border-sidebar-border py-3 text-icon-idle hover:text-icon-active",
2115
1490
  "aria-label": r ? "Expand sidebar" : "Collapse sidebar",
2116
- children: r ? /* @__PURE__ */ e.jsx(nt, { size: 16 }) : /* @__PURE__ */ e.jsx(rt, { size: 16 })
1491
+ children: r ? /* @__PURE__ */ e(J, { size: 16 }) : /* @__PURE__ */ e(Z, { size: 16 })
2117
1492
  }
2118
1493
  )
2119
1494
  ]
2120
1495
  }
2121
1496
  );
2122
1497
  }
2123
- function Jr({ onOpen: n, className: r }) {
2124
- function s() {
2125
- if (n) return n();
1498
+ function xt({ onOpen: t, className: r }) {
1499
+ function n() {
1500
+ if (t) return t();
2126
1501
  const a = window.open("", "_blank");
2127
1502
  a && a.document.write("<title>SLS License Agent</title><body style='font-family:sans-serif;padding:40px'><h2>SLS AI License Agent</h2><p>The agent would open here.</p></body>");
2128
1503
  }
2129
- return /* @__PURE__ */ e.jsx(
1504
+ return /* @__PURE__ */ e(
2130
1505
  "button",
2131
1506
  {
2132
- onClick: s,
1507
+ onClick: n,
2133
1508
  "aria-label": "Open AI license agent",
2134
1509
  title: "AI License Agent",
2135
- className: b(
1510
+ className: h(
2136
1511
  "fixed bottom-24 right-6 z-40 flex h-14 w-14 items-center justify-center rounded-full",
2137
1512
  "bg-accent-light text-white shadow-lg hover:brightness-110 active:scale-95 transition-all",
2138
1513
  r
2139
1514
  ),
2140
- children: /* @__PURE__ */ e.jsx(Xt, { size: 22 })
1515
+ children: /* @__PURE__ */ e(he, { size: 22 })
2141
1516
  }
2142
1517
  );
2143
1518
  }
2144
- function Gr({ title: n, loading: r, onReload: s, onExport: a, onFilter: i, children: l, className: f }) {
2145
- return /* @__PURE__ */ e.jsxs("div", { className: b("flex flex-col rounded-lg border border-card-border bg-card", f), children: [
2146
- /* @__PURE__ */ e.jsxs("div", { className: "flex items-center justify-between border-b border-card-border px-4 py-3", children: [
2147
- /* @__PURE__ */ e.jsx("h3", { className: "font-secondary text-sm font-semibold text-ink-primary", children: n }),
2148
- /* @__PURE__ */ e.jsxs("div", { className: "flex items-center gap-1", children: [
2149
- i && /* @__PURE__ */ e.jsx(B, { icon: /* @__PURE__ */ e.jsx(at, { size: 14 }), label: "Filter", size: "sm", onClick: i }),
2150
- s && /* @__PURE__ */ e.jsx(B, { icon: /* @__PURE__ */ e.jsx(ir, { size: 14 }), label: "Reload", size: "sm", onClick: s }),
2151
- a && /* @__PURE__ */ e.jsx(B, { icon: /* @__PURE__ */ e.jsx(er, { size: 14 }), label: "Export", size: "sm", onClick: a })
1519
+ function pt({ title: t, loading: r, onReload: n, onExport: a, onFilter: i, children: c, className: l }) {
1520
+ return /* @__PURE__ */ s("div", { className: h("flex flex-col rounded-lg border border-card-border bg-card", l), children: [
1521
+ /* @__PURE__ */ s("div", { className: "flex items-center justify-between border-b border-card-border px-4 py-3", children: [
1522
+ /* @__PURE__ */ e("h3", { className: "font-secondary text-sm font-semibold text-ink-primary", children: t }),
1523
+ /* @__PURE__ */ s("div", { className: "flex items-center gap-1", children: [
1524
+ i && /* @__PURE__ */ e(S, { icon: /* @__PURE__ */ e(K, { size: 14 }), label: "Filter", size: "sm", onClick: i }),
1525
+ n && /* @__PURE__ */ e(S, { icon: /* @__PURE__ */ e(Ce, { size: 14 }), label: "Reload", size: "sm", onClick: n }),
1526
+ a && /* @__PURE__ */ e(S, { icon: /* @__PURE__ */ e(ge, { size: 14 }), label: "Export", size: "sm", onClick: a })
2152
1527
  ] })
2153
1528
  ] }),
2154
- /* @__PURE__ */ e.jsx("div", { className: "p-4", children: r ? /* @__PURE__ */ e.jsx(it, { label: "Loading widget..." }) : l })
1529
+ /* @__PURE__ */ e("div", { className: "p-4", children: r ? /* @__PURE__ */ e(ee, { label: "Loading widget..." }) : c })
2155
1530
  ] });
2156
1531
  }
2157
- const wr = [
1532
+ const We = [
2158
1533
  { value: "pdf", label: "Invoice PDF" },
2159
1534
  { value: "excel", label: "Renewal Excel" }
2160
1535
  ];
2161
- function Xr({
2162
- open: n,
1536
+ function gt({
1537
+ open: t,
2163
1538
  onClose: r,
2164
- customerEmail: s,
1539
+ customerEmail: n,
2165
1540
  activeTab: a,
2166
1541
  onTabChange: i,
2167
- onSendEmail: l,
2168
- children: f
1542
+ onSendEmail: c,
1543
+ children: l
2169
1544
  }) {
2170
- return /* @__PURE__ */ e.jsx(jr, { open: n, onClose: r, title: "Invoice preview", width: "640px", children: /* @__PURE__ */ e.jsxs("div", { className: "flex flex-col gap-4", children: [
2171
- /* @__PURE__ */ e.jsx(kr, { items: wr, value: a, onChange: i }),
2172
- s && /* @__PURE__ */ e.jsxs("div", { className: "flex items-center justify-between rounded-md bg-accent-muted px-3 py-2 text-sm", children: [
2173
- /* @__PURE__ */ e.jsxs("span", { className: "flex items-center gap-2 text-ink-secondary", children: [
2174
- /* @__PURE__ */ e.jsx(ar, { size: 14 }),
2175
- s
1545
+ return /* @__PURE__ */ e(Ie, { open: t, onClose: r, title: "Invoice preview", width: "640px", children: /* @__PURE__ */ s("div", { className: "flex flex-col gap-4", children: [
1546
+ /* @__PURE__ */ e(qe, { items: We, value: a, onChange: i }),
1547
+ n && /* @__PURE__ */ s("div", { className: "flex items-center justify-between rounded-md bg-accent-muted px-3 py-2 text-sm", children: [
1548
+ /* @__PURE__ */ s("span", { className: "flex items-center gap-2 text-ink-secondary", children: [
1549
+ /* @__PURE__ */ e(Ne, { size: 14 }),
1550
+ n
2176
1551
  ] }),
2177
- l && /* @__PURE__ */ e.jsx(F, { size: "sm", variant: "secondary", onClick: l, children: "Send" })
1552
+ c && /* @__PURE__ */ e(B, { size: "sm", variant: "secondary", onClick: c, children: "Send" })
2178
1553
  ] }),
2179
- /* @__PURE__ */ e.jsx("div", { className: "min-h-[60vh]", children: f })
1554
+ /* @__PURE__ */ e("div", { className: "min-h-[60vh]", children: l })
2180
1555
  ] }) });
2181
1556
  }
2182
- function Zr({ open: n, onClose: r, title: s = "Changes", fields: a }) {
2183
- return /* @__PURE__ */ e.jsx(pe, { open: n, onClose: r, title: s, size: "md", children: /* @__PURE__ */ e.jsxs("div", { className: "grid grid-cols-3 gap-2 text-sm", children: [
2184
- /* @__PURE__ */ e.jsx("div", { className: "font-medium text-ink-secondary", children: "Field" }),
2185
- /* @__PURE__ */ e.jsx("div", { className: "font-medium text-ink-secondary", children: "Previous" }),
2186
- /* @__PURE__ */ e.jsx("div", { className: "font-medium text-ink-secondary", children: "Current" }),
2187
- a.map((i) => /* @__PURE__ */ e.jsxs(v.Fragment, { children: [
2188
- /* @__PURE__ */ e.jsx("div", { className: "text-ink-primary", children: i.label }),
2189
- /* @__PURE__ */ e.jsx("div", { className: "rounded bg-status-offline-bg px-2 py-1 text-status-offline", children: i.previous }),
2190
- /* @__PURE__ */ e.jsx("div", { className: "rounded bg-status-online-bg px-2 py-1 text-status-online", children: i.current })
1557
+ function vt({ open: t, onClose: r, title: n = "Changes", fields: a }) {
1558
+ return /* @__PURE__ */ e(R, { open: t, onClose: r, title: n, size: "md", children: /* @__PURE__ */ s("div", { className: "grid grid-cols-3 gap-2 text-sm", children: [
1559
+ /* @__PURE__ */ e("div", { className: "font-medium text-ink-secondary", children: "Field" }),
1560
+ /* @__PURE__ */ e("div", { className: "font-medium text-ink-secondary", children: "Previous" }),
1561
+ /* @__PURE__ */ e("div", { className: "font-medium text-ink-secondary", children: "Current" }),
1562
+ a.map((i) => /* @__PURE__ */ s(b.Fragment, { children: [
1563
+ /* @__PURE__ */ e("div", { className: "text-ink-primary", children: i.label }),
1564
+ /* @__PURE__ */ e("div", { className: "rounded bg-status-offline-bg px-2 py-1 text-status-offline", children: i.previous }),
1565
+ /* @__PURE__ */ e("div", { className: "rounded bg-status-online-bg px-2 py-1 text-status-online", children: i.current })
2191
1566
  ] }, i.label))
2192
1567
  ] }) });
2193
1568
  }
1569
+ const W = {
1570
+ chromeBg: "--chrome-bg",
1571
+ chromeDeep: "--chrome-deep",
1572
+ canvasBg: "--canvas-bg",
1573
+ cardBg: "--card-bg",
1574
+ cardBorder: "--card-border",
1575
+ accentPrimary: "--accent-primary",
1576
+ accentLight: "--accent-light",
1577
+ accentMutedBg: "--accent-muted-bg",
1578
+ accentBorder: "--accent-border",
1579
+ textPrimary: "--text-primary",
1580
+ textSecondary: "--text-secondary",
1581
+ textMuted: "--text-muted",
1582
+ textOnChrome: "--text-on-chrome",
1583
+ iconIdle: "--icon-idle",
1584
+ iconActive: "--icon-active",
1585
+ statusOnline: "--status-online",
1586
+ statusOnlineBg: "--status-online-bg",
1587
+ statusWarn: "--status-warn",
1588
+ statusWarnBg: "--status-warn-bg",
1589
+ statusOffline: "--status-offline",
1590
+ statusOfflineBg: "--status-offline-bg",
1591
+ liveBg: "--live-bg",
1592
+ liveText: "--live-text",
1593
+ sidebarBorder: "--sidebar-border",
1594
+ topbarBorder: "--topbar-border",
1595
+ navActiveBg: "--nav-active-bg",
1596
+ navActiveBorder: "--nav-active-border",
1597
+ tagBg: "--tag-bg",
1598
+ tagText: "--tag-text",
1599
+ tagBorder: "--tag-border",
1600
+ inputBg: "--input-bg"
1601
+ }, re = {
1602
+ "slate-navy": {
1603
+ label: "Theme 1 — Slate Navy",
1604
+ chromeBg: "#0d1b2e",
1605
+ chromeDeep: "#0a1626",
1606
+ canvasBg: "#f4f6f9",
1607
+ cardBg: "#ffffff",
1608
+ cardBorder: "#e2e8f0",
1609
+ accentPrimary: "#1d4ed8",
1610
+ accentLight: "#60a5fa",
1611
+ accentMutedBg: "#eff6ff",
1612
+ accentBorder: "#bfdbfe",
1613
+ textPrimary: "#0d1b2e",
1614
+ textSecondary: "#718096",
1615
+ textMuted: "#a0aec0",
1616
+ textOnChrome: "#e8edf5",
1617
+ iconIdle: "#4b7bab",
1618
+ iconActive: "#60a5fa",
1619
+ statusOnline: "#1a9b5a",
1620
+ statusOnlineBg: "#f0fdf4",
1621
+ statusWarn: "#e07b00",
1622
+ statusWarnBg: "#fffbeb",
1623
+ statusOffline: "#c53030",
1624
+ statusOfflineBg: "#fff5f5",
1625
+ liveBg: "#eff6ff",
1626
+ liveText: "#1d4ed8",
1627
+ barColors: ["#1d4ed8", "#3b82f6", "#60a5fa", "#93c5fd", "#bfdbfe", "#dbeafe", "#eff6ff"],
1628
+ sidebarBorder: "transparent",
1629
+ topbarBorder: "transparent",
1630
+ navActiveBg: "rgba(29,78,216,0.08)",
1631
+ navActiveBorder: "#1d4ed8",
1632
+ tagBg: "#eff6ff",
1633
+ tagText: "#1d4ed8",
1634
+ tagBorder: "#bfdbfe",
1635
+ inputBg: "#f4f6f9"
1636
+ },
1637
+ "arctic-white": {
1638
+ label: "Theme 2 — Arctic White",
1639
+ chromeBg: "#ffffff",
1640
+ chromeDeep: "#f8fafc",
1641
+ canvasBg: "#f1f5f9",
1642
+ cardBg: "#ffffff",
1643
+ cardBorder: "#e2e8f0",
1644
+ accentPrimary: "#2563eb",
1645
+ accentLight: "#3b82f6",
1646
+ accentMutedBg: "#eff6ff",
1647
+ accentBorder: "#bfdbfe",
1648
+ textPrimary: "#0f172a",
1649
+ textSecondary: "#64748b",
1650
+ textMuted: "#94a3b8",
1651
+ textOnChrome: "#0f172a",
1652
+ iconIdle: "#94a3b8",
1653
+ iconActive: "#2563eb",
1654
+ statusOnline: "#15803d",
1655
+ statusOnlineBg: "#f0fdf4",
1656
+ statusWarn: "#b45309",
1657
+ statusWarnBg: "#fffbeb",
1658
+ statusOffline: "#b91c1c",
1659
+ statusOfflineBg: "#fef2f2",
1660
+ liveBg: "#f0fdf4",
1661
+ liveText: "#15803d",
1662
+ barColors: ["#0ea5e9", "#38bdf8", "#7dd3fc", "#bae6fd", "#e0f2fe", "#f0f9ff", "#f8fafc"],
1663
+ sidebarBorder: "#e2e8f0",
1664
+ topbarBorder: "#e5e7eb",
1665
+ navActiveBg: "#eff6ff",
1666
+ navActiveBorder: "#2563eb",
1667
+ tagBg: "#eff6ff",
1668
+ tagText: "#2563eb",
1669
+ tagBorder: "#bfdbfe",
1670
+ inputBg: "#f8fafc"
1671
+ },
1672
+ "carbon-pro": {
1673
+ label: "Theme 3 — Carbon Pro",
1674
+ chromeBg: "#161b22",
1675
+ chromeDeep: "#0d1117",
1676
+ canvasBg: "#1c2128",
1677
+ cardBg: "#21262d",
1678
+ cardBorder: "#30363d",
1679
+ accentPrimary: "#58a6ff",
1680
+ accentLight: "#79c0ff",
1681
+ accentMutedBg: "#0d2a1f",
1682
+ accentBorder: "#30363d",
1683
+ textPrimary: "#e6edf3",
1684
+ textSecondary: "#c9d1d9",
1685
+ textMuted: "#8b949e",
1686
+ textOnChrome: "#e6edf3",
1687
+ iconIdle: "#484f58",
1688
+ iconActive: "#58a6ff",
1689
+ statusOnline: "#34d399",
1690
+ statusOnlineBg: "#0d2a1f",
1691
+ statusWarn: "#fbbf24",
1692
+ statusWarnBg: "#1f1a00",
1693
+ statusOffline: "#f87171",
1694
+ statusOfflineBg: "#1f0a0a",
1695
+ liveBg: "#0d2a1f",
1696
+ liveText: "#34d399",
1697
+ barColors: ["#58a6ff", "#388bfd", "#1f6feb", "#0d419d", "#0a2d6e", "#071e4a", "#040f2b"],
1698
+ sidebarBorder: "#21262d",
1699
+ topbarBorder: "#30363d",
1700
+ navActiveBg: "rgba(88,166,255,0.08)",
1701
+ navActiveBorder: "#58a6ff",
1702
+ tagBg: "#21262d",
1703
+ tagText: "#58a6ff",
1704
+ tagBorder: "#30363d",
1705
+ inputBg: "#21262d"
1706
+ },
1707
+ "narnix-edge": {
1708
+ label: "Theme 4 — Narnix Edge",
1709
+ chromeBg: "#061828",
1710
+ chromeDeep: "#040f1a",
1711
+ canvasBg: "#0b1e30",
1712
+ cardBg: "#112035",
1713
+ cardBorder: "#1e3a55",
1714
+ accentPrimary: "#00c9a7",
1715
+ accentLight: "#00ddb8",
1716
+ accentMutedBg: "#0a2240",
1717
+ accentBorder: "#1e3a55",
1718
+ textPrimary: "#daeaf8",
1719
+ textSecondary: "#a8c4d9",
1720
+ textMuted: "#4a7fa5",
1721
+ textOnChrome: "#daeaf8",
1722
+ iconIdle: "#2e5470",
1723
+ iconActive: "#00c9a7",
1724
+ statusOnline: "#00c9a7",
1725
+ statusOnlineBg: "#072219",
1726
+ statusWarn: "#f5a623",
1727
+ statusWarnBg: "#1e1200",
1728
+ statusOffline: "#e05252",
1729
+ statusOfflineBg: "#1a0808",
1730
+ liveBg: "#072219",
1731
+ liveText: "#00c9a7",
1732
+ barColors: ["#00ddb8", "#00c9a7", "#00b898", "#00a88a", "#018870", "#016a55", "#015a4a"],
1733
+ sidebarBorder: "#0e2236",
1734
+ topbarBorder: "#0e2236",
1735
+ navActiveBg: "rgba(0,201,167,0.08)",
1736
+ navActiveBorder: "#00c9a7",
1737
+ tagBg: "#0a2240",
1738
+ tagText: "#4a9ecf",
1739
+ tagBorder: "#1e3a55",
1740
+ inputBg: "#0b1e30"
1741
+ }
1742
+ }, $e = "narnix-edge", ne = b.createContext(null);
1743
+ function Ye(t, r) {
1744
+ const n = re[r];
1745
+ Object.keys(W).forEach((a) => {
1746
+ t.style.setProperty(W[a], n[a]);
1747
+ }), n.barColors.forEach((a, i) => {
1748
+ t.style.setProperty(`--bar-color-${i}`, a);
1749
+ }), t.dataset.theme = r;
1750
+ }
1751
+ function yt({ theme: t, onThemeChange: r, children: n }) {
1752
+ const [a, i] = b.useState(t ?? $e), c = t ?? a, l = b.useRef(null);
1753
+ b.useEffect(() => {
1754
+ l.current && Ye(l.current, c);
1755
+ }, [c]);
1756
+ const f = b.useCallback(
1757
+ (d) => {
1758
+ i(d), r == null || r(d);
1759
+ },
1760
+ [r]
1761
+ ), o = b.useMemo(() => ({ theme: c, setTheme: f, themes: re }), [c, f]);
1762
+ return /* @__PURE__ */ e(ne.Provider, { value: o, children: /* @__PURE__ */ e("div", { ref: l, "data-sls-theme-root": !0, children: n }) });
1763
+ }
1764
+ function He() {
1765
+ const t = b.useContext(ne);
1766
+ if (!t) throw new Error("useTheme must be used inside <ThemeProvider>");
1767
+ return t;
1768
+ }
1769
+ function kt({ className: t }) {
1770
+ const { theme: r, setTheme: n, themes: a } = He();
1771
+ return /* @__PURE__ */ e(
1772
+ "select",
1773
+ {
1774
+ value: r,
1775
+ onChange: (i) => n(i.target.value),
1776
+ className: h(
1777
+ "rounded-md border border-card-border bg-input px-3 py-1.5 text-sm text-ink-primary",
1778
+ "focus:outline-none focus:ring-2 focus:ring-accent/40",
1779
+ t
1780
+ ),
1781
+ children: Object.keys(a).map((i) => /* @__PURE__ */ e("option", { value: i, children: a[i].label }, i))
1782
+ }
1783
+ );
1784
+ }
2194
1785
  export {
2195
- Wr as AuthLayout,
2196
- Rr as Badge,
2197
- F as Button,
2198
- qt as Card,
2199
- Zr as ChangesPreviewModal,
2200
- be as Checkbox,
2201
- Er as ColumnFilterDropdown,
2202
- Sr as ConfirmDialog,
2203
- _r as DataTable,
2204
- Tr as DatePicker,
2205
- Mr as DateRangePicker,
2206
- Pr as Dropdown,
2207
- Or as DynamicRowList,
2208
- Dr as FilterPanel,
2209
- br as FloatingAddButton,
2210
- Vr as Footer,
2211
- U as FormGroup,
2212
- zr as FormModal,
2213
- qr as Header,
2214
- B as IconButton,
2215
- pr as InputField,
2216
- Xr as InvoicePreviewModal,
2217
- Jr as LicenseAgentButton,
2218
- it as Loader,
2219
- Br as MainLayout,
2220
- pe as Modal,
2221
- Ar as MultiSelectDropdown,
2222
- Lr as Pagination,
2223
- Fr as Panel,
2224
- vr as PasswordInput,
2225
- Ir as PasswordStrengthMeter,
2226
- Ur as ProfileMenu,
2227
- Gr as ReportWidget,
2228
- Ue as RowSelectCheckbox,
2229
- yr as SearchBox,
2230
- Hr as Sidebar,
2231
- jr as SlideOverModal,
2232
- $r as TableToolbar,
2233
- kr as Tabs,
2234
- Yr as ToggleButtonGroup,
2235
- fr as ValidationMessage
1786
+ dt as AuthLayout,
1787
+ _e as Badge,
1788
+ B as Button,
1789
+ le as Card,
1790
+ vt as ChangesPreviewModal,
1791
+ E as Checkbox,
1792
+ Qe as ColumnFilterDropdown,
1793
+ Ze as ConfirmDialog,
1794
+ Je as DataTable,
1795
+ Xe as DatePicker,
1796
+ Ke as DateRangePicker,
1797
+ et as Dropdown,
1798
+ tt as DynamicRowList,
1799
+ rt as FilterPanel,
1800
+ Oe as FloatingAddButton,
1801
+ ut as Footer,
1802
+ L as FormGroup,
1803
+ nt as FormModal,
1804
+ ft as Header,
1805
+ S as IconButton,
1806
+ Pe as InputField,
1807
+ gt as InvoicePreviewModal,
1808
+ xt as LicenseAgentButton,
1809
+ ee as Loader,
1810
+ mt as MainLayout,
1811
+ R as Modal,
1812
+ at as MultiSelectDropdown,
1813
+ it as Pagination,
1814
+ st as Panel,
1815
+ Ee as PasswordInput,
1816
+ ct as PasswordStrengthMeter,
1817
+ ht as ProfileMenu,
1818
+ pt as ReportWidget,
1819
+ I as RowSelectCheckbox,
1820
+ Fe as SearchBox,
1821
+ bt as Sidebar,
1822
+ Ie as SlideOverModal,
1823
+ lt as TableToolbar,
1824
+ qe as Tabs,
1825
+ yt as ThemeProvider,
1826
+ kt as ThemeSwitcher,
1827
+ ot as ToggleButtonGroup,
1828
+ Ae as ValidationMessage
2236
1829
  };