@base-framework/ui 1.0.307 → 1.0.308
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/index.es.js
CHANGED
|
@@ -5,7 +5,7 @@ import { C as F, d as B, D as P, c as k, E as M, F as v, H as x, I as N, M as f,
|
|
|
5
5
|
import { Icons as G } from "./icons.es.js";
|
|
6
6
|
import { A as E, B as V, C as j, w as q, J, y as z, z as K, E as Q, G as _, D as X, m as Y, n as Z, O as $, K as aa, v as ea, c as sa, a as oa, b as ta, Q as ra, l as na, g as ia, i as la, h as pa, j as da, e as ua, k as ma, F as ga, d as Ca, f as ca, L as Ta, x as ba, M as Da, o as Ia, N as Sa, P as Fa, s as Ba, t as Pa, S as ka, q as Ma, r as va, T as xa, H as Na, I as fa, p as ya, u as ha } from "./empty-state-vu_Mhyk4.js";
|
|
7
7
|
import { A as Ua, b as Wa, C as Ha, D as wa, a as Aa, F as Ra, M as Ga, P as Oa, R as Ea, c as Va, g as ja, p as qa } from "./range-calendar-CnBylqhu.js";
|
|
8
|
-
import { B as za, p as Ka, C as Qa, j as _a, D as Xa, m as Ya, k as Za, H as $a, I as ae, N as ee, O as se, P as oe, S as te, n as re, o as ne, x as ie, s as le, q as pe, r as de, T as ue, t as me, w as ge, u as Ce, v as ce, l as Te, U as be, W as De, f as Ie, h as Se, i as Fe, c as Be, d as Pe, b as ke, e as Me, a as ve, g as xe } from "./signature-panel-
|
|
8
|
+
import { B as za, p as Ka, C as Qa, j as _a, D as Xa, m as Ya, k as Za, H as $a, I as ae, N as ee, O as se, P as oe, S as te, n as re, o as ne, x as ie, s as le, q as pe, r as de, T as ue, t as me, w as ge, u as Ce, v as ce, l as Te, U as be, W as De, f as Ie, h as Se, i as Fe, c as Be, d as Pe, b as ke, e as Me, a as ve, g as xe } from "./signature-panel-CEQCcUUN.js";
|
|
9
9
|
import { B as fe, I as ye, M as he, d as Le, e as Ue, g as We, N as He, b as we, a as Ae, f as Re, P as Ge, c as Oe, S as Ee, T as Ve } from "./mobile-nav-wrapper-CWqhZ0qz.js";
|
|
10
10
|
import { B as qe, a as Je, C as ze, F as Ke, b as Qe, c as _e, M as Xe, P as Ye, S as Ze } from "./sidebar-menu-page-UmKsAvjb.js";
|
|
11
11
|
import { A as as, F as es, M as ss, a as os, T as ts } from "./aside-template-sUm-F2f0.js";
|
package/dist/organisms.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { B as s, p as n, C as t, j as o, D as r, m as l, k as i, H as d, I as b, N as u, O as v, P as g, S as p, n as T, o as D, x as N, s as k, q as C, r as c, T as B, t as M, w as m, u as y, v as W, l as h, U as S, W as H, f as P, h as U, i as x, c as I, d as f, b as L, e as O, a as F, g as G } from "./signature-panel-
|
|
1
|
+
import { B as s, p as n, C as t, j as o, D as r, m as l, k as i, H as d, I as b, N as u, O as v, P as g, S as p, n as T, o as D, x as N, s as k, q as C, r as c, T as B, t as M, w as m, u as y, v as W, l as h, U as S, W as H, f as P, h as U, i as x, c as I, d as f, b as L, e as O, a as F, g as G } from "./signature-panel-CEQCcUUN.js";
|
|
2
2
|
import { b as R, C as j, D as q, a as z, F as A, M as E, R as J, c as K, p as Q } from "./range-calendar-CnBylqhu.js";
|
|
3
3
|
import { B as X, I as Y, M as Z, d as _, e as $, g as aa, N as ea, b as sa, a as na, f as ta, P as oa, c as ra, S as la, T as ia } from "./mobile-nav-wrapper-CWqhZ0qz.js";
|
|
4
4
|
export {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { Button as w, Div as o, On as S, Span as C, Th as
|
|
2
|
-
import { Atom as h, Component as c, Data as B, DateTime as
|
|
3
|
-
import { B as M, I as
|
|
1
|
+
import { Button as w, Div as o, On as S, Span as C, Th as N, UseParent as E, I as Q, Thead as G, Tr as X, Table as I, P as x, Li as y, Time as q, Nav as m, Ul as g, Section as L, Canvas as K } from "@base-framework/atoms";
|
|
2
|
+
import { Atom as h, Component as c, Data as B, DateTime as V, router as k, NavLink as T, DataTracker as U, Jot as _, base as R, Dom as O } from "@base-framework/base";
|
|
3
|
+
import { B as M, I as J } from "./buttons-CHEs54Wl.js";
|
|
4
4
|
import { Icons as D } from "./icons.es.js";
|
|
5
|
-
import { TableBody as
|
|
6
|
-
import { C as
|
|
7
|
-
import { A as
|
|
5
|
+
import { TableBody as Z, DataTableBody as ee, ScrollableTableBody as te, List as se, IntervalTimer as ae } from "@base-framework/organisms";
|
|
6
|
+
import { C as ie, I as ne, H as oe } from "./inputs-9udyzkHR.js";
|
|
7
|
+
import { A as le, P as re } from "./range-calendar-CnBylqhu.js";
|
|
8
8
|
h((t, e) => ({
|
|
9
9
|
class: "flex items-center px-4 py-2",
|
|
10
10
|
...t,
|
|
@@ -34,31 +34,31 @@ class ft extends c {
|
|
|
34
34
|
return o({ class: this.class || "" }, this.children);
|
|
35
35
|
}
|
|
36
36
|
}
|
|
37
|
-
const
|
|
37
|
+
const ce = (t) => {
|
|
38
38
|
const e = new Date(t, 11, 31), s = new Date(t, 0, 1);
|
|
39
39
|
return e.getDay() === 4 || // December 31 is a Thursday
|
|
40
40
|
s.getDay() === 4;
|
|
41
|
-
},
|
|
41
|
+
}, de = (t) => {
|
|
42
42
|
const e = new Date(t.valueOf()), s = (e.getDay() + 6) % 7;
|
|
43
43
|
e.setDate(e.getDate() - s + 3);
|
|
44
44
|
const a = e.getFullYear(), i = new Date(a, 0, 4);
|
|
45
45
|
i.setDate(i.getDate() - (i.getDay() + 6) % 7);
|
|
46
46
|
const n = Math.ceil((e - i) / 6048e5) + 1;
|
|
47
|
-
return n > 52 && !
|
|
47
|
+
return n > 52 && !ce(a) ? {
|
|
48
48
|
weekNumber: 1,
|
|
49
49
|
year: a + 1
|
|
50
50
|
} : {
|
|
51
51
|
weekNumber: n,
|
|
52
52
|
year: a
|
|
53
53
|
};
|
|
54
|
-
},
|
|
54
|
+
}, he = (t, e, s) => {
|
|
55
55
|
if (s === 0) return [];
|
|
56
56
|
const a = new Date(t, e, 0).getDate();
|
|
57
57
|
return Array.from(
|
|
58
58
|
{ length: s },
|
|
59
59
|
(i, n) => new Date(t, e - 1, a - s + n + 1)
|
|
60
60
|
);
|
|
61
|
-
},
|
|
61
|
+
}, ue = (t, e, s) => Array.from({ length: s }, (a, i) => new Date(t, e + 1, i + 1)), W = (t, e) => {
|
|
62
62
|
const s = new Date(e, 0, 4), a = (s.getDay() + 6) % 7, i = new Date(s);
|
|
63
63
|
i.setDate(s.getDate() - a);
|
|
64
64
|
const n = new Date(i);
|
|
@@ -77,11 +77,11 @@ const re = (t) => {
|
|
|
77
77
|
for (let n = 1; n <= s; n++)
|
|
78
78
|
i.push(new Date(t, e, n)), i.length === 7 && (a.push(i), i = []);
|
|
79
79
|
return i.length > 0 && a.push(i), a;
|
|
80
|
-
},
|
|
80
|
+
}, fe = (t, e, s) => {
|
|
81
81
|
const a = /* @__PURE__ */ new Date();
|
|
82
82
|
return a.getDate() === t && a.getMonth() === e && a.getFullYear() === s;
|
|
83
|
-
},
|
|
84
|
-
const n =
|
|
83
|
+
}, ge = ({ day: t, month: e, year: s, weekNumber: a, selectWeek: i }) => {
|
|
84
|
+
const n = fe(t, e, s);
|
|
85
85
|
return w({
|
|
86
86
|
text: t || "",
|
|
87
87
|
disabled: !t,
|
|
@@ -92,19 +92,19 @@ const re = (t) => {
|
|
|
92
92
|
`,
|
|
93
93
|
click: () => i(a, s)
|
|
94
94
|
});
|
|
95
|
-
},
|
|
96
|
-
const s = new Date(t, e, 1).getDay(), a = new Date(t, e + 1, 0).getDate(), i =
|
|
95
|
+
}, me = (t, e) => {
|
|
96
|
+
const s = new Date(t, e, 1).getDay(), a = new Date(t, e + 1, 0).getDate(), i = he(t, e, s), n = Array.from({ length: a }, (u, b) => new Date(t, e, b + 1)), l = (i.length + n.length) % 7, d = l === 0 ? 0 : 7 - l, r = ue(t, e, d), f = [...i, ...n, ...r], p = [];
|
|
97
97
|
for (let u = 0; u < f.length; u += 7) {
|
|
98
|
-
const b = f.slice(u, u + 7), v = b.find((
|
|
98
|
+
const b = f.slice(u, u + 7), v = b.find((F) => F) || new Date(t, e, 1), { weekNumber: H, year: Y } = de(v);
|
|
99
99
|
p.push({
|
|
100
|
-
weekNumber:
|
|
101
|
-
year:
|
|
100
|
+
weekNumber: H,
|
|
101
|
+
year: Y,
|
|
102
102
|
days: b
|
|
103
103
|
});
|
|
104
104
|
}
|
|
105
105
|
return p;
|
|
106
|
-
},
|
|
107
|
-
const { year: i, month: n, currentDate: l } = a, d =
|
|
106
|
+
}, pe = ({ selectWeek: t }) => S("month", (e, s, { data: a }) => {
|
|
107
|
+
const { year: i, month: n, currentDate: l } = a, d = me(i, n);
|
|
108
108
|
return o(
|
|
109
109
|
{ class: "grid grid-cols-8 gap-1 text-sm px-4 py-2" },
|
|
110
110
|
[
|
|
@@ -141,7 +141,7 @@ const re = (t) => {
|
|
|
141
141
|
o(
|
|
142
142
|
{ class: "grid grid-cols-7 col-span-7 text-center" },
|
|
143
143
|
f.map(
|
|
144
|
-
(u) =>
|
|
144
|
+
(u) => ge({
|
|
145
145
|
year: u?.getFullYear() || null,
|
|
146
146
|
month: u?.getMonth() || null,
|
|
147
147
|
day: u?.getDate() || null,
|
|
@@ -167,7 +167,7 @@ const re = (t) => {
|
|
|
167
167
|
variant: "icon",
|
|
168
168
|
icon: t === "Previous" ? D.chevron.single.left : D.chevron.single.right
|
|
169
169
|
}
|
|
170
|
-
),
|
|
170
|
+
), be = ({ next: t, previous: e }) => o({ class: "flex flex-auto min-h-12 text-sm font-medium relative justify-center items-center" }, [
|
|
171
171
|
C("[[monthName]] [[year]]"),
|
|
172
172
|
$({
|
|
173
173
|
label: "Previous",
|
|
@@ -231,7 +231,7 @@ class pt extends c {
|
|
|
231
231
|
* @returns {string}
|
|
232
232
|
*/
|
|
233
233
|
getMonthName(e) {
|
|
234
|
-
return
|
|
234
|
+
return V.monthNames[e];
|
|
235
235
|
}
|
|
236
236
|
/**
|
|
237
237
|
* Updates the calendar to show the previous month.
|
|
@@ -286,38 +286,38 @@ class pt extends c {
|
|
|
286
286
|
*/
|
|
287
287
|
render() {
|
|
288
288
|
return o({ class: "week-calendar-container border rounded-md p-3" }, [
|
|
289
|
-
|
|
289
|
+
be({
|
|
290
290
|
next: () => this.goToNextMonth(),
|
|
291
291
|
previous: () => this.goToPreviousMonth()
|
|
292
292
|
}),
|
|
293
|
-
|
|
293
|
+
pe({
|
|
294
294
|
selectWeek: (e, s) => this.selectWeek(e, s)
|
|
295
295
|
})
|
|
296
296
|
]);
|
|
297
297
|
}
|
|
298
298
|
}
|
|
299
|
-
const
|
|
299
|
+
const ke = (t, e) => {
|
|
300
300
|
const s = t.toggleAllSelectedRows();
|
|
301
301
|
e.state.checked = !s;
|
|
302
|
-
},
|
|
303
|
-
|
|
304
|
-
]),
|
|
302
|
+
}, we = (t) => N({ class: `cursor-pointer py-3 px-4 text-base w-10 ${t.class || ""}` }, [
|
|
303
|
+
E((e) => new ie({ class: "mr-2", onChange: (s, a) => ke(e, a) }))
|
|
304
|
+
]), ye = ({ align: t, sortable: e, key: s, label: a, sort: i, class: n }) => {
|
|
305
305
|
const l = t || "justify-start";
|
|
306
|
-
return
|
|
306
|
+
return N({
|
|
307
307
|
class: `cursor-pointer py-3 px-4 text-base ${n || ""}`,
|
|
308
308
|
click: e && (() => i(s))
|
|
309
309
|
}, [
|
|
310
310
|
o({ class: `flex flex-auto w-full items-center ${l}` }, [
|
|
311
311
|
C(a),
|
|
312
|
-
e &&
|
|
312
|
+
e && Q({ class: "ml-2", html: D.arrows.upDown })
|
|
313
313
|
])
|
|
314
314
|
]);
|
|
315
|
-
}, P = (t) =>
|
|
316
|
-
|
|
315
|
+
}, P = (t) => G([
|
|
316
|
+
X({
|
|
317
317
|
class: "text-muted-foreground border-b",
|
|
318
318
|
map: [
|
|
319
319
|
t.headers,
|
|
320
|
-
(e) => e.label === "checkbox" ?
|
|
320
|
+
(e) => e.label === "checkbox" ? we({ toggle: t.toggle }) : ye({
|
|
321
321
|
align: e.align,
|
|
322
322
|
sortable: e.sortable,
|
|
323
323
|
key: e.key,
|
|
@@ -326,7 +326,7 @@ const be = (t, e) => {
|
|
|
326
326
|
})
|
|
327
327
|
]
|
|
328
328
|
})
|
|
329
|
-
]),
|
|
329
|
+
]), xe = ({ key: t, rows: e, selectRow: s, rowItem: a, emptyState: i, skeleton: n, columnCount: l }) => new Z({
|
|
330
330
|
cache: "list",
|
|
331
331
|
key: t,
|
|
332
332
|
items: e,
|
|
@@ -336,7 +336,7 @@ const be = (t, e) => {
|
|
|
336
336
|
skeleton: n,
|
|
337
337
|
columnCount: l
|
|
338
338
|
});
|
|
339
|
-
class
|
|
339
|
+
class j extends c {
|
|
340
340
|
/**
|
|
341
341
|
* Initializes component data.
|
|
342
342
|
*
|
|
@@ -422,7 +422,7 @@ class U extends c {
|
|
|
422
422
|
this.headers && P({ headers: this.headers, sort: (a) => this.sortRows(a) }),
|
|
423
423
|
// @ts-ignore
|
|
424
424
|
this.customHeader ?? null,
|
|
425
|
-
|
|
425
|
+
xe({
|
|
426
426
|
// @ts-ignore
|
|
427
427
|
key: this.key,
|
|
428
428
|
// @ts-ignore
|
|
@@ -501,7 +501,7 @@ class U extends c {
|
|
|
501
501
|
this.data.selectedRows = [];
|
|
502
502
|
}
|
|
503
503
|
}
|
|
504
|
-
const
|
|
504
|
+
const ve = (t) => new ee({
|
|
505
505
|
cache: "list",
|
|
506
506
|
loadMoreItems: t.loadMoreItems,
|
|
507
507
|
offset: t.offset,
|
|
@@ -514,7 +514,7 @@ const xe = (t) => new Z({
|
|
|
514
514
|
skeleton: t.skeleton,
|
|
515
515
|
columnCount: t.columnCount
|
|
516
516
|
});
|
|
517
|
-
class
|
|
517
|
+
class De extends j {
|
|
518
518
|
/**
|
|
519
519
|
* Renders the DataTable component.
|
|
520
520
|
*
|
|
@@ -530,7 +530,7 @@ class ve extends U {
|
|
|
530
530
|
this.headers && P({ headers: this.headers, sort: (a) => this.sortRows(a) }),
|
|
531
531
|
// @ts-ignore
|
|
532
532
|
this.customHeader ?? null,
|
|
533
|
-
|
|
533
|
+
ve({
|
|
534
534
|
// @ts-ignore
|
|
535
535
|
loadMoreItems: this.loadMoreItems,
|
|
536
536
|
// @ts-ignore
|
|
@@ -566,7 +566,7 @@ class ve extends U {
|
|
|
566
566
|
this.list.refresh();
|
|
567
567
|
}
|
|
568
568
|
}
|
|
569
|
-
const bt = h((t) => new
|
|
569
|
+
const bt = h((t) => new De(
|
|
570
570
|
{
|
|
571
571
|
cache: t.cache ?? "list",
|
|
572
572
|
tableData: t.data,
|
|
@@ -583,7 +583,7 @@ const bt = h((t) => new ve(
|
|
|
583
583
|
emptyState: t.emptyState,
|
|
584
584
|
skeleton: t.skeleton
|
|
585
585
|
}
|
|
586
|
-
)),
|
|
586
|
+
)), Se = (t) => new te({
|
|
587
587
|
cache: "list",
|
|
588
588
|
scrollContainer: t.scrollContainer,
|
|
589
589
|
loadMoreItems: t.loadMoreItems,
|
|
@@ -597,7 +597,7 @@ const bt = h((t) => new ve(
|
|
|
597
597
|
skeleton: t.skeleton,
|
|
598
598
|
columnCount: t.columnCount
|
|
599
599
|
});
|
|
600
|
-
class
|
|
600
|
+
class Ce extends j {
|
|
601
601
|
/**
|
|
602
602
|
* Renders the DataTable component.
|
|
603
603
|
*
|
|
@@ -613,7 +613,7 @@ class Se extends U {
|
|
|
613
613
|
this.headers && P({ headers: this.headers, sort: (a) => this.sortRows(a) }),
|
|
614
614
|
// @ts-ignore
|
|
615
615
|
this.customHeader ?? null,
|
|
616
|
-
|
|
616
|
+
Se({
|
|
617
617
|
// @ts-ignore
|
|
618
618
|
scrollContainer: this.scrollContainer,
|
|
619
619
|
// @ts-ignore
|
|
@@ -651,7 +651,7 @@ class Se extends U {
|
|
|
651
651
|
this.list.refresh();
|
|
652
652
|
}
|
|
653
653
|
}
|
|
654
|
-
const kt = h((t) => new
|
|
654
|
+
const kt = h((t) => new Ce(
|
|
655
655
|
{
|
|
656
656
|
cache: t.cache ?? "list",
|
|
657
657
|
tableData: t.data,
|
|
@@ -669,38 +669,38 @@ const kt = h((t) => new Se(
|
|
|
669
669
|
emptyState: t.emptyState,
|
|
670
670
|
skeleton: t.skeleton
|
|
671
671
|
}
|
|
672
|
-
)),
|
|
672
|
+
)), Le = h(({ name: t, email: e }) => o({ class: "min-w-0 flex-auto" }, [
|
|
673
673
|
x({ class: "text-base font-semibold leading-6 m-0" }, t),
|
|
674
674
|
x({ class: "truncate text-sm leading-5 text-muted-foreground m-0" }, e)
|
|
675
|
-
])),
|
|
675
|
+
])), Ie = () => o({ class: "flex items-center gap-x-1.5" }, [
|
|
676
676
|
o({ class: "flex-none rounded-full bg-emerald-500/20 p-1" }, [
|
|
677
677
|
o({ class: "h-1.5 w-1.5 rounded-full bg-emerald-500" })
|
|
678
678
|
]),
|
|
679
679
|
x({ class: "text-xs leading-5 text-gray-500" }, "Online")
|
|
680
|
-
]),
|
|
680
|
+
]), Be = (t) => x({ class: "text-xs leading-5 text-muted-foreground" }, [
|
|
681
681
|
C("Last seen "),
|
|
682
|
-
|
|
683
|
-
]),
|
|
682
|
+
q({ datetime: t }, "3h ago")
|
|
683
|
+
]), Te = (t, e) => t === "online" ? Ie() : Be(e), Me = h(({ role: t, lastSeen: e, status: s }) => o({ class: "hidden shrink-0 sm:flex sm:flex-col sm:items-end" }, [
|
|
684
684
|
x({ class: "text-sm leading-6 m-0" }, t),
|
|
685
|
-
|
|
686
|
-
])),
|
|
685
|
+
Te(s, e)
|
|
686
|
+
])), Pe = (t) => t.split(" ").map((s) => s[0]).join(""), Re = h((t) => y({ class: "fadeIn flex justify-between gap-x-6 py-4 px-4 rounded-md hover:bg-muted/50" }, [
|
|
687
687
|
o({ class: "flex min-w-0 gap-x-4" }, [
|
|
688
|
-
|
|
689
|
-
|
|
688
|
+
le({ src: t.image, alt: t.name, fallbackText: Pe(t.name) }),
|
|
689
|
+
Le({ name: t.name, email: t.email })
|
|
690
690
|
]),
|
|
691
|
-
|
|
691
|
+
Me({
|
|
692
692
|
role: t.role,
|
|
693
693
|
lastSeen: t.lastSeen,
|
|
694
694
|
status: t.status
|
|
695
695
|
})
|
|
696
|
-
])), wt = h((t) => new
|
|
696
|
+
])), wt = h((t) => new se({
|
|
697
697
|
cache: "list",
|
|
698
698
|
key: "name",
|
|
699
699
|
items: t.users,
|
|
700
700
|
role: "list",
|
|
701
701
|
class: "divide-y divide-border",
|
|
702
|
-
rowItem:
|
|
703
|
-
})),
|
|
702
|
+
rowItem: Re
|
|
703
|
+
})), Oe = (t, e) => e.includes(t), We = (t, e, s) => t.exact ? s === e : Oe(e, s), $e = ({ text: t, href: e, exact: s, hidden: a }) => new T({
|
|
704
704
|
text: t,
|
|
705
705
|
href: e,
|
|
706
706
|
exact: s,
|
|
@@ -763,7 +763,7 @@ class yt extends c {
|
|
|
763
763
|
for (const a of this.links) {
|
|
764
764
|
if (!a.rendered)
|
|
765
765
|
continue;
|
|
766
|
-
|
|
766
|
+
We(a, a.getLinkPath(), e) ? (this.updateLink(a, !0), s = !0) : this.updateLink(a, !1);
|
|
767
767
|
}
|
|
768
768
|
!s && this.links[0] && this.updateLink(this.links[0], !0);
|
|
769
769
|
}
|
|
@@ -793,7 +793,7 @@ class yt extends c {
|
|
|
793
793
|
* @returns {object}
|
|
794
794
|
*/
|
|
795
795
|
addLink({ label: e, href: s, exact: a, hidden: i }) {
|
|
796
|
-
const n =
|
|
796
|
+
const n = $e({ text: e, href: s, exact: a, hidden: i });
|
|
797
797
|
return this.links.push(n), n;
|
|
798
798
|
}
|
|
799
799
|
/**
|
|
@@ -811,7 +811,7 @@ const xt = h((t) => {
|
|
|
811
811
|
M({ variant: "back", class: "ghost", ...t })
|
|
812
812
|
]);
|
|
813
813
|
});
|
|
814
|
-
class
|
|
814
|
+
class A extends c {
|
|
815
815
|
/**
|
|
816
816
|
* This will declare the props for the compiler.
|
|
817
817
|
*
|
|
@@ -898,13 +898,13 @@ class j extends c {
|
|
|
898
898
|
return this.children;
|
|
899
899
|
}
|
|
900
900
|
}
|
|
901
|
-
|
|
901
|
+
U.addType("dockableOverlay", (t) => {
|
|
902
902
|
if (!t)
|
|
903
903
|
return;
|
|
904
904
|
const e = t.component;
|
|
905
905
|
e && e.rendered === !0 && e.state.docked === !1 && e.destroy();
|
|
906
906
|
});
|
|
907
|
-
class vt extends
|
|
907
|
+
class vt extends A {
|
|
908
908
|
/**
|
|
909
909
|
* This will stop presistence.
|
|
910
910
|
*
|
|
@@ -970,7 +970,7 @@ class vt extends j {
|
|
|
970
970
|
* @returns {void}
|
|
971
971
|
*/
|
|
972
972
|
afterSetup() {
|
|
973
|
-
|
|
973
|
+
U.add(
|
|
974
974
|
this.container,
|
|
975
975
|
"dockableOverlay",
|
|
976
976
|
{
|
|
@@ -1013,7 +1013,7 @@ class vt extends j {
|
|
|
1013
1013
|
document.documentElement.style.overflowY = "auto";
|
|
1014
1014
|
}
|
|
1015
1015
|
}
|
|
1016
|
-
class Dt extends
|
|
1016
|
+
class Dt extends A {
|
|
1017
1017
|
/**
|
|
1018
1018
|
* This will get the overlay type.
|
|
1019
1019
|
*
|
|
@@ -1032,7 +1032,7 @@ class Dt extends j {
|
|
|
1032
1032
|
this.container = e, this.initialize();
|
|
1033
1033
|
}
|
|
1034
1034
|
}
|
|
1035
|
-
const
|
|
1035
|
+
const ze = h(({ index: t, click: e, state: s }, a) => y({
|
|
1036
1036
|
class: "p-2 cursor-pointer hover:bg-muted/50",
|
|
1037
1037
|
onState: [
|
|
1038
1038
|
[s, "selectedIndex", {
|
|
@@ -1041,11 +1041,11 @@ const $e = h(({ index: t, click: e, state: s }, a) => y({
|
|
|
1041
1041
|
}]
|
|
1042
1042
|
],
|
|
1043
1043
|
click: () => e(t)
|
|
1044
|
-
}, a)),
|
|
1044
|
+
}, a)), Ne = h(({ selectOption: t, state: e }) => g({
|
|
1045
1045
|
class: "border rounded-md list-none m-0 p-0 max-h-[400px] overflow-y-auto",
|
|
1046
|
-
for: ["filteredOptions", (s, a) =>
|
|
1047
|
-
})),
|
|
1048
|
-
|
|
1046
|
+
for: ["filteredOptions", (s, a) => ze({ index: a, click: t, state: e }, s.label)]
|
|
1047
|
+
})), Ue = h((t) => o({ class: "relative flex items-center" }, [
|
|
1048
|
+
ne({
|
|
1049
1049
|
cache: "input",
|
|
1050
1050
|
class: t.class ?? "",
|
|
1051
1051
|
placeholder: t.placeholder ?? "Search...",
|
|
@@ -1061,22 +1061,22 @@ const $e = h(({ index: t, click: e, state: s }, a) => y({
|
|
|
1061
1061
|
]
|
|
1062
1062
|
}),
|
|
1063
1063
|
t.icon && o({ class: "absolute flex right-0 mr-2" }, [
|
|
1064
|
-
|
|
1064
|
+
J(t.icon)
|
|
1065
1065
|
])
|
|
1066
|
-
])),
|
|
1066
|
+
])), je = (t) => o({
|
|
1067
1067
|
class: "relative flex fle-auto flex-col",
|
|
1068
1068
|
onState: ["open", (e, s, a) => {
|
|
1069
1069
|
if (e)
|
|
1070
|
-
return new
|
|
1070
|
+
return new re({
|
|
1071
1071
|
cache: "dropdown",
|
|
1072
1072
|
parent: a,
|
|
1073
1073
|
button: a.input,
|
|
1074
1074
|
size: "xl"
|
|
1075
1075
|
}, [
|
|
1076
|
-
|
|
1076
|
+
Ne(t)
|
|
1077
1077
|
]);
|
|
1078
1078
|
}]
|
|
1079
|
-
}), St =
|
|
1079
|
+
}), St = _(
|
|
1080
1080
|
{
|
|
1081
1081
|
/**
|
|
1082
1082
|
* This will set up the data object.
|
|
@@ -1173,7 +1173,7 @@ const $e = h(({ index: t, click: e, state: s }, a) => y({
|
|
|
1173
1173
|
*/
|
|
1174
1174
|
render() {
|
|
1175
1175
|
return o({ class: "relative w-full max-w-md" }, [
|
|
1176
|
-
|
|
1176
|
+
Ue({
|
|
1177
1177
|
// @ts-ignore
|
|
1178
1178
|
state: this.state,
|
|
1179
1179
|
// @ts-ignore
|
|
@@ -1185,7 +1185,7 @@ const $e = h(({ index: t, click: e, state: s }, a) => y({
|
|
|
1185
1185
|
// @ts-ignore
|
|
1186
1186
|
handleKeyDown: this.handleKeyDown.bind(this)
|
|
1187
1187
|
}),
|
|
1188
|
-
|
|
1188
|
+
je({
|
|
1189
1189
|
// @ts-ignore
|
|
1190
1190
|
state: this.state,
|
|
1191
1191
|
// @ts-ignore
|
|
@@ -1196,7 +1196,7 @@ const $e = h(({ index: t, click: e, state: s }, a) => y({
|
|
|
1196
1196
|
]);
|
|
1197
1197
|
}
|
|
1198
1198
|
}
|
|
1199
|
-
),
|
|
1199
|
+
), Ae = (t) => y(
|
|
1200
1200
|
{
|
|
1201
1201
|
class: "inline-flex flex-auto items-center justify-center whitespace-nowrap rounded-sm text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-primary data-[state=active]:text-primary-foreground data-[state=active]:shadow-sm",
|
|
1202
1202
|
dataSet: ["selected", ["state", t.value, "active"]]
|
|
@@ -1208,8 +1208,8 @@ const $e = h(({ index: t, click: e, state: s }, a) => y({
|
|
|
1208
1208
|
click: (e) => t.callBack(t.value)
|
|
1209
1209
|
}, t.label)
|
|
1210
1210
|
]
|
|
1211
|
-
),
|
|
1212
|
-
g({ class: "flex flex-auto flex-row", map: [t.options, (e) =>
|
|
1211
|
+
), He = (t, e) => (t.callBack = e, Ae(t)), Ye = (t) => m({ class: `tab items-center justify-center rounded-md bg-muted p-1 text-muted-foreground ${t.class}` }, [
|
|
1212
|
+
g({ class: "flex flex-auto flex-row", map: [t.options, (e) => He(e, t.callBack)] })
|
|
1213
1213
|
]);
|
|
1214
1214
|
class Ct extends c {
|
|
1215
1215
|
/**
|
|
@@ -1228,7 +1228,7 @@ class Ct extends c {
|
|
|
1228
1228
|
render() {
|
|
1229
1229
|
const e = this.select.bind(this);
|
|
1230
1230
|
return o({ class: "" }, [
|
|
1231
|
-
|
|
1231
|
+
Ye({
|
|
1232
1232
|
class: this.class,
|
|
1233
1233
|
options: this.options,
|
|
1234
1234
|
callBack: e
|
|
@@ -1298,7 +1298,7 @@ class Ct extends c {
|
|
|
1298
1298
|
};
|
|
1299
1299
|
}
|
|
1300
1300
|
}
|
|
1301
|
-
const
|
|
1301
|
+
const Fe = (t) => y(
|
|
1302
1302
|
{
|
|
1303
1303
|
class: "inline-flex flex-auto items-center justify-center whitespace-nowrap rounded-sm text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-primary data-[state=active]:text-primary-foreground data-[state=active]:shadow-sm",
|
|
1304
1304
|
dataSet: ["selected", ["state", t.value, "active"]]
|
|
@@ -1311,8 +1311,8 @@ const Ye = (t) => y(
|
|
|
1311
1311
|
disabled: t.disabled
|
|
1312
1312
|
}, t.label)
|
|
1313
1313
|
]
|
|
1314
|
-
),
|
|
1315
|
-
g({ class: "flex flex-auto flex-row", map: [t.options, (e) =>
|
|
1314
|
+
), Ee = (t, e) => (t.callBack = e, Fe(t)), Qe = (t) => m({ class: `tab items-center justify-center rounded-md bg-muted p-1 text-muted-foreground ${t.class}` }, [
|
|
1315
|
+
g({ class: "flex flex-auto flex-row", map: [t.options, (e) => Ee(e, t.callBack)] })
|
|
1316
1316
|
]);
|
|
1317
1317
|
class Lt extends c {
|
|
1318
1318
|
/**
|
|
@@ -1330,7 +1330,7 @@ class Lt extends c {
|
|
|
1330
1330
|
*/
|
|
1331
1331
|
render() {
|
|
1332
1332
|
const e = this.select.bind(this);
|
|
1333
|
-
return
|
|
1333
|
+
return Qe({
|
|
1334
1334
|
class: this.class,
|
|
1335
1335
|
options: this.options,
|
|
1336
1336
|
callBack: e
|
|
@@ -1356,17 +1356,17 @@ class Lt extends c {
|
|
|
1356
1356
|
};
|
|
1357
1357
|
}
|
|
1358
1358
|
}
|
|
1359
|
-
const
|
|
1359
|
+
const Ge = (t, e) => new RegExp(`${t}($|/|\\.).*`).test(e), Xe = (t, e) => {
|
|
1360
1360
|
const s = t.getLinkPath();
|
|
1361
|
-
return t.exact ? e === s :
|
|
1362
|
-
},
|
|
1361
|
+
return t.exact ? e === s : Ge(s, e);
|
|
1362
|
+
}, qe = ({ text: t, href: e, exact: s }) => new T({
|
|
1363
1363
|
text: t,
|
|
1364
1364
|
href: e,
|
|
1365
1365
|
exact: s,
|
|
1366
1366
|
dataSet: ["selected", ["state", !0, "active"]],
|
|
1367
1367
|
class: "inline-flex flex-auto items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5 text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-primary data-[state=active]:text-primary-foreground data-[state=active]:shadow-sm"
|
|
1368
1368
|
});
|
|
1369
|
-
class
|
|
1369
|
+
class Ke extends c {
|
|
1370
1370
|
/**
|
|
1371
1371
|
* This will declare the props for the compiler.
|
|
1372
1372
|
*
|
|
@@ -1417,7 +1417,7 @@ class qe extends c {
|
|
|
1417
1417
|
let s = !1, a = this.links[0];
|
|
1418
1418
|
this.deactivateAllLinks();
|
|
1419
1419
|
for (const i of this.links)
|
|
1420
|
-
if (i.rendered !== !1 && (s =
|
|
1420
|
+
if (i.rendered !== !1 && (s = Xe(i, e), s === !0)) {
|
|
1421
1421
|
this.updateLink(i, !0);
|
|
1422
1422
|
break;
|
|
1423
1423
|
}
|
|
@@ -1449,7 +1449,7 @@ class qe extends c {
|
|
|
1449
1449
|
* @returns {object}
|
|
1450
1450
|
*/
|
|
1451
1451
|
addLink({ label: e, href: s, exact: a }) {
|
|
1452
|
-
const i =
|
|
1452
|
+
const i = qe({ text: e, href: s, exact: a });
|
|
1453
1453
|
return this.links.push(i), i;
|
|
1454
1454
|
}
|
|
1455
1455
|
/**
|
|
@@ -1477,7 +1477,7 @@ class It extends c {
|
|
|
1477
1477
|
*/
|
|
1478
1478
|
render() {
|
|
1479
1479
|
return o({ class: "tab-panel" }, [
|
|
1480
|
-
new
|
|
1480
|
+
new Ke({
|
|
1481
1481
|
class: this.class,
|
|
1482
1482
|
options: this.options
|
|
1483
1483
|
}),
|
|
@@ -1507,7 +1507,7 @@ class It extends c {
|
|
|
1507
1507
|
return s;
|
|
1508
1508
|
}
|
|
1509
1509
|
}
|
|
1510
|
-
const
|
|
1510
|
+
const Ve = (t) => y(
|
|
1511
1511
|
{
|
|
1512
1512
|
class: "relative inline-flex items-center justify-center whitespace-nowrap text-sm font-medium text-muted-foreground transition-colors hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:text-foreground after:absolute after:bottom-0 after:left-0 after:right-0 after:h-0.5 after:bg-primary after:transition-all after:duration-200 after:scale-x-0 data-[state=active]:after:scale-x-100",
|
|
1513
1513
|
dataSet: ["selected", ["state", t.value, "active"]]
|
|
@@ -1519,8 +1519,8 @@ const Ke = (t) => y(
|
|
|
1519
1519
|
click: (e) => t.callBack(t.value)
|
|
1520
1520
|
}, t.label)
|
|
1521
1521
|
]
|
|
1522
|
-
),
|
|
1523
|
-
g({ class: "flex flex-row items-center", map: [t.options, (e) =>
|
|
1522
|
+
), _e = (t, e) => (t.callBack = e, Ve(t)), Je = (t) => m({ class: `border-b border-border ${t.class}` }, [
|
|
1523
|
+
g({ class: "flex flex-row items-center", map: [t.options, (e) => _e(e, t.callBack)] })
|
|
1524
1524
|
]);
|
|
1525
1525
|
class Bt extends c {
|
|
1526
1526
|
/**
|
|
@@ -1539,7 +1539,7 @@ class Bt extends c {
|
|
|
1539
1539
|
render() {
|
|
1540
1540
|
const e = this.select.bind(this);
|
|
1541
1541
|
return o({ class: "underlined-button-tab-panel" }, [
|
|
1542
|
-
|
|
1542
|
+
Je({
|
|
1543
1543
|
class: this.class,
|
|
1544
1544
|
options: this.options,
|
|
1545
1545
|
callBack: e
|
|
@@ -1600,7 +1600,7 @@ class Bt extends c {
|
|
|
1600
1600
|
};
|
|
1601
1601
|
}
|
|
1602
1602
|
}
|
|
1603
|
-
const
|
|
1603
|
+
const Ze = (t) => y(
|
|
1604
1604
|
{
|
|
1605
1605
|
class: "relative inline-flex items-center justify-center whitespace-nowrap text-sm font-medium text-muted-foreground transition-colors hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:text-foreground after:absolute after:bottom-0 after:left-0 after:right-0 after:h-0.5 after:bg-primary after:transition-all after:duration-200 after:scale-x-0 data-[state=active]:after:scale-x-100",
|
|
1606
1606
|
dataSet: ["selected", ["state", t.value, "active"]]
|
|
@@ -1613,8 +1613,8 @@ const Je = (t) => y(
|
|
|
1613
1613
|
disabled: t.disabled
|
|
1614
1614
|
}, t.label)
|
|
1615
1615
|
]
|
|
1616
|
-
),
|
|
1617
|
-
g({ class: "flex flex-row items-center", map: [t.options, (e) =>
|
|
1616
|
+
), et = (t, e) => (t.callBack = e, Ze(t)), tt = (t) => m({ class: `border-b border-border ${t.class}` }, [
|
|
1617
|
+
g({ class: "flex flex-row items-center", map: [t.options, (e) => et(e, t.callBack)] })
|
|
1618
1618
|
]);
|
|
1619
1619
|
class Tt extends c {
|
|
1620
1620
|
/**
|
|
@@ -1632,7 +1632,7 @@ class Tt extends c {
|
|
|
1632
1632
|
*/
|
|
1633
1633
|
render() {
|
|
1634
1634
|
const e = this.select.bind(this);
|
|
1635
|
-
return
|
|
1635
|
+
return tt({
|
|
1636
1636
|
class: this.class,
|
|
1637
1637
|
options: this.options,
|
|
1638
1638
|
callBack: e
|
|
@@ -1658,9 +1658,9 @@ class Tt extends c {
|
|
|
1658
1658
|
};
|
|
1659
1659
|
}
|
|
1660
1660
|
}
|
|
1661
|
-
const
|
|
1661
|
+
const z = (t, e) => new RegExp(`${t}($|/|\\.).*`).test(e), st = (t, e) => {
|
|
1662
1662
|
const s = t.getLinkPath();
|
|
1663
|
-
return t.exact ? e === s :
|
|
1663
|
+
return console.log(s, e === s, t.exact, z(s, e)), t.exact ? e === s : z(s, e);
|
|
1664
1664
|
}, at = ({ text: t, href: e, exact: s }) => new T({
|
|
1665
1665
|
text: t,
|
|
1666
1666
|
href: e,
|
|
@@ -1717,7 +1717,7 @@ class it extends c {
|
|
|
1717
1717
|
*/
|
|
1718
1718
|
updateLinks(e) {
|
|
1719
1719
|
let s = !1, a = this.links[0];
|
|
1720
|
-
this.deactivateAllLinks();
|
|
1720
|
+
this.deactivateAllLinks(), console.log(e);
|
|
1721
1721
|
for (const i of this.links)
|
|
1722
1722
|
if (i.rendered !== !1 && (s = st(i, e), s === !0)) {
|
|
1723
1723
|
this.updateLink(i, !0);
|
|
@@ -1819,7 +1819,7 @@ class nt extends c {
|
|
|
1819
1819
|
onCreated() {
|
|
1820
1820
|
this.lineWidth = this.lineWidth || 3, this.lineColor = this.lineColor || "#000000", this.canvas = null, this.ctx = null, this.status = "stopped";
|
|
1821
1821
|
const e = 1e3 / 60;
|
|
1822
|
-
this.timer = new
|
|
1822
|
+
this.timer = new ae(e, this.draw.bind(this)), this.width = 0, this.height = 0, this.signed = !1, this.mouse = { x: 0, y: 0, status: "up" }, this.margin = this.margin || { x: 40, y: 60 }, this.targetSize = this.targetSize || { width: 740, height: 345 }, this.baseLineWidth = this.baseLineWidth || 2, this.baseStrokeColor = this.baseStrokeColor || "#000000";
|
|
1823
1823
|
}
|
|
1824
1824
|
/**
|
|
1825
1825
|
* Renders a <canvas> element.
|
|
@@ -1827,7 +1827,7 @@ class nt extends c {
|
|
|
1827
1827
|
* @returns {object} Layout definition for the canvas.
|
|
1828
1828
|
*/
|
|
1829
1829
|
render() {
|
|
1830
|
-
return
|
|
1830
|
+
return K({
|
|
1831
1831
|
style: "touch-action: none; -webkit-user-select: none; -webkit-touch-callout: none;"
|
|
1832
1832
|
});
|
|
1833
1833
|
}
|
|
@@ -2052,7 +2052,7 @@ class Pt extends c {
|
|
|
2052
2052
|
*/
|
|
2053
2053
|
render() {
|
|
2054
2054
|
return o({ class: "signature-panel relative flex flex-auto overflow-hidden select-none" }, [
|
|
2055
|
-
|
|
2055
|
+
oe({
|
|
2056
2056
|
cache: "hiddenInput",
|
|
2057
2057
|
required: !0,
|
|
2058
2058
|
bind: this.path + ".data"
|
|
@@ -2115,35 +2115,35 @@ class Pt extends c {
|
|
|
2115
2115
|
}
|
|
2116
2116
|
export {
|
|
2117
2117
|
xt as B,
|
|
2118
|
-
|
|
2119
|
-
|
|
2120
|
-
|
|
2118
|
+
we as C,
|
|
2119
|
+
xe as D,
|
|
2120
|
+
ye as H,
|
|
2121
2121
|
Dt as I,
|
|
2122
2122
|
yt as N,
|
|
2123
|
-
|
|
2123
|
+
A as O,
|
|
2124
2124
|
ft as P,
|
|
2125
2125
|
kt as S,
|
|
2126
2126
|
P as T,
|
|
2127
|
-
|
|
2127
|
+
Re as U,
|
|
2128
2128
|
pt as W,
|
|
2129
|
-
|
|
2129
|
+
ue as a,
|
|
2130
2130
|
W as b,
|
|
2131
|
-
|
|
2131
|
+
de as c,
|
|
2132
2132
|
gt as d,
|
|
2133
2133
|
mt as e,
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2134
|
+
ge as f,
|
|
2135
|
+
he as g,
|
|
2136
|
+
pe as h,
|
|
2137
|
+
be as i,
|
|
2138
|
+
j,
|
|
2139
2139
|
bt as k,
|
|
2140
2140
|
wt as l,
|
|
2141
2141
|
vt as m,
|
|
2142
2142
|
St as n,
|
|
2143
|
-
|
|
2143
|
+
Ue as o,
|
|
2144
2144
|
Ct as p,
|
|
2145
2145
|
Lt as q,
|
|
2146
|
-
|
|
2146
|
+
Ke as r,
|
|
2147
2147
|
It as s,
|
|
2148
2148
|
Bt as t,
|
|
2149
2149
|
Tt as u,
|
package/package.json
CHANGED