@kupola/kupola 1.5.2 → 1.5.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/kupola.cjs.js +15 -15
- package/dist/kupola.cjs.js.map +1 -1
- package/dist/kupola.esm.js +296 -256
- package/dist/kupola.esm.js.map +1 -1
- package/dist/kupola.umd.js +15 -15
- package/dist/kupola.umd.js.map +1 -1
- package/js/kupola-config.js +13 -0
- package/js/security.js +52 -0
- package/package.json +1 -1
package/dist/kupola.esm.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
class
|
|
1
|
+
class lt {
|
|
2
2
|
constructor(t = "app") {
|
|
3
3
|
this.scope = t, this.hooks = /* @__PURE__ */ new Map(), this.state = "created", this.stateHistory = ["created"], this.transitions = /* @__PURE__ */ new Map([
|
|
4
4
|
["created", ["bootstrapped", "destroyed"]],
|
|
@@ -201,9 +201,9 @@ class ot {
|
|
|
201
201
|
console.error(`[KupolaLifecycle] Unhandled error in ${t.phase}:`, t.error);
|
|
202
202
|
}
|
|
203
203
|
}
|
|
204
|
-
const Sa = new
|
|
204
|
+
const Sa = new lt("app");
|
|
205
205
|
function La(i = "app") {
|
|
206
|
-
return new
|
|
206
|
+
return new lt(i);
|
|
207
207
|
}
|
|
208
208
|
const Ce = /* @__PURE__ */ new Set(["__proto__", "prototype", "constructor"]);
|
|
209
209
|
function G(i) {
|
|
@@ -401,8 +401,8 @@ function Cs(i, t) {
|
|
|
401
401
|
function Ss(i, t = 1) {
|
|
402
402
|
return i ? i.flat(t) : [];
|
|
403
403
|
}
|
|
404
|
-
function
|
|
405
|
-
return i ? i.reduce((t, e) => Array.isArray(e) ? t.concat(
|
|
404
|
+
function wt(i) {
|
|
405
|
+
return i ? i.reduce((t, e) => Array.isArray(e) ? t.concat(wt(e)) : t.concat(e), []) : [];
|
|
406
406
|
}
|
|
407
407
|
function Ls(i) {
|
|
408
408
|
return i ? [...new Set(i)] : [];
|
|
@@ -431,11 +431,11 @@ function Ms(i) {
|
|
|
431
431
|
}
|
|
432
432
|
return t;
|
|
433
433
|
}
|
|
434
|
-
function
|
|
434
|
+
function Ct(i) {
|
|
435
435
|
return i ? i.reduce((t, e) => t + (Number(e) || 0), 0) : 0;
|
|
436
436
|
}
|
|
437
437
|
function Is(i) {
|
|
438
|
-
return !i || i.length === 0 ? 0 :
|
|
438
|
+
return !i || i.length === 0 ? 0 : Ct(i) / i.length;
|
|
439
439
|
}
|
|
440
440
|
function Ts(i) {
|
|
441
441
|
return i && i.length > 0 ? Math.max(...i) : -1 / 0;
|
|
@@ -457,8 +457,8 @@ function qs(...i) {
|
|
|
457
457
|
const t = Math.max(...i.map((e) => e ? e.length : 0));
|
|
458
458
|
return Array.from({ length: t }, (e, s) => i.map((n) => n && n[s]));
|
|
459
459
|
}
|
|
460
|
-
const Bs = { isArray: Je, isEmpty: Ge, size: Ze, first: Qe, last: ts, get: es, slice: ss, concat: is, join: ns, indexOf: rs, lastIndexOf: as, includes: os, push: ls, pop: cs, shift: hs, unshift: ds, remove: us, removeAt: ps, insert: fs, reverse: ms, sort: gs, sortBy: _s, filter: ys, map: vs, reduce: bs, forEach: xs, every: Es, some: ks, find: ws, findIndex: Cs, flat: Ss, flattenDeep:
|
|
461
|
-
function
|
|
460
|
+
const Bs = { isArray: Je, isEmpty: Ge, size: Ze, first: Qe, last: ts, get: es, slice: ss, concat: is, join: ns, indexOf: rs, lastIndexOf: as, includes: os, push: ls, pop: cs, shift: hs, unshift: ds, remove: us, removeAt: ps, insert: fs, reverse: ms, sort: gs, sortBy: _s, filter: ys, map: vs, reduce: bs, forEach: xs, every: Es, some: ks, find: ws, findIndex: Cs, flat: Ss, flattenDeep: wt, unique: Ls, uniqueBy: Ds, chunk: Hs, shuffle: Ms, sum: Ct, average: Is, max: Ts, min: As, intersection: zs, union: Ps, difference: $s, zip: qs };
|
|
461
|
+
function it(i) {
|
|
462
462
|
return i !== null && typeof i == "object" && !Array.isArray(i);
|
|
463
463
|
}
|
|
464
464
|
function Fs(i) {
|
|
@@ -497,9 +497,9 @@ function Us(i, t) {
|
|
|
497
497
|
function Ys(i, t) {
|
|
498
498
|
return i ? Object.keys(i).reduce((e, s) => (t.includes(s) || (e[s] = i[s]), e), {}) : {};
|
|
499
499
|
}
|
|
500
|
-
function
|
|
500
|
+
function St(...i) {
|
|
501
501
|
return i.reduce((t, e) => (e && typeof e == "object" && Object.keys(e).forEach((s) => {
|
|
502
|
-
G(s) || (
|
|
502
|
+
G(s) || (it(e[s]) && it(t[s]) ? t[s] = St(t[s], e[s]) : t[s] = e[s]);
|
|
503
503
|
}), t), {});
|
|
504
504
|
}
|
|
505
505
|
function Xs(i) {
|
|
@@ -566,21 +566,21 @@ function si(i) {
|
|
|
566
566
|
t[i[e]] = e;
|
|
567
567
|
}), t;
|
|
568
568
|
}
|
|
569
|
-
function
|
|
569
|
+
function Lt(i, t) {
|
|
570
570
|
if (i === t) return !0;
|
|
571
571
|
if (!i || !t || typeof i != "object" || typeof t != "object") return !1;
|
|
572
572
|
const e = Object.keys(i), s = Object.keys(t);
|
|
573
|
-
return e.length !== s.length ? !1 : e.every((n) =>
|
|
573
|
+
return e.length !== s.length ? !1 : e.every((n) => Lt(i[n], t[n]));
|
|
574
574
|
}
|
|
575
|
-
function
|
|
575
|
+
function Dt(i) {
|
|
576
576
|
return i && (Object.freeze(i), Object.keys(i).forEach((t) => {
|
|
577
|
-
typeof i[t] == "object" &&
|
|
577
|
+
typeof i[t] == "object" && Dt(i[t]);
|
|
578
578
|
}), i);
|
|
579
579
|
}
|
|
580
580
|
function ii(i) {
|
|
581
581
|
return i && Object.seal(i);
|
|
582
582
|
}
|
|
583
|
-
const ni = { isObject:
|
|
583
|
+
const ni = { isObject: it, isEmpty: Fs, keys: Ns, values: Os, entries: Rs, has: Vs, get: Ks, set: Ws, pick: Us, omit: Ys, merge: St, clone: Xs, deepClone: U, forEach: js, map: Js, filter: Gs, reduce: Zs, toArray: Qs, fromArray: ti, size: ei, invert: si, isEqual: Lt, freeze: Dt, seal: ii };
|
|
584
584
|
function L(i) {
|
|
585
585
|
return typeof i == "number" && !isNaN(i);
|
|
586
586
|
}
|
|
@@ -624,18 +624,18 @@ function gi(...i) {
|
|
|
624
624
|
const t = i.filter(L);
|
|
625
625
|
return t.length > 0 ? Math.max(...t) : void 0;
|
|
626
626
|
}
|
|
627
|
-
function
|
|
627
|
+
function Ht(...i) {
|
|
628
628
|
return i.flat().filter(L).reduce((e, s) => e + s, 0);
|
|
629
629
|
}
|
|
630
630
|
function _i(...i) {
|
|
631
631
|
const t = i.flat().filter(L);
|
|
632
|
-
return t.length > 0 ?
|
|
632
|
+
return t.length > 0 ? Ht(t) / t.length : 0;
|
|
633
633
|
}
|
|
634
|
-
function
|
|
634
|
+
function Mt(i = 0, t = 1) {
|
|
635
635
|
return Math.random() * (t - i) + i;
|
|
636
636
|
}
|
|
637
637
|
function yi(i, t) {
|
|
638
|
-
return Math.floor(
|
|
638
|
+
return Math.floor(Mt(i, t + 1));
|
|
639
639
|
}
|
|
640
640
|
function vi(i, t = 2) {
|
|
641
641
|
return L(i) ? i.toFixed(t) : String(i);
|
|
@@ -674,7 +674,7 @@ function Hi(i, t, e = 0) {
|
|
|
674
674
|
function Mi(...i) {
|
|
675
675
|
return i.reduce((t, e) => !L(t) || !L(e) ? 0 : t * e, 1);
|
|
676
676
|
}
|
|
677
|
-
const Ii = { isNumber: L, isInteger: ri, isFloat: ai, isPositive: oi, isNegative: li, isZero: ci, clamp: hi, round: di, floor: ui, ceil: pi, abs: fi, min: mi, max: gi, sum:
|
|
677
|
+
const Ii = { isNumber: L, isInteger: ri, isFloat: ai, isPositive: oi, isNegative: li, isZero: ci, clamp: hi, round: di, floor: ui, ceil: pi, abs: fi, min: mi, max: gi, sum: Ht, average: _i, random: Mt, randomInt: yi, format: vi, formatCurrency: bi, formatPercent: xi, toFixed: Ei, toPrecision: ki, isNaN: wi, isFinite: Ci, parseInt: Si, parseFloat: Li, toNumber: Di, safeDivide: Hi, safeMultiply: Mi };
|
|
678
678
|
function Z() {
|
|
679
679
|
return Date.now();
|
|
680
680
|
}
|
|
@@ -693,12 +693,12 @@ function Ai() {
|
|
|
693
693
|
function k(i) {
|
|
694
694
|
return i instanceof Date && !isNaN(i.getTime());
|
|
695
695
|
}
|
|
696
|
-
function
|
|
696
|
+
function It(i) {
|
|
697
697
|
return k(i);
|
|
698
698
|
}
|
|
699
699
|
function zi(i) {
|
|
700
700
|
const t = new Date(i);
|
|
701
|
-
return
|
|
701
|
+
return It(t) ? t : null;
|
|
702
702
|
}
|
|
703
703
|
function Pi(i, t = "YYYY-MM-DD HH:mm:ss") {
|
|
704
704
|
if (!k(i)) return "";
|
|
@@ -794,14 +794,14 @@ function sn(i) {
|
|
|
794
794
|
function nn(i) {
|
|
795
795
|
return k(i) ? new Date(i.getFullYear(), i.getMonth() + 1, 0, 23, 59, 59, 999) : i;
|
|
796
796
|
}
|
|
797
|
-
function
|
|
797
|
+
function Tt(i, t = 1) {
|
|
798
798
|
if (!k(i)) return i;
|
|
799
799
|
const e = new Date(i), s = e.getDay(), n = s >= t ? s - t : s + (7 - t);
|
|
800
800
|
return e.setDate(e.getDate() - n), e.setHours(0, 0, 0, 0), e;
|
|
801
801
|
}
|
|
802
802
|
function rn(i, t = 1) {
|
|
803
803
|
if (!k(i)) return i;
|
|
804
|
-
const e =
|
|
804
|
+
const e = Tt(i, t), s = new Date(e);
|
|
805
805
|
return s.setDate(s.getDate() + 6), s.setHours(23, 59, 59, 999), s;
|
|
806
806
|
}
|
|
807
807
|
function an(i) {
|
|
@@ -815,7 +815,7 @@ function on(i) {
|
|
|
815
815
|
const e = Z() - i.getTime(), s = 60 * 1e3, n = 60 * s, r = 24 * n, a = 7 * r, o = 30 * r, l = 365 * r;
|
|
816
816
|
return e < s ? "刚刚" : e < n ? `${Math.floor(e / s)}分钟前` : e < r ? `${Math.floor(e / n)}小时前` : e < a ? `${Math.floor(e / r)}天前` : e < o ? `${Math.floor(e / a)}周前` : e < l ? `${Math.floor(e / o)}个月前` : `${Math.floor(e / l)}年前`;
|
|
817
817
|
}
|
|
818
|
-
const ln = { now: Z, today: K, tomorrow: Ti, yesterday: Ai, isDate: k, isValid:
|
|
818
|
+
const ln = { now: Z, today: K, tomorrow: Ti, yesterday: Ai, isDate: k, isValid: It, parse: zi, format: Pi, toISO: $i, toUTC: qi, addDays: Bi, addHours: Fi, addMinutes: Ni, addSeconds: Oi, diffDays: Q, diffHours: Ri, diffMinutes: Vi, diffSeconds: Ki, isToday: Wi, isYesterday: Ui, isTomorrow: Yi, isFuture: Xi, isPast: ji, isLeapYear: Ji, getDaysInMonth: Gi, getWeekOfYear: Zi, getQuarter: Qi, startOfDay: tn, endOfDay: en, startOfMonth: sn, endOfMonth: nn, startOfWeek: Tt, endOfWeek: rn, getAge: an, fromNow: on };
|
|
819
819
|
function cn(i, t, e = {}) {
|
|
820
820
|
let s = null, n = null, r = null, a = 0;
|
|
821
821
|
const o = e.leading || !1, l = e.trailing !== !1;
|
|
@@ -857,14 +857,14 @@ function un(i) {
|
|
|
857
857
|
function pn(i) {
|
|
858
858
|
return /^(https?:\/\/)?([\da-z.-]+)\.([a-z.]{2,6})([/\w.-]*)*\/?$/.test(i || "");
|
|
859
859
|
}
|
|
860
|
-
function
|
|
860
|
+
function At(i) {
|
|
861
861
|
return /^((25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$/.test(i || "");
|
|
862
862
|
}
|
|
863
|
-
function
|
|
863
|
+
function zt(i) {
|
|
864
864
|
return /^([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}$/.test(i || "");
|
|
865
865
|
}
|
|
866
866
|
function fn(i) {
|
|
867
|
-
return
|
|
867
|
+
return At(i) || zt(i);
|
|
868
868
|
}
|
|
869
869
|
function mn(i) {
|
|
870
870
|
return /^[1-9]\d{5}(18|19|20)\d{2}(0[1-9]|1[0-2])(0[1-9]|[12]\d|3[01])\d{3}[\dXx]$/.test(i || "");
|
|
@@ -882,21 +882,21 @@ function _n(i) {
|
|
|
882
882
|
}
|
|
883
883
|
return s % 10 === 0;
|
|
884
884
|
}
|
|
885
|
-
function
|
|
885
|
+
function Pt(i) {
|
|
886
886
|
return /^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/.test(i || "");
|
|
887
887
|
}
|
|
888
|
-
function
|
|
888
|
+
function $t(i) {
|
|
889
889
|
const t = /^rgb\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/.exec(i || "");
|
|
890
890
|
return t ? t.slice(1).every((e) => parseInt(e) >= 0 && parseInt(e) <= 255) : !1;
|
|
891
891
|
}
|
|
892
|
-
function
|
|
892
|
+
function qt(i) {
|
|
893
893
|
const t = /^rgba\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3}),\s*([01]|0\.\d+)\)$/.exec(i || "");
|
|
894
894
|
if (!t) return !1;
|
|
895
895
|
const [, e, s, n, r] = t;
|
|
896
896
|
return parseInt(e) >= 0 && parseInt(e) <= 255 && parseInt(s) >= 0 && parseInt(s) <= 255 && parseInt(n) >= 0 && parseInt(n) <= 255 && parseFloat(r) >= 0 && parseFloat(r) <= 1;
|
|
897
897
|
}
|
|
898
898
|
function yn(i) {
|
|
899
|
-
return
|
|
899
|
+
return Pt(i) || $t(i) || qt(i);
|
|
900
900
|
}
|
|
901
901
|
function vn(i) {
|
|
902
902
|
return !isNaN(new Date(i).getTime());
|
|
@@ -956,11 +956,11 @@ function zn(i, t) {
|
|
|
956
956
|
function Pn(i, t) {
|
|
957
957
|
return String(i) === String(t);
|
|
958
958
|
}
|
|
959
|
-
function
|
|
959
|
+
function Bt(i, t) {
|
|
960
960
|
return (i || "").includes(t);
|
|
961
961
|
}
|
|
962
962
|
function $n(i, t) {
|
|
963
|
-
return !
|
|
963
|
+
return !Bt(i, t);
|
|
964
964
|
}
|
|
965
965
|
function qn(i) {
|
|
966
966
|
return Array.isArray(i);
|
|
@@ -988,7 +988,7 @@ function Vn(i, t) {
|
|
|
988
988
|
r.forEach((o) => {
|
|
989
989
|
if (typeof o == "string") {
|
|
990
990
|
const [l, ...c] = o.split(":");
|
|
991
|
-
|
|
991
|
+
Ft[l](n, ...c) || a.push(l);
|
|
992
992
|
} else if (typeof o == "function") {
|
|
993
993
|
const l = o(n, i);
|
|
994
994
|
l !== !0 && a.push(l || "validation_failed");
|
|
@@ -996,7 +996,7 @@ function Vn(i, t) {
|
|
|
996
996
|
}), a.length > 0 && (e[s] = a);
|
|
997
997
|
}), { valid: Object.keys(e).length === 0, errors: e };
|
|
998
998
|
}
|
|
999
|
-
const
|
|
999
|
+
const Ft = { isEmail: dn, isPhone: un, isURL: pn, isIPv4: At, isIPv6: zt, isIP: fn, isIDCard: mn, isPassport: gn, isCreditCard: _n, isHexColor: Pt, isRGB: $t, isRGBA: qt, isColor: yn, isDate: vn, isJSON: bn, isEmpty: xn, isWhitespace: En, isNumber: kn, isInteger: wn, isFloat: Cn, isPositive: Sn, isNegative: Ln, isAlpha: Dn, isAlphaNumeric: Hn, isChinese: Mn, isLength: In, minLength: Tn, maxLength: An, matches: zn, equals: Pn, contains: Bt, notContains: $n, isArray: qn, arrayLength: Bn, arrayMinLength: Fn, arrayMaxLength: Nn, isObject: On, hasKeys: Rn, validate: Vn };
|
|
1000
1000
|
function Kn(i) {
|
|
1001
1001
|
const t = i ? String(i) : "", e = [1732584193, 4023233417, 2562383102, 271733878], s = [3614090360, 3905402710, 606105819, 3250441966, 4118548399, 1200080426, 2821735955, 4249261313, 1770035416, 2336552879, 4294925233, 2304563134, 1804603682, 4254626195, 2792965006, 1236535329, 4129170786, 3225465664, 643717713, 3921069994, 3593408605, 38016083, 3634488961, 3889429448, 568446438, 3275163606, 4107603335, 1163531501, 2850285829, 4243563512, 1735328473, 2368359562, 4294588738, 2272392833, 1839030562, 4259657740, 2763975236, 1272893353, 4139469664, 3200236656, 681279174, 3936430074, 3572445317, 76029189, 3654602809, 3873151461, 530742520, 3299628645, 4096336452, 1126891415, 2878612391, 4237533241, 1700485571, 2399980690, 4293915773, 2240044497, 1873313359, 4264355552, 2734768916, 1309151649, 4149444226, 3174756917, 718787259, 3951481745], n = [[7, 12, 17, 22], [5, 9, 14, 20], [4, 11, 16, 23], [6, 10, 15, 21]];
|
|
1002
1002
|
function r(d, u) {
|
|
@@ -1123,7 +1123,7 @@ async function Jn(i, t = {}) {
|
|
|
1123
1123
|
s.push(await j(n, t));
|
|
1124
1124
|
return s;
|
|
1125
1125
|
}
|
|
1126
|
-
async function
|
|
1126
|
+
async function Nt(i, t = {}) {
|
|
1127
1127
|
const { type: e = "text/javascript", async: s = !0, defer: n = !1 } = t;
|
|
1128
1128
|
return q.has(i) ? q.get(i) : new Promise((r, a) => {
|
|
1129
1129
|
const o = document.createElement("script");
|
|
@@ -1134,7 +1134,7 @@ async function Ft(i, t = {}) {
|
|
|
1134
1134
|
}, o.src = i, document.head.appendChild(o);
|
|
1135
1135
|
});
|
|
1136
1136
|
}
|
|
1137
|
-
async function
|
|
1137
|
+
async function Ot(i, t = {}) {
|
|
1138
1138
|
const { media: e = "all" } = t;
|
|
1139
1139
|
return q.has(i) ? q.get(i) : new Promise((s, n) => {
|
|
1140
1140
|
const r = document.createElement("link");
|
|
@@ -1158,10 +1158,10 @@ async function Zn(i, t = "image") {
|
|
|
1158
1158
|
case "image":
|
|
1159
1159
|
return j(i);
|
|
1160
1160
|
case "script":
|
|
1161
|
-
return
|
|
1161
|
+
return Nt(i);
|
|
1162
1162
|
case "stylesheet":
|
|
1163
1163
|
case "style":
|
|
1164
|
-
return
|
|
1164
|
+
return Ot(i);
|
|
1165
1165
|
default:
|
|
1166
1166
|
throw new Error(`Unsupported preload type: ${t}`);
|
|
1167
1167
|
}
|
|
@@ -1175,7 +1175,7 @@ function tr() {
|
|
|
1175
1175
|
function er(i) {
|
|
1176
1176
|
q.delete(i);
|
|
1177
1177
|
}
|
|
1178
|
-
const sr = { loadImage: j, loadImages: Jn, loadScript:
|
|
1178
|
+
const sr = { loadImage: j, loadImages: Jn, loadScript: Nt, loadStylesheet: Ot, loadFont: Gn, preload: Zn, isLoaded: Qn, clearCache: tr, clearCacheByUrl: er }, Da = {
|
|
1179
1179
|
string: je,
|
|
1180
1180
|
array: Bs,
|
|
1181
1181
|
object: ni,
|
|
@@ -1183,7 +1183,7 @@ const sr = { loadImage: j, loadImages: Jn, loadScript: Ft, loadStylesheet: Nt, l
|
|
|
1183
1183
|
date: ln,
|
|
1184
1184
|
debounce: cn,
|
|
1185
1185
|
throttle: hn,
|
|
1186
|
-
validator:
|
|
1186
|
+
validator: Ft,
|
|
1187
1187
|
crypto: jn,
|
|
1188
1188
|
preload: sr
|
|
1189
1189
|
};
|
|
@@ -1197,20 +1197,20 @@ function ir(i) {
|
|
|
1197
1197
|
while (t !== s);
|
|
1198
1198
|
return t = t.replace(/\bon\w+\s*=\s*(?:"[^"]*"|'[^']*'|[^\s>]+)/gi, ""), t = t.replace(/(href|src|action|background)\s*=\s*(?:"[^"]*(?:javascript|vbscript|data)\s*:[^"]*"|'[^']*(?:javascript|vbscript|data)\s*:[^']*'|[^\s>]*(?:javascript|vbscript|data)\s*:[^\s>]*)/gi, '$1=""'), t = t.replace(/expression\s*\([^)]*\)/gi, ""), t;
|
|
1199
1199
|
}
|
|
1200
|
-
class
|
|
1200
|
+
class pt {
|
|
1201
1201
|
constructor() {
|
|
1202
1202
|
this.children = {}, this.keys = [];
|
|
1203
1203
|
}
|
|
1204
1204
|
}
|
|
1205
|
-
class
|
|
1205
|
+
class st {
|
|
1206
1206
|
constructor() {
|
|
1207
|
-
this.root = new
|
|
1207
|
+
this.root = new pt();
|
|
1208
1208
|
}
|
|
1209
1209
|
insert(t) {
|
|
1210
1210
|
let e = this.root;
|
|
1211
1211
|
const s = t.split(".");
|
|
1212
1212
|
s.forEach((n, r) => {
|
|
1213
|
-
e.children[n] || (e.children[n] = new
|
|
1213
|
+
e.children[n] || (e.children[n] = new pt()), e = e.children[n], r === s.length - 1 && e.keys.push(t);
|
|
1214
1214
|
});
|
|
1215
1215
|
}
|
|
1216
1216
|
getSubKeys(t) {
|
|
@@ -1244,7 +1244,7 @@ const g = {
|
|
|
1244
1244
|
};
|
|
1245
1245
|
class nr {
|
|
1246
1246
|
constructor() {
|
|
1247
|
-
this.rawData = {}, this.data = null, this.observers = {}, this.elements = {}, this.computedProperties = {}, this.pathTrie = new
|
|
1247
|
+
this.rawData = {}, this.data = null, this.observers = {}, this.elements = {}, this.computedProperties = {}, this.pathTrie = new st(), this.updateQueue = /* @__PURE__ */ new Map(), this.isProcessing = !1, this.pendingComputed = /* @__PURE__ */ new Set(), this.persistedKeys = /* @__PURE__ */ new Map(), this.snapshots = [], this.snapshotLimit = 10, this._proxyCache = /* @__PURE__ */ new WeakMap(), this.createReactiveData();
|
|
1248
1248
|
}
|
|
1249
1249
|
createReactiveData() {
|
|
1250
1250
|
const t = {
|
|
@@ -1440,7 +1440,7 @@ class nr {
|
|
|
1440
1440
|
}), this.processComputed();
|
|
1441
1441
|
}
|
|
1442
1442
|
reset() {
|
|
1443
|
-
this.rawData = {}, this.observers = {}, this.elements = {}, this.computedProperties = {}, this.pathTrie = new
|
|
1443
|
+
this.rawData = {}, this.observers = {}, this.elements = {}, this.computedProperties = {}, this.pathTrie = new st(), this.updateQueue.clear(), this.snapshots = [], this.createReactiveData(), this.bind();
|
|
1444
1444
|
}
|
|
1445
1445
|
persist(t, e = {}) {
|
|
1446
1446
|
const {
|
|
@@ -1706,10 +1706,10 @@ class nr {
|
|
|
1706
1706
|
});
|
|
1707
1707
|
}), this.persistedKeys.forEach((t, e) => {
|
|
1708
1708
|
t.timeout && clearTimeout(t.timeout);
|
|
1709
|
-
}), this.persistedKeys.clear(), this.rawData = {}, this.observers = {}, this.elements = {}, this.computedProperties = {}, this.pathTrie = new
|
|
1709
|
+
}), this.persistedKeys.clear(), this.rawData = {}, this.observers = {}, this.elements = {}, this.computedProperties = {}, this.pathTrie = new st(), this.updateQueue.clear(), this.snapshots = [];
|
|
1710
1710
|
}
|
|
1711
1711
|
}
|
|
1712
|
-
class
|
|
1712
|
+
class ft {
|
|
1713
1713
|
constructor(t, e = {}) {
|
|
1714
1714
|
this.name = t, this._stateKey = `__store_${t}__`;
|
|
1715
1715
|
const s = e.state ? e.state() : {};
|
|
@@ -1784,14 +1784,14 @@ class rr {
|
|
|
1784
1784
|
this.stores = /* @__PURE__ */ new Map();
|
|
1785
1785
|
}
|
|
1786
1786
|
createStore(t, e) {
|
|
1787
|
-
const s = new
|
|
1787
|
+
const s = new ft(t, e);
|
|
1788
1788
|
return this.stores.set(t, s), s;
|
|
1789
1789
|
}
|
|
1790
1790
|
getStore(t) {
|
|
1791
1791
|
return this.stores.get(t);
|
|
1792
1792
|
}
|
|
1793
1793
|
registerStore(t) {
|
|
1794
|
-
t instanceof
|
|
1794
|
+
t instanceof ft && this.stores.set(t.name, t);
|
|
1795
1795
|
}
|
|
1796
1796
|
dispose() {
|
|
1797
1797
|
this.stores.clear();
|
|
@@ -1874,12 +1874,12 @@ function I(i = null) {
|
|
|
1874
1874
|
}
|
|
1875
1875
|
}), t;
|
|
1876
1876
|
}
|
|
1877
|
-
const F = new nr(), Ha = new ar(),
|
|
1877
|
+
const F = new nr(), Ha = new ar(), Rt = new rr();
|
|
1878
1878
|
function Ma(i, t) {
|
|
1879
|
-
return
|
|
1879
|
+
return Rt.createStore(i, t);
|
|
1880
1880
|
}
|
|
1881
1881
|
function Ia(i) {
|
|
1882
|
-
return
|
|
1882
|
+
return Rt.getStore(i);
|
|
1883
1883
|
}
|
|
1884
1884
|
const T = {
|
|
1885
1885
|
paths: {
|
|
@@ -1921,6 +1921,19 @@ const T = {
|
|
|
1921
1921
|
span: ["class", "style"],
|
|
1922
1922
|
div: ["class", "style"]
|
|
1923
1923
|
}
|
|
1924
|
+
},
|
|
1925
|
+
maskData: {
|
|
1926
|
+
enabled: !0,
|
|
1927
|
+
patterns: {
|
|
1928
|
+
phone: { regex: "^(\\d{3})\\d{4}(\\d{4})$", replace: "$1****$2" },
|
|
1929
|
+
email: { regex: "^(.)(.*)(@.*)$", replace: "$1***$3" },
|
|
1930
|
+
idCard: { regex: "^(\\d{6})\\d{8}(\\d{4})$", replace: "$1********$2" },
|
|
1931
|
+
bankCard: { regex: "^(\\d{4})\\d{8}(\\d{4})$", replace: "$1 **** **** $2" }
|
|
1932
|
+
}
|
|
1933
|
+
},
|
|
1934
|
+
secureId: {
|
|
1935
|
+
length: 16,
|
|
1936
|
+
charset: "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"
|
|
1924
1937
|
}
|
|
1925
1938
|
},
|
|
1926
1939
|
dev: {
|
|
@@ -1945,10 +1958,10 @@ const T = {
|
|
|
1945
1958
|
function Ta(i) {
|
|
1946
1959
|
Kt(T, i);
|
|
1947
1960
|
}
|
|
1948
|
-
function
|
|
1961
|
+
function ct(i) {
|
|
1949
1962
|
return i ? hr(T, i) : T;
|
|
1950
1963
|
}
|
|
1951
|
-
function
|
|
1964
|
+
function Vt() {
|
|
1952
1965
|
return T.paths.base + T.paths.icons.replace(/^\//, "");
|
|
1953
1966
|
}
|
|
1954
1967
|
function Aa() {
|
|
@@ -1966,7 +1979,7 @@ function za() {
|
|
|
1966
1979
|
function cr() {
|
|
1967
1980
|
return T.ui;
|
|
1968
1981
|
}
|
|
1969
|
-
function
|
|
1982
|
+
function tt() {
|
|
1970
1983
|
return T.security;
|
|
1971
1984
|
}
|
|
1972
1985
|
function Pa() {
|
|
@@ -2002,7 +2015,7 @@ const Wt = "kupola-theme", Ut = "kupola-brand", Y = [
|
|
|
2002
2015
|
function R() {
|
|
2003
2016
|
return localStorage.getItem(Wt) || or();
|
|
2004
2017
|
}
|
|
2005
|
-
function
|
|
2018
|
+
function nt(i) {
|
|
2006
2019
|
if (i !== "dark" && i !== "light") return;
|
|
2007
2020
|
document.documentElement.setAttribute("data-theme", i), localStorage.setItem(Wt, i);
|
|
2008
2021
|
const t = document.querySelector("[data-theme-toggle]");
|
|
@@ -2018,7 +2031,7 @@ function it(i) {
|
|
|
2018
2031
|
function X() {
|
|
2019
2032
|
return localStorage.getItem(Ut) || lr();
|
|
2020
2033
|
}
|
|
2021
|
-
function
|
|
2034
|
+
function rt(i) {
|
|
2022
2035
|
const t = Y.find((n) => n.id === i);
|
|
2023
2036
|
if (!t) return;
|
|
2024
2037
|
document.documentElement.setAttribute("data-brand", i), localStorage.setItem(Ut, i);
|
|
@@ -2034,26 +2047,26 @@ function nt(i) {
|
|
|
2034
2047
|
n.getAttribute("data-brand-btn") === i ? n.classList.add("is-active") : n.classList.remove("is-active");
|
|
2035
2048
|
});
|
|
2036
2049
|
}
|
|
2037
|
-
function
|
|
2050
|
+
function mt(i) {
|
|
2038
2051
|
const t = i.querySelector(".theme-icon");
|
|
2039
2052
|
if (t) {
|
|
2040
|
-
const e = R(), s =
|
|
2053
|
+
const e = R(), s = Vt();
|
|
2041
2054
|
t.src = e === "dark" ? s + "sun.svg" : s + "moon.svg";
|
|
2042
2055
|
}
|
|
2043
2056
|
}
|
|
2044
2057
|
function dr() {
|
|
2045
2058
|
const i = R();
|
|
2046
|
-
|
|
2059
|
+
nt(i);
|
|
2047
2060
|
const t = X();
|
|
2048
|
-
|
|
2061
|
+
rt(t);
|
|
2049
2062
|
const e = document.querySelector("[data-theme-toggle]");
|
|
2050
2063
|
if (e) {
|
|
2051
|
-
|
|
2064
|
+
mt(e);
|
|
2052
2065
|
const o = e.onclick;
|
|
2053
2066
|
e.onclick = function(l) {
|
|
2054
2067
|
l.preventDefault();
|
|
2055
2068
|
const h = R() === "dark" ? "light" : "dark";
|
|
2056
|
-
|
|
2069
|
+
nt(h), mt(e), typeof o == "function" && o.call(this, l);
|
|
2057
2070
|
};
|
|
2058
2071
|
}
|
|
2059
2072
|
let s = document.getElementById("brand-picker");
|
|
@@ -2078,7 +2091,7 @@ function dr() {
|
|
|
2078
2091
|
o.addEventListener("click", (l) => {
|
|
2079
2092
|
l.stopPropagation();
|
|
2080
2093
|
const c = o.getAttribute("data-brand-btn");
|
|
2081
|
-
|
|
2094
|
+
rt(c), s && (s.style.display = "none");
|
|
2082
2095
|
});
|
|
2083
2096
|
});
|
|
2084
2097
|
}
|
|
@@ -2087,11 +2100,11 @@ function Ba() {
|
|
|
2087
2100
|
i.setAttribute("data-theme-toggle", ""), i.setAttribute("data-current-theme", R()), i.className = "ds-btn ds-btn--ghost ds-btn--sm ds-btn--icon", i.style.position = "fixed", i.style.top = "16px", i.style.right = "16px", i.style.zIndex = "9999";
|
|
2088
2101
|
const t = document.createElement("img");
|
|
2089
2102
|
t.className = "theme-icon";
|
|
2090
|
-
const e =
|
|
2103
|
+
const e = Vt();
|
|
2091
2104
|
return t.src = R() === "dark" ? e + "sun.svg" : e + "moon.svg", t.width = 14, t.height = 14, t.alt = "Toggle theme", i.appendChild(t), document.body.appendChild(i), i.onclick = function(s) {
|
|
2092
2105
|
s.preventDefault();
|
|
2093
2106
|
const r = R() === "dark" ? "light" : "dark";
|
|
2094
|
-
|
|
2107
|
+
nt(r);
|
|
2095
2108
|
}, i;
|
|
2096
2109
|
}
|
|
2097
2110
|
function Fa() {
|
|
@@ -2121,12 +2134,12 @@ function Fa() {
|
|
|
2121
2134
|
a.addEventListener("click", (o) => {
|
|
2122
2135
|
o.stopPropagation();
|
|
2123
2136
|
const l = a.getAttribute("data-brand-btn");
|
|
2124
|
-
|
|
2137
|
+
rt(l), i.style.display = "none";
|
|
2125
2138
|
});
|
|
2126
2139
|
}), { toggleBtn: t, container: i };
|
|
2127
2140
|
}
|
|
2128
2141
|
function Na(i, t = {}) {
|
|
2129
|
-
const s =
|
|
2142
|
+
const s = tt()?.sanitizeHtml || {};
|
|
2130
2143
|
if (!s.enabled && !t.force)
|
|
2131
2144
|
return i;
|
|
2132
2145
|
const n = t.allowedTags || s.allowedTags || [], r = t.allowedAttributes || s.allowedAttributes || {};
|
|
@@ -2154,6 +2167,31 @@ function Oa(i) {
|
|
|
2154
2167
|
function Ra(i) {
|
|
2155
2168
|
return typeof i != "string" ? i : new DOMParser().parseFromString(i, "text/html").body.textContent || "";
|
|
2156
2169
|
}
|
|
2170
|
+
function Va(i, t, e = {}) {
|
|
2171
|
+
const n = tt()?.maskData || {};
|
|
2172
|
+
if (!n.enabled && !e.force || i == null)
|
|
2173
|
+
return i;
|
|
2174
|
+
const a = (e.patterns || n.patterns || {})[t];
|
|
2175
|
+
if (!a)
|
|
2176
|
+
return i;
|
|
2177
|
+
const o = typeof a.regex == "string" ? new RegExp(a.regex) : a.regex;
|
|
2178
|
+
return String(i).replace(o, a.replace);
|
|
2179
|
+
}
|
|
2180
|
+
function Ka(i, t) {
|
|
2181
|
+
const s = tt()?.secureId || {}, n = i || s.length || 16, r = s.charset || "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
|
|
2182
|
+
if (typeof crypto > "u" || !crypto.getRandomValues) {
|
|
2183
|
+
let l = "";
|
|
2184
|
+
for (let c = 0; c < n; c++)
|
|
2185
|
+
l += r[Math.floor(Math.random() * r.length)];
|
|
2186
|
+
return t ? `${t}_${l}` : l;
|
|
2187
|
+
}
|
|
2188
|
+
const a = new Uint32Array(n);
|
|
2189
|
+
crypto.getRandomValues(a);
|
|
2190
|
+
let o = "";
|
|
2191
|
+
for (let l = 0; l < n; l++)
|
|
2192
|
+
o += r[a[l] % r.length];
|
|
2193
|
+
return t ? `${t}_${o}` : o;
|
|
2194
|
+
}
|
|
2157
2195
|
class ur {
|
|
2158
2196
|
constructor() {
|
|
2159
2197
|
this.initializers = /* @__PURE__ */ new Map(), this.cleanupFunctions = /* @__PURE__ */ new Map(), this.processedElements = /* @__PURE__ */ new WeakSet(), this._dataAttrs = ["data-component"], this._cssClasses = [], this._cachedSelector = null;
|
|
@@ -2287,7 +2325,7 @@ for (const i of pr)
|
|
|
2287
2325
|
i.attr && !E._dataAttrs.includes(i.attr) && E._dataAttrs.push(i.attr), i.cls && !E._cssClasses.includes(i.cls) && E._cssClasses.push(i.cls);
|
|
2288
2326
|
class J {
|
|
2289
2327
|
constructor(t) {
|
|
2290
|
-
this.element = t, this.isMounted = !1, this.isDestroyed = !1, this.props = this._parseProps(), this.state = {}, this.slots = this._parseSlots(), this._eventListeners = {}, this._appliedMixins = [], this.lifecycle = new
|
|
2328
|
+
this.element = t, this.isMounted = !1, this.isDestroyed = !1, this.props = this._parseProps(), this.state = {}, this.slots = this._parseSlots(), this._eventListeners = {}, this._appliedMixins = [], this.lifecycle = new lt(), this.setupContext = null;
|
|
2291
2329
|
}
|
|
2292
2330
|
_parseProps() {
|
|
2293
2331
|
const t = {};
|
|
@@ -2420,7 +2458,7 @@ class J {
|
|
|
2420
2458
|
setup() {
|
|
2421
2459
|
}
|
|
2422
2460
|
}
|
|
2423
|
-
function
|
|
2461
|
+
function gt(i, t) {
|
|
2424
2462
|
Object.keys(t).forEach((e) => {
|
|
2425
2463
|
if (e !== "constructor")
|
|
2426
2464
|
if (typeof t[e] == "function") {
|
|
@@ -2476,7 +2514,7 @@ class fr {
|
|
|
2476
2514
|
useMixin(t, ...e) {
|
|
2477
2515
|
e.forEach((s) => {
|
|
2478
2516
|
const n = this.mixins.get(s);
|
|
2479
|
-
n &&
|
|
2517
|
+
n && gt(t, n);
|
|
2480
2518
|
});
|
|
2481
2519
|
}
|
|
2482
2520
|
async bootstrap(t = document) {
|
|
@@ -2517,7 +2555,7 @@ class fr {
|
|
|
2517
2555
|
const n = t.getAttribute("data-mixins"), r = s;
|
|
2518
2556
|
n && n.split(",").forEach((o) => {
|
|
2519
2557
|
const l = this.mixins.get(o.trim());
|
|
2520
|
-
l &&
|
|
2558
|
+
l && gt(r, l);
|
|
2521
2559
|
});
|
|
2522
2560
|
const a = new r(t);
|
|
2523
2561
|
t.__kupolaInstance = a, this.instances.set(t, a), a.mount();
|
|
@@ -2565,35 +2603,35 @@ class fr {
|
|
|
2565
2603
|
let M = null;
|
|
2566
2604
|
typeof window < "u" && (M = new fr());
|
|
2567
2605
|
function mr() {
|
|
2568
|
-
if (
|
|
2606
|
+
if (tt().xssProtection && typeof document < "u") {
|
|
2569
2607
|
let t = document.querySelector('meta[http-equiv="X-XSS-Protection"]');
|
|
2570
2608
|
t || (t = document.createElement("meta"), t.setAttribute("http-equiv", "X-XSS-Protection"), t.setAttribute("content", "1; mode=block"), document.head.insertBefore(t, document.head.firstChild)), t = document.querySelector('meta[http-equiv="X-Content-Type-Options"]'), t || (t = document.createElement("meta"), t.setAttribute("http-equiv", "X-Content-Type-Options"), t.setAttribute("content", "nosniff"), document.head.insertBefore(t, document.head.firstChild)), t = document.querySelector('meta[http-equiv="X-Frame-Options"]'), t || (t = document.createElement("meta"), t.setAttribute("http-equiv", "X-Frame-Options"), t.setAttribute("content", "SAMEORIGIN"), document.head.insertBefore(t, document.head.firstChild));
|
|
2571
2609
|
}
|
|
2572
2610
|
}
|
|
2573
|
-
async function
|
|
2611
|
+
async function _t() {
|
|
2574
2612
|
if (typeof window < "u") {
|
|
2575
2613
|
mr();
|
|
2576
|
-
const i =
|
|
2614
|
+
const i = ct();
|
|
2577
2615
|
F.loadPersisted(), F.bind(), dr(), i.components?.autoInit !== !1 && (await E.initializeAll(), M && await M.bootstrap());
|
|
2578
2616
|
}
|
|
2579
2617
|
}
|
|
2580
|
-
typeof document < "u" && document.readyState === "loading" ? document.addEventListener("DOMContentLoaded",
|
|
2581
|
-
function
|
|
2618
|
+
typeof document < "u" && document.readyState === "loading" ? document.addEventListener("DOMContentLoaded", _t) : typeof window < "u" && setTimeout(_t, 0);
|
|
2619
|
+
function Wa(i, t) {
|
|
2582
2620
|
M && M.register(i, t);
|
|
2583
2621
|
}
|
|
2584
|
-
function
|
|
2622
|
+
function Ua(i, t) {
|
|
2585
2623
|
M && M.registerLazy(i, t);
|
|
2586
2624
|
}
|
|
2587
|
-
function
|
|
2625
|
+
function Ya(i) {
|
|
2588
2626
|
return M ? M.bootstrap(i) : Promise.resolve();
|
|
2589
2627
|
}
|
|
2590
|
-
function
|
|
2628
|
+
function Xa(i, t) {
|
|
2591
2629
|
M && M.defineMixin(i, t);
|
|
2592
2630
|
}
|
|
2593
|
-
function
|
|
2631
|
+
function ja(i, ...t) {
|
|
2594
2632
|
M && M.useMixin(i, ...t);
|
|
2595
2633
|
}
|
|
2596
|
-
function
|
|
2634
|
+
function Ja(i, t) {
|
|
2597
2635
|
if (!t || typeof t != "object")
|
|
2598
2636
|
throw new Error(`defineComponent("${i}"): options must be an object`);
|
|
2599
2637
|
t.componentClass ? M && M.register(i, t.componentClass) : t.lazy && M && M.registerLazy(i, t.lazy), t.init ? E.register(i, t.init, t.cleanup || null, {
|
|
@@ -2607,7 +2645,7 @@ function Xa(i, t) {
|
|
|
2607
2645
|
}
|
|
2608
2646
|
class Yt {
|
|
2609
2647
|
constructor(t = {}) {
|
|
2610
|
-
const e =
|
|
2648
|
+
const e = ct();
|
|
2611
2649
|
this.locales = t.locales || {}, this.currentLocale = t.defaultLocale || e.i18n?.locale || "zh-CN", this.fallbackLocale = t.fallbackLocale || e.i18n?.fallbackLocale || "en-US", this.delimiter = t.delimiter || ".", this.missingHandler = t.missingHandler || ((s) => (console.warn(`Missing translation: ${s}`), s)), this._initFromDOM();
|
|
2612
2650
|
}
|
|
2613
2651
|
_initFromDOM() {
|
|
@@ -2704,28 +2742,28 @@ class Yt {
|
|
|
2704
2742
|
}
|
|
2705
2743
|
}
|
|
2706
2744
|
const O = new Yt();
|
|
2707
|
-
function
|
|
2745
|
+
function Ga(i) {
|
|
2708
2746
|
return new Yt(i);
|
|
2709
2747
|
}
|
|
2710
|
-
function
|
|
2748
|
+
function Za(i, t = {}) {
|
|
2711
2749
|
return O.t(i, t);
|
|
2712
2750
|
}
|
|
2713
|
-
function
|
|
2751
|
+
function Qa(i, t, e = {}) {
|
|
2714
2752
|
return O.n(i, t, e);
|
|
2715
2753
|
}
|
|
2716
|
-
function
|
|
2754
|
+
function to(i) {
|
|
2717
2755
|
return O.setLocale(i);
|
|
2718
2756
|
}
|
|
2719
|
-
function
|
|
2757
|
+
function eo() {
|
|
2720
2758
|
return O.getLocale();
|
|
2721
2759
|
}
|
|
2722
|
-
function
|
|
2760
|
+
function so(i, t = {}) {
|
|
2723
2761
|
return O.formatDate(i, t);
|
|
2724
2762
|
}
|
|
2725
|
-
function
|
|
2763
|
+
function io(i, t = {}) {
|
|
2726
2764
|
return O.formatNumber(i, t);
|
|
2727
2765
|
}
|
|
2728
|
-
function
|
|
2766
|
+
function no(i, t, e = {}) {
|
|
2729
2767
|
return O.formatCurrency(i, t, e);
|
|
2730
2768
|
}
|
|
2731
2769
|
class gr {
|
|
@@ -2859,28 +2897,28 @@ class gr {
|
|
|
2859
2897
|
}
|
|
2860
2898
|
}
|
|
2861
2899
|
const H = new gr();
|
|
2862
|
-
function
|
|
2900
|
+
function ro(i, t, e, s) {
|
|
2863
2901
|
return H.on(i, t, e, s);
|
|
2864
2902
|
}
|
|
2865
|
-
function
|
|
2903
|
+
function ao(i, t, e, s) {
|
|
2866
2904
|
return H.once(i, t, e, s);
|
|
2867
2905
|
}
|
|
2868
|
-
function
|
|
2906
|
+
function oo(i, t, e) {
|
|
2869
2907
|
H.off(i, t, e);
|
|
2870
2908
|
}
|
|
2871
|
-
function
|
|
2909
|
+
function lo(i, t, e) {
|
|
2872
2910
|
return H.emit(i, t, e);
|
|
2873
2911
|
}
|
|
2874
|
-
function
|
|
2912
|
+
function co(i, t) {
|
|
2875
2913
|
return H.emitGlobal(i, t);
|
|
2876
2914
|
}
|
|
2877
|
-
function
|
|
2915
|
+
function ho(i) {
|
|
2878
2916
|
H.offByScope(i);
|
|
2879
2917
|
}
|
|
2880
|
-
function
|
|
2918
|
+
function uo(i, t) {
|
|
2881
2919
|
H.offAll(i, t);
|
|
2882
2920
|
}
|
|
2883
|
-
function
|
|
2921
|
+
function po(i, t) {
|
|
2884
2922
|
return H.getListenerCount(i, t);
|
|
2885
2923
|
}
|
|
2886
2924
|
class _r {
|
|
@@ -2989,7 +3027,7 @@ function Xt(i, t) {
|
|
|
2989
3027
|
const e = new _r(i, t);
|
|
2990
3028
|
e.init(), i._kupolaDropdown = e;
|
|
2991
3029
|
}
|
|
2992
|
-
function
|
|
3030
|
+
function fo(i = document) {
|
|
2993
3031
|
i.querySelectorAll(".ds-dropdown").forEach((t) => {
|
|
2994
3032
|
Xt(t);
|
|
2995
3033
|
});
|
|
@@ -2997,7 +3035,7 @@ function uo(i = document) {
|
|
|
2997
3035
|
function jt(i) {
|
|
2998
3036
|
i._kupolaDropdown && (i._kupolaDropdown.destroy(), i._kupolaDropdown = null);
|
|
2999
3037
|
}
|
|
3000
|
-
function
|
|
3038
|
+
function mo() {
|
|
3001
3039
|
document.querySelectorAll(".ds-dropdown").forEach((i) => {
|
|
3002
3040
|
jt(i);
|
|
3003
3041
|
});
|
|
@@ -3220,7 +3258,7 @@ function Jt(i, t) {
|
|
|
3220
3258
|
const e = new yr(i, t);
|
|
3221
3259
|
e.init(), i._kupolaSelect = e;
|
|
3222
3260
|
}
|
|
3223
|
-
function
|
|
3261
|
+
function go(i = document) {
|
|
3224
3262
|
i.querySelectorAll(".ds-select").forEach((t) => {
|
|
3225
3263
|
Jt(t);
|
|
3226
3264
|
});
|
|
@@ -3471,7 +3509,7 @@ function Gt(i, t) {
|
|
|
3471
3509
|
const e = new br(i, t);
|
|
3472
3510
|
e.init(), i._kupolaDatepicker = e;
|
|
3473
3511
|
}
|
|
3474
|
-
function
|
|
3512
|
+
function _o(i = document) {
|
|
3475
3513
|
i.querySelectorAll(".ds-datepicker").forEach((t) => {
|
|
3476
3514
|
Gt(t);
|
|
3477
3515
|
});
|
|
@@ -3666,7 +3704,7 @@ function Zt(i, t) {
|
|
|
3666
3704
|
const e = new Er(i, t);
|
|
3667
3705
|
e.init(), i._kupolaTimepicker = e;
|
|
3668
3706
|
}
|
|
3669
|
-
function
|
|
3707
|
+
function yo(i = document) {
|
|
3670
3708
|
i.querySelectorAll(".ds-timepicker").forEach((t) => {
|
|
3671
3709
|
Zt(t);
|
|
3672
3710
|
});
|
|
@@ -3836,7 +3874,7 @@ function Cr(i) {
|
|
|
3836
3874
|
if (!i.__kupolaInitialized || !i.__kupolaInstance) return;
|
|
3837
3875
|
i.__kupolaInstance.destroy(), i.__kupolaInstance = null, i.__kupolaInitialized = !1;
|
|
3838
3876
|
}
|
|
3839
|
-
function
|
|
3877
|
+
function vo() {
|
|
3840
3878
|
document.querySelectorAll(".ds-slider").forEach((i) => {
|
|
3841
3879
|
Qt(i);
|
|
3842
3880
|
});
|
|
@@ -3928,7 +3966,7 @@ function te(i, t) {
|
|
|
3928
3966
|
const e = new Sr(i, t);
|
|
3929
3967
|
i.__kupolaInstance = e, i.__kupolaInitialized = !0;
|
|
3930
3968
|
}
|
|
3931
|
-
function
|
|
3969
|
+
function bo(i = document) {
|
|
3932
3970
|
i.querySelectorAll(".ds-carousel").forEach((t) => {
|
|
3933
3971
|
te(t);
|
|
3934
3972
|
});
|
|
@@ -3975,7 +4013,7 @@ class Dr {
|
|
|
3975
4013
|
return this.drawerEl?.classList.contains("is-visible") || !1;
|
|
3976
4014
|
}
|
|
3977
4015
|
}
|
|
3978
|
-
function
|
|
4016
|
+
function at(i, t) {
|
|
3979
4017
|
if (i.__kupolaInitialized) return;
|
|
3980
4018
|
const e = new Dr(i, t);
|
|
3981
4019
|
i.__kupolaInstance = e, i.__kupolaInitialized = !0;
|
|
@@ -3984,11 +4022,11 @@ function Hr(i) {
|
|
|
3984
4022
|
if (!i.__kupolaInitialized || !i.__kupolaInstance) return;
|
|
3985
4023
|
i.__kupolaInstance.destroy(), i.__kupolaInstance = null, i.__kupolaInitialized = !1;
|
|
3986
4024
|
}
|
|
3987
|
-
function
|
|
4025
|
+
function xo() {
|
|
3988
4026
|
document.querySelectorAll("[data-drawer]").forEach((i) => {
|
|
3989
4027
|
i.addEventListener("click", () => {
|
|
3990
4028
|
const t = i.getAttribute("data-drawer"), e = document.getElementById(t);
|
|
3991
|
-
e && (
|
|
4029
|
+
e && (at(e, {
|
|
3992
4030
|
placement: i.getAttribute("data-drawer-placement") || "right",
|
|
3993
4031
|
width: i.getAttribute("data-drawer-width"),
|
|
3994
4032
|
height: i.getAttribute("data-drawer-height")
|
|
@@ -3996,10 +4034,10 @@ function vo() {
|
|
|
3996
4034
|
});
|
|
3997
4035
|
}), document.querySelectorAll(".ds-drawer-mask").forEach((i) => {
|
|
3998
4036
|
const t = i.parentElement;
|
|
3999
|
-
t &&
|
|
4037
|
+
t && at(t);
|
|
4000
4038
|
});
|
|
4001
4039
|
}
|
|
4002
|
-
E.register("drawer",
|
|
4040
|
+
E.register("drawer", at, Hr);
|
|
4003
4041
|
class $ {
|
|
4004
4042
|
constructor(t, e = {}) {
|
|
4005
4043
|
this.element = t, this.mask = t.querySelector(".ds-modal-mask"), this.modal = t.querySelector(".ds-modal"), this.closeBtn = t.querySelector(".ds-modal__close"), this.fullscreen = e.fullscreen || t.hasAttribute("data-modal-fullscreen"), this.closableOnMask = e.closableOnMask !== !1, this.escClose = e.escClose !== !1, this.width = e.width || t.getAttribute("data-modal-width") || "", this.center = e.center !== !1, this.onBeforeOpen = e.onBeforeOpen || null, this.onBeforeClose = e.onBeforeClose || null, this.onOpened = e.onOpened || null, this.onClosed = e.onClosed || null, this._isOpen = !1, this._keydownHandler = (s) => {
|
|
@@ -4082,8 +4120,8 @@ function ee(i = {}) {
|
|
|
4082
4120
|
const z = C.querySelector(".ds-modal__body");
|
|
4083
4121
|
z && (s ? z.innerHTML = e : z.textContent = e);
|
|
4084
4122
|
const D = C.querySelector("[data-modal-confirm]"), B = C.querySelector("[data-modal-cancel]");
|
|
4085
|
-
let
|
|
4086
|
-
const
|
|
4123
|
+
let ht = !1;
|
|
4124
|
+
const dt = async () => {
|
|
4087
4125
|
if (p) {
|
|
4088
4126
|
D.disabled = !0, D.classList.add("is-loading");
|
|
4089
4127
|
try {
|
|
@@ -4096,28 +4134,28 @@ function ee(i = {}) {
|
|
|
4096
4134
|
return;
|
|
4097
4135
|
}
|
|
4098
4136
|
}
|
|
4099
|
-
|
|
4100
|
-
},
|
|
4137
|
+
ht = !0, w.close();
|
|
4138
|
+
}, ut = () => {
|
|
4101
4139
|
m && m(), w.close();
|
|
4102
4140
|
};
|
|
4103
|
-
D && D.addEventListener("click",
|
|
4141
|
+
D && D.addEventListener("click", dt), B && B.addEventListener("click", ut);
|
|
4104
4142
|
const Ee = () => {
|
|
4105
4143
|
setTimeout(() => {
|
|
4106
|
-
D && D.removeEventListener("click",
|
|
4144
|
+
D && D.removeEventListener("click", dt), B && B.removeEventListener("click", ut), w.destroy(), C.remove(), _ && _(ht);
|
|
4107
4145
|
}, 300);
|
|
4108
4146
|
}, ke = w.close.bind(w);
|
|
4109
4147
|
return w.close = () => {
|
|
4110
4148
|
ke(), Ee();
|
|
4111
4149
|
}, w.open(), y && setTimeout(() => y(), 50), w;
|
|
4112
4150
|
}
|
|
4113
|
-
function
|
|
4151
|
+
function Eo(i) {
|
|
4114
4152
|
return typeof i == "string" && (i = { content: i }), ee({
|
|
4115
4153
|
...i,
|
|
4116
4154
|
showCancel: !0,
|
|
4117
4155
|
showConfirm: !0
|
|
4118
4156
|
});
|
|
4119
4157
|
}
|
|
4120
|
-
function
|
|
4158
|
+
function ko(i) {
|
|
4121
4159
|
return typeof i == "string" && (i = { content: i }), ee({
|
|
4122
4160
|
...i,
|
|
4123
4161
|
showCancel: !1,
|
|
@@ -4133,13 +4171,13 @@ function Mr(i) {
|
|
|
4133
4171
|
if (!i.__kupolaInitialized || !i.__kupolaInstance) return;
|
|
4134
4172
|
i.__kupolaInstance.destroy(), i.__kupolaInstance = null, i.__kupolaInitialized = !1;
|
|
4135
4173
|
}
|
|
4136
|
-
function
|
|
4174
|
+
function wo() {
|
|
4137
4175
|
document.querySelectorAll(".ds-modal-container").forEach((i) => {
|
|
4138
4176
|
se(i);
|
|
4139
4177
|
});
|
|
4140
4178
|
}
|
|
4141
4179
|
E.register("modal", se, Mr);
|
|
4142
|
-
class
|
|
4180
|
+
class Co {
|
|
4143
4181
|
static normal(t = {}) {
|
|
4144
4182
|
return this._create({ type: "normal", ...t });
|
|
4145
4183
|
}
|
|
@@ -4204,7 +4242,7 @@ class ko {
|
|
|
4204
4242
|
return c.classList.add("is-visible"), document.body.style.overflow = "hidden", h && h.addEventListener("click", p), d && d.addEventListener("click", m), c.addEventListener("click", f), document.addEventListener("keydown", u), { close: y };
|
|
4205
4243
|
}
|
|
4206
4244
|
}
|
|
4207
|
-
const
|
|
4245
|
+
const So = {
|
|
4208
4246
|
normal: function(i) {
|
|
4209
4247
|
this.show({ ...i, type: "normal" });
|
|
4210
4248
|
},
|
|
@@ -4250,9 +4288,9 @@ const wo = {
|
|
|
4250
4288
|
}, n);
|
|
4251
4289
|
}
|
|
4252
4290
|
};
|
|
4253
|
-
function
|
|
4291
|
+
function Lo() {
|
|
4254
4292
|
}
|
|
4255
|
-
const
|
|
4293
|
+
const Do = {
|
|
4256
4294
|
normal: function(i, t = {}) {
|
|
4257
4295
|
this.show(i, "normal", t);
|
|
4258
4296
|
},
|
|
@@ -4290,9 +4328,9 @@ const So = {
|
|
|
4290
4328
|
}, s);
|
|
4291
4329
|
}
|
|
4292
4330
|
};
|
|
4293
|
-
function
|
|
4331
|
+
function Ho() {
|
|
4294
4332
|
}
|
|
4295
|
-
function
|
|
4333
|
+
function yt(i) {
|
|
4296
4334
|
return i ? i.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """).replace(/'/g, "'") : "";
|
|
4297
4335
|
}
|
|
4298
4336
|
class Ir {
|
|
@@ -4351,7 +4389,7 @@ class Ir {
|
|
|
4351
4389
|
<div class="ds-fileupload__icon" style="width: 24px; height: 24px; border-radius: 4px;">
|
|
4352
4390
|
${s}
|
|
4353
4391
|
</div>
|
|
4354
|
-
<span class="ds-fileupload__filename">${this.truncateFilename(
|
|
4392
|
+
<span class="ds-fileupload__filename">${this.truncateFilename(yt(t.name))}</span>
|
|
4355
4393
|
<span class="ds-fileupload__size">${this.formatSize(t.size)}</span>
|
|
4356
4394
|
<button class="ds-fileupload__remove" type="button" aria-label="Remove file">
|
|
4357
4395
|
<svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
|
@@ -4403,7 +4441,7 @@ class Ir {
|
|
|
4403
4441
|
e.onload = (s) => {
|
|
4404
4442
|
const n = document.createElement("div");
|
|
4405
4443
|
n.className = "ds-fileupload__preview-item", n.innerHTML = `
|
|
4406
|
-
<img src="${s.target.result}" alt="${
|
|
4444
|
+
<img src="${s.target.result}" alt="${yt(t.name)}">
|
|
4407
4445
|
<button class="ds-fileupload__preview-remove" type="button" aria-label="Remove preview">
|
|
4408
4446
|
<svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
|
4409
4447
|
<path d="M18 6L6 18"/>
|
|
@@ -4462,7 +4500,7 @@ function Tr(i) {
|
|
|
4462
4500
|
if (!i.__kupolaInitialized || !i.__kupolaInstance) return;
|
|
4463
4501
|
i.__kupolaInstance.destroy(), i.__kupolaInstance = null, i.__kupolaInitialized = !1;
|
|
4464
4502
|
}
|
|
4465
|
-
function
|
|
4503
|
+
function Mo() {
|
|
4466
4504
|
document.querySelectorAll(".ds-fileupload").forEach((i) => {
|
|
4467
4505
|
ie(i);
|
|
4468
4506
|
});
|
|
@@ -4559,7 +4597,7 @@ function zr(i) {
|
|
|
4559
4597
|
if (!i.__kupolaInitialized || !i.__kupolaInstance) return;
|
|
4560
4598
|
i.__kupolaInstance.destroy(), i.__kupolaInstance = null, i.__kupolaInitialized = !1;
|
|
4561
4599
|
}
|
|
4562
|
-
function
|
|
4600
|
+
function Io() {
|
|
4563
4601
|
document.querySelectorAll(".ds-collapse").forEach((i) => {
|
|
4564
4602
|
ne(i);
|
|
4565
4603
|
});
|
|
@@ -4734,7 +4772,7 @@ function re(i, t) {
|
|
|
4734
4772
|
const e = new Pr(i, t);
|
|
4735
4773
|
e.init(), i._kupolaColorPicker = e;
|
|
4736
4774
|
}
|
|
4737
|
-
function
|
|
4775
|
+
function To(i = document) {
|
|
4738
4776
|
i.querySelectorAll(".ds-color-picker").forEach((t) => {
|
|
4739
4777
|
re(t);
|
|
4740
4778
|
});
|
|
@@ -4953,7 +4991,7 @@ function Br(i) {
|
|
|
4953
4991
|
if (!i.__kupolaInitialized || !i.__kupolaInstance) return;
|
|
4954
4992
|
i.__kupolaInstance.destroy(), i.__kupolaInstance = null, i.__kupolaInitialized = !1;
|
|
4955
4993
|
}
|
|
4956
|
-
function
|
|
4994
|
+
function Ao() {
|
|
4957
4995
|
document.querySelectorAll(".ds-calendar").forEach((i) => {
|
|
4958
4996
|
ae(i);
|
|
4959
4997
|
});
|
|
@@ -5114,7 +5152,7 @@ function Nr(i) {
|
|
|
5114
5152
|
if (!i.__kupolaInitialized || !i.__kupolaInstance) return;
|
|
5115
5153
|
i.__kupolaInstance.destroy(), i.__kupolaInstance = null, i.__kupolaInitialized = !1;
|
|
5116
5154
|
}
|
|
5117
|
-
function
|
|
5155
|
+
function zo() {
|
|
5118
5156
|
document.querySelectorAll(".ds-dynamic-tags").forEach((i) => {
|
|
5119
5157
|
oe(i);
|
|
5120
5158
|
});
|
|
@@ -5312,7 +5350,7 @@ class le {
|
|
|
5312
5350
|
}
|
|
5313
5351
|
}
|
|
5314
5352
|
let V = null;
|
|
5315
|
-
function
|
|
5353
|
+
function Po() {
|
|
5316
5354
|
V || (V = new le()), document.querySelectorAll("[data-image-preview]").forEach((i) => {
|
|
5317
5355
|
i.addEventListener("click", () => {
|
|
5318
5356
|
const t = JSON.parse(i.getAttribute("data-image-preview")), e = parseInt(i.getAttribute("data-image-index")) || 0;
|
|
@@ -5320,7 +5358,7 @@ function Ao() {
|
|
|
5320
5358
|
});
|
|
5321
5359
|
});
|
|
5322
5360
|
}
|
|
5323
|
-
function
|
|
5361
|
+
function $o(i, t = 0) {
|
|
5324
5362
|
V || (V = new le()), V.show(i, t);
|
|
5325
5363
|
}
|
|
5326
5364
|
class Or {
|
|
@@ -5462,7 +5500,7 @@ function Rr(i) {
|
|
|
5462
5500
|
if (!i.__kupolaInitialized || !i.__kupolaInstance) return;
|
|
5463
5501
|
i.__kupolaInstance.destroy(), i.__kupolaInstance = null, i.__kupolaInitialized = !1;
|
|
5464
5502
|
}
|
|
5465
|
-
function
|
|
5503
|
+
function qo() {
|
|
5466
5504
|
document.querySelectorAll(".ds-tag").forEach((i) => {
|
|
5467
5505
|
ce(i);
|
|
5468
5506
|
});
|
|
@@ -5537,7 +5575,7 @@ function Kr(i) {
|
|
|
5537
5575
|
if (!i.__kupolaInitialized || !i.__kupolaInstance) return;
|
|
5538
5576
|
i.__kupolaInstance.destroy(), i.__kupolaInstance = null, i.__kupolaInitialized = !1;
|
|
5539
5577
|
}
|
|
5540
|
-
function
|
|
5578
|
+
function Bo() {
|
|
5541
5579
|
document.querySelectorAll(".ds-statcard").forEach((i) => {
|
|
5542
5580
|
he(i);
|
|
5543
5581
|
});
|
|
@@ -5706,10 +5744,10 @@ function de(i) {
|
|
|
5706
5744
|
try {
|
|
5707
5745
|
e = JSON.parse(t);
|
|
5708
5746
|
} catch {
|
|
5709
|
-
e =
|
|
5747
|
+
e = vt();
|
|
5710
5748
|
}
|
|
5711
5749
|
else
|
|
5712
|
-
e =
|
|
5750
|
+
e = vt();
|
|
5713
5751
|
const s = new Wr(i, {
|
|
5714
5752
|
data: e,
|
|
5715
5753
|
onCellClick: (n) => {
|
|
@@ -5721,12 +5759,12 @@ function Ur(i) {
|
|
|
5721
5759
|
if (!i.__kupolaInitialized || !i.__kupolaInstance) return;
|
|
5722
5760
|
i.__kupolaInstance.destroy(), i.__kupolaInstance = null, i.__kupolaInitialized = !1;
|
|
5723
5761
|
}
|
|
5724
|
-
function
|
|
5762
|
+
function Fo() {
|
|
5725
5763
|
document.querySelectorAll(".ds-heatmap").forEach((i) => {
|
|
5726
5764
|
de(i);
|
|
5727
5765
|
});
|
|
5728
5766
|
}
|
|
5729
|
-
function
|
|
5767
|
+
function vt() {
|
|
5730
5768
|
const i = [], t = /* @__PURE__ */ new Date(), e = /* @__PURE__ */ new Date();
|
|
5731
5769
|
e.setFullYear(e.getFullYear() - 1);
|
|
5732
5770
|
for (let s = new Date(e); s <= t; s.setDate(s.getDate() + 1)) {
|
|
@@ -5834,7 +5872,7 @@ function ue(i, t) {
|
|
|
5834
5872
|
const e = new Yr(i, t);
|
|
5835
5873
|
e.init(), i._kupolaTooltip = e;
|
|
5836
5874
|
}
|
|
5837
|
-
function
|
|
5875
|
+
function No(i = document) {
|
|
5838
5876
|
i.querySelectorAll("[data-tooltip]").forEach((t) => {
|
|
5839
5877
|
ue(t);
|
|
5840
5878
|
});
|
|
@@ -6361,7 +6399,7 @@ class Jr {
|
|
|
6361
6399
|
}), this.data = [], this.dynamicHeightCache.clear(), this.container.innerHTML = "", this._listeners = null, this._scrollHandler = null, this._thumbDragStartHandler = null, this._thumbDragMoveHandler = null, this._thumbDragEndHandler = null, this._wheelHandler = null, this.container = null, this.scrollbarThumb = null, this.element = null;
|
|
6362
6400
|
}
|
|
6363
6401
|
}
|
|
6364
|
-
function
|
|
6402
|
+
function bt(i = 1e3) {
|
|
6365
6403
|
const t = [], e = ["Document", "Image", "Video", "Folder", "Archive", "Spreadsheet", "Presentation", "Code"];
|
|
6366
6404
|
for (let s = 1; s <= i; s++) {
|
|
6367
6405
|
const n = Math.floor(Math.random() * e.length), r = Math.floor(Math.random() * 1e4);
|
|
@@ -6382,10 +6420,10 @@ function Gr(i) {
|
|
|
6382
6420
|
try {
|
|
6383
6421
|
e = JSON.parse(t);
|
|
6384
6422
|
} catch {
|
|
6385
|
-
e =
|
|
6423
|
+
e = bt(1e3);
|
|
6386
6424
|
}
|
|
6387
6425
|
else
|
|
6388
|
-
e =
|
|
6426
|
+
e = bt(1e3);
|
|
6389
6427
|
const s = new Jr(i, {
|
|
6390
6428
|
data: e,
|
|
6391
6429
|
onItemClick: (n) => {
|
|
@@ -6514,14 +6552,14 @@ function fe(i, t = 16, e = "0 0 24 24") {
|
|
|
6514
6552
|
const s = pe[i];
|
|
6515
6553
|
return s ? `<svg ${Qr.replace('width="16"', `width="${t}"`).replace('height="16"', `height="${t}"`).replace('viewBox="0 0 24 24"', `viewBox="${e}"`)}>${s}</svg>` : "";
|
|
6516
6554
|
}
|
|
6517
|
-
function
|
|
6555
|
+
function ot(i = document) {
|
|
6518
6556
|
i.querySelectorAll("[data-icon]").forEach((t) => {
|
|
6519
6557
|
const e = t.getAttribute("data-icon"), s = +t.getAttribute("data-size") || 16, n = t.getAttribute("data-viewbox") || "0 0 24 24";
|
|
6520
6558
|
t.innerHTML = fe(e, s, n), t.classList.add("icon");
|
|
6521
6559
|
});
|
|
6522
6560
|
}
|
|
6523
|
-
const
|
|
6524
|
-
typeof document < "u" && (document.readyState !== "loading" ?
|
|
6561
|
+
const Oo = { svg: fe, render: ot, PATHS: pe };
|
|
6562
|
+
typeof document < "u" && (document.readyState !== "loading" ? ot() : document.addEventListener("DOMContentLoaded", () => ot()));
|
|
6525
6563
|
class ta {
|
|
6526
6564
|
constructor(t) {
|
|
6527
6565
|
this.element = t, this.hoursEl = t.querySelector(".ds-countdown__item--hours .ds-countdown__value"), this.minutesEl = t.querySelector(".ds-countdown__item--minutes .ds-countdown__value"), this.secondsEl = t.querySelector(".ds-countdown__item--seconds .ds-countdown__value"), this.endTime = this.parseEndTime(), this.interval = null, this.init();
|
|
@@ -6583,7 +6621,7 @@ function ea(i) {
|
|
|
6583
6621
|
if (!i.__kupolaInitialized || !i.__kupolaInstance) return;
|
|
6584
6622
|
i.__kupolaInstance.destroy(), i.__kupolaInstance = null, i.__kupolaInitialized = !1;
|
|
6585
6623
|
}
|
|
6586
|
-
function
|
|
6624
|
+
function Ro() {
|
|
6587
6625
|
document.querySelectorAll(".ds-countdown").forEach((t) => {
|
|
6588
6626
|
me(t);
|
|
6589
6627
|
});
|
|
@@ -6653,7 +6691,7 @@ function ia(i) {
|
|
|
6653
6691
|
if (!i.__kupolaInitialized || !i.__kupolaInstance) return;
|
|
6654
6692
|
i.__kupolaInstance.destroy(), i.__kupolaInstance = null, i.__kupolaInitialized = !1;
|
|
6655
6693
|
}
|
|
6656
|
-
function
|
|
6694
|
+
function Vo() {
|
|
6657
6695
|
document.querySelectorAll(".ds-number-input").forEach((i) => {
|
|
6658
6696
|
ge(i);
|
|
6659
6697
|
});
|
|
@@ -6965,10 +7003,10 @@ function ca(i) {
|
|
|
6965
7003
|
e._kupolaForm = s;
|
|
6966
7004
|
}), t.length;
|
|
6967
7005
|
}
|
|
6968
|
-
function
|
|
7006
|
+
function Ko(i) {
|
|
6969
7007
|
return i._kupolaForm;
|
|
6970
7008
|
}
|
|
6971
|
-
function
|
|
7009
|
+
function Wo(i) {
|
|
6972
7010
|
const t = i._kupolaForm;
|
|
6973
7011
|
return t ? t.validate() : !1;
|
|
6974
7012
|
}
|
|
@@ -7043,17 +7081,17 @@ class N extends Error {
|
|
|
7043
7081
|
super(t), this.name = "DependsError", this.code = e, this.cause = s, this.timestamp = Date.now();
|
|
7044
7082
|
}
|
|
7045
7083
|
}
|
|
7046
|
-
let
|
|
7047
|
-
function
|
|
7084
|
+
let et = typeof globalThis < "u" && globalThis.fetch ? globalThis.fetch.bind(globalThis) : typeof window < "u" && window.fetch ? window.fetch.bind(window) : null;
|
|
7085
|
+
function Uo(i) {
|
|
7048
7086
|
if (!i || typeof i.fetch != "function")
|
|
7049
7087
|
throw new TypeError("[Kupola] configureHttpClient: client must provide a fetch function");
|
|
7050
|
-
|
|
7088
|
+
et = i.fetch.bind(i);
|
|
7051
7089
|
}
|
|
7052
|
-
function
|
|
7053
|
-
return
|
|
7090
|
+
function Yo() {
|
|
7091
|
+
return et;
|
|
7054
7092
|
}
|
|
7055
|
-
function
|
|
7056
|
-
|
|
7093
|
+
function Xo() {
|
|
7094
|
+
et = typeof globalThis < "u" && globalThis.fetch ? globalThis.fetch.bind(globalThis) : typeof window < "u" && window.fetch ? window.fetch.bind(window) : null;
|
|
7057
7095
|
}
|
|
7058
7096
|
class W {
|
|
7059
7097
|
constructor(t, e) {
|
|
@@ -7120,7 +7158,7 @@ class pa extends W {
|
|
|
7120
7158
|
}
|
|
7121
7159
|
async fetch(t) {
|
|
7122
7160
|
let e = this.config.source;
|
|
7123
|
-
const s =
|
|
7161
|
+
const s = ct("http");
|
|
7124
7162
|
s?.baseURL && !e.startsWith("http://") && !e.startsWith("https://") && (e = s.baseURL + e.replace(/^\//, ""));
|
|
7125
7163
|
for (const u in t)
|
|
7126
7164
|
e = e.replace(`:${u}`, encodeURIComponent(t[u]));
|
|
@@ -7135,7 +7173,7 @@ class pa extends W {
|
|
|
7135
7173
|
headers: { "Content-Type": "application/json", ...r, ...this.headers }
|
|
7136
7174
|
};
|
|
7137
7175
|
s?.withCredentials && (a.credentials = "include"), ["POST", "PUT", "PATCH"].includes(a.method) && (a.body = JSON.stringify(t));
|
|
7138
|
-
const o =
|
|
7176
|
+
const o = et;
|
|
7139
7177
|
if (!o)
|
|
7140
7178
|
throw new N("No HTTP client available. Use configureHttpClient() to set one.", "NO_HTTP_CLIENT");
|
|
7141
7179
|
const l = await o(e, a), c = typeof l.ok == "boolean" ? l.ok : l.status >= 200 && l.status < 300, h = typeof l.status == "number" ? l.status : 0;
|
|
@@ -7235,16 +7273,16 @@ function be(i, t) {
|
|
|
7235
7273
|
const e = i.source;
|
|
7236
7274
|
return typeof e == "function" ? new ma(i, t) : typeof e == "string" && (e.startsWith("ws://") || e.startsWith("wss://")) ? new ve(i, t) : typeof e == "string" && (e.startsWith("/") || e.startsWith("http")) ? new pa(i, t) : typeof e == "string" && e.startsWith("localStorage:") ? new ye(i, t) : typeof e == "string" && e.startsWith("route:") ? new fa(i, t) : new ga(i, t);
|
|
7237
7275
|
}
|
|
7238
|
-
function
|
|
7276
|
+
function jo(i, t) {
|
|
7239
7277
|
const e = {}, s = new _e(), n = [];
|
|
7240
7278
|
for (const r in t) {
|
|
7241
7279
|
let p = function() {
|
|
7242
|
-
return
|
|
7280
|
+
return xt(i);
|
|
7243
7281
|
}, a = t[r];
|
|
7244
7282
|
typeof a == "string" && (a = { source: a });
|
|
7245
7283
|
const o = {
|
|
7246
7284
|
...a,
|
|
7247
|
-
cacheKey: a.cacheKey || `${r}-${JSON.stringify(
|
|
7285
|
+
cacheKey: a.cacheKey || `${r}-${JSON.stringify(xt(i))}`
|
|
7248
7286
|
}, l = be(o, s), c = I(null), h = I(!0), d = I(null), u = I(null);
|
|
7249
7287
|
let f = 0;
|
|
7250
7288
|
async function m() {
|
|
@@ -7302,7 +7340,7 @@ function Yo(i, t) {
|
|
|
7302
7340
|
}
|
|
7303
7341
|
}, window.__kupolaDepInstances || (window.__kupolaDepInstances = []), window.__kupolaDepInstances.push(e), e;
|
|
7304
7342
|
}
|
|
7305
|
-
function
|
|
7343
|
+
function Jo(i) {
|
|
7306
7344
|
const t = new _e(), e = be(i, t), s = I(null), n = I(!0), r = I(null);
|
|
7307
7345
|
let a = 0;
|
|
7308
7346
|
async function o() {
|
|
@@ -7331,7 +7369,7 @@ function Xo(i) {
|
|
|
7331
7369
|
}
|
|
7332
7370
|
};
|
|
7333
7371
|
}
|
|
7334
|
-
function
|
|
7372
|
+
function xt(i) {
|
|
7335
7373
|
const t = {};
|
|
7336
7374
|
for (const e in i) {
|
|
7337
7375
|
const s = i[e];
|
|
@@ -7339,7 +7377,7 @@ function bt(i) {
|
|
|
7339
7377
|
}
|
|
7340
7378
|
return t;
|
|
7341
7379
|
}
|
|
7342
|
-
function
|
|
7380
|
+
function Go() {
|
|
7343
7381
|
}
|
|
7344
7382
|
class _a {
|
|
7345
7383
|
constructor(t, e = {}) {
|
|
@@ -7884,7 +7922,7 @@ class _a {
|
|
|
7884
7922
|
function xe(i, t) {
|
|
7885
7923
|
return new _a(i, t);
|
|
7886
7924
|
}
|
|
7887
|
-
function
|
|
7925
|
+
function Zo() {
|
|
7888
7926
|
document.querySelectorAll("[data-kupola-table]").forEach((i) => {
|
|
7889
7927
|
const t = i.getAttribute("data-kupola-table");
|
|
7890
7928
|
let e = {};
|
|
@@ -7997,9 +8035,9 @@ class ya {
|
|
|
7997
8035
|
this.element.innerHTML = "", this.element.classList.remove("kupola-pagination");
|
|
7998
8036
|
}
|
|
7999
8037
|
}
|
|
8000
|
-
let
|
|
8038
|
+
let Et = !1;
|
|
8001
8039
|
function va() {
|
|
8002
|
-
if (
|
|
8040
|
+
if (Et || typeof document > "u") return;
|
|
8003
8041
|
const i = document.createElement("style");
|
|
8004
8042
|
i.textContent = `
|
|
8005
8043
|
.kupola-pagination { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
|
|
@@ -8015,12 +8053,12 @@ function va() {
|
|
|
8015
8053
|
.kupola-pagination-jumper { font-size: 14px; color: #666; }
|
|
8016
8054
|
.kupola-pagination-jumper input { width: 50px; height: 28px; margin: 0 4px; padding: 0 8px; border: 1px solid #d9d9d9; border-radius: 4px; text-align: center; font-size: 13px; }
|
|
8017
8055
|
.kupola-pagination-jumper input:focus { outline: none; border-color: #1890ff; }
|
|
8018
|
-
`, document.head.appendChild(i),
|
|
8056
|
+
`, document.head.appendChild(i), Et = !0;
|
|
8019
8057
|
}
|
|
8020
|
-
function
|
|
8058
|
+
function Qo(i, t) {
|
|
8021
8059
|
return va(), new ya(i, t);
|
|
8022
8060
|
}
|
|
8023
|
-
let
|
|
8061
|
+
let kt = !1;
|
|
8024
8062
|
class ba extends HTMLElement {
|
|
8025
8063
|
static get observedAttributes() {
|
|
8026
8064
|
return ["open"];
|
|
@@ -8143,9 +8181,9 @@ class Ca extends HTMLElement {
|
|
|
8143
8181
|
this.removeAttribute("open");
|
|
8144
8182
|
}
|
|
8145
8183
|
}
|
|
8146
|
-
function
|
|
8147
|
-
if (
|
|
8148
|
-
|
|
8184
|
+
function tl() {
|
|
8185
|
+
if (kt || typeof customElements > "u") return;
|
|
8186
|
+
kt = !0;
|
|
8149
8187
|
const i = [
|
|
8150
8188
|
["k-dropdown", ba],
|
|
8151
8189
|
["k-tooltip", xa],
|
|
@@ -8170,7 +8208,7 @@ export {
|
|
|
8170
8208
|
br as Datepicker,
|
|
8171
8209
|
N as DependsError,
|
|
8172
8210
|
W as DependsSource,
|
|
8173
|
-
|
|
8211
|
+
Co as Dialog,
|
|
8174
8212
|
Dr as Drawer,
|
|
8175
8213
|
_r as Dropdown,
|
|
8176
8214
|
Fr as DynamicTags,
|
|
@@ -8179,7 +8217,7 @@ export {
|
|
|
8179
8217
|
ma as FunctionSource,
|
|
8180
8218
|
gr as GlobalEvents,
|
|
8181
8219
|
Wr as Heatmap,
|
|
8182
|
-
|
|
8220
|
+
Oo as Icons,
|
|
8183
8221
|
le as ImagePreview,
|
|
8184
8222
|
J as KupolaComponent,
|
|
8185
8223
|
fr as KupolaComponentRegistry,
|
|
@@ -8187,16 +8225,16 @@ export {
|
|
|
8187
8225
|
ar as KupolaEventBus,
|
|
8188
8226
|
la as KupolaForm,
|
|
8189
8227
|
Yt as KupolaI18n,
|
|
8190
|
-
|
|
8228
|
+
lt as KupolaLifecycle,
|
|
8191
8229
|
ya as KupolaPagination,
|
|
8192
|
-
|
|
8230
|
+
ft as KupolaStore,
|
|
8193
8231
|
rr as KupolaStoreManager,
|
|
8194
8232
|
_a as KupolaTable,
|
|
8195
8233
|
Da as KupolaUtils,
|
|
8196
8234
|
jr as KupolaValidator,
|
|
8197
|
-
|
|
8235
|
+
Do as Message,
|
|
8198
8236
|
$ as Modal,
|
|
8199
|
-
|
|
8237
|
+
So as Notification,
|
|
8200
8238
|
sa as NumberInput,
|
|
8201
8239
|
pe as PATHS,
|
|
8202
8240
|
fa as RouteSource,
|
|
@@ -8212,11 +8250,11 @@ export {
|
|
|
8212
8250
|
Yr as Tooltip,
|
|
8213
8251
|
Jr as VirtualList,
|
|
8214
8252
|
ve as WebSocketSource,
|
|
8215
|
-
|
|
8216
|
-
|
|
8253
|
+
ko as alertModal,
|
|
8254
|
+
gt as applyMixin,
|
|
8217
8255
|
Bs as arrayUtils,
|
|
8218
|
-
|
|
8219
|
-
|
|
8256
|
+
Ya as bootstrapComponents,
|
|
8257
|
+
mo as cleanupAllDropdowns,
|
|
8220
8258
|
oa as cleanupAllSlideCaptchas,
|
|
8221
8259
|
Br as cleanupCalendar,
|
|
8222
8260
|
Lr as cleanupCarousel,
|
|
@@ -8239,11 +8277,11 @@ export {
|
|
|
8239
8277
|
kr as cleanupTimepicker,
|
|
8240
8278
|
Xr as cleanupTooltip,
|
|
8241
8279
|
Zr as cleanupVirtualList,
|
|
8242
|
-
|
|
8243
|
-
|
|
8244
|
-
|
|
8280
|
+
Go as clearCache,
|
|
8281
|
+
Uo as configureHttpClient,
|
|
8282
|
+
Eo as confirmModal,
|
|
8245
8283
|
Fa as createBrandPicker,
|
|
8246
|
-
|
|
8284
|
+
Ga as createI18n,
|
|
8247
8285
|
La as createLifecycle,
|
|
8248
8286
|
ee as createModal,
|
|
8249
8287
|
be as createSource,
|
|
@@ -8252,120 +8290,122 @@ export {
|
|
|
8252
8290
|
jn as cryptoUtils,
|
|
8253
8291
|
ln as dateUtils,
|
|
8254
8292
|
cn as debounce,
|
|
8255
|
-
|
|
8256
|
-
|
|
8257
|
-
|
|
8258
|
-
|
|
8293
|
+
Ja as defineComponent,
|
|
8294
|
+
Xa as defineMixin,
|
|
8295
|
+
lo as emit,
|
|
8296
|
+
co as emitGlobal,
|
|
8259
8297
|
Oa as escapeHtml,
|
|
8260
|
-
|
|
8261
|
-
|
|
8262
|
-
|
|
8298
|
+
no as formatCurrency,
|
|
8299
|
+
so as formatDate,
|
|
8300
|
+
io as formatNumber,
|
|
8301
|
+
Ka as generateSecureId,
|
|
8263
8302
|
Aa as getBasePath,
|
|
8264
8303
|
X as getBrand,
|
|
8265
|
-
|
|
8304
|
+
ct as getConfig,
|
|
8266
8305
|
lr as getDefaultBrand,
|
|
8267
8306
|
or as getDefaultTheme,
|
|
8268
8307
|
Pa as getDevConfig,
|
|
8269
8308
|
qa as getExtendConfig,
|
|
8270
|
-
|
|
8271
|
-
|
|
8309
|
+
Ko as getFormInstance,
|
|
8310
|
+
Yo as getHttpClient,
|
|
8272
8311
|
za as getHttpConfig,
|
|
8273
|
-
|
|
8274
|
-
|
|
8275
|
-
|
|
8312
|
+
Vt as getIconsPath,
|
|
8313
|
+
po as getListenerCount,
|
|
8314
|
+
eo as getLocale,
|
|
8276
8315
|
$a as getPerformanceConfig,
|
|
8277
|
-
|
|
8316
|
+
tt as getSecurityConfig,
|
|
8278
8317
|
Ia as getStore,
|
|
8279
8318
|
R as getTheme,
|
|
8280
8319
|
cr as getUiConfig,
|
|
8281
8320
|
H as globalEvents,
|
|
8282
|
-
|
|
8321
|
+
Zo as initAllTables,
|
|
8283
8322
|
ae as initCalendar,
|
|
8284
|
-
|
|
8323
|
+
Ao as initCalendars,
|
|
8285
8324
|
te as initCarousel,
|
|
8286
|
-
|
|
8325
|
+
bo as initCarousels,
|
|
8287
8326
|
ne as initCollapse,
|
|
8288
|
-
|
|
8327
|
+
Io as initCollapses,
|
|
8289
8328
|
re as initColorPicker,
|
|
8290
|
-
|
|
8329
|
+
To as initColorPickers,
|
|
8291
8330
|
me as initCountdown,
|
|
8292
|
-
|
|
8331
|
+
Ro as initCountdowns,
|
|
8293
8332
|
Gt as initDatepicker,
|
|
8294
|
-
|
|
8295
|
-
|
|
8296
|
-
|
|
8333
|
+
_o as initDatepickers,
|
|
8334
|
+
at as initDrawer,
|
|
8335
|
+
xo as initDrawers,
|
|
8297
8336
|
Xt as initDropdown,
|
|
8298
|
-
|
|
8337
|
+
fo as initDropdowns,
|
|
8299
8338
|
oe as initDynamicTags,
|
|
8300
|
-
|
|
8339
|
+
zo as initDynamicTagsAll,
|
|
8301
8340
|
ie as initFileUpload,
|
|
8302
|
-
|
|
8341
|
+
Mo as initFileUploads,
|
|
8303
8342
|
ca as initFormValidation,
|
|
8304
8343
|
de as initHeatmap,
|
|
8305
|
-
|
|
8306
|
-
|
|
8307
|
-
|
|
8344
|
+
Fo as initHeatmaps,
|
|
8345
|
+
Po as initImagePreview,
|
|
8346
|
+
Ho as initMessages,
|
|
8308
8347
|
se as initModal,
|
|
8309
|
-
|
|
8310
|
-
|
|
8348
|
+
wo as initModals,
|
|
8349
|
+
Lo as initNotifications,
|
|
8311
8350
|
ge as initNumberInput,
|
|
8312
|
-
|
|
8313
|
-
|
|
8351
|
+
Vo as initNumberInputs,
|
|
8352
|
+
Qo as initPagination,
|
|
8314
8353
|
Jt as initSelect,
|
|
8315
|
-
|
|
8354
|
+
go as initSelects,
|
|
8316
8355
|
ra as initSlideCaptchas,
|
|
8317
8356
|
Qt as initSlider,
|
|
8318
|
-
|
|
8357
|
+
vo as initSliders,
|
|
8319
8358
|
he as initStatCard,
|
|
8320
|
-
|
|
8359
|
+
Bo as initStatCards,
|
|
8321
8360
|
xe as initTable,
|
|
8322
8361
|
ce as initTag,
|
|
8323
|
-
|
|
8362
|
+
qo as initTags,
|
|
8324
8363
|
dr as initTheme,
|
|
8325
8364
|
Zt as initTimepicker,
|
|
8326
|
-
|
|
8365
|
+
yo as initTimepickers,
|
|
8327
8366
|
ue as initTooltip,
|
|
8328
|
-
|
|
8367
|
+
No as initTooltips,
|
|
8329
8368
|
Gr as initVirtualList,
|
|
8330
|
-
|
|
8369
|
+
_t as kupolaBootstrap,
|
|
8331
8370
|
F as kupolaData,
|
|
8332
8371
|
Ha as kupolaEvents,
|
|
8333
8372
|
O as kupolaI18n,
|
|
8334
8373
|
E as kupolaInitializer,
|
|
8335
8374
|
Sa as kupolaLifecycle,
|
|
8336
8375
|
M as kupolaRegistry,
|
|
8337
|
-
|
|
8338
|
-
|
|
8376
|
+
Rt as kupolaStoreManager,
|
|
8377
|
+
Va as maskData,
|
|
8378
|
+
Qa as n,
|
|
8339
8379
|
Ii as numberUtils,
|
|
8340
8380
|
ni as objectUtils,
|
|
8341
|
-
|
|
8342
|
-
|
|
8343
|
-
|
|
8344
|
-
|
|
8345
|
-
|
|
8381
|
+
oo as off,
|
|
8382
|
+
uo as offAll,
|
|
8383
|
+
ho as offByScope,
|
|
8384
|
+
ro as on,
|
|
8385
|
+
ao as once,
|
|
8346
8386
|
sr as preloadUtils,
|
|
8347
8387
|
I as ref,
|
|
8348
|
-
|
|
8349
|
-
|
|
8350
|
-
|
|
8351
|
-
|
|
8352
|
-
|
|
8388
|
+
Wa as registerComponent,
|
|
8389
|
+
Ua as registerLazyComponent,
|
|
8390
|
+
tl as registerWebComponents,
|
|
8391
|
+
ot as renderIcon,
|
|
8392
|
+
Xo as resetHttpClient,
|
|
8353
8393
|
Na as sanitizeHtml,
|
|
8354
|
-
|
|
8394
|
+
rt as setBrand,
|
|
8355
8395
|
Ta as setConfig,
|
|
8356
|
-
|
|
8357
|
-
|
|
8358
|
-
|
|
8396
|
+
to as setLocale,
|
|
8397
|
+
nt as setTheme,
|
|
8398
|
+
$o as showImagePreview,
|
|
8359
8399
|
je as stringUtils,
|
|
8360
8400
|
Ra as stripHtml,
|
|
8361
8401
|
fe as svg,
|
|
8362
|
-
|
|
8402
|
+
Za as t,
|
|
8363
8403
|
hn as throttle,
|
|
8364
|
-
|
|
8365
|
-
|
|
8366
|
-
|
|
8367
|
-
|
|
8404
|
+
jo as useDeps,
|
|
8405
|
+
ja as useMixin,
|
|
8406
|
+
Jo as useQuery,
|
|
8407
|
+
Wo as validateForm,
|
|
8368
8408
|
P as validator,
|
|
8369
|
-
|
|
8409
|
+
Ft as validatorUtils
|
|
8370
8410
|
};
|
|
8371
8411
|
//# sourceMappingURL=kupola.esm.js.map
|