@aitronos/freddy-plugins 0.2.5 → 0.2.7
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/CHANGELOG.md +8 -0
- package/dist/index.cjs +2 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +13 -21
- package/dist/index.js +126 -133
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -192,7 +192,7 @@ const z0 = {
|
|
|
192
192
|
}
|
|
193
193
|
}), M = (a) => {
|
|
194
194
|
!e.disabled && !e.loading && l("click", a);
|
|
195
|
-
},
|
|
195
|
+
}, C = (a) => {
|
|
196
196
|
a.stopPropagation(), !e.disabled && !e.loading && l("hoverIconClick", a);
|
|
197
197
|
}, v = () => {
|
|
198
198
|
c.value = !0;
|
|
@@ -224,7 +224,7 @@ const z0 = {
|
|
|
224
224
|
size: a.leftIcon || a.hoverIcon ? void 0 : A.value,
|
|
225
225
|
color: a.leftIcon || a.hoverIcon ? void 0 : g.value,
|
|
226
226
|
class: "button-icon button-icon-center",
|
|
227
|
-
onClick: B[0] || (B[0] = (U) => c.value && a.hoverIcon ?
|
|
227
|
+
onClick: B[0] || (B[0] = (U) => c.value && a.hoverIcon ? C(U) : void 0)
|
|
228
228
|
}, null, 8, ["size", "color"])) : a.loading ? (s(), i(l1, { key: 2 }, [
|
|
229
229
|
B[2] || (B[2] = n("span", {
|
|
230
230
|
class: "button-spinner",
|
|
@@ -240,7 +240,7 @@ const z0 = {
|
|
|
240
240
|
key: 0,
|
|
241
241
|
class: "button-icon button-icon-left button-hover-icon",
|
|
242
242
|
"aria-hidden": "true",
|
|
243
|
-
onClick:
|
|
243
|
+
onClick: C
|
|
244
244
|
})) : a.leftIcon ? (s(), D(e1(a.leftIcon), {
|
|
245
245
|
key: 1,
|
|
246
246
|
class: "button-icon button-icon-left",
|
|
@@ -274,7 +274,7 @@ const z0 = {
|
|
|
274
274
|
size: a.leftIcon || a.hoverIcon ? void 0 : A.value,
|
|
275
275
|
color: a.leftIcon || a.hoverIcon ? void 0 : g.value,
|
|
276
276
|
class: "button-icon button-icon-center",
|
|
277
|
-
onClick: B[1] || (B[1] = (U) => c.value && a.hoverIcon ?
|
|
277
|
+
onClick: B[1] || (B[1] = (U) => c.value && a.hoverIcon ? C(U) : void 0)
|
|
278
278
|
}, null, 8, ["size", "color"])) : a.loading ? (s(), i(l1, { key: 2 }, [
|
|
279
279
|
B[3] || (B[3] = n("span", {
|
|
280
280
|
class: "button-spinner",
|
|
@@ -290,7 +290,7 @@ const z0 = {
|
|
|
290
290
|
key: 0,
|
|
291
291
|
class: "button-icon button-icon-left button-hover-icon",
|
|
292
292
|
"aria-hidden": "true",
|
|
293
|
-
onClick:
|
|
293
|
+
onClick: C
|
|
294
294
|
})) : a.leftIcon ? (s(), D(e1(a.leftIcon), {
|
|
295
295
|
key: 1,
|
|
296
296
|
class: "button-icon button-icon-left",
|
|
@@ -1161,7 +1161,7 @@ const tn = /* @__PURE__ */ p(Ot, [["render", Ht]]), Vt = "data:image/png;base64,
|
|
|
1161
1161
|
return Object.fromEntries(
|
|
1162
1162
|
Array.from({ length: e }, (c, d) => {
|
|
1163
1163
|
var M;
|
|
1164
|
-
const A = d + 1, g = ((M = t.find((
|
|
1164
|
+
const A = d + 1, g = ((M = t.find((C) => C[A])) == null ? void 0 : M[A]) || 0;
|
|
1165
1165
|
return [A, g];
|
|
1166
1166
|
})
|
|
1167
1167
|
);
|
|
@@ -1243,9 +1243,9 @@ const jt = "Feb", J2 = 2023, cn = Pt(
|
|
|
1243
1243
|
(/* @__PURE__ */ new Date(`${jt} 1, ${J2}`)).getMonth() + 1,
|
|
1244
1244
|
J2
|
|
1245
1245
|
), pn = (o, t, e) => {
|
|
1246
|
-
const l = (M) => M.match(/\w\w/g).map((
|
|
1247
|
-
return Array.from({ length: e }, (M,
|
|
1248
|
-
const v =
|
|
1246
|
+
const l = (M) => M.match(/\w\w/g).map((C) => parseInt(C, 16)), c = (M) => `#${M.map((C) => C.toString(16).padStart(2, "0")).join("")}`, d = l(o), A = l(t);
|
|
1247
|
+
return Array.from({ length: e }, (M, C) => {
|
|
1248
|
+
const v = C / (e - 1), m = d.map(
|
|
1249
1249
|
(a, B) => Math.round(a + v * (A[B] - a))
|
|
1250
1250
|
);
|
|
1251
1251
|
return c(m);
|
|
@@ -1421,40 +1421,40 @@ function n5() {
|
|
|
1421
1421
|
function t(l) {
|
|
1422
1422
|
if (l = l || {}, l.circles) return e(l);
|
|
1423
1423
|
const c = /* @__PURE__ */ new Map();
|
|
1424
|
-
if (c.set(Date, (
|
|
1425
|
-
for (const
|
|
1426
|
-
c.set(
|
|
1424
|
+
if (c.set(Date, (C) => new Date(C)), c.set(Map, (C, v) => new Map(A(Array.from(C), v))), c.set(Set, (C, v) => new Set(A(Array.from(C), v))), l.constructorHandlers)
|
|
1425
|
+
for (const C of l.constructorHandlers)
|
|
1426
|
+
c.set(C[0], C[1]);
|
|
1427
1427
|
let d = null;
|
|
1428
1428
|
return l.proto ? M : g;
|
|
1429
|
-
function A(
|
|
1430
|
-
const m = Object.keys(
|
|
1429
|
+
function A(C, v) {
|
|
1430
|
+
const m = Object.keys(C), a = new Array(m.length);
|
|
1431
1431
|
for (let B = 0; B < m.length; B++) {
|
|
1432
|
-
const k = m[B], U =
|
|
1432
|
+
const k = m[B], U = C[k];
|
|
1433
1433
|
typeof U != "object" || U === null ? a[k] = U : U.constructor !== Object && (d = c.get(U.constructor)) ? a[k] = d(U, v) : ArrayBuffer.isView(U) ? a[k] = o(U) : a[k] = v(U);
|
|
1434
1434
|
}
|
|
1435
1435
|
return a;
|
|
1436
1436
|
}
|
|
1437
|
-
function g(
|
|
1438
|
-
if (typeof
|
|
1439
|
-
if (Array.isArray(
|
|
1440
|
-
if (
|
|
1441
|
-
return d(
|
|
1437
|
+
function g(C) {
|
|
1438
|
+
if (typeof C != "object" || C === null) return C;
|
|
1439
|
+
if (Array.isArray(C)) return A(C, g);
|
|
1440
|
+
if (C.constructor !== Object && (d = c.get(C.constructor)))
|
|
1441
|
+
return d(C, g);
|
|
1442
1442
|
const v = {};
|
|
1443
|
-
for (const m in
|
|
1444
|
-
if (Object.hasOwnProperty.call(
|
|
1445
|
-
const a =
|
|
1443
|
+
for (const m in C) {
|
|
1444
|
+
if (Object.hasOwnProperty.call(C, m) === !1) continue;
|
|
1445
|
+
const a = C[m];
|
|
1446
1446
|
typeof a != "object" || a === null ? v[m] = a : a.constructor !== Object && (d = c.get(a.constructor)) ? v[m] = d(a, g) : ArrayBuffer.isView(a) ? v[m] = o(a) : v[m] = g(a);
|
|
1447
1447
|
}
|
|
1448
1448
|
return v;
|
|
1449
1449
|
}
|
|
1450
|
-
function M(
|
|
1451
|
-
if (typeof
|
|
1452
|
-
if (Array.isArray(
|
|
1453
|
-
if (
|
|
1454
|
-
return d(
|
|
1450
|
+
function M(C) {
|
|
1451
|
+
if (typeof C != "object" || C === null) return C;
|
|
1452
|
+
if (Array.isArray(C)) return A(C, M);
|
|
1453
|
+
if (C.constructor !== Object && (d = c.get(C.constructor)))
|
|
1454
|
+
return d(C, M);
|
|
1455
1455
|
const v = {};
|
|
1456
|
-
for (const m in
|
|
1457
|
-
const a =
|
|
1456
|
+
for (const m in C) {
|
|
1457
|
+
const a = C[m];
|
|
1458
1458
|
typeof a != "object" || a === null ? v[m] = a : a.constructor !== Object && (d = c.get(a.constructor)) ? v[m] = d(a, M) : ArrayBuffer.isView(a) ? v[m] = o(a) : v[m] = M(a);
|
|
1459
1459
|
}
|
|
1460
1460
|
return v;
|
|
@@ -1466,7 +1466,7 @@ function n5() {
|
|
|
1466
1466
|
for (const m of l.constructorHandlers)
|
|
1467
1467
|
A.set(m[0], m[1]);
|
|
1468
1468
|
let g = null;
|
|
1469
|
-
return l.proto ? v :
|
|
1469
|
+
return l.proto ? v : C;
|
|
1470
1470
|
function M(m, a) {
|
|
1471
1471
|
const B = Object.keys(m), k = new Array(B.length);
|
|
1472
1472
|
for (let U = 0; U < B.length; U++) {
|
|
@@ -1484,11 +1484,11 @@ function n5() {
|
|
|
1484
1484
|
}
|
|
1485
1485
|
return k;
|
|
1486
1486
|
}
|
|
1487
|
-
function
|
|
1487
|
+
function C(m) {
|
|
1488
1488
|
if (typeof m != "object" || m === null) return m;
|
|
1489
|
-
if (Array.isArray(m)) return M(m,
|
|
1489
|
+
if (Array.isArray(m)) return M(m, C);
|
|
1490
1490
|
if (m.constructor !== Object && (g = A.get(m.constructor)))
|
|
1491
|
-
return g(m,
|
|
1491
|
+
return g(m, C);
|
|
1492
1492
|
const a = {};
|
|
1493
1493
|
c.push(m), d.push(a);
|
|
1494
1494
|
for (const B in m) {
|
|
@@ -1497,12 +1497,12 @@ function n5() {
|
|
|
1497
1497
|
if (typeof k != "object" || k === null)
|
|
1498
1498
|
a[B] = k;
|
|
1499
1499
|
else if (k.constructor !== Object && (g = A.get(k.constructor)))
|
|
1500
|
-
a[B] = g(k,
|
|
1500
|
+
a[B] = g(k, C);
|
|
1501
1501
|
else if (ArrayBuffer.isView(k))
|
|
1502
1502
|
a[B] = o(k);
|
|
1503
1503
|
else {
|
|
1504
1504
|
const U = c.indexOf(k);
|
|
1505
|
-
U !== -1 ? a[B] = d[U] : a[B] =
|
|
1505
|
+
U !== -1 ? a[B] = d[U] : a[B] = C(k);
|
|
1506
1506
|
}
|
|
1507
1507
|
}
|
|
1508
1508
|
return c.pop(), d.pop(), a;
|
|
@@ -2021,7 +2021,6 @@ function I4(o, t) {
|
|
|
2021
2021
|
n("path", {
|
|
2022
2022
|
d: "M10 14V10.4C10 10.0266 10 9.83995 9.92734 9.69734C9.86342 9.5719 9.76144 9.46991 9.63599 9.406C9.49339 9.33333 9.3067 9.33333 8.93333 9.33333H7.06667C6.6933 9.33333 6.50661 9.33333 6.36401 9.406C6.23857 9.46991 6.13658 9.5719 6.07266 9.69734C6 9.83995 6 10.0266 6 10.4V14M2 4.66667C2 5.77124 2.89543 6.66667 4 6.66667C5.10457 6.66667 6 5.77124 6 4.66667C6 5.77124 6.89543 6.66667 8 6.66667C9.10457 6.66667 10 5.77124 10 4.66667C10 5.77124 10.8954 6.66667 12 6.66667C13.1046 6.66667 14 5.77124 14 4.66667M4.13333 14H11.8667C12.6134 14 12.9868 14 13.272 13.8547C13.5229 13.7268 13.7268 13.5229 13.8547 13.272C14 12.9868 14 12.6134 14 11.8667V4.13333C14 3.3866 14 3.01323 13.8547 2.72801C13.7268 2.47713 13.5229 2.27316 13.272 2.14532C12.9868 2 12.6134 2 11.8667 2H4.13333C3.3866 2 3.01323 2 2.72801 2.14532C2.47713 2.27316 2.27316 2.47713 2.14532 2.72801C2 3.01323 2 3.3866 2 4.13333V11.8667C2 12.6134 2 12.9868 2.14532 13.272C2.27316 13.5229 2.47713 13.7268 2.72801 13.8547C3.01323 14 3.3866 14 4.13333 14Z",
|
|
2023
2023
|
stroke: "currentColor",
|
|
2024
|
-
"stroke-opacity": "0.4",
|
|
2025
2024
|
"stroke-linecap": "round",
|
|
2026
2025
|
"stroke-linejoin": "round"
|
|
2027
2026
|
}, null, -1)
|
|
@@ -2346,7 +2345,6 @@ function ke(o, t) {
|
|
|
2346
2345
|
n("path", {
|
|
2347
2346
|
d: "M8.00016 10.6667V14M8.00016 10.6667L12.0002 14M8.00016 10.6667L4.00016 14M14.0002 2V7.46667C14.0002 8.58677 14.0002 9.14682 13.7822 9.57465C13.5904 9.95097 13.2845 10.2569 12.9081 10.4487C12.4803 10.6667 11.9203 10.6667 10.8002 10.6667H5.20016C4.08006 10.6667 3.52001 10.6667 3.09218 10.4487C2.71586 10.2569 2.4099 9.95097 2.21815 9.57465C2.00016 9.14682 2.00016 8.58677 2.00016 7.46667V2M5.3335 6V8M8.00016 4.66667V8M10.6668 7.33333V8M14.6668 2H1.3335",
|
|
2348
2347
|
stroke: "currentColor",
|
|
2349
|
-
"stroke-opacity": "0.4",
|
|
2350
2348
|
"stroke-linecap": "round",
|
|
2351
2349
|
"stroke-linejoin": "round"
|
|
2352
2350
|
}, null, -1)
|
|
@@ -2487,7 +2485,6 @@ function je(o, t) {
|
|
|
2487
2485
|
n("path", {
|
|
2488
2486
|
d: "M6.06016 6.00004C6.2169 5.55449 6.52626 5.17878 6.93347 4.93946C7.34067 4.70015 7.81943 4.61267 8.28495 4.69252C8.75047 4.77236 9.17271 5.01439 9.47688 5.37573C9.78106 5.73706 9.94753 6.19439 9.94683 6.66671C9.94683 8.00004 7.94683 8.66671 7.94683 8.66671M8.00016 11.3334H8.00683M14.6668 8.00004C14.6668 11.6819 11.6821 14.6667 8.00016 14.6667C4.31826 14.6667 1.3335 11.6819 1.3335 8.00004C1.3335 4.31814 4.31826 1.33337 8.00016 1.33337C11.6821 1.33337 14.6668 4.31814 14.6668 8.00004Z",
|
|
2489
2487
|
stroke: "currentColor",
|
|
2490
|
-
"stroke-opacity": "0.4",
|
|
2491
2488
|
"stroke-linecap": "round",
|
|
2492
2489
|
"stroke-linejoin": "round"
|
|
2493
2490
|
})
|
|
@@ -3272,7 +3269,7 @@ const Fs = /* @__PURE__ */ p(v7, [["render", B7]]), S7 = { class: "fixed z-[9998
|
|
|
3272
3269
|
G1(g, () => {
|
|
3273
3270
|
M();
|
|
3274
3271
|
}, { immediate: !0 });
|
|
3275
|
-
const
|
|
3272
|
+
const C = z(() => e.label !== "Select" ? e.label : A.value ? A.value.label : "Select"), v = z(() => e.showIcon ? e.customIcon ? e.customIcon : e.openUp ? h6 : h2 : null), m = () => {
|
|
3276
3273
|
c.value = !c.value, c.value || (d.value = "");
|
|
3277
3274
|
}, a = () => {
|
|
3278
3275
|
c.value = !1, d.value = "";
|
|
@@ -3299,7 +3296,7 @@ const Fs = /* @__PURE__ */ p(v7, [["render", B7]]), S7 = { class: "fixed z-[9998
|
|
|
3299
3296
|
}, [
|
|
3300
3297
|
o1(c3, {
|
|
3301
3298
|
class: "dropdown-trigger",
|
|
3302
|
-
label:
|
|
3299
|
+
label: C.value,
|
|
3303
3300
|
iconOnly: S.iconOnly,
|
|
3304
3301
|
rightIcon: S.chevronRight && S.showIcon ? v.value : void 0,
|
|
3305
3302
|
leftIcon: !S.chevronRight && S.showIcon ? v.value : void 0,
|
|
@@ -3312,7 +3309,7 @@ const Fs = /* @__PURE__ */ p(v7, [["render", B7]]), S7 = { class: "fixed z-[9998
|
|
|
3312
3309
|
}, {
|
|
3313
3310
|
default: x1(() => [
|
|
3314
3311
|
X(S.$slots, "button", {}, () => [
|
|
3315
|
-
M1(O(
|
|
3312
|
+
M1(O(C.value), 1)
|
|
3316
3313
|
])
|
|
3317
3314
|
]),
|
|
3318
3315
|
_: 3
|
|
@@ -3419,7 +3416,7 @@ const Fs = /* @__PURE__ */ p(v7, [["render", B7]]), S7 = { class: "fixed z-[9998
|
|
|
3419
3416
|
"input-field--disabled": e.state === "disabled",
|
|
3420
3417
|
"input-field--with-leading": e.iconLeading || e.type === "leading-dropdown" || e.type === "leading-text",
|
|
3421
3418
|
"input-field--with-trailing": e.type === "trailing-dropdown" || e.type === "trailing-button" || e.type === "clear" || e.helpIcon
|
|
3422
|
-
})),
|
|
3419
|
+
})), C = () => {
|
|
3423
3420
|
var y;
|
|
3424
3421
|
e.state !== "disabled" && ((y = c.value) == null || y.focus());
|
|
3425
3422
|
}, v = (y) => {
|
|
@@ -3460,7 +3457,7 @@ const Fs = /* @__PURE__ */ p(v7, [["render", B7]]), S7 = { class: "fixed z-[9998
|
|
|
3460
3457
|
], 10, X7)) : L("", !0),
|
|
3461
3458
|
n("div", {
|
|
3462
3459
|
class: _(["input-field-container", g.value]),
|
|
3463
|
-
onClick:
|
|
3460
|
+
onClick: C
|
|
3464
3461
|
}, [
|
|
3465
3462
|
y.type === "leading-dropdown" ? (s(), i("div", {
|
|
3466
3463
|
key: 0,
|
|
@@ -3693,15 +3690,15 @@ const Fs = /* @__PURE__ */ p(v7, [["render", B7]]), S7 = { class: "fixed z-[9998
|
|
|
3693
3690
|
emits: ["update:currentPage"],
|
|
3694
3691
|
setup(o, { emit: t }) {
|
|
3695
3692
|
const e = o, l = t, c = z(() => !e.totalItems || isNaN(e.totalItems) ? 0 : Math.ceil(e.totalItems / e.itemsPerPage)), d = z(() => {
|
|
3696
|
-
const g = [], M = c.value,
|
|
3693
|
+
const g = [], M = c.value, C = e.currentPage;
|
|
3697
3694
|
if (M <= 7)
|
|
3698
3695
|
for (let v = 1; v <= M; v++)
|
|
3699
3696
|
g.push(v);
|
|
3700
3697
|
else {
|
|
3701
|
-
g.push(1),
|
|
3702
|
-
for (let v = Math.max(4,
|
|
3698
|
+
g.push(1), C > 4 ? g.push("...") : g.push(2, 3);
|
|
3699
|
+
for (let v = Math.max(4, C - 1); v <= Math.min(M - 3, C + 1); v++)
|
|
3703
3700
|
g.push(v);
|
|
3704
|
-
|
|
3701
|
+
C < M - 4 && g.push("..."), g.push(M - 2, M - 1, M);
|
|
3705
3702
|
}
|
|
3706
3703
|
return g;
|
|
3707
3704
|
});
|
|
@@ -3711,21 +3708,21 @@ const Fs = /* @__PURE__ */ p(v7, [["render", B7]]), S7 = { class: "fixed z-[9998
|
|
|
3711
3708
|
return (g, M) => c.value > 0 ? (s(), i("nav", f9, [
|
|
3712
3709
|
n("button", {
|
|
3713
3710
|
class: _(["freddy-pagination-end-button", { "freddy-pagination-hover-enabled": o.currentPage !== 1 }]),
|
|
3714
|
-
onClick: M[0] || (M[0] = (
|
|
3711
|
+
onClick: M[0] || (M[0] = (C) => A(o.currentPage - 1)),
|
|
3715
3712
|
disabled: o.currentPage === 1
|
|
3716
3713
|
}, " Previous ", 10, u9),
|
|
3717
3714
|
n("div", A9, [
|
|
3718
|
-
(s(!0), i(l1, null, v1(d.value, (
|
|
3719
|
-
key: String(
|
|
3720
|
-
class: _(["freddy-pagination-number-button", { active:
|
|
3721
|
-
onClick: (v) => A(
|
|
3722
|
-
disabled:
|
|
3723
|
-
}, O(
|
|
3715
|
+
(s(!0), i(l1, null, v1(d.value, (C) => (s(), i("button", {
|
|
3716
|
+
key: String(C),
|
|
3717
|
+
class: _(["freddy-pagination-number-button", { active: C === o.currentPage }]),
|
|
3718
|
+
onClick: (v) => A(C),
|
|
3719
|
+
disabled: C === "..." || C === o.currentPage
|
|
3720
|
+
}, O(C), 11, C9))), 128)),
|
|
3724
3721
|
n("button", {
|
|
3725
3722
|
class: _(["freddy-pagination-end-button", {
|
|
3726
3723
|
"freddy-pagination-hover-enabled": o.currentPage !== c.value
|
|
3727
3724
|
}]),
|
|
3728
|
-
onClick: M[1] || (M[1] = (
|
|
3725
|
+
onClick: M[1] || (M[1] = (C) => A(o.currentPage + 1)),
|
|
3729
3726
|
disabled: o.currentPage === c.value || c.value === 0
|
|
3730
3727
|
}, " Next ", 10, h9)
|
|
3731
3728
|
])
|
|
@@ -3741,28 +3738,23 @@ const Fs = /* @__PURE__ */ p(v7, [["render", B7]]), S7 = { class: "fixed z-[9998
|
|
|
3741
3738
|
class: _(["freddy-plugin-spinner", t.customClass])
|
|
3742
3739
|
}, null, 2));
|
|
3743
3740
|
}
|
|
3744
|
-
}), m9 = ["placeholder"], js = /* @__PURE__ */ Z({
|
|
3741
|
+
}), m9 = ["placeholder", "maxlength"], js = /* @__PURE__ */ Z({
|
|
3745
3742
|
inheritAttrs: !1,
|
|
3746
3743
|
__name: "SearchInput",
|
|
3747
3744
|
props: {
|
|
3748
|
-
placeholder: {
|
|
3749
|
-
|
|
3750
|
-
|
|
3751
|
-
},
|
|
3752
|
-
showLoaderForSearch: {
|
|
3753
|
-
type: Boolean,
|
|
3754
|
-
default: () => !1
|
|
3755
|
-
}
|
|
3745
|
+
placeholder: { default: "Search here..." },
|
|
3746
|
+
showLoaderForSearch: { type: Boolean, default: !1 },
|
|
3747
|
+
maxCharLimit: { default: void 0 }
|
|
3756
3748
|
},
|
|
3757
3749
|
emits: ["update:searchInput"],
|
|
3758
3750
|
setup(o, { emit: t }) {
|
|
3759
3751
|
const e = j0(), l = Q(null), c = Q(null), d = Q(null), A = t, g = () => {
|
|
3760
|
-
var
|
|
3761
|
-
(
|
|
3752
|
+
var C;
|
|
3753
|
+
(C = c.value) == null || C.focus();
|
|
3762
3754
|
}, M = () => {
|
|
3763
3755
|
A("update:searchInput", l.value);
|
|
3764
3756
|
};
|
|
3765
|
-
return (
|
|
3757
|
+
return (C, v) => (s(), i("div", {
|
|
3766
3758
|
ref_key: "dropdownRef",
|
|
3767
3759
|
ref: d,
|
|
3768
3760
|
class: _(["freddy-search-wrapper", H(e).class]),
|
|
@@ -3777,11 +3769,12 @@ const Fs = /* @__PURE__ */ p(v7, [["render", B7]]), S7 = { class: "fixed z-[9998
|
|
|
3777
3769
|
ref: c,
|
|
3778
3770
|
"onUpdate:modelValue": v[0] || (v[0] = (m) => l.value = m),
|
|
3779
3771
|
onInput: M,
|
|
3780
|
-
placeholder:
|
|
3772
|
+
placeholder: C.placeholder,
|
|
3773
|
+
maxlength: C.maxCharLimit
|
|
3781
3774
|
}, null, 40, m9), [
|
|
3782
3775
|
[A0, l.value]
|
|
3783
3776
|
]),
|
|
3784
|
-
|
|
3777
|
+
C.showLoaderForSearch ? (s(), D(g9, {
|
|
3785
3778
|
key: 0,
|
|
3786
3779
|
class: "freddy-search-spinner"
|
|
3787
3780
|
})) : L("", !0)
|
|
@@ -3922,7 +3915,7 @@ const Fs = /* @__PURE__ */ p(v7, [["render", B7]]), S7 = { class: "fixed z-[9998
|
|
|
3922
3915
|
]),
|
|
3923
3916
|
n("button", {
|
|
3924
3917
|
class: "freddy-plugin-snackbar-close-btn",
|
|
3925
|
-
onClick: (
|
|
3918
|
+
onClick: (C) => c(M)
|
|
3926
3919
|
}, [
|
|
3927
3920
|
o1(m0, { class: "freddy-plugin-snackbar-close-icon" })
|
|
3928
3921
|
], 8, F9)
|
|
@@ -3942,9 +3935,9 @@ const Fs = /* @__PURE__ */ p(v7, [["render", B7]]), S7 = { class: "fixed z-[9998
|
|
|
3942
3935
|
c.value !== A.id && (c.value = A.id, l("tabSwitch", A.id));
|
|
3943
3936
|
};
|
|
3944
3937
|
return (A, g) => (s(), i("div", T9, [
|
|
3945
|
-
(s(!0), i(l1, null, v1(A.tabList, (M,
|
|
3938
|
+
(s(!0), i(l1, null, v1(A.tabList, (M, C) => (s(), i("button", {
|
|
3946
3939
|
class: "freddy-plugin-menu-button",
|
|
3947
|
-
key:
|
|
3940
|
+
key: C,
|
|
3948
3941
|
onClick: (v) => d(M)
|
|
3949
3942
|
}, [
|
|
3950
3943
|
M1(O(M.title) + " ", 1),
|
|
@@ -3976,8 +3969,8 @@ const Fs = /* @__PURE__ */ p(v7, [["render", B7]]), S7 = { class: "fixed z-[9998
|
|
|
3976
3969
|
t.value.splice(A, 1);
|
|
3977
3970
|
};
|
|
3978
3971
|
return (A, g) => (s(), i("div", V9, [
|
|
3979
|
-
(s(!0), i(l1, null, v1(H(t), (M,
|
|
3980
|
-
key:
|
|
3972
|
+
(s(!0), i(l1, null, v1(H(t), (M, C) => (s(), i("div", {
|
|
3973
|
+
key: C,
|
|
3981
3974
|
class: _(["toast-item", l(M.toastType)])
|
|
3982
3975
|
}, [
|
|
3983
3976
|
n("div", R9, [
|
|
@@ -3986,7 +3979,7 @@ const Fs = /* @__PURE__ */ p(v7, [["render", B7]]), S7 = { class: "fixed z-[9998
|
|
|
3986
3979
|
n("span", N9, O(M.message), 1),
|
|
3987
3980
|
n("button", {
|
|
3988
3981
|
class: "toast-close-button",
|
|
3989
|
-
onClick: (v) => d(
|
|
3982
|
+
onClick: (v) => d(C)
|
|
3990
3983
|
}, [
|
|
3991
3984
|
o1(H(z1), { class: "toast-close-icon" })
|
|
3992
3985
|
], 8, P9)
|
|
@@ -4153,7 +4146,7 @@ function v0() {
|
|
|
4153
4146
|
HTMLTemplateElement: A,
|
|
4154
4147
|
Node: g,
|
|
4155
4148
|
Element: M,
|
|
4156
|
-
NodeFilter:
|
|
4149
|
+
NodeFilter: C,
|
|
4157
4150
|
NamedNodeMap: v = o.NamedNodeMap || o.MozNamedAttrMap,
|
|
4158
4151
|
HTMLFormElement: m,
|
|
4159
4152
|
DOMParser: a,
|
|
@@ -4241,13 +4234,13 @@ function v0() {
|
|
|
4241
4234
|
q && q(r), m1 = r;
|
|
4242
4235
|
}
|
|
4243
4236
|
}, Z2 = I({}, [...d2, ...f2, ...t8]), F2 = I({}, [...u2, ...e8]), T0 = function(r) {
|
|
4244
|
-
let
|
|
4245
|
-
(!
|
|
4237
|
+
let h = R(r);
|
|
4238
|
+
(!h || !h.tagName) && (h = {
|
|
4246
4239
|
namespaceURI: g1,
|
|
4247
4240
|
tagName: "template"
|
|
4248
4241
|
});
|
|
4249
|
-
const w = P1(r.tagName), G = P1(
|
|
4250
|
-
return s2[r.namespaceURI] ? r.namespaceURI === T1 ?
|
|
4242
|
+
const w = P1(r.tagName), G = P1(h.tagName);
|
|
4243
|
+
return s2[r.namespaceURI] ? r.namespaceURI === T1 ? h.namespaceURI === a1 ? w === "svg" : h.namespaceURI === O1 ? w === "svg" && (G === "annotation-xml" || H1[G]) : !!Z2[w] : r.namespaceURI === O1 ? h.namespaceURI === a1 ? w === "math" : h.namespaceURI === T1 ? w === "math" && V1[G] : !!F2[w] : r.namespaceURI === a1 ? h.namespaceURI === T1 && !V1[G] || h.namespaceURI === O1 && !H1[G] ? !1 : !F2[w] && (D0[w] || !Z2[w]) : !!(S1 === "application/xhtml+xml" && s2[r.namespaceURI]) : !1;
|
|
4251
4244
|
}, i1 = function(r) {
|
|
4252
4245
|
_1(t.removed, {
|
|
4253
4246
|
element: r
|
|
@@ -4257,31 +4250,31 @@ function v0() {
|
|
|
4257
4250
|
} catch {
|
|
4258
4251
|
y(r);
|
|
4259
4252
|
}
|
|
4260
|
-
}, y1 = function(r,
|
|
4253
|
+
}, y1 = function(r, h) {
|
|
4261
4254
|
try {
|
|
4262
4255
|
_1(t.removed, {
|
|
4263
|
-
attribute:
|
|
4264
|
-
from:
|
|
4256
|
+
attribute: h.getAttributeNode(r),
|
|
4257
|
+
from: h
|
|
4265
4258
|
});
|
|
4266
4259
|
} catch {
|
|
4267
4260
|
_1(t.removed, {
|
|
4268
4261
|
attribute: null,
|
|
4269
|
-
from:
|
|
4262
|
+
from: h
|
|
4270
4263
|
});
|
|
4271
4264
|
}
|
|
4272
|
-
if (
|
|
4265
|
+
if (h.removeAttribute(r), r === "is")
|
|
4273
4266
|
if (A1 || Z1)
|
|
4274
4267
|
try {
|
|
4275
|
-
i1(
|
|
4268
|
+
i1(h);
|
|
4276
4269
|
} catch {
|
|
4277
4270
|
}
|
|
4278
4271
|
else
|
|
4279
4272
|
try {
|
|
4280
|
-
|
|
4273
|
+
h.setAttribute(r, "");
|
|
4281
4274
|
} catch {
|
|
4282
4275
|
}
|
|
4283
4276
|
}, O2 = function(r) {
|
|
4284
|
-
let
|
|
4277
|
+
let h = null, w = null;
|
|
4285
4278
|
if (t2)
|
|
4286
4279
|
r = "<remove></remove>" + r;
|
|
4287
4280
|
else {
|
|
@@ -4292,24 +4285,24 @@ function v0() {
|
|
|
4292
4285
|
const G = E ? E.createHTML(r) : r;
|
|
4293
4286
|
if (g1 === a1)
|
|
4294
4287
|
try {
|
|
4295
|
-
|
|
4288
|
+
h = new a().parseFromString(G, S1);
|
|
4296
4289
|
} catch {
|
|
4297
4290
|
}
|
|
4298
|
-
if (!
|
|
4299
|
-
|
|
4291
|
+
if (!h || !h.documentElement) {
|
|
4292
|
+
h = J1.createDocument(g1, "template", null);
|
|
4300
4293
|
try {
|
|
4301
|
-
|
|
4294
|
+
h.documentElement.innerHTML = n2 ? r1 : G;
|
|
4302
4295
|
} catch {
|
|
4303
4296
|
}
|
|
4304
4297
|
}
|
|
4305
|
-
const Y =
|
|
4306
|
-
return r && w && Y.insertBefore(e.createTextNode(w), Y.childNodes[0] || null), g1 === a1 ? S0.call(
|
|
4298
|
+
const Y = h.body || h.documentElement;
|
|
4299
|
+
return r && w && Y.insertBefore(e.createTextNode(w), Y.childNodes[0] || null), g1 === a1 ? S0.call(h, f1 ? "html" : "body")[0] : f1 ? h.documentElement : Y;
|
|
4307
4300
|
}, T2 = function(r) {
|
|
4308
4301
|
return k0.call(
|
|
4309
4302
|
r.ownerDocument || r,
|
|
4310
4303
|
r,
|
|
4311
4304
|
// eslint-disable-next-line no-bitwise
|
|
4312
|
-
|
|
4305
|
+
C.SHOW_ELEMENT | C.SHOW_COMMENT | C.SHOW_TEXT | C.SHOW_PROCESSING_INSTRUCTION | C.SHOW_CDATA_SECTION,
|
|
4313
4306
|
null
|
|
4314
4307
|
);
|
|
4315
4308
|
}, i2 = function(r) {
|
|
@@ -4317,13 +4310,13 @@ function v0() {
|
|
|
4317
4310
|
}, H2 = function(r) {
|
|
4318
4311
|
return typeof g == "function" && r instanceof g;
|
|
4319
4312
|
};
|
|
4320
|
-
function c1(x, r,
|
|
4313
|
+
function c1(x, r, h) {
|
|
4321
4314
|
R1(x, (w) => {
|
|
4322
|
-
w.call(t, r,
|
|
4315
|
+
w.call(t, r, h, m1);
|
|
4323
4316
|
});
|
|
4324
4317
|
}
|
|
4325
4318
|
const V2 = function(r) {
|
|
4326
|
-
let
|
|
4319
|
+
let h = null;
|
|
4327
4320
|
if (c1(W.beforeSanitizeElements, r, null), i2(r))
|
|
4328
4321
|
return i1(r), !0;
|
|
4329
4322
|
const w = P(r.nodeName);
|
|
@@ -4347,28 +4340,28 @@ function v0() {
|
|
|
4347
4340
|
}
|
|
4348
4341
|
return i1(r), !0;
|
|
4349
4342
|
}
|
|
4350
|
-
return r instanceof M && !T0(r) || (w === "noscript" || w === "noembed" || w === "noframes") && K(/<\/no(script|embed|frames)/i, r.innerHTML) ? (i1(r), !0) : (u1 && r.nodeType === b1.text && (
|
|
4351
|
-
|
|
4352
|
-
}), r.textContent !==
|
|
4343
|
+
return r instanceof M && !T0(r) || (w === "noscript" || w === "noembed" || w === "noframes") && K(/<\/no(script|embed|frames)/i, r.innerHTML) ? (i1(r), !0) : (u1 && r.nodeType === b1.text && (h = r.textContent, R1([Q1, W1, K1], (G) => {
|
|
4344
|
+
h = E1(h, G, " ");
|
|
4345
|
+
}), r.textContent !== h && (_1(t.removed, {
|
|
4353
4346
|
element: r.cloneNode()
|
|
4354
|
-
}), r.textContent =
|
|
4355
|
-
}, R2 = function(r,
|
|
4356
|
-
if (_2 && (
|
|
4347
|
+
}), r.textContent = h)), c1(W.afterSanitizeElements, r, null), !1);
|
|
4348
|
+
}, R2 = function(r, h, w) {
|
|
4349
|
+
if (_2 && (h === "id" || h === "name") && (w in e || w in O0))
|
|
4357
4350
|
return !1;
|
|
4358
|
-
if (!(q1 && !X1[
|
|
4359
|
-
if (!(B2 && K(E0,
|
|
4360
|
-
if (!j[
|
|
4351
|
+
if (!(q1 && !X1[h] && K(_0, h))) {
|
|
4352
|
+
if (!(B2 && K(E0, h))) {
|
|
4353
|
+
if (!j[h] || X1[h]) {
|
|
4361
4354
|
if (
|
|
4362
4355
|
// First condition does a very basic check if a) it's basically a valid custom element tagname AND
|
|
4363
4356
|
// b) if the tagName passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
|
|
4364
4357
|
// and c) if the attribute name passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.attributeNameCheck
|
|
4365
|
-
!(N2(r) && (T.tagNameCheck instanceof RegExp && K(T.tagNameCheck, r) || T.tagNameCheck instanceof Function && T.tagNameCheck(r)) && (T.attributeNameCheck instanceof RegExp && K(T.attributeNameCheck,
|
|
4358
|
+
!(N2(r) && (T.tagNameCheck instanceof RegExp && K(T.tagNameCheck, r) || T.tagNameCheck instanceof Function && T.tagNameCheck(r)) && (T.attributeNameCheck instanceof RegExp && K(T.attributeNameCheck, h) || T.attributeNameCheck instanceof Function && T.attributeNameCheck(h)) || // Alternative, second condition checks if it's an `is`-attribute, AND
|
|
4366
4359
|
// the value passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
|
|
4367
|
-
|
|
4360
|
+
h === "is" && T.allowCustomizedBuiltInElements && (T.tagNameCheck instanceof RegExp && K(T.tagNameCheck, w) || T.tagNameCheck instanceof Function && T.tagNameCheck(w)))
|
|
4368
4361
|
) return !1;
|
|
4369
|
-
} else if (!o2[
|
|
4362
|
+
} else if (!o2[h]) {
|
|
4370
4363
|
if (!K(x2, E1(w, M2, ""))) {
|
|
4371
|
-
if (!((
|
|
4364
|
+
if (!((h === "src" || h === "xlink:href" || h === "href") && r !== "script" && K9(w, "data:") === 0 && U2[r])) {
|
|
4372
4365
|
if (!(S2 && !K(L0, E1(w, M2, "")))) {
|
|
4373
4366
|
if (w)
|
|
4374
4367
|
return !1;
|
|
@@ -4384,9 +4377,9 @@ function v0() {
|
|
|
4384
4377
|
}, P2 = function(r) {
|
|
4385
4378
|
c1(W.beforeSanitizeAttributes, r, null);
|
|
4386
4379
|
const {
|
|
4387
|
-
attributes:
|
|
4380
|
+
attributes: h
|
|
4388
4381
|
} = r;
|
|
4389
|
-
if (!
|
|
4382
|
+
if (!h || i2(r))
|
|
4390
4383
|
return;
|
|
4391
4384
|
const w = {
|
|
4392
4385
|
attrName: "",
|
|
@@ -4395,9 +4388,9 @@ function v0() {
|
|
|
4395
4388
|
allowedAttributes: j,
|
|
4396
4389
|
forceKeepAttr: void 0
|
|
4397
4390
|
};
|
|
4398
|
-
let G =
|
|
4391
|
+
let G = h.length;
|
|
4399
4392
|
for (; G--; ) {
|
|
4400
|
-
const Y =
|
|
4393
|
+
const Y = h[G], {
|
|
4401
4394
|
name: V,
|
|
4402
4395
|
namespaceURI: t1,
|
|
4403
4396
|
value: p1
|
|
@@ -4445,14 +4438,14 @@ function v0() {
|
|
|
4445
4438
|
}
|
|
4446
4439
|
c1(W.afterSanitizeAttributes, r, null);
|
|
4447
4440
|
}, H0 = function x(r) {
|
|
4448
|
-
let
|
|
4441
|
+
let h = null;
|
|
4449
4442
|
const w = T2(r);
|
|
4450
|
-
for (c1(W.beforeSanitizeShadowDOM, r, null);
|
|
4451
|
-
c1(W.uponSanitizeShadowNode,
|
|
4443
|
+
for (c1(W.beforeSanitizeShadowDOM, r, null); h = w.nextNode(); )
|
|
4444
|
+
c1(W.uponSanitizeShadowNode, h, null), V2(h), P2(h), h.content instanceof d && x(h.content);
|
|
4452
4445
|
c1(W.afterSanitizeShadowDOM, r, null);
|
|
4453
4446
|
};
|
|
4454
4447
|
return t.sanitize = function(x) {
|
|
4455
|
-
let r = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {},
|
|
4448
|
+
let r = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, h = null, w = null, G = null, Y = null;
|
|
4456
4449
|
if (n2 = !x, n2 && (x = "<!-->"), typeof x != "string" && !H2(x))
|
|
4457
4450
|
if (typeof x.toString == "function") {
|
|
4458
4451
|
if (x = x.toString(), typeof x != "string")
|
|
@@ -4468,30 +4461,30 @@ function v0() {
|
|
|
4468
4461
|
throw L1("root node is forbidden and cannot be sanitized in-place");
|
|
4469
4462
|
}
|
|
4470
4463
|
} else if (x instanceof g)
|
|
4471
|
-
|
|
4464
|
+
h = O2("<!---->"), w = h.ownerDocument.importNode(x, !0), w.nodeType === b1.element && w.nodeName === "BODY" || w.nodeName === "HTML" ? h = w : h.appendChild(w);
|
|
4472
4465
|
else {
|
|
4473
4466
|
if (!A1 && !u1 && !f1 && // eslint-disable-next-line unicorn/prefer-includes
|
|
4474
4467
|
x.indexOf("<") === -1)
|
|
4475
4468
|
return E && F1 ? E.createHTML(x) : x;
|
|
4476
|
-
if (
|
|
4469
|
+
if (h = O2(x), !h)
|
|
4477
4470
|
return A1 ? null : F1 ? r1 : "";
|
|
4478
4471
|
}
|
|
4479
|
-
|
|
4480
|
-
const V = T2(B1 ? x :
|
|
4472
|
+
h && t2 && i1(h.firstChild);
|
|
4473
|
+
const V = T2(B1 ? x : h);
|
|
4481
4474
|
for (; G = V.nextNode(); )
|
|
4482
4475
|
V2(G), P2(G), G.content instanceof d && H0(G.content);
|
|
4483
4476
|
if (B1)
|
|
4484
4477
|
return x;
|
|
4485
4478
|
if (A1) {
|
|
4486
4479
|
if (Z1)
|
|
4487
|
-
for (Y = B0.call(
|
|
4488
|
-
Y.appendChild(
|
|
4480
|
+
for (Y = B0.call(h.ownerDocument); h.firstChild; )
|
|
4481
|
+
Y.appendChild(h.firstChild);
|
|
4489
4482
|
else
|
|
4490
|
-
Y =
|
|
4483
|
+
Y = h;
|
|
4491
4484
|
return (j.shadowroot || j.shadowrootmode) && (Y = I0.call(l, Y, !0)), Y;
|
|
4492
4485
|
}
|
|
4493
|
-
let t1 = f1 ?
|
|
4494
|
-
return f1 && N["!doctype"] &&
|
|
4486
|
+
let t1 = f1 ? h.outerHTML : h.innerHTML;
|
|
4487
|
+
return f1 && N["!doctype"] && h.ownerDocument && h.ownerDocument.doctype && h.ownerDocument.doctype.name && K(x0, h.ownerDocument.doctype.name) && (t1 = "<!DOCTYPE " + h.ownerDocument.doctype.name + `>
|
|
4495
4488
|
` + t1), u1 && R1([Q1, W1, K1], (p1) => {
|
|
4496
4489
|
t1 = E1(t1, p1, " ");
|
|
4497
4490
|
}), E && F1 ? E.createHTML(t1) : t1;
|
|
@@ -4500,16 +4493,16 @@ function v0() {
|
|
|
4500
4493
|
r2(x), $1 = !0;
|
|
4501
4494
|
}, t.clearConfig = function() {
|
|
4502
4495
|
m1 = null, $1 = !1;
|
|
4503
|
-
}, t.isValidAttribute = function(x, r,
|
|
4496
|
+
}, t.isValidAttribute = function(x, r, h) {
|
|
4504
4497
|
m1 || r2({});
|
|
4505
4498
|
const w = P(x), G = P(r);
|
|
4506
|
-
return R2(w, G,
|
|
4499
|
+
return R2(w, G, h);
|
|
4507
4500
|
}, t.addHook = function(x, r) {
|
|
4508
4501
|
typeof r == "function" && _1(W[x], r);
|
|
4509
4502
|
}, t.removeHook = function(x, r) {
|
|
4510
4503
|
if (r !== void 0) {
|
|
4511
|
-
const
|
|
4512
|
-
return
|
|
4504
|
+
const h = Q9(W[x], r);
|
|
4505
|
+
return h === -1 ? void 0 : W9(W[x], h, 1)[0];
|
|
4513
4506
|
}
|
|
4514
4507
|
return e0(W[x]);
|
|
4515
4508
|
}, t.removeHooks = function(x) {
|