@base-framework/ui 1.0.62 → 1.0.66

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,10 +1,10 @@
1
- import { Button as y, Div as o, On as Y, Span as v, Th as P, UseParent as F, I as E, Thead as H, Tr as Q, Table as X, P as m, Li as D, Time as q, Nav as S, Ul as b, Section as O, Canvas as K } from "@base-framework/atoms";
2
- import { Atom as h, Component as u, Data as L, DateTime as G, Jot as R, router as x, NavLink as M, DataTracker as z, base as B, Dom as I } from "@base-framework/base";
3
- import { B as C, I as N } from "./buttons-CVEwmPAi.js";
1
+ import { Button as y, Div as o, On as E, Span as v, Th as P, UseParent as H, I as Q, Thead as X, Tr as q, Table as R, P as m, Li as D, Time as K, Nav as S, Ul as b, Section as O, Canvas as G } from "@base-framework/atoms";
2
+ import { Atom as h, Component as u, Data as L, DateTime as V, Jot as M, router as x, NavLink as z, DataTracker as N, base as B, Dom as I } from "@base-framework/base";
3
+ import { B as C, I as $ } from "./buttons-CVEwmPAi.js";
4
4
  import { Icons as w } from "./icons.es.js";
5
- import { TableBody as V, List as _, IntervalTimer as J } from "@base-framework/organisms";
6
- import { C as Z, I as ee, H as te } from "./inputs-DmJuUwS9.js";
7
- import { A as se, P as ne } from "./calendar-BDqm833e.js";
5
+ import { TableBody as _, ScrollableTableBody as J, List as Z, IntervalTimer as ee } from "@base-framework/organisms";
6
+ import { C as te, I as se, H as ae } from "./inputs-DmJuUwS9.js";
7
+ import { A as ne, P as ie } from "./calendar-BDqm833e.js";
8
8
  h((t, e) => ({
9
9
  class: "flex items-center px-4 py-2",
10
10
  ...t,
@@ -14,9 +14,9 @@ h(({ value: t, label: e }) => y({
14
14
  class: "inline-flex flex-auto items-center justify-center whitespace-nowrap rounded-md px-8 py-1 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-background data-[state=active]:text-foreground data-[state=active]:shadow",
15
15
  onState: ["performance", { active: t }],
16
16
  dataSet: ["performance", ["state", t, "active"]],
17
- click: (s, { state: n }) => n.performance = t
17
+ click: (s, { state: a }) => a.performance = t
18
18
  }, e));
19
- class Ve extends u {
19
+ class Je extends u {
20
20
  /**
21
21
  * This will declare the props for the compiler.
22
22
  *
@@ -34,54 +34,54 @@ class Ve extends u {
34
34
  return o({ class: this.class || "" }, this.children);
35
35
  }
36
36
  }
37
- const ae = (t) => {
37
+ const oe = (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
- }, ie = (t) => {
41
+ }, le = (t) => {
42
42
  const e = new Date(t.valueOf()), s = (e.getDay() + 6) % 7;
43
43
  e.setDate(e.getDate() - s + 3);
44
- const n = e.getFullYear(), a = new Date(n, 0, 4);
45
- a.setDate(a.getDate() - (a.getDay() + 6) % 7);
46
- const i = Math.ceil((e - a) / 6048e5) + 1;
47
- return i > 52 && !ae(n) ? {
44
+ const a = e.getFullYear(), n = new Date(a, 0, 4);
45
+ n.setDate(n.getDate() - (n.getDay() + 6) % 7);
46
+ const i = Math.ceil((e - n) / 6048e5) + 1;
47
+ return i > 52 && !oe(a) ? {
48
48
  weekNumber: 1,
49
- year: n + 1
49
+ year: a + 1
50
50
  } : {
51
51
  weekNumber: i,
52
- year: n
52
+ year: a
53
53
  };
54
- }, oe = (t, e, s) => {
54
+ }, re = (t, e, s) => {
55
55
  if (s === 0) return [];
56
- const n = new Date(t, e, 0).getDate();
56
+ const a = new Date(t, e, 0).getDate();
57
57
  return Array.from(
58
58
  { length: s },
59
- (a, i) => new Date(t, e - 1, n - s + i + 1)
59
+ (n, i) => new Date(t, e - 1, a - s + i + 1)
60
60
  );
61
- }, le = (t, e, s) => Array.from({ length: s }, (n, a) => new Date(t, e + 1, a + 1)), T = (t, e) => {
62
- const s = new Date(e, 0, 4), n = (s.getDay() + 6) % 7, a = new Date(s);
63
- a.setDate(s.getDate() - n);
64
- const i = new Date(a);
65
- return i.setDate(a.getDate() + (t - 1) * 7), i;
66
- }, _e = (t, e) => {
67
- const s = new Date(t, e, 1).getDay(), n = new Date(t, e + 1, 0).getDate(), a = [];
61
+ }, ce = (t, e, s) => Array.from({ length: s }, (a, n) => new Date(t, e + 1, n + 1)), T = (t, e) => {
62
+ const s = new Date(e, 0, 4), a = (s.getDay() + 6) % 7, n = new Date(s);
63
+ n.setDate(s.getDate() - a);
64
+ const i = new Date(n);
65
+ return i.setDate(n.getDate() + (t - 1) * 7), i;
66
+ }, Ze = (t, e) => {
67
+ const s = new Date(t, e, 1).getDay(), a = new Date(t, e + 1, 0).getDate(), n = [];
68
68
  let i = [];
69
- for (let l = 1 - s; l <= n; l++) {
69
+ for (let l = 1 - s; l <= a; l++) {
70
70
  const d = new Date(t, e, l);
71
- i.push(l > 0 ? d : null), (i.length === 7 || l === n) && (a.push([...i]), i = []);
71
+ i.push(l > 0 ? d : null), (i.length === 7 || l === a) && (n.push([...i]), i = []);
72
72
  }
73
- return a;
74
- }, Je = (t, e) => {
75
- const s = new Date(t, e + 1, 0).getDate(), n = [];
76
- let a = [];
73
+ return n;
74
+ }, et = (t, e) => {
75
+ const s = new Date(t, e + 1, 0).getDate(), a = [];
76
+ let n = [];
77
77
  for (let i = 1; i <= s; i++)
78
- a.push(new Date(t, e, i)), a.length === 7 && (n.push(a), a = []);
79
- return a.length > 0 && n.push(a), n;
80
- }, re = (t, e, s) => {
81
- const n = /* @__PURE__ */ new Date();
82
- return n.getDate() === t && n.getMonth() === e && n.getFullYear() === s;
83
- }, ce = ({ day: t, month: e, year: s, weekNumber: n, selectWeek: a }) => {
84
- const i = re(t, e, s);
78
+ n.push(new Date(t, e, i)), n.length === 7 && (a.push(n), n = []);
79
+ return n.length > 0 && a.push(n), a;
80
+ }, de = (t, e, s) => {
81
+ const a = /* @__PURE__ */ new Date();
82
+ return a.getDate() === t && a.getMonth() === e && a.getFullYear() === s;
83
+ }, he = ({ day: t, month: e, year: s, weekNumber: a, selectWeek: n }) => {
84
+ const i = de(t, e, s);
85
85
  return y({
86
86
  text: t || "",
87
87
  disabled: !t,
@@ -90,21 +90,21 @@ const ae = (t) => {
90
90
  ${i ? "bg-accent text-accent-foreground" : ""}
91
91
  hover:bg-primary hover:text-primary-foreground
92
92
  `,
93
- click: () => a(n, s)
93
+ click: () => n(a, s)
94
94
  });
95
- }, de = (t, e) => {
96
- const s = new Date(t, e, 1).getDay(), n = new Date(t, e + 1, 0).getDate(), a = oe(t, e, s), i = Array.from({ length: n }, (r, p) => new Date(t, e, p + 1)), l = (a.length + i.length) % 7, d = l === 0 ? 0 : 7 - l, c = le(t, e, d), g = [...a, ...i, ...c], f = [];
97
- for (let r = 0; r < g.length; r += 7) {
98
- const p = g.slice(r, r + 7), k = p.find((U) => U) || new Date(t, e, 1), { weekNumber: j, year: A } = ie(k);
99
- f.push({
100
- weekNumber: j,
101
- year: A,
95
+ }, ue = (t, e) => {
96
+ const s = new Date(t, e, 1).getDay(), a = new Date(t, e + 1, 0).getDate(), n = re(t, e, s), i = Array.from({ length: a }, (r, p) => new Date(t, e, p + 1)), l = (n.length + i.length) % 7, d = l === 0 ? 0 : 7 - l, c = ce(t, e, d), f = [...n, ...i, ...c], g = [];
97
+ for (let r = 0; r < f.length; r += 7) {
98
+ const p = f.slice(r, r + 7), k = p.find((F) => F) || new Date(t, e, 1), { weekNumber: U, year: Y } = le(k);
99
+ g.push({
100
+ weekNumber: U,
101
+ year: Y,
102
102
  days: p
103
103
  });
104
104
  }
105
- return f;
106
- }, he = ({ selectWeek: t }) => Y("month", (e, s, { data: n }) => {
107
- const { year: a, month: i, currentDate: l } = n, d = de(a, i);
105
+ return g;
106
+ }, fe = ({ selectWeek: t }) => E("month", (e, s, { data: a }) => {
107
+ const { year: n, month: i, currentDate: l } = a, d = ue(n, i);
108
108
  return o(
109
109
  { class: "grid grid-cols-8 gap-1 text-sm px-4 py-2" },
110
110
  [
@@ -120,7 +120,7 @@ const ae = (t) => {
120
120
  ),
121
121
  // Render each "week" row
122
122
  ...d.map(
123
- ({ weekNumber: c, days: g, year: f }) => o({
123
+ ({ weekNumber: c, days: f, year: g }) => o({
124
124
  class: "grid grid-cols-8 col-span-8 items-center ring-primary rounded-sm px-1",
125
125
  onSet: ["currentWeek", {
126
126
  ring: c
@@ -129,7 +129,7 @@ const ae = (t) => {
129
129
  // Left column: ISO week number
130
130
  o({
131
131
  class: "font-medium text-center col-span-1 rounded-sm cursor-pointer",
132
- click: () => t(c, f),
132
+ click: () => t(c, g),
133
133
  // If you have a 'currentWeek' state, you can highlight it with 'onSet'
134
134
  onSet: ["currentWeek", {
135
135
  "text-primary-foreground": c,
@@ -140,8 +140,8 @@ const ae = (t) => {
140
140
  // The 7 cells for each day in the row
141
141
  o(
142
142
  { class: "grid grid-cols-7 col-span-7 text-center" },
143
- g.map(
144
- (r) => ce({
143
+ f.map(
144
+ (r) => he({
145
145
  year: (r == null ? void 0 : r.getFullYear()) || null,
146
146
  month: (r == null ? void 0 : r.getMonth()) || null,
147
147
  day: (r == null ? void 0 : r.getDate()) || null,
@@ -167,7 +167,7 @@ const ae = (t) => {
167
167
  variant: "icon",
168
168
  icon: t === "Previous" ? w.chevron.single.left : w.chevron.single.right
169
169
  }
170
- ), ue = ({ next: t, previous: e }) => o({ class: "flex flex-auto min-h-12 text-sm font-medium relative justify-center items-center" }, [
170
+ ), ge = ({ next: t, previous: e }) => o({ class: "flex flex-auto min-h-12 text-sm font-medium relative justify-center items-center" }, [
171
171
  v("[[monthName]] [[year]]"),
172
172
  W({
173
173
  label: "Previous",
@@ -178,7 +178,7 @@ const ae = (t) => {
178
178
  click: t
179
179
  })
180
180
  ]);
181
- class Ze extends u {
181
+ class tt extends u {
182
182
  /**
183
183
  * This will declare the props for the compiler.
184
184
  *
@@ -193,12 +193,12 @@ class Ze extends u {
193
193
  * @returns {Data}
194
194
  */
195
195
  setData() {
196
- const e = /* @__PURE__ */ new Date(), s = this.selectedWeek || this.calculateCurrentWeek(e), n = T(s, e.getFullYear());
196
+ const e = /* @__PURE__ */ new Date(), s = this.selectedWeek || this.calculateCurrentWeek(e), a = T(s, e.getFullYear());
197
197
  return new L({
198
- monthName: this.getMonthName(n.getMonth()),
199
- year: n.getFullYear(),
200
- month: n.getMonth(),
201
- currentDate: n.getDate(),
198
+ monthName: this.getMonthName(a.getMonth()),
199
+ year: a.getFullYear(),
200
+ month: a.getMonth(),
201
+ currentDate: a.getDate(),
202
202
  currentWeek: s
203
203
  });
204
204
  }
@@ -219,10 +219,10 @@ class Ze extends u {
219
219
  * @returns {number}
220
220
  */
221
221
  calculateCurrentWeek(e) {
222
- const s = new Date(e.valueOf()), n = (e.getDay() + 6) % 7;
223
- s.setDate(s.getDate() - n + 3);
224
- const a = s.valueOf();
225
- return s.setMonth(0, 1), s.getDay() !== 4 && s.setMonth(0, 1 + (4 - s.getDay() + 7) % 7), 1 + Math.ceil((a - s) / 6048e5);
222
+ const s = new Date(e.valueOf()), a = (e.getDay() + 6) % 7;
223
+ s.setDate(s.getDate() - a + 3);
224
+ const n = s.valueOf();
225
+ return s.setMonth(0, 1), s.getDay() !== 4 && s.setMonth(0, 1 + (4 - s.getDay() + 7) % 7), 1 + Math.ceil((n - s) / 6048e5);
226
226
  }
227
227
  /**
228
228
  * Gets the name of the month.
@@ -231,7 +231,7 @@ class Ze extends u {
231
231
  * @returns {string}
232
232
  */
233
233
  getMonthName(e) {
234
- return G.monthNames[e];
234
+ return V.monthNames[e];
235
235
  }
236
236
  /**
237
237
  * Updates the calendar to show the previous month.
@@ -240,8 +240,8 @@ class Ze extends u {
240
240
  */
241
241
  goToPreviousMonth() {
242
242
  const e = this.data;
243
- let { year: s, month: n } = e;
244
- n === 0 ? (n = 11, s--) : n--, this.setDate(n, s);
243
+ let { year: s, month: a } = e;
244
+ a === 0 ? (a = 11, s--) : a--, this.setDate(a, s);
245
245
  }
246
246
  /**
247
247
  * Updates the calendar to show the next month.
@@ -250,8 +250,8 @@ class Ze extends u {
250
250
  */
251
251
  goToNextMonth() {
252
252
  const e = this.data;
253
- let { year: s, month: n } = e;
254
- n === 11 ? (n = 0, s++) : n++, this.setDate(n, s);
253
+ let { year: s, month: a } = e;
254
+ a === 11 ? (a = 0, s++) : a++, this.setDate(a, s);
255
255
  }
256
256
  /**
257
257
  * Sets the selected date.
@@ -261,12 +261,12 @@ class Ze extends u {
261
261
  * @param {number|null} [date=null]
262
262
  * @returns {void}
263
263
  */
264
- setDate(e, s, n) {
264
+ setDate(e, s, a) {
265
265
  this.data.set({
266
266
  year: s,
267
267
  month: e,
268
268
  monthName: this.getMonthName(e)
269
- }), n && (this.data.currentDate = n);
269
+ }), a && (this.data.currentDate = a);
270
270
  }
271
271
  /**
272
272
  * Handles week selection.
@@ -276,8 +276,8 @@ class Ze extends u {
276
276
  */
277
277
  selectWeek(e, s) {
278
278
  this.data.currentWeek = e;
279
- const n = T(e, s);
280
- this.setDate(n.getMonth(), n.getFullYear(), n.getDate()), typeof this.selectedCallBack == "function" && this.selectedCallBack(e);
279
+ const a = T(e, s);
280
+ this.setDate(a.getMonth(), a.getFullYear(), a.getDate()), typeof this.selectedCallBack == "function" && this.selectedCallBack(e);
281
281
  }
282
282
  /**
283
283
  * Renders the WeekCalendar component.
@@ -286,36 +286,36 @@ class Ze extends u {
286
286
  */
287
287
  render() {
288
288
  return o({ class: "week-calendar-container border rounded-md bg-background p-3" }, [
289
- ue({
289
+ ge({
290
290
  next: () => this.goToNextMonth(),
291
291
  previous: () => this.goToPreviousMonth()
292
292
  }),
293
- he({
293
+ fe({
294
294
  selectWeek: (e, s) => this.selectWeek(e, s)
295
295
  })
296
296
  ]);
297
297
  }
298
298
  }
299
- const ge = (t, e) => {
299
+ const pe = (t, e) => {
300
300
  const s = t.toggleAllSelectedRows();
301
301
  e.state.checked = !s;
302
- }, fe = (t) => P({ class: `cursor-pointer py-3 px-4 text-base w-10 ${t.class || ""}` }, [
303
- F((e) => new Z({ class: "mr-2", onChange: (s, n) => ge(e, n) }))
304
- ]), pe = ({ align: t, sortable: e, key: s, label: n, sort: a, class: i }) => {
302
+ }, me = (t) => P({ class: `cursor-pointer py-3 px-4 text-base w-10 ${t.class || ""}` }, [
303
+ H((e) => new te({ class: "mr-2", onChange: (s, a) => pe(e, a) }))
304
+ ]), we = ({ align: t, sortable: e, key: s, label: a, sort: n, class: i }) => {
305
305
  const l = t || "justify-start";
306
306
  return P({
307
307
  class: `cursor-pointer py-3 px-4 text-base ${i || ""}`,
308
- click: e && (() => a(s))
308
+ click: e && (() => n(s))
309
309
  }, [
310
310
  o({ class: `flex flex-auto w-full items-center ${l}` }, [
311
- v(n),
312
- e && E({ class: "ml-2", html: w.arrows.upDown })
311
+ v(a),
312
+ e && Q({ class: "ml-2", html: w.arrows.upDown })
313
313
  ])
314
314
  ]);
315
- }, me = (t) => H([
316
- Q({
315
+ }, j = (t) => X([
316
+ q({
317
317
  class: "text-muted-foreground border-b",
318
- map: [t.headers, (e) => e.label === "checkbox" ? fe({ toggle: t.toggle }) : pe({
318
+ map: [t.headers, (e) => e.label === "checkbox" ? me({ toggle: t.toggle }) : we({
319
319
  align: e.align,
320
320
  sortable: e.sortable,
321
321
  key: e.key,
@@ -323,13 +323,13 @@ const ge = (t, e) => {
323
323
  sort: t.sort
324
324
  })]
325
325
  })
326
- ]), we = ({ key: t, rows: e, selectRow: s, rowItem: n }) => new V({
326
+ ]), be = ({ key: t, rows: e, selectRow: s, rowItem: a }) => new _({
327
327
  cache: "table",
328
328
  key: t,
329
329
  items: e,
330
- rowItem: (a) => n(a, s),
330
+ rowItem: (n) => a(n, s),
331
331
  class: "divide-y divide-border"
332
- }), et = R(
332
+ }), ke = M(
333
333
  {
334
334
  /**
335
335
  * Initializes component data.
@@ -387,8 +387,8 @@ const ge = (t, e) => {
387
387
  selectRow(t) {
388
388
  const e = t.selected ?? !1;
389
389
  t.selected = !e;
390
- const s = this.data.get("selectedRows"), n = t.selected ? [...s, t] : s.filter((a) => a !== t);
391
- this.data.selectedRows = n, this.updateSelected();
390
+ const s = this.data.get("selectedRows"), a = t.selected ? [...s, t] : s.filter((n) => n !== t);
391
+ this.data.selectedRows = a, this.updateSelected();
392
392
  },
393
393
  /**
394
394
  * Renders the DataTable component.
@@ -399,12 +399,12 @@ const ge = (t, e) => {
399
399
  const t = this.rows, e = this.border !== !1 ? "border" : "";
400
400
  return o({ class: "w-full" }, [
401
401
  o({ class: `w-full rounded-md ${e} overflow-x-auto` }, [
402
- X({ class: "w-full" }, [
402
+ R({ class: "w-full" }, [
403
403
  // @ts-ignore
404
- this.headers && me({ headers: this.headers, sort: (s) => this.sortRows(s) }),
404
+ this.headers && j({ headers: this.headers, sort: (s) => this.sortRows(s) }),
405
405
  // @ts-ignore
406
406
  this.customHeader ?? null,
407
- we({
407
+ be({
408
408
  // @ts-ignore
409
409
  key: this.key,
410
410
  rows: t,
@@ -477,45 +477,75 @@ const ge = (t, e) => {
477
477
  this.data.selectedRows = [];
478
478
  }
479
479
  }
480
- ), be = h(({ name: t, email: e }) => o({ class: "min-w-0 flex-auto" }, [
480
+ );
481
+ class st extends ke {
482
+ /**
483
+ * Renders the DataTable component.
484
+ *
485
+ * @returns {object}
486
+ */
487
+ render() {
488
+ const e = this.rows, s = this.border !== !1 ? "border" : "";
489
+ return o({ class: "w-full" }, [
490
+ o({ class: `w-full rounded-md ${s} overflow-x-auto` }, [
491
+ R({ class: "w-full" }, [
492
+ // @ts-ignore
493
+ this.headers && j({ headers: this.headers, sort: (a) => this.sortRows(a) }),
494
+ // @ts-ignore
495
+ this.customHeader ?? null,
496
+ J({
497
+ // @ts-ignore
498
+ key: this.key,
499
+ rows: e,
500
+ // @ts-ignore
501
+ selectRow: this.selectRow.bind(this),
502
+ // @ts-ignore
503
+ rowItem: this.rowItem
504
+ })
505
+ ])
506
+ ])
507
+ ]);
508
+ }
509
+ }
510
+ const xe = h(({ name: t, email: e }) => o({ class: "min-w-0 flex-auto" }, [
481
511
  m({ class: "text-base font-semibold leading-6 m-0" }, t),
482
512
  m({ class: "truncate text-sm leading-5 text-muted-foreground m-0" }, e)
483
- ])), ke = () => o({ class: "flex items-center gap-x-1.5" }, [
513
+ ])), ye = () => o({ class: "flex items-center gap-x-1.5" }, [
484
514
  o({ class: "flex-none rounded-full bg-emerald-500/20 p-1" }, [
485
515
  o({ class: "h-1.5 w-1.5 rounded-full bg-emerald-500" })
486
516
  ]),
487
517
  m({ class: "text-xs leading-5 text-gray-500" }, "Online")
488
- ]), xe = (t) => m({ class: "text-xs leading-5 text-muted-foreground" }, [
518
+ ]), ve = (t) => m({ class: "text-xs leading-5 text-muted-foreground" }, [
489
519
  v("Last seen "),
490
- q({ datetime: t }, "3h ago")
491
- ]), ye = (t, e) => t === "online" ? ke() : xe(e), ve = h(({ role: t, lastSeen: e, status: s }) => o({ class: "hidden shrink-0 sm:flex sm:flex-col sm:items-end" }, [
520
+ K({ datetime: t }, "3h ago")
521
+ ]), De = (t, e) => t === "online" ? ye() : ve(e), Se = h(({ role: t, lastSeen: e, status: s }) => o({ class: "hidden shrink-0 sm:flex sm:flex-col sm:items-end" }, [
492
522
  m({ class: "text-sm leading-6 m-0" }, t),
493
- ye(s, e)
494
- ])), De = (t) => t.split(" ").map((s) => s[0]).join(""), Se = h((t) => D({ class: "fadeIn flex justify-between gap-x-6 py-4 px-4 rounded-md hover:bg-muted/50" }, [
523
+ De(s, e)
524
+ ])), Le = (t) => t.split(" ").map((s) => s[0]).join(""), Ce = h((t) => D({ class: "fadeIn flex justify-between gap-x-6 py-4 px-4 rounded-md hover:bg-muted/50" }, [
495
525
  o({ class: "flex min-w-0 gap-x-4" }, [
496
- se({ src: t.image, alt: t.name, fallbackText: De(t.name) }),
497
- be({ name: t.name, email: t.email })
526
+ ne({ src: t.image, alt: t.name, fallbackText: Le(t.name) }),
527
+ xe({ name: t.name, email: t.email })
498
528
  ]),
499
- ve({
529
+ Se({
500
530
  role: t.role,
501
531
  lastSeen: t.lastSeen,
502
532
  status: t.status
503
533
  })
504
- ])), tt = h((t) => new _({
534
+ ])), at = h((t) => new Z({
505
535
  cache: "list",
506
536
  key: "name",
507
537
  items: t.users,
508
538
  role: "list",
509
539
  class: "divide-y divide-border",
510
- rowItem: Se
511
- })), Le = (t, e) => e.includes(t), Ce = (t, e, s) => t.exact ? s === e : Le(e, s), Be = ({ text: t, href: e, exact: s, hidden: n }) => new M({
540
+ rowItem: Ce
541
+ })), Be = (t, e) => e.includes(t), Ie = (t, e, s) => t.exact ? s === e : Be(e, s), Te = ({ text: t, href: e, exact: s, hidden: a }) => new z({
512
542
  text: t,
513
543
  href: e,
514
544
  exact: s,
515
545
  dataSet: ["selected", ["state", !0, "active"]],
516
- class: `${n ? "hidden" : "inline-flex"} items-center justify-center whitespace-nowrap px-3 py-1.5 text-sm font-medium transition-all rounded-md focus:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:ring-ring focus-visible:ring-offset-background hover:bg-primary hover:text-primary-foreground disabled:opacity-50 disabled:pointer-events-none data-[state=active]:bg-primary data-[state=active]:text-primary-foreground data-[state=active]:shadow-sm`
546
+ class: `${a ? "hidden" : "inline-flex"} items-center justify-center whitespace-nowrap px-3 py-1.5 text-sm font-medium transition-all rounded-md focus:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:ring-ring focus-visible:ring-offset-background hover:bg-primary hover:text-primary-foreground disabled:opacity-50 disabled:pointer-events-none data-[state=active]:bg-primary data-[state=active]:text-primary-foreground data-[state=active]:shadow-sm`
517
547
  });
518
- class st extends u {
548
+ class nt extends u {
519
549
  /**
520
550
  * This will declare the props for the compiler.
521
551
  *
@@ -568,10 +598,10 @@ class st extends u {
568
598
  updateLinks(e) {
569
599
  let s = !1;
570
600
  this.deactivateAllLinks();
571
- for (const n of this.links) {
572
- if (!n.rendered)
601
+ for (const a of this.links) {
602
+ if (!a.rendered)
573
603
  continue;
574
- Ce(n, n.getLinkPath(), e) ? (this.updateLink(n, !0), s = !0) : this.updateLink(n, !1);
604
+ Ie(a, a.getLinkPath(), e) ? (this.updateLink(a, !0), s = !0) : this.updateLink(a, !1);
575
605
  }
576
606
  !s && this.links[0] && this.updateLink(this.links[0], !0);
577
607
  }
@@ -600,8 +630,8 @@ class st extends u {
600
630
  * @param {object} option
601
631
  * @returns {object}
602
632
  */
603
- addLink({ label: e, href: s, exact: n, hidden: a }) {
604
- const i = Be({ text: e, href: s, exact: n, hidden: a });
633
+ addLink({ label: e, href: s, exact: a, hidden: n }) {
634
+ const i = Te({ text: e, href: s, exact: a, hidden: n });
605
635
  return this.links.push(i), i;
606
636
  }
607
637
  /**
@@ -613,7 +643,7 @@ class st extends u {
613
643
  this.links = [];
614
644
  }
615
645
  }
616
- const nt = h((t) => {
646
+ const it = h((t) => {
617
647
  const e = t.margin || "m-4 ml-0";
618
648
  return o({ class: `flex-none ${e}` }, [
619
649
  C({
@@ -627,11 +657,11 @@ const nt = h((t) => {
627
657
  t.backUrl && app.navigate(t.backUrl);
628
658
  }
629
659
  }, [
630
- N(w.arrows.left)
660
+ $(w.arrows.left)
631
661
  ])
632
662
  ]);
633
663
  });
634
- class $ extends u {
664
+ class A extends u {
635
665
  /**
636
666
  * This will declare the props for the compiler.
637
667
  *
@@ -718,13 +748,13 @@ class $ extends u {
718
748
  return this.children;
719
749
  }
720
750
  }
721
- z.addType("dockableOverlay", (t) => {
751
+ N.addType("dockableOverlay", (t) => {
722
752
  if (!t)
723
753
  return;
724
754
  const e = t.component;
725
755
  e && e.rendered === !0 && e.state.docked === !1 && e.destroy();
726
756
  });
727
- class at extends $ {
757
+ class ot extends A {
728
758
  /**
729
759
  * This will stop presistence.
730
760
  *
@@ -746,8 +776,8 @@ class at extends $ {
746
776
  ["loading", {
747
777
  loading: !0
748
778
  }],
749
- ["docked", (s, n) => {
750
- s ? (n.className = this.getDockedClassName(), e.appendChild(n), document.documentElement.style.overflowY = "auto") : (n.className = this.getClassName(), app.root.appendChild(n), document.documentElement.style.overflowY = "hidden");
779
+ ["docked", (s, a) => {
780
+ s ? (a.className = this.getDockedClassName(), e.appendChild(a), document.documentElement.style.overflowY = "auto") : (a.className = this.getClassName(), app.root.appendChild(a), document.documentElement.style.overflowY = "hidden");
751
781
  }]
752
782
  ]
753
783
  },
@@ -790,7 +820,7 @@ class at extends $ {
790
820
  * @returns {void}
791
821
  */
792
822
  afterSetup() {
793
- z.add(
823
+ N.add(
794
824
  this.container,
795
825
  "dockableOverlay",
796
826
  {
@@ -833,7 +863,7 @@ class at extends $ {
833
863
  document.documentElement.style.overflowY = "auto";
834
864
  }
835
865
  }
836
- class it extends $ {
866
+ class lt extends A {
837
867
  /**
838
868
  * This will get the overlay type.
839
869
  *
@@ -852,7 +882,7 @@ class it extends $ {
852
882
  this.container = e, this.initialize();
853
883
  }
854
884
  }
855
- const Ie = h(({ index: t, click: e, state: s }, n) => D({
885
+ const We = h(({ index: t, click: e, state: s }, a) => D({
856
886
  class: "p-2 cursor-pointer hover:bg-muted/50",
857
887
  onState: [
858
888
  [s, "selectedIndex", {
@@ -861,11 +891,11 @@ const Ie = h(({ index: t, click: e, state: s }, n) => D({
861
891
  }]
862
892
  ],
863
893
  click: () => e(t)
864
- }, n)), Te = h(({ selectOption: t, state: e }) => b({
894
+ }, a)), Pe = h(({ selectOption: t, state: e }) => b({
865
895
  class: "border rounded-md list-none m-0 p-0 max-h-[400px] overflow-y-auto",
866
- for: ["filteredOptions", (s, n) => Ie({ index: n, click: t, state: e }, s.label)]
867
- })), We = h((t) => o({ class: "relative flex items-center" }, [
868
- ee({
896
+ for: ["filteredOptions", (s, a) => We({ index: a, click: t, state: e }, s.label)]
897
+ })), Re = h((t) => o({ class: "relative flex items-center" }, [
898
+ se({
869
899
  cache: "input",
870
900
  placeholder: t.placeholder ?? "Search...",
871
901
  bind: [t.state, "searchQuery"],
@@ -876,22 +906,22 @@ const Ie = h(({ index: t, click: e, state: s }, n) => D({
876
906
  keydown: (e) => typeof t.handleKeyDown == "function" && t.handleKeyDown(e)
877
907
  }),
878
908
  t.icon && o({ class: "absolute right-0 mr-2" }, [
879
- N(t.icon)
909
+ $(t.icon)
880
910
  ])
881
- ])), Pe = (t) => o({
911
+ ])), Oe = (t) => o({
882
912
  class: "relative flex fle-auto flex-col",
883
- onState: ["open", (e, s, n) => {
913
+ onState: ["open", (e, s, a) => {
884
914
  if (e)
885
- return new ne({
915
+ return new ie({
886
916
  cache: "dropdown",
887
- parent: n,
888
- button: n.input,
917
+ parent: a,
918
+ button: a.input,
889
919
  size: "xl"
890
920
  }, [
891
- Te(t)
921
+ Pe(t)
892
922
  ]);
893
923
  }]
894
- }), ot = R(
924
+ }), rt = M(
895
925
  {
896
926
  /**
897
927
  * This will set up the data object.
@@ -926,7 +956,7 @@ const Ie = h(({ index: t, click: e, state: s }, n) => D({
926
956
  const t = this.data.filteredOptions;
927
957
  let { searchQuery: e } = this.state;
928
958
  e = e.toLowerCase();
929
- const s = t.findIndex((n) => n.label.toLowerCase() === e);
959
+ const s = t.findIndex((a) => a.label.toLowerCase() === e);
930
960
  s >= 0 && (this.state.selectedIndex = s);
931
961
  },
932
962
  /**
@@ -988,7 +1018,7 @@ const Ie = h(({ index: t, click: e, state: s }, n) => D({
988
1018
  */
989
1019
  render() {
990
1020
  return o({ class: "relative w-full max-w-md" }, [
991
- We({
1021
+ Re({
992
1022
  // @ts-ignore
993
1023
  state: this.state,
994
1024
  // @ts-ignore
@@ -1000,7 +1030,7 @@ const Ie = h(({ index: t, click: e, state: s }, n) => D({
1000
1030
  // @ts-ignore
1001
1031
  handleKeyDown: this.handleKeyDown.bind(this)
1002
1032
  }),
1003
- Pe({
1033
+ Oe({
1004
1034
  // @ts-ignore
1005
1035
  state: this.state,
1006
1036
  // @ts-ignore
@@ -1011,7 +1041,7 @@ const Ie = h(({ index: t, click: e, state: s }, n) => D({
1011
1041
  ]);
1012
1042
  }
1013
1043
  }
1014
- ), Oe = (t) => D(
1044
+ ), Me = (t) => D(
1015
1045
  {
1016
1046
  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",
1017
1047
  dataSet: ["selected", ["state", t.value, "active"]]
@@ -1023,10 +1053,10 @@ const Ie = h(({ index: t, click: e, state: s }, n) => D({
1023
1053
  click: (e) => t.callBack(t.value)
1024
1054
  }, t.label)
1025
1055
  ]
1026
- ), Re = (t, e) => (t.callBack = e, Oe(t)), Me = (t) => S({ class: `tab items-center justify-center rounded-md bg-muted p-1 text-muted-foreground ${t.class}` }, [
1027
- b({ class: "flex flex-auto flex-row", map: [t.options, (e) => Re(e, t.callBack)] })
1056
+ ), ze = (t, e) => (t.callBack = e, Me(t)), Ne = (t) => S({ class: `tab items-center justify-center rounded-md bg-muted p-1 text-muted-foreground ${t.class}` }, [
1057
+ b({ class: "flex flex-auto flex-row", map: [t.options, (e) => ze(e, t.callBack)] })
1028
1058
  ]);
1029
- class lt extends u {
1059
+ class ct extends u {
1030
1060
  /**
1031
1061
  * This will declare the props for the compiler.
1032
1062
  *
@@ -1043,7 +1073,7 @@ class lt extends u {
1043
1073
  render() {
1044
1074
  const e = this.select.bind(this);
1045
1075
  return o({ class: "" }, [
1046
- Me({
1076
+ Ne({
1047
1077
  class: this.class,
1048
1078
  options: this.options,
1049
1079
  callBack: e
@@ -1091,11 +1121,11 @@ class lt extends u {
1091
1121
  const s = this.options;
1092
1122
  if (!s || s.length < 1)
1093
1123
  return;
1094
- const n = s[0];
1095
- for (const a of s)
1096
- if (a.value === e)
1097
- return a.layout;
1098
- return n.layout;
1124
+ const a = s[0];
1125
+ for (const n of s)
1126
+ if (n.value === e)
1127
+ return n.layout;
1128
+ return a.layout;
1099
1129
  }
1100
1130
  /**
1101
1131
  * This will setup the states.
@@ -1107,14 +1137,14 @@ class lt extends u {
1107
1137
  return {
1108
1138
  selected: {
1109
1139
  state: this.getFirstValue(),
1110
- callBack(n) {
1111
- s === "function" && e(n);
1140
+ callBack(a) {
1141
+ s === "function" && e(a);
1112
1142
  }
1113
1143
  }
1114
1144
  };
1115
1145
  }
1116
1146
  }
1117
- const ze = (t) => D(
1147
+ const $e = (t) => D(
1118
1148
  {
1119
1149
  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",
1120
1150
  dataSet: ["selected", ["state", t.value, "active"]]
@@ -1127,10 +1157,10 @@ const ze = (t) => D(
1127
1157
  disabled: t.disabled
1128
1158
  }, t.label)
1129
1159
  ]
1130
- ), Ne = (t, e) => (t.callBack = e, ze(t)), $e = (t) => S({ class: `tab items-center justify-center rounded-md bg-muted p-1 text-muted-foreground ${t.class}` }, [
1131
- b({ class: "flex flex-auto flex-row", map: [t.options, (e) => Ne(e, t.callBack)] })
1160
+ ), je = (t, e) => (t.callBack = e, $e(t)), Ae = (t) => S({ class: `tab items-center justify-center rounded-md bg-muted p-1 text-muted-foreground ${t.class}` }, [
1161
+ b({ class: "flex flex-auto flex-row", map: [t.options, (e) => je(e, t.callBack)] })
1132
1162
  ]);
1133
- class rt extends u {
1163
+ class dt extends u {
1134
1164
  /**
1135
1165
  * This will declare the props for the compiler.
1136
1166
  *
@@ -1146,7 +1176,7 @@ class rt extends u {
1146
1176
  */
1147
1177
  render() {
1148
1178
  const e = this.select.bind(this);
1149
- return $e({
1179
+ return Ae({
1150
1180
  class: this.class,
1151
1181
  options: this.options,
1152
1182
  callBack: e
@@ -1173,17 +1203,17 @@ class rt extends u {
1173
1203
  };
1174
1204
  }
1175
1205
  }
1176
- const je = (t, e) => new RegExp(`${t}($|/|\\.).*`).test(e), Ae = (t, e) => {
1206
+ const Ue = (t, e) => new RegExp(`${t}($|/|\\.).*`).test(e), Ye = (t, e) => {
1177
1207
  const s = t.getLinkPath();
1178
- return t.exact ? e === s : je(s, e);
1179
- }, Ue = ({ text: t, href: e, exact: s }) => new M({
1208
+ return t.exact ? e === s : Ue(s, e);
1209
+ }, Fe = ({ text: t, href: e, exact: s }) => new z({
1180
1210
  text: t,
1181
1211
  href: e,
1182
1212
  exact: s,
1183
1213
  dataSet: ["selected", ["state", !0, "active"]],
1184
1214
  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"
1185
1215
  });
1186
- class Ye extends u {
1216
+ class Ee extends u {
1187
1217
  /**
1188
1218
  * This will declare the props for the compiler.
1189
1219
  *
@@ -1231,14 +1261,14 @@ class Ye extends u {
1231
1261
  * @returns {void}
1232
1262
  */
1233
1263
  updateLinks(e) {
1234
- let s = !1, n = this.links[0];
1264
+ let s = !1, a = this.links[0];
1235
1265
  this.deactivateAllLinks();
1236
- for (const a of this.links)
1237
- if (a.rendered !== !1 && (s = Ae(a, e), s === !0)) {
1238
- this.updateLink(a, !0);
1266
+ for (const n of this.links)
1267
+ if (n.rendered !== !1 && (s = Ye(n, e), s === !0)) {
1268
+ this.updateLink(n, !0);
1239
1269
  break;
1240
1270
  }
1241
- s !== !0 && n && this.updateLink(n, !0);
1271
+ s !== !0 && a && this.updateLink(a, !0);
1242
1272
  }
1243
1273
  /**
1244
1274
  * This will deactivate all links.
@@ -1265,9 +1295,9 @@ class Ye extends u {
1265
1295
  * @param {object} option
1266
1296
  * @returns {object}
1267
1297
  */
1268
- addLink({ label: e, href: s, exact: n }) {
1269
- const a = Ue({ text: e, href: s, exact: n });
1270
- return this.links.push(a), a;
1298
+ addLink({ label: e, href: s, exact: a }) {
1299
+ const n = Fe({ text: e, href: s, exact: a });
1300
+ return this.links.push(n), n;
1271
1301
  }
1272
1302
  /**
1273
1303
  * This will remove all the links.
@@ -1278,7 +1308,7 @@ class Ye extends u {
1278
1308
  this.links = [];
1279
1309
  }
1280
1310
  }
1281
- class ct extends u {
1311
+ class ht extends u {
1282
1312
  /**
1283
1313
  * This will declare the props for the compiler.
1284
1314
  *
@@ -1294,7 +1324,7 @@ class ct extends u {
1294
1324
  */
1295
1325
  render() {
1296
1326
  return o({ class: "tab-panel" }, [
1297
- new Ye({
1327
+ new Ee({
1298
1328
  class: this.class,
1299
1329
  options: this.options
1300
1330
  }),
@@ -1311,9 +1341,9 @@ class ct extends u {
1311
1341
  */
1312
1342
  addGroup() {
1313
1343
  let e;
1314
- const s = [], n = this.options;
1315
- for (let a = 0, i = n.length; a < i; a++)
1316
- e = n[a], s.push(
1344
+ const s = [], a = this.options;
1345
+ for (let n = 0, i = a.length; n < i; n++)
1346
+ e = a[n], s.push(
1317
1347
  {
1318
1348
  uri: e.uri || e.href,
1319
1349
  component: e.component,
@@ -1324,7 +1354,7 @@ class ct extends u {
1324
1354
  return s;
1325
1355
  }
1326
1356
  }
1327
- class Fe extends u {
1357
+ class He extends u {
1328
1358
  /**
1329
1359
  * Runs before rendering, sets up defaults, a timer for drawing,
1330
1360
  * and basic canvas properties.
@@ -1334,7 +1364,7 @@ class Fe extends u {
1334
1364
  onCreated() {
1335
1365
  this.lineWidth = this.lineWidth || 3, this.lineColor = this.lineColor || "#000000", this.canvas = null, this.ctx = null, this.status = "stopped";
1336
1366
  const e = 1e3 / 60;
1337
- this.timer = new J(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";
1367
+ this.timer = new ee(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";
1338
1368
  }
1339
1369
  /**
1340
1370
  * Renders a <canvas> element.
@@ -1342,7 +1372,7 @@ class Fe extends u {
1342
1372
  * @returns {object} Layout definition for the canvas.
1343
1373
  */
1344
1374
  render() {
1345
- return K({
1375
+ return G({
1346
1376
  style: "touch-action: none; -webkit-user-select: none; -webkit-touch-callout: none;"
1347
1377
  });
1348
1378
  }
@@ -1372,12 +1402,12 @@ class Fe extends u {
1372
1402
  * @returns {Array} An array of [eventName, element, callback] definitions.
1373
1403
  */
1374
1404
  setupEvents() {
1375
- const e = this.panel, s = this.pointerPosition.bind(this), n = this.pointerUp.bind(this), a = this.pointerDown.bind(this), i = this.resize.bind(this), l = { passive: !1 };
1405
+ const e = this.panel, s = this.pointerPosition.bind(this), a = this.pointerUp.bind(this), n = this.pointerDown.bind(this), i = this.resize.bind(this), l = { passive: !1 };
1376
1406
  return [
1377
1407
  ["pointermove", e, s, l],
1378
- ["pointerup", e, n],
1379
- ["pointerdown", e, a, l],
1380
- ["pointerout", e, n],
1408
+ ["pointerup", e, a],
1409
+ ["pointerdown", e, n, l],
1410
+ ["pointerout", e, a],
1381
1411
  ["resize", window, i]
1382
1412
  ];
1383
1413
  }
@@ -1388,14 +1418,14 @@ class Fe extends u {
1388
1418
  * @returns {void}
1389
1419
  */
1390
1420
  getEventPosition(e) {
1391
- let s, n;
1392
- const a = this.canvas, i = a.width / parseInt(a.style.width), l = a.getBoundingClientRect();
1421
+ let s, a;
1422
+ const n = this.canvas, i = n.width / parseInt(n.style.width), l = n.getBoundingClientRect();
1393
1423
  if (e.touches && e.touches.length) {
1394
- const g = e.touches[0];
1395
- s = g.clientX, n = g.clientY;
1424
+ const f = e.touches[0];
1425
+ s = f.clientX, a = f.clientY;
1396
1426
  } else
1397
- s = e.x || e.clientX, n = e.y || e.clientY;
1398
- const d = parseInt((s - l.left) * i), c = parseInt((n - l.top) * i);
1427
+ s = e.x || e.clientX, a = e.y || e.clientY;
1428
+ const d = parseInt((s - l.left) * i), c = parseInt((a - l.top) * i);
1399
1429
  this.mouse.x = d, this.mouse.y = c;
1400
1430
  }
1401
1431
  /**
@@ -1407,8 +1437,8 @@ class Fe extends u {
1407
1437
  */
1408
1438
  pointerDown(e) {
1409
1439
  e.preventDefault(), e.stopPropagation(), this.getEventPosition(e);
1410
- const { ctx: s, mouse: n } = this;
1411
- s.beginPath(), s.moveTo(n.x, n.y), n.status = "down", this.startTimer();
1440
+ const { ctx: s, mouse: a } = this;
1441
+ s.beginPath(), s.moveTo(a.x, a.y), a.status = "down", this.startTimer();
1412
1442
  }
1413
1443
  /**
1414
1444
  * Called when the pointer goes up or leaves the canvas area.
@@ -1436,12 +1466,12 @@ class Fe extends u {
1436
1466
  * @returns {void}
1437
1467
  */
1438
1468
  resize() {
1439
- const { canvas: e, ctx: s } = this, n = e.toDataURL();
1440
- if (this.scale(), this.setupBackground(s), n !== "data:,") {
1441
- const a = new window.Image();
1442
- B.on("load", a, function i() {
1443
- s.drawImage(a, 0, 0), B.off("load", a, i);
1444
- }), a.src = n;
1469
+ const { canvas: e, ctx: s } = this, a = e.toDataURL();
1470
+ if (this.scale(), this.setupBackground(s), a !== "data:,") {
1471
+ const n = new window.Image();
1472
+ B.on("load", n, function i() {
1473
+ s.drawImage(n, 0, 0), B.off("load", n, i);
1474
+ }), n.src = a;
1445
1475
  }
1446
1476
  this.draw();
1447
1477
  }
@@ -1470,10 +1500,10 @@ class Fe extends u {
1470
1500
  * @returns {void}
1471
1501
  */
1472
1502
  scale() {
1473
- const e = this.canvas, s = this.container, n = I.getSize(s), a = this.targetSize, i = a.width, l = a.height;
1503
+ const e = this.canvas, s = this.container, a = I.getSize(s), n = this.targetSize, i = n.width, l = n.height;
1474
1504
  let d = i + "px", c = l + "px";
1475
- if (this.width = e.width = i, this.height = e.height = l, n.width !== 0 && n.height !== 0) {
1476
- const g = n.width, f = n.height, r = g / i, p = f / l, k = Math.min(r, p);
1505
+ if (this.width = e.width = i, this.height = e.height = l, a.width !== 0 && a.height !== 0) {
1506
+ const f = a.width, g = a.height, r = f / i, p = g / l, k = Math.min(r, p);
1477
1507
  d = i * k + "px", c = l * k + "px";
1478
1508
  }
1479
1509
  e.style.width = d, e.style.height = c;
@@ -1496,8 +1526,8 @@ class Fe extends u {
1496
1526
  drawBottomLine(e) {
1497
1527
  const s = this.canvas;
1498
1528
  e.globalAlpha = 1, e.shadowBlur = 0;
1499
- const n = this.margin.x, a = this.height - this.margin.y;
1500
- e.beginPath(), e.moveTo(n, a), e.lineTo(s.width - this.margin.x, a), e.lineWidth = this.baseLineWidth, e.strokeStyle = this.baseStrokeColor, e.stroke(), e.closePath();
1529
+ const a = this.margin.x, n = this.height - this.margin.y;
1530
+ e.beginPath(), e.moveTo(a, n), e.lineTo(s.width - this.margin.x, n), e.lineWidth = this.baseLineWidth, e.strokeStyle = this.baseStrokeColor, e.stroke(), e.closePath();
1501
1531
  }
1502
1532
  /**
1503
1533
  * Adds a line to the current path, updating the 'signed' status.
@@ -1508,10 +1538,10 @@ class Fe extends u {
1508
1538
  * @param {string} color The stroke color.
1509
1539
  * @returns {void}
1510
1540
  */
1511
- addLine(e, s, n, a) {
1541
+ addLine(e, s, a, n) {
1512
1542
  this.signed || (this.signed = !0);
1513
- const i = Math.round(s), l = Math.round(n);
1514
- e.lineWidth = this.lineWidth, e.strokeStyle = a, e.lineTo(i, l), e.stroke();
1543
+ const i = Math.round(s), l = Math.round(a);
1544
+ e.lineWidth = this.lineWidth, e.strokeStyle = n, e.lineTo(i, l), e.stroke();
1515
1545
  }
1516
1546
  /**
1517
1547
  * Clears the canvas, sets signed to false, and re-initializes
@@ -1550,7 +1580,7 @@ class Fe extends u {
1550
1580
  this.timer.stop(), this.status = "stopped";
1551
1581
  }
1552
1582
  }
1553
- class dt extends u {
1583
+ class ut extends u {
1554
1584
  /**
1555
1585
  * Sets up default properties for the signature panel.
1556
1586
  *
@@ -1567,7 +1597,7 @@ class dt extends u {
1567
1597
  */
1568
1598
  render() {
1569
1599
  return o({ class: "signature-panel relative flex flex-auto overflow-hidden select-none" }, [
1570
- te({
1600
+ ae({
1571
1601
  cache: "hiddenInput",
1572
1602
  required: !0,
1573
1603
  bind: this.path + ".data"
@@ -1579,7 +1609,7 @@ class dt extends u {
1579
1609
  click: this.reset.bind(this)
1580
1610
  })
1581
1611
  ]),
1582
- new Fe({
1612
+ new He({
1583
1613
  cache: "canvasLayer",
1584
1614
  margin: this.margin,
1585
1615
  targetSize: this.targetSize,
@@ -1629,33 +1659,34 @@ class dt extends u {
1629
1659
  }
1630
1660
  }
1631
1661
  export {
1632
- nt as B,
1633
- fe as C,
1634
- we as D,
1635
- pe as H,
1636
- it as I,
1637
- st as N,
1638
- $ as O,
1639
- Ve as P,
1640
- ot as S,
1641
- me as T,
1642
- Se as U,
1643
- Ze as W,
1644
- le as a,
1662
+ it as B,
1663
+ me as C,
1664
+ be as D,
1665
+ we as H,
1666
+ lt as I,
1667
+ nt as N,
1668
+ A as O,
1669
+ Je as P,
1670
+ st as S,
1671
+ j as T,
1672
+ Ce as U,
1673
+ tt as W,
1674
+ ce as a,
1645
1675
  T as b,
1646
- ie as c,
1647
- _e as d,
1648
- Je as e,
1649
- ce as f,
1650
- oe as g,
1651
- he as h,
1652
- ue as i,
1653
- et as j,
1654
- tt as k,
1655
- at as l,
1656
- lt as m,
1657
- rt as n,
1658
- Ye as o,
1659
- ct as p,
1660
- dt as q
1676
+ le as c,
1677
+ Ze as d,
1678
+ et as e,
1679
+ he as f,
1680
+ re as g,
1681
+ fe as h,
1682
+ ge as i,
1683
+ ke as j,
1684
+ at as k,
1685
+ ot as l,
1686
+ rt as m,
1687
+ ct as n,
1688
+ dt as o,
1689
+ Ee as p,
1690
+ ht as q,
1691
+ ut as r
1661
1692
  };