@dxtmisha/functional-basic 1.0.0 → 1.1.0
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/ai-types.txt +1656 -0
- package/dist/library.d.ts +81 -0
- package/dist/library.js +165 -127
- package/package.json +2 -1
package/dist/library.js
CHANGED
|
@@ -3382,6 +3382,44 @@ var K = class {
|
|
|
3382
3382
|
return this.getItem().html();
|
|
3383
3383
|
}
|
|
3384
3384
|
}, Tt = class {
|
|
3385
|
+
constructor(e, t = 320, n = !1) {
|
|
3386
|
+
S(this, "timerId", void 0), S(this, "startTime", void 0), S(this, "remaining", void 0), S(this, "completed", !1), this.callback = e, this.delay = t, n || this.resume();
|
|
3387
|
+
}
|
|
3388
|
+
resume() {
|
|
3389
|
+
if (this.timerId || this.completed) return this;
|
|
3390
|
+
let e = this.getRemaining();
|
|
3391
|
+
return e <= 0 ? this.go() : (this.updateStartTime(), this.timerId = setTimeout(() => this.go(), e)), this;
|
|
3392
|
+
}
|
|
3393
|
+
pause() {
|
|
3394
|
+
return this.timerId && !this.completed && this.stop().updateRemaining(), this;
|
|
3395
|
+
}
|
|
3396
|
+
reset() {
|
|
3397
|
+
return this.clear().resume(), this;
|
|
3398
|
+
}
|
|
3399
|
+
clear() {
|
|
3400
|
+
return this.stop(), this.startTime = void 0, this.remaining = void 0, this.completed = !1, this;
|
|
3401
|
+
}
|
|
3402
|
+
getRemaining() {
|
|
3403
|
+
var e;
|
|
3404
|
+
return (e = this.remaining) == null ? this.delay : e;
|
|
3405
|
+
}
|
|
3406
|
+
getStartTime() {
|
|
3407
|
+
var e;
|
|
3408
|
+
return (e = this.startTime) == null ? Date.now() : e;
|
|
3409
|
+
}
|
|
3410
|
+
go() {
|
|
3411
|
+
return this.callback(), this.timerId = void 0, this.completed = !0, this;
|
|
3412
|
+
}
|
|
3413
|
+
updateRemaining() {
|
|
3414
|
+
return this.completed ? this : (this.remaining === void 0 && (this.remaining = this.delay), this.remaining -= Date.now() - this.getStartTime(), this.remaining < 0 && (this.remaining = 0), this);
|
|
3415
|
+
}
|
|
3416
|
+
updateStartTime() {
|
|
3417
|
+
return this.startTime = Date.now(), this;
|
|
3418
|
+
}
|
|
3419
|
+
stop() {
|
|
3420
|
+
return this.timerId && (clearTimeout(this.timerId), this.timerId = void 0), this;
|
|
3421
|
+
}
|
|
3422
|
+
}, Et = class {
|
|
3385
3423
|
static async is() {
|
|
3386
3424
|
let e = await this.get();
|
|
3387
3425
|
return e !== -1 && e <= 8;
|
|
@@ -3419,7 +3457,7 @@ var K = class {
|
|
|
3419
3457
|
});
|
|
3420
3458
|
}
|
|
3421
3459
|
};
|
|
3422
|
-
S(
|
|
3460
|
+
S(Et, "calculate", !1);
|
|
3423
3461
|
//#endregion
|
|
3424
3462
|
//#region src/functions/escapeExp.ts
|
|
3425
3463
|
function X(e) {
|
|
@@ -3427,7 +3465,7 @@ function X(e) {
|
|
|
3427
3465
|
}
|
|
3428
3466
|
//#endregion
|
|
3429
3467
|
//#region src/functions/getSeparatingSearchExp.ts
|
|
3430
|
-
function
|
|
3468
|
+
function Dt(e, t = 128) {
|
|
3431
3469
|
if (e instanceof RegExp) return e;
|
|
3432
3470
|
if (!e || e.trim().length === 0 || e.length > t) return /^/;
|
|
3433
3471
|
let n = String(e).replace(/\s+/g, " ").trim().split(" ").map(X).join("|");
|
|
@@ -3435,18 +3473,18 @@ function Et(e, t = 128) {
|
|
|
3435
3473
|
}
|
|
3436
3474
|
//#endregion
|
|
3437
3475
|
//#region src/functions/addTagHighlightMatch.ts
|
|
3438
|
-
var
|
|
3439
|
-
function
|
|
3476
|
+
var Ot = `___HIGHLIGHT_START_${f(1e5, 999999)}___`, kt = `___HIGHLIGHT_END_${f(1e5, 999999)}___`, At = RegExp(`${Ot}|${kt}`, "g");
|
|
3477
|
+
function jt(e, t, n = "sys-highlight-match", r = !1) {
|
|
3440
3478
|
let i = a(e);
|
|
3441
3479
|
if (l(i) && l(t)) {
|
|
3442
|
-
let e = i.replace(
|
|
3443
|
-
return r && (e = G(e)), e.replace(
|
|
3480
|
+
let e = i.replace(Dt(t), `${Ot}$1${kt}`);
|
|
3481
|
+
return r && (e = G(e)), e.replace(At, (e) => e === Ot ? `<span class="${n}">` : "</span>");
|
|
3444
3482
|
}
|
|
3445
3483
|
return r ? G(i) : i;
|
|
3446
3484
|
}
|
|
3447
3485
|
//#endregion
|
|
3448
3486
|
//#region src/classes/SearchListData.ts
|
|
3449
|
-
var
|
|
3487
|
+
var Mt = class {
|
|
3450
3488
|
constructor(e, t, n, r) {
|
|
3451
3489
|
S(this, "listCache", void 0), this.list = e, this.columns = t, this.item = n, this.options = r;
|
|
3452
3490
|
}
|
|
@@ -3497,7 +3535,7 @@ var jt = class {
|
|
|
3497
3535
|
return e.replace(/\.([a-z0-9])/gi, (e, t) => t.toUpperCase()) + "Search";
|
|
3498
3536
|
}
|
|
3499
3537
|
addTag(e) {
|
|
3500
|
-
return
|
|
3538
|
+
return jt(P(e), this.item.get(), this.options.getClassName());
|
|
3501
3539
|
}
|
|
3502
3540
|
generateCache() {
|
|
3503
3541
|
if (!this.isList()) return [];
|
|
@@ -3521,7 +3559,7 @@ var jt = class {
|
|
|
3521
3559
|
resetCache() {
|
|
3522
3560
|
this.listCache = void 0;
|
|
3523
3561
|
}
|
|
3524
|
-
},
|
|
3562
|
+
}, Nt = class {
|
|
3525
3563
|
constructor(e, t) {
|
|
3526
3564
|
this.value = e, this.options = t;
|
|
3527
3565
|
}
|
|
@@ -3541,18 +3579,18 @@ var jt = class {
|
|
|
3541
3579
|
};
|
|
3542
3580
|
//#endregion
|
|
3543
3581
|
//#region src/functions/getExp.ts
|
|
3544
|
-
function
|
|
3582
|
+
function Pt(e, t = "ig", n = ":value") {
|
|
3545
3583
|
let r = X(e);
|
|
3546
3584
|
return new RegExp(n.replace(/:value/g, r), t);
|
|
3547
3585
|
}
|
|
3548
3586
|
//#endregion
|
|
3549
3587
|
//#region src/functions/getExactSearchExp.ts
|
|
3550
|
-
function
|
|
3551
|
-
return
|
|
3588
|
+
function Ft(e) {
|
|
3589
|
+
return Pt(e, "i", "(:value)");
|
|
3552
3590
|
}
|
|
3553
3591
|
//#endregion
|
|
3554
3592
|
//#region src/functions/getSearchExp.ts
|
|
3555
|
-
function
|
|
3593
|
+
function It(e, t = 128) {
|
|
3556
3594
|
if (!d(e) || e.trim().length === 0 || e.length > t) return /^/;
|
|
3557
3595
|
let n = [];
|
|
3558
3596
|
return a(e).split(" ").forEach((e) => {
|
|
@@ -3562,7 +3600,7 @@ function Ft(e, t = 128) {
|
|
|
3562
3600
|
}
|
|
3563
3601
|
//#endregion
|
|
3564
3602
|
//#region src/classes/SearchListMatcher.ts
|
|
3565
|
-
var
|
|
3603
|
+
var Lt = class {
|
|
3566
3604
|
constructor(e, t) {
|
|
3567
3605
|
S(this, "matcher", void 0), this.item = e, this.options = t, this.initMatcher();
|
|
3568
3606
|
}
|
|
@@ -3579,9 +3617,9 @@ var It = class {
|
|
|
3579
3617
|
this.initMatcher();
|
|
3580
3618
|
}
|
|
3581
3619
|
initMatcher() {
|
|
3582
|
-
this.item.is() ? this.matcher = this.options.getFindExactMatch() ?
|
|
3620
|
+
this.item.is() ? this.matcher = this.options.getFindExactMatch() ? Ft(this.item.get()) : It(this.item.get()) : this.matcher = void 0;
|
|
3583
3621
|
}
|
|
3584
|
-
},
|
|
3622
|
+
}, Rt = class {
|
|
3585
3623
|
constructor(e) {
|
|
3586
3624
|
this.options = e;
|
|
3587
3625
|
}
|
|
@@ -3611,12 +3649,12 @@ var It = class {
|
|
|
3611
3649
|
setOptions(e) {
|
|
3612
3650
|
return this.options = e, this;
|
|
3613
3651
|
}
|
|
3614
|
-
},
|
|
3652
|
+
}, zt = class {
|
|
3615
3653
|
constructor(e, t, n, r) {
|
|
3616
3654
|
S(this, "options", void 0), S(this, "item", void 0), S(this, "matcher", void 0), S(this, "data", void 0), S(this, "callbackToSelection", (e, t) => {
|
|
3617
3655
|
if (this.matcher.isSelection(t)) return this.data.toFormatItem(e, !0);
|
|
3618
3656
|
if (this.options.getReturnEverything()) return this.data.toFormatItem(e, !1);
|
|
3619
|
-
}), S(this, "callbackToNone", (e) => this.data.toFormatItem(e, !1)), this.options = new
|
|
3657
|
+
}), S(this, "callbackToNone", (e) => this.data.toFormatItem(e, !1)), this.options = new Rt(r), this.item = new Nt(n, this.options), this.matcher = new Lt(this.item, this.options), this.data = new Mt(e, t, this.item, this.options);
|
|
3620
3658
|
}
|
|
3621
3659
|
getData() {
|
|
3622
3660
|
return this.data;
|
|
@@ -3653,13 +3691,13 @@ var It = class {
|
|
|
3653
3691
|
let e = this.data.getList();
|
|
3654
3692
|
return e ? r(e, this.callbackToNone) : [];
|
|
3655
3693
|
}
|
|
3656
|
-
},
|
|
3694
|
+
}, Bt = () => T.get("__ui:storage-callback__", () => ({})), Vt = class e {
|
|
3657
3695
|
static getInstance(t, n = "main") {
|
|
3658
3696
|
return new e(t, n);
|
|
3659
3697
|
}
|
|
3660
3698
|
constructor(e, t = "main") {
|
|
3661
3699
|
S(this, "callbacks", []), S(this, "loading", !1), this.name = e, this.group = t;
|
|
3662
|
-
let n = `${t}:${e}`, r =
|
|
3700
|
+
let n = `${t}:${e}`, r = Bt();
|
|
3663
3701
|
if (n in r) return r[n];
|
|
3664
3702
|
r[n] = this;
|
|
3665
3703
|
}
|
|
@@ -3689,7 +3727,7 @@ var It = class {
|
|
|
3689
3727
|
for (let { callback: t, isOnce: n } of this.callbacks) await Le(t, e), n && this.removeCallback(t);
|
|
3690
3728
|
return this;
|
|
3691
3729
|
}
|
|
3692
|
-
},
|
|
3730
|
+
}, Ht = [
|
|
3693
3731
|
"d",
|
|
3694
3732
|
"e",
|
|
3695
3733
|
"f",
|
|
@@ -3709,10 +3747,10 @@ var It = class {
|
|
|
3709
3747
|
"t",
|
|
3710
3748
|
"u",
|
|
3711
3749
|
"v"
|
|
3712
|
-
],
|
|
3750
|
+
], Ut = RegExp(`%(${Ht.join("|")})`, "g"), Wt = (e, t = {}) => {
|
|
3713
3751
|
let r = String(e);
|
|
3714
|
-
return Array.isArray(t) && e.match(/%[a-z]/) && (r = r.replace(
|
|
3715
|
-
let r =
|
|
3752
|
+
return Array.isArray(t) && e.match(/%[a-z]/) && (r = r.replace(Ut, (e, n) => {
|
|
3753
|
+
let r = Ht.indexOf(n);
|
|
3716
3754
|
if (r !== -1) {
|
|
3717
3755
|
var i;
|
|
3718
3756
|
return String((i = t == null ? void 0 : t[r]) == null ? "" : i);
|
|
@@ -3731,10 +3769,10 @@ var It = class {
|
|
|
3731
3769
|
}
|
|
3732
3770
|
return e;
|
|
3733
3771
|
})), r;
|
|
3734
|
-
},
|
|
3772
|
+
}, Gt = (e) => {
|
|
3735
3773
|
var t;
|
|
3736
3774
|
return i(e) ? !0 : !!(e && n(e) && ((e == null ? void 0 : e.status) === "success" || e != null && e.success || !(e == null || (t = e.statusObject) == null) && t.status && /^2/.test(String(e.statusObject.status)) || !("status" in e) && !("success" in e) && !("statusObject" in e) && /^2/.test(String(N.getStatus().getStatus()))));
|
|
3737
|
-
},
|
|
3775
|
+
}, Kt = "global", qt = 160, Jt = class {
|
|
3738
3776
|
constructor(e, t = () => D.getLanguage(), n = () => D.getLocation()) {
|
|
3739
3777
|
S(this, "files", {}), S(this, "data", {}), this.language = t, this.location = n, e && this.add(e);
|
|
3740
3778
|
}
|
|
@@ -3764,7 +3802,7 @@ var It = class {
|
|
|
3764
3802
|
if (e in this.files) return e;
|
|
3765
3803
|
let t = this.getLanguage();
|
|
3766
3804
|
if (t in this.files) return t;
|
|
3767
|
-
if ("global" in this.files) return
|
|
3805
|
+
if ("global" in this.files) return Kt;
|
|
3768
3806
|
}
|
|
3769
3807
|
getByData(e) {
|
|
3770
3808
|
if (e in this.data) return this.data[e];
|
|
@@ -3775,8 +3813,8 @@ var It = class {
|
|
|
3775
3813
|
return t && (this.data[e] = t), t;
|
|
3776
3814
|
}
|
|
3777
3815
|
}
|
|
3778
|
-
},
|
|
3779
|
-
constructor(e = "/api/translate", t = "list", n = new
|
|
3816
|
+
}, Yt = class {
|
|
3817
|
+
constructor(e = "/api/translate", t = "list", n = new Jt()) {
|
|
3780
3818
|
S(this, "data", {}), S(this, "cache", []), S(this, "resolveList", []), S(this, "timeout", void 0), S(this, "isReadApi", !0), this.url = e, this.propsName = t, this.files = n;
|
|
3781
3819
|
}
|
|
3782
3820
|
async get(e, t) {
|
|
@@ -3865,7 +3903,7 @@ var It = class {
|
|
|
3865
3903
|
return `${this.files.getLanguage()}-${e}`;
|
|
3866
3904
|
}
|
|
3867
3905
|
getNameByGlobal(e) {
|
|
3868
|
-
return `${
|
|
3906
|
+
return `${Kt}-${e}`;
|
|
3869
3907
|
}
|
|
3870
3908
|
getNamesNone(e) {
|
|
3871
3909
|
let t = [];
|
|
@@ -3882,14 +3920,14 @@ var It = class {
|
|
|
3882
3920
|
timeout: 12e3,
|
|
3883
3921
|
global: !0
|
|
3884
3922
|
});
|
|
3885
|
-
return
|
|
3923
|
+
return Gt(e) || C.on({
|
|
3886
3924
|
group: "translate",
|
|
3887
3925
|
code: "error",
|
|
3888
3926
|
details: e
|
|
3889
3927
|
}), e == null ? {} : e;
|
|
3890
3928
|
}
|
|
3891
3929
|
replacement(e, t) {
|
|
3892
|
-
return t ?
|
|
3930
|
+
return t ? Wt(e, t) : e;
|
|
3893
3931
|
}
|
|
3894
3932
|
async make() {
|
|
3895
3933
|
let e;
|
|
@@ -3901,12 +3939,12 @@ var It = class {
|
|
|
3901
3939
|
this.data[this.getName(t)] = (n = e == null ? void 0 : e[t]) == null ? "" : n;
|
|
3902
3940
|
}), this.cache = [];
|
|
3903
3941
|
}
|
|
3904
|
-
},
|
|
3942
|
+
}, Xt = class {
|
|
3905
3943
|
static async get(e, t) {
|
|
3906
3944
|
return this.getItem().get(e, t);
|
|
3907
3945
|
}
|
|
3908
3946
|
static getItem() {
|
|
3909
|
-
return this.item || (this.item = new
|
|
3947
|
+
return this.item || (this.item = new Yt()), this.item;
|
|
3910
3948
|
}
|
|
3911
3949
|
static getSync(e, t = !1, n) {
|
|
3912
3950
|
return this.getItem().getSync(e, t, n);
|
|
@@ -3945,18 +3983,18 @@ var It = class {
|
|
|
3945
3983
|
e.url && this.getItem().setUrl(e.url), e.propsName && this.getItem().setPropsName(e.propsName), typeof e.readApi == "boolean" && this.getItem().setReadApi(e.readApi);
|
|
3946
3984
|
}
|
|
3947
3985
|
};
|
|
3948
|
-
S(
|
|
3986
|
+
S(Xt, "item", void 0);
|
|
3949
3987
|
//#endregion
|
|
3950
3988
|
//#region src/functions/arrFill.ts
|
|
3951
|
-
function
|
|
3989
|
+
function Zt(e, t) {
|
|
3952
3990
|
return Array(t).fill(e);
|
|
3953
3991
|
}
|
|
3954
3992
|
//#endregion
|
|
3955
3993
|
//#region src/functions/blobToBase64.ts
|
|
3956
|
-
var
|
|
3994
|
+
var Qt = () => $t() !== void 0, $t = () => {
|
|
3957
3995
|
var e;
|
|
3958
3996
|
return (e = globalThis) == null ? void 0 : e.Buffer;
|
|
3959
|
-
},
|
|
3997
|
+
}, en = async (e) => new Promise((t, n) => {
|
|
3960
3998
|
if (typeof FileReader < "u") {
|
|
3961
3999
|
let r = new FileReader();
|
|
3962
4000
|
r.onloadend = () => {
|
|
@@ -3967,17 +4005,17 @@ var Zt = () => Qt() !== void 0, Qt = () => {
|
|
|
3967
4005
|
t(r.result.replace(/^data:.*?,/, ""));
|
|
3968
4006
|
}, r.onerror = n, r.readAsDataURL(e);
|
|
3969
4007
|
} else n();
|
|
3970
|
-
}),
|
|
4008
|
+
}), tn = (e) => {
|
|
3971
4009
|
var t;
|
|
3972
4010
|
return ((t = globalThis) == null ? void 0 : t.Buffer).from(e).toString("base64");
|
|
3973
4011
|
};
|
|
3974
|
-
async function
|
|
3975
|
-
let n = s() ? await
|
|
4012
|
+
async function nn(e, t = !1) {
|
|
4013
|
+
let n = s() ? await en(e) : Qt() ? tn(await e.arrayBuffer()) : void 0;
|
|
3976
4014
|
if (n) return t ? n : `data:${e.type};base64,${n}`;
|
|
3977
4015
|
}
|
|
3978
4016
|
//#endregion
|
|
3979
4017
|
//#region src/functions/capitalize.ts
|
|
3980
|
-
function
|
|
4018
|
+
function rn(e, t = !1) {
|
|
3981
4019
|
let n = String(e);
|
|
3982
4020
|
return n.length > 0 ? t ? n.charAt(0).toLocaleUpperCase(D.getLocation()) + n.slice(1) : n.charAt(0).toUpperCase() + n.slice(1) : n;
|
|
3983
4021
|
}
|
|
@@ -3988,12 +4026,12 @@ function Z(e) {
|
|
|
3988
4026
|
}
|
|
3989
4027
|
//#endregion
|
|
3990
4028
|
//#region src/functions/copyObjectLite.ts
|
|
3991
|
-
function
|
|
4029
|
+
function an(e, t) {
|
|
3992
4030
|
return Object.assign({}, e, t);
|
|
3993
4031
|
}
|
|
3994
4032
|
//#endregion
|
|
3995
4033
|
//#region src/functions/domQuerySelector.ts
|
|
3996
|
-
function
|
|
4034
|
+
function on(e) {
|
|
3997
4035
|
if (s()) {
|
|
3998
4036
|
var t;
|
|
3999
4037
|
return (t = document.querySelector(e)) == null ? void 0 : t;
|
|
@@ -4001,67 +4039,67 @@ function an(e) {
|
|
|
4001
4039
|
}
|
|
4002
4040
|
//#endregion
|
|
4003
4041
|
//#region src/functions/domQuerySelectorAll.ts
|
|
4004
|
-
function
|
|
4042
|
+
function sn(e) {
|
|
4005
4043
|
if (s()) return document.querySelectorAll(e);
|
|
4006
4044
|
}
|
|
4007
4045
|
//#endregion
|
|
4008
4046
|
//#region src/functions/getElementImage.ts
|
|
4009
|
-
function
|
|
4047
|
+
function cn(e) {
|
|
4010
4048
|
return d(e) ? W(void 0, "img", { src: e }) : e;
|
|
4011
4049
|
}
|
|
4012
4050
|
//#endregion
|
|
4013
4051
|
//#region src/functions/resizeImageByMax.ts
|
|
4014
|
-
function
|
|
4052
|
+
function ln(e, t = "auto") {
|
|
4015
4053
|
switch (t) {
|
|
4016
4054
|
case "auto": return e.naturalWidth >= e.naturalHeight;
|
|
4017
4055
|
case "width": return !0;
|
|
4018
4056
|
case "height": return !1;
|
|
4019
4057
|
}
|
|
4020
4058
|
}
|
|
4021
|
-
function
|
|
4022
|
-
let i =
|
|
4059
|
+
function un(e, t, n = "auto", r) {
|
|
4060
|
+
let i = cn(e);
|
|
4023
4061
|
if (s() && i && i.naturalWidth && i.naturalHeight && (i.naturalWidth > t && (n === "auto" || n === "width") || i.naturalHeight > t && (n === "auto" || n === "height"))) {
|
|
4024
4062
|
var a;
|
|
4025
|
-
let e =
|
|
4063
|
+
let e = ln(i, n), o = (a = document.createElement("canvas")) == null ? void 0 : a.getContext("2d");
|
|
4026
4064
|
if (o) return o.canvas.width = e ? t : i.naturalWidth / i.naturalHeight * t, o.canvas.height = e ? i.naturalHeight / i.naturalWidth * t : t, o.drawImage(i, 0, 0, o.canvas.width, o.canvas.height), o.canvas.toDataURL(r);
|
|
4027
4065
|
}
|
|
4028
4066
|
}
|
|
4029
4067
|
//#endregion
|
|
4030
4068
|
//#region src/functions/ensureMaxSize.ts
|
|
4031
|
-
async function
|
|
4069
|
+
async function dn(e, t = .56, n = "image/jpeg") {
|
|
4032
4070
|
return new Promise((r) => {
|
|
4033
4071
|
if (!s()) {
|
|
4034
4072
|
r("");
|
|
4035
4073
|
return;
|
|
4036
4074
|
}
|
|
4037
|
-
let i = new Blob([e], { type: n }), a = URL.createObjectURL(i), o =
|
|
4075
|
+
let i = new Blob([e], { type: n }), a = URL.createObjectURL(i), o = cn(a);
|
|
4038
4076
|
o ? (o.onload = () => {
|
|
4039
|
-
let e =
|
|
4077
|
+
let e = un(o, t * o.naturalWidth, "width", n);
|
|
4040
4078
|
r(e == null ? "" : e), URL.revokeObjectURL(a);
|
|
4041
4079
|
}, o.onerror = () => {
|
|
4042
4080
|
URL.revokeObjectURL(a), r("");
|
|
4043
|
-
}) :
|
|
4081
|
+
}) : nn(i).then((e) => r(String(e == null ? "" : e)));
|
|
4044
4082
|
});
|
|
4045
4083
|
}
|
|
4046
4084
|
//#endregion
|
|
4047
4085
|
//#region src/functions/eventStopPropagation.ts
|
|
4048
|
-
function
|
|
4086
|
+
function fn(e) {
|
|
4049
4087
|
e.preventDefault(), e.stopPropagation();
|
|
4050
4088
|
}
|
|
4051
4089
|
//#endregion
|
|
4052
4090
|
//#region src/functions/frame.ts
|
|
4053
|
-
function
|
|
4091
|
+
function pn(e, t, n) {
|
|
4054
4092
|
let r = () => {
|
|
4055
|
-
e(), s() && t != null && t() ?
|
|
4093
|
+
e(), s() && t != null && t() ? pn(e, t, n) : n == null || n();
|
|
4056
4094
|
};
|
|
4057
4095
|
s() ? requestAnimationFrame(r) : r();
|
|
4058
4096
|
}
|
|
4059
4097
|
//#endregion
|
|
4060
4098
|
//#region src/functions/getArrayHighlightMatch.ts
|
|
4061
|
-
function
|
|
4099
|
+
function mn(e, t) {
|
|
4062
4100
|
let n = a(e);
|
|
4063
4101
|
if (l(n) && l(t)) {
|
|
4064
|
-
let e = [], r =
|
|
4102
|
+
let e = [], r = Dt(t), i = 0, a;
|
|
4065
4103
|
for (; (a = r.exec(n)) !== null && a.index !== r.lastIndex;) a.index > i && e.push({
|
|
4066
4104
|
text: n.substring(i, a.index),
|
|
4067
4105
|
isMatch: !1
|
|
@@ -4081,7 +4119,7 @@ function pn(e, t) {
|
|
|
4081
4119
|
}
|
|
4082
4120
|
//#endregion
|
|
4083
4121
|
//#region src/functions/getAttributes.ts
|
|
4084
|
-
function
|
|
4122
|
+
function hn(e) {
|
|
4085
4123
|
let t = {}, n = O(e);
|
|
4086
4124
|
if (n) for (let e of n.attributes) {
|
|
4087
4125
|
var r;
|
|
@@ -4091,7 +4129,7 @@ function mn(e) {
|
|
|
4091
4129
|
}
|
|
4092
4130
|
//#endregion
|
|
4093
4131
|
//#region src/functions/getClipboardData.ts
|
|
4094
|
-
async function
|
|
4132
|
+
async function gn(e) {
|
|
4095
4133
|
if (s()) try {
|
|
4096
4134
|
var t, n;
|
|
4097
4135
|
return (t = e == null || (n = e.clipboardData) == null ? void 0 : n.getData("text")) == null ? await navigator.clipboard.readText() || "" : t;
|
|
@@ -4106,41 +4144,41 @@ async function hn(e) {
|
|
|
4106
4144
|
}
|
|
4107
4145
|
//#endregion
|
|
4108
4146
|
//#region src/functions/getCurrentDate.ts
|
|
4109
|
-
function
|
|
4147
|
+
function _n(e = "datetime") {
|
|
4110
4148
|
return new $e(void 0, e).standard();
|
|
4111
4149
|
}
|
|
4112
4150
|
//#endregion
|
|
4113
4151
|
//#region src/functions/getCurrentTime.ts
|
|
4114
|
-
function
|
|
4152
|
+
function vn() {
|
|
4115
4153
|
return Date.now();
|
|
4116
4154
|
}
|
|
4117
4155
|
//#endregion
|
|
4118
4156
|
//#region src/functions/getElementId.ts
|
|
4119
|
-
var Q,
|
|
4157
|
+
var Q, yn = () => {
|
|
4120
4158
|
let e = Q == null ? void 0 : Q();
|
|
4121
4159
|
if (e) return `id-server-${e}`;
|
|
4122
4160
|
let t = T.get("__ui:getElementId__", () => ({ id: 1e5 }));
|
|
4123
4161
|
return `id-${t.id++}`;
|
|
4124
4162
|
};
|
|
4125
|
-
function
|
|
4163
|
+
function bn(e, t) {
|
|
4126
4164
|
if (e) {
|
|
4127
4165
|
let n = O(e);
|
|
4128
|
-
if (n) return l(n.id) || n.setAttribute("id",
|
|
4166
|
+
if (n) return l(n.id) || n.setAttribute("id", yn()), t ? `#${n.id}${t}`.trim() : n.id;
|
|
4129
4167
|
}
|
|
4130
|
-
return
|
|
4168
|
+
return yn();
|
|
4131
4169
|
}
|
|
4132
|
-
function
|
|
4170
|
+
function xn(e) {
|
|
4133
4171
|
Q || (Q = e);
|
|
4134
4172
|
}
|
|
4135
4173
|
//#endregion
|
|
4136
4174
|
//#region src/functions/getKey.ts
|
|
4137
|
-
function
|
|
4175
|
+
function Sn(e) {
|
|
4138
4176
|
var t, n, r;
|
|
4139
4177
|
return (t = (n = e == null ? void 0 : e.key) == null ? e == null ? void 0 : e.code : n) == null ? e == null || (r = e.keyCode) == null ? void 0 : r.toString() : t;
|
|
4140
4178
|
}
|
|
4141
4179
|
//#endregion
|
|
4142
4180
|
//#region src/functions/getLengthOfAllArray.ts
|
|
4143
|
-
function
|
|
4181
|
+
function Cn(e) {
|
|
4144
4182
|
return r(e, (e) => {
|
|
4145
4183
|
var t;
|
|
4146
4184
|
return (t = e == null ? void 0 : e.length) == null ? 0 : t;
|
|
@@ -4148,41 +4186,41 @@ function Sn(e) {
|
|
|
4148
4186
|
}
|
|
4149
4187
|
//#endregion
|
|
4150
4188
|
//#region src/functions/getMaxLengthAllArray.ts
|
|
4151
|
-
function
|
|
4189
|
+
function wn(e) {
|
|
4152
4190
|
if (!l(e)) return 0;
|
|
4153
|
-
let t =
|
|
4191
|
+
let t = Cn(e);
|
|
4154
4192
|
return t.length > 1e4 ? t.reduce((e, t) => Math.max(e, t)) : Math.max(...t);
|
|
4155
4193
|
}
|
|
4156
4194
|
//#endregion
|
|
4157
4195
|
//#region src/functions/getMinLengthAllArray.ts
|
|
4158
|
-
function
|
|
4196
|
+
function Tn(e) {
|
|
4159
4197
|
if (!l(e)) return 0;
|
|
4160
|
-
let t =
|
|
4198
|
+
let t = Cn(e);
|
|
4161
4199
|
return t.length > 1e4 ? t.reduce((e, t) => Math.min(e, t)) : Math.min(...t);
|
|
4162
4200
|
}
|
|
4163
4201
|
//#endregion
|
|
4164
4202
|
//#region src/functions/getMouseClientX.ts
|
|
4165
|
-
function
|
|
4203
|
+
function En(e) {
|
|
4166
4204
|
var t, n;
|
|
4167
4205
|
return (e == null ? void 0 : e.clientX) || (e == null || (t = e.targetTouches) == null || (t = t[0]) == null ? void 0 : t.clientX) || (e == null || (n = e.touches) == null || (n = n[0]) == null ? void 0 : n.clientX) || 0;
|
|
4168
4206
|
}
|
|
4169
4207
|
//#endregion
|
|
4170
4208
|
//#region src/functions/getMouseClientY.ts
|
|
4171
|
-
function
|
|
4209
|
+
function Dn(e) {
|
|
4172
4210
|
var t, n;
|
|
4173
4211
|
return (e == null ? void 0 : e.clientY) || (e == null || (t = e.targetTouches) == null || (t = t[0]) == null ? void 0 : t.clientY) || (e == null || (n = e.touches) == null || (n = n[0]) == null ? void 0 : n.clientY) || 0;
|
|
4174
4212
|
}
|
|
4175
4213
|
//#endregion
|
|
4176
4214
|
//#region src/functions/getMouseClient.ts
|
|
4177
|
-
function
|
|
4215
|
+
function On(e) {
|
|
4178
4216
|
return {
|
|
4179
|
-
x:
|
|
4180
|
-
y:
|
|
4217
|
+
x: En(e),
|
|
4218
|
+
y: Dn(e)
|
|
4181
4219
|
};
|
|
4182
4220
|
}
|
|
4183
4221
|
//#endregion
|
|
4184
4222
|
//#region src/functions/getObjectByKeys.ts
|
|
4185
|
-
function
|
|
4223
|
+
function kn(e, t) {
|
|
4186
4224
|
let r = {};
|
|
4187
4225
|
return n(e) && t.forEach((t) => {
|
|
4188
4226
|
t in e && e[t] !== void 0 && (r[t] = e[t]);
|
|
@@ -4190,7 +4228,7 @@ function On(e, t) {
|
|
|
4190
4228
|
}
|
|
4191
4229
|
//#endregion
|
|
4192
4230
|
//#region src/functions/getObjectNoUndefined.ts
|
|
4193
|
-
function
|
|
4231
|
+
function An(e, t = void 0) {
|
|
4194
4232
|
let n = {};
|
|
4195
4233
|
return r(e, (e, r) => {
|
|
4196
4234
|
e !== t && (n[r] = e);
|
|
@@ -4198,42 +4236,42 @@ function kn(e, t = void 0) {
|
|
|
4198
4236
|
}
|
|
4199
4237
|
//#endregion
|
|
4200
4238
|
//#region src/functions/getObjectOrNone.ts
|
|
4201
|
-
function
|
|
4239
|
+
function jn(e) {
|
|
4202
4240
|
return n(e) ? e : {};
|
|
4203
4241
|
}
|
|
4204
4242
|
//#endregion
|
|
4205
4243
|
//#region src/functions/getOnlyText.ts
|
|
4206
|
-
function
|
|
4244
|
+
function Mn(e) {
|
|
4207
4245
|
return P(e).replace(/[^\p{L}\p{N}\s]+/gu, "").trim();
|
|
4208
4246
|
}
|
|
4209
4247
|
//#endregion
|
|
4210
4248
|
//#region src/functions/strFill.ts
|
|
4211
|
-
function
|
|
4249
|
+
function Nn(e, t) {
|
|
4212
4250
|
return String(e).repeat(t);
|
|
4213
4251
|
}
|
|
4214
4252
|
//#endregion
|
|
4215
4253
|
//#region src/functions/getRandomText.ts
|
|
4216
|
-
function
|
|
4254
|
+
function Pn(e, t, n = "#", r = 2, i = 12) {
|
|
4217
4255
|
let a = f(e, t), o = [];
|
|
4218
|
-
for (let e = 0; e < a; e++) o.push(
|
|
4256
|
+
for (let e = 0; e < a; e++) o.push(Nn(n, f(r, i)));
|
|
4219
4257
|
return o.join(" ");
|
|
4220
4258
|
}
|
|
4221
4259
|
//#endregion
|
|
4222
4260
|
//#region src/functions/getStepPercent.ts
|
|
4223
|
-
function
|
|
4261
|
+
function Fn(e, t) {
|
|
4224
4262
|
let n = e == null ? 0 : e;
|
|
4225
4263
|
return t > n ? 100 / (t - n) : 0;
|
|
4226
4264
|
}
|
|
4227
4265
|
//#endregion
|
|
4228
4266
|
//#region src/functions/getStepValue.ts
|
|
4229
|
-
function
|
|
4267
|
+
function In(e, t) {
|
|
4230
4268
|
let n = e == null ? 0 : e;
|
|
4231
4269
|
return t > n ? (t - n) / 100 : 0;
|
|
4232
4270
|
}
|
|
4233
4271
|
//#endregion
|
|
4234
4272
|
//#region src/functions/goScroll.ts
|
|
4235
|
-
var
|
|
4236
|
-
function
|
|
4273
|
+
var Ln = 0;
|
|
4274
|
+
function Rn(e, t, n) {
|
|
4237
4275
|
if (!s()) return;
|
|
4238
4276
|
let r = t == null ? void 0 : t.closest(e);
|
|
4239
4277
|
if (t && r && r.scrollHeight !== r.offsetHeight) {
|
|
@@ -4241,12 +4279,12 @@ function Ln(e, t, n) {
|
|
|
4241
4279
|
if (n) {
|
|
4242
4280
|
let a = n.getBoundingClientRect();
|
|
4243
4281
|
r.scrollTop = t.offsetTop - (a.top - e.top) - (a.height / 2 - i.height / 2), r.scrollTop + r.offsetHeight < t.offsetTop + t.offsetHeight && (r.scrollTop = t.offsetTop + t.offsetHeight - r.offsetHeight);
|
|
4244
|
-
} else r.scrollTop > t.offsetTop ? r.scrollTop = i.top - e.top -
|
|
4282
|
+
} else r.scrollTop > t.offsetTop ? r.scrollTop = i.top - e.top - Ln : r.scrollTop + r.offsetHeight < t.offsetTop + t.offsetHeight && (r.scrollTop = i.top - e.top + i.height - e.height + Ln);
|
|
4245
4283
|
}
|
|
4246
4284
|
}
|
|
4247
4285
|
//#endregion
|
|
4248
4286
|
//#region src/functions/goScrollSmooth.ts
|
|
4249
|
-
function
|
|
4287
|
+
function zn(e, t, n = 0) {
|
|
4250
4288
|
if (!s()) return;
|
|
4251
4289
|
let r = (t == null ? void 0 : t.behavior) || "smooth";
|
|
4252
4290
|
if ("scrollIntoView" in e && !n) {
|
|
@@ -4268,7 +4306,7 @@ function Rn(e, t, n = 0) {
|
|
|
4268
4306
|
}
|
|
4269
4307
|
//#endregion
|
|
4270
4308
|
//#region src/functions/goScrollTo.ts
|
|
4271
|
-
function
|
|
4309
|
+
function Bn(e, t, n = "smooth") {
|
|
4272
4310
|
if (!s() || !e || !t) return;
|
|
4273
4311
|
let r = e.getBoundingClientRect(), i = t.getBoundingClientRect();
|
|
4274
4312
|
e.scrollBy({
|
|
@@ -4279,13 +4317,13 @@ function zn(e, t, n = "smooth") {
|
|
|
4279
4317
|
}
|
|
4280
4318
|
//#endregion
|
|
4281
4319
|
//#region src/functions/isShare.ts
|
|
4282
|
-
function
|
|
4320
|
+
function Vn() {
|
|
4283
4321
|
return s() && typeof navigator < "u" && !!navigator.share;
|
|
4284
4322
|
}
|
|
4285
4323
|
//#endregion
|
|
4286
4324
|
//#region src/functions/handleShare.ts
|
|
4287
|
-
async function
|
|
4288
|
-
if (
|
|
4325
|
+
async function Hn(e) {
|
|
4326
|
+
if (Vn() && navigator.canShare && navigator.canShare(e)) try {
|
|
4289
4327
|
return await navigator.share(e), !0;
|
|
4290
4328
|
} catch (e) {
|
|
4291
4329
|
C.on({
|
|
@@ -4298,20 +4336,20 @@ async function Vn(e) {
|
|
|
4298
4336
|
}
|
|
4299
4337
|
//#endregion
|
|
4300
4338
|
//#region src/functions/inArray.ts
|
|
4301
|
-
function
|
|
4339
|
+
function Un(e, t) {
|
|
4302
4340
|
return e.includes(t);
|
|
4303
4341
|
}
|
|
4304
4342
|
//#endregion
|
|
4305
4343
|
//#region src/functions/initScrollbarOffset.ts
|
|
4306
|
-
async function
|
|
4344
|
+
async function Wn() {
|
|
4307
4345
|
if (s()) {
|
|
4308
|
-
let e = await
|
|
4346
|
+
let e = await Et.get();
|
|
4309
4347
|
document.body.style.setProperty("--sys-scrollbar-offset", `${e}px`);
|
|
4310
4348
|
}
|
|
4311
4349
|
}
|
|
4312
4350
|
//#endregion
|
|
4313
4351
|
//#region src/functions/intersectKey.ts
|
|
4314
|
-
function
|
|
4352
|
+
function Gn(e, n) {
|
|
4315
4353
|
let i = {};
|
|
4316
4354
|
return t(e) && t(n) && r(e, (e, t) => {
|
|
4317
4355
|
t in n && (i[t] = e);
|
|
@@ -4319,7 +4357,7 @@ function Wn(e, n) {
|
|
|
4319
4357
|
}
|
|
4320
4358
|
//#endregion
|
|
4321
4359
|
//#region src/functions/isDifferent.ts
|
|
4322
|
-
function
|
|
4360
|
+
function Kn(e, t) {
|
|
4323
4361
|
let n = Object.keys(e).length !== Object.keys(t).length;
|
|
4324
4362
|
return n || r(e, (e, r) => {
|
|
4325
4363
|
e !== (t == null ? void 0 : t[r]) && (n = !0);
|
|
@@ -4327,7 +4365,7 @@ function Gn(e, t) {
|
|
|
4327
4365
|
}
|
|
4328
4366
|
//#endregion
|
|
4329
4367
|
//#region src/functions/isElementVisible.ts
|
|
4330
|
-
function
|
|
4368
|
+
function qn(e) {
|
|
4331
4369
|
if (!s()) return !1;
|
|
4332
4370
|
let t = O(e);
|
|
4333
4371
|
if (!t || "isConnected" in t && t.isConnected === !1) return !1;
|
|
@@ -4336,16 +4374,16 @@ function Kn(e) {
|
|
|
4336
4374
|
}
|
|
4337
4375
|
//#endregion
|
|
4338
4376
|
//#region src/functions/isInput.ts
|
|
4339
|
-
var
|
|
4377
|
+
var Jn = (e) => {
|
|
4340
4378
|
if (e instanceof HTMLElement) {
|
|
4341
4379
|
let t = e.tagName.toLowerCase();
|
|
4342
4380
|
return !!(t === "input" || t === "textarea" || t === "select" || e.isContentEditable || e.getAttribute("contenteditable") === "true");
|
|
4343
4381
|
}
|
|
4344
4382
|
return !1;
|
|
4345
|
-
},
|
|
4383
|
+
}, Yn = (e, t) => e.code === "Space" || e.code === "Enter" || e.key === " " || e.key === "Spacebar" || e.key === "Enter" || e.keyCode === 13 || e.keyCode === 32 ? t === void 0 ? !Jn(e.target) : !t : !1;
|
|
4346
4384
|
//#endregion
|
|
4347
4385
|
//#region src/functions/isFloat.ts
|
|
4348
|
-
function
|
|
4386
|
+
function Xn(e) {
|
|
4349
4387
|
switch (typeof e) {
|
|
4350
4388
|
case "number": return !0;
|
|
4351
4389
|
case "string": return /^-?\d+(\.\d+)?$/.test(e);
|
|
@@ -4354,18 +4392,18 @@ function Yn(e) {
|
|
|
4354
4392
|
}
|
|
4355
4393
|
//#endregion
|
|
4356
4394
|
//#region src/functions/isIntegerBetween.ts
|
|
4357
|
-
function
|
|
4395
|
+
function Zn(e, t) {
|
|
4358
4396
|
let n = Math.floor(t);
|
|
4359
4397
|
return e >= n && e < n + 1;
|
|
4360
4398
|
}
|
|
4361
4399
|
//#endregion
|
|
4362
4400
|
//#region src/functions/isSelectedByList.ts
|
|
4363
|
-
function
|
|
4401
|
+
function Qn(e, t) {
|
|
4364
4402
|
return Array.isArray(e) ? e.every((e) => v(e, t)) : v(e, t);
|
|
4365
4403
|
}
|
|
4366
4404
|
//#endregion
|
|
4367
4405
|
//#region src/functions/removeCommonPrefix.ts
|
|
4368
|
-
function
|
|
4406
|
+
function $n(e, t) {
|
|
4369
4407
|
if (e.startsWith(t)) return e.slice(t.length).trim();
|
|
4370
4408
|
let n = 0;
|
|
4371
4409
|
for (; e[n] === t[n] && n < e.length && n < t.length;) n++;
|
|
@@ -4373,13 +4411,13 @@ function Qn(e, t) {
|
|
|
4373
4411
|
}
|
|
4374
4412
|
//#endregion
|
|
4375
4413
|
//#region src/functions/replaceComponentName.ts
|
|
4376
|
-
var
|
|
4414
|
+
var er = (e, t, n) => {
|
|
4377
4415
|
var r;
|
|
4378
4416
|
return e == null || (r = e.replace(RegExp(`<${t}`, "ig"), `<${n}`)) == null || (r = r.replace(RegExp(`</${t}`, "ig"), `</${n}`)) == null ? void 0 : r.trim();
|
|
4379
4417
|
};
|
|
4380
4418
|
//#endregion
|
|
4381
4419
|
//#region src/functions/uniqueArray.ts
|
|
4382
|
-
function
|
|
4420
|
+
function tr(e) {
|
|
4383
4421
|
return [...new Set(e)];
|
|
4384
4422
|
}
|
|
4385
4423
|
//#endregion
|
|
@@ -4388,20 +4426,20 @@ function $(e, n, i = !0) {
|
|
|
4388
4426
|
let a = Z(e);
|
|
4389
4427
|
return t(e) && t(n) && r(n, (n, r) => {
|
|
4390
4428
|
let o = e == null ? void 0 : e[r];
|
|
4391
|
-
t(o) && t(n) ? i && Array.isArray(o) && Array.isArray(n) ? a[r] = Z(
|
|
4429
|
+
t(o) && t(n) ? i && Array.isArray(o) && Array.isArray(n) ? a[r] = Z(tr([...o, ...n])) : a[r] = $(Array.isArray(o) ? { ...o } : o, n, i) : a[r] = t(n) ? Z(n) : n;
|
|
4392
4430
|
}), a;
|
|
4393
4431
|
}
|
|
4394
4432
|
//#endregion
|
|
4395
4433
|
//#region src/functions/replaceTemplate.ts
|
|
4396
|
-
function
|
|
4434
|
+
function nr(e, t) {
|
|
4397
4435
|
let n = e;
|
|
4398
4436
|
return r(t, (e, t) => {
|
|
4399
|
-
n = n.replace(
|
|
4437
|
+
n = n.replace(Pt(`[${t}]`), b(e));
|
|
4400
4438
|
}), n;
|
|
4401
4439
|
}
|
|
4402
4440
|
//#endregion
|
|
4403
4441
|
//#region src/functions/secondToTime.ts
|
|
4404
|
-
function
|
|
4442
|
+
function rr(e, t) {
|
|
4405
4443
|
let n = _(e);
|
|
4406
4444
|
if (n > 0) {
|
|
4407
4445
|
let e = String(Math.floor(n / 60)).padStart(2, "0"), r = String(n % 60).padStart(2, "0");
|
|
@@ -4411,7 +4449,7 @@ function nr(e, t) {
|
|
|
4411
4449
|
}
|
|
4412
4450
|
//#endregion
|
|
4413
4451
|
//#region src/functions/setValues.ts
|
|
4414
|
-
function
|
|
4452
|
+
function ir(e, t, { multiple: n = !1, maxlength: r = 0, alwaysChange: a = !0, notEmpty: o = !1 }) {
|
|
4415
4453
|
if (n) {
|
|
4416
4454
|
if (i(e)) {
|
|
4417
4455
|
let n = e.indexOf(t), i = [...e];
|
|
@@ -4423,7 +4461,7 @@ function rr(e, t, { multiple: n = !1, maxlength: r = 0, alwaysChange: a = !0, no
|
|
|
4423
4461
|
}
|
|
4424
4462
|
//#endregion
|
|
4425
4463
|
//#region src/functions/splice.ts
|
|
4426
|
-
function
|
|
4464
|
+
function ar(e, n, i) {
|
|
4427
4465
|
if (t(e) && t(n)) {
|
|
4428
4466
|
if (i) {
|
|
4429
4467
|
let a = {}, o = !1;
|
|
@@ -4437,34 +4475,34 @@ function ir(e, n, i) {
|
|
|
4437
4475
|
}
|
|
4438
4476
|
//#endregion
|
|
4439
4477
|
//#region src/functions/toCamelCaseFirst.ts
|
|
4440
|
-
function
|
|
4478
|
+
function or(e) {
|
|
4441
4479
|
return et(e).replace(/^([a-z])/, (e) => `${e.toUpperCase()}`);
|
|
4442
4480
|
}
|
|
4443
4481
|
//#endregion
|
|
4444
4482
|
//#region src/functions/toKebabCase.ts
|
|
4445
|
-
function
|
|
4483
|
+
function sr(e) {
|
|
4446
4484
|
return e.toString().trim().replace(/[^\w-. ]+/g, "").replace(/[ .]+/g, "-").replace(/(?<=[A-Z])([A-Z])/g, (e) => `${e.toLowerCase()}`).replace(/^[A-Z]/, (e) => e.toLowerCase()).replace(/(?<=[\w ])[A-Z]/g, (e) => `-${e.toLowerCase()}`).replace(/[A-Z]/g, (e) => e.toLowerCase());
|
|
4447
4485
|
}
|
|
4448
4486
|
//#endregion
|
|
4449
4487
|
//#region src/functions/toNumberByMax.ts
|
|
4450
|
-
function
|
|
4488
|
+
function cr(e, t, n, r) {
|
|
4451
4489
|
let i = _(e), a = _(t);
|
|
4452
|
-
return t && a < i ? `${
|
|
4490
|
+
return t && a < i ? `${lr(a, n, r)}+` : lr(i, n, r);
|
|
4453
4491
|
}
|
|
4454
|
-
var
|
|
4492
|
+
var lr = (e, t, n) => t ? new z(n).number(e) : e;
|
|
4455
4493
|
//#endregion
|
|
4456
4494
|
//#region src/functions/toPercent.ts
|
|
4457
|
-
function
|
|
4495
|
+
function ur(e, t) {
|
|
4458
4496
|
return e === 0 ? t : 1 / e * t;
|
|
4459
4497
|
}
|
|
4460
4498
|
//#endregion
|
|
4461
4499
|
//#region src/functions/toPercentBy100.ts
|
|
4462
|
-
function
|
|
4463
|
-
return
|
|
4500
|
+
function dr(e, t) {
|
|
4501
|
+
return ur(e, t) * 100;
|
|
4464
4502
|
}
|
|
4465
4503
|
//#endregion
|
|
4466
4504
|
//#region src/functions/uint8ArrayToBase64.ts
|
|
4467
|
-
function
|
|
4505
|
+
function fr(e) {
|
|
4468
4506
|
let t = "";
|
|
4469
4507
|
for (let n of e) t += String.fromCharCode(n);
|
|
4470
4508
|
if (s()) return window.btoa(t);
|
|
@@ -4476,7 +4514,7 @@ function dr(e) {
|
|
|
4476
4514
|
}
|
|
4477
4515
|
//#endregion
|
|
4478
4516
|
//#region src/functions/writeClipboardData.ts
|
|
4479
|
-
async function
|
|
4517
|
+
async function pr(e) {
|
|
4480
4518
|
if (s()) try {
|
|
4481
4519
|
await navigator.clipboard.writeText(e);
|
|
4482
4520
|
} catch (n) {
|
|
@@ -4485,4 +4523,4 @@ async function fr(e) {
|
|
|
4485
4523
|
}
|
|
4486
4524
|
}
|
|
4487
4525
|
//#endregion
|
|
4488
|
-
export { N as Api, j as ApiCache, je as ApiDataReturn, Me as ApiDefault, Ne as ApiHeaders, Fe as ApiHydration, Be as ApiInstance, M as ApiMethodItem, Ie as ApiPreparation, ze as ApiResponse, ke as ApiStatus, Ve as BroadcastMessage, We as Cache, Ue as CacheItem, Ge as CacheStatic, Ze as Cookie, Je as CookieBlock, qe as CookieBlockInstance, L as CookieStorage, E as DataStorage, $e as Datetime, C as ErrorCenter, de as ErrorCenterHandler, fe as ErrorCenterInstance, we as EventItem, tt as Formatters, U as FormattersType, nt as GEO_FLAG_ICON_NAME, D as Geo, rt as GeoFlag, be as GeoInstance, z as GeoIntl, it as GeoPhone, at as Global, st as Hash, ot as HashInstance, ut as Icons, A as Loading, Ee as LoadingInstance, Ct as Meta, K as MetaManager, xt as MetaOg, vt as MetaOpenGraphAge, gt as MetaOpenGraphAvailability, _t as MetaOpenGraphCondition, yt as MetaOpenGraphGender, J as MetaOpenGraphTag, ht as MetaOpenGraphType, mt as MetaRobots, wt as MetaStatic, q as MetaTag, St as MetaTwitter, bt as MetaTwitterCard, Y as MetaTwitterTag, Tt as ScrollbarWidth,
|
|
4526
|
+
export { N as Api, j as ApiCache, je as ApiDataReturn, Me as ApiDefault, Ne as ApiHeaders, Fe as ApiHydration, Be as ApiInstance, M as ApiMethodItem, Ie as ApiPreparation, ze as ApiResponse, ke as ApiStatus, Ve as BroadcastMessage, We as Cache, Ue as CacheItem, Ge as CacheStatic, Ze as Cookie, Je as CookieBlock, qe as CookieBlockInstance, L as CookieStorage, E as DataStorage, $e as Datetime, C as ErrorCenter, de as ErrorCenterHandler, fe as ErrorCenterInstance, we as EventItem, tt as Formatters, U as FormattersType, nt as GEO_FLAG_ICON_NAME, D as Geo, rt as GeoFlag, be as GeoInstance, z as GeoIntl, it as GeoPhone, at as Global, st as Hash, ot as HashInstance, ut as Icons, A as Loading, Ee as LoadingInstance, Ct as Meta, K as MetaManager, xt as MetaOg, vt as MetaOpenGraphAge, gt as MetaOpenGraphAvailability, _t as MetaOpenGraphCondition, yt as MetaOpenGraphGender, J as MetaOpenGraphTag, ht as MetaOpenGraphType, mt as MetaRobots, wt as MetaStatic, q as MetaTag, St as MetaTwitter, bt as MetaTwitterCard, Y as MetaTwitterTag, Tt as ResumableTimer, Et as ScrollbarWidth, zt as SearchList, Mt as SearchListData, Nt as SearchListItem, Lt as SearchListMatcher, Rt as SearchListOptions, T as ServerStorage, Vt as StorageCallback, Kt as TRANSLATE_GLOBAL_PREFIX, qt as TRANSLATE_TIME_OUT, Xt as Translate, Jt as TranslateFile, Yt as TranslateInstance, jt as addTagHighlightMatch, P as anyToString, Wt as applyTemplate, Zt as arrFill, nn as blobToBase64, rn as capitalize, Z as copyObject, an as copyObjectLite, W as createElement, on as domQuerySelector, sn as domQuerySelectorAll, G as encodeAttribute, se as encodeLiteAttribute, dn as ensureMaxSize, X as escapeExp, fn as eventStopPropagation, b as executeFunction, Le as executePromise, r as forEach, pn as frame, mn as getArrayHighlightMatch, hn as getAttributes, gn as getClipboardData, Qe as getColumn, _n as getCurrentDate, vn as getCurrentTime, O as getElement, bn as getElementId, cn as getElementImage, dt as getElementItem, Se as getElementOrWindow, me as getElementSafeScript, Ft as getExactSearchExp, Pt as getExp, he as getHydrationData, H as getItemByPath, Sn as getKey, Cn as getLengthOfAllArray, wn as getMaxLengthAllArray, Tn as getMinLengthAllArray, On as getMouseClient, En as getMouseClientX, Dn as getMouseClientY, kn as getObjectByKeys, An as getObjectNoUndefined, jn as getObjectOrNone, Mn as getOnlyText, Pn as getRandomText, o as getRequestString, It as getSearchExp, Dt as getSeparatingSearchExp, Fn as getStepPercent, In as getStepValue, Rn as goScroll, zn as goScrollSmooth, Bn as goScrollTo, Hn as handleShare, Un as inArray, xn as initGetElementId, Wn as initScrollbarOffset, Gn as intersectKey, Gt as isApiSuccess, i as isArray, Kn as isDifferent, ce as isDomData, s as isDomRuntime, qn as isElementVisible, Yn as isEnter, l as isFilled, Xn as isFloat, y as isFunction, Ce as isInDom, Jn as isInput, Zn as isIntegerBetween, c as isNull, h as isNumber, t as isObject, n as isObjectNotArray, u as isOnLine, v as isSelected, Qn as isSelectedByList, Vn as isShare, d as isString, xe as isWindow, f as random, $n as removeCommonPrefix, er as replaceComponentName, $ as replaceRecursive, nr as replaceTemplate, un as resizeImageByMax, rr as secondToTime, ft as setElementItem, ir as setValues, p as sleep, ar as splice, Nn as strFill, F as strSplit, k as toArray, et as toCamelCase, or as toCamelCaseFirst, R as toDate, sr as toKebabCase, _ as toNumber, cr as toNumberByMax, ur as toPercent, dr as toPercentBy100, a as toString, I as transformation, fr as uint8ArrayToBase64, tr as uniqueArray, pr as writeClipboardData };
|