image-salon-sdk 1.0.78 → 1.0.79
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/image-salon-sdk.js +341 -332
- package/dist/image-salon-sdk.umd.cjs +8 -8
- package/dist/image-salon.d.ts +1 -0
- package/dist/style.css +1 -1
- package/dist/types/image-salon-types.d.ts +1 -0
- package/package.json +1 -1
package/dist/image-salon-sdk.js
CHANGED
|
@@ -19,17 +19,17 @@ function Ir(s) {
|
|
|
19
19
|
function oi(s) {
|
|
20
20
|
return s !== null && typeof s == "object" && !Array.isArray(s);
|
|
21
21
|
}
|
|
22
|
-
let bt = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split(""),
|
|
22
|
+
let bt = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split(""), Ln = [];
|
|
23
23
|
for (let s = 0; s < bt.length; s++)
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
24
|
+
Ln[bt[s].charCodeAt(0)] = s;
|
|
25
|
+
Ln[45] = bt.indexOf("+");
|
|
26
|
+
Ln[95] = bt.indexOf("/");
|
|
27
27
|
function Tr(s) {
|
|
28
28
|
let e = s.length * 3 / 4;
|
|
29
29
|
s[s.length - 2] == "=" ? e -= 2 : s[s.length - 1] == "=" && (e -= 1);
|
|
30
30
|
let t = new Uint8Array(e), n = 0, r = 0, i, o = 0;
|
|
31
31
|
for (let a = 0; a < s.length; a++) {
|
|
32
|
-
if (i =
|
|
32
|
+
if (i = Ln[s.charCodeAt(a)], i === void 0)
|
|
33
33
|
switch (s[a]) {
|
|
34
34
|
case "=":
|
|
35
35
|
r = 0;
|
|
@@ -117,7 +117,7 @@ function li() {
|
|
|
117
117
|
}
|
|
118
118
|
throw new Error("invalid varint");
|
|
119
119
|
}
|
|
120
|
-
function
|
|
120
|
+
function Bn(s, e, t) {
|
|
121
121
|
for (let i = 0; i < 28; i = i + 7) {
|
|
122
122
|
const o = s >>> i, a = !(!(o >>> 7) && e == 0), c = (a ? o | 128 : o) & 255;
|
|
123
123
|
if (t.push(c), !a)
|
|
@@ -133,7 +133,7 @@ function _n(s, e, t) {
|
|
|
133
133
|
t.push(e >>> 31 & 1);
|
|
134
134
|
}
|
|
135
135
|
}
|
|
136
|
-
const
|
|
136
|
+
const yn = 65536 * 65536;
|
|
137
137
|
function Ur(s) {
|
|
138
138
|
let e = s[0] == "-";
|
|
139
139
|
e && (s = s.slice(1));
|
|
@@ -141,13 +141,13 @@ function Ur(s) {
|
|
|
141
141
|
let n = 0, r = 0;
|
|
142
142
|
function i(o, a) {
|
|
143
143
|
const c = Number(s.slice(o, a));
|
|
144
|
-
r *= t, n = n * t + c, n >=
|
|
144
|
+
r *= t, n = n * t + c, n >= yn && (r = r + (n / yn | 0), n = n % yn);
|
|
145
145
|
}
|
|
146
146
|
return i(-24, -18), i(-18, -12), i(-12, -6), i(-6), [e, n, r];
|
|
147
147
|
}
|
|
148
|
-
function
|
|
148
|
+
function Wn(s, e) {
|
|
149
149
|
if (e >>> 0 <= 2097151)
|
|
150
|
-
return "" + (
|
|
150
|
+
return "" + (yn * e + (s >>> 0));
|
|
151
151
|
let t = s & 16777215, n = (s >>> 24 | e << 8) >>> 0 & 16777215, r = e >> 16 & 65535, i = t + n * 6777216 + r * 6710656, o = n + r * 8147497, a = r * 2, c = 1e7;
|
|
152
152
|
i >= c && (o += Math.floor(i / c), i %= c), o >= c && (a += Math.floor(o / c), o %= c);
|
|
153
153
|
function h(l, u) {
|
|
@@ -215,7 +215,7 @@ function xr(s) {
|
|
|
215
215
|
if (!s)
|
|
216
216
|
throw new Error("BigInt unavailable, see https://github.com/timostamm/protobuf-ts/blob/v1.0.8/MANUAL.md#bigint-support");
|
|
217
217
|
}
|
|
218
|
-
const _r = /^-?[0-9]+$/,
|
|
218
|
+
const _r = /^-?[0-9]+$/, Cn = 4294967296, un = 2147483648;
|
|
219
219
|
class Br {
|
|
220
220
|
/**
|
|
221
221
|
* Create a new instance with the given bits.
|
|
@@ -233,7 +233,7 @@ class Br {
|
|
|
233
233
|
* Convert to a native number.
|
|
234
234
|
*/
|
|
235
235
|
toNumber() {
|
|
236
|
-
let e = this.hi *
|
|
236
|
+
let e = this.hi * Cn + (this.lo >>> 0);
|
|
237
237
|
if (!Number.isSafeInteger(e))
|
|
238
238
|
throw new Error("cannot convert to safe number");
|
|
239
239
|
return e;
|
|
@@ -283,7 +283,7 @@ class Se extends Br {
|
|
|
283
283
|
throw new Error("number is no integer");
|
|
284
284
|
if (e < 0)
|
|
285
285
|
throw new Error("signed value for ulong");
|
|
286
|
-
return new Se(e, e /
|
|
286
|
+
return new Se(e, e / Cn);
|
|
287
287
|
}
|
|
288
288
|
throw new Error("unknown value " + typeof e);
|
|
289
289
|
}
|
|
@@ -291,7 +291,7 @@ class Se extends Br {
|
|
|
291
291
|
* Convert to decimal string.
|
|
292
292
|
*/
|
|
293
293
|
toString() {
|
|
294
|
-
return se ? this.toBigInt().toString() :
|
|
294
|
+
return se ? this.toBigInt().toString() : Wn(this.lo, this.hi);
|
|
295
295
|
}
|
|
296
296
|
/**
|
|
297
297
|
* Convert to native bigint.
|
|
@@ -336,9 +336,9 @@ class ve extends Br {
|
|
|
336
336
|
throw new Error("string is no integer");
|
|
337
337
|
let [t, n, r] = Ur(e);
|
|
338
338
|
if (t) {
|
|
339
|
-
if (r >
|
|
339
|
+
if (r > un || r == un && n != 0)
|
|
340
340
|
throw new Error("signed long too small");
|
|
341
|
-
} else if (r >=
|
|
341
|
+
} else if (r >= un)
|
|
342
342
|
throw new Error("signed long too large");
|
|
343
343
|
let i = new ve(n, r);
|
|
344
344
|
return t ? i.negate() : i;
|
|
@@ -347,7 +347,7 @@ class ve extends Br {
|
|
|
347
347
|
return this.ZERO;
|
|
348
348
|
if (!Number.isSafeInteger(e))
|
|
349
349
|
throw new Error("number is no integer");
|
|
350
|
-
return e > 0 ? new ve(e, e /
|
|
350
|
+
return e > 0 ? new ve(e, e / Cn) : new ve(-e, -e / Cn).negate();
|
|
351
351
|
}
|
|
352
352
|
throw new Error("unknown value " + typeof e);
|
|
353
353
|
}
|
|
@@ -355,7 +355,7 @@ class ve extends Br {
|
|
|
355
355
|
* Do we have a minus sign?
|
|
356
356
|
*/
|
|
357
357
|
isNegative() {
|
|
358
|
-
return (this.hi &
|
|
358
|
+
return (this.hi & un) !== 0;
|
|
359
359
|
}
|
|
360
360
|
/**
|
|
361
361
|
* Negate two's complement.
|
|
@@ -373,9 +373,9 @@ class ve extends Br {
|
|
|
373
373
|
return this.toBigInt().toString();
|
|
374
374
|
if (this.isNegative()) {
|
|
375
375
|
let e = this.negate();
|
|
376
|
-
return "-" +
|
|
376
|
+
return "-" + Wn(e.lo, e.hi);
|
|
377
377
|
}
|
|
378
|
-
return
|
|
378
|
+
return Wn(this.lo, this.hi);
|
|
379
379
|
}
|
|
380
380
|
/**
|
|
381
381
|
* Convert to native bigint.
|
|
@@ -539,13 +539,13 @@ function J(s, e) {
|
|
|
539
539
|
throw new Error(e);
|
|
540
540
|
}
|
|
541
541
|
const fi = 34028234663852886e22, pi = -34028234663852886e22, mi = 4294967295, gi = 2147483647, wi = -2147483648;
|
|
542
|
-
function
|
|
542
|
+
function rn(s) {
|
|
543
543
|
if (typeof s != "number")
|
|
544
544
|
throw new Error("invalid int 32: " + typeof s);
|
|
545
545
|
if (!Number.isInteger(s) || s > gi || s < wi)
|
|
546
546
|
throw new Error("invalid int 32: " + s);
|
|
547
547
|
}
|
|
548
|
-
function
|
|
548
|
+
function En(s) {
|
|
549
549
|
if (typeof s != "number")
|
|
550
550
|
throw new Error("invalid uint 32: " + typeof s);
|
|
551
551
|
if (!Number.isInteger(s) || s > mi || s < 0)
|
|
@@ -620,7 +620,7 @@ class bi {
|
|
|
620
620
|
* Write a `uint32` value, an unsigned 32 bit varint.
|
|
621
621
|
*/
|
|
622
622
|
uint32(e) {
|
|
623
|
-
for (
|
|
623
|
+
for (En(e); e > 127; )
|
|
624
624
|
this.buf.push(e & 127 | 128), e = e >>> 7;
|
|
625
625
|
return this.buf.push(e), this;
|
|
626
626
|
}
|
|
@@ -628,7 +628,7 @@ class bi {
|
|
|
628
628
|
* Write a `int32` value, a signed 32 bit varint.
|
|
629
629
|
*/
|
|
630
630
|
int32(e) {
|
|
631
|
-
return
|
|
631
|
+
return rn(e), rr(e, this.buf), this;
|
|
632
632
|
}
|
|
633
633
|
/**
|
|
634
634
|
* Write a `bool` value, a variant.
|
|
@@ -668,7 +668,7 @@ class bi {
|
|
|
668
668
|
* Write a `fixed32` value, an unsigned, fixed-length 32-bit integer.
|
|
669
669
|
*/
|
|
670
670
|
fixed32(e) {
|
|
671
|
-
|
|
671
|
+
En(e);
|
|
672
672
|
let t = new Uint8Array(4);
|
|
673
673
|
return new DataView(t.buffer).setUint32(0, e, !0), this.raw(t);
|
|
674
674
|
}
|
|
@@ -676,7 +676,7 @@ class bi {
|
|
|
676
676
|
* Write a `sfixed32` value, a signed, fixed-length 32-bit integer.
|
|
677
677
|
*/
|
|
678
678
|
sfixed32(e) {
|
|
679
|
-
|
|
679
|
+
rn(e);
|
|
680
680
|
let t = new Uint8Array(4);
|
|
681
681
|
return new DataView(t.buffer).setInt32(0, e, !0), this.raw(t);
|
|
682
682
|
}
|
|
@@ -684,7 +684,7 @@ class bi {
|
|
|
684
684
|
* Write a `sint32` value, a signed, zigzag-encoded 32-bit varint.
|
|
685
685
|
*/
|
|
686
686
|
sint32(e) {
|
|
687
|
-
return
|
|
687
|
+
return rn(e), e = (e << 1 ^ e >> 31) >>> 0, rr(e, this.buf), this;
|
|
688
688
|
}
|
|
689
689
|
/**
|
|
690
690
|
* Write a `fixed64` value, a signed, fixed-length 64-bit integer.
|
|
@@ -705,21 +705,21 @@ class bi {
|
|
|
705
705
|
*/
|
|
706
706
|
int64(e) {
|
|
707
707
|
let t = ve.from(e);
|
|
708
|
-
return
|
|
708
|
+
return Bn(t.lo, t.hi, this.buf), this;
|
|
709
709
|
}
|
|
710
710
|
/**
|
|
711
711
|
* Write a `sint64` value, a signed, zig-zag-encoded 64-bit varint.
|
|
712
712
|
*/
|
|
713
713
|
sint64(e) {
|
|
714
714
|
let t = ve.from(e), n = t.hi >> 31, r = t.lo << 1 ^ n, i = (t.hi << 1 | t.lo >>> 31) ^ n;
|
|
715
|
-
return
|
|
715
|
+
return Bn(r, i, this.buf), this;
|
|
716
716
|
}
|
|
717
717
|
/**
|
|
718
718
|
* Write a `uint64` value, an unsigned 64-bit varint.
|
|
719
719
|
*/
|
|
720
720
|
uint64(e) {
|
|
721
721
|
let t = Se.from(e);
|
|
722
|
-
return
|
|
722
|
+
return Bn(t.lo, t.hi, this.buf), this;
|
|
723
723
|
}
|
|
724
724
|
}
|
|
725
725
|
const or = {
|
|
@@ -742,7 +742,7 @@ function vi(s, e) {
|
|
|
742
742
|
return r.typeRegistry = [...(t = s == null ? void 0 : s.typeRegistry) !== null && t !== void 0 ? t : [], ...(n = e == null ? void 0 : e.typeRegistry) !== null && n !== void 0 ? n : []], r;
|
|
743
743
|
}
|
|
744
744
|
const Or = Symbol.for("protobuf-ts/message-type");
|
|
745
|
-
function
|
|
745
|
+
function jn(s) {
|
|
746
746
|
let e = !1;
|
|
747
747
|
const t = [];
|
|
748
748
|
for (let n = 0; n < s.length; n++) {
|
|
@@ -759,13 +759,13 @@ var ut;
|
|
|
759
759
|
(function(s) {
|
|
760
760
|
s[s.BIGINT = 0] = "BIGINT", s[s.STRING = 1] = "STRING", s[s.NUMBER = 2] = "NUMBER";
|
|
761
761
|
})(ut || (ut = {}));
|
|
762
|
-
var
|
|
762
|
+
var vn;
|
|
763
763
|
(function(s) {
|
|
764
764
|
s[s.NO = 0] = "NO", s[s.PACKED = 1] = "PACKED", s[s.UNPACKED = 2] = "UNPACKED";
|
|
765
|
-
})(
|
|
765
|
+
})(vn || (vn = {}));
|
|
766
766
|
function Ai(s) {
|
|
767
767
|
var e, t, n, r;
|
|
768
|
-
return s.localName = (e = s.localName) !== null && e !== void 0 ? e :
|
|
768
|
+
return s.localName = (e = s.localName) !== null && e !== void 0 ? e : jn(s.name), s.jsonName = (t = s.jsonName) !== null && t !== void 0 ? t : jn(s.name), s.repeat = (n = s.repeat) !== null && n !== void 0 ? n : vn.NO, s.opt = (r = s.opt) !== null && r !== void 0 ? r : s.repeat || s.oneof ? !1 : s.kind == "message", s;
|
|
769
769
|
}
|
|
770
770
|
function ki(s) {
|
|
771
771
|
if (typeof s != "object" || s === null || !s.hasOwnProperty("oneofKind"))
|
|
@@ -1146,7 +1146,7 @@ class Ni {
|
|
|
1146
1146
|
let a;
|
|
1147
1147
|
if (typeof e == "number" ? a = e : e === "" ? i = "empty string" : typeof e == "string" && (e.trim().length !== e.length ? i = "extra whitespace" : a = Number(e)), a === void 0)
|
|
1148
1148
|
break;
|
|
1149
|
-
return t == D.UINT32 ?
|
|
1149
|
+
return t == D.UINT32 ? En(a) : rn(a), a;
|
|
1150
1150
|
case D.INT64:
|
|
1151
1151
|
case D.SFIXED64:
|
|
1152
1152
|
case D.SINT64:
|
|
@@ -1316,10 +1316,10 @@ class Ii {
|
|
|
1316
1316
|
case D.INT32:
|
|
1317
1317
|
case D.SFIXED32:
|
|
1318
1318
|
case D.SINT32:
|
|
1319
|
-
return t === 0 ? o ? 0 : void 0 : (
|
|
1319
|
+
return t === 0 ? o ? 0 : void 0 : (rn(t), t);
|
|
1320
1320
|
case D.FIXED32:
|
|
1321
1321
|
case D.UINT32:
|
|
1322
|
-
return t === 0 ? o ? 0 : void 0 : (
|
|
1322
|
+
return t === 0 ? o ? 0 : void 0 : (En(t), t);
|
|
1323
1323
|
case D.FLOAT:
|
|
1324
1324
|
Xn(t);
|
|
1325
1325
|
case D.DOUBLE:
|
|
@@ -1344,7 +1344,7 @@ class Ii {
|
|
|
1344
1344
|
}
|
|
1345
1345
|
}
|
|
1346
1346
|
}
|
|
1347
|
-
function
|
|
1347
|
+
function qn(s, e = ut.STRING) {
|
|
1348
1348
|
switch (s) {
|
|
1349
1349
|
case D.BOOL:
|
|
1350
1350
|
return !1;
|
|
@@ -1460,13 +1460,13 @@ class Ti {
|
|
|
1460
1460
|
}
|
|
1461
1461
|
}
|
|
1462
1462
|
if (o === void 0) {
|
|
1463
|
-
let c =
|
|
1463
|
+
let c = qn(e.K);
|
|
1464
1464
|
o = e.K == D.BOOL ? c.toString() : c;
|
|
1465
1465
|
}
|
|
1466
1466
|
if (a === void 0)
|
|
1467
1467
|
switch (e.V.kind) {
|
|
1468
1468
|
case "scalar":
|
|
1469
|
-
a =
|
|
1469
|
+
a = qn(e.V.T, e.V.L);
|
|
1470
1470
|
break;
|
|
1471
1471
|
case "enum":
|
|
1472
1472
|
a = 0;
|
|
@@ -1541,7 +1541,7 @@ class Li {
|
|
|
1541
1541
|
case "enum":
|
|
1542
1542
|
let l = i.kind == "enum" ? D.INT32 : i.T;
|
|
1543
1543
|
if (c)
|
|
1544
|
-
if (J(Array.isArray(o)), c ==
|
|
1544
|
+
if (J(Array.isArray(o)), c == vn.PACKED)
|
|
1545
1545
|
this.packed(t, l, i.no, o);
|
|
1546
1546
|
else
|
|
1547
1547
|
for (const u of o)
|
|
@@ -1690,7 +1690,7 @@ function Ui(s) {
|
|
|
1690
1690
|
else
|
|
1691
1691
|
switch (t.kind) {
|
|
1692
1692
|
case "scalar":
|
|
1693
|
-
e[n] =
|
|
1693
|
+
e[n] = qn(t.T, t.L);
|
|
1694
1694
|
break;
|
|
1695
1695
|
case "enum":
|
|
1696
1696
|
e[n] = 0;
|
|
@@ -1763,7 +1763,7 @@ function xi(s, e, t) {
|
|
|
1763
1763
|
return !1;
|
|
1764
1764
|
break;
|
|
1765
1765
|
case "map":
|
|
1766
|
-
if (!(n.V.kind == "message" ? cr(n.V.T(),
|
|
1766
|
+
if (!(n.V.kind == "message" ? cr(n.V.T(), fn(i), fn(o)) : lr(n.V.kind == "enum" ? D.INT32 : n.V.T, fn(i), fn(o))))
|
|
1767
1767
|
return !1;
|
|
1768
1768
|
break;
|
|
1769
1769
|
case "message":
|
|
@@ -1775,7 +1775,7 @@ function xi(s, e, t) {
|
|
|
1775
1775
|
}
|
|
1776
1776
|
return !0;
|
|
1777
1777
|
}
|
|
1778
|
-
const
|
|
1778
|
+
const fn = Object.values;
|
|
1779
1779
|
function Sr(s, e, t) {
|
|
1780
1780
|
if (e === t)
|
|
1781
1781
|
return !0;
|
|
@@ -1945,7 +1945,7 @@ class Fe {
|
|
|
1945
1945
|
function Bi(s, e) {
|
|
1946
1946
|
var t, n, r;
|
|
1947
1947
|
let i = s;
|
|
1948
|
-
return i.service = e, i.localName = (t = i.localName) !== null && t !== void 0 ? t :
|
|
1948
|
+
return i.service = e, i.localName = (t = i.localName) !== null && t !== void 0 ? t : jn(i.name), i.serverStreaming = !!i.serverStreaming, i.clientStreaming = !!i.clientStreaming, i.options = (n = i.options) !== null && n !== void 0 ? n : {}, i.idempotency = (r = i.idempotency) !== null && r !== void 0 ? r : void 0, i;
|
|
1949
1949
|
}
|
|
1950
1950
|
class Gn {
|
|
1951
1951
|
constructor(e, t, n) {
|
|
@@ -1973,7 +1973,7 @@ function Oi(s, e) {
|
|
|
1973
1973
|
if (!e)
|
|
1974
1974
|
return s;
|
|
1975
1975
|
let t = {};
|
|
1976
|
-
|
|
1976
|
+
pn(s, t), pn(e, t);
|
|
1977
1977
|
for (let n of Object.keys(e)) {
|
|
1978
1978
|
let r = e[n];
|
|
1979
1979
|
switch (n) {
|
|
@@ -1984,7 +1984,7 @@ function Oi(s, e) {
|
|
|
1984
1984
|
t.binaryOptions = ai(s.binaryOptions, t.binaryOptions);
|
|
1985
1985
|
break;
|
|
1986
1986
|
case "meta":
|
|
1987
|
-
t.meta = {},
|
|
1987
|
+
t.meta = {}, pn(s.meta, t.meta), pn(e.meta, t.meta);
|
|
1988
1988
|
break;
|
|
1989
1989
|
case "interceptors":
|
|
1990
1990
|
t.interceptors = s.interceptors ? s.interceptors.concat(r) : r.concat();
|
|
@@ -1993,7 +1993,7 @@ function Oi(s, e) {
|
|
|
1993
1993
|
}
|
|
1994
1994
|
return t;
|
|
1995
1995
|
}
|
|
1996
|
-
function
|
|
1996
|
+
function pn(s, e) {
|
|
1997
1997
|
if (!s)
|
|
1998
1998
|
return;
|
|
1999
1999
|
let t = e;
|
|
@@ -2347,7 +2347,7 @@ function hr(s, e) {
|
|
|
2347
2347
|
t[r] = n % 256, n >>>= 8;
|
|
2348
2348
|
return t.set(s, 5), e === "binary" ? t : Lr(t);
|
|
2349
2349
|
}
|
|
2350
|
-
function
|
|
2350
|
+
function Zn(s, e, t) {
|
|
2351
2351
|
if (arguments.length === 1) {
|
|
2352
2352
|
let c = s, h;
|
|
2353
2353
|
try {
|
|
@@ -2360,7 +2360,7 @@ function qn(s, e, t) {
|
|
|
2360
2360
|
case "opaqueredirect":
|
|
2361
2361
|
throw new ie(`fetch response type ${c.type}`, j[j.UNKNOWN]);
|
|
2362
2362
|
}
|
|
2363
|
-
return
|
|
2363
|
+
return Zn(ji(c.headers), c.status, c.statusText);
|
|
2364
2364
|
}
|
|
2365
2365
|
let n = s, r = e >= 200 && e < 300, i = Dr(n), [o, a] = Rr(n);
|
|
2366
2366
|
return (o === void 0 || o === j.OK) && !r && (o = qi(e), a = t), [o, a, i];
|
|
@@ -2375,8 +2375,8 @@ var tt;
|
|
|
2375
2375
|
})(tt || (tt = {}));
|
|
2376
2376
|
function fr(s, e, t) {
|
|
2377
2377
|
return Hi(this, void 0, void 0, function* () {
|
|
2378
|
-
let n, r = "", i = new Uint8Array(0), o =
|
|
2379
|
-
if (
|
|
2378
|
+
let n, r = "", i = new Uint8Array(0), o = $i(e);
|
|
2379
|
+
if (Pi(s)) {
|
|
2380
2380
|
let a = s.getReader();
|
|
2381
2381
|
n = {
|
|
2382
2382
|
next: () => a.read()
|
|
@@ -2416,12 +2416,12 @@ function fr(s, e, t) {
|
|
|
2416
2416
|
}
|
|
2417
2417
|
});
|
|
2418
2418
|
}
|
|
2419
|
-
const
|
|
2419
|
+
const Pi = (s) => typeof s.getReader == "function";
|
|
2420
2420
|
function pr(s, e) {
|
|
2421
2421
|
let t = new Uint8Array(s.length + e.length);
|
|
2422
2422
|
return t.set(s), t.set(e, s.length), t;
|
|
2423
2423
|
}
|
|
2424
|
-
function
|
|
2424
|
+
function $i(s) {
|
|
2425
2425
|
switch (s) {
|
|
2426
2426
|
case "application/grpc-web-text":
|
|
2427
2427
|
case "application/grpc-web-text+proto":
|
|
@@ -2563,7 +2563,7 @@ class Zi {
|
|
|
2563
2563
|
signal: (o = n.abort) !== null && o !== void 0 ? o : null
|
|
2564
2564
|
// node-fetch@3.0.0-beta.9 rejects `undefined`
|
|
2565
2565
|
})).then((v) => {
|
|
2566
|
-
let [L, b, B] =
|
|
2566
|
+
let [L, b, B] = Zn(v);
|
|
2567
2567
|
if (f.resolve(B), L != null && L !== j.OK)
|
|
2568
2568
|
throw new ie(b ?? j[L], j[L], B);
|
|
2569
2569
|
return L != null && (I = {
|
|
@@ -2610,7 +2610,7 @@ class Zi {
|
|
|
2610
2610
|
signal: (o = n.abort) !== null && o !== void 0 ? o : null
|
|
2611
2611
|
// node-fetch@3.0.0-beta.9 rejects `undefined`
|
|
2612
2612
|
})).then((v) => {
|
|
2613
|
-
let [L, b, B] =
|
|
2613
|
+
let [L, b, B] = Zn(v);
|
|
2614
2614
|
if (f.resolve(B), L != null && L !== j.OK)
|
|
2615
2615
|
throw new ie(b ?? j[L], j[L], B);
|
|
2616
2616
|
return L != null && (I = {
|
|
@@ -2654,7 +2654,7 @@ class Zi {
|
|
|
2654
2654
|
}), new Di(e, (a = c.meta) !== null && a !== void 0 ? a : {}, t, f.promise, F.promise, C.promise, O.promise);
|
|
2655
2655
|
}
|
|
2656
2656
|
}
|
|
2657
|
-
var
|
|
2657
|
+
var Un = /* @__PURE__ */ ((s) => (s[s.IMAGE = 0] = "IMAGE", s[s.AUDIO = 1] = "AUDIO", s[s.VIDEO = 2] = "VIDEO", s[s.ALL = 3] = "ALL", s[s.FOLDER = 4] = "FOLDER", s))(Un || {});
|
|
2658
2658
|
class Ki extends Fe {
|
|
2659
2659
|
constructor() {
|
|
2660
2660
|
super("com.hamropatro.grpc.common.SearchRequest", [
|
|
@@ -2799,7 +2799,7 @@ class Gi extends Fe {
|
|
|
2799
2799
|
T: 9
|
|
2800
2800
|
/*ScalarType.STRING*/
|
|
2801
2801
|
},
|
|
2802
|
-
{ no: 5, name: "type", kind: "enum", T: () => ["com.hamropatro.grpc.common.FileType",
|
|
2802
|
+
{ no: 5, name: "type", kind: "enum", T: () => ["com.hamropatro.grpc.common.FileType", Un] },
|
|
2803
2803
|
{
|
|
2804
2804
|
no: 6,
|
|
2805
2805
|
name: "extension",
|
|
@@ -2869,7 +2869,7 @@ class Ji extends Fe {
|
|
|
2869
2869
|
T: 9
|
|
2870
2870
|
/*ScalarType.STRING*/
|
|
2871
2871
|
},
|
|
2872
|
-
{ no: 2, name: "type", kind: "enum", T: () => ["com.hamropatro.grpc.common.FileType",
|
|
2872
|
+
{ no: 2, name: "type", kind: "enum", T: () => ["com.hamropatro.grpc.common.FileType", Un] },
|
|
2873
2873
|
{
|
|
2874
2874
|
no: 3,
|
|
2875
2875
|
name: "extension",
|
|
@@ -2969,8 +2969,8 @@ class Qi extends Fe {
|
|
|
2969
2969
|
T: 9
|
|
2970
2970
|
/*ScalarType.STRING*/
|
|
2971
2971
|
},
|
|
2972
|
-
{ no: 8, name: "type", kind: "enum", T: () => ["com.hamropatro.grpc.common.FileType",
|
|
2973
|
-
{ no: 9, name: "metadata", kind: "message", T: () =>
|
|
2972
|
+
{ no: 8, name: "type", kind: "enum", T: () => ["com.hamropatro.grpc.common.FileType", Un] },
|
|
2973
|
+
{ no: 9, name: "metadata", kind: "message", T: () => On }
|
|
2974
2974
|
]);
|
|
2975
2975
|
}
|
|
2976
2976
|
create(e) {
|
|
@@ -3016,7 +3016,7 @@ class Qi extends Fe {
|
|
|
3016
3016
|
break;
|
|
3017
3017
|
case /* com.hamropatro.grpc.common.FileMetadata metadata */
|
|
3018
3018
|
9:
|
|
3019
|
-
i.metadata =
|
|
3019
|
+
i.metadata = On.internalBinaryRead(e, e.uint32(), n, i.metadata);
|
|
3020
3020
|
break;
|
|
3021
3021
|
default:
|
|
3022
3022
|
let h = n.readUnknownField;
|
|
@@ -3029,7 +3029,7 @@ class Qi extends Fe {
|
|
|
3029
3029
|
return i;
|
|
3030
3030
|
}
|
|
3031
3031
|
internalBinaryWrite(e, t, n) {
|
|
3032
|
-
e.key !== "" && t.tag(1, W.LengthDelimited).string(e.key), e.name !== "" && t.tag(2, W.LengthDelimited).string(e.name), e.folderName !== "" && t.tag(3, W.LengthDelimited).string(e.folderName), e.nestedFolderName !== "" && t.tag(4, W.LengthDelimited).string(e.nestedFolderName), e.url !== "" && t.tag(5, W.LengthDelimited).string(e.url), e.thumborUrl !== "" && t.tag(6, W.LengthDelimited).string(e.thumborUrl), e.proxyUrl !== "" && t.tag(7, W.LengthDelimited).string(e.proxyUrl), e.type !== 0 && t.tag(8, W.Varint).int32(e.type), e.metadata &&
|
|
3032
|
+
e.key !== "" && t.tag(1, W.LengthDelimited).string(e.key), e.name !== "" && t.tag(2, W.LengthDelimited).string(e.name), e.folderName !== "" && t.tag(3, W.LengthDelimited).string(e.folderName), e.nestedFolderName !== "" && t.tag(4, W.LengthDelimited).string(e.nestedFolderName), e.url !== "" && t.tag(5, W.LengthDelimited).string(e.url), e.thumborUrl !== "" && t.tag(6, W.LengthDelimited).string(e.thumborUrl), e.proxyUrl !== "" && t.tag(7, W.LengthDelimited).string(e.proxyUrl), e.type !== 0 && t.tag(8, W.Varint).int32(e.type), e.metadata && On.internalBinaryWrite(e.metadata, t.tag(9, W.LengthDelimited).fork(), n).join();
|
|
3033
3033
|
let r = n.writeUnknownFields;
|
|
3034
3034
|
return r !== !1 && (r == !0 ? G.onWrite : r)(this.typeName, e, t), t;
|
|
3035
3035
|
}
|
|
@@ -3109,7 +3109,7 @@ class Yi extends Fe {
|
|
|
3109
3109
|
return r !== !1 && (r == !0 ? G.onWrite : r)(this.typeName, e, t), t;
|
|
3110
3110
|
}
|
|
3111
3111
|
}
|
|
3112
|
-
const
|
|
3112
|
+
const On = new Yi();
|
|
3113
3113
|
class es extends Fe {
|
|
3114
3114
|
constructor() {
|
|
3115
3115
|
super("com.hamropatro.grpc.common.DeleteFileRequest", [
|
|
@@ -3257,7 +3257,7 @@ class rs extends Fe {
|
|
|
3257
3257
|
return r !== !1 && (r == !0 ? G.onWrite : r)(this.typeName, e, t), t;
|
|
3258
3258
|
}
|
|
3259
3259
|
}
|
|
3260
|
-
const
|
|
3260
|
+
const Pr = new rs();
|
|
3261
3261
|
class is extends Fe {
|
|
3262
3262
|
constructor() {
|
|
3263
3263
|
super("com.hamropatro.grpc.common.GetFilesByFolderResponse", [
|
|
@@ -3317,19 +3317,19 @@ class is extends Fe {
|
|
|
3317
3317
|
return r !== !1 && (r == !0 ? G.onWrite : r)(this.typeName, e, t), t;
|
|
3318
3318
|
}
|
|
3319
3319
|
}
|
|
3320
|
-
const ss = new is(),
|
|
3320
|
+
const ss = new is(), Sn = new Gn("com.hamropatro.grpc.common.FileService", [
|
|
3321
3321
|
{ name: "createFile", options: {}, I: Vr, O: nt },
|
|
3322
3322
|
{ name: "updateFile", options: {}, I: nt, O: nt },
|
|
3323
3323
|
{ name: "deleteFile", options: {}, I: Hr, O: ns },
|
|
3324
|
-
{ name: "getFilesByFolder", options: {}, I:
|
|
3324
|
+
{ name: "getFilesByFolder", options: {}, I: Pr, O: ss },
|
|
3325
3325
|
{ name: "createUserFile", options: {}, I: Jn, O: nt },
|
|
3326
3326
|
{ name: "search", options: {}, I: Mr, O: Xi }
|
|
3327
3327
|
]);
|
|
3328
|
-
class
|
|
3328
|
+
class Mt {
|
|
3329
3329
|
constructor(e) {
|
|
3330
|
-
he(this, "typeName",
|
|
3331
|
-
he(this, "methods",
|
|
3332
|
-
he(this, "options",
|
|
3330
|
+
he(this, "typeName", Sn.typeName);
|
|
3331
|
+
he(this, "methods", Sn.methods);
|
|
3332
|
+
he(this, "options", Sn.options);
|
|
3333
3333
|
this._transport = e;
|
|
3334
3334
|
}
|
|
3335
3335
|
/**
|
|
@@ -3380,7 +3380,7 @@ class Dt {
|
|
|
3380
3380
|
const os = async (s, e, t, n, r, i) => {
|
|
3381
3381
|
var o;
|
|
3382
3382
|
try {
|
|
3383
|
-
const a = (o = window.ImageSalonSDK) == null ? void 0 : o.grpcConfig, c = new
|
|
3383
|
+
const a = (o = window.ImageSalonSDK) == null ? void 0 : o.grpcConfig, c = new Mt(a), h = Vr.create();
|
|
3384
3384
|
return h.name = s, h.nestedFolderName = e, h.url = t, h.type = n, h.folderName = r, await c.createFile(
|
|
3385
3385
|
h,
|
|
3386
3386
|
i
|
|
@@ -3391,7 +3391,7 @@ const os = async (s, e, t, n, r, i) => {
|
|
|
3391
3391
|
}, as = async (s, e, t) => {
|
|
3392
3392
|
var n;
|
|
3393
3393
|
try {
|
|
3394
|
-
const r = (n = window.ImageSalonSDK) == null ? void 0 : n.grpcConfig, i = new
|
|
3394
|
+
const r = (n = window.ImageSalonSDK) == null ? void 0 : n.grpcConfig, i = new Mt(r), o = Jn.create();
|
|
3395
3395
|
return o.url = s, o.type = e, await i.createUserFile(
|
|
3396
3396
|
o,
|
|
3397
3397
|
t
|
|
@@ -3402,7 +3402,7 @@ const os = async (s, e, t, n, r, i) => {
|
|
|
3402
3402
|
}, ls = async (s, e, t) => {
|
|
3403
3403
|
var n, r;
|
|
3404
3404
|
try {
|
|
3405
|
-
const i = (n = window.ImageSalonSDK) == null ? void 0 : n.grpcConfig, o = (r = window.ImageSalonSDK) == null ? void 0 : r.mode, a = new
|
|
3405
|
+
const i = (n = window.ImageSalonSDK) == null ? void 0 : n.grpcConfig, o = (r = window.ImageSalonSDK) == null ? void 0 : r.mode, a = new Mt(i), c = Jn.create();
|
|
3406
3406
|
return c.url = s, c.type = e, await a.createUserFile(
|
|
3407
3407
|
c,
|
|
3408
3408
|
{
|
|
@@ -3418,7 +3418,7 @@ const os = async (s, e, t, n, r, i) => {
|
|
|
3418
3418
|
}, cs = async (s, e, t, n) => {
|
|
3419
3419
|
var r;
|
|
3420
3420
|
try {
|
|
3421
|
-
const i = (r = window.ImageSalonSDK) == null ? void 0 : r.grpcConfig, o = new
|
|
3421
|
+
const i = (r = window.ImageSalonSDK) == null ? void 0 : r.grpcConfig, o = new Mt(i), a = Pr.create();
|
|
3422
3422
|
return a.folderName = s, a.cursor = e, a.limit = t, await o.getFilesByFolder(
|
|
3423
3423
|
a,
|
|
3424
3424
|
n
|
|
@@ -3429,7 +3429,7 @@ const os = async (s, e, t, n, r, i) => {
|
|
|
3429
3429
|
}, ds = async (s, e, t = 20, n) => {
|
|
3430
3430
|
var r;
|
|
3431
3431
|
try {
|
|
3432
|
-
const i = (r = window.ImageSalonSDK) == null ? void 0 : r.grpcConfig, o = new
|
|
3432
|
+
const i = (r = window.ImageSalonSDK) == null ? void 0 : r.grpcConfig, o = new Mt(i), a = Mr.create();
|
|
3433
3433
|
return a.searchValue = s, a.cursor = e, a.limit = t, await o.search(
|
|
3434
3434
|
a,
|
|
3435
3435
|
n
|
|
@@ -3440,7 +3440,7 @@ const os = async (s, e, t, n, r, i) => {
|
|
|
3440
3440
|
}, hs = async (s, e, t, n, r, i, o, a, c) => {
|
|
3441
3441
|
var h;
|
|
3442
3442
|
try {
|
|
3443
|
-
const l = (h = window.ImageSalonSDK) == null ? void 0 : h.grpcConfig, u = new
|
|
3443
|
+
const l = (h = window.ImageSalonSDK) == null ? void 0 : h.grpcConfig, u = new Mt(l), d = nt.create();
|
|
3444
3444
|
return d.key = s, d.name = e, d.nestedFolderName = t, d.url = n, d.thumborUrl = r, d.proxyUrl = i, d.type = o, d.folderName = a, await u.updateFile(
|
|
3445
3445
|
d,
|
|
3446
3446
|
c
|
|
@@ -3451,7 +3451,7 @@ const os = async (s, e, t, n, r, i) => {
|
|
|
3451
3451
|
}, us = async (s, e) => {
|
|
3452
3452
|
var t;
|
|
3453
3453
|
try {
|
|
3454
|
-
const n = (t = window.ImageSalonSDK) == null ? void 0 : t.grpcConfig, r = new
|
|
3454
|
+
const n = (t = window.ImageSalonSDK) == null ? void 0 : t.grpcConfig, r = new Mt(n), i = Hr.create();
|
|
3455
3455
|
return i.key = s, await r.deleteFile(
|
|
3456
3456
|
i,
|
|
3457
3457
|
e
|
|
@@ -3501,7 +3501,7 @@ class fs extends Fe {
|
|
|
3501
3501
|
return r !== !1 && (r == !0 ? G.onWrite : r)(this.typeName, e, t), t;
|
|
3502
3502
|
}
|
|
3503
3503
|
}
|
|
3504
|
-
const
|
|
3504
|
+
const $r = new fs();
|
|
3505
3505
|
class ps extends Fe {
|
|
3506
3506
|
constructor() {
|
|
3507
3507
|
super("com.hamropatro.grpc.common.CreateFolderRequest", [
|
|
@@ -3629,7 +3629,7 @@ class ms extends Fe {
|
|
|
3629
3629
|
return r !== !1 && (r == !0 ? G.onWrite : r)(this.typeName, e, t), t;
|
|
3630
3630
|
}
|
|
3631
3631
|
}
|
|
3632
|
-
const
|
|
3632
|
+
const Kn = new ms();
|
|
3633
3633
|
class gs extends Fe {
|
|
3634
3634
|
constructor() {
|
|
3635
3635
|
super("com.hamropatro.grpc.common.GetAllFoldersResponse", [
|
|
@@ -3845,20 +3845,20 @@ class bs extends Fe {
|
|
|
3845
3845
|
return r !== !1 && (r == !0 ? G.onWrite : r)(this.typeName, e, t), t;
|
|
3846
3846
|
}
|
|
3847
3847
|
}
|
|
3848
|
-
const Cs = new bs(),
|
|
3848
|
+
const Cs = new bs(), Rn = new Gn("com.hamropatro.grpc.common.FolderService", [
|
|
3849
3849
|
{ name: "createFolder", options: {}, I: Wr, O: Ct },
|
|
3850
|
-
{ name: "getFolders", options: {}, I:
|
|
3851
|
-
{ name: "getUserFolders", options: {}, I:
|
|
3850
|
+
{ name: "getFolders", options: {}, I: Kn, O: mr },
|
|
3851
|
+
{ name: "getUserFolders", options: {}, I: Kn, O: mr },
|
|
3852
3852
|
{ name: "updateFolder", options: {}, I: Ct, O: Ct },
|
|
3853
|
-
{ name: "deleteFolder", options: {}, I:
|
|
3853
|
+
{ name: "deleteFolder", options: {}, I: $r, O: Ct },
|
|
3854
3854
|
{ name: "ChangeNestedFolderName", options: {}, I: Cs, O: Ct },
|
|
3855
3855
|
{ name: "setBooleanForUserFolder", options: {}, I: gr, O: gr }
|
|
3856
3856
|
]);
|
|
3857
|
-
class
|
|
3857
|
+
class xn {
|
|
3858
3858
|
constructor(e) {
|
|
3859
|
-
he(this, "typeName",
|
|
3860
|
-
he(this, "methods",
|
|
3861
|
-
he(this, "options",
|
|
3859
|
+
he(this, "typeName", Rn.typeName);
|
|
3860
|
+
he(this, "methods", Rn.methods);
|
|
3861
|
+
he(this, "options", Rn.options);
|
|
3862
3862
|
this._transport = e;
|
|
3863
3863
|
}
|
|
3864
3864
|
/**
|
|
@@ -3915,7 +3915,7 @@ class Un {
|
|
|
3915
3915
|
}
|
|
3916
3916
|
const Es = async (s, e = 20, t) => {
|
|
3917
3917
|
var o;
|
|
3918
|
-
const n = (o = window.ImageSalonSDK) == null ? void 0 : o.grpcConfig, r = new
|
|
3918
|
+
const n = (o = window.ImageSalonSDK) == null ? void 0 : o.grpcConfig, r = new xn(n), i = Kn.create();
|
|
3919
3919
|
try {
|
|
3920
3920
|
return i.cursor = s, i.limit = e, await r.getFolders(
|
|
3921
3921
|
i,
|
|
@@ -3927,7 +3927,7 @@ const Es = async (s, e = 20, t) => {
|
|
|
3927
3927
|
}, vs = async (s, e, t, n, r) => {
|
|
3928
3928
|
var i;
|
|
3929
3929
|
try {
|
|
3930
|
-
const o = (i = window.ImageSalonSDK) == null ? void 0 : i.grpcConfig, a = new
|
|
3930
|
+
const o = (i = window.ImageSalonSDK) == null ? void 0 : i.grpcConfig, a = new xn(o), c = Wr.create();
|
|
3931
3931
|
return c.name = s, c.nestedFolderName = e, c.createdBy = t, c.forUser = n, await a.createFolder(
|
|
3932
3932
|
c,
|
|
3933
3933
|
r
|
|
@@ -3938,7 +3938,7 @@ const Es = async (s, e = 20, t) => {
|
|
|
3938
3938
|
}, As = async (s, e, t, n, r) => {
|
|
3939
3939
|
var i;
|
|
3940
3940
|
try {
|
|
3941
|
-
const o = (i = window.ImageSalonSDK) == null ? void 0 : i.grpcConfig, a = new
|
|
3941
|
+
const o = (i = window.ImageSalonSDK) == null ? void 0 : i.grpcConfig, a = new xn(o), c = Ct.create();
|
|
3942
3942
|
return c.name = e, c.key = s, c.nestedFolderName = t, c.createdBy = n, await a.updateFolder(
|
|
3943
3943
|
c,
|
|
3944
3944
|
r
|
|
@@ -3949,7 +3949,7 @@ const Es = async (s, e = 20, t) => {
|
|
|
3949
3949
|
}, ks = async (s, e) => {
|
|
3950
3950
|
var t;
|
|
3951
3951
|
try {
|
|
3952
|
-
const n = (t = window.ImageSalonSDK) == null ? void 0 : t.grpcConfig, r = new
|
|
3952
|
+
const n = (t = window.ImageSalonSDK) == null ? void 0 : t.grpcConfig, r = new xn(n), i = $r.create();
|
|
3953
3953
|
return i.key = s, await r.deleteFolder(
|
|
3954
3954
|
i,
|
|
3955
3955
|
e
|
|
@@ -3957,7 +3957,7 @@ const Es = async (s, e = 20, t) => {
|
|
|
3957
3957
|
} catch (n) {
|
|
3958
3958
|
throw n;
|
|
3959
3959
|
}
|
|
3960
|
-
},
|
|
3960
|
+
}, Dn = (s, e, t) => {
|
|
3961
3961
|
const n = document.createElementNS("http://www.w3.org/2000/svg", "svg");
|
|
3962
3962
|
n.setAttribute("xmlns", "http://www.w3.org/2000/svg"), n.setAttribute("width", s || "20"), n.setAttribute("height", e || "20"), n.setAttribute("viewBox", "0 0 24 24"), n.setAttribute("fill", "none"), n.setAttribute("stroke", t || "#ee3f3f"), n.setAttribute("stroke-width", "2"), n.setAttribute("stroke-linecap", "round"), n.setAttribute("stroke-linejoin", "round"), n.classList.add("lucide", "lucide-circle-alert");
|
|
3963
3963
|
const r = document.createElementNS(
|
|
@@ -3970,7 +3970,7 @@ const Es = async (s, e = 20, t) => {
|
|
|
3970
3970
|
const o = document.createElementNS("http://www.w3.org/2000/svg", "line");
|
|
3971
3971
|
return o.setAttribute("x1", "12"), o.setAttribute("x2", "12.01"), o.setAttribute("y1", "16"), o.setAttribute("y2", "16"), n.appendChild(r), n.appendChild(i), n.appendChild(o), n;
|
|
3972
3972
|
};
|
|
3973
|
-
function
|
|
3973
|
+
function mn(s = "24px", e = "24px", t = "#333") {
|
|
3974
3974
|
const n = document.createElementNS(
|
|
3975
3975
|
"http://www.w3.org/2000/svg",
|
|
3976
3976
|
"svg"
|
|
@@ -4011,7 +4011,7 @@ const wr = (s) => {
|
|
|
4011
4011
|
const n = document.createElementNS("http://www.w3.org/2000/svg", "path");
|
|
4012
4012
|
return n.setAttribute("d", "m9 11 3 3L22 4"), e.appendChild(t), e.appendChild(n), e;
|
|
4013
4013
|
};
|
|
4014
|
-
function
|
|
4014
|
+
function zn(s = "#333") {
|
|
4015
4015
|
const e = document.createElementNS("http://www.w3.org/2000/svg", "svg");
|
|
4016
4016
|
e.setAttribute("xmlns", "http://www.w3.org/2000/svg"), e.setAttribute("x", "0px"), e.setAttribute("y", "0px"), e.setAttribute("width", "18"), e.setAttribute("height", "18"), e.setAttribute("viewBox", "0 0 50 50"), e.setAttribute("fill", s);
|
|
4017
4017
|
const t = document.createElementNS("http://www.w3.org/2000/svg", "path");
|
|
@@ -4031,7 +4031,7 @@ function yr() {
|
|
|
4031
4031
|
const t = document.createElementNS("http://www.w3.org/2000/svg", "path");
|
|
4032
4032
|
return t.setAttribute("d", "m15 5 4 4"), s.appendChild(e), s.appendChild(t), document.body.appendChild(s), s;
|
|
4033
4033
|
}
|
|
4034
|
-
function
|
|
4034
|
+
function en() {
|
|
4035
4035
|
const s = document.createElementNS("http://www.w3.org/2000/svg", "svg");
|
|
4036
4036
|
s.setAttribute("xmlns", "http://www.w3.org/2000/folder"), s.setAttribute("x", "0px"), s.setAttribute("y", "0px"), s.setAttribute("width", "24"), s.setAttribute("height", "24"), s.setAttribute("viewBox", "0 0 48 48");
|
|
4037
4037
|
const e = document.createElementNS("http://www.w3.org/2000/svg", "path");
|
|
@@ -4107,7 +4107,7 @@ function Cr() {
|
|
|
4107
4107
|
const i = document.createElementNS("http://www.w3.org/2000/svg", "line");
|
|
4108
4108
|
return i.setAttribute("x1", "14"), i.setAttribute("x2", "14"), i.setAttribute("y1", "11"), i.setAttribute("y2", "17"), s.appendChild(e), s.appendChild(t), s.appendChild(n), s.appendChild(r), s.appendChild(i), document.body.appendChild(s), s;
|
|
4109
4109
|
}
|
|
4110
|
-
function
|
|
4110
|
+
function Mn() {
|
|
4111
4111
|
const s = document.createElementNS("http://www.w3.org/2000/svg", "svg");
|
|
4112
4112
|
s.setAttribute("xmlns", "http://www.w3.org/2000/svg"), s.setAttribute("width", "24"), s.setAttribute("height", "24"), s.setAttribute("viewBox", "0 0 24 24"), s.setAttribute("fill", "none"), s.setAttribute("stroke", "currentColor"), s.setAttribute("stroke-width", "2"), s.setAttribute("stroke-linecap", "round"), s.setAttribute("stroke-linejoin", "round"), s.classList.add("lucide", "lucide-upload");
|
|
4113
4113
|
const e = document.createElementNS("http://www.w3.org/2000/svg", "path");
|
|
@@ -4135,30 +4135,30 @@ function Q(s, e, t, n, r) {
|
|
|
4135
4135
|
let i = document.createElement(s);
|
|
4136
4136
|
return e && (i.className += e), t && (i.style.cssText = t), n && (i.textContent = n), r && r.appendChild(i), i;
|
|
4137
4137
|
}
|
|
4138
|
-
var pt, Ge,
|
|
4138
|
+
var pt, Ge, Wt;
|
|
4139
4139
|
class xs {
|
|
4140
4140
|
constructor() {
|
|
4141
4141
|
z(this, pt);
|
|
4142
4142
|
z(this, Ge);
|
|
4143
4143
|
// Store the circle element as a private property
|
|
4144
|
-
z(this,
|
|
4144
|
+
z(this, Wt, "#fff");
|
|
4145
4145
|
H(this, pt, document.createElementNS(
|
|
4146
4146
|
"http://www.w3.org/2000/svg",
|
|
4147
4147
|
"svg"
|
|
4148
4148
|
)), E(this, pt).setAttribute("viewBox", "25 25 50 50"), E(this, pt).classList.add("loader-svg"), H(this, Ge, document.createElementNS(
|
|
4149
4149
|
"http://www.w3.org/2000/svg",
|
|
4150
4150
|
"circle"
|
|
4151
|
-
)), E(this, Ge).setAttribute("r", "20"), E(this, Ge).setAttribute("cy", "50"), E(this, Ge).setAttribute("cx", "50"), E(this, Ge).setAttribute("stroke", E(this,
|
|
4151
|
+
)), E(this, Ge).setAttribute("r", "20"), E(this, Ge).setAttribute("cy", "50"), E(this, Ge).setAttribute("cx", "50"), E(this, Ge).setAttribute("stroke", E(this, Wt)), E(this, Ge).classList.add("loader-circle"), E(this, pt).appendChild(E(this, Ge));
|
|
4152
4152
|
}
|
|
4153
4153
|
show(e, t) {
|
|
4154
|
-
t && (H(this,
|
|
4154
|
+
t && (H(this, Wt, t), E(this, Ge).setAttribute("stroke", E(this, Wt))), e.appendChild(E(this, pt));
|
|
4155
4155
|
}
|
|
4156
4156
|
hide() {
|
|
4157
4157
|
E(this, pt).remove();
|
|
4158
4158
|
}
|
|
4159
4159
|
}
|
|
4160
|
-
pt = new WeakMap(), Ge = new WeakMap(),
|
|
4161
|
-
const Er = new xs(),
|
|
4160
|
+
pt = new WeakMap(), Ge = new WeakMap(), Wt = new WeakMap();
|
|
4161
|
+
const Er = new xs(), gn = document.body;
|
|
4162
4162
|
class jr {
|
|
4163
4163
|
constructor() {
|
|
4164
4164
|
he(this, "main");
|
|
@@ -4181,7 +4181,7 @@ class jr {
|
|
|
4181
4181
|
"dialog-presentation",
|
|
4182
4182
|
"",
|
|
4183
4183
|
"",
|
|
4184
|
-
|
|
4184
|
+
gn
|
|
4185
4185
|
), this.main.setAttribute("role", "presentation"), this.dialogContainer = Q(
|
|
4186
4186
|
"div",
|
|
4187
4187
|
"dialog-container",
|
|
@@ -4222,9 +4222,9 @@ class jr {
|
|
|
4222
4222
|
"",
|
|
4223
4223
|
this.dialogContent
|
|
4224
4224
|
);
|
|
4225
|
-
n.appendChild(
|
|
4225
|
+
n.appendChild(zn()), n.onclick = () => this.hide();
|
|
4226
4226
|
}
|
|
4227
|
-
return e.header && this._setHeader(e), this._setBody(e), this._setFooter(e), this.confirmButton.textContent = e.confirmButtonText || "Upload", this.cancelButton.textContent = e.cancelButtonText || "Cancel",
|
|
4227
|
+
return e.header && this._setHeader(e), this._setBody(e), this._setFooter(e), this.confirmButton.textContent = e.confirmButtonText || "Upload", this.cancelButton.textContent = e.cancelButtonText || "Cancel", gn.style.overflow = "hidden", this.confirmButton.textContent = e.confirmButtonText || "Upload", this.cancelButton.textContent = e.cancelButtonText || "Cancel", gn.classList.add("dialog-visible"), new Promise((n) => {
|
|
4228
4228
|
const r = (i) => () => {
|
|
4229
4229
|
this.hide(), n(i === "confirm");
|
|
4230
4230
|
};
|
|
@@ -4276,7 +4276,7 @@ class jr {
|
|
|
4276
4276
|
}, 150);
|
|
4277
4277
|
}
|
|
4278
4278
|
hide() {
|
|
4279
|
-
this.main ||
|
|
4279
|
+
this.main || gn.style.removeProperty("overflow"), this.dialog.style.transform = "scale(0.8)", this.dialog.style.transition = "transform 150ms ease-out", this.dialogBackdrop.style.opacity = "0", setTimeout(() => {
|
|
4280
4280
|
this.dialogContainer.style.opacity = "0", this.dialog.style.opacity = "0", this.dialogContent.style.opacity = "0", this.main.remove();
|
|
4281
4281
|
}, 150);
|
|
4282
4282
|
}
|
|
@@ -4284,7 +4284,7 @@ class jr {
|
|
|
4284
4284
|
e ? (Er.show(this.confirmButton), this.confirmButton.disabled = !0) : (Er.hide(), this.confirmButton.disabled = !1);
|
|
4285
4285
|
}
|
|
4286
4286
|
}
|
|
4287
|
-
const
|
|
4287
|
+
const wn = new jr(), Ce = new jr();
|
|
4288
4288
|
class _s {
|
|
4289
4289
|
constructor() {
|
|
4290
4290
|
he(this, "main");
|
|
@@ -4300,23 +4300,23 @@ class _s {
|
|
|
4300
4300
|
}
|
|
4301
4301
|
const ze = new _s();
|
|
4302
4302
|
var Ye = /* @__PURE__ */ ((s) => (s[s.IMAGE = 0] = "IMAGE", s[s.AUDIO = 1] = "AUDIO", s[s.VIDEO = 2] = "VIDEO", s[s.ALL = 3] = "ALL", s[s.FOLDER = 4] = "FOLDER", s))(Ye || {});
|
|
4303
|
-
const
|
|
4303
|
+
const nn = {
|
|
4304
4304
|
0: "IMAGE",
|
|
4305
4305
|
1: "AUDIO",
|
|
4306
4306
|
2: "VIDEO",
|
|
4307
4307
|
3: "ALL",
|
|
4308
4308
|
4: "FOLDER"
|
|
4309
4309
|
};
|
|
4310
|
-
function
|
|
4310
|
+
function Vn(s) {
|
|
4311
4311
|
switch (s) {
|
|
4312
4312
|
case "image":
|
|
4313
|
-
return
|
|
4313
|
+
return nn[Ye.IMAGE];
|
|
4314
4314
|
case "video":
|
|
4315
|
-
return
|
|
4315
|
+
return nn[Ye.VIDEO];
|
|
4316
4316
|
case "audio":
|
|
4317
|
-
return
|
|
4317
|
+
return nn[Ye.AUDIO];
|
|
4318
4318
|
default:
|
|
4319
|
-
return
|
|
4319
|
+
return nn[Ye.ALL];
|
|
4320
4320
|
}
|
|
4321
4321
|
}
|
|
4322
4322
|
function Bs(s) {
|
|
@@ -4365,7 +4365,7 @@ function K(s, e) {
|
|
|
4365
4365
|
const t = document.createElement("div");
|
|
4366
4366
|
return s && (t.className = s), e && (t.id = e), t;
|
|
4367
4367
|
}
|
|
4368
|
-
function
|
|
4368
|
+
function tn(s, e, t) {
|
|
4369
4369
|
const n = document.createElement("p");
|
|
4370
4370
|
return e && (n.className = e), t && (n.id = t), s && (n.textContent = s), n;
|
|
4371
4371
|
}
|
|
@@ -4389,7 +4389,7 @@ function He(s, e, t, n, r) {
|
|
|
4389
4389
|
const i = document.createElement("button");
|
|
4390
4390
|
return e && (i.className = e), t && (i.id = t), s && (i.textContent = s), r && (i.innerHTML = r), i.disabled = n, i;
|
|
4391
4391
|
}
|
|
4392
|
-
function
|
|
4392
|
+
function Hn(s, e, t) {
|
|
4393
4393
|
const n = document.createElement("input");
|
|
4394
4394
|
return n.className = e, n.defaultValue = t, s && (n.type = s), n;
|
|
4395
4395
|
}
|
|
@@ -4456,10 +4456,10 @@ const Vs = (s) => new Promise((e, t) => {
|
|
|
4456
4456
|
return e(new Blob());
|
|
4457
4457
|
}), n.readAsArrayBuffer(s);
|
|
4458
4458
|
});
|
|
4459
|
-
var
|
|
4460
|
-
return
|
|
4459
|
+
var An = {}, Hs = { get exports() {
|
|
4460
|
+
return An;
|
|
4461
4461
|
}, set exports(s) {
|
|
4462
|
-
|
|
4462
|
+
An = s;
|
|
4463
4463
|
} };
|
|
4464
4464
|
(function(s) {
|
|
4465
4465
|
var e, t, n = {};
|
|
@@ -4679,8 +4679,8 @@ var vn = {}, Hs = { get exports() {
|
|
|
4679
4679
|
for (var p = h, M = 0; M < o; M += 2) {
|
|
4680
4680
|
for (var x = i[M], V = x >>> 23, Z = p + (8388607 & x); p < Z; ) d = n.F._writeLit(c[p++], A, u, d);
|
|
4681
4681
|
if (V != 0) {
|
|
4682
|
-
var
|
|
4683
|
-
m(u, d = n.F._writeLit(257 +
|
|
4682
|
+
var $ = i[M + 1], q = $ >> 16, P = $ >> 8 & 255, S = 255 & $;
|
|
4683
|
+
m(u, d = n.F._writeLit(257 + P, A, u, d), V - b.of0[P]), d += b.exb[P], B(u, d = n.F._writeLit(S, _, u, d), q - b.df0[S]), d += b.dxb[S], p += V;
|
|
4684
4684
|
}
|
|
4685
4685
|
}
|
|
4686
4686
|
d = n.F._writeLit(256, A, u, d);
|
|
@@ -4796,15 +4796,15 @@ var vn = {}, Hs = { get exports() {
|
|
|
4796
4796
|
}
|
|
4797
4797
|
var V = C[f(r, k) & m];
|
|
4798
4798
|
k += 15 & V;
|
|
4799
|
-
var Z = V >>> 4,
|
|
4800
|
-
for (k += 15 &
|
|
4799
|
+
var Z = V >>> 4, $ = y.ddef[Z], q = ($ >>> 4) + c(r, k, 15 & $);
|
|
4800
|
+
for (k += 15 & $, F && (i = n.F._check(i, g + (1 << 17))); g < M; ) i[g] = i[g++ - q], i[g] = i[g++ - q], i[g] = i[g++ - q], i[g] = i[g++ - q];
|
|
4801
4801
|
g = M;
|
|
4802
4802
|
}
|
|
4803
4803
|
}
|
|
4804
4804
|
} else {
|
|
4805
4805
|
7 & k && (k += 8 - (7 & k));
|
|
4806
|
-
var
|
|
4807
|
-
F && (i = n.F._check(i, g + S)), i.set(new o(r.buffer, r.byteOffset +
|
|
4806
|
+
var P = 4 + (k >>> 3), S = r[P - 4] | r[P - 3] << 8;
|
|
4807
|
+
F && (i = n.F._check(i, g + S)), i.set(new o(r.buffer, r.byteOffset + P, S), g), k = P + S << 3, g += S;
|
|
4808
4808
|
}
|
|
4809
4809
|
return i.length == g ? i : i.slice(0, g);
|
|
4810
4810
|
}, n.F._check = function(r, i) {
|
|
@@ -4874,7 +4874,7 @@ var vn = {}, Hs = { get exports() {
|
|
|
4874
4874
|
a(r.fltree, 144, 8), a(r.fltree, 112, 9), a(r.fltree, 24, 7), a(r.fltree, 8, 8), n.F.makeCodes(r.fltree, 9), n.F.codes2map(r.fltree, 9, r.flmap), n.F.revCodes(r.fltree, 9), a(r.fdtree, 32, 5), n.F.makeCodes(r.fdtree, 5), n.F.codes2map(r.fdtree, 5, r.fdmap), n.F.revCodes(r.fdtree, 5), a(r.itree, 19, 0), a(r.ltree, 286, 0), a(r.dtree, 30, 0), a(r.ttree, 320, 0);
|
|
4875
4875
|
}();
|
|
4876
4876
|
})();
|
|
4877
|
-
var
|
|
4877
|
+
var Ps = Ms({ __proto__: null, default: An }, [An]);
|
|
4878
4878
|
const Xe = function() {
|
|
4879
4879
|
var s = { nextZero(l, u) {
|
|
4880
4880
|
for (; l[u] != 0; ) u++;
|
|
@@ -4984,13 +4984,13 @@ const Xe = function() {
|
|
|
4984
4984
|
const p = U[_], M = A[_];
|
|
4985
4985
|
let x = 0, V = 0, Z = T[_];
|
|
4986
4986
|
for (; Z < L; ) Z += p, V++;
|
|
4987
|
-
let
|
|
4988
|
-
for (;
|
|
4987
|
+
let $ = N[_];
|
|
4988
|
+
for (; $ < v; ) $ += M, x++;
|
|
4989
4989
|
const q = Math.ceil(x * b / 8);
|
|
4990
4990
|
o(R, O, k, x, V);
|
|
4991
|
-
let
|
|
4991
|
+
let P = 0, S = T[_];
|
|
4992
4992
|
for (; S < L; ) {
|
|
4993
|
-
let X = N[_], oe = k +
|
|
4993
|
+
let X = N[_], oe = k + P * q << 3;
|
|
4994
4994
|
for (; X < v; ) {
|
|
4995
4995
|
var w;
|
|
4996
4996
|
if (b == 1 && (w = (w = R[oe >> 3]) >> 7 - (7 & oe) & 1, g[S * m + (X >> 3)] |= w << 7 - ((7 & X) << 0)), b == 2 && (w = (w = R[oe >> 3]) >> 6 - (7 & oe) & 3, g[S * m + (X >> 2)] |= w << 6 - ((3 & X) << 1)), b == 4 && (w = (w = R[oe >> 3]) >> 4 - (7 & oe) & 15, g[S * m + (X >> 1)] |= w << 4 - ((1 & X) << 2)), b >= 8) {
|
|
@@ -4999,7 +4999,7 @@ const Xe = function() {
|
|
|
4999
4999
|
}
|
|
5000
5000
|
oe += b, X += M;
|
|
5001
5001
|
}
|
|
5002
|
-
|
|
5002
|
+
P++, S += p;
|
|
5003
5003
|
}
|
|
5004
5004
|
x * V != 0 && (k += V * (1 + q)), _ += 1;
|
|
5005
5005
|
}
|
|
@@ -5022,8 +5022,8 @@ const Xe = function() {
|
|
|
5022
5022
|
let x = 1;
|
|
5023
5023
|
for (var M = 0; M < 38; M += 2) w.Q[M] = 0, w.Q[M + 1] = 0;
|
|
5024
5024
|
for (M = 0; M < v; M++) {
|
|
5025
|
-
const
|
|
5026
|
-
w.Q[1 + (w.X[M] << 1)] =
|
|
5025
|
+
const $ = T(u, m + 3 * M, 3);
|
|
5026
|
+
w.Q[1 + (w.X[M] << 1)] = $, $ > x && (x = $);
|
|
5027
5027
|
}
|
|
5028
5028
|
m += 3 * v, U(w.Q, x), A(w.Q, x, w.u), y = w.w, F = w.d, m = N(w.u, (1 << x) - 1, R + O, u, m, w.v);
|
|
5029
5029
|
const V = g.V(w.v, 0, R, w.C);
|
|
@@ -5044,10 +5044,10 @@ const Xe = function() {
|
|
|
5044
5044
|
const X = w.q[V - 257];
|
|
5045
5045
|
Z = B + (X >>> 3) + T(u, m, 7 & X), m += 7 & X;
|
|
5046
5046
|
}
|
|
5047
|
-
const
|
|
5048
|
-
m += 15 &
|
|
5049
|
-
const q =
|
|
5050
|
-
for (m += 15 &
|
|
5047
|
+
const $ = F[_(u, m) & b];
|
|
5048
|
+
m += 15 & $;
|
|
5049
|
+
const q = $ >>> 4, P = w.c[q], S = (P >>> 4) + k(u, m, 15 & P);
|
|
5050
|
+
for (m += 15 & P; B < Z; ) d[B] = d[B++ - S], d[B] = d[B++ - S], d[B] = d[B++ - S], d[B] = d[B++ - S];
|
|
5051
5051
|
B = Z;
|
|
5052
5052
|
}
|
|
5053
5053
|
}
|
|
@@ -5314,18 +5314,18 @@ const Xe = function() {
|
|
|
5314
5314
|
x != p && V < S && (S = V, M = x);
|
|
5315
5315
|
}
|
|
5316
5316
|
}
|
|
5317
|
-
const Z = new Uint32Array(N.buffer),
|
|
5317
|
+
const Z = new Uint32Array(N.buffer), $ = new Int16Array(g * k * 4), q = [0, 8, 2, 10, 12, 4, 14, 6, 3, 11, 1, 9, 15, 7, 13, 5];
|
|
5318
5318
|
for (p = 0; p < q.length; p++) q[p] = 255 * ((q[p] + 0.5) / 16 - 0.5);
|
|
5319
5319
|
for (let S = 0; S < k; S++) for (let X = 0; X < g; X++) {
|
|
5320
|
-
var
|
|
5321
|
-
p = 4 * (S * g + X), A != 2 ?
|
|
5320
|
+
var P;
|
|
5321
|
+
p = 4 * (S * g + X), A != 2 ? P = [i(m[p] + $[p]), i(m[p + 1] + $[p + 1]), i(m[p + 2] + $[p + 2]), i(m[p + 3] + $[p + 3])] : (V = q[4 * (3 & S) + (3 & X)], P = [i(m[p] + V), i(m[p + 1] + V), i(m[p + 2] + V), i(m[p + 3] + V)]), M = 0;
|
|
5322
5322
|
let oe = 16777215;
|
|
5323
5323
|
for (x = 0; x < _; x++) {
|
|
5324
|
-
const re = o(
|
|
5324
|
+
const re = o(P, w[x]);
|
|
5325
5325
|
re < oe && (oe = re, M = x);
|
|
5326
5326
|
}
|
|
5327
|
-
const te = w[M], Y = [
|
|
5328
|
-
A == 1 && (X != g - 1 && r(Y,
|
|
5327
|
+
const te = w[M], Y = [P[0] - te[0], P[1] - te[1], P[2] - te[2], P[3] - te[3]];
|
|
5328
|
+
A == 1 && (X != g - 1 && r(Y, $, p + 4, 7), S != k - 1 && (X != 0 && r(Y, $, p + 4 * g - 4, 3), r(Y, $, p + 4 * g, 5), X != g - 1 && r(Y, $, p + 4 * g + 4, 1))), U[p >> 2] = M, Z[p >> 2] = T[M];
|
|
5329
5329
|
}
|
|
5330
5330
|
}
|
|
5331
5331
|
function c(m, g, k, T, N) {
|
|
@@ -5335,11 +5335,11 @@ const Xe = function() {
|
|
|
5335
5335
|
const M = m.frames.length > 1;
|
|
5336
5336
|
let x, V = !1, Z = 33 + (M ? 20 : 0);
|
|
5337
5337
|
if (N.sRGB != null && (Z += 13), N.pHYs != null && (Z += 21), N.iCCP != null && (x = pako.deflate(N.iCCP), Z += 21 + x.length + 4), m.ctype == 3) {
|
|
5338
|
-
for (var
|
|
5339
|
-
Z += 8 + 3 *
|
|
5338
|
+
for (var $ = m.plte.length, q = 0; q < $; q++) m.plte[q] >>> 24 != 255 && (V = !0);
|
|
5339
|
+
Z += 8 + 3 * $ + 4 + (V ? 8 + 1 * $ + 4 : 0);
|
|
5340
5340
|
}
|
|
5341
|
-
for (var
|
|
5342
|
-
M && (Z += 38), Z += (te = m.frames[
|
|
5341
|
+
for (var P = 0; P < m.frames.length; P++)
|
|
5342
|
+
M && (Z += 38), Z += (te = m.frames[P]).cimg.length + 12, P != 0 && (Z += 4);
|
|
5343
5343
|
Z += 12;
|
|
5344
5344
|
const S = new Uint8Array(Z), X = [137, 80, 78, 71, 13, 10, 26, 10];
|
|
5345
5345
|
for (q = 0; q < 8; q++) S[q] = X[q];
|
|
@@ -5348,23 +5348,23 @@ const Xe = function() {
|
|
|
5348
5348
|
A(S, p, Y), p += 4, w(S, p, "iCCP"), p += 4, w(S, p, "ICC profile"), p += 11, p += 2, S.set(x, p), p += x.length, A(S, p, U(S, p - (Y + 4), Y + 4)), p += 4;
|
|
5349
5349
|
}
|
|
5350
5350
|
if (N.pHYs != null && (A(S, p, 9), p += 4, w(S, p, "pHYs"), p += 4, A(S, p, N.pHYs[0]), p += 4, A(S, p, N.pHYs[1]), p += 4, S[p] = N.pHYs[2], p++, A(S, p, U(S, p - 13, 13)), p += 4), M && (A(S, p, 8), p += 4, w(S, p, "acTL"), p += 4, A(S, p, m.frames.length), p += 4, A(S, p, N.loop != null ? N.loop : 0), p += 4, A(S, p, U(S, p - 12, 12)), p += 4), m.ctype == 3) {
|
|
5351
|
-
for (A(S, p, 3 * (
|
|
5351
|
+
for (A(S, p, 3 * ($ = m.plte.length)), p += 4, w(S, p, "PLTE"), p += 4, q = 0; q < $; q++) {
|
|
5352
5352
|
const Y = 3 * q, re = m.plte[q], fe = 255 & re, be = re >>> 8 & 255, ft = re >>> 16 & 255;
|
|
5353
5353
|
S[p + Y + 0] = fe, S[p + Y + 1] = be, S[p + Y + 2] = ft;
|
|
5354
5354
|
}
|
|
5355
|
-
if (p += 3 *
|
|
5356
|
-
for (A(S, p,
|
|
5357
|
-
p +=
|
|
5355
|
+
if (p += 3 * $, A(S, p, U(S, p - 3 * $ - 4, 3 * $ + 4)), p += 4, V) {
|
|
5356
|
+
for (A(S, p, $), p += 4, w(S, p, "tRNS"), p += 4, q = 0; q < $; q++) S[p + q] = m.plte[q] >>> 24 & 255;
|
|
5357
|
+
p += $, A(S, p, U(S, p - $ - 4, $ + 4)), p += 4;
|
|
5358
5358
|
}
|
|
5359
5359
|
}
|
|
5360
5360
|
let oe = 0;
|
|
5361
|
-
for (
|
|
5362
|
-
var te = m.frames[
|
|
5363
|
-
M && (A(S, p, 26), p += 4, w(S, p, "fcTL"), p += 4, A(S, p, oe++), p += 4, A(S, p, te.rect.width), p += 4, A(S, p, te.rect.height), p += 4, A(S, p, te.rect.x), p += 4, A(S, p, te.rect.y), p += 4, _(S, p, T[
|
|
5361
|
+
for (P = 0; P < m.frames.length; P++) {
|
|
5362
|
+
var te = m.frames[P];
|
|
5363
|
+
M && (A(S, p, 26), p += 4, w(S, p, "fcTL"), p += 4, A(S, p, oe++), p += 4, A(S, p, te.rect.width), p += 4, A(S, p, te.rect.height), p += 4, A(S, p, te.rect.x), p += 4, A(S, p, te.rect.y), p += 4, _(S, p, T[P]), p += 2, _(S, p, 1e3), p += 2, S[p] = te.dispose, p++, S[p] = te.blend, p++, A(S, p, U(S, p - 30, 30)), p += 4);
|
|
5364
5364
|
const Y = te.cimg;
|
|
5365
|
-
A(S, p, (
|
|
5365
|
+
A(S, p, ($ = Y.length) + (P == 0 ? 0 : 4)), p += 4;
|
|
5366
5366
|
const re = p;
|
|
5367
|
-
w(S, p,
|
|
5367
|
+
w(S, p, P == 0 ? "IDAT" : "fdAT"), p += 4, P != 0 && (A(S, p, oe++), p += 4), S.set(Y, p), p += $, A(S, p, U(S, re, p - re)), p += 4;
|
|
5368
5368
|
}
|
|
5369
5369
|
return A(S, p, 0), p += 4, w(S, p, "IEND"), p += 4, A(S, p, U(S, p - 4, 4)), p += 4, S.buffer;
|
|
5370
5370
|
}
|
|
@@ -5379,32 +5379,32 @@ const Xe = function() {
|
|
|
5379
5379
|
function l(m, g, k, T, N) {
|
|
5380
5380
|
const U = N[0], A = N[1], _ = N[2], w = N[3], p = N[4], M = N[5];
|
|
5381
5381
|
let x = 6, V = 8, Z = 255;
|
|
5382
|
-
for (var
|
|
5383
|
-
const Ne = new Uint8Array(m[
|
|
5384
|
-
for (var q = Ne.length,
|
|
5382
|
+
for (var $ = 0; $ < m.length; $++) {
|
|
5383
|
+
const Ne = new Uint8Array(m[$]);
|
|
5384
|
+
for (var q = Ne.length, P = 0; P < q; P += 4) Z &= Ne[P + 3];
|
|
5385
5385
|
}
|
|
5386
5386
|
const S = Z != 255, X = function(ae, ne, me, Ie, ge, Te) {
|
|
5387
5387
|
const pe = [];
|
|
5388
5388
|
for (var ee = 0; ee < ae.length; ee++) {
|
|
5389
5389
|
const Le = new Uint8Array(ae[ee]), Ve = new Uint32Array(Le.buffer);
|
|
5390
5390
|
var Re;
|
|
5391
|
-
let xe = 0, _e = 0, Ke = ne, st = me,
|
|
5391
|
+
let xe = 0, _e = 0, Ke = ne, st = me, Vt = Ie ? 1 : 0;
|
|
5392
5392
|
if (ee != 0) {
|
|
5393
|
-
const
|
|
5394
|
-
let
|
|
5395
|
-
for (let je = 0; je <
|
|
5393
|
+
const hn = Te || Ie || ee == 1 || pe[ee - 2].dispose != 0 ? 1 : 2;
|
|
5394
|
+
let Ht = 0, ce = 1e9;
|
|
5395
|
+
for (let je = 0; je < hn; je++) {
|
|
5396
5396
|
var Ue = new Uint8Array(ae[ee - 1 - je]);
|
|
5397
5397
|
const ot = new Uint32Array(ae[ee - 1 - je]);
|
|
5398
|
-
let Et = ne, vt = me,
|
|
5398
|
+
let Et = ne, vt = me, Pt = -1, Yt = -1;
|
|
5399
5399
|
for (let Ut = 0; Ut < me; Ut++) for (let xt = 0; xt < ne; xt++)
|
|
5400
|
-
Ve[Ae = Ut * ne + xt] != ot[Ae] && (xt < Et && (Et = xt), xt >
|
|
5401
|
-
|
|
5402
|
-
const er = (
|
|
5403
|
-
er < ce && (ce = er,
|
|
5400
|
+
Ve[Ae = Ut * ne + xt] != ot[Ae] && (xt < Et && (Et = xt), xt > Pt && (Pt = xt), Ut < vt && (vt = Ut), Ut > Yt && (Yt = Ut));
|
|
5401
|
+
Pt == -1 && (Et = vt = Pt = Yt = 0), ge && ((1 & Et) == 1 && Et--, (1 & vt) == 1 && vt--);
|
|
5402
|
+
const er = (Pt - Et + 1) * (Yt - vt + 1);
|
|
5403
|
+
er < ce && (ce = er, Ht = je, xe = Et, _e = vt, Ke = Pt - Et + 1, st = Yt - vt + 1);
|
|
5404
5404
|
}
|
|
5405
|
-
Ue = new Uint8Array(ae[ee - 1 -
|
|
5405
|
+
Ue = new Uint8Array(ae[ee - 1 - Ht]), Ht == 1 && (pe[ee - 1].dispose = 2), Re = new Uint8Array(Ke * st * 4), s(Ue, ne, me, Re, Ke, st, -xe, -_e, 0), Vt = s(Le, ne, me, Re, Ke, st, -xe, -_e, 3) ? 1 : 0, Vt == 1 ? d(Le, ne, me, Re, { x: xe, y: _e, width: Ke, height: st }) : s(Le, ne, me, Re, Ke, st, -xe, -_e, 0);
|
|
5406
5406
|
} else Re = Le.slice(0);
|
|
5407
|
-
pe.push({ rect: { x: xe, y: _e, width: Ke, height: st }, img: Re, blend:
|
|
5407
|
+
pe.push({ rect: { x: xe, y: _e, width: Ke, height: st }, img: Re, blend: Vt, dispose: 0 });
|
|
5408
5408
|
}
|
|
5409
5409
|
if (Ie) for (ee = 0; ee < pe.length; ee++) {
|
|
5410
5410
|
if ((it = pe[ee]).blend == 1) continue;
|
|
@@ -5420,7 +5420,7 @@ const Xe = function() {
|
|
|
5420
5420
|
}(m, g, k, U, A, _), oe = {}, te = [], Y = [];
|
|
5421
5421
|
if (T != 0) {
|
|
5422
5422
|
const Ne = [];
|
|
5423
|
-
for (
|
|
5423
|
+
for (P = 0; P < X.length; P++) Ne.push(X[P].img.buffer);
|
|
5424
5424
|
const ae = function(ge) {
|
|
5425
5425
|
let Te = 0;
|
|
5426
5426
|
for (var pe = 0; pe < ge.length; pe++) Te += ge[pe].byteLength;
|
|
@@ -5437,33 +5437,33 @@ const Xe = function() {
|
|
|
5437
5437
|
}
|
|
5438
5438
|
return ee.buffer;
|
|
5439
5439
|
}(Ne), ne = F(ae, T);
|
|
5440
|
-
for (
|
|
5440
|
+
for (P = 0; P < ne.plte.length; P++) te.push(ne.plte[P].est.rgba);
|
|
5441
5441
|
let me = 0;
|
|
5442
|
-
for (
|
|
5443
|
-
const Ie = (fe = X[
|
|
5442
|
+
for (P = 0; P < X.length; P++) {
|
|
5443
|
+
const Ie = (fe = X[P]).img.length;
|
|
5444
5444
|
var re = new Uint8Array(ne.inds.buffer, me >> 2, Ie >> 2);
|
|
5445
5445
|
Y.push(re);
|
|
5446
5446
|
const ge = new Uint8Array(ne.abuf, me, Ie);
|
|
5447
5447
|
M && a(fe.img, fe.rect.width, fe.rect.height, te, ge, re), fe.img.set(ge), me += Ie;
|
|
5448
5448
|
}
|
|
5449
|
-
} else for (
|
|
5450
|
-
var fe = X[
|
|
5449
|
+
} else for ($ = 0; $ < X.length; $++) {
|
|
5450
|
+
var fe = X[$];
|
|
5451
5451
|
const Ne = new Uint32Array(fe.img.buffer);
|
|
5452
5452
|
var be = fe.rect.width;
|
|
5453
|
-
for (q = Ne.length, re = new Uint8Array(q), Y.push(re),
|
|
5454
|
-
const ae = Ne[
|
|
5455
|
-
if (
|
|
5456
|
-
else if (
|
|
5453
|
+
for (q = Ne.length, re = new Uint8Array(q), Y.push(re), P = 0; P < q; P++) {
|
|
5454
|
+
const ae = Ne[P];
|
|
5455
|
+
if (P != 0 && ae == Ne[P - 1]) re[P] = re[P - 1];
|
|
5456
|
+
else if (P > be && ae == Ne[P - be]) re[P] = re[P - be];
|
|
5457
5457
|
else {
|
|
5458
5458
|
let ne = oe[ae];
|
|
5459
5459
|
if (ne == null && (oe[ae] = ne = te.length, te.push(ae), te.length >= 300)) break;
|
|
5460
|
-
re[
|
|
5460
|
+
re[P] = ne;
|
|
5461
5461
|
}
|
|
5462
5462
|
}
|
|
5463
5463
|
}
|
|
5464
5464
|
const ft = te.length;
|
|
5465
|
-
for (ft <= 256 && p == 0 && (V = ft <= 2 ? 1 : ft <= 4 ? 2 : ft <= 16 ? 4 : 8, V = Math.max(V, w)),
|
|
5466
|
-
(fe = X[
|
|
5465
|
+
for (ft <= 256 && p == 0 && (V = ft <= 2 ? 1 : ft <= 4 ? 2 : ft <= 16 ? 4 : 8, V = Math.max(V, w)), $ = 0; $ < X.length; $++) {
|
|
5466
|
+
(fe = X[$]).rect.x, fe.rect.y, be = fe.rect.width;
|
|
5467
5467
|
const Ne = fe.rect.height;
|
|
5468
5468
|
let ae = fe.img;
|
|
5469
5469
|
new Uint32Array(ae.buffer);
|
|
@@ -5471,21 +5471,21 @@ const Xe = function() {
|
|
|
5471
5471
|
if (ft <= 256 && p == 0) {
|
|
5472
5472
|
ne = Math.ceil(V * be / 8);
|
|
5473
5473
|
var We = new Uint8Array(ne * Ne);
|
|
5474
|
-
const Ie = Y[
|
|
5474
|
+
const Ie = Y[$];
|
|
5475
5475
|
for (let ge = 0; ge < Ne; ge++) {
|
|
5476
|
-
|
|
5476
|
+
P = ge * ne;
|
|
5477
5477
|
const Te = ge * be;
|
|
5478
|
-
if (V == 8) for (var de = 0; de < be; de++) We[
|
|
5479
|
-
else if (V == 4) for (de = 0; de < be; de++) We[
|
|
5480
|
-
else if (V == 2) for (de = 0; de < be; de++) We[
|
|
5481
|
-
else if (V == 1) for (de = 0; de < be; de++) We[
|
|
5478
|
+
if (V == 8) for (var de = 0; de < be; de++) We[P + de] = Ie[Te + de];
|
|
5479
|
+
else if (V == 4) for (de = 0; de < be; de++) We[P + (de >> 1)] |= Ie[Te + de] << 4 - 4 * (1 & de);
|
|
5480
|
+
else if (V == 2) for (de = 0; de < be; de++) We[P + (de >> 2)] |= Ie[Te + de] << 6 - 2 * (3 & de);
|
|
5481
|
+
else if (V == 1) for (de = 0; de < be; de++) We[P + (de >> 3)] |= Ie[Te + de] << 7 - 1 * (7 & de);
|
|
5482
5482
|
}
|
|
5483
5483
|
ae = We, x = 3, me = 1;
|
|
5484
5484
|
} else if (S == 0 && X.length == 1) {
|
|
5485
5485
|
We = new Uint8Array(be * Ne * 3);
|
|
5486
5486
|
const Ie = be * Ne;
|
|
5487
|
-
for (
|
|
5488
|
-
const ge = 3 *
|
|
5487
|
+
for (P = 0; P < Ie; P++) {
|
|
5488
|
+
const ge = 3 * P, Te = 4 * P;
|
|
5489
5489
|
We[ge] = ae[Te], We[ge + 1] = ae[Te + 1], We[ge + 2] = ae[Te + 2];
|
|
5490
5490
|
}
|
|
5491
5491
|
ae = We, x = 2, me = 3, ne = 3 * be;
|
|
@@ -5496,12 +5496,12 @@ const Xe = function() {
|
|
|
5496
5496
|
}
|
|
5497
5497
|
function u(m, g, k, T, N, U, A) {
|
|
5498
5498
|
const _ = Uint8Array, w = Uint32Array, p = new _(m[N - 1]), M = new w(m[N - 1]), x = N + 1 < m.length ? new _(m[N + 1]) : null, V = new _(m[N]), Z = new w(V.buffer);
|
|
5499
|
-
let
|
|
5499
|
+
let $ = g, q = k, P = -1, S = -1;
|
|
5500
5500
|
for (let oe = 0; oe < U.height; oe++) for (let te = 0; te < U.width; te++) {
|
|
5501
5501
|
const Y = U.x + te, re = U.y + oe, fe = re * g + Y, be = Z[fe];
|
|
5502
|
-
be == 0 || T[N - 1].dispose == 0 && M[fe] == be && (x == null || x[4 * fe + 3] != 0) || (Y <
|
|
5502
|
+
be == 0 || T[N - 1].dispose == 0 && M[fe] == be && (x == null || x[4 * fe + 3] != 0) || (Y < $ && ($ = Y), Y > P && (P = Y), re < q && (q = re), re > S && (S = re));
|
|
5503
5503
|
}
|
|
5504
|
-
|
|
5504
|
+
P == -1 && ($ = q = P = S = 0), A && ((1 & $) == 1 && $--, (1 & q) == 1 && q--), U = { x: $, y: q, width: P - $ + 1, height: S - q + 1 };
|
|
5505
5505
|
const X = T[N];
|
|
5506
5506
|
X.rect = U, X.blend = 1, X.img = new Uint8Array(U.width * U.height * 4), T[N - 1].dispose == 0 ? (s(p, g, k, X.img, U.width, U.height, -U.x, -U.y, 0), d(V, g, k, X.img, U)) : s(V, g, k, X.img, U.width, U.height, -U.x, -U.y, 0);
|
|
5507
5507
|
}
|
|
@@ -5512,9 +5512,9 @@ const Xe = function() {
|
|
|
5512
5512
|
const _ = [];
|
|
5513
5513
|
let w, p = [0, 1, 2, 3, 4];
|
|
5514
5514
|
U != -1 ? p = [U] : (g * T > 5e5 || k == 1) && (p = [0]), A && (w = { level: 0 });
|
|
5515
|
-
const M =
|
|
5515
|
+
const M = Ps;
|
|
5516
5516
|
for (var x = 0; x < p.length; x++) {
|
|
5517
|
-
for (let
|
|
5517
|
+
for (let $ = 0; $ < g; $++) y(N, m, $, T, k, p[x]);
|
|
5518
5518
|
_.push(M.deflate(N, w));
|
|
5519
5519
|
}
|
|
5520
5520
|
let V, Z = 1e9;
|
|
@@ -5550,10 +5550,10 @@ const Xe = function() {
|
|
|
5550
5550
|
const k = new Uint8Array(m), T = k.slice(0), N = new Uint32Array(T.buffer), U = I(T, g), A = U[0], _ = U[1], w = k.length, p = new Uint8Array(w >> 2);
|
|
5551
5551
|
let M;
|
|
5552
5552
|
if (k.length < 2e7) for (var x = 0; x < w; x += 4)
|
|
5553
|
-
M = C(A, V = k[x] * (1 / 255), Z = k[x + 1] * (1 / 255),
|
|
5553
|
+
M = C(A, V = k[x] * (1 / 255), Z = k[x + 1] * (1 / 255), $ = k[x + 2] * (1 / 255), q = k[x + 3] * (1 / 255)), p[x >> 2] = M.ind, N[x >> 2] = M.est.rgba;
|
|
5554
5554
|
else for (x = 0; x < w; x += 4) {
|
|
5555
|
-
var V = k[x] * 0.00392156862745098, Z = k[x + 1] * (1 / 255),
|
|
5556
|
-
for (M = A; M.left; ) M = R(M.est, V, Z,
|
|
5555
|
+
var V = k[x] * 0.00392156862745098, Z = k[x + 1] * (1 / 255), $ = k[x + 2] * (1 / 255), q = k[x + 3] * (1 / 255);
|
|
5556
|
+
for (M = A; M.left; ) M = R(M.est, V, Z, $, q) <= 0 ? M.left : M.right;
|
|
5557
5557
|
p[x >> 2] = M.ind, N[x >> 2] = M.est.rgba;
|
|
5558
5558
|
}
|
|
5559
5559
|
return { abuf: T.buffer, inds: p, plte: _ };
|
|
@@ -5583,9 +5583,9 @@ const Xe = function() {
|
|
|
5583
5583
|
return [N, U];
|
|
5584
5584
|
}
|
|
5585
5585
|
function C(m, g, k, T, N) {
|
|
5586
|
-
if (m.left == null) return m.tdst = function(x, V, Z,
|
|
5587
|
-
const
|
|
5588
|
-
return
|
|
5586
|
+
if (m.left == null) return m.tdst = function(x, V, Z, $, q) {
|
|
5587
|
+
const P = V - x[0], S = Z - x[1], X = $ - x[2], oe = q - x[3];
|
|
5588
|
+
return P * P + S * S + X * X + oe * oe;
|
|
5589
5589
|
}(m.est.q, g, k, T, N), m;
|
|
5590
5590
|
const U = R(m.est, g, k, T, N);
|
|
5591
5591
|
let A = m.left, _ = m.right;
|
|
@@ -5623,8 +5623,8 @@ const Xe = function() {
|
|
|
5623
5623
|
}
|
|
5624
5624
|
function b(m) {
|
|
5625
5625
|
const { R: g } = m, { m: k } = m, { N: T } = m, N = k[0], U = k[1], A = k[2], _ = k[3], w = T == 0 ? 0 : 1 / T, p = [g[0] - N * N * w, g[1] - N * U * w, g[2] - N * A * w, g[3] - N * _ * w, g[4] - U * N * w, g[5] - U * U * w, g[6] - U * A * w, g[7] - U * _ * w, g[8] - A * N * w, g[9] - A * U * w, g[10] - A * A * w, g[11] - A * _ * w, g[12] - _ * N * w, g[13] - _ * U * w, g[14] - _ * A * w, g[15] - _ * _ * w], M = p, x = B;
|
|
5626
|
-
let V = [Math.random(), Math.random(), Math.random(), Math.random()], Z = 0,
|
|
5627
|
-
if (T != 0) for (let
|
|
5626
|
+
let V = [Math.random(), Math.random(), Math.random(), Math.random()], Z = 0, $ = 0;
|
|
5627
|
+
if (T != 0) for (let P = 0; P < 16 && (V = x.multVec(M, V), $ = Math.sqrt(x.dot(V, V)), V = x.sml(1 / $, V), !(P != 0 && Math.abs($ - Z) < 1e-9)); P++) Z = $;
|
|
5628
5628
|
const q = [N * w, U * w, A * w, _ * w];
|
|
5629
5629
|
return { Cov: p, q, e: V, L: Z, eMq255: x.dot(x.sml(255, q), V), eMq: x.dot(V, q), rgba: (Math.round(255 * q[3]) << 24 | Math.round(255 * q[2]) << 16 | Math.round(255 * q[1]) << 8 | Math.round(255 * q[0]) << 0) >>> 0 };
|
|
5630
5630
|
}
|
|
@@ -5663,8 +5663,8 @@ const Zr = { toArrayBuffer(s, e) {
|
|
|
5663
5663
|
e(new Blob([t], { type: "image/bmp" }));
|
|
5664
5664
|
});
|
|
5665
5665
|
}, _dly: 9 };
|
|
5666
|
-
var
|
|
5667
|
-
const Qn = typeof window < "u", Kr = typeof WorkerGlobalScope < "u" && self instanceof WorkerGlobalScope,
|
|
5666
|
+
var Pe = { CHROME: "CHROME", FIREFOX: "FIREFOX", DESKTOP_SAFARI: "DESKTOP_SAFARI", IE: "IE", IOS: "IOS", ETC: "ETC" }, $s = { [Pe.CHROME]: 16384, [Pe.FIREFOX]: 11180, [Pe.DESKTOP_SAFARI]: 16384, [Pe.IE]: 8192, [Pe.IOS]: 4096, [Pe.ETC]: 8192 };
|
|
5667
|
+
const Qn = typeof window < "u", Kr = typeof WorkerGlobalScope < "u" && self instanceof WorkerGlobalScope, kn = Qn && window.cordova && window.cordova.require && window.cordova.require("cordova/modulemapper"), Ws = (Qn || Kr) && (kn && kn.getOriginalSymbol(window, "File") || typeof File < "u" && File), zr = (Qn || Kr) && (kn && kn.getOriginalSymbol(window, "FileReader") || typeof FileReader < "u" && FileReader);
|
|
5668
5668
|
function Yn(s, e, t = Date.now()) {
|
|
5669
5669
|
return new Promise((n) => {
|
|
5670
5670
|
const r = s.split(","), i = r[0].match(/:(.*?);/)[1], o = globalThis.atob(r[1]);
|
|
@@ -5689,12 +5689,12 @@ function Gr(s) {
|
|
|
5689
5689
|
}
|
|
5690
5690
|
function _t() {
|
|
5691
5691
|
if (_t.cachedResult !== void 0) return _t.cachedResult;
|
|
5692
|
-
let s =
|
|
5692
|
+
let s = Pe.ETC;
|
|
5693
5693
|
const { userAgent: e } = navigator;
|
|
5694
|
-
return /Chrom(e|ium)/i.test(e) ? s =
|
|
5694
|
+
return /Chrom(e|ium)/i.test(e) ? s = Pe.CHROME : /iP(ad|od|hone)/i.test(e) && /WebKit/i.test(e) ? s = Pe.IOS : /Safari/i.test(e) ? s = Pe.DESKTOP_SAFARI : /Firefox/i.test(e) ? s = Pe.FIREFOX : (/MSIE/i.test(e) || document.documentMode) && (s = Pe.IE), _t.cachedResult = s, _t.cachedResult;
|
|
5695
5695
|
}
|
|
5696
5696
|
function Jr(s, e) {
|
|
5697
|
-
const t = _t(), n =
|
|
5697
|
+
const t = _t(), n = $s[t];
|
|
5698
5698
|
let r = s, i = e, o = r * i;
|
|
5699
5699
|
const a = r > i ? i / r : r / i;
|
|
5700
5700
|
for (; o > n * n; ) {
|
|
@@ -5703,7 +5703,7 @@ function Jr(s, e) {
|
|
|
5703
5703
|
}
|
|
5704
5704
|
return { width: r, height: i };
|
|
5705
5705
|
}
|
|
5706
|
-
function
|
|
5706
|
+
function _n(s, e) {
|
|
5707
5707
|
let t, n;
|
|
5708
5708
|
try {
|
|
5709
5709
|
if (t = new OffscreenCanvas(s, e), n = t.getContext("2d"), n === null) throw new Error("getContext of OffscreenCanvas returns null");
|
|
@@ -5713,13 +5713,13 @@ function xn(s, e) {
|
|
|
5713
5713
|
return t.width = s, t.height = e, [t, n];
|
|
5714
5714
|
}
|
|
5715
5715
|
function Qr(s, e) {
|
|
5716
|
-
const { width: t, height: n } = Jr(s.width, s.height), [r, i] =
|
|
5716
|
+
const { width: t, height: n } = Jr(s.width, s.height), [r, i] = _n(t, n);
|
|
5717
5717
|
return e && /jpe?g/.test(e) && (i.fillStyle = "white", i.fillRect(0, 0, r.width, r.height)), i.drawImage(s, 0, 0, r.width, r.height), r;
|
|
5718
5718
|
}
|
|
5719
|
-
function
|
|
5720
|
-
return
|
|
5719
|
+
function bn() {
|
|
5720
|
+
return bn.cachedResult !== void 0 || (bn.cachedResult = ["iPad Simulator", "iPhone Simulator", "iPod Simulator", "iPad", "iPhone", "iPod"].includes(navigator.platform) || navigator.userAgent.includes("Mac") && typeof document < "u" && "ontouchend" in document), bn.cachedResult;
|
|
5721
5721
|
}
|
|
5722
|
-
function
|
|
5722
|
+
function Fn(s, e = {}) {
|
|
5723
5723
|
return new Promise(function(t, n) {
|
|
5724
5724
|
let r, i;
|
|
5725
5725
|
var o = function() {
|
|
@@ -5766,7 +5766,7 @@ function kn(s, e = {}) {
|
|
|
5766
5766
|
}
|
|
5767
5767
|
};
|
|
5768
5768
|
try {
|
|
5769
|
-
if (
|
|
5769
|
+
if (bn() || [Pe.DESKTOP_SAFARI, Pe.MOBILE_SAFARI].includes(_t())) throw new Error("Skip createImageBitmap on IOS and Safari");
|
|
5770
5770
|
return createImageBitmap(s).then(function(c) {
|
|
5771
5771
|
try {
|
|
5772
5772
|
return r = c, o();
|
|
@@ -5779,7 +5779,7 @@ function kn(s, e = {}) {
|
|
|
5779
5779
|
}
|
|
5780
5780
|
});
|
|
5781
5781
|
}
|
|
5782
|
-
function
|
|
5782
|
+
function Nn(s, e, t, n, r = 1) {
|
|
5783
5783
|
return new Promise(function(i, o) {
|
|
5784
5784
|
let a;
|
|
5785
5785
|
if (e === "image/png") {
|
|
@@ -5833,11 +5833,11 @@ function $t() {
|
|
|
5833
5833
|
let t, n, r, i;
|
|
5834
5834
|
return $t.cachedResult !== void 0 ? s($t.cachedResult) : Yn("data:image/jpeg;base64,/9j/4QAiRXhpZgAATU0AKgAAAAgAAQESAAMAAAABAAYAAAAAAAD/2wCEAAEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAf/AABEIAAEAAgMBEQACEQEDEQH/xABKAAEAAAAAAAAAAAAAAAAAAAALEAEAAAAAAAAAAAAAAAAAAAAAAQEAAAAAAAAAAAAAAAAAAAAAEQEAAAAAAAAAAAAAAAAAAAAA/9oADAMBAAIRAxEAPwA/8H//2Q==", "test.jpg", Date.now()).then(function(o) {
|
|
5835
5835
|
try {
|
|
5836
|
-
return t = o,
|
|
5836
|
+
return t = o, Fn(t).then(function(a) {
|
|
5837
5837
|
try {
|
|
5838
|
-
return n = a[1],
|
|
5838
|
+
return n = a[1], Nn(n, t.type, t.name, t.lastModified).then(function(c) {
|
|
5839
5839
|
try {
|
|
5840
|
-
return r = c, ht(n),
|
|
5840
|
+
return r = c, ht(n), Fn(r).then(function(h) {
|
|
5841
5841
|
try {
|
|
5842
5842
|
return i = h[0], $t.cachedResult = i.width === 1 && i.height === 2, s($t.cachedResult);
|
|
5843
5843
|
} catch (l) {
|
|
@@ -5888,10 +5888,10 @@ function Yr(s) {
|
|
|
5888
5888
|
function ei(s, e) {
|
|
5889
5889
|
const { width: t } = s, { height: n } = s, { maxWidthOrHeight: r } = e;
|
|
5890
5890
|
let i, o = s;
|
|
5891
|
-
return isFinite(r) && (t > r || n > r) && ([o, i] =
|
|
5891
|
+
return isFinite(r) && (t > r || n > r) && ([o, i] = _n(t, n), t > n ? (o.width = r, o.height = n / t * r) : (o.width = t / n * r, o.height = r), i.drawImage(s, 0, 0, o.width, o.height), ht(s)), o;
|
|
5892
5892
|
}
|
|
5893
5893
|
function ti(s, e) {
|
|
5894
|
-
const { width: t } = s, { height: n } = s, [r, i] =
|
|
5894
|
+
const { width: t } = s, { height: n } = s, [r, i] = _n(t, n);
|
|
5895
5895
|
switch (e > 4 && e < 9 ? (r.width = n, r.height = t) : (r.width = t, r.height = n), e) {
|
|
5896
5896
|
case 2:
|
|
5897
5897
|
i.transform(-1, 0, 0, 1, t, 0);
|
|
@@ -5927,7 +5927,7 @@ function Ar(s, e, t = 0) {
|
|
|
5927
5927
|
if (e.signal && e.signal.aborted) throw e.signal.reason;
|
|
5928
5928
|
i = Math.min(Math.max(T, i), 100), e.onProgress(i);
|
|
5929
5929
|
}
|
|
5930
|
-
return i = t, o = e.maxIteration || 10, a = 1024 * e.maxSizeMB * 1024, g(),
|
|
5930
|
+
return i = t, o = e.maxIteration || 10, a = 1024 * e.maxSizeMB * 1024, g(), Fn(s, e).then((function(T) {
|
|
5931
5931
|
try {
|
|
5932
5932
|
return [, c] = T, g(), h = ei(c, e), g(), new Promise(function(N, U) {
|
|
5933
5933
|
var A;
|
|
@@ -5946,13 +5946,13 @@ function Ar(s, e, t = 0) {
|
|
|
5946
5946
|
try {
|
|
5947
5947
|
return l = N, g(), $t().then((function(U) {
|
|
5948
5948
|
try {
|
|
5949
|
-
return u = U ? h : ti(h, l), g(), d = e.initialQuality || 1, f = e.fileType || s.type,
|
|
5949
|
+
return u = U ? h : ti(h, l), g(), d = e.initialQuality || 1, f = e.fileType || s.type, Nn(u, f, s.name, s.lastModified, d).then((function(A) {
|
|
5950
5950
|
try {
|
|
5951
5951
|
{
|
|
5952
5952
|
let w = function() {
|
|
5953
5953
|
if (o-- && (O > a || O > C)) {
|
|
5954
5954
|
let M, x;
|
|
5955
|
-
return M = m ? 0.95 * B.width : B.width, x = m ? 0.95 * B.height : B.height, [L, b] =
|
|
5955
|
+
return M = m ? 0.95 * B.width : B.width, x = m ? 0.95 * B.height : B.height, [L, b] = _n(M, x), b.drawImage(B, 0, 0, M, x), d *= f === "image/png" ? 0.85 : 0.95, Nn(L, f, s.name, s.lastModified, d).then(function(V) {
|
|
5956
5956
|
try {
|
|
5957
5957
|
return v = V, ht(B), B = L, O = v.size, k(Math.min(99, Math.floor((R - O) / (R - a) * 100))), w;
|
|
5958
5958
|
} catch (Z) {
|
|
@@ -6018,14 +6018,14 @@ self.addEventListener('message', async (e) => {
|
|
|
6018
6018
|
}
|
|
6019
6019
|
})
|
|
6020
6020
|
`;
|
|
6021
|
-
let
|
|
6021
|
+
let Pn;
|
|
6022
6022
|
function qs(s, e) {
|
|
6023
6023
|
return new Promise((t, n) => {
|
|
6024
|
-
|
|
6024
|
+
Pn || (Pn = function(o) {
|
|
6025
6025
|
const a = [];
|
|
6026
6026
|
return a.push(o), URL.createObjectURL(new Blob(a));
|
|
6027
6027
|
}(js));
|
|
6028
|
-
const r = new Worker(
|
|
6028
|
+
const r = new Worker(Pn);
|
|
6029
6029
|
r.addEventListener("message", function(o) {
|
|
6030
6030
|
if (e.signal && e.signal.aborted) r.terminate();
|
|
6031
6031
|
else if (o.data.progress === void 0) {
|
|
@@ -6094,7 +6094,7 @@ function Be(s, e) {
|
|
|
6094
6094
|
}
|
|
6095
6095
|
});
|
|
6096
6096
|
}
|
|
6097
|
-
Be.getDataUrlFromFile = Xr, Be.getFilefromDataUrl = Yn, Be.loadImage = Gr, Be.drawImageInCanvas = Qr, Be.drawFileInCanvas =
|
|
6097
|
+
Be.getDataUrlFromFile = Xr, Be.getFilefromDataUrl = Yn, Be.loadImage = Gr, Be.drawImageInCanvas = Qr, Be.drawFileInCanvas = Fn, Be.canvasToFile = Nn, Be.getExifOrientation = Yr, Be.handleMaxWidthOrHeight = ei, Be.followExifOrientation = ti, Be.cleanupCanvasMemory = ht, Be.isAutoOrientationInBrowser = $t, Be.approximateBelowMaximumCanvasSizeOfBrowser = Jr, Be.copyExifWithoutOrientation = qr, Be.getBrowserName = _t, Be.version = "2.0.2";
|
|
6098
6098
|
class Zs extends Fe {
|
|
6099
6099
|
constructor() {
|
|
6100
6100
|
super("com.hamropatro.grpc.common.ImageUploadRequest", [
|
|
@@ -6136,7 +6136,7 @@ class Zs extends Fe {
|
|
|
6136
6136
|
return r !== !1 && (r == !0 ? G.onWrite : r)(this.typeName, e, t), t;
|
|
6137
6137
|
}
|
|
6138
6138
|
}
|
|
6139
|
-
const
|
|
6139
|
+
const In = new Zs();
|
|
6140
6140
|
class Ks extends Fe {
|
|
6141
6141
|
constructor() {
|
|
6142
6142
|
super("com.hamropatro.grpc.common.ImageUploadResponse", [
|
|
@@ -6201,8 +6201,8 @@ class Ks extends Fe {
|
|
|
6201
6201
|
}
|
|
6202
6202
|
}
|
|
6203
6203
|
const kr = new Ks(), $n = new Gn("com.hamropatro.grpc.common.ImageUploadService", [
|
|
6204
|
-
{ name: "Upload", options: {}, I:
|
|
6205
|
-
{ name: "UploadUserImage", options: {}, I:
|
|
6204
|
+
{ name: "Upload", options: {}, I: In, O: kr },
|
|
6205
|
+
{ name: "UploadUserImage", options: {}, I: In, O: kr }
|
|
6206
6206
|
]);
|
|
6207
6207
|
class ni {
|
|
6208
6208
|
constructor(e) {
|
|
@@ -6228,7 +6228,7 @@ class ni {
|
|
|
6228
6228
|
}
|
|
6229
6229
|
const zs = async (s, e, t = !0) => {
|
|
6230
6230
|
var o;
|
|
6231
|
-
const n = (o = window.ImageSalonSDK) == null ? void 0 : o.grpcConfig, r = new ni(n), i =
|
|
6231
|
+
const n = (o = window.ImageSalonSDK) == null ? void 0 : o.grpcConfig, r = new ni(n), i = In.create();
|
|
6232
6232
|
try {
|
|
6233
6233
|
return i.mimeType = s, t ? await r.upload(i, e) : await r.uploadUserImage(
|
|
6234
6234
|
i,
|
|
@@ -6239,7 +6239,7 @@ const zs = async (s, e, t = !0) => {
|
|
|
6239
6239
|
}
|
|
6240
6240
|
}, Xs = async (s, e) => {
|
|
6241
6241
|
var o, a;
|
|
6242
|
-
const t = (o = window.ImageSalonSDK) == null ? void 0 : o.grpcConfig, n = (a = window.ImageSalonSDK) == null ? void 0 : a.mode, r = new ni(t), i =
|
|
6242
|
+
const t = (o = window.ImageSalonSDK) == null ? void 0 : o.grpcConfig, n = (a = window.ImageSalonSDK) == null ? void 0 : a.mode, r = new ni(t), i = In.create();
|
|
6243
6243
|
try {
|
|
6244
6244
|
return i.mimeType = s, await r.uploadUserImage(
|
|
6245
6245
|
i,
|
|
@@ -6312,7 +6312,7 @@ function Qs(s = "24px", e = "24px", t = "#000") {
|
|
|
6312
6312
|
"M240-200h120v-240h240v240h120v-360L480-740 240-560v360Zm-80 80v-480l320-240 320 240v480H520v-240h-80v240H160Zm320-350Z"
|
|
6313
6313
|
), n.appendChild(r), n;
|
|
6314
6314
|
}
|
|
6315
|
-
var mt, we, Ee, gt, ue, ke, Je,
|
|
6315
|
+
var mt, we, Ee, gt, ue, ke, Je, $e, Bt, kt, at, De, Qe, Ot, Ft, Nt, wt, St, lt, Ze, It, Tt, yt, jt, sn, Oe, Rt, on, Tn, an, ct, qt, Lt, Zt, Dt, Kt, zt, Xt, ln, cn, Gt, dt, Jt, dn, Qt;
|
|
6316
6316
|
class eo {
|
|
6317
6317
|
constructor(e) {
|
|
6318
6318
|
z(this, mt);
|
|
@@ -6322,14 +6322,13 @@ class eo {
|
|
|
6322
6322
|
z(this, ue, []);
|
|
6323
6323
|
z(this, ke, []);
|
|
6324
6324
|
z(this, Je);
|
|
6325
|
-
z(this,
|
|
6325
|
+
z(this, $e);
|
|
6326
6326
|
z(this, Bt);
|
|
6327
6327
|
z(this, kt);
|
|
6328
6328
|
z(this, at, []);
|
|
6329
6329
|
z(this, De);
|
|
6330
6330
|
z(this, Qe);
|
|
6331
6331
|
z(this, Ot);
|
|
6332
|
-
z(this, zn);
|
|
6333
6332
|
z(this, Ft);
|
|
6334
6333
|
z(this, Nt);
|
|
6335
6334
|
z(this, wt);
|
|
@@ -6339,29 +6338,30 @@ class eo {
|
|
|
6339
6338
|
z(this, It);
|
|
6340
6339
|
z(this, Tt);
|
|
6341
6340
|
z(this, yt);
|
|
6342
|
-
z(this,
|
|
6343
|
-
z(this,
|
|
6341
|
+
z(this, jt);
|
|
6342
|
+
z(this, sn);
|
|
6344
6343
|
z(this, Oe);
|
|
6345
6344
|
z(this, Rt);
|
|
6346
|
-
z(this,
|
|
6347
|
-
z(this,
|
|
6348
|
-
z(this,
|
|
6345
|
+
z(this, on, !1);
|
|
6346
|
+
z(this, Tn);
|
|
6347
|
+
z(this, an);
|
|
6349
6348
|
z(this, ct);
|
|
6350
|
-
z(this, jt);
|
|
6351
|
-
z(this, Lt);
|
|
6352
6349
|
z(this, qt);
|
|
6350
|
+
z(this, Lt);
|
|
6353
6351
|
z(this, Zt);
|
|
6352
|
+
z(this, Dt);
|
|
6354
6353
|
z(this, Kt);
|
|
6355
6354
|
z(this, zt);
|
|
6356
6355
|
z(this, Xt);
|
|
6357
|
-
z(this, an);
|
|
6358
6356
|
z(this, ln);
|
|
6357
|
+
z(this, cn);
|
|
6359
6358
|
z(this, Gt);
|
|
6360
6359
|
z(this, dt);
|
|
6361
6360
|
z(this, Jt);
|
|
6362
|
-
z(this,
|
|
6363
|
-
|
|
6364
|
-
|
|
6361
|
+
z(this, dn);
|
|
6362
|
+
z(this, Qt);
|
|
6363
|
+
H(this, an, e.isAdmin), H(this, Je, !1), H(this, Zt, e == null ? void 0 : e.mode), e.handleUpload && H(this, Ot, e.handleUpload.bind(this)), e != null && e.accessToken && (H(this, sn, e.accessToken), this._grpcOptionInitializer()), this._init(e).then(() => {
|
|
6364
|
+
H(this, on, !0), e != null && e.parentContainerId && this._renderView(e), this.updateWindowObject({ initialized: !0 }), this._initializeGrpcConfig(e.mode, e.endPoint);
|
|
6365
6365
|
});
|
|
6366
6366
|
}
|
|
6367
6367
|
async _init(e) {
|
|
@@ -6377,14 +6377,14 @@ class eo {
|
|
|
6377
6377
|
}
|
|
6378
6378
|
_renderView(e) {
|
|
6379
6379
|
var t, n, r;
|
|
6380
|
-
return this._isAdminOptions(e) ? (H(this,
|
|
6380
|
+
return this._isAdminOptions(e) ? (H(this, $e, !1), H(this, Bt, !1), H(this, Ft, 0), H(this, Ze, ""), H(this, yt, !1), H(this, Zt, e.mode), H(this, It, !1), H(this, Lt, ""), H(this, Rt, null), H(this, dn, e.enableDialog), this._removeToastContainer(), this._renderAdminView(e)) : (H(this, qt, ""), H(this, Dt, e == null ? void 0 : e.restrictedFileSize), H(this, Kt, e == null ? void 0 : e.localizedFileRestrictedMessage), H(this, Xt, e == null ? void 0 : e.localizedSuccessMessage), H(this, zt, e == null ? void 0 : e.localizedErrorMessage), H(this, dt, e == null ? void 0 : e.imagePreviewWidth), H(this, Jt, e == null ? void 0 : e.imagePreviewHeight), H(this, ln, (t = e == null ? void 0 : e.removeImageConfirm) == null ? void 0 : t.bind(this)), H(this, cn, (n = e == null ? void 0 : e.removeImagePreviewCB) == null ? void 0 : n.bind(this)), H(this, Gt, (r = e == null ? void 0 : e.getUploadingState) == null ? void 0 : r.bind(this)), H(this, Qt, e == null ? void 0 : e.uploadText), this._removeUserToast(), this._renderUserView(e));
|
|
6381
6381
|
}
|
|
6382
6382
|
_renderAdminView(e) {
|
|
6383
|
-
if (!E(this,
|
|
6383
|
+
if (!E(this, on)) return;
|
|
6384
6384
|
const { parentContainerId: t } = e;
|
|
6385
6385
|
if (e.isAdmin === !0)
|
|
6386
6386
|
var { buttonProps: n } = e;
|
|
6387
|
-
if (H(this, mt, document.getElementById(t)), !E(this,
|
|
6387
|
+
if (H(this, mt, document.getElementById(t)), !E(this, dn))
|
|
6388
6388
|
setTimeout(() => {
|
|
6389
6389
|
const r = this._selectedImageContainer();
|
|
6390
6390
|
E(this, mt).appendChild(r);
|
|
@@ -6404,8 +6404,8 @@ class eo {
|
|
|
6404
6404
|
}
|
|
6405
6405
|
async _grpcOptionInitializer() {
|
|
6406
6406
|
H(this, Oe, await Ss(
|
|
6407
|
-
E(this,
|
|
6408
|
-
E(this,
|
|
6407
|
+
E(this, sn),
|
|
6408
|
+
E(this, Zt)
|
|
6409
6409
|
));
|
|
6410
6410
|
}
|
|
6411
6411
|
_commonImageContainer() {
|
|
@@ -6413,7 +6413,7 @@ class eo {
|
|
|
6413
6413
|
H(this, Nt, K("folder-container")), H(this, wt, K("folder-list-wrapper")), this._fetchAllFolders(), H(this, we, K("browse-container"));
|
|
6414
6414
|
const e = K();
|
|
6415
6415
|
e.style.display = "flex", e.style.alignItems = "center", e.style.justifyContent = "space-between", e.style.padding = "10px 20px";
|
|
6416
|
-
const t =
|
|
6416
|
+
const t = tn("Folders", "folder-title"), n = He("", "add-folder-btn");
|
|
6417
6417
|
n.append(br()), this._createUpdateFolderDialog(n, "create"), e.append(t, n), E(this, Nt).append(e, E(this, wt));
|
|
6418
6418
|
const r = this._renderSearchField(), i = this._createBrowseMoreContainer(), o = this._createBrowseImageMain(), a = K("footer");
|
|
6419
6419
|
H(this, Qe, He(
|
|
@@ -6444,12 +6444,12 @@ class eo {
|
|
|
6444
6444
|
!1,
|
|
6445
6445
|
'<svg xmlns="http://www.w3.org/2000/svg" x="0px" y="0px" width="24" height="24" viewBox="0 0 50 50"> <path d="M 9.15625 6.3125 L 6.3125 9.15625 L 22.15625 25 L 6.21875 40.96875 L 9.03125 43.78125 L 25 27.84375 L 40.9375 43.78125 L 43.78125 40.9375 L 27.84375 25 L 43.6875 9.15625 L 40.84375 6.3125 L 25 22.15625 Z"></path> </svg>'
|
|
6446
6446
|
).addEventListener("click", () => {
|
|
6447
|
-
|
|
6447
|
+
wn.hide(), H(this, ue, []), H(this, ke, []);
|
|
6448
6448
|
}), t.onclick = () => {
|
|
6449
|
-
|
|
6449
|
+
wn.hide(), H(this, Ze, ""), H(this, ke, []), H(this, ue, []);
|
|
6450
6450
|
}, E(this, Qe).onclick = () => {
|
|
6451
|
-
E(this, Ot).call(this),
|
|
6452
|
-
}, e.append(t, E(this, Qe)),
|
|
6451
|
+
E(this, Ot).call(this), wn.hide(), H(this, Ze, ""), H(this, ue, []), H(this, ke, []);
|
|
6452
|
+
}, e.append(t, E(this, Qe)), wn.show({
|
|
6453
6453
|
content: E(this, we)
|
|
6454
6454
|
});
|
|
6455
6455
|
}
|
|
@@ -6467,9 +6467,9 @@ class eo {
|
|
|
6467
6467
|
"margin-block: 0px; font-size: 13px; color: #777",
|
|
6468
6468
|
`Max File size: ${n}MB`
|
|
6469
6469
|
);
|
|
6470
|
-
i.append(
|
|
6470
|
+
i.append(Mn(), c, h);
|
|
6471
6471
|
} else
|
|
6472
|
-
i.append(
|
|
6472
|
+
i.append(Mn(), c);
|
|
6473
6473
|
return E(this, ct).append(i), r && this._renderImagePreview(r, "", i, !0), E(this, mt).appendChild(E(this, ct)), E(this, mt);
|
|
6474
6474
|
}
|
|
6475
6475
|
_renderImagePreview(e, t, n, r = !1) {
|
|
@@ -6506,14 +6506,14 @@ class eo {
|
|
|
6506
6506
|
"width: 18px; height: 18px; display:none; cursor:pointer; align-items: center; justify-content: center; padding: 4px; position: absolute; top: -5px; right: -5px; background: #c10007; border-radius: 50%;z-index:1"
|
|
6507
6507
|
);
|
|
6508
6508
|
f.id = "remove-preview-btn";
|
|
6509
|
-
const y =
|
|
6509
|
+
const y = zn();
|
|
6510
6510
|
y.style.fill = "#fff", f == null || f.appendChild(y), f.addEventListener("click", () => {
|
|
6511
|
-
E(this,
|
|
6511
|
+
E(this, ln).call(this);
|
|
6512
6512
|
});
|
|
6513
6513
|
const F = Q("button", "", "display:none");
|
|
6514
6514
|
F.id = "image-preview-hidden-btn", F.addEventListener("click", (C) => {
|
|
6515
6515
|
var R;
|
|
6516
|
-
C.preventDefault(), C.stopPropagation(), (R = E(this, ct)) == null || R.removeChild(c), E(this,
|
|
6516
|
+
C.preventDefault(), C.stopPropagation(), (R = E(this, ct)) == null || R.removeChild(c), E(this, cn).call(this), this._removeUserToast(), o && (o.style.display = "flex");
|
|
6517
6517
|
}), c == null || c.append(l, f, F), (I = E(this, ct)) == null || I.append(c);
|
|
6518
6518
|
}
|
|
6519
6519
|
_renderImageErrorContainer() {
|
|
@@ -6544,30 +6544,41 @@ class eo {
|
|
|
6544
6544
|
const e = document.getElementById("remove-preview-btn");
|
|
6545
6545
|
e && (e.style.display = "flex");
|
|
6546
6546
|
}
|
|
6547
|
+
_showInitialPreview(e) {
|
|
6548
|
+
const t = new FileReader();
|
|
6549
|
+
t.readAsDataURL(e), t.onload = () => {
|
|
6550
|
+
this._renderUserUploading(), this._renderImagePreview(t.result, "");
|
|
6551
|
+
}, t.onerror = () => {
|
|
6552
|
+
console.error("Error reading file:", t.error);
|
|
6553
|
+
};
|
|
6554
|
+
}
|
|
6547
6555
|
async _readFileAsBase64(e) {
|
|
6548
|
-
|
|
6549
|
-
|
|
6550
|
-
|
|
6551
|
-
|
|
6552
|
-
|
|
6553
|
-
|
|
6554
|
-
return;
|
|
6555
|
-
}
|
|
6556
|
-
H(this, Je, !0), E(this, Gt).call(this, !0);
|
|
6557
|
-
try {
|
|
6558
|
-
const n = await Nr(e);
|
|
6559
|
-
this._removeUserToast();
|
|
6560
|
-
const r = new FileReader();
|
|
6561
|
-
r.readAsDataURL(n), r.onload = () => {
|
|
6562
|
-
this._userViewUploadAndAddSelectedImageList(
|
|
6563
|
-
r.result,
|
|
6564
|
-
e
|
|
6556
|
+
if (E(this, Dt)) {
|
|
6557
|
+
const t = E(this, Dt) * 1024 * 1024;
|
|
6558
|
+
if (e.size > t) {
|
|
6559
|
+
this._renderUserToast(
|
|
6560
|
+
E(this, Kt) ? E(this, Kt) : `File size must be less than ${E(this, Dt)}MB.`,
|
|
6561
|
+
"error"
|
|
6565
6562
|
);
|
|
6566
|
-
|
|
6567
|
-
|
|
6568
|
-
|
|
6569
|
-
|
|
6570
|
-
|
|
6563
|
+
return;
|
|
6564
|
+
}
|
|
6565
|
+
} else {
|
|
6566
|
+
H(this, Je, !0), E(this, Gt).call(this, !0), this._showInitialPreview(e);
|
|
6567
|
+
try {
|
|
6568
|
+
const t = await Nr(e);
|
|
6569
|
+
this._removeUserToast();
|
|
6570
|
+
const n = new FileReader();
|
|
6571
|
+
n.readAsDataURL(t), n.onload = () => {
|
|
6572
|
+
this._userViewUploadAndAddSelectedImageList(
|
|
6573
|
+
n.result,
|
|
6574
|
+
e
|
|
6575
|
+
);
|
|
6576
|
+
}, n.onerror = () => {
|
|
6577
|
+
console.error("Error reading file:", n.error);
|
|
6578
|
+
};
|
|
6579
|
+
} catch (t) {
|
|
6580
|
+
this._renderUserToast(t == null ? void 0 : t.message, "error");
|
|
6581
|
+
}
|
|
6571
6582
|
}
|
|
6572
6583
|
}
|
|
6573
6584
|
_renderUserToast(e, t = "success") {
|
|
@@ -6583,7 +6594,7 @@ class eo {
|
|
|
6583
6594
|
"margin-block:0px;font-size:14px;padding-top:3px"
|
|
6584
6595
|
);
|
|
6585
6596
|
r.textContent = e, r.style.color = t === "success" ? "#4caf50" : "#ee3f3f";
|
|
6586
|
-
const i = t === "success" ? wr("#4caf50") :
|
|
6597
|
+
const i = t === "success" ? wr("#4caf50") : Dn();
|
|
6587
6598
|
i.style.width = "15px", i.style.height = "15px", n.append(i, r), E(this, ct).appendChild(n);
|
|
6588
6599
|
}
|
|
6589
6600
|
_removeUserToast() {
|
|
@@ -6591,13 +6602,13 @@ class eo {
|
|
|
6591
6602
|
e && e.remove();
|
|
6592
6603
|
}
|
|
6593
6604
|
_renderUserViewBrowseButton() {
|
|
6594
|
-
const e =
|
|
6605
|
+
const e = Hn("file");
|
|
6595
6606
|
e.style.display = "none", e.setAttribute("multiple", "true"), e.setAttribute("accept", "image/*");
|
|
6596
6607
|
const t = Q(
|
|
6597
6608
|
"a",
|
|
6598
6609
|
"user-upload-btn",
|
|
6599
6610
|
"",
|
|
6600
|
-
"Click to upload"
|
|
6611
|
+
E(this, Qt) ? E(this, Qt) : "Click to upload"
|
|
6601
6612
|
);
|
|
6602
6613
|
return t.classList.add("user-upload-btn"), t.role = "button", t.addEventListener("click", () => {
|
|
6603
6614
|
this._removeUserToast(), e.click();
|
|
@@ -6625,9 +6636,7 @@ class eo {
|
|
|
6625
6636
|
e && e.remove();
|
|
6626
6637
|
}
|
|
6627
6638
|
async _userViewUploadAndAddSelectedImageList(e, t) {
|
|
6628
|
-
this._renderUserUploading();
|
|
6629
6639
|
try {
|
|
6630
|
-
this._renderImagePreview(e, t.name);
|
|
6631
6640
|
const n = await Fr(e, t, E(this, Oe), !1);
|
|
6632
6641
|
await this._uploadForUser(n, t), E(this, Xt) && this._renderUserToast(E(this, Xt), "success");
|
|
6633
6642
|
} catch {
|
|
@@ -6644,16 +6653,16 @@ class eo {
|
|
|
6644
6653
|
try {
|
|
6645
6654
|
const r = await as(
|
|
6646
6655
|
e,
|
|
6647
|
-
Ye[
|
|
6656
|
+
Ye[Vn((n = t.type) == null ? void 0 : n.split("/")[0])],
|
|
6648
6657
|
E(this, Oe)
|
|
6649
6658
|
);
|
|
6650
|
-
H(this,
|
|
6659
|
+
H(this, qt, r == null ? void 0 : r.response), E(this, Ot).call(this);
|
|
6651
6660
|
} catch (r) {
|
|
6652
6661
|
throw Error(r);
|
|
6653
6662
|
}
|
|
6654
6663
|
}
|
|
6655
6664
|
_createAllAndSelectedTab(e) {
|
|
6656
|
-
const t = K("select-options"), n =
|
|
6665
|
+
const t = K("select-options"), n = tn("Browse", "select"), r = tn(
|
|
6657
6666
|
"Selected",
|
|
6658
6667
|
"select",
|
|
6659
6668
|
"selected-images-tab"
|
|
@@ -6666,10 +6675,10 @@ class eo {
|
|
|
6666
6675
|
}), t.append(n, r), e.appendChild(t);
|
|
6667
6676
|
}
|
|
6668
6677
|
_renderUploadButton() {
|
|
6669
|
-
const e =
|
|
6678
|
+
const e = Hn("file");
|
|
6670
6679
|
e.style.display = "none", e.setAttribute("multiple", "true"), e.setAttribute("accept", "image/*,video/*,audio/*,.gif"), H(this, gt, document.createElement("button")), E(this, gt).className = "browse-more-btn";
|
|
6671
6680
|
const t = document.createElement("span");
|
|
6672
|
-
return t.textContent = "Upload", E(this, gt).append(
|
|
6681
|
+
return t.textContent = "Upload", E(this, gt).append(Mn(), t), E(this, gt).type = "button", E(this, gt).addEventListener(
|
|
6673
6682
|
"click",
|
|
6674
6683
|
() => e.click()
|
|
6675
6684
|
), e.addEventListener("change", async () => {
|
|
@@ -6701,7 +6710,7 @@ class eo {
|
|
|
6701
6710
|
"search-input-wrapper",
|
|
6702
6711
|
"search-input-wrapper"
|
|
6703
6712
|
);
|
|
6704
|
-
H(this, Tt,
|
|
6713
|
+
H(this, Tt, Hn("search")), E(this, Tt).value = "", E(this, Tt).addEventListener("input", (i) => {
|
|
6705
6714
|
H(this, ke, []);
|
|
6706
6715
|
const o = i.target;
|
|
6707
6716
|
e && clearTimeout(e), e = setTimeout(() => {
|
|
@@ -6709,7 +6718,7 @@ class eo {
|
|
|
6709
6718
|
H(this, Ze, ""), H(this, It, !1), H(this, yt, !1), this._fetchFilesFromFolder(E(this, kt));
|
|
6710
6719
|
return;
|
|
6711
6720
|
}
|
|
6712
|
-
H(this, yt, !0), H(this,
|
|
6721
|
+
H(this, yt, !0), H(this, jt, o.value), this._search(E(this, jt));
|
|
6713
6722
|
}, 750);
|
|
6714
6723
|
}), E(this, Tt).setAttribute("placeholder", "Search");
|
|
6715
6724
|
const r = Ls();
|
|
@@ -6724,7 +6733,7 @@ class eo {
|
|
|
6724
6733
|
const e = K("browse-image-main");
|
|
6725
6734
|
return H(this, Ee, K("selected-image-container")), E(this, Ee).addEventListener("scroll", () => {
|
|
6726
6735
|
const t = E(this, Ee).clientHeight, n = E(this, Ee).scrollTop, r = E(this, Ee).scrollHeight;
|
|
6727
|
-
t + n >= r - 5 && E(this, It) && (E(this, yt) ? this._search(E(this,
|
|
6736
|
+
t + n >= r - 5 && E(this, It) && (E(this, yt) ? this._search(E(this, jt)) : this._fetchFilesFromFolder(E(this, kt)));
|
|
6728
6737
|
}), e.appendChild(E(this, Ee)), e;
|
|
6729
6738
|
}
|
|
6730
6739
|
_renderFetchingSkeletonUI() {
|
|
@@ -6734,7 +6743,7 @@ class eo {
|
|
|
6734
6743
|
}
|
|
6735
6744
|
}
|
|
6736
6745
|
_renderEmptyImageContainer() {
|
|
6737
|
-
if (E(this,
|
|
6746
|
+
if (E(this, $e) || E(this, Je)) return;
|
|
6738
6747
|
const e = K(), t = K(), n = document.createElement("p");
|
|
6739
6748
|
E(this, yt) && E(this, Ft) === 0 ? (t.innerHTML = `
|
|
6740
6749
|
<svg width="300" height="300" viewBox="0 0 1000 1000" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
@@ -6827,7 +6836,7 @@ class eo {
|
|
|
6827
6836
|
e.innerHTML = "", E(this, Ee).appendChild(e);
|
|
6828
6837
|
}
|
|
6829
6838
|
_fileCardBody(e) {
|
|
6830
|
-
var st,
|
|
6839
|
+
var st, Vt, hn, Ht;
|
|
6831
6840
|
const t = K("selected-image-content"), n = K("selected-image-top-bar"), r = He(
|
|
6832
6841
|
"",
|
|
6833
6842
|
"selected-image-btn",
|
|
@@ -6839,7 +6848,7 @@ class eo {
|
|
|
6839
6848
|
(e == null ? void 0 : e.type) === Ye.IMAGE && (i = vr(e == null ? void 0 : e.url, "selected-image"), o = Ns()), (e == null ? void 0 : e.type) === Ye.VIDEO && (i = Rs(e == null ? void 0 : e.url, "uploaded-video"), o = Us()), (e == null ? void 0 : e.type) === Ye.AUDIO && (i = Ds(e == null ? void 0 : e.url, "uploaded-audio"), o = Fs());
|
|
6840
6849
|
const a = K("selected-image-wrapper");
|
|
6841
6850
|
a.setAttribute("data-key", e == null ? void 0 : e.key);
|
|
6842
|
-
const c =
|
|
6851
|
+
const c = tn(e == null ? void 0 : e.name, "selected-image-name"), h = le("", "selected-image-type");
|
|
6843
6852
|
h.append(o), n.append(h, r);
|
|
6844
6853
|
const l = K();
|
|
6845
6854
|
l.style.marginTop = "10px", l.style.display = "flex", l.style.justifyContent = "space-between", l.style.alignItems = "center", l.append(c), t.append(n, i), a.append(t, l);
|
|
@@ -6851,18 +6860,18 @@ class eo {
|
|
|
6851
6860
|
R.append(v, O);
|
|
6852
6861
|
const L = He("", "action-option delete"), b = le("Delete", ""), B = Cr();
|
|
6853
6862
|
L.append(B, b);
|
|
6854
|
-
const m = e.name.split(".")[0], g = e.name.split(".")[1], k =
|
|
6863
|
+
const m = e.name.split(".")[0], g = e.name.split(".")[1], k = nn[e.type], T = K("edit-form-wrapper"), N = K("move-form-wrapper"), U = K("preview-details-container"), A = K("preview-details-wrapper"), _ = K(
|
|
6855
6864
|
"preview-option-image-wrapper"
|
|
6856
6865
|
), w = K("preview-option-wrapper"), p = K("preview-option-wrapper"), M = K(
|
|
6857
6866
|
"preview-option-wrapper"
|
|
6858
6867
|
), x = K("preview-option-wrapper"), V = K(
|
|
6859
6868
|
"preview-option-wrapper"
|
|
6860
|
-
), Z = K("preview-option-wrapper"),
|
|
6869
|
+
), Z = K("preview-option-wrapper"), $ = K(
|
|
6861
6870
|
"preview-option-wrapper"
|
|
6862
6871
|
), q = vr(e.url, "preview-option-image");
|
|
6863
6872
|
_.append(q);
|
|
6864
|
-
const
|
|
6865
|
-
S.innerHTML = e.name, w.append(
|
|
6873
|
+
const P = le("File name", "preview-title"), S = K("preview-option-name");
|
|
6874
|
+
S.innerHTML = e.name, w.append(P, S);
|
|
6866
6875
|
const X = le("Folder name", "preview-title"), oe = le(
|
|
6867
6876
|
e.folderName,
|
|
6868
6877
|
"preview-option-name"
|
|
@@ -6888,7 +6897,7 @@ class eo {
|
|
|
6888
6897
|
fe
|
|
6889
6898
|
);
|
|
6890
6899
|
const be = le("Dimension", "preview-title"), ft = le(
|
|
6891
|
-
`${(st = e == null ? void 0 : e.metadata) == null ? void 0 : st.width} * ${(
|
|
6900
|
+
`${(st = e == null ? void 0 : e.metadata) == null ? void 0 : st.width} * ${(Vt = e == null ? void 0 : e.metadata) == null ? void 0 : Vt.height}`,
|
|
6892
6901
|
"preview-option-name"
|
|
6893
6902
|
);
|
|
6894
6903
|
V.append(
|
|
@@ -6910,7 +6919,7 @@ class eo {
|
|
|
6910
6919
|
e.nestedFolderName,
|
|
6911
6920
|
"preview-option-name"
|
|
6912
6921
|
);
|
|
6913
|
-
|
|
6922
|
+
$.append(
|
|
6914
6923
|
Ne,
|
|
6915
6924
|
ae
|
|
6916
6925
|
), A.append(
|
|
@@ -6918,9 +6927,9 @@ class eo {
|
|
|
6918
6927
|
w,
|
|
6919
6928
|
M,
|
|
6920
6929
|
x,
|
|
6921
|
-
((
|
|
6930
|
+
((hn = e == null ? void 0 : e.metadata) == null ? void 0 : hn.width) > 0 && ((Ht = e == null ? void 0 : e.metadata) == null ? void 0 : Ht.height) > 0 ? V : "",
|
|
6922
6931
|
Z,
|
|
6923
|
-
e.nestedFolderName ?
|
|
6932
|
+
e.nestedFolderName ? $ : ""
|
|
6924
6933
|
), U.append(
|
|
6925
6934
|
_,
|
|
6926
6935
|
A
|
|
@@ -6928,14 +6937,14 @@ class eo {
|
|
|
6928
6937
|
const ne = K("form-control"), me = document.createElement("input");
|
|
6929
6938
|
ne.appendChild(me), me.classList.add("input-field"), me.value = e.name;
|
|
6930
6939
|
const Ie = K("form-control"), ge = le("Current Folder:", "input-label"), Te = K("folder-field current");
|
|
6931
|
-
Te.textContent = e.folderName, Te.prepend(
|
|
6940
|
+
Te.textContent = e.folderName, Te.prepend(en()), Ie.append(ge, Te);
|
|
6932
6941
|
const pe = K("form-control"), ee = K();
|
|
6933
6942
|
ee.style.width = "100%", ee.style.display = "flex", ee.style.alignItems = "center", ee.style.justifyContent = "space-between";
|
|
6934
6943
|
const Re = le(
|
|
6935
6944
|
"Suggested Folder List:",
|
|
6936
6945
|
"input-label"
|
|
6937
6946
|
), Ue = le();
|
|
6938
|
-
Ue.style.display = "flex", Ue.style.alignItems = "center", Ue.style.gap = "5px", Ue.style.fontSize = "14px", Ue.textContent = "Move the file in selected folder", Ue.appendChild(
|
|
6947
|
+
Ue.style.display = "flex", Ue.style.alignItems = "center", Ue.style.gap = "5px", Ue.style.fontSize = "14px", Ue.textContent = "Move the file in selected folder", Ue.appendChild(Dn("14px", "14px", "#333")), ee.append(Re, Ue);
|
|
6939
6948
|
const rt = K();
|
|
6940
6949
|
rt.style.width = "100%", rt.style.maxHeight = "250px", rt.style.overflowY = "auto";
|
|
6941
6950
|
const Ae = document.createElement("ul");
|
|
@@ -6947,7 +6956,7 @@ class eo {
|
|
|
6947
6956
|
"folder-field source",
|
|
6948
6957
|
"source-folder-wrapper"
|
|
6949
6958
|
), xe = document.createElement("span");
|
|
6950
|
-
xe.id = "source-folder-name", xe.textContent = E(this, Lt) ? E(this, Lt) : e.folderName, Ve.append(
|
|
6959
|
+
xe.id = "source-folder-name", xe.textContent = E(this, Lt) ? E(this, Lt) : e.folderName, Ve.append(en(), xe);
|
|
6951
6960
|
let _e = "";
|
|
6952
6961
|
it.append(Le, Ve), me.onchange = (ce) => {
|
|
6953
6962
|
_e = ce.target.value;
|
|
@@ -7033,7 +7042,7 @@ class eo {
|
|
|
7033
7042
|
if (t.classList.contains("checked"))
|
|
7034
7043
|
t.classList.remove("checked"), ce !== -1 && (E(this, ue).splice(ce, 1), E(this, Ft) === 1 && a.remove());
|
|
7035
7044
|
else {
|
|
7036
|
-
if (E(this,
|
|
7045
|
+
if (E(this, Tn))
|
|
7037
7046
|
E(this, ue).push(e);
|
|
7038
7047
|
else {
|
|
7039
7048
|
const ot = document.querySelector(
|
|
@@ -7082,9 +7091,9 @@ class eo {
|
|
|
7082
7091
|
const n = document.createElement("div");
|
|
7083
7092
|
n.style.position = "relative", n.style.display = "flex", n.style.alignItems = "center", n.style.gap = "2px";
|
|
7084
7093
|
const r = document.createElement("span"), i = document.createElement("span");
|
|
7085
|
-
if (i.className = "folder-name", i.textContent = e == null ? void 0 : e.name, r.appendChild(
|
|
7094
|
+
if (i.className = "folder-name", i.textContent = e == null ? void 0 : e.name, r.appendChild(en()), n.append(r, i), t.append(n), e.children && Object.keys(e.children).length > 0) {
|
|
7086
7095
|
const v = document.createElement("button");
|
|
7087
|
-
v.classList.add("expand-icon"), v.appendChild(
|
|
7096
|
+
v.classList.add("expand-icon"), v.appendChild(mn()), n.prepend(v);
|
|
7088
7097
|
const L = document.createElement("ul");
|
|
7089
7098
|
L.className = "folders nested", t.appendChild(L), v.addEventListener("click", (b) => {
|
|
7090
7099
|
b.stopPropagation(), t.classList.toggle("active"), L.classList.toggle("visible");
|
|
@@ -7149,9 +7158,9 @@ class eo {
|
|
|
7149
7158
|
const n = document.createElement("div");
|
|
7150
7159
|
n.style.position = "relative", n.style.display = "flex", n.style.alignItems = "center", n.style.gap = "2px";
|
|
7151
7160
|
const r = document.createElement("span"), i = document.createElement("span");
|
|
7152
|
-
if (i.className = "folder-name", i.textContent = e == null ? void 0 : e.name, r.appendChild(
|
|
7161
|
+
if (i.className = "folder-name", i.textContent = e == null ? void 0 : e.name, r.appendChild(en()), n.append(r, i), t.append(n), e.children && Object.keys(e.children).length > 0) {
|
|
7153
7162
|
const a = document.createElement("button");
|
|
7154
|
-
a.classList.add("expand-icon"), a.appendChild(
|
|
7163
|
+
a.classList.add("expand-icon"), a.appendChild(mn()), n.prepend(a);
|
|
7155
7164
|
const c = document.createElement("ul");
|
|
7156
7165
|
c.className = "folders nested", t.appendChild(c), a.addEventListener("click", (h) => {
|
|
7157
7166
|
h.stopPropagation(), t.classList.toggle("active"), c.classList.toggle("visible");
|
|
@@ -7184,9 +7193,9 @@ class eo {
|
|
|
7184
7193
|
}
|
|
7185
7194
|
_renderToastContainer(e, t, n) {
|
|
7186
7195
|
this._removeToastContainer(), H(this, lt, document.createElement("div")), E(this, lt).className = `message-container ${t}`;
|
|
7187
|
-
const r =
|
|
7196
|
+
const r = tn(e, "message"), i = t === "success" ? wr() : Dn(), o = He("");
|
|
7188
7197
|
o.style.cursor = "pointer", o.style.border = "0", o.style.outline = "none", o.style.background = "transparent", o.appendChild(
|
|
7189
|
-
|
|
7198
|
+
zn(t === "error" ? "#ee3f3f" : "#4caf50")
|
|
7190
7199
|
), o.setAttribute(
|
|
7191
7200
|
"fill",
|
|
7192
7201
|
t === "error" ? "#ee3f3f" : "#4caf50"
|
|
@@ -7200,11 +7209,11 @@ class eo {
|
|
|
7200
7209
|
_updateSelectedImageListContainerUI() {
|
|
7201
7210
|
var t, n;
|
|
7202
7211
|
if (!E(this, Ee)) return;
|
|
7203
|
-
E(this, Ee).innerHTML = "", E(this, Je) && this._renderLoadingUI(), E(this,
|
|
7212
|
+
E(this, Ee).innerHTML = "", E(this, Je) && this._renderLoadingUI(), E(this, $e) && this._renderFetchingSkeletonUI();
|
|
7204
7213
|
const e = document.getElementById(
|
|
7205
7214
|
"search-input-wrapper"
|
|
7206
7215
|
);
|
|
7207
|
-
E(this, Ft) === 0 ? (e && (e.style.visibility = "visible"), ((t = E(this, ke)) == null ? void 0 : t.length) === 0 && !E(this,
|
|
7216
|
+
E(this, Ft) === 0 ? (e && (e.style.visibility = "visible"), ((t = E(this, ke)) == null ? void 0 : t.length) === 0 && !E(this, $e) ? (E(this, Ee).classList.add(
|
|
7208
7217
|
"no-selected-image-container"
|
|
7209
7218
|
), this._renderEmptyImageContainer()) : (E(this, Ee).classList.remove(
|
|
7210
7219
|
"no-selected-image-container"
|
|
@@ -7227,7 +7236,7 @@ class eo {
|
|
|
7227
7236
|
t == null ? void 0 : t.name,
|
|
7228
7237
|
"",
|
|
7229
7238
|
i,
|
|
7230
|
-
Ye[
|
|
7239
|
+
Ye[Vn((n = t.type) == null ? void 0 : n.split("/")[0])],
|
|
7231
7240
|
(r = E(this, De)) == null ? void 0 : r.name,
|
|
7232
7241
|
E(this, Oe)
|
|
7233
7242
|
);
|
|
@@ -7328,7 +7337,7 @@ class eo {
|
|
|
7328
7337
|
}
|
|
7329
7338
|
}
|
|
7330
7339
|
async _upload() {
|
|
7331
|
-
return E(this,
|
|
7340
|
+
return E(this, an) ? E(this, ue) : E(this, qt);
|
|
7332
7341
|
}
|
|
7333
7342
|
async _uploadFromSource(e, t) {
|
|
7334
7343
|
this._removeUserToast();
|
|
@@ -7348,7 +7357,7 @@ class eo {
|
|
|
7348
7357
|
t
|
|
7349
7358
|
), u = await ls(
|
|
7350
7359
|
l,
|
|
7351
|
-
Ye[
|
|
7360
|
+
Ye[Vn((h = r.type) == null ? void 0 : h.split("/")[0])],
|
|
7352
7361
|
t
|
|
7353
7362
|
);
|
|
7354
7363
|
o(u);
|
|
@@ -7366,7 +7375,7 @@ class eo {
|
|
|
7366
7375
|
}
|
|
7367
7376
|
async _fetchFilesFromFolder(e) {
|
|
7368
7377
|
var t, n, r;
|
|
7369
|
-
H(this,
|
|
7378
|
+
H(this, $e, !0), this._updateSelectedImageListContainerUI();
|
|
7370
7379
|
try {
|
|
7371
7380
|
const i = await cs(
|
|
7372
7381
|
e,
|
|
@@ -7384,17 +7393,17 @@ class eo {
|
|
|
7384
7393
|
"Something went wrong. Error while fetching files from folder" + e
|
|
7385
7394
|
);
|
|
7386
7395
|
} finally {
|
|
7387
|
-
H(this,
|
|
7396
|
+
H(this, $e, !1), this._updateSelectedImageListContainerUI();
|
|
7388
7397
|
}
|
|
7389
7398
|
}
|
|
7390
7399
|
async _fetchAllFolders() {
|
|
7391
7400
|
var e, t;
|
|
7392
|
-
H(this,
|
|
7401
|
+
H(this, $e, !0), H(this, Bt, !0), this._updateSelectedImageListContainerUI(), this._updateFolderListContainer(), this._removeToastContainer();
|
|
7393
7402
|
try {
|
|
7394
7403
|
const r = (await Es("", 1e3, E(this, Oe))).response.folder, i = Bs(r);
|
|
7395
7404
|
H(this, kt, (e = i[0]) == null ? void 0 : e.name), this._fetchFilesFromFolder((t = i[0]) == null ? void 0 : t.name), H(this, De, i[0]), H(this, at, i);
|
|
7396
7405
|
} catch {
|
|
7397
|
-
H(this,
|
|
7406
|
+
H(this, $e, !1), this._renderToastContainer(
|
|
7398
7407
|
"Folder not found. Please create a folder or try again later",
|
|
7399
7408
|
"error",
|
|
7400
7409
|
E(this, we)
|
|
@@ -7405,7 +7414,7 @@ class eo {
|
|
|
7405
7414
|
}
|
|
7406
7415
|
async _search(e) {
|
|
7407
7416
|
var t, n;
|
|
7408
|
-
H(this,
|
|
7417
|
+
H(this, $e, !0), this._updateSelectedImageListContainerUI(), this._removeToastContainer();
|
|
7409
7418
|
try {
|
|
7410
7419
|
const r = await ds(
|
|
7411
7420
|
e,
|
|
@@ -7421,7 +7430,7 @@ class eo {
|
|
|
7421
7430
|
E(this, we)
|
|
7422
7431
|
);
|
|
7423
7432
|
} finally {
|
|
7424
|
-
H(this,
|
|
7433
|
+
H(this, $e, !1), this._updateSelectedImageListContainerUI();
|
|
7425
7434
|
}
|
|
7426
7435
|
}
|
|
7427
7436
|
async _updateFolder(e, t) {
|
|
@@ -7471,7 +7480,7 @@ class eo {
|
|
|
7471
7480
|
"div",
|
|
7472
7481
|
"",
|
|
7473
7482
|
"display:flex;align-items:center;gap:5px;"
|
|
7474
|
-
), h = Qs("20px", "20px"), l =
|
|
7483
|
+
), h = Qs("20px", "20px"), l = mn("20px", "20px"), u = mn("20px", "20px"), d = (R = E(this, De)) != null && R.nestedFolderName ? (O = E(this, De)) == null ? void 0 : O.nestedFolderName : "", f = (v = E(this, De)) != null && v.name ? (L = E(this, De)) == null ? void 0 : L.name : "";
|
|
7475
7484
|
d ? c.append(
|
|
7476
7485
|
h,
|
|
7477
7486
|
l,
|
|
@@ -7488,7 +7497,7 @@ class eo {
|
|
|
7488
7497
|
"",
|
|
7489
7498
|
"position:absolute;top:50%;left:5%;transform:translate(-40%,-40%)"
|
|
7490
7499
|
);
|
|
7491
|
-
C.appendChild(
|
|
7500
|
+
C.appendChild(en()), I.classList.add("input-field"), F.append(I, C), t === "update" && (I.value = n.name), I.onchange = (b) => {
|
|
7492
7501
|
i = b.target.value;
|
|
7493
7502
|
}, a.append(
|
|
7494
7503
|
c,
|
|
@@ -7525,7 +7534,7 @@ class eo {
|
|
|
7525
7534
|
this.updateWindowObject({ grpcConfig: r });
|
|
7526
7535
|
}
|
|
7527
7536
|
}
|
|
7528
|
-
mt = new WeakMap(), we = new WeakMap(), Ee = new WeakMap(), gt = new WeakMap(), ue = new WeakMap(), ke = new WeakMap(), Je = new WeakMap(),
|
|
7537
|
+
mt = new WeakMap(), we = new WeakMap(), Ee = new WeakMap(), gt = new WeakMap(), ue = new WeakMap(), ke = new WeakMap(), Je = new WeakMap(), $e = new WeakMap(), Bt = new WeakMap(), kt = new WeakMap(), at = new WeakMap(), De = new WeakMap(), Qe = new WeakMap(), Ot = new WeakMap(), Ft = new WeakMap(), Nt = new WeakMap(), wt = new WeakMap(), St = new WeakMap(), lt = new WeakMap(), Ze = new WeakMap(), It = new WeakMap(), Tt = new WeakMap(), yt = new WeakMap(), jt = new WeakMap(), sn = new WeakMap(), Oe = new WeakMap(), Rt = new WeakMap(), on = new WeakMap(), Tn = new WeakMap(), an = new WeakMap(), ct = new WeakMap(), qt = new WeakMap(), Lt = new WeakMap(), Zt = new WeakMap(), Dt = new WeakMap(), Kt = new WeakMap(), zt = new WeakMap(), Xt = new WeakMap(), ln = new WeakMap(), cn = new WeakMap(), Gt = new WeakMap(), dt = new WeakMap(), Jt = new WeakMap(), dn = new WeakMap(), Qt = new WeakMap();
|
|
7529
7538
|
export {
|
|
7530
7539
|
eo as default
|
|
7531
7540
|
};
|