@designcombo/state 0.1.37 → 0.1.38
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/index.es.js +776 -783
- package/dist/index.umd.js +2 -2
- package/package.json +6 -6
package/dist/index.es.js
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
var Si = Object.defineProperty;
|
2
2
|
var Ei = (t, r, n) => r in t ? Si(t, r, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[r] = n;
|
3
3
|
var Ut = (t, r, n) => Ei(t, typeof r != "symbol" ? r + "" : r, n);
|
4
|
-
import { subject as de, filter as pe, DESIGN_PREFIX as Ti, ADD_PREFIX as
|
4
|
+
import { subject as de, filter as pe, DESIGN_PREFIX as Ti, ADD_PREFIX as ki, LAYER_PREFIX as wi, HISTORY_PREFIX as Ai, ACTIVE_PREFIX as Di, EDIT_PREFIX as Mi, DESIGN_LOAD as Oi, DESIGN_RESIZE as Pi, HISTORY_UNDO as xi, HISTORY_REDO as Ci, LAYER_DELETE as Ri, LAYER_CLONE as Li, ADD_CAPTION as Fi, ADD_TEXT as $i, ADD_TEMPLATE as Ni, ADD_IMAGE as Hi, ADD_AUDIO as ji, ADD_VIDEO as zi, ACTIVE_SPLIT as Ui, ACTIVE_CLONE as Gi, ACTIVE_PASTE as Yi, EDIT_OBJECT as Wi, REPLACE_MEDIA as Xi } from "@designcombo/events";
|
5
5
|
var dn = function(t, r) {
|
6
6
|
return dn = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(n, i) {
|
7
7
|
n.__proto__ = i;
|
@@ -9,7 +9,7 @@ var dn = function(t, r) {
|
|
9
9
|
for (var s in i) Object.prototype.hasOwnProperty.call(i, s) && (n[s] = i[s]);
|
10
10
|
}, dn(t, r);
|
11
11
|
};
|
12
|
-
function
|
12
|
+
function $e(t, r) {
|
13
13
|
if (typeof r != "function" && r !== null)
|
14
14
|
throw new TypeError("Class extends value " + String(r) + " is not a constructor or null");
|
15
15
|
dn(t, r);
|
@@ -34,8 +34,8 @@ function hn(t, r) {
|
|
34
34
|
var i = n.call(t), s, c = [], d;
|
35
35
|
try {
|
36
36
|
for (; (r === void 0 || r-- > 0) && !(s = i.next()).done; ) c.push(s.value);
|
37
|
-
} catch (
|
38
|
-
d = { error:
|
37
|
+
} catch (y) {
|
38
|
+
d = { error: y };
|
39
39
|
} finally {
|
40
40
|
try {
|
41
41
|
s && !s.done && (n = i.return) && n.call(i);
|
@@ -50,7 +50,7 @@ function mn(t, r, n) {
|
|
50
50
|
(c || !(i in r)) && (c || (c = Array.prototype.slice.call(r, 0, i)), c[i] = r[i]);
|
51
51
|
return t.concat(c || Array.prototype.slice.call(r));
|
52
52
|
}
|
53
|
-
function
|
53
|
+
function At(t) {
|
54
54
|
return typeof t == "function";
|
55
55
|
}
|
56
56
|
function Vn(t) {
|
@@ -86,15 +86,15 @@ var mr = function() {
|
|
86
86
|
if (d)
|
87
87
|
if (this._parentage = null, Array.isArray(d))
|
88
88
|
try {
|
89
|
-
for (var
|
90
|
-
var
|
91
|
-
|
89
|
+
for (var y = pn(d), T = y.next(); !T.done; T = y.next()) {
|
90
|
+
var C = T.value;
|
91
|
+
C.remove(this);
|
92
92
|
}
|
93
|
-
} catch (
|
94
|
-
r = { error:
|
93
|
+
} catch (h) {
|
94
|
+
r = { error: h };
|
95
95
|
} finally {
|
96
96
|
try {
|
97
|
-
T && !T.done && (n =
|
97
|
+
T && !T.done && (n = y.return) && n.call(y);
|
98
98
|
} finally {
|
99
99
|
if (r) throw r.error;
|
100
100
|
}
|
@@ -102,11 +102,11 @@ var mr = function() {
|
|
102
102
|
else
|
103
103
|
d.remove(this);
|
104
104
|
var S = this.initialTeardown;
|
105
|
-
if (
|
105
|
+
if (At(S))
|
106
106
|
try {
|
107
107
|
S();
|
108
|
-
} catch (
|
109
|
-
c =
|
108
|
+
} catch (h) {
|
109
|
+
c = h instanceof on ? h.errors : [h];
|
110
110
|
}
|
111
111
|
var F = this._finalizers;
|
112
112
|
if (F) {
|
@@ -116,12 +116,12 @@ var mr = function() {
|
|
116
116
|
var l = f.value;
|
117
117
|
try {
|
118
118
|
Cn(l);
|
119
|
-
} catch (
|
120
|
-
c = c ?? [],
|
119
|
+
} catch (h) {
|
120
|
+
c = c ?? [], h instanceof on ? c = mn(mn([], hn(c)), hn(h.errors)) : c.push(h);
|
121
121
|
}
|
122
122
|
}
|
123
|
-
} catch (
|
124
|
-
i = { error:
|
123
|
+
} catch (h) {
|
124
|
+
i = { error: h };
|
125
125
|
} finally {
|
126
126
|
try {
|
127
127
|
f && !f.done && (s = _.return) && s.call(_);
|
@@ -164,10 +164,10 @@ var mr = function() {
|
|
164
164
|
}(), t;
|
165
165
|
}(), Jn = mr.EMPTY;
|
166
166
|
function Zn(t) {
|
167
|
-
return t instanceof mr || t && "closed" in t &&
|
167
|
+
return t instanceof mr || t && "closed" in t && At(t.remove) && At(t.add) && At(t.unsubscribe);
|
168
168
|
}
|
169
169
|
function Cn(t) {
|
170
|
-
|
170
|
+
At(t) ? t() : t.unsubscribe();
|
171
171
|
}
|
172
172
|
var qn = {
|
173
173
|
onUnhandledError: null,
|
@@ -194,11 +194,11 @@ function Bi(t) {
|
|
194
194
|
}
|
195
195
|
function Rn() {
|
196
196
|
}
|
197
|
-
function
|
197
|
+
function cr(t) {
|
198
198
|
t();
|
199
199
|
}
|
200
200
|
var ti = function(t) {
|
201
|
-
|
201
|
+
$e(r, t);
|
202
202
|
function r(n) {
|
203
203
|
var i = t.call(this) || this;
|
204
204
|
return i.isStopped = !1, n ? (i.destination = n, Zn(n) && n.add(i)) : i.destination = Zi, i;
|
@@ -242,7 +242,7 @@ var Vi = function() {
|
|
242
242
|
try {
|
243
243
|
n.next(r);
|
244
244
|
} catch (i) {
|
245
|
-
|
245
|
+
or(i);
|
246
246
|
}
|
247
247
|
}, t.prototype.error = function(r) {
|
248
248
|
var n = this.partialObserver;
|
@@ -250,44 +250,44 @@ var Vi = function() {
|
|
250
250
|
try {
|
251
251
|
n.error(r);
|
252
252
|
} catch (i) {
|
253
|
-
|
253
|
+
or(i);
|
254
254
|
}
|
255
255
|
else
|
256
|
-
|
256
|
+
or(r);
|
257
257
|
}, t.prototype.complete = function() {
|
258
258
|
var r = this.partialObserver;
|
259
259
|
if (r.complete)
|
260
260
|
try {
|
261
261
|
r.complete();
|
262
262
|
} catch (n) {
|
263
|
-
|
263
|
+
or(n);
|
264
264
|
}
|
265
265
|
}, t;
|
266
266
|
}(), _n = function(t) {
|
267
|
-
|
267
|
+
$e(r, t);
|
268
268
|
function r(n, i, s) {
|
269
269
|
var c = t.call(this) || this, d;
|
270
|
-
if (
|
270
|
+
if (At(n) || !n)
|
271
271
|
d = {
|
272
272
|
next: n ?? void 0,
|
273
273
|
error: i ?? void 0,
|
274
274
|
complete: s ?? void 0
|
275
275
|
};
|
276
276
|
else {
|
277
|
-
var
|
278
|
-
c && qn.useDeprecatedNextContext ? (
|
277
|
+
var y;
|
278
|
+
c && qn.useDeprecatedNextContext ? (y = Object.create(n), y.unsubscribe = function() {
|
279
279
|
return c.unsubscribe();
|
280
280
|
}, d = {
|
281
|
-
next: n.next && cn(n.next,
|
282
|
-
error: n.error && cn(n.error,
|
283
|
-
complete: n.complete && cn(n.complete,
|
281
|
+
next: n.next && cn(n.next, y),
|
282
|
+
error: n.error && cn(n.error, y),
|
283
|
+
complete: n.complete && cn(n.complete, y)
|
284
284
|
}) : d = n;
|
285
285
|
}
|
286
286
|
return c.destination = new Vi(d), c;
|
287
287
|
}
|
288
288
|
return r;
|
289
289
|
}(ti);
|
290
|
-
function
|
290
|
+
function or(t) {
|
291
291
|
Bi(t);
|
292
292
|
}
|
293
293
|
function Ji(t) {
|
@@ -320,9 +320,9 @@ var Ln = function() {
|
|
320
320
|
return n.source = this, n.operator = r, n;
|
321
321
|
}, t.prototype.subscribe = function(r, n, i) {
|
322
322
|
var s = this, c = ra(r) ? r : new _n(r, n, i);
|
323
|
-
return
|
324
|
-
var d = s,
|
325
|
-
c.add(
|
323
|
+
return cr(function() {
|
324
|
+
var d = s, y = d.operator, T = d.source;
|
325
|
+
c.add(y ? y.call(c, T) : T ? s._subscribe(c) : s._trySubscribe(c));
|
326
326
|
}), c;
|
327
327
|
}, t.prototype._trySubscribe = function(r) {
|
328
328
|
try {
|
@@ -334,9 +334,9 @@ var Ln = function() {
|
|
334
334
|
var i = this;
|
335
335
|
return n = Fn(n), new n(function(s, c) {
|
336
336
|
var d = new _n({
|
337
|
-
next: function(
|
337
|
+
next: function(y) {
|
338
338
|
try {
|
339
|
-
r(
|
339
|
+
r(y);
|
340
340
|
} catch (T) {
|
341
341
|
c(T), d.unsubscribe();
|
342
342
|
}
|
@@ -376,7 +376,7 @@ function Fn(t) {
|
|
376
376
|
return (r = t ?? qn.Promise) !== null && r !== void 0 ? r : Promise;
|
377
377
|
}
|
378
378
|
function ea(t) {
|
379
|
-
return t &&
|
379
|
+
return t && At(t.next) && At(t.error) && At(t.complete);
|
380
380
|
}
|
381
381
|
function ra(t) {
|
382
382
|
return t && t instanceof ti || ea(t) && Zn(t);
|
@@ -386,7 +386,7 @@ var na = Vn(function(t) {
|
|
386
386
|
t(this), this.name = "ObjectUnsubscribedError", this.message = "object unsubscribed";
|
387
387
|
};
|
388
388
|
}), ei = function(t) {
|
389
|
-
|
389
|
+
$e(r, t);
|
390
390
|
function r() {
|
391
391
|
var n = t.call(this) || this;
|
392
392
|
return n.closed = !1, n.currentObservers = null, n.observers = [], n.isStopped = !1, n.hasError = !1, n.thrownError = null, n;
|
@@ -399,20 +399,20 @@ var na = Vn(function(t) {
|
|
399
399
|
throw new na();
|
400
400
|
}, r.prototype.next = function(n) {
|
401
401
|
var i = this;
|
402
|
-
|
402
|
+
cr(function() {
|
403
403
|
var s, c;
|
404
404
|
if (i._throwIfClosed(), !i.isStopped) {
|
405
405
|
i.currentObservers || (i.currentObservers = Array.from(i.observers));
|
406
406
|
try {
|
407
|
-
for (var d = pn(i.currentObservers),
|
408
|
-
var T =
|
407
|
+
for (var d = pn(i.currentObservers), y = d.next(); !y.done; y = d.next()) {
|
408
|
+
var T = y.value;
|
409
409
|
T.next(n);
|
410
410
|
}
|
411
|
-
} catch (
|
412
|
-
s = { error:
|
411
|
+
} catch (C) {
|
412
|
+
s = { error: C };
|
413
413
|
} finally {
|
414
414
|
try {
|
415
|
-
|
415
|
+
y && !y.done && (c = d.return) && c.call(d);
|
416
416
|
} finally {
|
417
417
|
if (s) throw s.error;
|
418
418
|
}
|
@@ -421,7 +421,7 @@ var na = Vn(function(t) {
|
|
421
421
|
});
|
422
422
|
}, r.prototype.error = function(n) {
|
423
423
|
var i = this;
|
424
|
-
|
424
|
+
cr(function() {
|
425
425
|
if (i._throwIfClosed(), !i.isStopped) {
|
426
426
|
i.hasError = i.isStopped = !0, i.thrownError = n;
|
427
427
|
for (var s = i.observers; s.length; )
|
@@ -430,7 +430,7 @@ var na = Vn(function(t) {
|
|
430
430
|
});
|
431
431
|
}, r.prototype.complete = function() {
|
432
432
|
var n = this;
|
433
|
-
|
433
|
+
cr(function() {
|
434
434
|
if (n._throwIfClosed(), !n.isStopped) {
|
435
435
|
n.isStopped = !0;
|
436
436
|
for (var i = n.observers; i.length; )
|
@@ -451,9 +451,9 @@ var na = Vn(function(t) {
|
|
451
451
|
}, r.prototype._subscribe = function(n) {
|
452
452
|
return this._throwIfClosed(), this._checkFinalizedStatuses(n), this._innerSubscribe(n);
|
453
453
|
}, r.prototype._innerSubscribe = function(n) {
|
454
|
-
var i = this, s = this, c = s.hasError, d = s.isStopped,
|
455
|
-
return c || d ? Jn : (this.currentObservers = null,
|
456
|
-
i.currentObservers = null, yn(
|
454
|
+
var i = this, s = this, c = s.hasError, d = s.isStopped, y = s.observers;
|
455
|
+
return c || d ? Jn : (this.currentObservers = null, y.push(n), new mr(function() {
|
456
|
+
i.currentObservers = null, yn(y, n);
|
457
457
|
}));
|
458
458
|
}, r.prototype._checkFinalizedStatuses = function(n) {
|
459
459
|
var i = this, s = i.hasError, c = i.thrownError, d = i.isStopped;
|
@@ -465,7 +465,7 @@ var na = Vn(function(t) {
|
|
465
465
|
return new $n(n, i);
|
466
466
|
}, r;
|
467
467
|
}(Ln), $n = function(t) {
|
468
|
-
|
468
|
+
$e(r, t);
|
469
469
|
function r(n, i) {
|
470
470
|
var s = t.call(this) || this;
|
471
471
|
return s.destination = n, s.source = i, s;
|
@@ -484,7 +484,7 @@ var na = Vn(function(t) {
|
|
484
484
|
return (s = (i = this.source) === null || i === void 0 ? void 0 : i.subscribe(n)) !== null && s !== void 0 ? s : Jn;
|
485
485
|
}, r;
|
486
486
|
}(ei), Nn = function(t) {
|
487
|
-
|
487
|
+
$e(r, t);
|
488
488
|
function r(n) {
|
489
489
|
var i = t.call(this) || this;
|
490
490
|
return i._value = n, i;
|
@@ -506,34 +506,34 @@ var na = Vn(function(t) {
|
|
506
506
|
}, r.prototype.next = function(n) {
|
507
507
|
t.prototype.next.call(this, this._value = n);
|
508
508
|
}, r;
|
509
|
-
}(ei),
|
510
|
-
function
|
509
|
+
}(ei), ht = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
510
|
+
function kn(t) {
|
511
511
|
return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
|
512
512
|
}
|
513
513
|
var lr = { exports: {} };
|
514
514
|
lr.exports;
|
515
515
|
(function(t, r) {
|
516
|
-
var n = 200, i = "__lodash_hash_undefined__", s = 1, c = 2, d = 9007199254740991,
|
517
|
-
H[
|
518
|
-
var U = typeof
|
516
|
+
var n = 200, i = "__lodash_hash_undefined__", s = 1, c = 2, d = 9007199254740991, y = "[object Arguments]", T = "[object Array]", C = "[object AsyncFunction]", S = "[object Boolean]", F = "[object Date]", _ = "[object Error]", f = "[object Function]", l = "[object GeneratorFunction]", h = "[object Map]", g = "[object Number]", I = "[object Null]", b = "[object Object]", p = "[object Promise]", m = "[object Proxy]", k = "[object RegExp]", O = "[object Set]", w = "[object String]", x = "[object Symbol]", R = "[object Undefined]", P = "[object WeakMap]", E = "[object ArrayBuffer]", D = "[object DataView]", z = "[object Float32Array]", Pt = "[object Float64Array]", xt = "[object Int8Array]", Vt = "[object Int16Array]", Jt = "[object Int32Array]", Zt = "[object Uint8Array]", qt = "[object Uint8ClampedArray]", N = "[object Uint16Array]", Qt = "[object Uint32Array]", te = /[\\^$.*+?()[\]{}|]/g, at = /^\[object .+?Constructor\]$/, Ct = /^(?:0|[1-9]\d*)$/, H = {};
|
517
|
+
H[z] = H[Pt] = H[xt] = H[Vt] = H[Jt] = H[Zt] = H[qt] = H[N] = H[Qt] = !0, H[y] = H[T] = H[E] = H[S] = H[D] = H[F] = H[_] = H[f] = H[h] = H[g] = H[b] = H[k] = H[O] = H[w] = H[P] = !1;
|
518
|
+
var U = typeof ht == "object" && ht && ht.Object === Object && ht, G = typeof self == "object" && self && self.Object === Object && self, M = U || G || Function("return this")(), ut = r && !r.nodeType && r, rt = ut && !0 && t && !t.nodeType && t, K = rt && rt.exports === ut, lt = K && U.process, V = function() {
|
519
519
|
try {
|
520
|
-
return
|
520
|
+
return lt && lt.binding && lt.binding("util");
|
521
521
|
} catch {
|
522
522
|
}
|
523
523
|
}(), Y = V && V.isTypedArray;
|
524
|
-
function
|
525
|
-
for (var o = -1, u = e == null ? 0 : e.length,
|
524
|
+
function It(e, a) {
|
525
|
+
for (var o = -1, u = e == null ? 0 : e.length, A = 0, v = []; ++o < u; ) {
|
526
526
|
var $ = e[o];
|
527
|
-
a($, o, e) && (v[
|
527
|
+
a($, o, e) && (v[A++] = $);
|
528
528
|
}
|
529
529
|
return v;
|
530
530
|
}
|
531
531
|
function Rt(e, a) {
|
532
|
-
for (var o = -1, u = a.length,
|
533
|
-
e[
|
532
|
+
for (var o = -1, u = a.length, A = e.length; ++o < u; )
|
533
|
+
e[A + o] = a[o];
|
534
534
|
return e;
|
535
535
|
}
|
536
|
-
function
|
536
|
+
function Ue(e, a) {
|
537
537
|
for (var o = -1, u = e == null ? 0 : e.length; ++o < u; )
|
538
538
|
if (a(e[o], o, e))
|
539
539
|
return !0;
|
@@ -552,32 +552,32 @@ lr.exports;
|
|
552
552
|
function ee(e, a) {
|
553
553
|
return e.has(a);
|
554
554
|
}
|
555
|
-
function
|
555
|
+
function _e(e, a) {
|
556
556
|
return e == null ? void 0 : e[a];
|
557
557
|
}
|
558
|
-
function
|
558
|
+
function Ge(e) {
|
559
559
|
var a = -1, o = Array(e.size);
|
560
|
-
return e.forEach(function(u,
|
561
|
-
o[++a] = [
|
560
|
+
return e.forEach(function(u, A) {
|
561
|
+
o[++a] = [A, u];
|
562
562
|
}), o;
|
563
563
|
}
|
564
|
-
function
|
564
|
+
function Ye(e, a) {
|
565
565
|
return function(o) {
|
566
566
|
return e(a(o));
|
567
567
|
};
|
568
568
|
}
|
569
|
-
function
|
569
|
+
function gt(e) {
|
570
570
|
var a = -1, o = Array(e.size);
|
571
571
|
return e.forEach(function(u) {
|
572
572
|
o[++a] = u;
|
573
573
|
}), o;
|
574
574
|
}
|
575
|
-
var re = Array.prototype, vr = Function.prototype, Lt = Object.prototype, ne =
|
575
|
+
var re = Array.prototype, vr = Function.prototype, Lt = Object.prototype, ne = M["__core-js_shared__"], Ie = vr.toString, pt = Lt.hasOwnProperty, We = function() {
|
576
576
|
var e = /[^.]+$/.exec(ne && ne.keys && ne.keys.IE_PROTO || "");
|
577
577
|
return e ? "Symbol(src)_1." + e : "";
|
578
|
-
}(),
|
579
|
-
"^" +
|
580
|
-
),
|
578
|
+
}(), Xe = Lt.toString, Sr = RegExp(
|
579
|
+
"^" + Ie.call(pt).replace(te, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
|
580
|
+
), ge = K ? M.Buffer : void 0, ie = M.Symbol, Be = M.Uint8Array, ae = Lt.propertyIsEnumerable, Ft = re.splice, mt = ie ? ie.toStringTag : void 0, se = Object.getOwnPropertySymbols, be = ge ? ge.isBuffer : void 0, $t = Ye(Object.keys, Object), ve = Tt(M, "DataView"), Nt = Tt(M, "Map"), Se = Tt(M, "Promise"), Ee = Tt(M, "Set"), Te = Tt(M, "WeakMap"), Dt = Tt(Object, "create"), Ke = nt(ve), Et = nt(Nt), Er = nt(Se), Tr = nt(Ee), kr = nt(Te), Ve = ie ? ie.prototype : void 0, ke = Ve ? Ve.valueOf : void 0;
|
581
581
|
function J(e) {
|
582
582
|
var a = -1, o = e == null ? 0 : e.length;
|
583
583
|
for (this.clear(); ++a < o; ) {
|
@@ -585,8 +585,8 @@ lr.exports;
|
|
585
585
|
this.set(u[0], u[1]);
|
586
586
|
}
|
587
587
|
}
|
588
|
-
function
|
589
|
-
this.__data__ =
|
588
|
+
function wr() {
|
589
|
+
this.__data__ = Dt ? Dt(null) : {}, this.size = 0;
|
590
590
|
}
|
591
591
|
function Ar(e) {
|
592
592
|
var a = this.has(e) && delete this.__data__[e];
|
@@ -594,21 +594,21 @@ lr.exports;
|
|
594
594
|
}
|
595
595
|
function Dr(e) {
|
596
596
|
var a = this.__data__;
|
597
|
-
if (
|
597
|
+
if (Dt) {
|
598
598
|
var o = a[e];
|
599
599
|
return o === i ? void 0 : o;
|
600
600
|
}
|
601
|
-
return
|
601
|
+
return pt.call(a, e) ? a[e] : void 0;
|
602
602
|
}
|
603
603
|
function Mr(e) {
|
604
604
|
var a = this.__data__;
|
605
|
-
return
|
605
|
+
return Dt ? a[e] !== void 0 : pt.call(a, e);
|
606
606
|
}
|
607
607
|
function Or(e, a) {
|
608
608
|
var o = this.__data__;
|
609
|
-
return this.size += this.has(e) ? 0 : 1, o[e] =
|
609
|
+
return this.size += this.has(e) ? 0 : 1, o[e] = Dt && a === void 0 ? i : a, this;
|
610
610
|
}
|
611
|
-
J.prototype.clear =
|
611
|
+
J.prototype.clear = wr, J.prototype.delete = Ar, J.prototype.get = Dr, J.prototype.has = Mr, J.prototype.set = Or;
|
612
612
|
function q(e) {
|
613
613
|
var a = -1, o = e == null ? 0 : e.length;
|
614
614
|
for (this.clear(); ++a < o; ) {
|
@@ -616,10 +616,10 @@ lr.exports;
|
|
616
616
|
this.set(u[0], u[1]);
|
617
617
|
}
|
618
618
|
}
|
619
|
-
function
|
619
|
+
function Pr() {
|
620
620
|
this.__data__ = [], this.size = 0;
|
621
621
|
}
|
622
|
-
function
|
622
|
+
function xr(e) {
|
623
623
|
var a = this.__data__, o = ue(a, e);
|
624
624
|
if (o < 0)
|
625
625
|
return !1;
|
@@ -637,7 +637,7 @@ lr.exports;
|
|
637
637
|
var o = this.__data__, u = ue(o, e);
|
638
638
|
return u < 0 ? (++this.size, o.push([e, a])) : o[u][1] = a, this;
|
639
639
|
}
|
640
|
-
q.prototype.clear =
|
640
|
+
q.prototype.clear = Pr, q.prototype.delete = xr, q.prototype.get = Cr, q.prototype.has = Rr, q.prototype.set = Lr;
|
641
641
|
function st(e) {
|
642
642
|
var a = -1, o = e == null ? 0 : e.length;
|
643
643
|
for (this.clear(); ++a < o; ) {
|
@@ -653,40 +653,40 @@ lr.exports;
|
|
653
653
|
};
|
654
654
|
}
|
655
655
|
function $r(e) {
|
656
|
-
var a =
|
656
|
+
var a = yt(this, e).delete(e);
|
657
657
|
return this.size -= a ? 1 : 0, a;
|
658
658
|
}
|
659
659
|
function Nr(e) {
|
660
|
-
return
|
660
|
+
return yt(this, e).get(e);
|
661
661
|
}
|
662
662
|
function Hr(e) {
|
663
|
-
return
|
663
|
+
return yt(this, e).has(e);
|
664
664
|
}
|
665
|
-
function
|
666
|
-
var o =
|
665
|
+
function jr(e, a) {
|
666
|
+
var o = yt(this, e), u = o.size;
|
667
667
|
return o.set(e, a), this.size += o.size == u ? 0 : 1, this;
|
668
668
|
}
|
669
|
-
st.prototype.clear = Fr, st.prototype.delete = $r, st.prototype.get = Nr, st.prototype.has = Hr, st.prototype.set =
|
669
|
+
st.prototype.clear = Fr, st.prototype.delete = $r, st.prototype.get = Nr, st.prototype.has = Hr, st.prototype.set = jr;
|
670
670
|
function oe(e) {
|
671
671
|
var a = -1, o = e == null ? 0 : e.length;
|
672
672
|
for (this.__data__ = new st(); ++a < o; )
|
673
673
|
this.add(e[a]);
|
674
674
|
}
|
675
|
-
function
|
675
|
+
function Je(e) {
|
676
676
|
return this.__data__.set(e, i), this;
|
677
677
|
}
|
678
678
|
function ce(e) {
|
679
679
|
return this.__data__.has(e);
|
680
680
|
}
|
681
|
-
oe.prototype.add = oe.prototype.push =
|
682
|
-
function
|
681
|
+
oe.prototype.add = oe.prototype.push = Je, oe.prototype.has = ce;
|
682
|
+
function bt(e) {
|
683
683
|
var a = this.__data__ = new q(e);
|
684
684
|
this.size = a.size;
|
685
685
|
}
|
686
686
|
function we() {
|
687
687
|
this.__data__ = new q(), this.size = 0;
|
688
688
|
}
|
689
|
-
function
|
689
|
+
function zr(e) {
|
690
690
|
var a = this.__data__, o = a.delete(e);
|
691
691
|
return this.size = a.size, o;
|
692
692
|
}
|
@@ -706,148 +706,148 @@ lr.exports;
|
|
706
706
|
}
|
707
707
|
return o.set(e, a), this.size = o.size, this;
|
708
708
|
}
|
709
|
-
|
709
|
+
bt.prototype.clear = we, bt.prototype.delete = zr, bt.prototype.get = Ur, bt.prototype.has = Gr, bt.prototype.set = Yr;
|
710
710
|
function Wr(e, a) {
|
711
|
-
var o = le(e), u = !o &&
|
712
|
-
for (var
|
713
|
-
|
714
|
-
(
|
715
|
-
|
716
|
-
v && (
|
717
|
-
Qr(
|
711
|
+
var o = le(e), u = !o && er(e), A = !o && !u && fe(e), v = !o && !u && !A && ir(e), $ = o || u || A || v, L = $ ? gr(e.length, String) : [], W = L.length;
|
712
|
+
for (var j in e)
|
713
|
+
pt.call(e, j) && !($ && // Safari 9 has enumerable `arguments.length` in strict mode.
|
714
|
+
(j == "length" || // Node.js 0.10 has enumerable non-index properties on buffers.
|
715
|
+
A && (j == "offset" || j == "parent") || // PhantomJS 2 has enumerable non-index properties on typed arrays.
|
716
|
+
v && (j == "buffer" || j == "byteLength" || j == "byteOffset") || // Skip index properties.
|
717
|
+
Qr(j, W))) && L.push(j);
|
718
718
|
return L;
|
719
719
|
}
|
720
720
|
function ue(e, a) {
|
721
721
|
for (var o = e.length; o--; )
|
722
|
-
if (
|
722
|
+
if (tr(e[o][0], a))
|
723
723
|
return o;
|
724
724
|
return -1;
|
725
725
|
}
|
726
|
-
function
|
726
|
+
function Ae(e, a, o) {
|
727
727
|
var u = a(e);
|
728
728
|
return le(e) ? u : Rt(u, o(e));
|
729
729
|
}
|
730
730
|
function Ht(e) {
|
731
|
-
return e == null ? e === void 0 ?
|
731
|
+
return e == null ? e === void 0 ? R : I : mt && mt in Object(e) ? kt(e) : Qe(e);
|
732
732
|
}
|
733
|
-
function
|
734
|
-
return
|
733
|
+
function Ze(e) {
|
734
|
+
return St(e) && Ht(e) == y;
|
735
735
|
}
|
736
|
-
function
|
737
|
-
return e === a ? !0 : e == null || a == null || !
|
736
|
+
function qe(e, a, o, u, A) {
|
737
|
+
return e === a ? !0 : e == null || a == null || !St(e) && !St(a) ? e !== e && a !== a : Xr(e, a, o, u, qe, A);
|
738
738
|
}
|
739
|
-
function Xr(e, a, o, u,
|
740
|
-
var $ = le(e), L = le(a), W = $ ? T :
|
741
|
-
W = W ==
|
742
|
-
var Q = W == b, ot =
|
739
|
+
function Xr(e, a, o, u, A, v) {
|
740
|
+
var $ = le(e), L = le(a), W = $ ? T : vt(e), j = L ? T : vt(a);
|
741
|
+
W = W == y ? b : W, j = j == y ? b : j;
|
742
|
+
var Q = W == b, ot = j == b, X = W == j;
|
743
743
|
if (X && fe(e)) {
|
744
744
|
if (!fe(a))
|
745
745
|
return !1;
|
746
746
|
$ = !0, Q = !1;
|
747
747
|
}
|
748
748
|
if (X && !Q)
|
749
|
-
return v || (v = new
|
749
|
+
return v || (v = new bt()), $ || ir(e) ? De(e, a, o, u, A, v) : Jr(e, a, W, o, u, A, v);
|
750
750
|
if (!(o & s)) {
|
751
|
-
var tt = Q &&
|
751
|
+
var tt = Q && pt.call(e, "__wrapped__"), Z = ot && pt.call(a, "__wrapped__");
|
752
752
|
if (tt || Z) {
|
753
|
-
var
|
754
|
-
return v || (v = new
|
753
|
+
var Mt = tt ? e.value() : e, wt = Z ? a.value() : a;
|
754
|
+
return v || (v = new bt()), A(Mt, wt, o, u, v);
|
755
755
|
}
|
756
756
|
}
|
757
|
-
return X ? (v || (v = new
|
757
|
+
return X ? (v || (v = new bt()), Zr(e, a, o, u, A, v)) : !1;
|
758
758
|
}
|
759
759
|
function Br(e) {
|
760
|
-
if (!
|
760
|
+
if (!nr(e) || en(e))
|
761
761
|
return !1;
|
762
|
-
var a =
|
762
|
+
var a = rr(e) ? Sr : at;
|
763
763
|
return a.test(nt(e));
|
764
764
|
}
|
765
765
|
function Kr(e) {
|
766
|
-
return
|
766
|
+
return St(e) && Oe(e.length) && !!H[Ht(e)];
|
767
767
|
}
|
768
768
|
function Vr(e) {
|
769
769
|
if (!rn(e))
|
770
770
|
return $t(e);
|
771
771
|
var a = [];
|
772
772
|
for (var o in Object(e))
|
773
|
-
|
773
|
+
pt.call(e, o) && o != "constructor" && a.push(o);
|
774
774
|
return a;
|
775
775
|
}
|
776
|
-
function
|
776
|
+
function De(e, a, o, u, A, v) {
|
777
777
|
var $ = o & s, L = e.length, W = a.length;
|
778
778
|
if (L != W && !($ && W > L))
|
779
779
|
return !1;
|
780
|
-
var
|
781
|
-
if (
|
782
|
-
return
|
780
|
+
var j = v.get(e);
|
781
|
+
if (j && v.get(a))
|
782
|
+
return j == a;
|
783
783
|
var Q = -1, ot = !0, X = o & c ? new oe() : void 0;
|
784
784
|
for (v.set(e, a), v.set(a, e); ++Q < L; ) {
|
785
785
|
var tt = e[Q], Z = a[Q];
|
786
786
|
if (u)
|
787
|
-
var
|
788
|
-
if (
|
789
|
-
if (
|
787
|
+
var Mt = $ ? u(Z, tt, Q, a, e, v) : u(tt, Z, Q, e, a, v);
|
788
|
+
if (Mt !== void 0) {
|
789
|
+
if (Mt)
|
790
790
|
continue;
|
791
791
|
ot = !1;
|
792
792
|
break;
|
793
793
|
}
|
794
794
|
if (X) {
|
795
|
-
if (!
|
796
|
-
if (!ee(X,
|
797
|
-
return X.push(
|
795
|
+
if (!Ue(a, function(wt, zt) {
|
796
|
+
if (!ee(X, zt) && (tt === wt || A(tt, wt, o, u, v)))
|
797
|
+
return X.push(zt);
|
798
798
|
})) {
|
799
799
|
ot = !1;
|
800
800
|
break;
|
801
801
|
}
|
802
|
-
} else if (!(tt === Z ||
|
802
|
+
} else if (!(tt === Z || A(tt, Z, o, u, v))) {
|
803
803
|
ot = !1;
|
804
804
|
break;
|
805
805
|
}
|
806
806
|
}
|
807
807
|
return v.delete(e), v.delete(a), ot;
|
808
808
|
}
|
809
|
-
function Jr(e, a, o, u,
|
809
|
+
function Jr(e, a, o, u, A, v, $) {
|
810
810
|
switch (o) {
|
811
|
-
case
|
811
|
+
case D:
|
812
812
|
if (e.byteLength != a.byteLength || e.byteOffset != a.byteOffset)
|
813
813
|
return !1;
|
814
814
|
e = e.buffer, a = a.buffer;
|
815
|
-
case
|
816
|
-
return !(e.byteLength != a.byteLength || !v(new
|
815
|
+
case E:
|
816
|
+
return !(e.byteLength != a.byteLength || !v(new Be(e), new Be(a)));
|
817
817
|
case S:
|
818
818
|
case F:
|
819
819
|
case g:
|
820
|
-
return
|
820
|
+
return tr(+e, +a);
|
821
821
|
case _:
|
822
822
|
return e.name == a.name && e.message == a.message;
|
823
|
-
case
|
823
|
+
case k:
|
824
824
|
case w:
|
825
825
|
return e == a + "";
|
826
|
-
case
|
827
|
-
var L =
|
828
|
-
case
|
826
|
+
case h:
|
827
|
+
var L = Ge;
|
828
|
+
case O:
|
829
829
|
var W = u & s;
|
830
|
-
if (L || (L =
|
830
|
+
if (L || (L = gt), e.size != a.size && !W)
|
831
831
|
return !1;
|
832
|
-
var
|
833
|
-
if (
|
834
|
-
return
|
832
|
+
var j = $.get(e);
|
833
|
+
if (j)
|
834
|
+
return j == a;
|
835
835
|
u |= c, $.set(e, a);
|
836
|
-
var Q =
|
836
|
+
var Q = De(L(e), L(a), u, A, v, $);
|
837
837
|
return $.delete(e), Q;
|
838
838
|
case x:
|
839
|
-
if (
|
840
|
-
return
|
839
|
+
if (ke)
|
840
|
+
return ke.call(e) == ke.call(a);
|
841
841
|
}
|
842
842
|
return !1;
|
843
843
|
}
|
844
|
-
function Zr(e, a, o, u,
|
845
|
-
var $ = o & s, L =
|
844
|
+
function Zr(e, a, o, u, A, v) {
|
845
|
+
var $ = o & s, L = jt(e), W = L.length, j = jt(a), Q = j.length;
|
846
846
|
if (W != Q && !$)
|
847
847
|
return !1;
|
848
848
|
for (var ot = W; ot--; ) {
|
849
849
|
var X = L[ot];
|
850
|
-
if (!($ ? X in a :
|
850
|
+
if (!($ ? X in a : pt.call(a, X)))
|
851
851
|
return !1;
|
852
852
|
}
|
853
853
|
var tt = v.get(e);
|
@@ -855,62 +855,62 @@ lr.exports;
|
|
855
855
|
return tt == a;
|
856
856
|
var Z = !0;
|
857
857
|
v.set(e, a), v.set(a, e);
|
858
|
-
for (var
|
858
|
+
for (var Mt = $; ++ot < W; ) {
|
859
859
|
X = L[ot];
|
860
|
-
var
|
860
|
+
var wt = e[X], zt = a[X];
|
861
861
|
if (u)
|
862
|
-
var
|
863
|
-
if (!(
|
862
|
+
var xn = $ ? u(zt, wt, X, a, e, v) : u(wt, zt, X, e, a, v);
|
863
|
+
if (!(xn === void 0 ? wt === zt || A(wt, zt, o, u, v) : xn)) {
|
864
864
|
Z = !1;
|
865
865
|
break;
|
866
866
|
}
|
867
|
-
|
867
|
+
Mt || (Mt = X == "constructor");
|
868
868
|
}
|
869
|
-
if (Z && !
|
870
|
-
var
|
871
|
-
|
869
|
+
if (Z && !Mt) {
|
870
|
+
var ar = e.constructor, sr = a.constructor;
|
871
|
+
ar != sr && "constructor" in e && "constructor" in a && !(typeof ar == "function" && ar instanceof ar && typeof sr == "function" && sr instanceof sr) && (Z = !1);
|
872
872
|
}
|
873
873
|
return v.delete(e), v.delete(a), Z;
|
874
874
|
}
|
875
|
-
function
|
876
|
-
return
|
875
|
+
function jt(e) {
|
876
|
+
return Ae(e, Pe, qr);
|
877
877
|
}
|
878
|
-
function
|
878
|
+
function yt(e, a) {
|
879
879
|
var o = e.__data__;
|
880
880
|
return tn(a) ? o[typeof a == "string" ? "string" : "hash"] : o.map;
|
881
881
|
}
|
882
|
-
function
|
883
|
-
var o =
|
882
|
+
function Tt(e, a) {
|
883
|
+
var o = _e(e, a);
|
884
884
|
return Br(o) ? o : void 0;
|
885
885
|
}
|
886
886
|
function kt(e) {
|
887
|
-
var a =
|
887
|
+
var a = pt.call(e, mt), o = e[mt];
|
888
888
|
try {
|
889
|
-
e[
|
889
|
+
e[mt] = void 0;
|
890
890
|
var u = !0;
|
891
891
|
} catch {
|
892
892
|
}
|
893
|
-
var
|
894
|
-
return u && (a ? e[
|
893
|
+
var A = Xe.call(e);
|
894
|
+
return u && (a ? e[mt] = o : delete e[mt]), A;
|
895
895
|
}
|
896
896
|
var qr = se ? function(e) {
|
897
|
-
return e == null ? [] : (e = Object(e),
|
897
|
+
return e == null ? [] : (e = Object(e), It(se(e), function(a) {
|
898
898
|
return ae.call(e, a);
|
899
899
|
}));
|
900
|
-
} : an,
|
901
|
-
(
|
900
|
+
} : an, vt = Ht;
|
901
|
+
(ve && vt(new ve(new ArrayBuffer(1))) != D || Nt && vt(new Nt()) != h || Se && vt(Se.resolve()) != p || Ee && vt(new Ee()) != O || Te && vt(new Te()) != P) && (vt = function(e) {
|
902
902
|
var a = Ht(e), o = a == b ? e.constructor : void 0, u = o ? nt(o) : "";
|
903
903
|
if (u)
|
904
904
|
switch (u) {
|
905
|
-
case
|
906
|
-
return
|
907
|
-
case
|
908
|
-
return
|
905
|
+
case Ke:
|
906
|
+
return D;
|
907
|
+
case Et:
|
908
|
+
return h;
|
909
909
|
case Er:
|
910
|
-
return
|
910
|
+
return p;
|
911
911
|
case Tr:
|
912
|
-
return
|
913
|
-
case
|
912
|
+
return O;
|
913
|
+
case kr:
|
914
914
|
return P;
|
915
915
|
}
|
916
916
|
return a;
|
@@ -923,19 +923,19 @@ lr.exports;
|
|
923
923
|
return a == "string" || a == "number" || a == "symbol" || a == "boolean" ? e !== "__proto__" : e === null;
|
924
924
|
}
|
925
925
|
function en(e) {
|
926
|
-
return !!
|
926
|
+
return !!We && We in e;
|
927
927
|
}
|
928
928
|
function rn(e) {
|
929
929
|
var a = e && e.constructor, o = typeof a == "function" && a.prototype || Lt;
|
930
930
|
return e === o;
|
931
931
|
}
|
932
|
-
function
|
933
|
-
return
|
932
|
+
function Qe(e) {
|
933
|
+
return Xe.call(e);
|
934
934
|
}
|
935
935
|
function nt(e) {
|
936
936
|
if (e != null) {
|
937
937
|
try {
|
938
|
-
return
|
938
|
+
return Ie.call(e);
|
939
939
|
} catch {
|
940
940
|
}
|
941
941
|
try {
|
@@ -945,40 +945,40 @@ lr.exports;
|
|
945
945
|
}
|
946
946
|
return "";
|
947
947
|
}
|
948
|
-
function
|
948
|
+
function tr(e, a) {
|
949
949
|
return e === a || e !== e && a !== a;
|
950
950
|
}
|
951
|
-
var
|
951
|
+
var er = Ze(/* @__PURE__ */ function() {
|
952
952
|
return arguments;
|
953
|
-
}()) ?
|
954
|
-
return
|
953
|
+
}()) ? Ze : function(e) {
|
954
|
+
return St(e) && pt.call(e, "callee") && !ae.call(e, "callee");
|
955
955
|
}, le = Array.isArray;
|
956
|
-
function
|
957
|
-
return e != null &&
|
956
|
+
function Me(e) {
|
957
|
+
return e != null && Oe(e.length) && !rr(e);
|
958
958
|
}
|
959
|
-
var fe =
|
959
|
+
var fe = be || sn;
|
960
960
|
function nn(e, a) {
|
961
|
-
return
|
961
|
+
return qe(e, a);
|
962
962
|
}
|
963
|
-
function
|
964
|
-
if (!
|
963
|
+
function rr(e) {
|
964
|
+
if (!nr(e))
|
965
965
|
return !1;
|
966
966
|
var a = Ht(e);
|
967
|
-
return a == f || a == l || a ==
|
967
|
+
return a == f || a == l || a == C || a == m;
|
968
968
|
}
|
969
|
-
function
|
969
|
+
function Oe(e) {
|
970
970
|
return typeof e == "number" && e > -1 && e % 1 == 0 && e <= d;
|
971
971
|
}
|
972
|
-
function
|
972
|
+
function nr(e) {
|
973
973
|
var a = typeof e;
|
974
974
|
return e != null && (a == "object" || a == "function");
|
975
975
|
}
|
976
|
-
function
|
976
|
+
function St(e) {
|
977
977
|
return e != null && typeof e == "object";
|
978
978
|
}
|
979
|
-
var
|
980
|
-
function
|
981
|
-
return
|
979
|
+
var ir = Y ? br(Y) : Kr;
|
980
|
+
function Pe(e) {
|
981
|
+
return Me(e) ? Wr(e) : Vr(e);
|
982
982
|
}
|
983
983
|
function an() {
|
984
984
|
return [];
|
@@ -989,35 +989,35 @@ lr.exports;
|
|
989
989
|
t.exports = nn;
|
990
990
|
})(lr, lr.exports);
|
991
991
|
var ia = lr.exports;
|
992
|
-
const it = /* @__PURE__ */
|
992
|
+
const it = /* @__PURE__ */ kn(ia);
|
993
993
|
var fr = { exports: {} };
|
994
994
|
fr.exports;
|
995
995
|
(function(t, r) {
|
996
|
-
var n = 200, i = "__lodash_hash_undefined__", s = 9007199254740991, c = "[object Arguments]", d = "[object Array]",
|
997
|
-
N[c] = N[d] = N[
|
998
|
-
var Qt = typeof
|
996
|
+
var n = 200, i = "__lodash_hash_undefined__", s = 9007199254740991, c = "[object Arguments]", d = "[object Array]", y = "[object Boolean]", T = "[object Date]", C = "[object Error]", S = "[object Function]", F = "[object GeneratorFunction]", _ = "[object Map]", f = "[object Number]", l = "[object Object]", h = "[object Promise]", g = "[object RegExp]", I = "[object Set]", b = "[object String]", p = "[object Symbol]", m = "[object WeakMap]", k = "[object ArrayBuffer]", O = "[object DataView]", w = "[object Float32Array]", x = "[object Float64Array]", R = "[object Int8Array]", P = "[object Int16Array]", E = "[object Int32Array]", D = "[object Uint8Array]", z = "[object Uint8ClampedArray]", Pt = "[object Uint16Array]", xt = "[object Uint32Array]", Vt = /[\\^$.*+?()[\]{}|]/g, Jt = /\w*$/, Zt = /^\[object .+?Constructor\]$/, qt = /^(?:0|[1-9]\d*)$/, N = {};
|
997
|
+
N[c] = N[d] = N[k] = N[O] = N[y] = N[T] = N[w] = N[x] = N[R] = N[P] = N[E] = N[_] = N[f] = N[l] = N[g] = N[I] = N[b] = N[p] = N[D] = N[z] = N[Pt] = N[xt] = !0, N[C] = N[S] = N[m] = !1;
|
998
|
+
var Qt = typeof ht == "object" && ht && ht.Object === Object && ht, te = typeof self == "object" && self && self.Object === Object && self, at = Qt || te || Function("return this")(), Ct = r && !r.nodeType && r, H = Ct && !0 && t && !t.nodeType && t, U = H && H.exports === Ct;
|
999
999
|
function G(e, a) {
|
1000
1000
|
return e.set(a[0], a[1]), e;
|
1001
1001
|
}
|
1002
|
-
function
|
1002
|
+
function M(e, a) {
|
1003
1003
|
return e.add(a), e;
|
1004
1004
|
}
|
1005
|
-
function
|
1005
|
+
function ut(e, a) {
|
1006
1006
|
for (var o = -1, u = e ? e.length : 0; ++o < u && a(e[o], o, e) !== !1; )
|
1007
1007
|
;
|
1008
1008
|
return e;
|
1009
1009
|
}
|
1010
1010
|
function rt(e, a) {
|
1011
|
-
for (var o = -1, u = a.length,
|
1012
|
-
e[
|
1011
|
+
for (var o = -1, u = a.length, A = e.length; ++o < u; )
|
1012
|
+
e[A + o] = a[o];
|
1013
1013
|
return e;
|
1014
1014
|
}
|
1015
1015
|
function K(e, a, o, u) {
|
1016
|
-
for (var
|
1017
|
-
o = a(o, e[
|
1016
|
+
for (var A = -1, v = e ? e.length : 0; ++A < v; )
|
1017
|
+
o = a(o, e[A], A, e);
|
1018
1018
|
return o;
|
1019
1019
|
}
|
1020
|
-
function
|
1020
|
+
function lt(e, a) {
|
1021
1021
|
for (var o = -1, u = Array(e); ++o < e; )
|
1022
1022
|
u[o] = a(o);
|
1023
1023
|
return u;
|
@@ -1034,10 +1034,10 @@ fr.exports;
|
|
1034
1034
|
}
|
1035
1035
|
return a;
|
1036
1036
|
}
|
1037
|
-
function
|
1037
|
+
function It(e) {
|
1038
1038
|
var a = -1, o = Array(e.size);
|
1039
|
-
return e.forEach(function(u,
|
1040
|
-
o[++a] = [
|
1039
|
+
return e.forEach(function(u, A) {
|
1040
|
+
o[++a] = [A, u];
|
1041
1041
|
}), o;
|
1042
1042
|
}
|
1043
1043
|
function Rt(e, a) {
|
@@ -1045,19 +1045,19 @@ fr.exports;
|
|
1045
1045
|
return e(a(o));
|
1046
1046
|
};
|
1047
1047
|
}
|
1048
|
-
function
|
1048
|
+
function Ue(e) {
|
1049
1049
|
var a = -1, o = Array(e.size);
|
1050
1050
|
return e.forEach(function(u) {
|
1051
1051
|
o[++a] = u;
|
1052
1052
|
}), o;
|
1053
1053
|
}
|
1054
|
-
var gr = Array.prototype, br = Function.prototype, ee = Object.prototype,
|
1055
|
-
var e = /[^.]+$/.exec(
|
1054
|
+
var gr = Array.prototype, br = Function.prototype, ee = Object.prototype, _e = at["__core-js_shared__"], Ge = function() {
|
1055
|
+
var e = /[^.]+$/.exec(_e && _e.keys && _e.keys.IE_PROTO || "");
|
1056
1056
|
return e ? "Symbol(src)_1." + e : "";
|
1057
|
-
}(),
|
1058
|
-
"^" +
|
1059
|
-
), Lt = U ? at.Buffer : void 0, ne = at.Symbol,
|
1060
|
-
function
|
1057
|
+
}(), Ye = br.toString, gt = ee.hasOwnProperty, re = ee.toString, vr = RegExp(
|
1058
|
+
"^" + Ye.call(gt).replace(Vt, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
|
1059
|
+
), Lt = U ? at.Buffer : void 0, ne = at.Symbol, Ie = at.Uint8Array, pt = Rt(Object.getPrototypeOf, Object), We = Object.create, Xe = ee.propertyIsEnumerable, Sr = gr.splice, ge = Object.getOwnPropertySymbols, ie = Lt ? Lt.isBuffer : void 0, Be = Rt(Object.keys, Object), ae = yt(at, "DataView"), Ft = yt(at, "Map"), mt = yt(at, "Promise"), se = yt(at, "Set"), be = yt(at, "WeakMap"), $t = yt(Object, "create"), ve = nt(ae), Nt = nt(Ft), Se = nt(mt), Ee = nt(se), Te = nt(be), Dt = ne ? ne.prototype : void 0, Ke = Dt ? Dt.valueOf : void 0;
|
1060
|
+
function Et(e) {
|
1061
1061
|
var a = -1, o = e ? e.length : 0;
|
1062
1062
|
for (this.clear(); ++a < o; ) {
|
1063
1063
|
var u = e[a];
|
@@ -1070,23 +1070,23 @@ fr.exports;
|
|
1070
1070
|
function Tr(e) {
|
1071
1071
|
return this.has(e) && delete this.__data__[e];
|
1072
1072
|
}
|
1073
|
-
function
|
1073
|
+
function kr(e) {
|
1074
1074
|
var a = this.__data__;
|
1075
1075
|
if ($t) {
|
1076
1076
|
var o = a[e];
|
1077
1077
|
return o === i ? void 0 : o;
|
1078
1078
|
}
|
1079
|
-
return
|
1079
|
+
return gt.call(a, e) ? a[e] : void 0;
|
1080
1080
|
}
|
1081
|
-
function
|
1081
|
+
function Ve(e) {
|
1082
1082
|
var a = this.__data__;
|
1083
|
-
return $t ? a[e] !== void 0 :
|
1083
|
+
return $t ? a[e] !== void 0 : gt.call(a, e);
|
1084
1084
|
}
|
1085
|
-
function
|
1085
|
+
function ke(e, a) {
|
1086
1086
|
var o = this.__data__;
|
1087
1087
|
return o[e] = $t && a === void 0 ? i : a, this;
|
1088
1088
|
}
|
1089
|
-
|
1089
|
+
Et.prototype.clear = Er, Et.prototype.delete = Tr, Et.prototype.get = kr, Et.prototype.has = Ve, Et.prototype.set = ke;
|
1090
1090
|
function J(e) {
|
1091
1091
|
var a = -1, o = e ? e.length : 0;
|
1092
1092
|
for (this.clear(); ++a < o; ) {
|
@@ -1094,7 +1094,7 @@ fr.exports;
|
|
1094
1094
|
this.set(u[0], u[1]);
|
1095
1095
|
}
|
1096
1096
|
}
|
1097
|
-
function
|
1097
|
+
function wr() {
|
1098
1098
|
this.__data__ = [];
|
1099
1099
|
}
|
1100
1100
|
function Ar(e) {
|
@@ -1115,7 +1115,7 @@ fr.exports;
|
|
1115
1115
|
var o = this.__data__, u = ce(o, e);
|
1116
1116
|
return u < 0 ? o.push([e, a]) : o[u][1] = a, this;
|
1117
1117
|
}
|
1118
|
-
J.prototype.clear =
|
1118
|
+
J.prototype.clear = wr, J.prototype.delete = Ar, J.prototype.get = Dr, J.prototype.has = Mr, J.prototype.set = Or;
|
1119
1119
|
function q(e) {
|
1120
1120
|
var a = -1, o = e ? e.length : 0;
|
1121
1121
|
for (this.clear(); ++a < o; ) {
|
@@ -1123,26 +1123,26 @@ fr.exports;
|
|
1123
1123
|
this.set(u[0], u[1]);
|
1124
1124
|
}
|
1125
1125
|
}
|
1126
|
-
function
|
1126
|
+
function Pr() {
|
1127
1127
|
this.__data__ = {
|
1128
|
-
hash: new
|
1128
|
+
hash: new Et(),
|
1129
1129
|
map: new (Ft || J)(),
|
1130
|
-
string: new
|
1130
|
+
string: new Et()
|
1131
1131
|
};
|
1132
1132
|
}
|
1133
|
-
function
|
1134
|
-
return
|
1133
|
+
function xr(e) {
|
1134
|
+
return jt(this, e).delete(e);
|
1135
1135
|
}
|
1136
1136
|
function Cr(e) {
|
1137
|
-
return
|
1137
|
+
return jt(this, e).get(e);
|
1138
1138
|
}
|
1139
1139
|
function Rr(e) {
|
1140
|
-
return
|
1140
|
+
return jt(this, e).has(e);
|
1141
1141
|
}
|
1142
1142
|
function Lr(e, a) {
|
1143
|
-
return
|
1143
|
+
return jt(this, e).set(e, a), this;
|
1144
1144
|
}
|
1145
|
-
q.prototype.clear =
|
1145
|
+
q.prototype.clear = Pr, q.prototype.delete = xr, q.prototype.get = Cr, q.prototype.has = Rr, q.prototype.set = Lr;
|
1146
1146
|
function st(e) {
|
1147
1147
|
this.__data__ = new J(e);
|
1148
1148
|
}
|
@@ -1158,7 +1158,7 @@ fr.exports;
|
|
1158
1158
|
function Hr(e) {
|
1159
1159
|
return this.__data__.has(e);
|
1160
1160
|
}
|
1161
|
-
function
|
1161
|
+
function jr(e, a) {
|
1162
1162
|
var o = this.__data__;
|
1163
1163
|
if (o instanceof J) {
|
1164
1164
|
var u = o.__data__;
|
@@ -1168,49 +1168,49 @@ fr.exports;
|
|
1168
1168
|
}
|
1169
1169
|
return o.set(e, a), this;
|
1170
1170
|
}
|
1171
|
-
st.prototype.clear = Fr, st.prototype.delete = $r, st.prototype.get = Nr, st.prototype.has = Hr, st.prototype.set =
|
1171
|
+
st.prototype.clear = Fr, st.prototype.delete = $r, st.prototype.get = Nr, st.prototype.has = Hr, st.prototype.set = jr;
|
1172
1172
|
function oe(e, a) {
|
1173
|
-
var o =
|
1173
|
+
var o = Me(e) || le(e) ? lt(e.length, String) : [], u = o.length, A = !!u;
|
1174
1174
|
for (var v in e)
|
1175
|
-
|
1175
|
+
gt.call(e, v) && !(A && (v == "length" || tn(v, u))) && o.push(v);
|
1176
1176
|
return o;
|
1177
1177
|
}
|
1178
|
-
function
|
1178
|
+
function Je(e, a, o) {
|
1179
1179
|
var u = e[a];
|
1180
|
-
(!(
|
1180
|
+
(!(gt.call(e, a) && er(u, o)) || o === void 0 && !(a in e)) && (e[a] = o);
|
1181
1181
|
}
|
1182
1182
|
function ce(e, a) {
|
1183
1183
|
for (var o = e.length; o--; )
|
1184
|
-
if (
|
1184
|
+
if (er(e[o][0], a))
|
1185
1185
|
return o;
|
1186
1186
|
return -1;
|
1187
1187
|
}
|
1188
|
-
function
|
1189
|
-
return e &&
|
1188
|
+
function bt(e, a) {
|
1189
|
+
return e && De(a, Pe(a), e);
|
1190
1190
|
}
|
1191
|
-
function we(e, a, o, u,
|
1191
|
+
function we(e, a, o, u, A, v, $) {
|
1192
1192
|
var L;
|
1193
|
-
if (u && (L = v ? u(e,
|
1193
|
+
if (u && (L = v ? u(e, A, v, $) : u(e)), L !== void 0)
|
1194
1194
|
return L;
|
1195
|
-
if (!
|
1195
|
+
if (!St(e))
|
1196
1196
|
return e;
|
1197
|
-
var W =
|
1197
|
+
var W = Me(e);
|
1198
1198
|
if (W) {
|
1199
1199
|
if (L = qr(e), !a)
|
1200
1200
|
return Vr(e, L);
|
1201
1201
|
} else {
|
1202
|
-
var
|
1203
|
-
if (
|
1202
|
+
var j = kt(e), Q = j == S || j == F;
|
1203
|
+
if (rr(e))
|
1204
1204
|
return ue(e, a);
|
1205
|
-
if (
|
1205
|
+
if (j == l || j == c || Q && !v) {
|
1206
1206
|
if (Y(e))
|
1207
1207
|
return v ? e : {};
|
1208
|
-
if (L =
|
1209
|
-
return Jr(e,
|
1208
|
+
if (L = vt(Q ? {} : e), !a)
|
1209
|
+
return Jr(e, bt(L, e));
|
1210
1210
|
} else {
|
1211
|
-
if (!N[
|
1211
|
+
if (!N[j])
|
1212
1212
|
return v ? e : {};
|
1213
|
-
L = Qr(e,
|
1213
|
+
L = Qr(e, j, we, a);
|
1214
1214
|
}
|
1215
1215
|
}
|
1216
1216
|
$ || ($ = new st());
|
@@ -1218,33 +1218,33 @@ fr.exports;
|
|
1218
1218
|
if (ot)
|
1219
1219
|
return ot;
|
1220
1220
|
if ($.set(e, L), !W)
|
1221
|
-
var X = o ? Zr(e) :
|
1222
|
-
return
|
1223
|
-
X && (Z = tt, tt = e[Z]),
|
1221
|
+
var X = o ? Zr(e) : Pe(e);
|
1222
|
+
return ut(X || e, function(tt, Z) {
|
1223
|
+
X && (Z = tt, tt = e[Z]), Je(L, Z, we(tt, a, o, u, Z, e, $));
|
1224
1224
|
}), L;
|
1225
1225
|
}
|
1226
|
-
function
|
1227
|
-
return
|
1226
|
+
function zr(e) {
|
1227
|
+
return St(e) ? We(e) : {};
|
1228
1228
|
}
|
1229
1229
|
function Ur(e, a, o) {
|
1230
1230
|
var u = a(e);
|
1231
|
-
return
|
1231
|
+
return Me(e) ? u : rt(u, o(e));
|
1232
1232
|
}
|
1233
1233
|
function Gr(e) {
|
1234
1234
|
return re.call(e);
|
1235
1235
|
}
|
1236
1236
|
function Yr(e) {
|
1237
|
-
if (!
|
1237
|
+
if (!St(e) || rn(e))
|
1238
1238
|
return !1;
|
1239
|
-
var a =
|
1239
|
+
var a = Oe(e) || Y(e) ? vr : Zt;
|
1240
1240
|
return a.test(nt(e));
|
1241
1241
|
}
|
1242
1242
|
function Wr(e) {
|
1243
|
-
if (!
|
1244
|
-
return
|
1243
|
+
if (!Qe(e))
|
1244
|
+
return Be(e);
|
1245
1245
|
var a = [];
|
1246
1246
|
for (var o in Object(e))
|
1247
|
-
|
1247
|
+
gt.call(e, o) && o != "constructor" && a.push(o);
|
1248
1248
|
return a;
|
1249
1249
|
}
|
1250
1250
|
function ue(e, a) {
|
@@ -1253,31 +1253,31 @@ fr.exports;
|
|
1253
1253
|
var o = new e.constructor(e.length);
|
1254
1254
|
return e.copy(o), o;
|
1255
1255
|
}
|
1256
|
-
function
|
1256
|
+
function Ae(e) {
|
1257
1257
|
var a = new e.constructor(e.byteLength);
|
1258
|
-
return new
|
1258
|
+
return new Ie(a).set(new Ie(e)), a;
|
1259
1259
|
}
|
1260
1260
|
function Ht(e, a) {
|
1261
|
-
var o = a ?
|
1261
|
+
var o = a ? Ae(e.buffer) : e.buffer;
|
1262
1262
|
return new e.constructor(o, e.byteOffset, e.byteLength);
|
1263
1263
|
}
|
1264
|
-
function
|
1265
|
-
var u = a ? o(
|
1264
|
+
function Ze(e, a, o) {
|
1265
|
+
var u = a ? o(It(e), !0) : It(e);
|
1266
1266
|
return K(u, G, new e.constructor());
|
1267
1267
|
}
|
1268
|
-
function
|
1268
|
+
function qe(e) {
|
1269
1269
|
var a = new e.constructor(e.source, Jt.exec(e));
|
1270
1270
|
return a.lastIndex = e.lastIndex, a;
|
1271
1271
|
}
|
1272
1272
|
function Xr(e, a, o) {
|
1273
|
-
var u = a ? o(
|
1274
|
-
return K(u,
|
1273
|
+
var u = a ? o(Ue(e), !0) : Ue(e);
|
1274
|
+
return K(u, M, new e.constructor());
|
1275
1275
|
}
|
1276
1276
|
function Br(e) {
|
1277
|
-
return
|
1277
|
+
return Ke ? Object(Ke.call(e)) : {};
|
1278
1278
|
}
|
1279
1279
|
function Kr(e, a) {
|
1280
|
-
var o = a ?
|
1280
|
+
var o = a ? Ae(e.buffer) : e.buffer;
|
1281
1281
|
return new e.constructor(o, e.byteOffset, e.length);
|
1282
1282
|
}
|
1283
1283
|
function Vr(e, a) {
|
@@ -1286,83 +1286,83 @@ fr.exports;
|
|
1286
1286
|
a[o] = e[o];
|
1287
1287
|
return a;
|
1288
1288
|
}
|
1289
|
-
function
|
1289
|
+
function De(e, a, o, u) {
|
1290
1290
|
o || (o = {});
|
1291
|
-
for (var
|
1292
|
-
var $ = a[
|
1293
|
-
|
1291
|
+
for (var A = -1, v = a.length; ++A < v; ) {
|
1292
|
+
var $ = a[A], L = void 0;
|
1293
|
+
Je(o, $, L === void 0 ? e[$] : L);
|
1294
1294
|
}
|
1295
1295
|
return o;
|
1296
1296
|
}
|
1297
1297
|
function Jr(e, a) {
|
1298
|
-
return
|
1298
|
+
return De(e, Tt(e), a);
|
1299
1299
|
}
|
1300
1300
|
function Zr(e) {
|
1301
|
-
return Ur(e,
|
1301
|
+
return Ur(e, Pe, Tt);
|
1302
1302
|
}
|
1303
|
-
function
|
1303
|
+
function jt(e, a) {
|
1304
1304
|
var o = e.__data__;
|
1305
1305
|
return en(a) ? o[typeof a == "string" ? "string" : "hash"] : o.map;
|
1306
1306
|
}
|
1307
|
-
function
|
1307
|
+
function yt(e, a) {
|
1308
1308
|
var o = V(e, a);
|
1309
1309
|
return Yr(o) ? o : void 0;
|
1310
1310
|
}
|
1311
|
-
var
|
1312
|
-
(ae && kt(new ae(new ArrayBuffer(1))) !=
|
1311
|
+
var Tt = ge ? Rt(ge, Object) : an, kt = Gr;
|
1312
|
+
(ae && kt(new ae(new ArrayBuffer(1))) != O || Ft && kt(new Ft()) != _ || mt && kt(mt.resolve()) != h || se && kt(new se()) != I || be && kt(new be()) != m) && (kt = function(e) {
|
1313
1313
|
var a = re.call(e), o = a == l ? e.constructor : void 0, u = o ? nt(o) : void 0;
|
1314
1314
|
if (u)
|
1315
1315
|
switch (u) {
|
1316
|
-
case
|
1317
|
-
return
|
1316
|
+
case ve:
|
1317
|
+
return O;
|
1318
1318
|
case Nt:
|
1319
1319
|
return _;
|
1320
|
-
case ve:
|
1321
|
-
return p;
|
1322
1320
|
case Se:
|
1323
|
-
return I;
|
1324
|
-
case Ee:
|
1325
1321
|
return h;
|
1322
|
+
case Ee:
|
1323
|
+
return I;
|
1324
|
+
case Te:
|
1325
|
+
return m;
|
1326
1326
|
}
|
1327
1327
|
return a;
|
1328
1328
|
});
|
1329
1329
|
function qr(e) {
|
1330
1330
|
var a = e.length, o = e.constructor(a);
|
1331
|
-
return a && typeof e[0] == "string" &&
|
1331
|
+
return a && typeof e[0] == "string" && gt.call(e, "index") && (o.index = e.index, o.input = e.input), o;
|
1332
1332
|
}
|
1333
|
-
function
|
1334
|
-
return typeof e.constructor == "function" && !
|
1333
|
+
function vt(e) {
|
1334
|
+
return typeof e.constructor == "function" && !Qe(e) ? zr(pt(e)) : {};
|
1335
1335
|
}
|
1336
1336
|
function Qr(e, a, o, u) {
|
1337
|
-
var
|
1337
|
+
var A = e.constructor;
|
1338
1338
|
switch (a) {
|
1339
|
-
case
|
1340
|
-
return
|
1341
|
-
case
|
1339
|
+
case k:
|
1340
|
+
return Ae(e);
|
1341
|
+
case y:
|
1342
1342
|
case T:
|
1343
|
-
return new
|
1344
|
-
case
|
1343
|
+
return new A(+e);
|
1344
|
+
case O:
|
1345
1345
|
return Ht(e, u);
|
1346
1346
|
case w:
|
1347
1347
|
case x:
|
1348
|
-
case
|
1348
|
+
case R:
|
1349
1349
|
case P:
|
1350
|
-
case
|
1351
|
-
case
|
1352
|
-
case
|
1353
|
-
case ut:
|
1350
|
+
case E:
|
1351
|
+
case D:
|
1352
|
+
case z:
|
1354
1353
|
case Pt:
|
1354
|
+
case xt:
|
1355
1355
|
return Kr(e, u);
|
1356
1356
|
case _:
|
1357
|
-
return
|
1357
|
+
return Ze(e, u, o);
|
1358
1358
|
case f:
|
1359
1359
|
case b:
|
1360
|
-
return new
|
1360
|
+
return new A(e);
|
1361
1361
|
case g:
|
1362
|
-
return
|
1362
|
+
return qe(e);
|
1363
1363
|
case I:
|
1364
1364
|
return Xr(e, u, o);
|
1365
|
-
case
|
1365
|
+
case p:
|
1366
1366
|
return Br(e);
|
1367
1367
|
}
|
1368
1368
|
}
|
@@ -1374,16 +1374,16 @@ fr.exports;
|
|
1374
1374
|
return a == "string" || a == "number" || a == "symbol" || a == "boolean" ? e !== "__proto__" : e === null;
|
1375
1375
|
}
|
1376
1376
|
function rn(e) {
|
1377
|
-
return !!
|
1377
|
+
return !!Ge && Ge in e;
|
1378
1378
|
}
|
1379
|
-
function
|
1379
|
+
function Qe(e) {
|
1380
1380
|
var a = e && e.constructor, o = typeof a == "function" && a.prototype || ee;
|
1381
1381
|
return e === o;
|
1382
1382
|
}
|
1383
1383
|
function nt(e) {
|
1384
1384
|
if (e != null) {
|
1385
1385
|
try {
|
1386
|
-
return
|
1386
|
+
return Ye.call(e);
|
1387
1387
|
} catch {
|
1388
1388
|
}
|
1389
1389
|
try {
|
@@ -1393,38 +1393,38 @@ fr.exports;
|
|
1393
1393
|
}
|
1394
1394
|
return "";
|
1395
1395
|
}
|
1396
|
-
function
|
1396
|
+
function tr(e) {
|
1397
1397
|
return we(e, !0, !0);
|
1398
1398
|
}
|
1399
|
-
function
|
1399
|
+
function er(e, a) {
|
1400
1400
|
return e === a || e !== e && a !== a;
|
1401
1401
|
}
|
1402
1402
|
function le(e) {
|
1403
|
-
return nn(e) &&
|
1403
|
+
return nn(e) && gt.call(e, "callee") && (!Xe.call(e, "callee") || re.call(e) == c);
|
1404
1404
|
}
|
1405
|
-
var
|
1405
|
+
var Me = Array.isArray;
|
1406
1406
|
function fe(e) {
|
1407
|
-
return e != null &&
|
1407
|
+
return e != null && nr(e.length) && !Oe(e);
|
1408
1408
|
}
|
1409
1409
|
function nn(e) {
|
1410
|
-
return
|
1410
|
+
return ir(e) && fe(e);
|
1411
1411
|
}
|
1412
|
-
var
|
1413
|
-
function
|
1414
|
-
var a =
|
1412
|
+
var rr = ie || sn;
|
1413
|
+
function Oe(e) {
|
1414
|
+
var a = St(e) ? re.call(e) : "";
|
1415
1415
|
return a == S || a == F;
|
1416
1416
|
}
|
1417
|
-
function
|
1417
|
+
function nr(e) {
|
1418
1418
|
return typeof e == "number" && e > -1 && e % 1 == 0 && e <= s;
|
1419
1419
|
}
|
1420
|
-
function
|
1420
|
+
function St(e) {
|
1421
1421
|
var a = typeof e;
|
1422
1422
|
return !!e && (a == "object" || a == "function");
|
1423
1423
|
}
|
1424
|
-
function
|
1424
|
+
function ir(e) {
|
1425
1425
|
return !!e && typeof e == "object";
|
1426
1426
|
}
|
1427
|
-
function
|
1427
|
+
function Pe(e) {
|
1428
1428
|
return fe(e) ? oe(e) : Wr(e);
|
1429
1429
|
}
|
1430
1430
|
function an() {
|
@@ -1433,10 +1433,10 @@ fr.exports;
|
|
1433
1433
|
function sn() {
|
1434
1434
|
return !1;
|
1435
1435
|
}
|
1436
|
-
t.exports =
|
1436
|
+
t.exports = tr;
|
1437
1437
|
})(fr, fr.exports);
|
1438
1438
|
var aa = fr.exports;
|
1439
|
-
const et = /* @__PURE__ */
|
1439
|
+
const et = /* @__PURE__ */ kn(aa), ri = (t) => new Promise((r, n) => {
|
1440
1440
|
const i = new Image();
|
1441
1441
|
console.warn("update cdn config for cors?"), i.onload = () => {
|
1442
1442
|
const s = i.width, c = i.height;
|
@@ -1477,15 +1477,15 @@ const et = /* @__PURE__ */ wn(aa), ri = (t) => new Promise((r, n) => {
|
|
1477
1477
|
}).catch((s) => i(s));
|
1478
1478
|
});
|
1479
1479
|
}, oa = "useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";
|
1480
|
-
let
|
1480
|
+
let ur = (t = 21) => {
|
1481
1481
|
let r = "", n = crypto.getRandomValues(new Uint8Array(t));
|
1482
1482
|
for (; t--; )
|
1483
1483
|
r += oa[n[t] & 63];
|
1484
1484
|
return r;
|
1485
1485
|
};
|
1486
|
-
function
|
1486
|
+
function he(t = 16) {
|
1487
1487
|
const r = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ", n = r.charAt(Math.floor(Math.random() * r.length));
|
1488
|
-
let i =
|
1488
|
+
let i = ur(t - 1);
|
1489
1489
|
return i = i.replace(/[^a-zA-Z0-9]/g, "").slice(0, t - 1), n + i;
|
1490
1490
|
}
|
1491
1491
|
const yr = {
|
@@ -1493,7 +1493,7 @@ const yr = {
|
|
1493
1493
|
x: 0,
|
1494
1494
|
y: 0,
|
1495
1495
|
blur: 0
|
1496
|
-
},
|
1496
|
+
}, Ne = (t, r) => {
|
1497
1497
|
let n = r != null && r.trim ? r.trim.to - r.trim.from : (r == null ? void 0 : r.duration) || 5e3;
|
1498
1498
|
const i = {
|
1499
1499
|
from: 0,
|
@@ -1581,7 +1581,7 @@ const si = async (t, r) => {
|
|
1581
1581
|
name: "video",
|
1582
1582
|
details: d,
|
1583
1583
|
playbackRate: t.playbackRate || 1,
|
1584
|
-
display:
|
1584
|
+
display: Ne(t.display, { duration: i.duration, trim: c }),
|
1585
1585
|
duration: i.duration
|
1586
1586
|
};
|
1587
1587
|
}, oi = async (t) => {
|
@@ -1590,7 +1590,7 @@ const si = async (t, r) => {
|
|
1590
1590
|
id: r,
|
1591
1591
|
name: "",
|
1592
1592
|
type: "audio",
|
1593
|
-
display:
|
1593
|
+
display: Ne(t.display, { duration: s, trim: c }),
|
1594
1594
|
trim: c,
|
1595
1595
|
playbackRate: t.playbackRate || 1,
|
1596
1596
|
details: {
|
@@ -1612,11 +1612,11 @@ const si = async (t, r) => {
|
|
1612
1612
|
), c = ((F = t.details) == null ? void 0 : F.rotate) || 0, d = {
|
1613
1613
|
top: ((_ = t.details) == null ? void 0 : _.top) || 0,
|
1614
1614
|
left: ((f = t.details) == null ? void 0 : f.left) || 0
|
1615
|
-
},
|
1616
|
-
let
|
1615
|
+
}, y = t.display, T = t.trim || t.display;
|
1616
|
+
let C = 1 / 0, S = 0;
|
1617
1617
|
return n.forEach((l) => {
|
1618
|
-
const
|
1619
|
-
|
1618
|
+
const h = t.trackItemsMap[l];
|
1619
|
+
h.display.from < C && (C = h.display.from), h.display.to > S && (S = h.display.to);
|
1620
1620
|
}), {
|
1621
1621
|
id: t.id,
|
1622
1622
|
details: {
|
@@ -1627,7 +1627,7 @@ const si = async (t, r) => {
|
|
1627
1627
|
rotate: c
|
1628
1628
|
},
|
1629
1629
|
trim: T,
|
1630
|
-
display:
|
1630
|
+
display: y || { from: C, to: S },
|
1631
1631
|
activeEdit: !1
|
1632
1632
|
};
|
1633
1633
|
}, ci = async (t, r) => {
|
@@ -1636,7 +1636,7 @@ const si = async (t, r) => {
|
|
1636
1636
|
id: t.id,
|
1637
1637
|
type: "image",
|
1638
1638
|
name: "image",
|
1639
|
-
display:
|
1639
|
+
display: Ne(t.display),
|
1640
1640
|
playbackRate: t.playbackRate || 1,
|
1641
1641
|
details: {
|
1642
1642
|
src: n.src || "",
|
@@ -1682,7 +1682,7 @@ const si = async (t, r) => {
|
|
1682
1682
|
url: n.details.fontUrl
|
1683
1683
|
}
|
1684
1684
|
]);
|
1685
|
-
const i = n.id, s = n.details, c = fi(s), d = ii(n.details.text, c),
|
1685
|
+
const i = n.id, s = n.details, c = fi(s), d = ii(n.details.text, c), y = _r(r, {
|
1686
1686
|
width: c.width,
|
1687
1687
|
height: d
|
1688
1688
|
});
|
@@ -1690,7 +1690,7 @@ const si = async (t, r) => {
|
|
1690
1690
|
id: i,
|
1691
1691
|
name: "caption",
|
1692
1692
|
type: "caption",
|
1693
|
-
display:
|
1693
|
+
display: Ne(n.display),
|
1694
1694
|
details: {
|
1695
1695
|
...c,
|
1696
1696
|
text: s.text || "",
|
@@ -1698,8 +1698,8 @@ const si = async (t, r) => {
|
|
1698
1698
|
height: d,
|
1699
1699
|
// Default height
|
1700
1700
|
fontUrl: s.fontUrl,
|
1701
|
-
top: c.top ||
|
1702
|
-
left: c.left ||
|
1701
|
+
top: c.top || y.top,
|
1702
|
+
left: c.left || y.left,
|
1703
1703
|
borderWidth: s.borderWidth || 0,
|
1704
1704
|
borderColor: s.borderColor || "#000000",
|
1705
1705
|
boxShadow: s.boxShadow || yr,
|
@@ -1722,7 +1722,7 @@ const si = async (t, r) => {
|
|
1722
1722
|
id: n,
|
1723
1723
|
name: "text",
|
1724
1724
|
type: "text",
|
1725
|
-
display:
|
1725
|
+
display: Ne(t.display),
|
1726
1726
|
details: {
|
1727
1727
|
...s,
|
1728
1728
|
text: i.text || "",
|
@@ -1804,7 +1804,7 @@ function la(t, r) {
|
|
1804
1804
|
);
|
1805
1805
|
}
|
1806
1806
|
const fa = (t = [], r = []) => t.length === 0 ? r.map((i) => ({
|
1807
|
-
id:
|
1807
|
+
id: he(),
|
1808
1808
|
items: [i.id],
|
1809
1809
|
type: i.type,
|
1810
1810
|
accepts: ["text", "image", "video", "audio", "caption", "template"]
|
@@ -1815,13 +1815,13 @@ const fa = (t = [], r = []) => t.length === 0 ? r.map((i) => ({
|
|
1815
1815
|
type: n.type || "text",
|
1816
1816
|
magnetic: n.magnetic || !1,
|
1817
1817
|
static: n.static || !1,
|
1818
|
-
id: n.id ||
|
1818
|
+
id: n.id || he()
|
1819
1819
|
}));
|
1820
1820
|
function da(t, r) {
|
1821
1821
|
return t.filter((i) => {
|
1822
1822
|
if (r.forEach((s) => {
|
1823
1823
|
i.items.includes(s) && (i.items = i.items.filter((c) => c !== s));
|
1824
|
-
}), i.items.length !== 0)
|
1824
|
+
}), i.items.length !== 0 || i.static)
|
1825
1825
|
return i;
|
1826
1826
|
});
|
1827
1827
|
}
|
@@ -1841,12 +1841,12 @@ const pa = (t, r, n, i, s) => {
|
|
1841
1841
|
trackId: void 0,
|
1842
1842
|
trackIndex: s !== void 0 ? In(s, 0, r.length) : void 0
|
1843
1843
|
};
|
1844
|
-
const d = c.items.map((T) => n[T]),
|
1844
|
+
const d = c.items.map((T) => n[T]), y = t.map((T) => n[T]);
|
1845
1845
|
for (const T of d) {
|
1846
|
-
const
|
1847
|
-
for (const F of
|
1846
|
+
const C = T.display.from, S = T.display.to;
|
1847
|
+
for (const F of y) {
|
1848
1848
|
const _ = F.display.from;
|
1849
|
-
if (!(F.display.to <=
|
1849
|
+
if (!(F.display.to <= C || _ >= S))
|
1850
1850
|
return {
|
1851
1851
|
trackId: void 0,
|
1852
1852
|
trackIndex: r.indexOf(c)
|
@@ -1862,35 +1862,35 @@ function ha(t) {
|
|
1862
1862
|
const r = de.pipe(
|
1863
1863
|
pe(({ key: f }) => f.startsWith(Ti))
|
1864
1864
|
), n = de.pipe(
|
1865
|
-
pe(({ key: f }) => f.startsWith(wi))
|
1866
|
-
), i = de.pipe(
|
1867
1865
|
pe(({ key: f }) => f.startsWith(ki))
|
1866
|
+
), i = de.pipe(
|
1867
|
+
pe(({ key: f }) => f.startsWith(wi))
|
1868
1868
|
), s = de.pipe(
|
1869
1869
|
pe(({ key: f }) => f.startsWith(Ai))
|
1870
1870
|
), c = de.pipe(
|
1871
1871
|
pe(({ key: f }) => f.startsWith(Di))
|
1872
1872
|
), d = de.pipe(
|
1873
1873
|
pe(({ key: f }) => f.startsWith(Mi))
|
1874
|
-
),
|
1875
|
-
var l,
|
1874
|
+
), y = r.subscribe(async (f) => {
|
1875
|
+
var l, h;
|
1876
1876
|
if (f.key === Oi) {
|
1877
1877
|
const g = (l = f.value) == null ? void 0 : l.payload, I = g.trackItemsMap, b = g.trackItemDetailsMap;
|
1878
1878
|
console.warn("IMPROVE FONTS LOADING");
|
1879
|
-
for (const
|
1880
|
-
if (b[
|
1881
|
-
const
|
1879
|
+
for (const m in b)
|
1880
|
+
if (b[m].type === "text" || b[m].type === "caption") {
|
1881
|
+
const k = b[m].details;
|
1882
1882
|
await dr([
|
1883
1883
|
{
|
1884
|
-
fontFamily:
|
1885
|
-
url:
|
1884
|
+
fontFamily: k.fontFamily,
|
1885
|
+
url: k.fontUrl
|
1886
1886
|
}
|
1887
1887
|
]);
|
1888
1888
|
}
|
1889
|
-
const
|
1889
|
+
const p = Yt(I);
|
1890
1890
|
t.updateState(
|
1891
1891
|
{
|
1892
1892
|
...g,
|
1893
|
-
duration:
|
1893
|
+
duration: p
|
1894
1894
|
},
|
1895
1895
|
{
|
1896
1896
|
kind: "design:load",
|
@@ -1898,8 +1898,8 @@ function ha(t) {
|
|
1898
1898
|
}
|
1899
1899
|
);
|
1900
1900
|
}
|
1901
|
-
if (f.key ===
|
1902
|
-
const g = (
|
1901
|
+
if (f.key === Pi) {
|
1902
|
+
const g = (h = f.value) == null ? void 0 : h.payload;
|
1903
1903
|
t.updateState(
|
1904
1904
|
{
|
1905
1905
|
size: g
|
@@ -1911,80 +1911,73 @@ function ha(t) {
|
|
1911
1911
|
);
|
1912
1912
|
}
|
1913
1913
|
}), T = s.subscribe((f) => {
|
1914
|
-
if (f.key ===
|
1914
|
+
if (f.key === xi) return t.undo();
|
1915
1915
|
if (f.key === Ci) return t.redo();
|
1916
|
-
}),
|
1917
|
-
var g, I, b
|
1918
|
-
const l = []
|
1919
|
-
if ((
|
1916
|
+
}), C = i.subscribe((f) => {
|
1917
|
+
var h, g, I, b;
|
1918
|
+
const l = [];
|
1919
|
+
if ((h = f.value) != null && h.payload.trackItemIds && (l.push((g = f.value) == null ? void 0 : g.payload.trackItemIds), t.updateState(
|
1920
1920
|
{ activeIds: l },
|
1921
1921
|
{
|
1922
1922
|
kind: "update",
|
1923
1923
|
updateHistory: !1
|
1924
1924
|
}
|
1925
1925
|
)), f.key === Ri) {
|
1926
|
-
const
|
1927
|
-
(
|
1928
|
-
),
|
1929
|
-
Object.entries(
|
1930
|
-
([
|
1926
|
+
const p = (I = f.value) == null ? void 0 : I.payload.trackItemIds, m = et(t.getState()), k = p && p.length ? p : m.activeIds, O = m.trackItemIds, w = m.trackItemDetailsMap, x = O.filter(
|
1927
|
+
(z) => !k.includes(z)
|
1928
|
+
), R = Object.fromEntries(
|
1929
|
+
Object.entries(w).filter(
|
1930
|
+
([z]) => !k.includes(z)
|
1931
1931
|
)
|
1932
|
-
),
|
1933
|
-
|
1934
|
-
|
1935
|
-
),
|
1936
|
-
Object.entries(
|
1937
|
-
([
|
1932
|
+
), P = da(
|
1933
|
+
m.tracks,
|
1934
|
+
k
|
1935
|
+
), E = Object.fromEntries(
|
1936
|
+
Object.entries(m.trackItemsMap).filter(
|
1937
|
+
([z]) => !k.includes(z)
|
1938
1938
|
)
|
1939
|
-
),
|
1939
|
+
), D = Yt(E);
|
1940
1940
|
t.updateState(
|
1941
1941
|
{
|
1942
|
-
trackItemIds:
|
1943
|
-
trackItemDetailsMap:
|
1942
|
+
trackItemIds: x,
|
1943
|
+
trackItemDetailsMap: R,
|
1944
1944
|
activeIds: [],
|
1945
|
-
trackItemsMap:
|
1946
|
-
tracks:
|
1947
|
-
duration:
|
1945
|
+
trackItemsMap: E,
|
1946
|
+
tracks: P,
|
1947
|
+
duration: D
|
1948
1948
|
},
|
1949
1949
|
{ updateHistory: !0, kind: "remove" }
|
1950
1950
|
);
|
1951
1951
|
}
|
1952
1952
|
if (f.key === Li) {
|
1953
|
-
const
|
1954
|
-
if (
|
1955
|
-
|
1956
|
-
const x =
|
1957
|
-
p.
|
1958
|
-
...
|
1959
|
-
|
1960
|
-
},
|
1961
|
-
...
|
1962
|
-
|
1963
|
-
|
1964
|
-
|
1965
|
-
|
1966
|
-
|
1967
|
-
|
1968
|
-
|
1969
|
-
|
1970
|
-
|
1971
|
-
|
1972
|
-
id: xe()
|
1953
|
+
const p = et(t.getState()), m = {}, k = ((b = f.value) == null ? void 0 : b.payload.trackItemIds) || p.activeIds;
|
1954
|
+
if (k.length === 0) return;
|
1955
|
+
k.forEach((w) => {
|
1956
|
+
const x = p.trackItemsMap[w], R = p.trackItemDetailsMap[w], P = he();
|
1957
|
+
p.trackItemsMap[P] = {
|
1958
|
+
...et(x),
|
1959
|
+
id: P
|
1960
|
+
}, p.trackItemDetailsMap[P] = {
|
1961
|
+
...et(R)
|
1962
|
+
}, p.trackItemIds.push(P);
|
1963
|
+
const E = p.tracks.find(
|
1964
|
+
(D) => D.items.includes(w)
|
1965
|
+
);
|
1966
|
+
m[E.id] ? m[E.id].items.push(P) : m[E.id] = {
|
1967
|
+
...E,
|
1968
|
+
id: he(),
|
1969
|
+
items: [P],
|
1970
|
+
static: !1,
|
1971
|
+
magnetic: !1
|
1973
1972
|
};
|
1974
|
-
|
1975
|
-
|
1976
|
-
|
1977
|
-
x.items.push(p[P]);
|
1978
|
-
}
|
1979
|
-
}), A.push(x);
|
1980
|
-
}), A.forEach((w) => {
|
1981
|
-
w.items.length !== 0 && h.tracks.unshift(w);
|
1982
|
-
}), t.updateState(
|
1973
|
+
});
|
1974
|
+
const O = Object.values(m);
|
1975
|
+
p.tracks = [...O, ...p.tracks], t.updateState(
|
1983
1976
|
{
|
1984
|
-
trackItemDetailsMap:
|
1985
|
-
tracks:
|
1986
|
-
trackItemIds:
|
1987
|
-
trackItemsMap:
|
1977
|
+
trackItemDetailsMap: p.trackItemDetailsMap,
|
1978
|
+
tracks: p.tracks,
|
1979
|
+
trackItemIds: p.trackItemIds,
|
1980
|
+
trackItemsMap: p.trackItemsMap
|
1988
1981
|
},
|
1989
1982
|
{
|
1990
1983
|
updateHistory: !0,
|
@@ -1993,46 +1986,46 @@ function ha(t) {
|
|
1993
1986
|
);
|
1994
1987
|
}
|
1995
1988
|
}), S = n.subscribe(async (f) => {
|
1996
|
-
var
|
1997
|
-
const l = et(t.getState()),
|
1989
|
+
var k, O, w, x, R, P, E, D, z, Pt, xt, Vt, Jt, Zt, qt, N, Qt, te, at, Ct, H;
|
1990
|
+
const l = et(t.getState()), h = ((O = (k = f.value) == null ? void 0 : k.options) == null ? void 0 : O.isSelected) || !1;
|
1998
1991
|
let g = [], I = "text";
|
1999
1992
|
const b = (x = (w = f.value) == null ? void 0 : w.options) == null ? void 0 : x.trackId;
|
2000
|
-
let
|
1993
|
+
let p = (P = (R = f.value) == null ? void 0 : R.options) == null ? void 0 : P.trackIndex;
|
2001
1994
|
if (f.key === us) {
|
2002
|
-
const U = (
|
1995
|
+
const U = (E = f.value) == null ? void 0 : E.payload, G = U.trackItems.map(
|
2003
1996
|
(Y) => ua(Y, {
|
2004
1997
|
size: l.size
|
2005
1998
|
})
|
2006
|
-
),
|
2007
|
-
if (
|
2008
|
-
const { details:
|
1999
|
+
), M = await Promise.all(G), ut = fa(U.tracks, U.trackItems), rt = [], K = {}, lt = {};
|
2000
|
+
if (M.forEach((Y) => {
|
2001
|
+
const { details: It, ...Rt } = Y;
|
2009
2002
|
rt.push(Y.id), K[Y.id] = {
|
2010
2003
|
type: Y.type,
|
2011
|
-
details:
|
2012
|
-
},
|
2004
|
+
details: It
|
2005
|
+
}, lt[Y.id] = Rt;
|
2013
2006
|
}), la(
|
2014
2007
|
l.tracks,
|
2015
|
-
|
2008
|
+
ut
|
2016
2009
|
))
|
2017
2010
|
l.tracks.forEach((Y) => {
|
2018
|
-
|
2019
|
-
Y.id ===
|
2011
|
+
ut.forEach((It) => {
|
2012
|
+
Y.id === It.id && Y.items.push(...rt);
|
2020
2013
|
});
|
2021
2014
|
});
|
2022
2015
|
else {
|
2023
|
-
const Y = ((
|
2016
|
+
const Y = ((z = (D = f.value) == null ? void 0 : D.options) == null ? void 0 : z.trackIndex) || 0, It = In(
|
2024
2017
|
Y,
|
2025
2018
|
0,
|
2026
2019
|
l.tracks.length
|
2027
2020
|
);
|
2028
|
-
l.tracks.splice(
|
2021
|
+
l.tracks.splice(It, 0, ...ut);
|
2029
2022
|
}
|
2030
2023
|
l.trackItemDetailsMap = {
|
2031
2024
|
...l.trackItemDetailsMap,
|
2032
2025
|
...K
|
2033
2026
|
}, l.trackItemsMap = {
|
2034
2027
|
...l.trackItemsMap,
|
2035
|
-
...
|
2028
|
+
...lt
|
2036
2029
|
}, l.trackItemIds = [
|
2037
2030
|
...l.trackItemIds,
|
2038
2031
|
...rt
|
@@ -2053,48 +2046,48 @@ function ha(t) {
|
|
2053
2046
|
}
|
2054
2047
|
if (f.key === Fi) {
|
2055
2048
|
I = "caption";
|
2056
|
-
const U = (
|
2049
|
+
const U = (Pt = f.value) == null ? void 0 : Pt.payload, G = [];
|
2057
2050
|
for (const rt of U) {
|
2058
2051
|
const K = ui(rt, {
|
2059
2052
|
size: l.size
|
2060
2053
|
});
|
2061
2054
|
G.push(K);
|
2062
2055
|
}
|
2063
|
-
const
|
2064
|
-
for (const rt of
|
2056
|
+
const M = await Promise.all(G), ut = [];
|
2057
|
+
for (const rt of M) {
|
2065
2058
|
const K = rt.id;
|
2066
|
-
|
2067
|
-
const { details:
|
2059
|
+
ut.push(K);
|
2060
|
+
const { details: lt, ...V } = rt;
|
2068
2061
|
l.trackItemDetailsMap[K] = {
|
2069
2062
|
type: I,
|
2070
|
-
details:
|
2063
|
+
details: lt
|
2071
2064
|
}, l.trackItemsMap[K] = V, l.trackItemIds.push(K);
|
2072
2065
|
}
|
2073
|
-
g =
|
2066
|
+
g = ut;
|
2074
2067
|
}
|
2075
2068
|
if (f.key === $i) {
|
2076
2069
|
I = "text";
|
2077
|
-
const U = await li((
|
2070
|
+
const U = await li((xt = f.value) == null ? void 0 : xt.payload, {
|
2078
2071
|
size: l.size
|
2079
|
-
}), { details: G, ...
|
2080
|
-
l.trackItemDetailsMap[
|
2072
|
+
}), { details: G, ...M } = U;
|
2073
|
+
l.trackItemDetailsMap[M.id] = {
|
2081
2074
|
type: I,
|
2082
2075
|
details: G
|
2083
|
-
}, l.trackItemsMap[
|
2076
|
+
}, l.trackItemsMap[M.id] = M, l.trackItemIds.push(M.id), g = [M.id];
|
2084
2077
|
}
|
2085
2078
|
if (f.key === Ni) {
|
2086
2079
|
I = "template";
|
2087
|
-
const U = (Vt = f.value) == null ? void 0 : Vt.payload.trackItemsMap, G = (Jt = f.value) == null ? void 0 : Jt.payload.trackItemDetailsMap,
|
2080
|
+
const U = (Vt = f.value) == null ? void 0 : Vt.payload.trackItemsMap, G = (Jt = f.value) == null ? void 0 : Jt.payload.trackItemDetailsMap, M = (Zt = f.value) == null ? void 0 : Zt.payload.transitionsMap, ut = ((qt = f.value) == null ? void 0 : qt.payload.transitionIds) || [], rt = (N = f.value) == null ? void 0 : N.payload.trackItemIds, K = ((Qt = f.value) == null ? void 0 : Qt.payload.tracks) || [], { details: lt, ...V } = await ca((te = f.value) == null ? void 0 : te.payload, {
|
2088
2081
|
size: l.size
|
2089
2082
|
}), Y = {
|
2090
2083
|
id: V.id,
|
2091
2084
|
items: rt,
|
2092
|
-
transitions:
|
2085
|
+
transitions: ut,
|
2093
2086
|
tracks: K
|
2094
2087
|
};
|
2095
2088
|
l.trackItemDetailsMap[V.id] = {
|
2096
2089
|
type: I,
|
2097
|
-
details:
|
2090
|
+
details: lt
|
2098
2091
|
}, l.trackItemsMap[V.id] = V, l.trackItemIds.push(V.id), g = [V.id], l.trackItemsMap = {
|
2099
2092
|
...l.trackItemsMap,
|
2100
2093
|
...U,
|
@@ -2107,56 +2100,56 @@ function ha(t) {
|
|
2107
2100
|
...G,
|
2108
2101
|
[V.id]: {
|
2109
2102
|
type: "template",
|
2110
|
-
details:
|
2103
|
+
details: lt
|
2111
2104
|
}
|
2112
2105
|
}, l.transitionsMap = {
|
2113
2106
|
...l.transitionsMap,
|
2114
|
-
...
|
2107
|
+
...M
|
2115
2108
|
}, l.structure = [...l.structure, Y];
|
2116
2109
|
}
|
2117
2110
|
if (f.key === Hi) {
|
2118
2111
|
I = "image";
|
2119
2112
|
const U = await ci((at = f.value) == null ? void 0 : at.payload, {
|
2120
2113
|
size: l.size
|
2121
|
-
}), { details: G, ...
|
2122
|
-
l.trackItemDetailsMap[
|
2114
|
+
}), { details: G, ...M } = U;
|
2115
|
+
l.trackItemDetailsMap[M.id] = {
|
2123
2116
|
type: I,
|
2124
2117
|
details: G
|
2125
|
-
}, l.trackItemsMap[
|
2118
|
+
}, l.trackItemsMap[M.id] = M, l.trackItemIds.push(M.id), g = [M.id];
|
2126
2119
|
}
|
2127
|
-
if (f.key ===
|
2120
|
+
if (f.key === ji) {
|
2128
2121
|
I = "audio";
|
2129
|
-
const U = await oi((Ct = f.value) == null ? void 0 : Ct.payload), { details: G, ...
|
2130
|
-
l.trackItemDetailsMap[
|
2122
|
+
const U = await oi((Ct = f.value) == null ? void 0 : Ct.payload), { details: G, ...M } = U;
|
2123
|
+
l.trackItemDetailsMap[M.id] = {
|
2131
2124
|
type: I,
|
2132
2125
|
details: G
|
2133
|
-
}, l.trackItemsMap[
|
2126
|
+
}, l.trackItemsMap[M.id] = M, l.trackItemIds.push(M.id), g = [M.id];
|
2134
2127
|
}
|
2135
|
-
if (f.key ===
|
2128
|
+
if (f.key === zi) {
|
2136
2129
|
I = "video";
|
2137
2130
|
const U = await si((H = f.value) == null ? void 0 : H.payload, {
|
2138
2131
|
size: l.size
|
2139
|
-
}), { details: G, ...
|
2140
|
-
l.trackItemDetailsMap[
|
2132
|
+
}), { details: G, ...M } = U;
|
2133
|
+
l.trackItemDetailsMap[M.id] = {
|
2141
2134
|
type: I,
|
2142
2135
|
details: G
|
2143
|
-
}, l.trackItemsMap[
|
2136
|
+
}, l.trackItemsMap[M.id] = M, l.trackItemIds.push(M.id), g = [M.id];
|
2144
2137
|
}
|
2145
|
-
const
|
2138
|
+
const m = pa(
|
2146
2139
|
g,
|
2147
2140
|
l.tracks,
|
2148
2141
|
l.trackItemsMap,
|
2149
2142
|
b,
|
2150
|
-
|
2143
|
+
p
|
2151
2144
|
);
|
2152
|
-
if (
|
2145
|
+
if (m.trackId) {
|
2153
2146
|
const U = l.tracks.find(
|
2154
|
-
(G) => G.id ===
|
2147
|
+
(G) => G.id === m.trackId
|
2155
2148
|
);
|
2156
2149
|
U && U.items.push(...g);
|
2157
|
-
} else if (
|
2150
|
+
} else if (m.trackIndex !== void 0) {
|
2158
2151
|
const U = {
|
2159
|
-
id:
|
2152
|
+
id: ur(),
|
2160
2153
|
accepts: [
|
2161
2154
|
"text",
|
2162
2155
|
"audio",
|
@@ -2171,10 +2164,10 @@ function ha(t) {
|
|
2171
2164
|
magnetic: !1,
|
2172
2165
|
static: !1
|
2173
2166
|
};
|
2174
|
-
l.tracks.splice(
|
2167
|
+
l.tracks.splice(m.trackIndex, 0, U);
|
2175
2168
|
} else
|
2176
2169
|
l.tracks.unshift({
|
2177
|
-
id:
|
2170
|
+
id: ur(),
|
2178
2171
|
accepts: [
|
2179
2172
|
"text",
|
2180
2173
|
"audio",
|
@@ -2189,7 +2182,7 @@ function ha(t) {
|
|
2189
2182
|
magnetic: !1,
|
2190
2183
|
static: !1
|
2191
2184
|
});
|
2192
|
-
|
2185
|
+
h && (l.activeIds = g), l.duration = Yt(l.trackItemsMap), t.updateState(
|
2193
2186
|
{
|
2194
2187
|
activeIds: l.activeIds,
|
2195
2188
|
trackItemIds: l.trackItemIds,
|
@@ -2208,14 +2201,14 @@ function ha(t) {
|
|
2208
2201
|
}), F = c.subscribe(async (f) => {
|
2209
2202
|
var l;
|
2210
2203
|
if (f.key === Ui) {
|
2211
|
-
const
|
2212
|
-
if (
|
2213
|
-
const I =
|
2204
|
+
const h = et(t.getState()), g = (l = f.value) == null ? void 0 : l.options.time;
|
2205
|
+
if (h.activeIds.length === 1) {
|
2206
|
+
const I = h.activeIds[0], b = h.trackItemsMap[I];
|
2214
2207
|
if (g >= b.display.to || g <= b.display.from)
|
2215
2208
|
return;
|
2216
|
-
const
|
2209
|
+
const p = h.trackItemDetailsMap[I], m = he(), k = {
|
2217
2210
|
...b,
|
2218
|
-
id:
|
2211
|
+
id: m,
|
2219
2212
|
display: {
|
2220
2213
|
from: g,
|
2221
2214
|
to: b.display.to
|
@@ -2225,14 +2218,14 @@ function ha(t) {
|
|
2225
2218
|
to: b.display.to
|
2226
2219
|
}
|
2227
2220
|
};
|
2228
|
-
|
2229
|
-
|
2221
|
+
h.trackItemsMap[I].display.to = g, h.trackItemsMap[m] = k, h.trackItemIds.push(m), h.trackItemDetailsMap[m] = p, h.tracks.forEach((O) => {
|
2222
|
+
O.items.includes(I) && O.items.push(m);
|
2230
2223
|
}), t.updateState(
|
2231
2224
|
{
|
2232
|
-
trackItemDetailsMap:
|
2233
|
-
tracks:
|
2234
|
-
trackItemIds:
|
2235
|
-
trackItemsMap:
|
2225
|
+
trackItemDetailsMap: h.trackItemDetailsMap,
|
2226
|
+
tracks: h.tracks,
|
2227
|
+
trackItemIds: h.trackItemIds,
|
2228
|
+
trackItemsMap: h.trackItemsMap
|
2236
2229
|
},
|
2237
2230
|
{
|
2238
2231
|
updateHistory: !0,
|
@@ -2243,48 +2236,48 @@ function ha(t) {
|
|
2243
2236
|
return;
|
2244
2237
|
}
|
2245
2238
|
if (f.key === Gi) {
|
2246
|
-
const
|
2247
|
-
if (
|
2248
|
-
const g =
|
2239
|
+
const h = et(t.getState());
|
2240
|
+
if (h.activeIds.length) {
|
2241
|
+
const g = h.activeIds, I = [], b = {
|
2249
2242
|
activeIds: g,
|
2250
2243
|
trackItemDetailsMap: {},
|
2251
2244
|
trackItemsMap: {},
|
2252
2245
|
tracks: []
|
2253
2246
|
};
|
2254
|
-
g.forEach((
|
2255
|
-
b.trackItemDetailsMap[
|
2256
|
-
|
2247
|
+
g.forEach((m) => {
|
2248
|
+
b.trackItemDetailsMap[m] = h.trackItemDetailsMap[m], b.trackItemsMap[m] = h.trackItemsMap[m], I.push(
|
2249
|
+
h.tracks.find((k) => k.items.includes(m))
|
2257
2250
|
);
|
2258
2251
|
});
|
2259
|
-
const
|
2260
|
-
I.filter((
|
2252
|
+
const p = /* @__PURE__ */ new Set();
|
2253
|
+
I.filter((m) => p.has(m.id) ? !1 : (p.add(m), !0)), b.tracks = Array.from(p.keys()), localStorage.setItem("DesignComboTemp", JSON.stringify(b));
|
2261
2254
|
}
|
2262
2255
|
}
|
2263
2256
|
if (f.key === Yi) {
|
2264
|
-
const
|
2265
|
-
if (!
|
2266
|
-
const g = et(t.getState()), I = JSON.parse(
|
2267
|
-
const
|
2268
|
-
(
|
2257
|
+
const h = localStorage.getItem("DesignComboTemp");
|
2258
|
+
if (!h) return;
|
2259
|
+
const g = et(t.getState()), I = JSON.parse(h), b = {}, p = I.trackItemsMap, m = I.trackItemDetailsMap, k = I.tracks, O = [], w = I.activeIds.map(async (x) => {
|
2260
|
+
const R = m[x];
|
2261
|
+
(R.type === "caption" || R.type === "text") && R.details.fontUrl && await dr([
|
2269
2262
|
{
|
2270
|
-
fontFamily:
|
2271
|
-
url:
|
2263
|
+
fontFamily: R.details.fontFamily,
|
2264
|
+
url: R.details.fontUrl
|
2272
2265
|
}
|
2273
2266
|
]);
|
2274
|
-
const P =
|
2267
|
+
const P = he();
|
2275
2268
|
return b[x] = P, g.trackItemsMap[P] = {
|
2276
|
-
...
|
2269
|
+
...p[x],
|
2277
2270
|
id: P
|
2278
|
-
}, g.trackItemDetailsMap[P] =
|
2271
|
+
}, g.trackItemDetailsMap[P] = R, g.trackItemIds.push(P), !0;
|
2279
2272
|
});
|
2280
|
-
await Promise.all(w),
|
2281
|
-
const
|
2273
|
+
await Promise.all(w), k.forEach((x) => {
|
2274
|
+
const R = x.items.map((E) => b[E]), P = {
|
2282
2275
|
...x,
|
2283
|
-
items:
|
2284
|
-
id:
|
2276
|
+
items: R,
|
2277
|
+
id: ur()
|
2285
2278
|
};
|
2286
|
-
|
2287
|
-
}), g.tracks = [...g.tracks, ...
|
2279
|
+
O.push(P);
|
2280
|
+
}), g.tracks = [...g.tracks, ...O], t.updateState(
|
2288
2281
|
{
|
2289
2282
|
trackItemDetailsMap: g.trackItemDetailsMap,
|
2290
2283
|
tracks: g.tracks,
|
@@ -2298,24 +2291,24 @@ function ha(t) {
|
|
2298
2291
|
);
|
2299
2292
|
}
|
2300
2293
|
}), _ = d.subscribe(async (f) => {
|
2301
|
-
var l,
|
2294
|
+
var l, h, g;
|
2302
2295
|
if (f.key === Wi) {
|
2303
|
-
const I = et(t.getState()), b = I.trackItemDetailsMap,
|
2304
|
-
if (!
|
2305
|
-
const
|
2306
|
-
|
2307
|
-
const x =
|
2296
|
+
const I = et(t.getState()), b = I.trackItemDetailsMap, p = I.trackItemsMap, m = Object.keys((l = f.value) == null ? void 0 : l.payload);
|
2297
|
+
if (!m.length) return;
|
2298
|
+
const k = (h = f.value) == null ? void 0 : h.payload;
|
2299
|
+
m.forEach((w) => {
|
2300
|
+
const x = k[w];
|
2308
2301
|
x.details ? b[w].details = {
|
2309
2302
|
...b[w].details,
|
2310
2303
|
...x.details
|
2311
|
-
} :
|
2304
|
+
} : k[w].playbackRate && (p[w].playbackRate = k[w].playbackRate);
|
2312
2305
|
});
|
2313
|
-
const
|
2306
|
+
const O = Yt(p);
|
2314
2307
|
t.updateState(
|
2315
2308
|
{
|
2316
2309
|
trackItemDetailsMap: { ...b },
|
2317
|
-
trackItemsMap: { ...
|
2318
|
-
duration:
|
2310
|
+
trackItemsMap: { ...p },
|
2311
|
+
duration: O
|
2319
2312
|
},
|
2320
2313
|
{
|
2321
2314
|
updateHistory: !0,
|
@@ -2324,34 +2317,34 @@ function ha(t) {
|
|
2324
2317
|
);
|
2325
2318
|
}
|
2326
2319
|
if (f.key === Xi) {
|
2327
|
-
const I = (g = f.value) == null ? void 0 : g.payload, b = Object.keys(I)[0],
|
2328
|
-
if (
|
2329
|
-
if (
|
2330
|
-
const x = await ri(
|
2331
|
-
let
|
2332
|
-
const
|
2333
|
-
|
2320
|
+
const I = (g = f.value) == null ? void 0 : g.payload, b = Object.keys(I)[0], p = Object.values(I)[0], m = et(t.getState()), k = m.trackItemDetailsMap[b];
|
2321
|
+
if (p.details) {
|
2322
|
+
if (p.type === "image" && p.details.src) {
|
2323
|
+
const x = await ri(p.details.src), R = k.details.width || 0, P = k.details.height || 0;
|
2324
|
+
let E = x.width, D = x.height;
|
2325
|
+
const z = x.width / x.height;
|
2326
|
+
R / P > z ? (E = R, D = R / z) : (D = P, E = P * z), p.details.mediaWidth = E, p.details.mediaHeight = D;
|
2334
2327
|
}
|
2335
|
-
if (
|
2336
|
-
const x = await ni(
|
2337
|
-
let
|
2338
|
-
const
|
2339
|
-
|
2328
|
+
if (p.type === "video" && p.details.src) {
|
2329
|
+
const x = await ni(p.details.src), R = k.details.width || 0, P = k.details.height || 0;
|
2330
|
+
let E = x.width, D = x.height;
|
2331
|
+
const z = x.width / x.height;
|
2332
|
+
R / P > z ? (E = R, D = R / z) : (D = P, E = P * z), p.details.mediaWidth = E, p.details.mediaHeight = D;
|
2340
2333
|
}
|
2341
|
-
const w =
|
2342
|
-
|
2334
|
+
const w = k.details;
|
2335
|
+
k.details = { ...w, ...p.details }, p.details = k.details;
|
2343
2336
|
}
|
2344
|
-
const
|
2345
|
-
|
2346
|
-
...
|
2347
|
-
type:
|
2337
|
+
const O = { ...k, ...p };
|
2338
|
+
m.trackItemDetailsMap[b] = O, m.trackItemsMap[b] = {
|
2339
|
+
...m.trackItemsMap[b],
|
2340
|
+
type: p.type
|
2348
2341
|
}, t.updateState(
|
2349
2342
|
{
|
2350
2343
|
trackItemDetailsMap: {
|
2351
|
-
...
|
2344
|
+
...m.trackItemDetailsMap
|
2352
2345
|
},
|
2353
2346
|
trackItemsMap: {
|
2354
|
-
...
|
2347
|
+
...m.trackItemsMap
|
2355
2348
|
}
|
2356
2349
|
},
|
2357
2350
|
{
|
@@ -2363,29 +2356,29 @@ function ha(t) {
|
|
2363
2356
|
});
|
2364
2357
|
return {
|
2365
2358
|
unsubscribe: () => {
|
2366
|
-
S.unsubscribe(), F.unsubscribe(), _.unsubscribe(), T.unsubscribe(),
|
2359
|
+
S.unsubscribe(), F.unsubscribe(), _.unsubscribe(), T.unsubscribe(), C.unsubscribe(), y.unsubscribe();
|
2367
2360
|
}
|
2368
2361
|
};
|
2369
2362
|
}
|
2370
2363
|
const ma = { Date: !0, RegExp: !0, String: !0, Number: !0 };
|
2371
2364
|
function di(t, r, n = { cyclesFix: !0 }, i = []) {
|
2372
|
-
var
|
2365
|
+
var y, T;
|
2373
2366
|
let s = [];
|
2374
2367
|
const c = Array.isArray(t);
|
2375
|
-
for (const
|
2376
|
-
const S = t[
|
2377
|
-
if (!(
|
2368
|
+
for (const C in t) {
|
2369
|
+
const S = t[C], F = c ? +C : C;
|
2370
|
+
if (!(C in r)) {
|
2378
2371
|
s.push({
|
2379
2372
|
type: "REMOVE",
|
2380
2373
|
path: [F],
|
2381
|
-
oldValue: t[
|
2374
|
+
oldValue: t[C]
|
2382
2375
|
});
|
2383
2376
|
continue;
|
2384
2377
|
}
|
2385
|
-
const _ = r[
|
2386
|
-
if (S && _ && f && !ma[(T = (
|
2378
|
+
const _ = r[C], f = typeof S == "object" && typeof _ == "object" && Array.isArray(S) === Array.isArray(_);
|
2379
|
+
if (S && _ && f && !ma[(T = (y = Object.getPrototypeOf(S)) == null ? void 0 : y.constructor) == null ? void 0 : T.name] && (!n.cyclesFix || !i.includes(S))) {
|
2387
2380
|
const l = di(S, _, n, n.cyclesFix ? i.concat([S]) : []);
|
2388
|
-
s.push.apply(s, l.map((
|
2381
|
+
s.push.apply(s, l.map((h) => (h.path.unshift(F), h)));
|
2389
2382
|
} else S !== _ && // treat NaN values as equivalent
|
2390
2383
|
!(Number.isNaN(S) && Number.isNaN(_)) && !(f && (isNaN(S) ? S + "" == _ + "" : +S == +_)) && s.push({
|
2391
2384
|
path: [F],
|
@@ -2395,15 +2388,15 @@ function di(t, r, n = { cyclesFix: !0 }, i = []) {
|
|
2395
2388
|
});
|
2396
2389
|
}
|
2397
2390
|
const d = Array.isArray(r);
|
2398
|
-
for (const
|
2399
|
-
|
2391
|
+
for (const C in r)
|
2392
|
+
C in t || s.push({
|
2400
2393
|
type: "CREATE",
|
2401
|
-
path: [d ? +
|
2402
|
-
value: r[
|
2394
|
+
path: [d ? +C : C],
|
2395
|
+
value: r[C]
|
2403
2396
|
});
|
2404
2397
|
return s;
|
2405
2398
|
}
|
2406
|
-
var
|
2399
|
+
var wn = Symbol.for("immer-nothing"), xe = Symbol.for("immer-draftable"), ft = Symbol.for("immer-state"), pi = process.env.NODE_ENV !== "production" ? [
|
2407
2400
|
// All error codes, starting by 0:
|
2408
2401
|
function(t) {
|
2409
2402
|
return `The plugin for '${t}' has not been loaded into Immer. To enable the plugin, import and call \`enable${t}()\` when initializing your application.`;
|
@@ -2445,11 +2438,11 @@ function B(t, ...r) {
|
|
2445
2438
|
}
|
2446
2439
|
var Wt = Object.getPrototypeOf;
|
2447
2440
|
function Xt(t) {
|
2448
|
-
return !!t && !!t[
|
2441
|
+
return !!t && !!t[ft];
|
2449
2442
|
}
|
2450
|
-
function
|
2443
|
+
function Ot(t) {
|
2451
2444
|
var r;
|
2452
|
-
return t ? hi(t) || Array.isArray(t) || !!t[
|
2445
|
+
return t ? hi(t) || Array.isArray(t) || !!t[xe] || !!((r = t.constructor) != null && r[xe]) || He(t) || je(t) : !1;
|
2453
2446
|
}
|
2454
2447
|
var ya = Object.prototype.constructor.toString();
|
2455
2448
|
function hi(t) {
|
@@ -2461,16 +2454,16 @@ function hi(t) {
|
|
2461
2454
|
const n = Object.hasOwnProperty.call(r, "constructor") && r.constructor;
|
2462
2455
|
return n === Object ? !0 : typeof n == "function" && Function.toString.call(n) === ya;
|
2463
2456
|
}
|
2464
|
-
function
|
2457
|
+
function Ce(t, r) {
|
2465
2458
|
Bt(t) === 0 ? Reflect.ownKeys(t).forEach((n) => {
|
2466
2459
|
r(n, t[n], t);
|
2467
2460
|
}) : t.forEach((n, i) => r(i, n, t));
|
2468
2461
|
}
|
2469
2462
|
function Bt(t) {
|
2470
|
-
const r = t[
|
2471
|
-
return r ? r.type_ : Array.isArray(t) ? 1 :
|
2463
|
+
const r = t[ft];
|
2464
|
+
return r ? r.type_ : Array.isArray(t) ? 1 : He(t) ? 2 : je(t) ? 3 : 0;
|
2472
2465
|
}
|
2473
|
-
function
|
2466
|
+
function Re(t, r) {
|
2474
2467
|
return Bt(t) === 2 ? t.has(r) : Object.prototype.hasOwnProperty.call(t, r);
|
2475
2468
|
}
|
2476
2469
|
function un(t, r) {
|
@@ -2483,7 +2476,7 @@ function mi(t, r, n) {
|
|
2483
2476
|
function _a(t, r) {
|
2484
2477
|
return t === r ? t !== 0 || 1 / t === 1 / r : t !== t && r !== r;
|
2485
2478
|
}
|
2486
|
-
function
|
2479
|
+
function He(t) {
|
2487
2480
|
return t instanceof Map;
|
2488
2481
|
}
|
2489
2482
|
function je(t) {
|
@@ -2493,7 +2486,7 @@ function Gt(t) {
|
|
2493
2486
|
return t.copy_ || t.base_;
|
2494
2487
|
}
|
2495
2488
|
function gn(t, r) {
|
2496
|
-
if (
|
2489
|
+
if (He(t))
|
2497
2490
|
return new Map(t);
|
2498
2491
|
if (je(t))
|
2499
2492
|
return new Set(t);
|
@@ -2502,15 +2495,15 @@ function gn(t, r) {
|
|
2502
2495
|
const n = hi(t);
|
2503
2496
|
if (r === !0 || r === "class_only" && !n) {
|
2504
2497
|
const i = Object.getOwnPropertyDescriptors(t);
|
2505
|
-
delete i[
|
2498
|
+
delete i[ft];
|
2506
2499
|
let s = Reflect.ownKeys(i);
|
2507
2500
|
for (let c = 0; c < s.length; c++) {
|
2508
|
-
const d = s[c],
|
2509
|
-
|
2501
|
+
const d = s[c], y = i[d];
|
2502
|
+
y.writable === !1 && (y.writable = !0, y.configurable = !0), (y.get || y.set) && (i[d] = {
|
2510
2503
|
configurable: !0,
|
2511
2504
|
writable: !0,
|
2512
2505
|
// could live with !!desc.set as well here...
|
2513
|
-
enumerable:
|
2506
|
+
enumerable: y.enumerable,
|
2514
2507
|
value: t[d]
|
2515
2508
|
});
|
2516
2509
|
}
|
@@ -2524,7 +2517,7 @@ function gn(t, r) {
|
|
2524
2517
|
}
|
2525
2518
|
}
|
2526
2519
|
function An(t, r = !1) {
|
2527
|
-
return Ir(t) || Xt(t) || !
|
2520
|
+
return Ir(t) || Xt(t) || !Ot(t) || (Bt(t) > 1 && (t.set = t.add = t.clear = t.delete = Ia), Object.freeze(t), r && Object.entries(t).forEach(([n, i]) => An(i, !0))), t;
|
2528
2521
|
}
|
2529
2522
|
function Ia() {
|
2530
2523
|
B(2);
|
@@ -2540,9 +2533,9 @@ function Kt(t) {
|
|
2540
2533
|
function ga(t, r) {
|
2541
2534
|
bn[t] || (bn[t] = r);
|
2542
2535
|
}
|
2543
|
-
var
|
2536
|
+
var Le;
|
2544
2537
|
function yi() {
|
2545
|
-
return
|
2538
|
+
return Le;
|
2546
2539
|
}
|
2547
2540
|
function ba(t, r) {
|
2548
2541
|
return {
|
@@ -2562,31 +2555,31 @@ function vn(t) {
|
|
2562
2555
|
Sn(t), t.drafts_.forEach(va), t.drafts_ = null;
|
2563
2556
|
}
|
2564
2557
|
function Sn(t) {
|
2565
|
-
t ===
|
2558
|
+
t === Le && (Le = t.parent_);
|
2566
2559
|
}
|
2567
|
-
function
|
2568
|
-
return
|
2560
|
+
function jn(t) {
|
2561
|
+
return Le = ba(Le, t);
|
2569
2562
|
}
|
2570
2563
|
function va(t) {
|
2571
|
-
const r = t[
|
2564
|
+
const r = t[ft];
|
2572
2565
|
r.type_ === 0 || r.type_ === 1 ? r.revoke_() : r.revoked_ = !0;
|
2573
2566
|
}
|
2574
|
-
function
|
2567
|
+
function zn(t, r) {
|
2575
2568
|
r.unfinalizedDrafts_ = r.drafts_.length;
|
2576
2569
|
const n = r.drafts_[0];
|
2577
|
-
return t !== void 0 && t !== n ? (n[
|
2578
|
-
n[
|
2570
|
+
return t !== void 0 && t !== n ? (n[ft].modified_ && (vn(r), B(4)), Ot(t) && (t = pr(r, t), r.parent_ || hr(r, t)), r.patches_ && Kt("Patches").generateReplacementPatches_(
|
2571
|
+
n[ft].base_,
|
2579
2572
|
t,
|
2580
2573
|
r.patches_,
|
2581
2574
|
r.inversePatches_
|
2582
|
-
)) : t = pr(r, n, []), vn(r), r.patches_ && r.patchListener_(r.patches_, r.inversePatches_), t !==
|
2575
|
+
)) : t = pr(r, n, []), vn(r), r.patches_ && r.patchListener_(r.patches_, r.inversePatches_), t !== wn ? t : void 0;
|
2583
2576
|
}
|
2584
2577
|
function pr(t, r, n) {
|
2585
2578
|
if (Ir(r))
|
2586
2579
|
return r;
|
2587
|
-
const i = r[
|
2580
|
+
const i = r[ft];
|
2588
2581
|
if (!i)
|
2589
|
-
return
|
2582
|
+
return Ce(
|
2590
2583
|
r,
|
2591
2584
|
(s, c) => Un(t, i, r, s, c, n)
|
2592
2585
|
), r;
|
@@ -2598,9 +2591,9 @@ function pr(t, r, n) {
|
|
2598
2591
|
i.finalized_ = !0, i.scope_.unfinalizedDrafts_--;
|
2599
2592
|
const s = i.copy_;
|
2600
2593
|
let c = s, d = !1;
|
2601
|
-
i.type_ === 3 && (c = new Set(s), s.clear(), d = !0),
|
2594
|
+
i.type_ === 3 && (c = new Set(s), s.clear(), d = !0), Ce(
|
2602
2595
|
c,
|
2603
|
-
(
|
2596
|
+
(y, T) => Un(t, i, s, y, T, n, d)
|
2604
2597
|
), hr(t, s, !1), n && t.patches_ && Kt("Patches").generatePatches_(
|
2605
2598
|
i,
|
2606
2599
|
n,
|
@@ -2612,14 +2605,14 @@ function pr(t, r, n) {
|
|
2612
2605
|
}
|
2613
2606
|
function Un(t, r, n, i, s, c, d) {
|
2614
2607
|
if (process.env.NODE_ENV !== "production" && s === n && B(5), Xt(s)) {
|
2615
|
-
const
|
2616
|
-
!
|
2608
|
+
const y = c && r && r.type_ !== 3 && // Set objects are atomic since they have no keys.
|
2609
|
+
!Re(r.assigned_, i) ? c.concat(i) : void 0, T = pr(t, s, y);
|
2617
2610
|
if (mi(n, i, T), Xt(T))
|
2618
2611
|
t.canAutoFreeze_ = !1;
|
2619
2612
|
else
|
2620
2613
|
return;
|
2621
2614
|
} else d && n.add(s);
|
2622
|
-
if (
|
2615
|
+
if (Ot(s) && !Ir(s)) {
|
2623
2616
|
if (!t.immer_.autoFreeze_ && t.unfinalizedDrafts_ < 1)
|
2624
2617
|
return;
|
2625
2618
|
pr(t, s), (!r || !r.scope_.parent_) && typeof i != "symbol" && Object.prototype.propertyIsEnumerable.call(n, i) && hr(t, s);
|
@@ -2653,19 +2646,19 @@ function Sa(t, r) {
|
|
2653
2646
|
isManual_: !1
|
2654
2647
|
};
|
2655
2648
|
let s = i, c = Dn;
|
2656
|
-
n && (s = [i], c =
|
2657
|
-
const { revoke: d, proxy:
|
2658
|
-
return i.draft_ =
|
2649
|
+
n && (s = [i], c = Fe);
|
2650
|
+
const { revoke: d, proxy: y } = Proxy.revocable(s, c);
|
2651
|
+
return i.draft_ = y, i.revoke_ = d, y;
|
2659
2652
|
}
|
2660
2653
|
var Dn = {
|
2661
2654
|
get(t, r) {
|
2662
|
-
if (r ===
|
2655
|
+
if (r === ft)
|
2663
2656
|
return t;
|
2664
2657
|
const n = Gt(t);
|
2665
|
-
if (!
|
2658
|
+
if (!Re(n, r))
|
2666
2659
|
return Ea(t, n, r);
|
2667
2660
|
const i = n[r];
|
2668
|
-
return t.finalized_ || !
|
2661
|
+
return t.finalized_ || !Ot(i) ? i : i === ln(t.base_, r) ? (fn(t), t.copy_[r] = Tn(i, t)) : i;
|
2669
2662
|
},
|
2670
2663
|
has(t, r) {
|
2671
2664
|
return r in Gt(t);
|
@@ -2678,10 +2671,10 @@ var Dn = {
|
|
2678
2671
|
if (i != null && i.set)
|
2679
2672
|
return i.set.call(t.draft_, n), !0;
|
2680
2673
|
if (!t.modified_) {
|
2681
|
-
const s = ln(Gt(t), r), c = s == null ? void 0 : s[
|
2674
|
+
const s = ln(Gt(t), r), c = s == null ? void 0 : s[ft];
|
2682
2675
|
if (c && c.base_ === n)
|
2683
2676
|
return t.copy_[r] = n, t.assigned_[r] = !1, !0;
|
2684
|
-
if (_a(n, s) && (n !== void 0 ||
|
2677
|
+
if (_a(n, s) && (n !== void 0 || Re(t.base_, r)))
|
2685
2678
|
return !0;
|
2686
2679
|
fn(t), En(t);
|
2687
2680
|
}
|
@@ -2712,20 +2705,20 @@ var Dn = {
|
|
2712
2705
|
setPrototypeOf() {
|
2713
2706
|
B(12);
|
2714
2707
|
}
|
2715
|
-
},
|
2716
|
-
|
2717
|
-
|
2708
|
+
}, Fe = {};
|
2709
|
+
Ce(Dn, (t, r) => {
|
2710
|
+
Fe[t] = function() {
|
2718
2711
|
return arguments[0] = arguments[0][0], r.apply(this, arguments);
|
2719
2712
|
};
|
2720
2713
|
});
|
2721
|
-
|
2722
|
-
return process.env.NODE_ENV !== "production" && isNaN(parseInt(r)) && B(13),
|
2714
|
+
Fe.deleteProperty = function(t, r) {
|
2715
|
+
return process.env.NODE_ENV !== "production" && isNaN(parseInt(r)) && B(13), Fe.set.call(this, t, r, void 0);
|
2723
2716
|
};
|
2724
|
-
|
2717
|
+
Fe.set = function(t, r, n) {
|
2725
2718
|
return process.env.NODE_ENV !== "production" && r !== "length" && isNaN(parseInt(r)) && B(14), Dn.set.call(this, t[0], r, n, t[0]);
|
2726
2719
|
};
|
2727
2720
|
function ln(t, r) {
|
2728
|
-
const n = t[
|
2721
|
+
const n = t[ft];
|
2729
2722
|
return (n ? Gt(n) : t)[r];
|
2730
2723
|
}
|
2731
2724
|
function Ea(t, r, n) {
|
@@ -2764,23 +2757,23 @@ var Ta = class {
|
|
2764
2757
|
const c = n;
|
2765
2758
|
n = r;
|
2766
2759
|
const d = this;
|
2767
|
-
return function(T = c, ...
|
2768
|
-
return d.produce(T, (S) => n.call(this, S, ...
|
2760
|
+
return function(T = c, ...C) {
|
2761
|
+
return d.produce(T, (S) => n.call(this, S, ...C));
|
2769
2762
|
};
|
2770
2763
|
}
|
2771
2764
|
typeof n != "function" && B(6), i !== void 0 && typeof i != "function" && B(7);
|
2772
2765
|
let s;
|
2773
|
-
if (
|
2774
|
-
const c =
|
2775
|
-
let
|
2766
|
+
if (Ot(r)) {
|
2767
|
+
const c = jn(this), d = Tn(r, void 0);
|
2768
|
+
let y = !0;
|
2776
2769
|
try {
|
2777
|
-
s = n(d),
|
2770
|
+
s = n(d), y = !1;
|
2778
2771
|
} finally {
|
2779
|
-
|
2772
|
+
y ? vn(c) : Sn(c);
|
2780
2773
|
}
|
2781
|
-
return Hn(c, i),
|
2774
|
+
return Hn(c, i), zn(s, c);
|
2782
2775
|
} else if (!r || typeof r != "object") {
|
2783
|
-
if (s = n(r), s === void 0 && (s = r), s ===
|
2776
|
+
if (s = n(r), s === void 0 && (s = r), s === wn && (s = void 0), this.autoFreeze_ && An(s, !0), i) {
|
2784
2777
|
const c = [], d = [];
|
2785
2778
|
Kt("Patches").generateReplacementPatches_(r, s, c, d), i(c, d);
|
2786
2779
|
}
|
@@ -2789,23 +2782,23 @@ var Ta = class {
|
|
2789
2782
|
B(1, r);
|
2790
2783
|
}, this.produceWithPatches = (r, n) => {
|
2791
2784
|
if (typeof r == "function")
|
2792
|
-
return (d, ...
|
2785
|
+
return (d, ...y) => this.produceWithPatches(d, (T) => r(T, ...y));
|
2793
2786
|
let i, s;
|
2794
|
-
return [this.produce(r, n, (d,
|
2795
|
-
i = d, s =
|
2787
|
+
return [this.produce(r, n, (d, y) => {
|
2788
|
+
i = d, s = y;
|
2796
2789
|
}), i, s];
|
2797
2790
|
}, typeof (t == null ? void 0 : t.autoFreeze) == "boolean" && this.setAutoFreeze(t.autoFreeze), typeof (t == null ? void 0 : t.useStrictShallowCopy) == "boolean" && this.setUseStrictShallowCopy(t.useStrictShallowCopy);
|
2798
2791
|
}
|
2799
2792
|
createDraft(t) {
|
2800
|
-
|
2801
|
-
const r =
|
2802
|
-
return n[
|
2793
|
+
Ot(t) || B(8), Xt(t) && (t = ka(t));
|
2794
|
+
const r = jn(this), n = Tn(t, void 0);
|
2795
|
+
return n[ft].isManual_ = !0, Sn(r), n;
|
2803
2796
|
}
|
2804
2797
|
finishDraft(t, r) {
|
2805
|
-
const n = t && t[
|
2798
|
+
const n = t && t[ft];
|
2806
2799
|
(!n || !n.isManual_) && B(9);
|
2807
2800
|
const { scope_: i } = n;
|
2808
|
-
return Hn(i, r),
|
2801
|
+
return Hn(i, r), zn(void 0, i);
|
2809
2802
|
}
|
2810
2803
|
/**
|
2811
2804
|
* Pass true to automatically freeze all copies created by Immer.
|
@@ -2841,16 +2834,16 @@ var Ta = class {
|
|
2841
2834
|
}
|
2842
2835
|
};
|
2843
2836
|
function Tn(t, r) {
|
2844
|
-
const n =
|
2837
|
+
const n = He(t) ? Kt("MapSet").proxyMap_(t, r) : je(t) ? Kt("MapSet").proxySet_(t, r) : Sa(t, r);
|
2845
2838
|
return (r ? r.scope_ : yi()).drafts_.push(n), n;
|
2846
2839
|
}
|
2847
|
-
function
|
2840
|
+
function ka(t) {
|
2848
2841
|
return Xt(t) || B(10, t), Ii(t);
|
2849
2842
|
}
|
2850
2843
|
function Ii(t) {
|
2851
|
-
if (!
|
2844
|
+
if (!Ot(t) || Ir(t))
|
2852
2845
|
return t;
|
2853
|
-
const r = t[
|
2846
|
+
const r = t[ft];
|
2854
2847
|
let n;
|
2855
2848
|
if (r) {
|
2856
2849
|
if (!r.modified_)
|
@@ -2858,7 +2851,7 @@ function Ii(t) {
|
|
2858
2851
|
r.finalized_ = !0, n = gn(t, r.scope_.immer_.useStrictShallowCopy_);
|
2859
2852
|
} else
|
2860
2853
|
n = gn(t, !0);
|
2861
|
-
return
|
2854
|
+
return Ce(n, (i, s) => {
|
2862
2855
|
mi(n, i, Ii(s));
|
2863
2856
|
}), r && (r.finalized_ = !1), n;
|
2864
2857
|
}
|
@@ -2874,7 +2867,7 @@ function Gn() {
|
|
2874
2867
|
"Patching reserved attributes like __proto__, prototype and constructor is not allowed"
|
2875
2868
|
);
|
2876
2869
|
const r = "replace", n = "add", i = "remove";
|
2877
|
-
function s(_, f, l,
|
2870
|
+
function s(_, f, l, h) {
|
2878
2871
|
switch (_.type_) {
|
2879
2872
|
case 0:
|
2880
2873
|
case 2:
|
@@ -2882,151 +2875,151 @@ function Gn() {
|
|
2882
2875
|
_,
|
2883
2876
|
f,
|
2884
2877
|
l,
|
2885
|
-
|
2878
|
+
h
|
2886
2879
|
);
|
2887
2880
|
case 1:
|
2888
|
-
return c(_, f, l,
|
2881
|
+
return c(_, f, l, h);
|
2889
2882
|
case 3:
|
2890
|
-
return
|
2883
|
+
return y(
|
2891
2884
|
_,
|
2892
2885
|
f,
|
2893
2886
|
l,
|
2894
|
-
|
2887
|
+
h
|
2895
2888
|
);
|
2896
2889
|
}
|
2897
2890
|
}
|
2898
|
-
function c(_, f, l,
|
2891
|
+
function c(_, f, l, h) {
|
2899
2892
|
let { base_: g, assigned_: I } = _, b = _.copy_;
|
2900
|
-
b.length < g.length && ([g, b] = [b, g], [l,
|
2901
|
-
for (let
|
2902
|
-
if (I[
|
2903
|
-
const
|
2893
|
+
b.length < g.length && ([g, b] = [b, g], [l, h] = [h, l]);
|
2894
|
+
for (let p = 0; p < g.length; p++)
|
2895
|
+
if (I[p] && b[p] !== g[p]) {
|
2896
|
+
const m = f.concat([p]);
|
2904
2897
|
l.push({
|
2905
2898
|
op: r,
|
2906
|
-
path:
|
2899
|
+
path: m,
|
2907
2900
|
// Need to maybe clone it, as it can in fact be the original value
|
2908
2901
|
// due to the base/copy inversion at the start of this function
|
2909
|
-
value: F(b[
|
2910
|
-
}),
|
2902
|
+
value: F(b[p])
|
2903
|
+
}), h.push({
|
2911
2904
|
op: r,
|
2912
|
-
path:
|
2913
|
-
value: F(g[
|
2905
|
+
path: m,
|
2906
|
+
value: F(g[p])
|
2914
2907
|
});
|
2915
2908
|
}
|
2916
|
-
for (let
|
2917
|
-
const
|
2909
|
+
for (let p = g.length; p < b.length; p++) {
|
2910
|
+
const m = f.concat([p]);
|
2918
2911
|
l.push({
|
2919
2912
|
op: n,
|
2920
|
-
path:
|
2913
|
+
path: m,
|
2921
2914
|
// Need to maybe clone it, as it can in fact be the original value
|
2922
2915
|
// due to the base/copy inversion at the start of this function
|
2923
|
-
value: F(b[
|
2916
|
+
value: F(b[p])
|
2924
2917
|
});
|
2925
2918
|
}
|
2926
|
-
for (let
|
2927
|
-
const
|
2928
|
-
|
2919
|
+
for (let p = b.length - 1; g.length <= p; --p) {
|
2920
|
+
const m = f.concat([p]);
|
2921
|
+
h.push({
|
2929
2922
|
op: i,
|
2930
|
-
path:
|
2923
|
+
path: m
|
2931
2924
|
});
|
2932
2925
|
}
|
2933
2926
|
}
|
2934
|
-
function d(_, f, l,
|
2927
|
+
function d(_, f, l, h) {
|
2935
2928
|
const { base_: g, copy_: I } = _;
|
2936
|
-
|
2937
|
-
const
|
2938
|
-
if (
|
2929
|
+
Ce(_.assigned_, (b, p) => {
|
2930
|
+
const m = un(g, b), k = un(I, b), O = p ? Re(g, b) ? r : n : i;
|
2931
|
+
if (m === k && O === r)
|
2939
2932
|
return;
|
2940
2933
|
const w = f.concat(b);
|
2941
|
-
l.push(
|
2942
|
-
|
2934
|
+
l.push(O === i ? { op: O, path: w } : { op: O, path: w, value: k }), h.push(
|
2935
|
+
O === n ? { op: i, path: w } : O === i ? { op: n, path: w, value: F(m) } : { op: r, path: w, value: F(m) }
|
2943
2936
|
);
|
2944
2937
|
});
|
2945
2938
|
}
|
2946
|
-
function
|
2939
|
+
function y(_, f, l, h) {
|
2947
2940
|
let { base_: g, copy_: I } = _, b = 0;
|
2948
|
-
g.forEach((
|
2949
|
-
if (!I.has(
|
2950
|
-
const
|
2941
|
+
g.forEach((p) => {
|
2942
|
+
if (!I.has(p)) {
|
2943
|
+
const m = f.concat([b]);
|
2951
2944
|
l.push({
|
2952
2945
|
op: i,
|
2953
|
-
path:
|
2954
|
-
value:
|
2955
|
-
}),
|
2946
|
+
path: m,
|
2947
|
+
value: p
|
2948
|
+
}), h.unshift({
|
2956
2949
|
op: n,
|
2957
|
-
path:
|
2958
|
-
value:
|
2950
|
+
path: m,
|
2951
|
+
value: p
|
2959
2952
|
});
|
2960
2953
|
}
|
2961
2954
|
b++;
|
2962
|
-
}), b = 0, I.forEach((
|
2963
|
-
if (!g.has(
|
2964
|
-
const
|
2955
|
+
}), b = 0, I.forEach((p) => {
|
2956
|
+
if (!g.has(p)) {
|
2957
|
+
const m = f.concat([b]);
|
2965
2958
|
l.push({
|
2966
2959
|
op: n,
|
2967
|
-
path:
|
2968
|
-
value:
|
2969
|
-
}),
|
2960
|
+
path: m,
|
2961
|
+
value: p
|
2962
|
+
}), h.unshift({
|
2970
2963
|
op: i,
|
2971
|
-
path:
|
2972
|
-
value:
|
2964
|
+
path: m,
|
2965
|
+
value: p
|
2973
2966
|
});
|
2974
2967
|
}
|
2975
2968
|
b++;
|
2976
2969
|
});
|
2977
2970
|
}
|
2978
|
-
function T(_, f, l,
|
2971
|
+
function T(_, f, l, h) {
|
2979
2972
|
l.push({
|
2980
2973
|
op: r,
|
2981
2974
|
path: [],
|
2982
|
-
value: f ===
|
2983
|
-
}),
|
2975
|
+
value: f === wn ? void 0 : f
|
2976
|
+
}), h.push({
|
2984
2977
|
op: r,
|
2985
2978
|
path: [],
|
2986
2979
|
value: _
|
2987
2980
|
});
|
2988
2981
|
}
|
2989
|
-
function
|
2982
|
+
function C(_, f) {
|
2990
2983
|
return f.forEach((l) => {
|
2991
|
-
const { path:
|
2984
|
+
const { path: h, op: g } = l;
|
2992
2985
|
let I = _;
|
2993
|
-
for (let
|
2994
|
-
const
|
2995
|
-
let w =
|
2996
|
-
typeof w != "string" && typeof w != "number" && (w = "" + w), (
|
2986
|
+
for (let k = 0; k < h.length - 1; k++) {
|
2987
|
+
const O = Bt(I);
|
2988
|
+
let w = h[k];
|
2989
|
+
typeof w != "string" && typeof w != "number" && (w = "" + w), (O === 0 || O === 1) && (w === "__proto__" || w === "constructor") && B(19), typeof I == "function" && w === "prototype" && B(19), I = un(I, w), typeof I != "object" && B(18, h.join("/"));
|
2997
2990
|
}
|
2998
|
-
const b = Bt(I),
|
2991
|
+
const b = Bt(I), p = S(l.value), m = h[h.length - 1];
|
2999
2992
|
switch (g) {
|
3000
2993
|
case r:
|
3001
2994
|
switch (b) {
|
3002
2995
|
case 2:
|
3003
|
-
return I.set(
|
2996
|
+
return I.set(m, p);
|
3004
2997
|
case 3:
|
3005
2998
|
B(16);
|
3006
2999
|
default:
|
3007
|
-
return I[
|
3000
|
+
return I[m] = p;
|
3008
3001
|
}
|
3009
3002
|
case n:
|
3010
3003
|
switch (b) {
|
3011
3004
|
case 1:
|
3012
|
-
return
|
3005
|
+
return m === "-" ? I.push(p) : I.splice(m, 0, p);
|
3013
3006
|
case 2:
|
3014
|
-
return I.set(
|
3007
|
+
return I.set(m, p);
|
3015
3008
|
case 3:
|
3016
|
-
return I.add(
|
3009
|
+
return I.add(p);
|
3017
3010
|
default:
|
3018
|
-
return I[
|
3011
|
+
return I[m] = p;
|
3019
3012
|
}
|
3020
3013
|
case i:
|
3021
3014
|
switch (b) {
|
3022
3015
|
case 1:
|
3023
|
-
return I.splice(
|
3016
|
+
return I.splice(m, 1);
|
3024
3017
|
case 2:
|
3025
|
-
return I.delete(
|
3018
|
+
return I.delete(m);
|
3026
3019
|
case 3:
|
3027
3020
|
return I.delete(l.value);
|
3028
3021
|
default:
|
3029
|
-
return delete I[
|
3022
|
+
return delete I[m];
|
3030
3023
|
}
|
3031
3024
|
default:
|
3032
3025
|
B(17, g);
|
@@ -3034,40 +3027,40 @@ function Gn() {
|
|
3034
3027
|
}), _;
|
3035
3028
|
}
|
3036
3029
|
function S(_) {
|
3037
|
-
if (!
|
3030
|
+
if (!Ot(_))
|
3038
3031
|
return _;
|
3039
3032
|
if (Array.isArray(_))
|
3040
3033
|
return _.map(S);
|
3041
|
-
if (
|
3034
|
+
if (He(_))
|
3042
3035
|
return new Map(
|
3043
|
-
Array.from(_.entries()).map(([l,
|
3036
|
+
Array.from(_.entries()).map(([l, h]) => [l, S(h)])
|
3044
3037
|
);
|
3045
3038
|
if (je(_))
|
3046
3039
|
return new Set(Array.from(_).map(S));
|
3047
3040
|
const f = Object.create(Wt(_));
|
3048
3041
|
for (const l in _)
|
3049
3042
|
f[l] = S(_[l]);
|
3050
|
-
return
|
3043
|
+
return Re(_, xe) && (f[xe] = _[xe]), f;
|
3051
3044
|
}
|
3052
3045
|
function F(_) {
|
3053
3046
|
return Xt(_) ? S(_) : _;
|
3054
3047
|
}
|
3055
3048
|
ga("Patches", {
|
3056
|
-
applyPatches_:
|
3049
|
+
applyPatches_: C,
|
3057
3050
|
generatePatches_: s,
|
3058
3051
|
generateReplacementPatches_: T
|
3059
3052
|
});
|
3060
3053
|
}
|
3061
|
-
var
|
3062
|
-
|
3063
|
-
|
3054
|
+
var dt = new Ta(), wa = dt.produce;
|
3055
|
+
dt.produceWithPatches.bind(
|
3056
|
+
dt
|
3064
3057
|
);
|
3065
|
-
|
3066
|
-
|
3067
|
-
var Aa =
|
3068
|
-
|
3069
|
-
|
3070
|
-
var Da = 1 / 0, Ma = 9007199254740991, Oa = "[object Arguments]",
|
3058
|
+
dt.setAutoFreeze.bind(dt);
|
3059
|
+
dt.setUseStrictShallowCopy.bind(dt);
|
3060
|
+
var Aa = dt.applyPatches.bind(dt);
|
3061
|
+
dt.createDraft.bind(dt);
|
3062
|
+
dt.finishDraft.bind(dt);
|
3063
|
+
var Da = 1 / 0, Ma = 9007199254740991, Oa = "[object Arguments]", Pa = "[object Function]", xa = "[object GeneratorFunction]", Ca = "[object Symbol]", Ra = typeof ht == "object" && ht && ht.Object === Object && ht, La = typeof self == "object" && self && self.Object === Object && self, Fa = Ra || La || Function("return this")();
|
3071
3064
|
function $a(t, r, n) {
|
3072
3065
|
switch (n.length) {
|
3073
3066
|
case 0:
|
@@ -3091,12 +3084,12 @@ function Ha(t, r) {
|
|
3091
3084
|
t[s + n] = r[n];
|
3092
3085
|
return t;
|
3093
3086
|
}
|
3094
|
-
var Mn = Object.prototype,
|
3087
|
+
var Mn = Object.prototype, ja = Mn.hasOwnProperty, On = Mn.toString, Yn = Fa.Symbol, za = Mn.propertyIsEnumerable, Wn = Yn ? Yn.isConcatSpreadable : void 0, Xn = Math.max;
|
3095
3088
|
function Ua(t, r, n, i, s) {
|
3096
3089
|
var c = -1, d = t.length;
|
3097
3090
|
for (n || (n = Xa), s || (s = []); ++c < d; ) {
|
3098
|
-
var
|
3099
|
-
n(
|
3091
|
+
var y = t[c];
|
3092
|
+
n(y) ? Ha(s, y) : s[s.length] = y;
|
3100
3093
|
}
|
3101
3094
|
return s;
|
3102
3095
|
}
|
@@ -3107,8 +3100,8 @@ function Ga(t, r) {
|
|
3107
3100
|
}
|
3108
3101
|
function Ya(t, r, n) {
|
3109
3102
|
for (var i = -1, s = r.length, c = {}; ++i < s; ) {
|
3110
|
-
var d = r[i],
|
3111
|
-
n(
|
3103
|
+
var d = r[i], y = t[d];
|
3104
|
+
n(y, d) && (c[d] = y);
|
3112
3105
|
}
|
3113
3106
|
return c;
|
3114
3107
|
}
|
@@ -3132,7 +3125,7 @@ function Ba(t) {
|
|
3132
3125
|
return r == "0" && 1 / t == -Da ? "-0" : r;
|
3133
3126
|
}
|
3134
3127
|
function Ka(t) {
|
3135
|
-
return Za(t) &&
|
3128
|
+
return Za(t) && ja.call(t, "callee") && (!za.call(t, "callee") || On.call(t) == Oa);
|
3136
3129
|
}
|
3137
3130
|
var Va = Array.isArray;
|
3138
3131
|
function Ja(t) {
|
@@ -3143,7 +3136,7 @@ function Za(t) {
|
|
3143
3136
|
}
|
3144
3137
|
function qa(t) {
|
3145
3138
|
var r = ts(t) ? On.call(t) : "";
|
3146
|
-
return r ==
|
3139
|
+
return r == Pa || r == xa;
|
3147
3140
|
}
|
3148
3141
|
function Qa(t) {
|
3149
3142
|
return typeof t == "number" && t > -1 && t % 1 == 0 && t <= Ma;
|
@@ -3161,7 +3154,7 @@ function es(t) {
|
|
3161
3154
|
var rs = Wa(function(t, r) {
|
3162
3155
|
return t == null ? {} : Ga(t, Na(Ua(r), Ba));
|
3163
3156
|
}), ns = rs;
|
3164
|
-
const Bn = /* @__PURE__ */
|
3157
|
+
const Bn = /* @__PURE__ */ kn(ns), is = {
|
3165
3158
|
width: 1080,
|
3166
3159
|
height: 1920
|
3167
3160
|
}, as = {
|
@@ -3314,33 +3307,33 @@ class hs {
|
|
3314
3307
|
trackItemDetailsMap: s,
|
3315
3308
|
trackItemIds: c,
|
3316
3309
|
tracks: d,
|
3317
|
-
transitionIds:
|
3310
|
+
transitionIds: y,
|
3318
3311
|
transitionsMap: T,
|
3319
|
-
trackItemsMap:
|
3312
|
+
trackItemsMap: C
|
3320
3313
|
} = this.getState(), S = et({
|
3321
3314
|
trackItemDetailsMap: s,
|
3322
3315
|
trackItemIds: c,
|
3323
3316
|
tracks: d,
|
3324
|
-
transitionIds:
|
3317
|
+
transitionIds: y,
|
3325
3318
|
transitionsMap: T,
|
3326
|
-
trackItemsMap:
|
3327
|
-
}), F = [], _ = [], f = [], l = [],
|
3328
|
-
n.forEach((
|
3329
|
-
let
|
3330
|
-
const
|
3331
|
-
|
3332
|
-
path:
|
3319
|
+
trackItemsMap: C
|
3320
|
+
}), F = [], _ = [], f = [], l = [], h = [], g = [];
|
3321
|
+
n.forEach((E) => {
|
3322
|
+
let D;
|
3323
|
+
const z = E.path.slice(1);
|
3324
|
+
E.type === "CREATE" ? D = {
|
3325
|
+
path: z,
|
3333
3326
|
op: "remove",
|
3334
|
-
value:
|
3335
|
-
} :
|
3336
|
-
path:
|
3327
|
+
value: E.value
|
3328
|
+
} : E.type === "CHANGE" ? D = {
|
3329
|
+
path: z,
|
3337
3330
|
op: "replace",
|
3338
|
-
value:
|
3339
|
-
} :
|
3340
|
-
path:
|
3331
|
+
value: E.oldValue
|
3332
|
+
} : D = {
|
3333
|
+
path: z,
|
3341
3334
|
op: "add",
|
3342
|
-
value:
|
3343
|
-
},
|
3335
|
+
value: E.oldValue
|
3336
|
+
}, E.path.includes("trackItemIds") ? f.push(D) : E.path.includes("transitionIds") ? _.push(D) : E.path.includes("trackItemsMap") ? h.push(D) : E.path.includes("transitionsMap") ? l.push(D) : E.path.includes("tracks") ? F.push(D) : E.path.includes("trackItemDetailsMap") && g.push(D);
|
3344
3337
|
});
|
3345
3338
|
const I = this.applyPatch(
|
3346
3339
|
S.tracks,
|
@@ -3348,32 +3341,32 @@ class hs {
|
|
3348
3341
|
), b = this.applyPatch(
|
3349
3342
|
S.transitionIds,
|
3350
3343
|
_
|
3351
|
-
),
|
3344
|
+
), p = this.applyPatch(
|
3352
3345
|
S.trackItemIds,
|
3353
3346
|
f
|
3354
|
-
),
|
3347
|
+
), m = this.applyPatch(
|
3355
3348
|
S.transitionsMap,
|
3356
3349
|
l
|
3357
|
-
),
|
3350
|
+
), k = this.applyPatch(
|
3358
3351
|
S.trackItemsMap,
|
3359
|
-
|
3360
|
-
),
|
3352
|
+
h
|
3353
|
+
), O = this.applyPatch(
|
3361
3354
|
S.trackItemDetailsMap,
|
3362
3355
|
g
|
3363
3356
|
), w = et({
|
3364
3357
|
tracks: I,
|
3365
3358
|
transitionIds: b,
|
3366
|
-
trackItemIds:
|
3367
|
-
transitionsMap:
|
3368
|
-
trackItemsMap:
|
3369
|
-
trackItemDetailsMap:
|
3370
|
-
}), x = et(this.getState()),
|
3359
|
+
trackItemIds: p,
|
3360
|
+
transitionsMap: m,
|
3361
|
+
trackItemsMap: k,
|
3362
|
+
trackItemDetailsMap: O
|
3363
|
+
}), x = et(this.getState()), R = { ...x, ...w };
|
3371
3364
|
this.prevState = x, this.redos.push({ redos: n, type: i });
|
3372
|
-
const P = Yt(
|
3373
|
-
this.stateSubject.next({ ...
|
3365
|
+
const P = Yt(R.trackItemsMap);
|
3366
|
+
this.stateSubject.next({ ...R, duration: P }), this.stateHistorySubject.next({ handleRedo: !1, handleUndo: !0 });
|
3374
3367
|
}
|
3375
3368
|
applyPatch(r, n) {
|
3376
|
-
return n.reverse().reduce((i, s) =>
|
3369
|
+
return n.reverse().reduce((i, s) => wa(i, (c) => {
|
3377
3370
|
Aa(c, [s]);
|
3378
3371
|
}), r);
|
3379
3372
|
}
|
@@ -3385,33 +3378,33 @@ class hs {
|
|
3385
3378
|
trackItemDetailsMap: s,
|
3386
3379
|
trackItemIds: c,
|
3387
3380
|
tracks: d,
|
3388
|
-
transitionIds:
|
3381
|
+
transitionIds: y,
|
3389
3382
|
transitionsMap: T,
|
3390
|
-
trackItemsMap:
|
3383
|
+
trackItemsMap: C
|
3391
3384
|
} = this.getState(), S = et({
|
3392
3385
|
trackItemDetailsMap: s,
|
3393
3386
|
trackItemIds: c,
|
3394
3387
|
tracks: d,
|
3395
|
-
transitionIds:
|
3388
|
+
transitionIds: y,
|
3396
3389
|
transitionsMap: T,
|
3397
|
-
trackItemsMap:
|
3398
|
-
}), F = [], _ = [], f = [], l = [],
|
3399
|
-
n.forEach((
|
3400
|
-
let
|
3401
|
-
const
|
3402
|
-
|
3403
|
-
path:
|
3390
|
+
trackItemsMap: C
|
3391
|
+
}), F = [], _ = [], f = [], l = [], h = [], g = [];
|
3392
|
+
n.forEach((E) => {
|
3393
|
+
let D;
|
3394
|
+
const z = E.path.slice(1);
|
3395
|
+
E.type === "CREATE" ? D = {
|
3396
|
+
path: z,
|
3404
3397
|
op: "add",
|
3405
|
-
value:
|
3406
|
-
} :
|
3407
|
-
path:
|
3398
|
+
value: E.value
|
3399
|
+
} : E.type === "CHANGE" ? D = {
|
3400
|
+
path: z,
|
3408
3401
|
op: "replace",
|
3409
|
-
value:
|
3410
|
-
} :
|
3411
|
-
path:
|
3402
|
+
value: E.value
|
3403
|
+
} : D = {
|
3404
|
+
path: z,
|
3412
3405
|
op: "remove",
|
3413
|
-
value:
|
3414
|
-
},
|
3406
|
+
value: E.oldValue
|
3407
|
+
}, E.path.includes("trackItemIds") ? f.push(D) : E.path.includes("transitionIds") ? _.push(D) : E.path.includes("trackItemsMap") ? h.push(D) : E.path.includes("transitionsMap") ? l.push(D) : E.path.includes("trackItemDetailsMap") ? g.push(D) : F.push(D);
|
3415
3408
|
});
|
3416
3409
|
const I = this.applyPatch(
|
3417
3410
|
S.tracks,
|
@@ -3419,47 +3412,47 @@ class hs {
|
|
3419
3412
|
), b = this.applyPatch(
|
3420
3413
|
S.transitionIds,
|
3421
3414
|
_
|
3422
|
-
),
|
3415
|
+
), p = this.applyPatch(
|
3423
3416
|
S.trackItemIds,
|
3424
3417
|
f
|
3425
|
-
),
|
3418
|
+
), m = this.applyPatch(
|
3426
3419
|
S.transitionsMap,
|
3427
3420
|
l
|
3428
|
-
),
|
3421
|
+
), k = this.applyPatch(
|
3429
3422
|
S.trackItemsMap,
|
3430
|
-
|
3431
|
-
),
|
3423
|
+
h
|
3424
|
+
), O = this.applyPatch(
|
3432
3425
|
S.trackItemDetailsMap,
|
3433
3426
|
g
|
3434
3427
|
), w = et({
|
3435
3428
|
tracks: I,
|
3436
3429
|
transitionIds: b,
|
3437
|
-
trackItemIds:
|
3438
|
-
transitionsMap:
|
3439
|
-
trackItemsMap:
|
3440
|
-
trackItemDetailsMap:
|
3441
|
-
}), x = et(this.getState()),
|
3430
|
+
trackItemIds: p,
|
3431
|
+
transitionsMap: m,
|
3432
|
+
trackItemsMap: k,
|
3433
|
+
trackItemDetailsMap: O
|
3434
|
+
}), x = et(this.getState()), R = { ...x, ...w };
|
3442
3435
|
this.prevState = x, this.undos.push({ undos: n, type: i });
|
3443
|
-
const P = Yt(
|
3444
|
-
this.stateSubject.next({ ...
|
3436
|
+
const P = Yt(R.trackItemsMap);
|
3437
|
+
this.stateSubject.next({ ...R, duration: P }), this.stateHistorySubject.next({ handleRedo: !0, handleUndo: !1 });
|
3445
3438
|
}
|
3446
3439
|
}
|
3447
|
-
const ms = "add", ss = "track", os = "trackItems", ys = `${ss}:changed`, _s = `${os}:changed`, cs = "state", Is = `${cs}:changed`, bi = "design", gs = `${bi}:load`, bs = `${bi}:resize`,
|
3440
|
+
const ms = "add", ss = "track", os = "trackItems", ys = `${ss}:changed`, _s = `${os}:changed`, cs = "state", Is = `${cs}:changed`, bi = "design", gs = `${bi}:load`, bs = `${bi}:resize`, _t = "add", vs = `${_t}:text`, Ss = `${_t}:video`, Es = `${_t}:audio`, Ts = `${_t}:placeholder`, ks = `${_t}:image`, ws = `${_t}:mask`, us = `${_t}:items`, As = `${_t}:transition`, Ds = `${_t}:animation`, Ms = `${_t}:caption`, Os = `${_t}:template`, me = "edit", Ps = `${me}:object`, xs = `${me}:text`, Cs = `${me}:shape`, Rs = `${me}:templateItem`, Ls = `${me}:closeTemplate`, Fs = `${me}:deleteTemplateItem`, $s = "enterEditMode", ye = "player", Ns = `${ye}:play`, Hs = `${ye}:pause`, js = `${ye}:seek`, zs = `${ye}:seekTo`, Us = `${ye}:seekBy`, Gs = `${ye}:togglePlay`, ze = "active", Ys = `${ze}:set`, Ws = `${ze}:delete`, Xs = `${ze}:paste`, Bs = `${ze}:clone`, Ks = `${ze}:split`, ct = "layer", Vs = `${ct}:locked`, Js = `${ct}:hidden`, Zs = `${ct}:move`, qs = `${ct}:select`, Qs = `${ct}:selection`, to = `${ct}:sendTo`, eo = `${ct}:rename`, ro = `${ct}:editingName`, no = `${ct}:copy`, io = `${ct}:paste`, ao = `${ct}:clone`, so = `${ct}:split`, oo = `${ct}:cut`, co = `${ct}:delete`, Pn = "history", uo = `${Pn}:undo`, lo = `${Pn}:redo`, fo = `${Pn}:reset`, ls = "scale", po = `${ls}:changed`, vi = "drag", ho = `${vi}:start`, mo = `${vi}:end`, fs = "timeline", yo = `${fs}:boundingChanged`;
|
3448
3441
|
export {
|
3449
3442
|
Bs as ACTIVE_CLONE,
|
3450
3443
|
Ws as ACTIVE_DELETE,
|
3451
3444
|
Xs as ACTIVE_PASTE,
|
3452
|
-
|
3445
|
+
ze as ACTIVE_PREFIX,
|
3453
3446
|
Ys as ACTIVE_SET,
|
3454
3447
|
Ks as ACTIVE_SPLIT,
|
3455
3448
|
Ds as ADD_ANIMATION,
|
3456
3449
|
Es as ADD_AUDIO,
|
3457
3450
|
Ms as ADD_CAPTION,
|
3458
|
-
|
3451
|
+
ks as ADD_IMAGE,
|
3459
3452
|
us as ADD_ITEMS,
|
3460
|
-
|
3453
|
+
ws as ADD_MASK,
|
3461
3454
|
Ts as ADD_PLACEHOLDER,
|
3462
|
-
|
3455
|
+
_t as ADD_PREFIX,
|
3463
3456
|
ms as ADD_SUFFIX,
|
3464
3457
|
Os as ADD_TEMPLATE,
|
3465
3458
|
vs as ADD_TEXT,
|
@@ -3473,13 +3466,13 @@ export {
|
|
3473
3466
|
mo as DRAG_END,
|
3474
3467
|
vi as DRAG_PREFIX,
|
3475
3468
|
ho as DRAG_START,
|
3476
|
-
|
3477
|
-
|
3469
|
+
Ps as EDIT_OBJECT,
|
3470
|
+
me as EDIT_PREFIX,
|
3478
3471
|
Cs as EDIT_SHAPE,
|
3479
3472
|
Rs as EDIT_TEMPLATE_ITEM,
|
3480
|
-
|
3473
|
+
xs as EDIT_TEXT,
|
3481
3474
|
$s as ENTER_EDIT_MODE,
|
3482
|
-
|
3475
|
+
Pn as HISTORY_PREFIX,
|
3483
3476
|
lo as HISTORY_REDO,
|
3484
3477
|
fo as HISTORY_RESET,
|
3485
3478
|
uo as HISTORY_UNDO,
|
@@ -3500,10 +3493,10 @@ export {
|
|
3500
3493
|
so as LAYER_SPLIT,
|
3501
3494
|
Hs as PLAYER_PAUSE,
|
3502
3495
|
Ns as PLAYER_PLAY,
|
3503
|
-
|
3504
|
-
|
3496
|
+
ye as PLAYER_PREFIX,
|
3497
|
+
js as PLAYER_SEEK,
|
3505
3498
|
Us as PLAYER_SEEK_BY,
|
3506
|
-
|
3499
|
+
zs as PLAYER_SEEK_TO,
|
3507
3500
|
Gs as PLAYER_TOGGLE_PLAY,
|
3508
3501
|
Is as STATE_CHANGED,
|
3509
3502
|
cs as STATE_PREFIX,
|