@cliquify.me/state 5.0.1 → 5.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.es.js CHANGED
@@ -1,7 +1,7 @@
1
- var Ls = Object.defineProperty;
2
- var Hs = (t, r, e) => r in t ? Ls(t, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : t[r] = e;
3
- var Kt = (t, r, e) => Hs(t, typeof r != "symbol" ? r + "" : r, e);
4
- import { subject as Vt, filter as qt, dispatch as Us } from "@designcombo/events";
1
+ var Hs = Object.defineProperty;
2
+ var Us = (t, r, e) => r in t ? Hs(t, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : t[r] = e;
3
+ var Xt = (t, r, e) => Us(t, typeof r != "symbol" ? r + "" : r, e);
4
+ import { subject as Kt, filter as Vt, dispatch as Ws } from "@designcombo/events";
5
5
  var bn = function(t, r) {
6
6
  return bn = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(e, n) {
7
7
  e.__proto__ = n;
@@ -50,16 +50,16 @@ function _n(t, r, e) {
50
50
  (o || !(n in r)) && (o || (o = Array.prototype.slice.call(r, 0, n)), o[n] = r[n]);
51
51
  return t.concat(o || Array.prototype.slice.call(r));
52
52
  }
53
- function Dt(t) {
53
+ function Rt(t) {
54
54
  return typeof t == "function";
55
55
  }
56
- function as(t) {
56
+ function os(t) {
57
57
  var r = function(n) {
58
58
  Error.call(n), n.stack = new Error().stack;
59
59
  }, e = t(r);
60
60
  return e.prototype = Object.create(Error.prototype), e.prototype.constructor = e, e;
61
61
  }
62
- var pn = as(function(t) {
62
+ var pn = os(function(t) {
63
63
  return function(e) {
64
64
  t(this), this.message = e ? e.length + ` errors occurred during unsubscription:
65
65
  ` + e.map(function(n, i) {
@@ -102,7 +102,7 @@ var Er = function() {
102
102
  else
103
103
  c.remove(this);
104
104
  var m = this.initialTeardown;
105
- if (Dt(m))
105
+ if (Rt(m))
106
106
  try {
107
107
  m();
108
108
  } catch (b) {
@@ -115,7 +115,7 @@ var Er = function() {
115
115
  for (var h = kn(y), k = h.next(); !k.done; k = h.next()) {
116
116
  var I = k.value;
117
117
  try {
118
- Un(I);
118
+ Wn(I);
119
119
  } catch (b) {
120
120
  o = o ?? [], b instanceof pn ? o = _n(_n([], vn(o)), vn(b.errors)) : o.push(b);
121
121
  }
@@ -137,7 +137,7 @@ var Er = function() {
137
137
  var e;
138
138
  if (r && r !== this)
139
139
  if (this.closed)
140
- Un(r);
140
+ Wn(r);
141
141
  else {
142
142
  if (r instanceof t) {
143
143
  if (r.closed || r._hasParent(this))
@@ -162,14 +162,14 @@ var Er = function() {
162
162
  var r = new t();
163
163
  return r.closed = !0, r;
164
164
  }(), t;
165
- }(), os = Er.EMPTY;
166
- function cs(t) {
167
- return t instanceof Er || t && "closed" in t && Dt(t.remove) && Dt(t.add) && Dt(t.unsubscribe);
165
+ }(), cs = Er.EMPTY;
166
+ function us(t) {
167
+ return t instanceof Er || t && "closed" in t && Rt(t.remove) && Rt(t.add) && Rt(t.unsubscribe);
168
168
  }
169
- function Un(t) {
170
- Dt(t) ? t() : t.unsubscribe();
169
+ function Wn(t) {
170
+ Rt(t) ? t() : t.unsubscribe();
171
171
  }
172
- var Ws = {
172
+ var js = {
173
173
  Promise: void 0
174
174
  }, Bs = {
175
175
  setTimeout: function(t, r) {
@@ -182,21 +182,21 @@ var Ws = {
182
182
  },
183
183
  delegate: void 0
184
184
  };
185
- function js(t) {
185
+ function Ys(t) {
186
186
  Bs.setTimeout(function() {
187
187
  throw t;
188
188
  });
189
189
  }
190
- function Wn() {
190
+ function jn() {
191
191
  }
192
192
  function kr(t) {
193
193
  t();
194
194
  }
195
- var us = function(t) {
195
+ var ls = function(t) {
196
196
  rr(r, t);
197
197
  function r(e) {
198
198
  var n = t.call(this) || this;
199
- return n.isStopped = !1, e ? (n.destination = e, cs(e) && e.add(n)) : n.destination = Xs, n;
199
+ return n.isStopped = !1, e ? (n.destination = e, us(e) && e.add(n)) : n.destination = Ks, n;
200
200
  }
201
201
  return r.create = function(e, n, i) {
202
202
  return new wn(e, n, i);
@@ -223,7 +223,7 @@ var us = function(t) {
223
223
  this.unsubscribe();
224
224
  }
225
225
  }, r;
226
- }(Er), Ys = function() {
226
+ }(Er), Gs = function() {
227
227
  function t(r) {
228
228
  this.partialObserver = r;
229
229
  }
@@ -233,7 +233,7 @@ var us = function(t) {
233
233
  try {
234
234
  e.next(r);
235
235
  } catch (n) {
236
- br(n);
236
+ Ir(n);
237
237
  }
238
238
  }, t.prototype.error = function(r) {
239
239
  var e = this.partialObserver;
@@ -241,50 +241,50 @@ var us = function(t) {
241
241
  try {
242
242
  e.error(r);
243
243
  } catch (n) {
244
- br(n);
244
+ Ir(n);
245
245
  }
246
246
  else
247
- br(r);
247
+ Ir(r);
248
248
  }, t.prototype.complete = function() {
249
249
  var r = this.partialObserver;
250
250
  if (r.complete)
251
251
  try {
252
252
  r.complete();
253
253
  } catch (e) {
254
- br(e);
254
+ Ir(e);
255
255
  }
256
256
  }, t;
257
257
  }(), wn = function(t) {
258
258
  rr(r, t);
259
259
  function r(e, n, i) {
260
260
  var o = t.call(this) || this, c;
261
- return Dt(e) || !e ? c = {
261
+ return Rt(e) || !e ? c = {
262
262
  next: e ?? void 0,
263
263
  error: n ?? void 0,
264
264
  complete: i ?? void 0
265
- } : c = e, o.destination = new Ys(c), o;
265
+ } : c = e, o.destination = new Gs(c), o;
266
266
  }
267
267
  return r;
268
- }(us);
269
- function br(t) {
270
- js(t);
268
+ }(ls);
269
+ function Ir(t) {
270
+ Ys(t);
271
271
  }
272
- function Gs(t) {
272
+ function Xs(t) {
273
273
  throw t;
274
274
  }
275
- var Xs = {
275
+ var Ks = {
276
276
  closed: !0,
277
- next: Wn,
278
- error: Gs,
279
- complete: Wn
280
- }, Ks = function() {
277
+ next: jn,
278
+ error: Xs,
279
+ complete: jn
280
+ }, Vs = function() {
281
281
  return typeof Symbol == "function" && Symbol.observable || "@@observable";
282
282
  }();
283
- function Vs(t) {
283
+ function qs(t) {
284
284
  return t;
285
285
  }
286
- function qs(t) {
287
- return t.length === 0 ? Vs : t.length === 1 ? t[0] : function(e) {
286
+ function Js(t) {
287
+ return t.length === 0 ? qs : t.length === 1 ? t[0] : function(e) {
288
288
  return t.reduce(function(n, i) {
289
289
  return i(n);
290
290
  }, e);
@@ -298,7 +298,7 @@ var Bn = function() {
298
298
  var e = new t();
299
299
  return e.source = this, e.operator = r, e;
300
300
  }, t.prototype.subscribe = function(r, e, n) {
301
- var i = this, o = Zs(r) ? r : new wn(r, e, n);
301
+ var i = this, o = Qs(r) ? r : new wn(r, e, n);
302
302
  return kr(function() {
303
303
  var c = i, u = c.operator, d = c.source;
304
304
  o.add(u ? u.call(o, d) : d ? i._subscribe(o) : i._trySubscribe(o));
@@ -311,7 +311,7 @@ var Bn = function() {
311
311
  }
312
312
  }, t.prototype.forEach = function(r, e) {
313
313
  var n = this;
314
- return e = jn(e), new e(function(i, o) {
314
+ return e = Yn(e), new e(function(i, o) {
315
315
  var c = new wn({
316
316
  next: function(u) {
317
317
  try {
@@ -328,15 +328,15 @@ var Bn = function() {
328
328
  }, t.prototype._subscribe = function(r) {
329
329
  var e;
330
330
  return (e = this.source) === null || e === void 0 ? void 0 : e.subscribe(r);
331
- }, t.prototype[Ks] = function() {
331
+ }, t.prototype[Vs] = function() {
332
332
  return this;
333
333
  }, t.prototype.pipe = function() {
334
334
  for (var r = [], e = 0; e < arguments.length; e++)
335
335
  r[e] = arguments[e];
336
- return qs(r)(this);
336
+ return Js(r)(this);
337
337
  }, t.prototype.toPromise = function(r) {
338
338
  var e = this;
339
- return r = jn(r), new r(function(n, i) {
339
+ return r = Yn(r), new r(function(n, i) {
340
340
  var o;
341
341
  e.subscribe(function(c) {
342
342
  return o = c;
@@ -350,32 +350,32 @@ var Bn = function() {
350
350
  return new t(r);
351
351
  }, t;
352
352
  }();
353
- function jn(t) {
353
+ function Yn(t) {
354
354
  var r;
355
- return (r = t ?? Ws.Promise) !== null && r !== void 0 ? r : Promise;
356
- }
357
- function Js(t) {
358
- return t && Dt(t.next) && Dt(t.error) && Dt(t.complete);
355
+ return (r = t ?? js.Promise) !== null && r !== void 0 ? r : Promise;
359
356
  }
360
357
  function Zs(t) {
361
- return t && t instanceof us || Js(t) && cs(t);
358
+ return t && Rt(t.next) && Rt(t.error) && Rt(t.complete);
359
+ }
360
+ function Qs(t) {
361
+ return t && t instanceof ls || Zs(t) && us(t);
362
362
  }
363
- var Qs = as(function(t) {
363
+ var ti = os(function(t) {
364
364
  return function() {
365
365
  t(this), this.name = "ObjectUnsubscribedError", this.message = "object unsubscribed";
366
366
  };
367
- }), ls = function(t) {
367
+ }), ds = function(t) {
368
368
  rr(r, t);
369
369
  function r() {
370
370
  var e = t.call(this) || this;
371
371
  return e.closed = !1, e.currentObservers = null, e.observers = [], e.isStopped = !1, e.hasError = !1, e.thrownError = null, e;
372
372
  }
373
373
  return r.prototype.lift = function(e) {
374
- var n = new Yn(this, this);
374
+ var n = new Gn(this, this);
375
375
  return n.operator = e, n;
376
376
  }, r.prototype._throwIfClosed = function() {
377
377
  if (this.closed)
378
- throw new Qs();
378
+ throw new ti();
379
379
  }, r.prototype.next = function(e) {
380
380
  var n = this;
381
381
  kr(function() {
@@ -431,7 +431,7 @@ var Qs = as(function(t) {
431
431
  return this._throwIfClosed(), this._checkFinalizedStatuses(e), this._innerSubscribe(e);
432
432
  }, r.prototype._innerSubscribe = function(e) {
433
433
  var n = this, i = this, o = i.hasError, c = i.isStopped, u = i.observers;
434
- return o || c ? os : (this.currentObservers = null, u.push(e), new Er(function() {
434
+ return o || c ? cs : (this.currentObservers = null, u.push(e), new Er(function() {
435
435
  n.currentObservers = null, Sn(u, e);
436
436
  }));
437
437
  }, r.prototype._checkFinalizedStatuses = function(e) {
@@ -441,9 +441,9 @@ var Qs = as(function(t) {
441
441
  var e = new Bn();
442
442
  return e.source = this, e;
443
443
  }, r.create = function(e, n) {
444
- return new Yn(e, n);
444
+ return new Gn(e, n);
445
445
  }, r;
446
- }(Bn), Yn = function(t) {
446
+ }(Bn), Gn = function(t) {
447
447
  rr(r, t);
448
448
  function r(e, n) {
449
449
  var i = t.call(this) || this;
@@ -460,9 +460,9 @@ var Qs = as(function(t) {
460
460
  (n = (e = this.destination) === null || e === void 0 ? void 0 : e.complete) === null || n === void 0 || n.call(e);
461
461
  }, r.prototype._subscribe = function(e) {
462
462
  var n, i;
463
- return (i = (n = this.source) === null || n === void 0 ? void 0 : n.subscribe(e)) !== null && i !== void 0 ? i : os;
463
+ return (i = (n = this.source) === null || n === void 0 ? void 0 : n.subscribe(e)) !== null && i !== void 0 ? i : cs;
464
464
  }, r;
465
- }(ls), Gn = function(t) {
465
+ }(ds), Xn = function(t) {
466
466
  rr(r, t);
467
467
  function r(e) {
468
468
  var n = t.call(this) || this;
@@ -485,62 +485,62 @@ var Qs = as(function(t) {
485
485
  }, r.prototype.next = function(e) {
486
486
  t.prototype.next.call(this, this._value = e);
487
487
  }, r;
488
- }(ls), ft = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
489
- function Cn(t) {
488
+ }(ds), dt = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
489
+ function Pn(t) {
490
490
  return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
491
491
  }
492
492
  var vr = { exports: {} };
493
493
  vr.exports;
494
494
  (function(t, r) {
495
- var e = 200, n = "__lodash_hash_undefined__", i = 1, o = 2, c = 9007199254740991, u = "[object Arguments]", d = "[object Array]", p = "[object AsyncFunction]", m = "[object Boolean]", y = "[object Date]", h = "[object Error]", k = "[object Function]", I = "[object GeneratorFunction]", b = "[object Map]", _ = "[object Number]", f = "[object Null]", v = "[object Object]", T = "[object Promise]", w = "[object Proxy]", A = "[object RegExp]", S = "[object Set]", E = "[object String]", L = "[object Symbol]", R = "[object Undefined]", Y = "[object WeakMap]", x = "[object ArrayBuffer]", F = "[object DataView]", tt = "[object Float32Array]", Qt = "[object Float64Array]", te = "[object Int8Array]", Se = "[object Int16Array]", we = "[object Int32Array]", Te = "[object Uint8Array]", Ee = "[object Uint8ClampedArray]", z = "[object Uint16Array]", Ae = "[object Uint32Array]", Me = /[\\^$.*+?()[\]{}|]/g, st = /^\[object .+?Constructor\]$/, ee = /^(?:0|[1-9]\d*)$/, $ = {};
496
- $[tt] = $[Qt] = $[te] = $[Se] = $[we] = $[Te] = $[Ee] = $[z] = $[Ae] = !0, $[u] = $[d] = $[x] = $[m] = $[F] = $[y] = $[h] = $[k] = $[b] = $[_] = $[v] = $[A] = $[S] = $[E] = $[Y] = !1;
497
- var re = typeof ft == "object" && ft && ft.Object === Object && ft, xe = typeof self == "object" && self && self.Object === Object && self, it = re || xe || Function("return this")(), ne = r && !r.nodeType && r, se = ne && !0 && t && !t.nodeType && t, zt = se && se.exports === ne, $t = zt && re.process, ie = function() {
495
+ var e = 200, n = "__lodash_hash_undefined__", i = 1, o = 2, c = 9007199254740991, u = "[object Arguments]", d = "[object Array]", p = "[object AsyncFunction]", m = "[object Boolean]", y = "[object Date]", h = "[object Error]", k = "[object Function]", I = "[object GeneratorFunction]", b = "[object Map]", _ = "[object Number]", f = "[object Null]", v = "[object Object]", T = "[object Promise]", w = "[object Proxy]", A = "[object RegExp]", S = "[object Set]", E = "[object String]", L = "[object Symbol]", P = "[object Undefined]", Y = "[object WeakMap]", x = "[object ArrayBuffer]", F = "[object DataView]", tt = "[object Float32Array]", Zt = "[object Float64Array]", Qt = "[object Int8Array]", _e = "[object Int16Array]", Se = "[object Int32Array]", we = "[object Uint8Array]", Te = "[object Uint8ClampedArray]", z = "[object Uint16Array]", Ee = "[object Uint32Array]", Ae = /[\\^$.*+?()[\]{}|]/g, st = /^\[object .+?Constructor\]$/, te = /^(?:0|[1-9]\d*)$/, $ = {};
496
+ $[tt] = $[Zt] = $[Qt] = $[_e] = $[Se] = $[we] = $[Te] = $[z] = $[Ee] = !0, $[u] = $[d] = $[x] = $[m] = $[F] = $[y] = $[h] = $[k] = $[b] = $[_] = $[v] = $[A] = $[S] = $[E] = $[Y] = !1;
497
+ var ee = typeof dt == "object" && dt && dt.Object === Object && dt, Me = typeof self == "object" && self && self.Object === Object && self, it = ee || Me || Function("return this")(), re = r && !r.nodeType && r, ne = re && !0 && t && !t.nodeType && t, Dt = ne && ne.exports === re, zt = Dt && ee.process, se = function() {
498
498
  try {
499
- return $t && $t.binding && $t.binding("util");
499
+ return zt && zt.binding && zt.binding("util");
500
500
  } catch {
501
501
  }
502
- }(), Ft = ie && ie.isTypedArray;
503
- function ae(s, a) {
502
+ }(), $t = se && se.isTypedArray;
503
+ function ie(s, a) {
504
504
  for (var l = -1, g = s == null ? 0 : s.length, O = 0, M = []; ++l < g; ) {
505
505
  var D = s[l];
506
506
  a(D, l, s) && (M[O++] = D);
507
507
  }
508
508
  return M;
509
509
  }
510
- function Nt(s, a) {
510
+ function Ft(s, a) {
511
511
  for (var l = -1, g = a.length, O = s.length; ++l < g; )
512
512
  s[O + l] = a[l];
513
513
  return s;
514
514
  }
515
- function oe(s, a) {
515
+ function ae(s, a) {
516
516
  for (var l = -1, g = s == null ? 0 : s.length; ++l < g; )
517
517
  if (a(s[l], l, s))
518
518
  return !0;
519
519
  return !1;
520
520
  }
521
- function Oe(s, a) {
521
+ function xe(s, a) {
522
522
  for (var l = -1, g = Array(s); ++l < s; )
523
523
  g[l] = a(l);
524
524
  return g;
525
525
  }
526
- function Ce(s) {
526
+ function Oe(s) {
527
527
  return function(a) {
528
528
  return s(a);
529
529
  };
530
530
  }
531
- function wt(s, a) {
531
+ function St(s, a) {
532
532
  return s.has(a);
533
533
  }
534
- function Lt(s, a) {
534
+ function Nt(s, a) {
535
535
  return s == null ? void 0 : s[a];
536
536
  }
537
- function ce(s) {
537
+ function oe(s) {
538
538
  var a = -1, l = Array(s.size);
539
539
  return s.forEach(function(g, O) {
540
540
  l[++a] = [O, g];
541
541
  }), l;
542
542
  }
543
- function ue(s, a) {
543
+ function ce(s, a) {
544
544
  return function(l) {
545
545
  return s(a(l));
546
546
  };
@@ -551,12 +551,12 @@ vr.exports;
551
551
  l[++a] = g;
552
552
  }), l;
553
553
  }
554
- var Tt = Array.prototype, Re = Function.prototype, gt = Object.prototype, Et = it["__core-js_shared__"], Ht = Re.toString, et = gt.hasOwnProperty, le = function() {
555
- var s = /[^.]+$/.exec(Et && Et.keys && Et.keys.IE_PROTO || "");
554
+ var wt = Array.prototype, Ce = Function.prototype, mt = Object.prototype, Tt = it["__core-js_shared__"], Lt = Ce.toString, et = mt.hasOwnProperty, ue = function() {
555
+ var s = /[^.]+$/.exec(Tt && Tt.keys && Tt.keys.IE_PROTO || "");
556
556
  return s ? "Symbol(src)_1." + s : "";
557
- }(), de = gt.toString, Pe = RegExp(
558
- "^" + Ht.call(et).replace(Me, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
559
- ), Ut = zt ? it.Buffer : void 0, At = it.Symbol, fe = it.Uint8Array, Mt = gt.propertyIsEnumerable, yt = Tt.splice, at = At ? At.toStringTag : void 0, xt = Object.getOwnPropertySymbols, Wt = Ut ? Ut.isBuffer : void 0, It = ue(Object.keys, Object), Bt = Ct(it, "DataView"), bt = Ct(it, "Map"), jt = Ct(it, "Promise"), Yt = Ct(it, "Set"), We = Ct(it, "WeakMap"), Gt = Ct(Object, "create"), ar = rt(Bt), Ot = rt(bt), xr = rt(jt), Or = rt(Yt), Cr = rt(We), or = At ? At.prototype : void 0, Be = or ? or.valueOf : void 0;
557
+ }(), le = mt.toString, Pe = RegExp(
558
+ "^" + Lt.call(et).replace(Ae, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
559
+ ), Ht = Dt ? it.Buffer : void 0, Et = it.Symbol, de = it.Uint8Array, At = mt.propertyIsEnumerable, gt = wt.splice, at = Et ? Et.toStringTag : void 0, Mt = Object.getOwnPropertySymbols, Ut = Ht ? Ht.isBuffer : void 0, yt = ce(Object.keys, Object), Wt = Ot(it, "DataView"), It = Ot(it, "Map"), jt = Ot(it, "Promise"), Bt = Ot(it, "Set"), We = Ot(it, "WeakMap"), Yt = Ot(Object, "create"), ir = rt(Wt), xt = rt(It), xr = rt(jt), Or = rt(Bt), Cr = rt(We), ar = Et ? Et.prototype : void 0, je = ar ? ar.valueOf : void 0;
560
560
  function X(s) {
561
561
  var a = -1, l = s == null ? 0 : s.length;
562
562
  for (this.clear(); ++a < l; ) {
@@ -564,16 +564,16 @@ vr.exports;
564
564
  this.set(g[0], g[1]);
565
565
  }
566
566
  }
567
- function Rr() {
568
- this.__data__ = Gt ? Gt(null) : {}, this.size = 0;
567
+ function Pr() {
568
+ this.__data__ = Yt ? Yt(null) : {}, this.size = 0;
569
569
  }
570
- function Pr(s) {
570
+ function Rr(s) {
571
571
  var a = this.has(s) && delete this.__data__[s];
572
572
  return this.size -= a ? 1 : 0, a;
573
573
  }
574
574
  function Dr(s) {
575
575
  var a = this.__data__;
576
- if (Gt) {
576
+ if (Yt) {
577
577
  var l = a[s];
578
578
  return l === n ? void 0 : l;
579
579
  }
@@ -581,13 +581,13 @@ vr.exports;
581
581
  }
582
582
  function zr(s) {
583
583
  var a = this.__data__;
584
- return Gt ? a[s] !== void 0 : et.call(a, s);
584
+ return Yt ? a[s] !== void 0 : et.call(a, s);
585
585
  }
586
586
  function $r(s, a) {
587
587
  var l = this.__data__;
588
- return this.size += this.has(s) ? 0 : 1, l[s] = Gt && a === void 0 ? n : a, this;
588
+ return this.size += this.has(s) ? 0 : 1, l[s] = Yt && a === void 0 ? n : a, this;
589
589
  }
590
- X.prototype.clear = Rr, X.prototype.delete = Pr, X.prototype.get = Dr, X.prototype.has = zr, X.prototype.set = $r;
590
+ X.prototype.clear = Pr, X.prototype.delete = Rr, X.prototype.get = Dr, X.prototype.has = zr, X.prototype.set = $r;
591
591
  function q(s) {
592
592
  var a = -1, l = s == null ? 0 : s.length;
593
593
  for (this.clear(); ++a < l; ) {
@@ -599,21 +599,21 @@ vr.exports;
599
599
  this.__data__ = [], this.size = 0;
600
600
  }
601
601
  function Nr(s) {
602
- var a = this.__data__, l = $e(a, s);
602
+ var a = this.__data__, l = ze(a, s);
603
603
  if (l < 0)
604
604
  return !1;
605
605
  var g = a.length - 1;
606
- return l == g ? a.pop() : yt.call(a, l, 1), --this.size, !0;
606
+ return l == g ? a.pop() : gt.call(a, l, 1), --this.size, !0;
607
607
  }
608
608
  function Lr(s) {
609
- var a = this.__data__, l = $e(a, s);
609
+ var a = this.__data__, l = ze(a, s);
610
610
  return l < 0 ? void 0 : a[l][1];
611
611
  }
612
612
  function Hr(s) {
613
- return $e(this.__data__, s) > -1;
613
+ return ze(this.__data__, s) > -1;
614
614
  }
615
615
  function Ur(s, a) {
616
- var l = this.__data__, g = $e(l, s);
616
+ var l = this.__data__, g = ze(l, s);
617
617
  return g < 0 ? (++this.size, l.push([s, a])) : l[g][1] = a, this;
618
618
  }
619
619
  q.prototype.clear = Fr, q.prototype.delete = Nr, q.prototype.get = Lr, q.prototype.has = Hr, q.prototype.set = Ur;
@@ -627,42 +627,42 @@ vr.exports;
627
627
  function Wr() {
628
628
  this.size = 0, this.__data__ = {
629
629
  hash: new X(),
630
- map: new (bt || q)(),
630
+ map: new (It || q)(),
631
631
  string: new X()
632
632
  };
633
633
  }
634
- function Br(s) {
635
- var a = mt(this, s).delete(s);
634
+ function jr(s) {
635
+ var a = ht(this, s).delete(s);
636
636
  return this.size -= a ? 1 : 0, a;
637
637
  }
638
- function jr(s) {
639
- return mt(this, s).get(s);
638
+ function Br(s) {
639
+ return ht(this, s).get(s);
640
640
  }
641
641
  function Yr(s) {
642
- return mt(this, s).has(s);
642
+ return ht(this, s).has(s);
643
643
  }
644
644
  function Gr(s, a) {
645
- var l = mt(this, s), g = l.size;
645
+ var l = ht(this, s), g = l.size;
646
646
  return l.set(s, a), this.size += l.size == g ? 0 : 1, this;
647
647
  }
648
- ot.prototype.clear = Wr, ot.prototype.delete = Br, ot.prototype.get = jr, ot.prototype.has = Yr, ot.prototype.set = Gr;
649
- function De(s) {
648
+ ot.prototype.clear = Wr, ot.prototype.delete = jr, ot.prototype.get = Br, ot.prototype.has = Yr, ot.prototype.set = Gr;
649
+ function Re(s) {
650
650
  var a = -1, l = s == null ? 0 : s.length;
651
651
  for (this.__data__ = new ot(); ++a < l; )
652
652
  this.add(s[a]);
653
653
  }
654
- function cr(s) {
654
+ function or(s) {
655
655
  return this.__data__.set(s, n), this;
656
656
  }
657
- function ze(s) {
657
+ function De(s) {
658
658
  return this.__data__.has(s);
659
659
  }
660
- De.prototype.add = De.prototype.push = cr, De.prototype.has = ze;
661
- function kt(s) {
660
+ Re.prototype.add = Re.prototype.push = or, Re.prototype.has = De;
661
+ function bt(s) {
662
662
  var a = this.__data__ = new q(s);
663
663
  this.size = a.size;
664
664
  }
665
- function je() {
665
+ function Be() {
666
666
  this.__data__ = new q(), this.size = 0;
667
667
  }
668
668
  function Xr(s) {
@@ -679,101 +679,101 @@ vr.exports;
679
679
  var l = this.__data__;
680
680
  if (l instanceof q) {
681
681
  var g = l.__data__;
682
- if (!bt || g.length < e - 1)
682
+ if (!It || g.length < e - 1)
683
683
  return g.push([s, a]), this.size = ++l.size, this;
684
684
  l = this.__data__ = new ot(g);
685
685
  }
686
686
  return l.set(s, a), this.size = l.size, this;
687
687
  }
688
- kt.prototype.clear = je, kt.prototype.delete = Xr, kt.prototype.get = Kr, kt.prototype.has = Vr, kt.prototype.set = qr;
688
+ bt.prototype.clear = Be, bt.prototype.delete = Xr, bt.prototype.get = Kr, bt.prototype.has = Vr, bt.prototype.set = qr;
689
689
  function Jr(s, a) {
690
- var l = Fe(s), g = !l && pr(s), O = !l && !g && Ne(s), M = !l && !g && !O && gr(s), D = l || g || O || M, P = D ? Oe(s.length, String) : [], U = P.length;
690
+ var l = $e(s), g = !l && fr(s), O = !l && !g && Fe(s), M = !l && !g && !O && mr(s), D = l || g || O || M, R = D ? xe(s.length, String) : [], U = R.length;
691
691
  for (var N in s)
692
692
  et.call(s, N) && !(D && // Safari 9 has enumerable `arguments.length` in strict mode.
693
693
  (N == "length" || // Node.js 0.10 has enumerable non-index properties on buffers.
694
694
  O && (N == "offset" || N == "parent") || // PhantomJS 2 has enumerable non-index properties on typed arrays.
695
695
  M && (N == "buffer" || N == "byteLength" || N == "byteOffset") || // Skip index properties.
696
- an(N, U))) && P.push(N);
697
- return P;
696
+ an(N, U))) && R.push(N);
697
+ return R;
698
698
  }
699
- function $e(s, a) {
699
+ function ze(s, a) {
700
700
  for (var l = s.length; l--; )
701
- if (fr(s[l][0], a))
701
+ if (dr(s[l][0], a))
702
702
  return l;
703
703
  return -1;
704
704
  }
705
705
  function Ye(s, a, l) {
706
706
  var g = a(s);
707
- return Fe(s) ? g : Nt(g, l(s));
707
+ return $e(s) ? g : Ft(g, l(s));
708
708
  }
709
- function pe(s) {
710
- return s == null ? s === void 0 ? R : f : at && at in Object(s) ? Rt(s) : dr(s);
709
+ function fe(s) {
710
+ return s == null ? s === void 0 ? P : f : at && at in Object(s) ? Ct(s) : lr(s);
711
711
  }
712
- function ur(s) {
713
- return _t(s) && pe(s) == u;
712
+ function cr(s) {
713
+ return vt(s) && fe(s) == u;
714
714
  }
715
- function lr(s, a, l, g, O) {
716
- return s === a ? !0 : s == null || a == null || !_t(s) && !_t(a) ? s !== s && a !== a : Zr(s, a, l, g, lr, O);
715
+ function ur(s, a, l, g, O) {
716
+ return s === a ? !0 : s == null || a == null || !vt(s) && !vt(a) ? s !== s && a !== a : Zr(s, a, l, g, ur, O);
717
717
  }
718
718
  function Zr(s, a, l, g, O, M) {
719
- var D = Fe(s), P = Fe(a), U = D ? d : vt(s), N = P ? d : vt(a);
719
+ var D = $e(s), R = $e(a), U = D ? d : kt(s), N = R ? d : kt(a);
720
720
  U = U == u ? v : U, N = N == u ? v : N;
721
721
  var J = U == v, ct = N == v, W = U == N;
722
- if (W && Ne(s)) {
723
- if (!Ne(a))
722
+ if (W && Fe(s)) {
723
+ if (!Fe(a))
724
724
  return !1;
725
725
  D = !0, J = !1;
726
726
  }
727
727
  if (W && !J)
728
- return M || (M = new kt()), D || gr(s) ? Ge(s, a, l, g, O, M) : rn(s, a, U, l, g, O, M);
728
+ return M || (M = new bt()), D || mr(s) ? Ge(s, a, l, g, O, M) : rn(s, a, U, l, g, O, M);
729
729
  if (!(l & i)) {
730
730
  var Z = J && et.call(s, "__wrapped__"), K = ct && et.call(a, "__wrapped__");
731
731
  if (Z || K) {
732
- var Xt = Z ? s.value() : s, Pt = K ? a.value() : a;
733
- return M || (M = new kt()), O(Xt, Pt, l, g, M);
732
+ var Gt = Z ? s.value() : s, Pt = K ? a.value() : a;
733
+ return M || (M = new bt()), O(Gt, Pt, l, g, M);
734
734
  }
735
735
  }
736
- return W ? (M || (M = new kt()), nn(s, a, l, g, O, M)) : !1;
736
+ return W ? (M || (M = new bt()), nn(s, a, l, g, O, M)) : !1;
737
737
  }
738
738
  function Qr(s) {
739
- if (!mr(s) || cn(s))
739
+ if (!hr(s) || cn(s))
740
740
  return !1;
741
- var a = hr(s) ? Pe : st;
741
+ var a = pr(s) ? Pe : st;
742
742
  return a.test(rt(s));
743
743
  }
744
744
  function tn(s) {
745
- return _t(s) && Ke(s.length) && !!$[pe(s)];
745
+ return vt(s) && Ke(s.length) && !!$[fe(s)];
746
746
  }
747
747
  function en(s) {
748
748
  if (!un(s))
749
- return It(s);
749
+ return yt(s);
750
750
  var a = [];
751
751
  for (var l in Object(s))
752
752
  et.call(s, l) && l != "constructor" && a.push(l);
753
753
  return a;
754
754
  }
755
755
  function Ge(s, a, l, g, O, M) {
756
- var D = l & i, P = s.length, U = a.length;
757
- if (P != U && !(D && U > P))
756
+ var D = l & i, R = s.length, U = a.length;
757
+ if (R != U && !(D && U > R))
758
758
  return !1;
759
759
  var N = M.get(s);
760
760
  if (N && M.get(a))
761
761
  return N == a;
762
- var J = -1, ct = !0, W = l & o ? new De() : void 0;
763
- for (M.set(s, a), M.set(a, s); ++J < P; ) {
762
+ var J = -1, ct = !0, W = l & o ? new Re() : void 0;
763
+ for (M.set(s, a), M.set(a, s); ++J < R; ) {
764
764
  var Z = s[J], K = a[J];
765
765
  if (g)
766
- var Xt = D ? g(K, Z, J, a, s, M) : g(Z, K, J, s, a, M);
767
- if (Xt !== void 0) {
768
- if (Xt)
766
+ var Gt = D ? g(K, Z, J, a, s, M) : g(Z, K, J, s, a, M);
767
+ if (Gt !== void 0) {
768
+ if (Gt)
769
769
  continue;
770
770
  ct = !1;
771
771
  break;
772
772
  }
773
773
  if (W) {
774
- if (!oe(a, function(Pt, me) {
775
- if (!wt(W, me) && (Z === Pt || O(Z, Pt, l, g, M)))
776
- return W.push(me);
774
+ if (!ae(a, function(Pt, he) {
775
+ if (!St(W, he) && (Z === Pt || O(Z, Pt, l, g, M)))
776
+ return W.push(he);
777
777
  })) {
778
778
  ct = !1;
779
779
  break;
@@ -792,40 +792,40 @@ vr.exports;
792
792
  return !1;
793
793
  s = s.buffer, a = a.buffer;
794
794
  case x:
795
- return !(s.byteLength != a.byteLength || !M(new fe(s), new fe(a)));
795
+ return !(s.byteLength != a.byteLength || !M(new de(s), new de(a)));
796
796
  case m:
797
797
  case y:
798
798
  case _:
799
- return fr(+s, +a);
799
+ return dr(+s, +a);
800
800
  case h:
801
801
  return s.name == a.name && s.message == a.message;
802
802
  case A:
803
803
  case E:
804
804
  return s == a + "";
805
805
  case b:
806
- var P = ce;
806
+ var R = oe;
807
807
  case S:
808
808
  var U = g & i;
809
- if (P || (P = ut), s.size != a.size && !U)
809
+ if (R || (R = ut), s.size != a.size && !U)
810
810
  return !1;
811
811
  var N = D.get(s);
812
812
  if (N)
813
813
  return N == a;
814
814
  g |= o, D.set(s, a);
815
- var J = Ge(P(s), P(a), g, O, M, D);
815
+ var J = Ge(R(s), R(a), g, O, M, D);
816
816
  return D.delete(s), J;
817
817
  case L:
818
- if (Be)
819
- return Be.call(s) == Be.call(a);
818
+ if (je)
819
+ return je.call(s) == je.call(a);
820
820
  }
821
821
  return !1;
822
822
  }
823
823
  function nn(s, a, l, g, O, M) {
824
- var D = l & i, P = he(s), U = P.length, N = he(a), J = N.length;
824
+ var D = l & i, R = pe(s), U = R.length, N = pe(a), J = N.length;
825
825
  if (U != J && !D)
826
826
  return !1;
827
827
  for (var ct = U; ct--; ) {
828
- var W = P[ct];
828
+ var W = R[ct];
829
829
  if (!(D ? W in a : et.call(a, W)))
830
830
  return !1;
831
831
  }
@@ -834,56 +834,56 @@ vr.exports;
834
834
  return Z == a;
835
835
  var K = !0;
836
836
  M.set(s, a), M.set(a, s);
837
- for (var Xt = D; ++ct < U; ) {
838
- W = P[ct];
839
- var Pt = s[W], me = a[W];
837
+ for (var Gt = D; ++ct < U; ) {
838
+ W = R[ct];
839
+ var Pt = s[W], he = a[W];
840
840
  if (g)
841
- var Hn = D ? g(me, Pt, W, a, s, M) : g(Pt, me, W, s, a, M);
842
- if (!(Hn === void 0 ? Pt === me || O(Pt, me, l, g, M) : Hn)) {
841
+ var Un = D ? g(he, Pt, W, a, s, M) : g(Pt, he, W, s, a, M);
842
+ if (!(Un === void 0 ? Pt === he || O(Pt, he, l, g, M) : Un)) {
843
843
  K = !1;
844
844
  break;
845
845
  }
846
- Xt || (Xt = W == "constructor");
846
+ Gt || (Gt = W == "constructor");
847
847
  }
848
- if (K && !Xt) {
849
- var yr = s.constructor, Ir = a.constructor;
850
- yr != Ir && "constructor" in s && "constructor" in a && !(typeof yr == "function" && yr instanceof yr && typeof Ir == "function" && Ir instanceof Ir) && (K = !1);
848
+ if (K && !Gt) {
849
+ var gr = s.constructor, yr = a.constructor;
850
+ gr != yr && "constructor" in s && "constructor" in a && !(typeof gr == "function" && gr instanceof gr && typeof yr == "function" && yr instanceof yr) && (K = !1);
851
851
  }
852
852
  return M.delete(s), M.delete(a), K;
853
853
  }
854
- function he(s) {
854
+ function pe(s) {
855
855
  return Ye(s, Ve, sn);
856
856
  }
857
- function mt(s, a) {
857
+ function ht(s, a) {
858
858
  var l = s.__data__;
859
859
  return on(a) ? l[typeof a == "string" ? "string" : "hash"] : l.map;
860
860
  }
861
- function Ct(s, a) {
862
- var l = Lt(s, a);
861
+ function Ot(s, a) {
862
+ var l = Nt(s, a);
863
863
  return Qr(l) ? l : void 0;
864
864
  }
865
- function Rt(s) {
865
+ function Ct(s) {
866
866
  var a = et.call(s, at), l = s[at];
867
867
  try {
868
868
  s[at] = void 0;
869
869
  var g = !0;
870
870
  } catch {
871
871
  }
872
- var O = de.call(s);
872
+ var O = le.call(s);
873
873
  return g && (a ? s[at] = l : delete s[at]), O;
874
874
  }
875
- var sn = xt ? function(s) {
876
- return s == null ? [] : (s = Object(s), ae(xt(s), function(a) {
877
- return Mt.call(s, a);
875
+ var sn = Mt ? function(s) {
876
+ return s == null ? [] : (s = Object(s), ie(Mt(s), function(a) {
877
+ return At.call(s, a);
878
878
  }));
879
- } : dn, vt = pe;
880
- (Bt && vt(new Bt(new ArrayBuffer(1))) != F || bt && vt(new bt()) != b || jt && vt(jt.resolve()) != T || Yt && vt(new Yt()) != S || We && vt(new We()) != Y) && (vt = function(s) {
881
- var a = pe(s), l = a == v ? s.constructor : void 0, g = l ? rt(l) : "";
879
+ } : dn, kt = fe;
880
+ (Wt && kt(new Wt(new ArrayBuffer(1))) != F || It && kt(new It()) != b || jt && kt(jt.resolve()) != T || Bt && kt(new Bt()) != S || We && kt(new We()) != Y) && (kt = function(s) {
881
+ var a = fe(s), l = a == v ? s.constructor : void 0, g = l ? rt(l) : "";
882
882
  if (g)
883
883
  switch (g) {
884
- case ar:
884
+ case ir:
885
885
  return F;
886
- case Ot:
886
+ case xt:
887
887
  return b;
888
888
  case xr:
889
889
  return T;
@@ -895,26 +895,26 @@ vr.exports;
895
895
  return a;
896
896
  });
897
897
  function an(s, a) {
898
- return a = a ?? c, !!a && (typeof s == "number" || ee.test(s)) && s > -1 && s % 1 == 0 && s < a;
898
+ return a = a ?? c, !!a && (typeof s == "number" || te.test(s)) && s > -1 && s % 1 == 0 && s < a;
899
899
  }
900
900
  function on(s) {
901
901
  var a = typeof s;
902
902
  return a == "string" || a == "number" || a == "symbol" || a == "boolean" ? s !== "__proto__" : s === null;
903
903
  }
904
904
  function cn(s) {
905
- return !!le && le in s;
905
+ return !!ue && ue in s;
906
906
  }
907
907
  function un(s) {
908
- var a = s && s.constructor, l = typeof a == "function" && a.prototype || gt;
908
+ var a = s && s.constructor, l = typeof a == "function" && a.prototype || mt;
909
909
  return s === l;
910
910
  }
911
- function dr(s) {
912
- return de.call(s);
911
+ function lr(s) {
912
+ return le.call(s);
913
913
  }
914
914
  function rt(s) {
915
915
  if (s != null) {
916
916
  try {
917
- return Ht.call(s);
917
+ return Lt.call(s);
918
918
  } catch {
919
919
  }
920
920
  try {
@@ -924,38 +924,38 @@ vr.exports;
924
924
  }
925
925
  return "";
926
926
  }
927
- function fr(s, a) {
927
+ function dr(s, a) {
928
928
  return s === a || s !== s && a !== a;
929
929
  }
930
- var pr = ur(/* @__PURE__ */ function() {
930
+ var fr = cr(/* @__PURE__ */ function() {
931
931
  return arguments;
932
- }()) ? ur : function(s) {
933
- return _t(s) && et.call(s, "callee") && !Mt.call(s, "callee");
934
- }, Fe = Array.isArray;
932
+ }()) ? cr : function(s) {
933
+ return vt(s) && et.call(s, "callee") && !At.call(s, "callee");
934
+ }, $e = Array.isArray;
935
935
  function Xe(s) {
936
- return s != null && Ke(s.length) && !hr(s);
936
+ return s != null && Ke(s.length) && !pr(s);
937
937
  }
938
- var Ne = Wt || fn;
938
+ var Fe = Ut || fn;
939
939
  function ln(s, a) {
940
- return lr(s, a);
940
+ return ur(s, a);
941
941
  }
942
- function hr(s) {
943
- if (!mr(s))
942
+ function pr(s) {
943
+ if (!hr(s))
944
944
  return !1;
945
- var a = pe(s);
945
+ var a = fe(s);
946
946
  return a == k || a == I || a == p || a == w;
947
947
  }
948
948
  function Ke(s) {
949
949
  return typeof s == "number" && s > -1 && s % 1 == 0 && s <= c;
950
950
  }
951
- function mr(s) {
951
+ function hr(s) {
952
952
  var a = typeof s;
953
953
  return s != null && (a == "object" || a == "function");
954
954
  }
955
- function _t(s) {
955
+ function vt(s) {
956
956
  return s != null && typeof s == "object";
957
957
  }
958
- var gr = Ft ? Ce(Ft) : tn;
958
+ var mr = $t ? Oe($t) : tn;
959
959
  function Ve(s) {
960
960
  return Xe(s) ? Jr(s) : en(s);
961
961
  }
@@ -967,44 +967,44 @@ vr.exports;
967
967
  }
968
968
  t.exports = ln;
969
969
  })(vr, vr.exports);
970
- var ti = vr.exports;
971
- const B = /* @__PURE__ */ Cn(ti), vo = "add", ei = "track", ri = "trackItems", _o = `${ei}:changed`, So = `${ri}:changed`, ni = "state", wo = `${ni}:changed`, si = "bulk", Xn = `${si}:edit`, Rn = "design", ii = `${Rn}:load`, ai = `${Rn}:resize`, H = "add", oi = `${H}:text`, ci = `${H}:video`, ui = `${H}:audio`, To = `${H}:placeholder`, li = `${H}:image`, di = `${H}:illustration`, fi = `${H}:shape`, Eo = `${H}:mask`, Ao = `${H}:transition`, pi = `${H}:animation`, hi = `${H}:caption`, mi = `${H}:template`, gi = `${H}:items`, yi = `${H}:composition`, Ii = `${H}:progressBar`, bi = `${H}:progressFrame`, ki = `${H}:radialAudioBars`, vi = `${H}:linealAudioBars`, _i = `${H}:progressSquare`, Si = `${H}:waveAudioBars`, wi = `${H}:hillAudioBars`, Ti = `${H}:rect`, Zt = "edit", Ei = `${Zt}:object`, Ai = `${Zt}:replaceMedia`, Mo = `${Zt}:text`, xo = `${Zt}:shape`, Oo = `${Zt}:templateItem`, Co = `${Zt}:deleteTemplateItem`, Mi = `${Zt}:backgroundEditor`, Ro = "enterEditMode", Le = "active", Po = `${Le}:set`, Do = `${Le}:delete`, xi = `${Le}:paste`, zo = `${Le}:clone`, Oi = `${Le}:split`, Q = "layer", $o = `${Q}:locked`, Fo = `${Q}:hidden`, No = `${Q}:move`, Ci = `${Q}:select`, Lo = `${Q}:selection`, Ho = `${Q}:sendTo`, Uo = `${Q}:rename`, Wo = `${Q}:editingName`, Ri = `${Q}:copy`, Bo = `${Q}:paste`, Pi = `${Q}:clone`, jo = `${Q}:split`, Yo = `${Q}:cut`, Di = `${Q}:delete`, zi = `${Q}:replace`, Ar = "history", $i = `${Ar}:undo`, Fi = `${Ar}:redo`, Go = `${Ar}:reset`, ds = "scale", Ni = `${ds}:changed`;
970
+ var ei = vr.exports;
971
+ const j = /* @__PURE__ */ Pn(ei), vo = "add", ri = "track", ni = "trackItems", _o = `${ri}:changed`, So = `${ni}:changed`, si = "state", wo = `${si}:changed`, ii = "bulk", Kn = `${ii}:edit`, Rn = "design", ai = `${Rn}:load`, oi = `${Rn}:resize`, H = "add", ci = `${H}:text`, ui = `${H}:video`, li = `${H}:audio`, To = `${H}:placeholder`, di = `${H}:image`, fi = `${H}:illustration`, pi = `${H}:shape`, Eo = `${H}:mask`, Ao = `${H}:transition`, hi = `${H}:animation`, mi = `${H}:caption`, gi = `${H}:template`, yi = `${H}:items`, Ii = `${H}:composition`, bi = `${H}:progressBar`, ki = `${H}:progressFrame`, vi = `${H}:radialAudioBars`, _i = `${H}:linealAudioBars`, Si = `${H}:progressSquare`, wi = `${H}:waveAudioBars`, Ti = `${H}:hillAudioBars`, Ei = `${H}:rect`, Jt = "edit", Ai = `${Jt}:object`, Mi = `${Jt}:replaceMedia`, Mo = `${Jt}:text`, xo = `${Jt}:shape`, Oo = `${Jt}:templateItem`, Co = `${Jt}:deleteTemplateItem`, xi = `${Jt}:backgroundEditor`, Po = "enterEditMode", Ne = "active", Ro = `${Ne}:set`, Do = `${Ne}:delete`, Oi = `${Ne}:paste`, zo = `${Ne}:clone`, Ci = `${Ne}:split`, Q = "layer", $o = `${Q}:locked`, Fo = `${Q}:hidden`, No = `${Q}:move`, Pi = `${Q}:select`, Lo = `${Q}:selection`, Ho = `${Q}:sendTo`, Uo = `${Q}:rename`, Wo = `${Q}:editingName`, Ri = `${Q}:copy`, jo = `${Q}:paste`, Di = `${Q}:clone`, Bo = `${Q}:split`, Yo = `${Q}:cut`, zi = `${Q}:delete`, $i = `${Q}:replace`, Ar = "history", Fi = `${Ar}:undo`, Ni = `${Ar}:redo`, Go = `${Ar}:reset`, fs = "scale", Li = `${fs}:changed`;
972
972
  var _r = { exports: {} };
973
973
  _r.exports;
974
974
  (function(t, r) {
975
- var e = 200, n = "__lodash_hash_undefined__", i = 9007199254740991, o = "[object Arguments]", c = "[object Array]", u = "[object Boolean]", d = "[object Date]", p = "[object Error]", m = "[object Function]", y = "[object GeneratorFunction]", h = "[object Map]", k = "[object Number]", I = "[object Object]", b = "[object Promise]", _ = "[object RegExp]", f = "[object Set]", v = "[object String]", T = "[object Symbol]", w = "[object WeakMap]", A = "[object ArrayBuffer]", S = "[object DataView]", E = "[object Float32Array]", L = "[object Float64Array]", R = "[object Int8Array]", Y = "[object Int16Array]", x = "[object Int32Array]", F = "[object Uint8Array]", tt = "[object Uint8ClampedArray]", Qt = "[object Uint16Array]", te = "[object Uint32Array]", Se = /[\\^$.*+?()[\]{}|]/g, we = /\w*$/, Te = /^\[object .+?Constructor\]$/, Ee = /^(?:0|[1-9]\d*)$/, z = {};
976
- z[o] = z[c] = z[A] = z[S] = z[u] = z[d] = z[E] = z[L] = z[R] = z[Y] = z[x] = z[h] = z[k] = z[I] = z[_] = z[f] = z[v] = z[T] = z[F] = z[tt] = z[Qt] = z[te] = !0, z[p] = z[m] = z[w] = !1;
977
- var Ae = typeof ft == "object" && ft && ft.Object === Object && ft, Me = typeof self == "object" && self && self.Object === Object && self, st = Ae || Me || Function("return this")(), ee = r && !r.nodeType && r, $ = ee && !0 && t && !t.nodeType && t, re = $ && $.exports === ee;
978
- function xe(s, a) {
975
+ var e = 200, n = "__lodash_hash_undefined__", i = 9007199254740991, o = "[object Arguments]", c = "[object Array]", u = "[object Boolean]", d = "[object Date]", p = "[object Error]", m = "[object Function]", y = "[object GeneratorFunction]", h = "[object Map]", k = "[object Number]", I = "[object Object]", b = "[object Promise]", _ = "[object RegExp]", f = "[object Set]", v = "[object String]", T = "[object Symbol]", w = "[object WeakMap]", A = "[object ArrayBuffer]", S = "[object DataView]", E = "[object Float32Array]", L = "[object Float64Array]", P = "[object Int8Array]", Y = "[object Int16Array]", x = "[object Int32Array]", F = "[object Uint8Array]", tt = "[object Uint8ClampedArray]", Zt = "[object Uint16Array]", Qt = "[object Uint32Array]", _e = /[\\^$.*+?()[\]{}|]/g, Se = /\w*$/, we = /^\[object .+?Constructor\]$/, Te = /^(?:0|[1-9]\d*)$/, z = {};
976
+ z[o] = z[c] = z[A] = z[S] = z[u] = z[d] = z[E] = z[L] = z[P] = z[Y] = z[x] = z[h] = z[k] = z[I] = z[_] = z[f] = z[v] = z[T] = z[F] = z[tt] = z[Zt] = z[Qt] = !0, z[p] = z[m] = z[w] = !1;
977
+ var Ee = typeof dt == "object" && dt && dt.Object === Object && dt, Ae = typeof self == "object" && self && self.Object === Object && self, st = Ee || Ae || Function("return this")(), te = r && !r.nodeType && r, $ = te && !0 && t && !t.nodeType && t, ee = $ && $.exports === te;
978
+ function Me(s, a) {
979
979
  return s.set(a[0], a[1]), s;
980
980
  }
981
981
  function it(s, a) {
982
982
  return s.add(a), s;
983
983
  }
984
- function ne(s, a) {
984
+ function re(s, a) {
985
985
  for (var l = -1, g = s ? s.length : 0; ++l < g && a(s[l], l, s) !== !1; )
986
986
  ;
987
987
  return s;
988
988
  }
989
- function se(s, a) {
989
+ function ne(s, a) {
990
990
  for (var l = -1, g = a.length, O = s.length; ++l < g; )
991
991
  s[O + l] = a[l];
992
992
  return s;
993
993
  }
994
- function zt(s, a, l, g) {
994
+ function Dt(s, a, l, g) {
995
995
  for (var O = -1, M = s ? s.length : 0; ++O < M; )
996
996
  l = a(l, s[O], O, s);
997
997
  return l;
998
998
  }
999
- function $t(s, a) {
999
+ function zt(s, a) {
1000
1000
  for (var l = -1, g = Array(s); ++l < s; )
1001
1001
  g[l] = a(l);
1002
1002
  return g;
1003
1003
  }
1004
- function ie(s, a) {
1004
+ function se(s, a) {
1005
1005
  return s == null ? void 0 : s[a];
1006
1006
  }
1007
- function Ft(s) {
1007
+ function $t(s) {
1008
1008
  var a = !1;
1009
1009
  if (s != null && typeof s.toString != "function")
1010
1010
  try {
@@ -1013,30 +1013,30 @@ _r.exports;
1013
1013
  }
1014
1014
  return a;
1015
1015
  }
1016
- function ae(s) {
1016
+ function ie(s) {
1017
1017
  var a = -1, l = Array(s.size);
1018
1018
  return s.forEach(function(g, O) {
1019
1019
  l[++a] = [O, g];
1020
1020
  }), l;
1021
1021
  }
1022
- function Nt(s, a) {
1022
+ function Ft(s, a) {
1023
1023
  return function(l) {
1024
1024
  return s(a(l));
1025
1025
  };
1026
1026
  }
1027
- function oe(s) {
1027
+ function ae(s) {
1028
1028
  var a = -1, l = Array(s.size);
1029
1029
  return s.forEach(function(g) {
1030
1030
  l[++a] = g;
1031
1031
  }), l;
1032
1032
  }
1033
- var Oe = Array.prototype, Ce = Function.prototype, wt = Object.prototype, Lt = st["__core-js_shared__"], ce = function() {
1034
- var s = /[^.]+$/.exec(Lt && Lt.keys && Lt.keys.IE_PROTO || "");
1033
+ var xe = Array.prototype, Oe = Function.prototype, St = Object.prototype, Nt = st["__core-js_shared__"], oe = function() {
1034
+ var s = /[^.]+$/.exec(Nt && Nt.keys && Nt.keys.IE_PROTO || "");
1035
1035
  return s ? "Symbol(src)_1." + s : "";
1036
- }(), ue = Ce.toString, ut = wt.hasOwnProperty, Tt = wt.toString, Re = RegExp(
1037
- "^" + ue.call(ut).replace(Se, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
1038
- ), gt = re ? st.Buffer : void 0, Et = st.Symbol, Ht = st.Uint8Array, et = Nt(Object.getPrototypeOf, Object), le = Object.create, de = wt.propertyIsEnumerable, Pe = Oe.splice, Ut = Object.getOwnPropertySymbols, At = gt ? gt.isBuffer : void 0, fe = Nt(Object.keys, Object), Mt = mt(st, "DataView"), yt = mt(st, "Map"), at = mt(st, "Promise"), xt = mt(st, "Set"), Wt = mt(st, "WeakMap"), It = mt(Object, "create"), Bt = rt(Mt), bt = rt(yt), jt = rt(at), Yt = rt(xt), We = rt(Wt), Gt = Et ? Et.prototype : void 0, ar = Gt ? Gt.valueOf : void 0;
1039
- function Ot(s) {
1036
+ }(), ce = Oe.toString, ut = St.hasOwnProperty, wt = St.toString, Ce = RegExp(
1037
+ "^" + ce.call(ut).replace(_e, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
1038
+ ), mt = ee ? st.Buffer : void 0, Tt = st.Symbol, Lt = st.Uint8Array, et = Ft(Object.getPrototypeOf, Object), ue = Object.create, le = St.propertyIsEnumerable, Pe = xe.splice, Ht = Object.getOwnPropertySymbols, Et = mt ? mt.isBuffer : void 0, de = Ft(Object.keys, Object), At = ht(st, "DataView"), gt = ht(st, "Map"), at = ht(st, "Promise"), Mt = ht(st, "Set"), Ut = ht(st, "WeakMap"), yt = ht(Object, "create"), Wt = rt(At), It = rt(gt), jt = rt(at), Bt = rt(Mt), We = rt(Ut), Yt = Tt ? Tt.prototype : void 0, ir = Yt ? Yt.valueOf : void 0;
1039
+ function xt(s) {
1040
1040
  var a = -1, l = s ? s.length : 0;
1041
1041
  for (this.clear(); ++a < l; ) {
1042
1042
  var g = s[a];
@@ -1044,28 +1044,28 @@ _r.exports;
1044
1044
  }
1045
1045
  }
1046
1046
  function xr() {
1047
- this.__data__ = It ? It(null) : {};
1047
+ this.__data__ = yt ? yt(null) : {};
1048
1048
  }
1049
1049
  function Or(s) {
1050
1050
  return this.has(s) && delete this.__data__[s];
1051
1051
  }
1052
1052
  function Cr(s) {
1053
1053
  var a = this.__data__;
1054
- if (It) {
1054
+ if (yt) {
1055
1055
  var l = a[s];
1056
1056
  return l === n ? void 0 : l;
1057
1057
  }
1058
1058
  return ut.call(a, s) ? a[s] : void 0;
1059
1059
  }
1060
- function or(s) {
1060
+ function ar(s) {
1061
1061
  var a = this.__data__;
1062
- return It ? a[s] !== void 0 : ut.call(a, s);
1062
+ return yt ? a[s] !== void 0 : ut.call(a, s);
1063
1063
  }
1064
- function Be(s, a) {
1064
+ function je(s, a) {
1065
1065
  var l = this.__data__;
1066
- return l[s] = It && a === void 0 ? n : a, this;
1066
+ return l[s] = yt && a === void 0 ? n : a, this;
1067
1067
  }
1068
- Ot.prototype.clear = xr, Ot.prototype.delete = Or, Ot.prototype.get = Cr, Ot.prototype.has = or, Ot.prototype.set = Be;
1068
+ xt.prototype.clear = xr, xt.prototype.delete = Or, xt.prototype.get = Cr, xt.prototype.has = ar, xt.prototype.set = je;
1069
1069
  function X(s) {
1070
1070
  var a = -1, l = s ? s.length : 0;
1071
1071
  for (this.clear(); ++a < l; ) {
@@ -1073,28 +1073,28 @@ _r.exports;
1073
1073
  this.set(g[0], g[1]);
1074
1074
  }
1075
1075
  }
1076
- function Rr() {
1076
+ function Pr() {
1077
1077
  this.__data__ = [];
1078
1078
  }
1079
- function Pr(s) {
1080
- var a = this.__data__, l = ze(a, s);
1079
+ function Rr(s) {
1080
+ var a = this.__data__, l = De(a, s);
1081
1081
  if (l < 0)
1082
1082
  return !1;
1083
1083
  var g = a.length - 1;
1084
1084
  return l == g ? a.pop() : Pe.call(a, l, 1), !0;
1085
1085
  }
1086
1086
  function Dr(s) {
1087
- var a = this.__data__, l = ze(a, s);
1087
+ var a = this.__data__, l = De(a, s);
1088
1088
  return l < 0 ? void 0 : a[l][1];
1089
1089
  }
1090
1090
  function zr(s) {
1091
- return ze(this.__data__, s) > -1;
1091
+ return De(this.__data__, s) > -1;
1092
1092
  }
1093
1093
  function $r(s, a) {
1094
- var l = this.__data__, g = ze(l, s);
1094
+ var l = this.__data__, g = De(l, s);
1095
1095
  return g < 0 ? l.push([s, a]) : l[g][1] = a, this;
1096
1096
  }
1097
- X.prototype.clear = Rr, X.prototype.delete = Pr, X.prototype.get = Dr, X.prototype.has = zr, X.prototype.set = $r;
1097
+ X.prototype.clear = Pr, X.prototype.delete = Rr, X.prototype.get = Dr, X.prototype.has = zr, X.prototype.set = $r;
1098
1098
  function q(s) {
1099
1099
  var a = -1, l = s ? s.length : 0;
1100
1100
  for (this.clear(); ++a < l; ) {
@@ -1104,22 +1104,22 @@ _r.exports;
1104
1104
  }
1105
1105
  function Fr() {
1106
1106
  this.__data__ = {
1107
- hash: new Ot(),
1108
- map: new (yt || X)(),
1109
- string: new Ot()
1107
+ hash: new xt(),
1108
+ map: new (gt || X)(),
1109
+ string: new xt()
1110
1110
  };
1111
1111
  }
1112
1112
  function Nr(s) {
1113
- return he(this, s).delete(s);
1113
+ return pe(this, s).delete(s);
1114
1114
  }
1115
1115
  function Lr(s) {
1116
- return he(this, s).get(s);
1116
+ return pe(this, s).get(s);
1117
1117
  }
1118
1118
  function Hr(s) {
1119
- return he(this, s).has(s);
1119
+ return pe(this, s).has(s);
1120
1120
  }
1121
1121
  function Ur(s, a) {
1122
- return he(this, s).set(s, a), this;
1122
+ return pe(this, s).set(s, a), this;
1123
1123
  }
1124
1124
  q.prototype.clear = Fr, q.prototype.delete = Nr, q.prototype.get = Lr, q.prototype.has = Hr, q.prototype.set = Ur;
1125
1125
  function ot(s) {
@@ -1128,10 +1128,10 @@ _r.exports;
1128
1128
  function Wr() {
1129
1129
  this.__data__ = new X();
1130
1130
  }
1131
- function Br(s) {
1131
+ function jr(s) {
1132
1132
  return this.__data__.delete(s);
1133
1133
  }
1134
- function jr(s) {
1134
+ function Br(s) {
1135
1135
  return this.__data__.get(s);
1136
1136
  }
1137
1137
  function Yr(s) {
@@ -1141,92 +1141,92 @@ _r.exports;
1141
1141
  var l = this.__data__;
1142
1142
  if (l instanceof X) {
1143
1143
  var g = l.__data__;
1144
- if (!yt || g.length < e - 1)
1144
+ if (!gt || g.length < e - 1)
1145
1145
  return g.push([s, a]), this;
1146
1146
  l = this.__data__ = new q(g);
1147
1147
  }
1148
1148
  return l.set(s, a), this;
1149
1149
  }
1150
- ot.prototype.clear = Wr, ot.prototype.delete = Br, ot.prototype.get = jr, ot.prototype.has = Yr, ot.prototype.set = Gr;
1151
- function De(s, a) {
1152
- var l = Xe(s) || Fe(s) ? $t(s.length, String) : [], g = l.length, O = !!g;
1150
+ ot.prototype.clear = Wr, ot.prototype.delete = jr, ot.prototype.get = Br, ot.prototype.has = Yr, ot.prototype.set = Gr;
1151
+ function Re(s, a) {
1152
+ var l = Xe(s) || $e(s) ? zt(s.length, String) : [], g = l.length, O = !!g;
1153
1153
  for (var M in s)
1154
1154
  ut.call(s, M) && !(O && (M == "length" || on(M, g))) && l.push(M);
1155
1155
  return l;
1156
1156
  }
1157
- function cr(s, a, l) {
1157
+ function or(s, a, l) {
1158
1158
  var g = s[a];
1159
- (!(ut.call(s, a) && pr(g, l)) || l === void 0 && !(a in s)) && (s[a] = l);
1159
+ (!(ut.call(s, a) && fr(g, l)) || l === void 0 && !(a in s)) && (s[a] = l);
1160
1160
  }
1161
- function ze(s, a) {
1161
+ function De(s, a) {
1162
1162
  for (var l = s.length; l--; )
1163
- if (pr(s[l][0], a))
1163
+ if (fr(s[l][0], a))
1164
1164
  return l;
1165
1165
  return -1;
1166
1166
  }
1167
- function kt(s, a) {
1167
+ function bt(s, a) {
1168
1168
  return s && Ge(a, Ve(a), s);
1169
1169
  }
1170
- function je(s, a, l, g, O, M, D) {
1171
- var P;
1172
- if (g && (P = M ? g(s, O, M, D) : g(s)), P !== void 0)
1173
- return P;
1174
- if (!_t(s))
1170
+ function Be(s, a, l, g, O, M, D) {
1171
+ var R;
1172
+ if (g && (R = M ? g(s, O, M, D) : g(s)), R !== void 0)
1173
+ return R;
1174
+ if (!vt(s))
1175
1175
  return s;
1176
1176
  var U = Xe(s);
1177
1177
  if (U) {
1178
- if (P = sn(s), !a)
1179
- return en(s, P);
1178
+ if (R = sn(s), !a)
1179
+ return en(s, R);
1180
1180
  } else {
1181
- var N = Rt(s), J = N == m || N == y;
1182
- if (hr(s))
1183
- return $e(s, a);
1181
+ var N = Ct(s), J = N == m || N == y;
1182
+ if (pr(s))
1183
+ return ze(s, a);
1184
1184
  if (N == I || N == o || J && !M) {
1185
- if (Ft(s))
1185
+ if ($t(s))
1186
1186
  return M ? s : {};
1187
- if (P = vt(J ? {} : s), !a)
1188
- return rn(s, kt(P, s));
1187
+ if (R = kt(J ? {} : s), !a)
1188
+ return rn(s, bt(R, s));
1189
1189
  } else {
1190
1190
  if (!z[N])
1191
1191
  return M ? s : {};
1192
- P = an(s, N, je, a);
1192
+ R = an(s, N, Be, a);
1193
1193
  }
1194
1194
  }
1195
1195
  D || (D = new ot());
1196
1196
  var ct = D.get(s);
1197
1197
  if (ct)
1198
1198
  return ct;
1199
- if (D.set(s, P), !U)
1199
+ if (D.set(s, R), !U)
1200
1200
  var W = l ? nn(s) : Ve(s);
1201
- return ne(W || s, function(Z, K) {
1202
- W && (K = Z, Z = s[K]), cr(P, K, je(Z, a, l, g, K, s, D));
1203
- }), P;
1201
+ return re(W || s, function(Z, K) {
1202
+ W && (K = Z, Z = s[K]), or(R, K, Be(Z, a, l, g, K, s, D));
1203
+ }), R;
1204
1204
  }
1205
1205
  function Xr(s) {
1206
- return _t(s) ? le(s) : {};
1206
+ return vt(s) ? ue(s) : {};
1207
1207
  }
1208
1208
  function Kr(s, a, l) {
1209
1209
  var g = a(s);
1210
- return Xe(s) ? g : se(g, l(s));
1210
+ return Xe(s) ? g : ne(g, l(s));
1211
1211
  }
1212
1212
  function Vr(s) {
1213
- return Tt.call(s);
1213
+ return wt.call(s);
1214
1214
  }
1215
1215
  function qr(s) {
1216
- if (!_t(s) || un(s))
1216
+ if (!vt(s) || un(s))
1217
1217
  return !1;
1218
- var a = Ke(s) || Ft(s) ? Re : Te;
1218
+ var a = Ke(s) || $t(s) ? Ce : we;
1219
1219
  return a.test(rt(s));
1220
1220
  }
1221
1221
  function Jr(s) {
1222
- if (!dr(s))
1223
- return fe(s);
1222
+ if (!lr(s))
1223
+ return de(s);
1224
1224
  var a = [];
1225
1225
  for (var l in Object(s))
1226
1226
  ut.call(s, l) && l != "constructor" && a.push(l);
1227
1227
  return a;
1228
1228
  }
1229
- function $e(s, a) {
1229
+ function ze(s, a) {
1230
1230
  if (a)
1231
1231
  return s.slice();
1232
1232
  var l = new s.constructor(s.length);
@@ -1234,26 +1234,26 @@ _r.exports;
1234
1234
  }
1235
1235
  function Ye(s) {
1236
1236
  var a = new s.constructor(s.byteLength);
1237
- return new Ht(a).set(new Ht(s)), a;
1237
+ return new Lt(a).set(new Lt(s)), a;
1238
1238
  }
1239
- function pe(s, a) {
1239
+ function fe(s, a) {
1240
1240
  var l = a ? Ye(s.buffer) : s.buffer;
1241
1241
  return new s.constructor(l, s.byteOffset, s.byteLength);
1242
1242
  }
1243
- function ur(s, a, l) {
1244
- var g = a ? l(ae(s), !0) : ae(s);
1245
- return zt(g, xe, new s.constructor());
1243
+ function cr(s, a, l) {
1244
+ var g = a ? l(ie(s), !0) : ie(s);
1245
+ return Dt(g, Me, new s.constructor());
1246
1246
  }
1247
- function lr(s) {
1248
- var a = new s.constructor(s.source, we.exec(s));
1247
+ function ur(s) {
1248
+ var a = new s.constructor(s.source, Se.exec(s));
1249
1249
  return a.lastIndex = s.lastIndex, a;
1250
1250
  }
1251
1251
  function Zr(s, a, l) {
1252
- var g = a ? l(oe(s), !0) : oe(s);
1253
- return zt(g, it, new s.constructor());
1252
+ var g = a ? l(ae(s), !0) : ae(s);
1253
+ return Dt(g, it, new s.constructor());
1254
1254
  }
1255
1255
  function Qr(s) {
1256
- return ar ? Object(ar.call(s)) : {};
1256
+ return ir ? Object(ir.call(s)) : {};
1257
1257
  }
1258
1258
  function tn(s, a) {
1259
1259
  var l = a ? Ye(s.buffer) : s.buffer;
@@ -1268,37 +1268,37 @@ _r.exports;
1268
1268
  function Ge(s, a, l, g) {
1269
1269
  l || (l = {});
1270
1270
  for (var O = -1, M = a.length; ++O < M; ) {
1271
- var D = a[O], P = void 0;
1272
- cr(l, D, P === void 0 ? s[D] : P);
1271
+ var D = a[O], R = void 0;
1272
+ or(l, D, R === void 0 ? s[D] : R);
1273
1273
  }
1274
1274
  return l;
1275
1275
  }
1276
1276
  function rn(s, a) {
1277
- return Ge(s, Ct(s), a);
1277
+ return Ge(s, Ot(s), a);
1278
1278
  }
1279
1279
  function nn(s) {
1280
- return Kr(s, Ve, Ct);
1280
+ return Kr(s, Ve, Ot);
1281
1281
  }
1282
- function he(s, a) {
1282
+ function pe(s, a) {
1283
1283
  var l = s.__data__;
1284
1284
  return cn(a) ? l[typeof a == "string" ? "string" : "hash"] : l.map;
1285
1285
  }
1286
- function mt(s, a) {
1287
- var l = ie(s, a);
1286
+ function ht(s, a) {
1287
+ var l = se(s, a);
1288
1288
  return qr(l) ? l : void 0;
1289
1289
  }
1290
- var Ct = Ut ? Nt(Ut, Object) : dn, Rt = Vr;
1291
- (Mt && Rt(new Mt(new ArrayBuffer(1))) != S || yt && Rt(new yt()) != h || at && Rt(at.resolve()) != b || xt && Rt(new xt()) != f || Wt && Rt(new Wt()) != w) && (Rt = function(s) {
1292
- var a = Tt.call(s), l = a == I ? s.constructor : void 0, g = l ? rt(l) : void 0;
1290
+ var Ot = Ht ? Ft(Ht, Object) : dn, Ct = Vr;
1291
+ (At && Ct(new At(new ArrayBuffer(1))) != S || gt && Ct(new gt()) != h || at && Ct(at.resolve()) != b || Mt && Ct(new Mt()) != f || Ut && Ct(new Ut()) != w) && (Ct = function(s) {
1292
+ var a = wt.call(s), l = a == I ? s.constructor : void 0, g = l ? rt(l) : void 0;
1293
1293
  if (g)
1294
1294
  switch (g) {
1295
- case Bt:
1295
+ case Wt:
1296
1296
  return S;
1297
- case bt:
1297
+ case It:
1298
1298
  return h;
1299
1299
  case jt:
1300
1300
  return b;
1301
- case Yt:
1301
+ case Bt:
1302
1302
  return f;
1303
1303
  case We:
1304
1304
  return w;
@@ -1309,8 +1309,8 @@ _r.exports;
1309
1309
  var a = s.length, l = s.constructor(a);
1310
1310
  return a && typeof s[0] == "string" && ut.call(s, "index") && (l.index = s.index, l.input = s.input), l;
1311
1311
  }
1312
- function vt(s) {
1313
- return typeof s.constructor == "function" && !dr(s) ? Xr(et(s)) : {};
1312
+ function kt(s) {
1313
+ return typeof s.constructor == "function" && !lr(s) ? Xr(et(s)) : {};
1314
1314
  }
1315
1315
  function an(s, a, l, g) {
1316
1316
  var O = s.constructor;
@@ -1321,24 +1321,24 @@ _r.exports;
1321
1321
  case d:
1322
1322
  return new O(+s);
1323
1323
  case S:
1324
- return pe(s, g);
1324
+ return fe(s, g);
1325
1325
  case E:
1326
1326
  case L:
1327
- case R:
1327
+ case P:
1328
1328
  case Y:
1329
1329
  case x:
1330
1330
  case F:
1331
1331
  case tt:
1332
+ case Zt:
1332
1333
  case Qt:
1333
- case te:
1334
1334
  return tn(s, g);
1335
1335
  case h:
1336
- return ur(s, g, l);
1336
+ return cr(s, g, l);
1337
1337
  case k:
1338
1338
  case v:
1339
1339
  return new O(s);
1340
1340
  case _:
1341
- return lr(s);
1341
+ return ur(s);
1342
1342
  case f:
1343
1343
  return Zr(s, g, l);
1344
1344
  case T:
@@ -1346,23 +1346,23 @@ _r.exports;
1346
1346
  }
1347
1347
  }
1348
1348
  function on(s, a) {
1349
- return a = a ?? i, !!a && (typeof s == "number" || Ee.test(s)) && s > -1 && s % 1 == 0 && s < a;
1349
+ return a = a ?? i, !!a && (typeof s == "number" || Te.test(s)) && s > -1 && s % 1 == 0 && s < a;
1350
1350
  }
1351
1351
  function cn(s) {
1352
1352
  var a = typeof s;
1353
1353
  return a == "string" || a == "number" || a == "symbol" || a == "boolean" ? s !== "__proto__" : s === null;
1354
1354
  }
1355
1355
  function un(s) {
1356
- return !!ce && ce in s;
1356
+ return !!oe && oe in s;
1357
1357
  }
1358
- function dr(s) {
1359
- var a = s && s.constructor, l = typeof a == "function" && a.prototype || wt;
1358
+ function lr(s) {
1359
+ var a = s && s.constructor, l = typeof a == "function" && a.prototype || St;
1360
1360
  return s === l;
1361
1361
  }
1362
1362
  function rt(s) {
1363
1363
  if (s != null) {
1364
1364
  try {
1365
- return ue.call(s);
1365
+ return ce.call(s);
1366
1366
  } catch {
1367
1367
  }
1368
1368
  try {
@@ -1372,39 +1372,39 @@ _r.exports;
1372
1372
  }
1373
1373
  return "";
1374
1374
  }
1375
- function fr(s) {
1376
- return je(s, !0, !0);
1375
+ function dr(s) {
1376
+ return Be(s, !0, !0);
1377
1377
  }
1378
- function pr(s, a) {
1378
+ function fr(s, a) {
1379
1379
  return s === a || s !== s && a !== a;
1380
1380
  }
1381
- function Fe(s) {
1382
- return ln(s) && ut.call(s, "callee") && (!de.call(s, "callee") || Tt.call(s) == o);
1381
+ function $e(s) {
1382
+ return ln(s) && ut.call(s, "callee") && (!le.call(s, "callee") || wt.call(s) == o);
1383
1383
  }
1384
1384
  var Xe = Array.isArray;
1385
- function Ne(s) {
1386
- return s != null && mr(s.length) && !Ke(s);
1385
+ function Fe(s) {
1386
+ return s != null && hr(s.length) && !Ke(s);
1387
1387
  }
1388
1388
  function ln(s) {
1389
- return gr(s) && Ne(s);
1389
+ return mr(s) && Fe(s);
1390
1390
  }
1391
- var hr = At || fn;
1391
+ var pr = Et || fn;
1392
1392
  function Ke(s) {
1393
- var a = _t(s) ? Tt.call(s) : "";
1393
+ var a = vt(s) ? wt.call(s) : "";
1394
1394
  return a == m || a == y;
1395
1395
  }
1396
- function mr(s) {
1396
+ function hr(s) {
1397
1397
  return typeof s == "number" && s > -1 && s % 1 == 0 && s <= i;
1398
1398
  }
1399
- function _t(s) {
1399
+ function vt(s) {
1400
1400
  var a = typeof s;
1401
1401
  return !!s && (a == "object" || a == "function");
1402
1402
  }
1403
- function gr(s) {
1403
+ function mr(s) {
1404
1404
  return !!s && typeof s == "object";
1405
1405
  }
1406
1406
  function Ve(s) {
1407
- return Ne(s) ? De(s) : Jr(s);
1407
+ return Fe(s) ? Re(s) : Jr(s);
1408
1408
  }
1409
1409
  function dn() {
1410
1410
  return [];
@@ -1412,11 +1412,11 @@ _r.exports;
1412
1412
  function fn() {
1413
1413
  return !1;
1414
1414
  }
1415
- t.exports = fr;
1415
+ t.exports = dr;
1416
1416
  })(_r, _r.exports);
1417
- var Li = _r.exports;
1418
- const C = /* @__PURE__ */ Cn(Li);
1419
- function Hi(t, r) {
1417
+ var Hi = _r.exports;
1418
+ const C = /* @__PURE__ */ Pn(Hi);
1419
+ function Ui(t, r) {
1420
1420
  return t.filter((n) => {
1421
1421
  if (r.forEach((i) => {
1422
1422
  if (n.items.includes(i)) {
@@ -1473,11 +1473,11 @@ function nt(t, r, e) {
1473
1473
  });
1474
1474
  });
1475
1475
  }
1476
- function fs(t, r, e, n, i, o) {
1476
+ function ps(t, r, e, n, i, o) {
1477
1477
  return r.forEach((c) => {
1478
1478
  if (!t.includes(c) && (i[c] = e[c], e[c].type === "composition" || e[c].type === "template")) {
1479
1479
  const u = n.find((d) => d.id === c);
1480
- u && (o.push(u), fs(
1480
+ u && (o.push(u), ps(
1481
1481
  t,
1482
1482
  u.items,
1483
1483
  e,
@@ -1488,7 +1488,7 @@ function fs(t, r, e, n, i, o) {
1488
1488
  }
1489
1489
  }), { updatedTrackItems: i, updatedStructure: o };
1490
1490
  }
1491
- function Ui(t, r) {
1491
+ function Wi(t, r) {
1492
1492
  const e = C(t), n = r && r.length ? r : e.activeIds, i = n.map((S) => e.trackItemsMap[S]).filter((S) => !!S).map((S) => S.id), o = e.transitionIds.filter(
1493
1493
  (S) => {
1494
1494
  const E = e.transitionsMap[S];
@@ -1501,10 +1501,10 @@ function Ui(t, r) {
1501
1501
  var L;
1502
1502
  const E = e.trackItemsMap[S] || e.transitionsMap[S];
1503
1503
  if (E.type === "template" || E.type === "composition") {
1504
- const R = (L = e.structure.find(
1504
+ const P = (L = e.structure.find(
1505
1505
  (x) => x.id === E.id
1506
1506
  )) == null ? void 0 : L.items;
1507
- i.push(...R);
1507
+ i.push(...P);
1508
1508
  const Y = p.findIndex(
1509
1509
  (x) => x.id === E.id
1510
1510
  );
@@ -1533,7 +1533,7 @@ function Ui(t, r) {
1533
1533
  });
1534
1534
  const k = e.trackItemIds.filter(
1535
1535
  (S) => !n.includes(S)
1536
- ), I = Hi(
1536
+ ), I = Ui(
1537
1537
  e.tracks,
1538
1538
  n
1539
1539
  ), b = Object.fromEntries(
@@ -1542,7 +1542,7 @@ function Ui(t, r) {
1542
1542
  )
1543
1543
  ), _ = d.filter((S) => S.magnetic);
1544
1544
  nt(_, b, []);
1545
- const f = {}, v = [], { updatedTrackItems: T, updatedStructure: w } = fs(
1545
+ const f = {}, v = [], { updatedTrackItems: T, updatedStructure: w } = ps(
1546
1546
  i,
1547
1547
  k,
1548
1548
  e.trackItemsMap,
@@ -1561,19 +1561,19 @@ function Ui(t, r) {
1561
1561
  transitionsMap: h
1562
1562
  };
1563
1563
  }
1564
- const Wi = "useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";
1565
- let ps = (t = 21) => {
1564
+ const ji = "useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";
1565
+ let hs = (t = 21) => {
1566
1566
  let r = "", e = crypto.getRandomValues(new Uint8Array(t |= 0));
1567
1567
  for (; t--; )
1568
- r += Wi[e[t] & 63];
1568
+ r += ji[e[t] & 63];
1569
1569
  return r;
1570
1570
  };
1571
- function Ie(t = 16) {
1571
+ function ye(t = 16) {
1572
1572
  const r = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ", e = r.charAt(Math.floor(Math.random() * r.length));
1573
- let n = ps(t - 1);
1573
+ let n = hs(t - 1);
1574
1574
  return n = n.replace(/[^a-zA-Z0-9]/g, "").slice(0, t - 1), e + n;
1575
1575
  }
1576
- const He = (t) => {
1576
+ const Le = (t) => {
1577
1577
  const r = t.map((e) => new FontFace(e.fontFamily, `url(${e.url})`).load().catch((n) => n));
1578
1578
  return r.length === 0 ? Promise.resolve(!0) : new Promise((e, n) => {
1579
1579
  Promise.all(r).then((i) => {
@@ -1585,26 +1585,26 @@ const He = (t) => {
1585
1585
  };
1586
1586
  function Bi(t, r) {
1587
1587
  return t.forEach((e) => {
1588
- r = r.split(e).join(Ie());
1588
+ r = r.split(e).join(ye());
1589
1589
  }), r;
1590
1590
  }
1591
- function hs(t, r, e) {
1591
+ function ms(t, r, e) {
1592
1592
  const n = t.find((o) => o.id === r);
1593
1593
  if (!n) return [];
1594
1594
  const i = n.items;
1595
1595
  return i.forEach((o) => {
1596
1596
  const c = e[o];
1597
- (c.type === "text" || c.type === "caption") && He([
1597
+ (c.type === "text" || c.type === "caption") && Le([
1598
1598
  {
1599
1599
  fontFamily: c.details.fontFamily,
1600
1600
  url: c.details.fontUrl
1601
1601
  }
1602
1602
  ]), (c.type === "composition" || c.type === "template") && i.push(
1603
- ...hs(t, o, e)
1603
+ ...ms(t, o, e)
1604
1604
  );
1605
1605
  }), i;
1606
1606
  }
1607
- async function ji(t) {
1607
+ async function Yi(t) {
1608
1608
  let r = localStorage.getItem("DesignComboTemp");
1609
1609
  if (!r) return {};
1610
1610
  const e = C(t);
@@ -1612,13 +1612,13 @@ async function ji(t) {
1612
1612
  const i = n.activeIds, o = n.trackItemsMap, c = n.structure;
1613
1613
  Object.keys(o).forEach((b) => {
1614
1614
  const _ = o[b];
1615
- if ((_.type === "text" || _.type === "caption") && He([
1615
+ if ((_.type === "text" || _.type === "caption") && Le([
1616
1616
  {
1617
1617
  fontFamily: _.details.fontFamily,
1618
1618
  url: _.details.fontUrl
1619
1619
  }
1620
1620
  ]), _.type === "composition" || _.type === "template") {
1621
- const f = hs(
1621
+ const f = ms(
1622
1622
  c,
1623
1623
  b,
1624
1624
  o
@@ -1631,7 +1631,7 @@ async function ji(t) {
1631
1631
  const _ = d.trackItemsMap[b];
1632
1632
  e.trackItemsMap[b] = _, e.trackItemIds.push(b);
1633
1633
  const f = {
1634
- id: Ie(),
1634
+ id: ye(),
1635
1635
  type: _.type,
1636
1636
  items: [b],
1637
1637
  magnetic: !1,
@@ -1684,47 +1684,47 @@ let Sr = {
1684
1684
  progressSquare: ["progressSquare"]
1685
1685
  }
1686
1686
  };
1687
- const Yi = (t) => {
1687
+ const Gi = (t) => {
1688
1688
  const r = Object.fromEntries(
1689
1689
  Object.entries(t).filter(([e, n]) => n !== void 0)
1690
1690
  );
1691
1691
  Sr = { ...Sr, ...r };
1692
- }, Pn = () => Sr.cors, Gi = () => Sr.acceptsMap, Ue = (t) => new Promise((r, e) => {
1692
+ }, Dn = () => Sr.cors, Xi = () => Sr.acceptsMap, He = (t) => new Promise((r, e) => {
1693
1693
  const n = new Image();
1694
1694
  n.onload = () => {
1695
1695
  const o = n.width, c = n.height;
1696
1696
  r({ width: o, height: c });
1697
1697
  }, n.onerror = (o) => {
1698
1698
  e(o);
1699
- }, Pn().image && (n.crossOrigin = "anonymous"), n.src = t;
1700
- }), ms = (t) => new Promise((r, e) => {
1699
+ }, Dn().image && (n.crossOrigin = "anonymous"), n.src = t;
1700
+ }), gs = (t) => new Promise((r, e) => {
1701
1701
  const n = new Audio();
1702
1702
  n.preload = "auto", n.addEventListener("loadedmetadata", () => {
1703
1703
  const o = n.duration * 1e3;
1704
1704
  r({ duration: o });
1705
1705
  }), n.addEventListener("error", (o) => {
1706
1706
  e(o);
1707
- }), n.src = t, Pn().audio && (n.crossOrigin = "anonymous"), n.load();
1708
- }), Dn = (t) => new Promise((r, e) => {
1707
+ }), n.src = t, Dn().audio && (n.crossOrigin = "anonymous"), n.load();
1708
+ }), zn = (t) => new Promise((r, e) => {
1709
1709
  const n = document.createElement("video");
1710
1710
  n.preload = "auto", n.addEventListener("loadedmetadata", () => {
1711
1711
  const o = n.duration * 1e3, c = n.videoWidth, u = n.videoHeight;
1712
1712
  r({ duration: o, width: c, height: u });
1713
1713
  }), n.addEventListener("error", (o) => {
1714
1714
  e(o);
1715
- }), n.src = t, Pn().video && (n.crossOrigin = "anonymous"), n.load();
1716
- }), Xi = async (t) => {
1715
+ }), n.src = t, Dn().video && (n.crossOrigin = "anonymous"), n.load();
1716
+ }), Ki = async (t) => {
1717
1717
  var i, o;
1718
1718
  const r = t.duration, e = (i = t.details) == null ? void 0 : i.width, n = (o = t.details) == null ? void 0 : o.height;
1719
- return r && e && n ? { duration: r, width: e, height: n } : Dn(t.details.src);
1720
- }, gs = (t, r) => {
1719
+ return r && e && n ? { duration: r, width: e, height: n } : zn(t.details.src);
1720
+ }, ys = (t, r) => {
1721
1721
  const e = document.createElement("div");
1722
1722
  Object.keys(r).forEach((i) => {
1723
1723
  i !== "height" && (e.style[i] = r[i]);
1724
1724
  }), document.body.appendChild(e), e.textContent = t, e.style.whiteSpace = "normal", e.style.position = "absolute", e.style.visibility = "hidden", e.style.display = "inline-block", e.style.width = r.width + "px", e.style.fontSize = r.fontSize + "px";
1725
1725
  const n = getComputedStyle(e).height;
1726
1726
  return document.body.removeChild(e), parseFloat(n);
1727
- }, Kn = (t, r) => {
1727
+ }, Vn = (t, r) => {
1728
1728
  var u, d;
1729
1729
  const e = ((u = t.details.crop) == null ? void 0 : u.width) || t.details.width || 0, n = ((d = t.details.crop) == null ? void 0 : d.height) || t.details.height || 0;
1730
1730
  let i = r.width, o = r.height;
@@ -1739,39 +1739,39 @@ const Yi = (t) => {
1739
1739
  width: e
1740
1740
  }
1741
1741
  };
1742
- }, Vn = (t, r) => {
1742
+ }, qn = (t, r) => {
1743
1743
  const e = C(t.trim), n = C(t.display);
1744
- return r.duration < t.display.to && (n.to = r.duration, e && (e.to = r.duration)), {
1744
+ return r.duration < t.display.to && (n.to = r.duration + t.display.from, e && (e.to = r.duration)), {
1745
1745
  duration: r.duration,
1746
1746
  trim: e,
1747
1747
  display: n
1748
1748
  };
1749
1749
  };
1750
- async function Ki(t, r) {
1750
+ async function Vi(t, r) {
1751
1751
  const e = { ...t }, n = Object.keys(r)[0], i = Object.values(r)[0], o = e.trackItemsMap[n], c = { ...e.trackItemsMap[n] }, u = o.details;
1752
1752
  if (!i.details.src) return {};
1753
1753
  if (o.type === "image") {
1754
- const d = await Ue(i.details.src), { crop: p, newHeight: m, newWidth: y } = Kn(o, d);
1754
+ const d = await He(i.details.src), { crop: p, newHeight: m, newWidth: y } = Vn(o, d);
1755
1755
  i.details.crop = p, i.details.height = m, i.details.width = y;
1756
1756
  } else if (o.type === "video") {
1757
- const d = await Dn(i.details.src), p = e.trackItemsMap[n], { display: m, duration: y, trim: h } = Vn(p, d), { crop: k, newHeight: I, newWidth: b } = Kn(o, d);
1757
+ const d = await zn(i.details.src), p = e.trackItemsMap[n], { display: m, duration: y, trim: h } = qn(p, d), { crop: k, newHeight: I, newWidth: b } = Vn(o, d);
1758
1758
  i.details.crop = k, i.details.height = I, i.details.width = b, c.display = m, c.duration = y, c.trim = h;
1759
1759
  } else if (o.type === "audio") {
1760
- const d = await ms(i.details.src), p = e.trackItemsMap[n], { display: m, duration: y, trim: h } = Vn(p, d);
1760
+ const d = await gs(i.details.src), p = e.trackItemsMap[n], { display: m, duration: y, trim: h } = qn(p, d);
1761
1761
  c.display = m, c.duration = y, c.trim = h;
1762
1762
  }
1763
- return o.details = { ...u, ...i.details }, e.trackItemsMap[n] = { ...c }, {
1763
+ return o.metadata && i.metadata ? c.metadata = { ...o.metadata, ...i.metadata } : i.metadata && (c.metadata = i.metadata), o.details = { ...u, ...i.details }, e.trackItemsMap[n] = { ...c }, {
1764
1764
  trackItemsMap: {
1765
1765
  ...e.trackItemsMap,
1766
1766
  [n]: { ...c, details: { ...u, ...i.details } }
1767
1767
  }
1768
1768
  };
1769
1769
  }
1770
- function Vi(t, r) {
1770
+ function qi(t, r) {
1771
1771
  const e = C(t), n = {}, i = r && r.length ? r : e.activeIds;
1772
1772
  if (i.length === 0) return {};
1773
1773
  i.forEach((c) => {
1774
- const u = e.trackItemsMap[c], d = Ie();
1774
+ const u = e.trackItemsMap[c], d = ye();
1775
1775
  e.trackItemsMap[d] = {
1776
1776
  ...C(u),
1777
1777
  id: d
@@ -1781,7 +1781,7 @@ function Vi(t, r) {
1781
1781
  );
1782
1782
  n[p.id] ? n[p.id].items.push(d) : n[p.id] = {
1783
1783
  ...p,
1784
- id: Ie(),
1784
+ id: ye(),
1785
1785
  items: [d],
1786
1786
  static: !1,
1787
1787
  magnetic: !1
@@ -1794,7 +1794,7 @@ function Vi(t, r) {
1794
1794
  trackItemIds: e.trackItemIds
1795
1795
  };
1796
1796
  }
1797
- function qi(t) {
1797
+ function Ji(t) {
1798
1798
  const r = /#([0-9a-fA-F]{3,6})\b/g, e = /rgb\(\s*(\d+),\s*(\d+),\s*(\d+)\s*\)/g, n = /rgba\(\s*(\d+),\s*(\d+),\s*(\d+),\s*([0-9.]+)\s*\)/g;
1799
1799
  function i(c) {
1800
1800
  return c.length === 3 ? `#${c[0]}${c[0]}${c[1]}${c[1]}${c[2]}${c[2]}`.toUpperCase() : `#${c.toUpperCase()}`;
@@ -1813,7 +1813,7 @@ function qi(t) {
1813
1813
  function V(t) {
1814
1814
  return /^#[0-9a-fA-F]{3}$/.test(t) ? "#" + t[1] + t[1] + t[2] + t[2] + t[3] + t[3] : t;
1815
1815
  }
1816
- function ys(t, r) {
1816
+ function Is(t, r) {
1817
1817
  let e = t;
1818
1818
  for (const n in r)
1819
1819
  if (Object.prototype.hasOwnProperty.call(r, n)) {
@@ -1822,7 +1822,7 @@ function ys(t, r) {
1822
1822
  }
1823
1823
  return e;
1824
1824
  }
1825
- function Is(t) {
1825
+ function bs(t) {
1826
1826
  const r = t.getAttribute("fill");
1827
1827
  if (r && r.trim() !== "" && r.trim() !== "none")
1828
1828
  return r.trim();
@@ -1836,12 +1836,12 @@ function Is(t) {
1836
1836
  }
1837
1837
  }
1838
1838
  const n = t.parentElement;
1839
- return n ? Is(n) : null;
1839
+ return n ? bs(n) : null;
1840
1840
  }
1841
1841
  function qe(t) {
1842
1842
  return /^#([0-9A-Fa-f]{3}|[0-9A-Fa-f]{6})$/.test(t);
1843
1843
  }
1844
- const Ji = (t) => {
1844
+ const Zi = (t) => {
1845
1845
  const r = `.${t.split(".").filter((o) => o.includes("fill:")).join(".")}`, e = {}, n = /\.([\w-]+)\s*\{\s*([^}]+)\s*\}/g;
1846
1846
  let i;
1847
1847
  for (; (i = n.exec(r)) !== null; ) {
@@ -1859,12 +1859,12 @@ function hn(t) {
1859
1859
  }
1860
1860
  return !1;
1861
1861
  }
1862
- function Zi(t, r, e = 300, n = 300) {
1862
+ function Qi(t, r, e = 300, n = 300) {
1863
1863
  const i = [], c = new DOMParser().parseFromString(t, "image/svg+xml"), u = c.documentElement;
1864
1864
  u.setAttribute("width", `${e}`), u.setAttribute("height", `${n}`);
1865
1865
  const d = u.querySelectorAll("style"), p = {};
1866
1866
  d.forEach((b) => {
1867
- const _ = b.textContent || "", f = Ji(_);
1867
+ const _ = b.textContent || "", f = Zi(_);
1868
1868
  Object.assign(p, f);
1869
1869
  const v = _.replace(/\.(st[\w-]+)/g, `.${r}-$1`).replace(/url\(#(.*?)\)/g, `url(#${r}-$1)`);
1870
1870
  b.textContent = v;
@@ -1872,18 +1872,18 @@ function Zi(t, r, e = 300, n = 300) {
1872
1872
  T.forEach((A) => {
1873
1873
  if (hn(A)) return;
1874
1874
  ["fill", "stroke", "stop-color"].forEach((L) => {
1875
- const R = A.getAttribute(L);
1876
- R && !["none", "transparent"].includes(R) && w.add(V(R));
1875
+ const P = A.getAttribute(L);
1876
+ P && !["none", "transparent"].includes(P) && w.add(V(P));
1877
1877
  });
1878
1878
  const S = A.getAttribute("style");
1879
1879
  if (S) {
1880
- const L = /fill\s*:\s*([^;]+);?/.exec(S), R = /stroke\s*:\s*([^;]+);?/.exec(S), Y = /stop-color\s*:\s*([^;]+);?/.exec(S);
1880
+ const L = /fill\s*:\s*([^;]+);?/.exec(S), P = /stroke\s*:\s*([^;]+);?/.exec(S), Y = /stop-color\s*:\s*([^;]+);?/.exec(S);
1881
1881
  if (L) {
1882
1882
  const x = L[1].trim();
1883
1883
  x && !["none", "transparent"].includes(x) && qe(V(x)) && w.add(V(x));
1884
1884
  }
1885
- if (R) {
1886
- const x = R[1].trim();
1885
+ if (P) {
1886
+ const x = P[1].trim();
1887
1887
  x && !["none", "transparent"].includes(x) && qe(V(x)) && w.add(V(x));
1888
1888
  }
1889
1889
  if (Y) {
@@ -1893,8 +1893,8 @@ function Zi(t, r, e = 300, n = 300) {
1893
1893
  }
1894
1894
  const E = A.getAttribute("class");
1895
1895
  E && E.split(" ").forEach((L) => {
1896
- const R = p[L];
1897
- R != null && R.fill && !["none", "transparent"].includes(R.fill) && w.add(V(R.fill)), R != null && R.stroke && !["none", "transparent"].includes(R.stroke) && w.add(V(R.stroke));
1896
+ const P = p[L];
1897
+ P != null && P.fill && !["none", "transparent"].includes(P.fill) && w.add(V(P.fill)), P != null && P.stroke && !["none", "transparent"].includes(P.stroke) && w.add(V(P.stroke));
1898
1898
  });
1899
1899
  }), Array.from(w).forEach((A) => {
1900
1900
  qe(A) && i.push(A);
@@ -1955,7 +1955,7 @@ function Zi(t, r, e = 300, n = 300) {
1955
1955
  }
1956
1956
  }), Array.from(c.querySelectorAll("path")).forEach((b) => {
1957
1957
  if (hn(b)) return;
1958
- !Is(b) && !b.getAttribute("class") && (b.setAttribute("fill", "#000000"), i.includes("#000000") || i.push("#000000"));
1958
+ !bs(b) && !b.getAttribute("class") && (b.setAttribute("fill", "#000000"), i.includes("#000000") || i.push("#000000"));
1959
1959
  }), { serializer: new XMLSerializer().serializeToString(c), colors: i };
1960
1960
  }
1961
1961
  const nr = {
@@ -1963,7 +1963,7 @@ const nr = {
1963
1963
  x: 0,
1964
1964
  y: 0,
1965
1965
  blur: 0
1966
- }, pt = (t, r) => {
1966
+ }, ft = (t, r) => {
1967
1967
  let e = r != null && r.trim ? r.trim.to - r.trim.from : (r == null ? void 0 : r.duration) || 5e3;
1968
1968
  const n = {
1969
1969
  from: 0,
@@ -1991,14 +1991,14 @@ const nr = {
1991
1991
  ), n;
1992
1992
  }
1993
1993
  return t;
1994
- }, bs = (t, r) => t ? t.from && !t.to ? {
1994
+ }, ks = (t, r) => t ? t.from && !t.to ? {
1995
1995
  from: t.from,
1996
1996
  to: r.duration
1997
1997
  } : t : {
1998
1998
  from: 0,
1999
1999
  to: r.duration
2000
2000
  };
2001
- function ks(t, r) {
2001
+ function vs(t, r) {
2002
2002
  const e = {
2003
2003
  x: t.size.width / 2,
2004
2004
  y: t.size.height / 2
@@ -2010,7 +2010,7 @@ function ks(t, r) {
2010
2010
  // No scaling for text/captions
2011
2011
  };
2012
2012
  }
2013
- function ht(t, r) {
2013
+ function pt(t, r) {
2014
2014
  const e = t.scaleMode, n = {
2015
2015
  x: t.size.width / 2,
2016
2016
  y: t.size.height / 2
@@ -2039,10 +2039,10 @@ function ht(t, r) {
2039
2039
  transform: `scale(${o})`
2040
2040
  };
2041
2041
  }
2042
- const vs = async (t, r) => {
2043
- const e = t.details.src, n = await Xi(t), i = ht(r, {
2042
+ const _s = async (t, r) => {
2043
+ const e = t.details.src, n = await Ki(t), i = pt(r, {
2044
2044
  ...n
2045
- }), o = bs(t.trim, { duration: n.duration }), c = {
2045
+ }), o = ks(t.trim, { duration: n.duration }), c = {
2046
2046
  width: n.width,
2047
2047
  height: n.height,
2048
2048
  opacity: 100,
@@ -2076,16 +2076,16 @@ const vs = async (t, r) => {
2076
2076
  name: "video",
2077
2077
  details: c,
2078
2078
  playbackRate: t.playbackRate || 1,
2079
- display: pt(t.display, { duration: n.duration, trim: o }),
2079
+ display: ft(t.display, { duration: n.duration, trim: o }),
2080
2080
  duration: n.duration
2081
2081
  };
2082
- }, _s = async (t) => {
2083
- const r = t.id, e = t.details, i = (await ms(e.src)).duration, o = bs(t.trim, { duration: i });
2082
+ }, Ss = async (t) => {
2083
+ const r = t.id, e = t.details, i = (await gs(e.src)).duration, o = ks(t.trim, { duration: i });
2084
2084
  return {
2085
2085
  id: r,
2086
2086
  name: t.name || "audio",
2087
2087
  type: "audio",
2088
- display: pt(t.display, { duration: i, trim: o }),
2088
+ display: ft(t.display, { duration: i, trim: o }),
2089
2089
  trim: o,
2090
2090
  playbackRate: t.playbackRate || 1,
2091
2091
  details: {
@@ -2096,12 +2096,12 @@ const vs = async (t, r) => {
2096
2096
  metadata: { ...t.metadata },
2097
2097
  duration: i
2098
2098
  };
2099
- }, Qi = async (t, r) => {
2099
+ }, ta = async (t, r) => {
2100
2100
  var u, d;
2101
2101
  const e = t.id, n = {
2102
2102
  width: ((u = t.details) == null ? void 0 : u.width) || r.size.width,
2103
2103
  height: ((d = t.details) == null ? void 0 : d.height) || r.size.height
2104
- }, i = t.details, o = ht(r, n), c = pt(t.display);
2104
+ }, i = t.details, o = pt(r, n), c = ft(t.display);
2105
2105
  return {
2106
2106
  id: e,
2107
2107
  name: t.type,
@@ -2134,12 +2134,12 @@ const vs = async (t, r) => {
2134
2134
  },
2135
2135
  metadata: {}
2136
2136
  };
2137
- }, ta = async (t, r) => {
2137
+ }, ea = async (t, r) => {
2138
2138
  var u, d;
2139
2139
  const e = t.id, n = {
2140
2140
  width: ((u = t.details) == null ? void 0 : u.width) || r.size.width,
2141
2141
  height: ((d = t.details) == null ? void 0 : d.height) || r.size.height
2142
- }, i = t.details, o = ht(r, n), c = pt(t.display);
2142
+ }, i = t.details, o = pt(r, n), c = ft(t.display);
2143
2143
  return {
2144
2144
  id: e,
2145
2145
  name: t.type,
@@ -2173,12 +2173,12 @@ const vs = async (t, r) => {
2173
2173
  },
2174
2174
  metadata: {}
2175
2175
  };
2176
- }, ea = async (t, r) => {
2176
+ }, ra = async (t, r) => {
2177
2177
  var u, d;
2178
2178
  const e = t.id, n = {
2179
2179
  width: ((u = t.details) == null ? void 0 : u.width) || r.size.width,
2180
2180
  height: ((d = t.details) == null ? void 0 : d.height) || r.size.height
2181
- }, i = t.details, o = ht(r, n), c = pt(t.display);
2181
+ }, i = t.details, o = pt(r, n), c = ft(t.display);
2182
2182
  return {
2183
2183
  id: e,
2184
2184
  name: t.type,
@@ -2207,12 +2207,12 @@ const vs = async (t, r) => {
2207
2207
  },
2208
2208
  metadata: {}
2209
2209
  };
2210
- }, ra = async (t, r) => {
2210
+ }, na = async (t, r) => {
2211
2211
  var u, d;
2212
2212
  const e = t.id, n = {
2213
2213
  width: ((u = t.details) == null ? void 0 : u.width) || r.size.width,
2214
2214
  height: ((d = t.details) == null ? void 0 : d.height) || r.size.height
2215
- }, i = t.details, o = ht(r, n), c = pt(t.display);
2215
+ }, i = t.details, o = pt(r, n), c = ft(t.display);
2216
2216
  return {
2217
2217
  id: e,
2218
2218
  name: t.type,
@@ -2250,7 +2250,7 @@ const vs = async (t, r) => {
2250
2250
  const e = t.id, n = {
2251
2251
  width: ((c = t.details) == null ? void 0 : c.width) || r.size.width,
2252
2252
  height: ((u = t.details) == null ? void 0 : u.height) || r.size.height
2253
- }, i = t.details, o = ht(r, n);
2253
+ }, i = t.details, o = pt(r, n);
2254
2254
  return {
2255
2255
  id: e,
2256
2256
  name: t.type,
@@ -2298,7 +2298,7 @@ const vs = async (t, r) => {
2298
2298
  },
2299
2299
  metadata: {}
2300
2300
  };
2301
- }, Ss = async (t, r) => {
2301
+ }, ws = async (t, r) => {
2302
2302
  var y;
2303
2303
  const e = t.trackItemIds, n = t.size || {
2304
2304
  width: t.details.width,
@@ -2306,7 +2306,7 @@ const vs = async (t, r) => {
2306
2306
  }, i = Math.min(
2307
2307
  r.size.width / n.width,
2308
2308
  r.size.height / n.height
2309
- ), o = ((y = t.details) == null ? void 0 : y.rotate) || 0, c = ht(r, n), u = t.display;
2309
+ ), o = ((y = t.details) == null ? void 0 : y.rotate) || 0, c = pt(r, n), u = t.display;
2310
2310
  let d = 1 / 0, p = 0;
2311
2311
  e.forEach((h) => {
2312
2312
  const k = t.trackItemsMap[h];
@@ -2330,7 +2330,7 @@ const vs = async (t, r) => {
2330
2330
  display: u || { from: d, to: p },
2331
2331
  activeEdit: !1
2332
2332
  };
2333
- }, na = async (t, r) => {
2333
+ }, sa = async (t, r) => {
2334
2334
  var m;
2335
2335
  const e = t.trackItemIds, n = t.size || {
2336
2336
  width: t.details.width,
@@ -2338,7 +2338,7 @@ const vs = async (t, r) => {
2338
2338
  }, i = Math.min(
2339
2339
  r.size.width / n.width,
2340
2340
  r.size.height / n.height
2341
- ), o = ((m = t.details) == null ? void 0 : m.rotate) || 0, c = ht(r, n), u = t.display;
2341
+ ), o = ((m = t.details) == null ? void 0 : m.rotate) || 0, c = pt(r, n), u = t.display;
2342
2342
  let d = 1 / 0, p = 0;
2343
2343
  return e.forEach((y) => {
2344
2344
  const h = t.trackItemsMap[y];
@@ -2357,12 +2357,12 @@ const vs = async (t, r) => {
2357
2357
  },
2358
2358
  display: u || { from: d, to: p }
2359
2359
  };
2360
- }, ws = async (t, r) => {
2361
- const e = t.details, n = Ue(e.src), i = fetch(e.src), [o, c] = await Promise.all([
2360
+ }, Ts = async (t, r) => {
2361
+ const e = t.details, n = He(e.src), i = fetch(e.src), [o, c] = await Promise.all([
2362
2362
  n,
2363
2363
  i
2364
- ]), u = await c.text(), d = ht(r, o), { serializer: p, colors: m } = Zi(
2365
- qi(u),
2364
+ ]), u = await c.text(), d = pt(r, o), { serializer: p, colors: m } = Qi(
2365
+ Ji(u),
2366
2366
  t.id,
2367
2367
  Number(e.width || o.width),
2368
2368
  Number(e.height || o.height)
@@ -2371,7 +2371,7 @@ const vs = async (t, r) => {
2371
2371
  id: t.id,
2372
2372
  name: "illustration",
2373
2373
  type: t.type,
2374
- display: pt(t.display),
2374
+ display: ft(t.display),
2375
2375
  playbackRate: t.playbackRate || 1,
2376
2376
  details: {
2377
2377
  src: e.src || "",
@@ -2406,13 +2406,13 @@ const vs = async (t, r) => {
2406
2406
  },
2407
2407
  metadata: t.metadata || {}
2408
2408
  };
2409
- }, sa = async (t, r) => {
2410
- const e = t.details, n = Ue(e.src), [i] = await Promise.all([n]), o = ht(r, i);
2409
+ }, ia = async (t, r) => {
2410
+ const e = t.details, n = He(e.src), [i] = await Promise.all([n]), o = pt(r, i);
2411
2411
  return {
2412
2412
  id: t.id,
2413
2413
  name: "shape",
2414
2414
  type: t.type,
2415
- display: pt(t.display),
2415
+ display: ft(t.display),
2416
2416
  playbackRate: t.playbackRate || 1,
2417
2417
  details: {
2418
2418
  src: e.src || "",
@@ -2445,8 +2445,8 @@ const vs = async (t, r) => {
2445
2445
  },
2446
2446
  metadata: t.metadata || {}
2447
2447
  };
2448
- }, ia = async (t, r) => {
2449
- const e = t.details, n = ht(r, {
2448
+ }, aa = async (t, r) => {
2449
+ const e = t.details, n = pt(r, {
2450
2450
  width: e.width,
2451
2451
  height: e.height
2452
2452
  });
@@ -2454,7 +2454,7 @@ const vs = async (t, r) => {
2454
2454
  id: t.id,
2455
2455
  name: "rect",
2456
2456
  type: t.type,
2457
- display: pt(t.display),
2457
+ display: ft(t.display),
2458
2458
  playbackRate: t.playbackRate || 1,
2459
2459
  details: {
2460
2460
  width: e.width || 100,
@@ -2489,13 +2489,13 @@ const vs = async (t, r) => {
2489
2489
  },
2490
2490
  metadata: t.metadata || {}
2491
2491
  };
2492
- }, Ts = async (t, r) => {
2493
- const e = t.details, n = await Ue(e.src), i = ht(r, n);
2492
+ }, Es = async (t, r) => {
2493
+ const e = t.details, n = await He(e.src), i = pt(r, n);
2494
2494
  return {
2495
2495
  id: t.id,
2496
2496
  type: "image",
2497
2497
  name: "image",
2498
- display: pt(t.display),
2498
+ display: ft(t.display),
2499
2499
  playbackRate: t.playbackRate || 1,
2500
2500
  details: {
2501
2501
  src: e.src || "",
@@ -2531,18 +2531,18 @@ const vs = async (t, r) => {
2531
2531
  },
2532
2532
  metadata: t.metadata || {}
2533
2533
  };
2534
- }, Es = async (t, r) => {
2534
+ }, As = async (t, r) => {
2535
2535
  const e = t;
2536
- e.details.fontUrl && await He([
2536
+ e.details.fontUrl && await Le([
2537
2537
  {
2538
2538
  fontFamily: e.details.fontFamily,
2539
2539
  url: e.details.fontUrl
2540
2540
  }
2541
2541
  ]);
2542
- const n = e.id, i = e.details, o = Ms(i), c = i.height || gs(e.details.text, o), u = i.top != null && i.left != null ? {
2542
+ const n = e.id, i = e.details, o = xs(i), c = i.height || ys(e.details.text, o), u = i.top != null && i.left != null ? {
2543
2543
  top: `${i.top}px`,
2544
2544
  left: `${i.left}px`
2545
- } : ks(r, {
2545
+ } : vs(r, {
2546
2546
  width: o.width,
2547
2547
  height: c
2548
2548
  });
@@ -2550,7 +2550,7 @@ const vs = async (t, r) => {
2550
2550
  id: n,
2551
2551
  name: "caption",
2552
2552
  type: "caption",
2553
- display: pt(e.display),
2553
+ display: ft(e.display),
2554
2554
  details: {
2555
2555
  ...e.details,
2556
2556
  ...o,
@@ -2567,21 +2567,25 @@ const vs = async (t, r) => {
2567
2567
  words: i.words || [],
2568
2568
  appearedColor: i.appearedColor || i.color,
2569
2569
  activeColor: i.activeColor || i.color,
2570
- activeFillColor: i.activeFillColor || "transparent"
2570
+ activeFillColor: i.activeFillColor || "transparent",
2571
+ isKeywordColor: i.isKeywordColor || "transparent",
2572
+ preservedColorKeyWord: i.preservedColorKeyWord || !1,
2573
+ linesPerCaption: i.linesPerCaption || 2,
2574
+ wordsPerLine: i.wordsPerLine || "punctuationOrPause"
2571
2575
  },
2572
2576
  metadata: t.metadata || {}
2573
2577
  };
2574
- }, As = async (t, r) => {
2575
- t.details.fontUrl && await He([
2578
+ }, Ms = async (t, r) => {
2579
+ t.details.fontUrl && await Le([
2576
2580
  {
2577
2581
  fontFamily: t.details.fontFamily,
2578
2582
  url: t.details.fontUrl
2579
2583
  }
2580
2584
  ]);
2581
- const e = t.id, n = t.details, i = Ms(n), o = n.height || gs(t.details.text, i), c = n.top != null && n.left != null ? {
2585
+ const e = t.id, n = t.details, i = xs(n), o = n.height || ys(t.details.text, i), c = n.top != null && n.left != null ? {
2582
2586
  top: `${n.top}px`,
2583
2587
  left: `${n.left}px`
2584
- } : ks(r, {
2588
+ } : vs(r, {
2585
2589
  width: i.width,
2586
2590
  height: o
2587
2591
  });
@@ -2589,7 +2593,7 @@ const vs = async (t, r) => {
2589
2593
  id: e,
2590
2594
  name: "text",
2591
2595
  type: "text",
2592
- display: pt(t.display),
2596
+ display: ft(t.display),
2593
2597
  details: {
2594
2598
  ...t.details,
2595
2599
  ...i,
@@ -2606,7 +2610,7 @@ const vs = async (t, r) => {
2606
2610
  },
2607
2611
  metadata: {}
2608
2612
  };
2609
- }, Ms = (t) => ({
2613
+ }, xs = (t) => ({
2610
2614
  fontFamily: t.fontFamily || "Arial",
2611
2615
  // Default font family
2612
2616
  fontSize: t.fontSize || "16px",
@@ -2650,33 +2654,33 @@ const vs = async (t, r) => {
2650
2654
  transform: t.transform || "none",
2651
2655
  skewX: t.skewX || 0,
2652
2656
  skewY: t.skewY || 0
2653
- }), aa = async (t, r) => {
2657
+ }), oa = async (t, r) => {
2654
2658
  switch (t.type) {
2655
2659
  case "video":
2656
- return vs(t, r || {});
2660
+ return _s(t, r || {});
2657
2661
  case "audio":
2658
- return _s(t);
2662
+ return Ss(t);
2659
2663
  case "image":
2660
- return Ts(t, r || {});
2664
+ return Es(t, r || {});
2661
2665
  case "text":
2662
- return As(t, r || {});
2666
+ return Ms(t, r || {});
2663
2667
  case "caption":
2664
- return Es(t, r || {});
2668
+ return As(t, r || {});
2665
2669
  case "template":
2666
- return Ss(t, {
2670
+ return ws(t, {
2667
2671
  size: r == null ? void 0 : r.size
2668
2672
  });
2669
2673
  default:
2670
2674
  throw new Error("Unsupported track item");
2671
2675
  }
2672
2676
  };
2673
- function xs(t, r) {
2677
+ function Os(t, r) {
2674
2678
  return r.some(
2675
2679
  (e) => t.some((n) => n.id === e.id)
2676
2680
  );
2677
2681
  }
2678
- const Os = (t = [], r = []) => t.length === 0 ? r.map((n) => ({
2679
- id: Ie(),
2682
+ const Cs = (t = [], r = []) => t.length === 0 ? r.map((n) => ({
2683
+ id: ye(),
2680
2684
  items: [n.id],
2681
2685
  type: n.type,
2682
2686
  accepts: ["text", "image", "video", "audio", "caption", "template"]
@@ -2687,9 +2691,9 @@ const Os = (t = [], r = []) => t.length === 0 ? r.map((n) => ({
2687
2691
  type: e.type || "text",
2688
2692
  magnetic: e.magnetic || !1,
2689
2693
  static: e.static || !1,
2690
- id: e.id || Ie()
2694
+ id: e.id || ye()
2691
2695
  }));
2692
- async function oa(t, r) {
2696
+ async function ca(t, r) {
2693
2697
  var c, u, d;
2694
2698
  const e = r.trackItemsMap, n = /* @__PURE__ */ new Set(), i = /* @__PURE__ */ new Map();
2695
2699
  for (const p in e) {
@@ -2735,16 +2739,16 @@ async function oa(t, r) {
2735
2739
  details: m.details
2736
2740
  });
2737
2741
  }
2738
- n.size > 0 && await He(
2742
+ n.size > 0 && await Le(
2739
2743
  Array.from(n).map((p) => JSON.parse(p))
2740
2744
  );
2741
2745
  for (const [p, m] of i) {
2742
- const y = await ws(
2746
+ const y = await Ts(
2743
2747
  { ...m.trackItem, details: m.details },
2744
2748
  {
2745
2749
  size: { width: m.details.width, height: m.details.height }
2746
2750
  }
2747
- ), h = ys(
2751
+ ), h = Is(
2748
2752
  y.details.svgString,
2749
2753
  m.details.colorMap
2750
2754
  );
@@ -2756,7 +2760,7 @@ async function oa(t, r) {
2756
2760
  duration: o
2757
2761
  };
2758
2762
  }
2759
- function ca(t) {
2763
+ function ua(t) {
2760
2764
  const r = C(t);
2761
2765
  if (!r.activeIds.length) return;
2762
2766
  const e = r.activeIds, n = [], i = {
@@ -2782,13 +2786,13 @@ function ca(t) {
2782
2786
  let u = JSON.stringify(i);
2783
2787
  localStorage.setItem("DesignComboTemp", u);
2784
2788
  }
2785
- function ua(t, r) {
2789
+ function la(t, r) {
2786
2790
  const e = C(t);
2787
2791
  if (e.activeIds.length !== 1) return {};
2788
2792
  const n = e.activeIds[0], i = C(e.trackItemsMap[n]);
2789
2793
  if (r >= i.display.to || r <= i.display.from)
2790
2794
  return {};
2791
- const o = Ie(), c = {
2795
+ const o = ye(), c = {
2792
2796
  ...i,
2793
2797
  display: {
2794
2798
  from: i.display.from,
@@ -2856,7 +2860,7 @@ function ua(t, r) {
2856
2860
  transitionIds: e.transitionIds
2857
2861
  };
2858
2862
  }
2859
- async function la(t, r) {
2863
+ async function da(t, r) {
2860
2864
  const n = C(t).trackItemsMap, i = Object.keys(r);
2861
2865
  if (!i.length) return {};
2862
2866
  for (const c of i) {
@@ -2865,7 +2869,7 @@ async function la(t, r) {
2865
2869
  ...n[c].details,
2866
2870
  ...u.details
2867
2871
  }, u.details.colorMap)) {
2868
- const d = n[c].details.initialSvgString, p = ys(
2872
+ const d = n[c].details.initialSvgString, p = Is(
2869
2873
  d,
2870
2874
  u.details.colorMap
2871
2875
  );
@@ -2889,7 +2893,7 @@ async function la(t, r) {
2889
2893
  for (const c of i) {
2890
2894
  const u = r[c];
2891
2895
  if (n[c].type === "shape" && u.details.src) {
2892
- const d = await Ue(u.details.src);
2896
+ const d = await He(u.details.src);
2893
2897
  n[c].details.width = d.width, n[c].details.height = d.height;
2894
2898
  }
2895
2899
  }
@@ -2899,11 +2903,11 @@ async function la(t, r) {
2899
2903
  duration: o
2900
2904
  };
2901
2905
  }
2902
- async function da(t, r) {
2906
+ async function fa(t, r) {
2903
2907
  const e = C(t), n = Object.keys(r)[0], i = Object.values(r)[0], o = e.trackItemsMap[n], c = o.details;
2904
2908
  if (!i.details.src) return {};
2905
2909
  if (o.type === "image") {
2906
- const u = await Ue(i.details.src), d = o.details.width || 0, p = o.details.height || 0;
2910
+ const u = await He(i.details.src), d = o.details.width || 0, p = o.details.height || 0;
2907
2911
  let m = u.width, y = u.height;
2908
2912
  const h = u.width / u.height;
2909
2913
  d / p > h ? (m = d, y = d / h) : (y = p, m = p * h), c.crop = {
@@ -2913,7 +2917,7 @@ async function da(t, r) {
2913
2917
  width: c.width
2914
2918
  }, i.details.width = m, i.details.height = y;
2915
2919
  } else if (o.type === "video") {
2916
- const u = await Dn(i.details.src), d = o.details.width || 0, p = o.details.height || 0;
2920
+ const u = await zn(i.details.src), d = o.details.width || 0, p = o.details.height || 0;
2917
2921
  let m = u.width, y = u.height;
2918
2922
  const h = u.width / u.height;
2919
2923
  d / p > h ? (m = d, y = d / h) : (y = p, m = p * h), c.crop = {
@@ -2932,13 +2936,13 @@ async function da(t, r) {
2932
2936
  }
2933
2937
  };
2934
2938
  }
2935
- function fa(t, r) {
2939
+ function pa(t, r) {
2936
2940
  const e = C(t);
2937
2941
  return e.background.value = r.value, e.background.type = r.type || "color", {
2938
2942
  ...e
2939
2943
  };
2940
2944
  }
2941
- function pa(t, { idTrack: r, idItems: e }, n) {
2945
+ function ha(t, { idTrack: r, idItems: e }, n) {
2942
2946
  const i = n.tracks.find((c) => c.id === r);
2943
2947
  if (!i) return;
2944
2948
  const o = i.items.reduce((c, u) => {
@@ -2952,21 +2956,21 @@ function pa(t, { idTrack: r, idItems: e }, n) {
2952
2956
  u.display.from = o.display.to, u.display.to = u.display.from + d;
2953
2957
  });
2954
2958
  }
2955
- async function ha(t, r, e = {}) {
2959
+ async function ma(t, r, e = {}) {
2956
2960
  var k;
2957
2961
  const n = C(t), i = r.trackItems.map(
2958
- (I) => aa(I, {
2962
+ (I) => oa(I, {
2959
2963
  size: n.size
2960
2964
  })
2961
2965
  ), o = await Promise.all(i);
2962
2966
  (k = r.tracks) == null || k.forEach((I) => {
2963
- pa(
2967
+ ha(
2964
2968
  o,
2965
2969
  { idTrack: I.id, idItems: I.items },
2966
2970
  n
2967
2971
  );
2968
2972
  });
2969
- const c = Os(r.tracks, r.trackItems), u = [], d = o.map((I) => I.id);
2973
+ const c = Cs(r.tracks, r.trackItems), u = [], d = o.map((I) => I.id);
2970
2974
  r.trackItems.forEach((I) => {
2971
2975
  if (I.type !== "template") return;
2972
2976
  n.trackItemsMap = {
@@ -2987,7 +2991,7 @@ async function ha(t, r, e = {}) {
2987
2991
  const p = [], m = {};
2988
2992
  if (o.forEach((I) => {
2989
2993
  p.push(I.id), m[I.id] = I;
2990
- }), xs(
2994
+ }), Os(
2991
2995
  n.tracks,
2992
2996
  c
2993
2997
  ))
@@ -3025,7 +3029,7 @@ async function ha(t, r, e = {}) {
3025
3029
  transitionsMap: n.transitionsMap
3026
3030
  };
3027
3031
  }
3028
- function St(t, r, e = {
3032
+ function _t(t, r, e = {
3029
3033
  isNewTrack: !0
3030
3034
  }) {
3031
3035
  const n = r.map((c) => c.id), i = [], o = {};
@@ -3039,8 +3043,8 @@ function St(t, r, e = {
3039
3043
  d.items.push(...i);
3040
3044
  } else {
3041
3045
  const c = {
3042
- id: ps(),
3043
- accepts: Object.keys(Gi()),
3046
+ id: hs(),
3047
+ accepts: Object.keys(Xi()),
3044
3048
  type: r[0].type,
3045
3049
  items: n,
3046
3050
  magnetic: !1,
@@ -3056,14 +3060,14 @@ function St(t, r, e = {
3056
3060
  ...i
3057
3061
  ], t;
3058
3062
  }
3059
- async function ma(t, r, e = {}) {
3063
+ async function ga(t, r, e = {}) {
3060
3064
  const n = C(t), i = [
3061
- Ts(r, {
3065
+ Es(r, {
3062
3066
  size: n.size,
3063
3067
  scaleMode: e.scaleMode,
3064
3068
  scaleAspectRatio: e.scaleAspectRatio
3065
3069
  })
3066
- ], o = await Promise.all(i), c = o.map((p) => p.id), u = St(n, o, e), d = u.tracks.filter((p) => p.magnetic);
3070
+ ], o = await Promise.all(i), c = o.map((p) => p.id), u = _t(n, o, e), d = u.tracks.filter((p) => p.magnetic);
3067
3071
  return nt(d, u.trackItemsMap, c), u.duration = G(u.trackItemsMap), {
3068
3072
  trackItemIds: u.trackItemIds,
3069
3073
  trackItemsMap: u.trackItemsMap,
@@ -3071,8 +3075,8 @@ async function ma(t, r, e = {}) {
3071
3075
  duration: u.duration
3072
3076
  };
3073
3077
  }
3074
- async function ga(t, r, e = {}) {
3075
- const n = C(t), i = [_s(r)], o = await Promise.all(i), c = o.map((p) => p.id), u = St(n, o, e);
3078
+ async function ya(t, r, e = {}) {
3079
+ const n = C(t), i = [Ss(r)], o = await Promise.all(i), c = o.map((p) => p.id), u = _t(n, o, e);
3076
3080
  u.duration = G(u.trackItemsMap);
3077
3081
  const d = u.tracks.filter((p) => p.magnetic);
3078
3082
  return nt(d, u.trackItemsMap, c), {
@@ -3082,14 +3086,14 @@ async function ga(t, r, e = {}) {
3082
3086
  duration: u.duration
3083
3087
  };
3084
3088
  }
3085
- async function ya(t, r, e = {}) {
3089
+ async function Ia(t, r, e = {}) {
3086
3090
  const n = C(t), i = [
3087
- vs(r, {
3091
+ _s(r, {
3088
3092
  size: n.size,
3089
3093
  scaleMode: e.scaleMode,
3090
3094
  scaleAspectRatio: e.scaleAspectRatio
3091
3095
  })
3092
- ], o = await Promise.all(i), c = o.map((p) => p.id), u = St(n, o, e);
3096
+ ], o = await Promise.all(i), c = o.map((p) => p.id), u = _t(n, o, e);
3093
3097
  u.duration = G(u.trackItemsMap);
3094
3098
  const d = u.tracks.filter((p) => p.magnetic);
3095
3099
  return nt(d, u.trackItemsMap, c), {
@@ -3099,12 +3103,12 @@ async function ya(t, r, e = {}) {
3099
3103
  duration: u.duration
3100
3104
  };
3101
3105
  }
3102
- async function Ia(t, r, e = {}) {
3106
+ async function ba(t, r, e = {}) {
3103
3107
  const n = C(t), i = [
3104
- As(r, {
3108
+ Ms(r, {
3105
3109
  size: e.size
3106
3110
  })
3107
- ], o = await Promise.all(i), c = o.map((p) => p.id), u = St(n, o, e);
3111
+ ], o = await Promise.all(i), c = o.map((p) => p.id), u = _t(n, o, e);
3108
3112
  u.duration = G(u.trackItemsMap);
3109
3113
  const d = u.tracks.filter((p) => p.magnetic);
3110
3114
  return nt(d, u.trackItemsMap, c), {
@@ -3114,14 +3118,14 @@ async function Ia(t, r, e = {}) {
3114
3118
  duration: u.duration
3115
3119
  };
3116
3120
  }
3117
- async function ba(t, r, e = {}) {
3121
+ async function ka(t, r, e = {}) {
3118
3122
  const n = C(t), i = [
3119
- sa(r, {
3123
+ ia(r, {
3120
3124
  size: n.size,
3121
3125
  scaleMode: e.scaleMode,
3122
3126
  scaleAspectRatio: e.scaleAspectRatio
3123
3127
  })
3124
- ], o = await Promise.all(i), c = o.map((p) => p.id), u = St(n, o, e);
3128
+ ], o = await Promise.all(i), c = o.map((p) => p.id), u = _t(n, o, e);
3125
3129
  u.duration = G(u.trackItemsMap);
3126
3130
  const d = u.tracks.filter((p) => p.magnetic);
3127
3131
  return nt(d, u.trackItemsMap, c), {
@@ -3131,14 +3135,14 @@ async function ba(t, r, e = {}) {
3131
3135
  duration: u.duration
3132
3136
  };
3133
3137
  }
3134
- async function ka(t, r, e = {}) {
3138
+ async function va(t, r, e = {}) {
3135
3139
  const n = C(t), i = [
3136
- ws(r, {
3140
+ Ts(r, {
3137
3141
  size: n.size,
3138
3142
  scaleMode: e.scaleMode,
3139
3143
  scaleAspectRatio: e.scaleAspectRatio
3140
3144
  })
3141
- ], o = await Promise.all(i), c = o.map((p) => p.id), u = St(n, o, e);
3145
+ ], o = await Promise.all(i), c = o.map((p) => p.id), u = _t(n, o, e);
3142
3146
  u.duration = G(u.trackItemsMap);
3143
3147
  const d = u.tracks.filter((p) => p.magnetic);
3144
3148
  return nt(d, u.trackItemsMap, c), {
@@ -3148,8 +3152,8 @@ async function ka(t, r, e = {}) {
3148
3152
  duration: u.duration
3149
3153
  };
3150
3154
  }
3151
- async function va(t, r, e = {}) {
3152
- const n = C(t), i = "composition", o = r.trackItemsMap, c = r.trackItemIds, u = r.tracks || [], d = r.trackItemDetailsMap, { details: p, ...m } = await na(r, {
3155
+ async function _a(t, r, e = {}) {
3156
+ const n = C(t), i = "composition", o = r.trackItemsMap, c = r.trackItemIds, u = r.tracks || [], d = r.trackItemDetailsMap, { details: p, ...m } = await sa(r, {
3153
3157
  size: n.size,
3154
3158
  scaleMode: e.scaleMode,
3155
3159
  scaleAspectRatio: e.scaleAspectRatio
@@ -3162,7 +3166,7 @@ async function va(t, r, e = {}) {
3162
3166
  ...m,
3163
3167
  type: i,
3164
3168
  details: p
3165
- }], I = St(n, k, e);
3169
+ }], I = _t(n, k, e);
3166
3170
  I.trackItemsMap = {
3167
3171
  ...I.trackItemsMap,
3168
3172
  ...o,
@@ -3188,25 +3192,25 @@ async function va(t, r, e = {}) {
3188
3192
  structure: I.structure
3189
3193
  };
3190
3194
  }
3191
- async function ge(t, r, e = {}, n) {
3195
+ async function me(t, r, e = {}, n) {
3192
3196
  const i = C(t), o = (y) => y.display ? y.display : {
3193
3197
  from: 0,
3194
3198
  to: i.duration
3195
3199
  }, c = [];
3196
3200
  n === "progress-bar" && c.push(
3197
- Qi(r, {
3201
+ ta(r, {
3198
3202
  size: i.size,
3199
3203
  scaleMode: e.scaleMode,
3200
3204
  scaleAspectRatio: e.scaleAspectRatio
3201
3205
  })
3202
3206
  ), n === "progress-frame" && c.push(
3203
- ta(r, {
3207
+ ea(r, {
3204
3208
  size: i.size,
3205
3209
  scaleMode: e.scaleMode,
3206
3210
  scaleAspectRatio: e.scaleAspectRatio
3207
3211
  })
3208
3212
  ), n === "radial-audio-bars" && (r.display = o(r), c.push(
3209
- ea(r, {
3213
+ ra(r, {
3210
3214
  size: i.size,
3211
3215
  scaleMode: e.scaleMode,
3212
3216
  scaleAspectRatio: e.scaleAspectRatio
@@ -3230,13 +3234,13 @@ async function ge(t, r, e = {}, n) {
3230
3234
  scaleAspectRatio: e.scaleAspectRatio
3231
3235
  })
3232
3236
  )), n === "progress-square" && c.push(
3233
- ra(r, {
3237
+ na(r, {
3234
3238
  size: i.size,
3235
3239
  scaleMode: e.scaleMode,
3236
3240
  scaleAspectRatio: e.scaleAspectRatio
3237
3241
  })
3238
3242
  );
3239
- const u = await Promise.all(c), d = u.map((y) => y.id), p = St(i, u, e);
3243
+ const u = await Promise.all(c), d = u.map((y) => y.id), p = _t(i, u, e);
3240
3244
  p.duration = G(p.trackItemsMap);
3241
3245
  const m = p.tracks.filter((y) => y.magnetic);
3242
3246
  return nt(m, p.trackItemsMap, d), {
@@ -3246,8 +3250,8 @@ async function ge(t, r, e = {}, n) {
3246
3250
  duration: p.duration
3247
3251
  };
3248
3252
  }
3249
- async function _a(t, r, e = {}) {
3250
- const n = C(t), i = "template", o = r.trackItemsMap, c = r.trackItemIds, u = r.transitionsMap, d = r.transitionIds || [], p = r.tracks || [], m = r.structure || [], { details: y, ...h } = await Ss(r, {
3253
+ async function Sa(t, r, e = {}) {
3254
+ const n = C(t), i = "template", o = r.trackItemsMap, c = r.trackItemIds, u = r.transitionsMap, d = r.transitionIds || [], p = r.tracks || [], m = r.structure || [], { details: y, ...h } = await ws(r, {
3251
3255
  size: n.size,
3252
3256
  scaleMode: e.scaleMode,
3253
3257
  scaleAspectRatio: e.scaleAspectRatio
@@ -3260,7 +3264,7 @@ async function _a(t, r, e = {}) {
3260
3264
  ...h,
3261
3265
  type: i,
3262
3266
  details: y
3263
- }], _ = St(n, b, e);
3267
+ }], _ = _t(n, b, e);
3264
3268
  _.transitionIds = [
3265
3269
  ..._.transitionIds,
3266
3270
  ...d
@@ -3290,10 +3294,10 @@ async function _a(t, r, e = {}) {
3290
3294
  transitionsMap: _.transitionsMap
3291
3295
  };
3292
3296
  }
3293
- async function Sa(t, r, e = {}) {
3294
- const n = C(t), i = r.map((y) => Es(y, {
3297
+ async function wa(t, r, e = {}) {
3298
+ const n = C(t), i = r.map((y) => As(y, {
3295
3299
  size: e.size
3296
- })), o = await Promise.all(i), c = Os(
3300
+ })), o = await Promise.all(i), c = Cs(
3297
3301
  [
3298
3302
  {
3299
3303
  accepts: ["caption"],
@@ -3312,7 +3316,7 @@ async function Sa(t, r, e = {}) {
3312
3316
  ...k
3313
3317
  }
3314
3318
  };
3315
- }), xs(
3319
+ }), Os(
3316
3320
  n.tracks,
3317
3321
  c
3318
3322
  ))
@@ -3351,7 +3355,7 @@ async function Sa(t, r, e = {}) {
3351
3355
  duration: n.duration
3352
3356
  };
3353
3357
  }
3354
- async function wa(t, r) {
3358
+ async function Ta(t, r) {
3355
3359
  const e = C(t), n = e.trackItemsMap[r.id], i = [];
3356
3360
  if (!n) return {};
3357
3361
  let o = n.animations || {};
@@ -3375,18 +3379,18 @@ async function wa(t, r) {
3375
3379
  var u;
3376
3380
  (u = c.details) != null && u.fonts && i.push(...c.details.fonts);
3377
3381
  }
3378
- ), i.length > 0 && await He(i), o.in && r.animations.in ? o.in = r.animations.in : o.out && r.animations.out ? o.out = r.animations.out : o.loop && r.animations.loop ? o.loop = r.animations.loop : !o.out && r.animations.out ? o.out = r.animations.out : !o.in && r.animations.in ? o.in = r.animations.in : !o.loop && r.animations.loop ? o.loop = r.animations.loop : o = r.animations, (r.animations.in || r.animations.out || r.animations.loop) && delete o.timed, r.animations.timed && (o.timed = r.animations.timed, delete o.in, delete o.out, delete o.loop), n.animations = o, {
3382
+ ), i.length > 0 && await Le(i), o.in && r.animations.in ? o.in = r.animations.in : o.out && r.animations.out ? o.out = r.animations.out : o.loop && r.animations.loop ? o.loop = r.animations.loop : !o.out && r.animations.out ? o.out = r.animations.out : !o.in && r.animations.in ? o.in = r.animations.in : !o.loop && r.animations.loop ? o.loop = r.animations.loop : o = r.animations, (r.animations.in || r.animations.out || r.animations.loop) && delete o.timed, r.animations.timed && (o.timed = r.animations.timed, delete o.in, delete o.out, delete o.loop), n.animations = o, {
3379
3383
  trackItemsMap: e.trackItemsMap
3380
3384
  };
3381
3385
  }
3382
- async function Ta(t, r, e = {}) {
3386
+ async function Ea(t, r, e = {}) {
3383
3387
  const n = C(t), i = [
3384
- ia(r, {
3388
+ aa(r, {
3385
3389
  size: n.size,
3386
3390
  scaleMode: e.scaleMode,
3387
3391
  scaleAspectRatio: e.scaleAspectRatio
3388
3392
  })
3389
- ], o = await Promise.all(i), c = o.map((p) => p.id), u = St(n, o, e);
3393
+ ], o = await Promise.all(i), c = o.map((p) => p.id), u = _t(n, o, e);
3390
3394
  u.duration = G(u.trackItemsMap);
3391
3395
  const d = u.tracks.filter((p) => p.magnetic);
3392
3396
  return nt(d, u.trackItemsMap, c), {
@@ -3396,41 +3400,41 @@ async function Ta(t, r, e = {}) {
3396
3400
  duration: u.duration
3397
3401
  };
3398
3402
  }
3399
- function Ea(t) {
3400
- const r = Vt.pipe(
3401
- qt(({ key: f }) => f.startsWith(Xn))
3402
- ), e = Vt.pipe(
3403
- qt(({ key: f }) => f.startsWith(Rn))
3404
- ), n = Vt.pipe(
3405
- qt(({ key: f }) => f.startsWith(H))
3406
- ), i = Vt.pipe(
3407
- qt(({ key: f }) => f.startsWith(Q))
3408
- ), o = Vt.pipe(
3409
- qt(({ key: f }) => f.startsWith(Ar))
3410
- ), c = Vt.pipe(
3411
- qt(({ key: f }) => f.startsWith(Le))
3412
- ), u = Vt.pipe(
3413
- qt(({ key: f }) => f.startsWith(Zt))
3414
- ), d = Vt.pipe(
3415
- qt(({ key: f }) => f.startsWith(ds))
3403
+ function Aa(t) {
3404
+ const r = Kt.pipe(
3405
+ Vt(({ key: f }) => f.startsWith(Kn))
3406
+ ), e = Kt.pipe(
3407
+ Vt(({ key: f }) => f.startsWith(Rn))
3408
+ ), n = Kt.pipe(
3409
+ Vt(({ key: f }) => f.startsWith(H))
3410
+ ), i = Kt.pipe(
3411
+ Vt(({ key: f }) => f.startsWith(Q))
3412
+ ), o = Kt.pipe(
3413
+ Vt(({ key: f }) => f.startsWith(Ar))
3414
+ ), c = Kt.pipe(
3415
+ Vt(({ key: f }) => f.startsWith(Ne))
3416
+ ), u = Kt.pipe(
3417
+ Vt(({ key: f }) => f.startsWith(Jt))
3418
+ ), d = Kt.pipe(
3419
+ Vt(({ key: f }) => f.startsWith(fs))
3416
3420
  ), p = r.subscribe(async (f) => {
3417
3421
  var v;
3418
- if (f.key === Xn) {
3422
+ if (f.key === Kn) {
3419
3423
  const { actions: T } = (v = f.value) == null ? void 0 : v.payload;
3420
3424
  T.forEach((w) => {
3421
- Us(w.type, w.payload && { payload: w.payload });
3425
+ Ws(w.type, w.payload && { payload: w.payload });
3422
3426
  });
3423
3427
  }
3424
3428
  }), m = e.subscribe(async (f) => {
3425
3429
  var v, T;
3426
- if (f.key === ii) {
3427
- const w = (v = f.value) == null ? void 0 : v.payload, A = await oa(t.getState(), w);
3430
+ if (f.key === ai) {
3431
+ const w = (v = f.value) == null ? void 0 : v.payload, A = await ca(t.getState(), w);
3428
3432
  t.updateState(A, {
3429
3433
  kind: "design:load",
3430
3434
  updateHistory: !1
3431
3435
  });
3432
3436
  }
3433
- if (f.key === ai) {
3437
+ if (f.key === oi) {
3434
3438
  const w = (T = f.value) == null ? void 0 : T.payload;
3435
3439
  t.updateState(
3436
3440
  {
@@ -3443,11 +3447,11 @@ function Ea(t) {
3443
3447
  );
3444
3448
  }
3445
3449
  }), y = o.subscribe((f) => {
3446
- if (f.key === $i) return t.undo();
3447
- if (f.key === Fi) return t.redo();
3450
+ if (f.key === Fi) return t.undo();
3451
+ if (f.key === Ni) return t.redo();
3448
3452
  }), h = d.subscribe((f) => {
3449
3453
  var v;
3450
- if (f.key === Ni) {
3454
+ if (f.key === Li) {
3451
3455
  const T = (v = f.value) == null ? void 0 : v.payload.scale;
3452
3456
  t.updateState(
3453
3457
  {
@@ -3461,7 +3465,7 @@ function Ea(t) {
3461
3465
  }
3462
3466
  }), k = i.subscribe(async (f) => {
3463
3467
  var v, T, w, A;
3464
- if (f.key === Ci) {
3468
+ if (f.key === Pi) {
3465
3469
  const S = ((v = f.value) == null ? void 0 : v.payload.trackItemIds) || [];
3466
3470
  t.updateState(
3467
3471
  { activeIds: S },
@@ -3471,12 +3475,12 @@ function Ea(t) {
3471
3475
  }
3472
3476
  );
3473
3477
  }
3474
- if (f.key === Ri && ca(t.getState()), f.key === Di) {
3475
- const S = (T = f.value) == null ? void 0 : T.payload.trackItemIds, E = Ui(t.getState(), S);
3478
+ if (f.key === Ri && ua(t.getState()), f.key === zi) {
3479
+ const S = (T = f.value) == null ? void 0 : T.payload.trackItemIds, E = Wi(t.getState(), S);
3476
3480
  t.updateState(E, { updateHistory: !0, kind: "remove" });
3477
3481
  }
3478
- if (f.key === Pi) {
3479
- const S = Vi(
3482
+ if (f.key === Di) {
3483
+ const S = qi(
3480
3484
  t.getState(),
3481
3485
  (w = f.value) == null ? void 0 : w.payload.trackItemIds
3482
3486
  );
@@ -3485,121 +3489,121 @@ function Ea(t) {
3485
3489
  kind: "update"
3486
3490
  });
3487
3491
  }
3488
- if (f.key === zi) {
3489
- const S = (A = f.value) == null ? void 0 : A.payload, E = await Ki(t.getState(), S);
3492
+ if (f.key === $i) {
3493
+ const S = (A = f.value) == null ? void 0 : A.payload, E = await Vi(t.getState(), S);
3490
3494
  t.updateState(E, {
3491
3495
  updateHistory: !0,
3492
3496
  kind: "update:details"
3493
3497
  });
3494
3498
  }
3495
3499
  }), I = n.subscribe(async (f) => {
3496
- var L, R, Y, x, F, tt, Qt, te, Se, we, Te, Ee, z, Ae, Me, st, ee, $, re, xe, it, ne, se, zt, $t, ie, Ft, ae, Nt, oe, Oe, Ce, wt, Lt, ce, ue, ut, Tt, Re, gt, Et, Ht, et, le, de, Pe, Ut, At, fe, Mt, yt, at, xt, Wt, It, Bt, bt, jt, Yt;
3497
- const v = C(t.getState()), T = ((R = (L = f.value) == null ? void 0 : L.options) == null ? void 0 : R.isSelected) || !1, w = (x = (Y = f.value) == null ? void 0 : Y.options) == null ? void 0 : x.scaleMode, A = (tt = (F = f.value) == null ? void 0 : F.options) == null ? void 0 : tt.scaleAspectRatio, S = (te = (Qt = f.value) == null ? void 0 : Qt.options) == null ? void 0 : te.trackIndex;
3500
+ var L, P, Y, x, F, tt, Zt, Qt, _e, Se, we, Te, z, Ee, Ae, st, te, $, ee, Me, it, re, ne, Dt, zt, se, $t, ie, Ft, ae, xe, Oe, St, Nt, oe, ce, ut, wt, Ce, mt, Tt, Lt, et, ue, le, Pe, Ht, Et, de, At, gt, at, Mt, Ut, yt, Wt, It, jt, Bt;
3501
+ const v = C(t.getState()), T = ((P = (L = f.value) == null ? void 0 : L.options) == null ? void 0 : P.isSelected) || !1, w = (x = (Y = f.value) == null ? void 0 : Y.options) == null ? void 0 : x.scaleMode, A = (tt = (F = f.value) == null ? void 0 : F.options) == null ? void 0 : tt.scaleAspectRatio, S = (Qt = (Zt = f.value) == null ? void 0 : Zt.options) == null ? void 0 : Qt.trackIndex;
3498
3502
  let E = {};
3499
- f.key === pi ? E = await wa(v, (Se = f.value) == null ? void 0 : Se.payload) : f.key === gi ? E = await ha(v, (we = f.value) == null ? void 0 : we.payload, {
3503
+ f.key === hi ? E = await Ta(v, (_e = f.value) == null ? void 0 : _e.payload) : f.key === yi ? E = await ma(v, (Se = f.value) == null ? void 0 : Se.payload, {
3500
3504
  trackIndex: S
3501
- }) : f.key === hi ? E = await Sa(v, (Te = f.value) == null ? void 0 : Te.payload, {
3505
+ }) : f.key === mi ? E = await wa(v, (we = f.value) == null ? void 0 : we.payload, {
3502
3506
  size: v.size
3503
- }) : f.key === oi ? E = await Ia(v, (Ee = f.value) == null ? void 0 : Ee.payload, {
3507
+ }) : f.key === ci ? E = await ba(v, (Te = f.value) == null ? void 0 : Te.payload, {
3504
3508
  targetTrackIndex: S,
3505
3509
  targetTrackId: (z = f.value) == null ? void 0 : z.options.targetTrackId,
3506
3510
  size: v.size,
3507
- isNewTrack: (Me = (Ae = f.value) == null ? void 0 : Ae.options) == null ? void 0 : Me.isNewTrack
3508
- }) : f.key === mi ? E = await _a(v, (st = f.value) == null ? void 0 : st.payload, {
3511
+ isNewTrack: (Ae = (Ee = f.value) == null ? void 0 : Ee.options) == null ? void 0 : Ae.isNewTrack
3512
+ }) : f.key === gi ? E = await Sa(v, (st = f.value) == null ? void 0 : st.payload, {
3509
3513
  scaleMode: w,
3510
3514
  scaleAspectRatio: A,
3511
3515
  targetTrackIndex: S,
3512
- targetTrackId: ($ = (ee = f.value) == null ? void 0 : ee.options) == null ? void 0 : $.targetTrackId
3513
- }) : f.key === di ? E = await ka(v, (re = f.value) == null ? void 0 : re.payload, {
3516
+ targetTrackId: ($ = (te = f.value) == null ? void 0 : te.options) == null ? void 0 : $.targetTrackId
3517
+ }) : f.key === fi ? E = await va(v, (ee = f.value) == null ? void 0 : ee.payload, {
3514
3518
  scaleMode: w,
3515
3519
  scaleAspectRatio: A,
3516
3520
  targetTrackIndex: S,
3517
- targetTrackId: (xe = f.value) == null ? void 0 : xe.options.targetTrackId
3518
- }) : f.key === fi ? E = await ba(v, (it = f.value) == null ? void 0 : it.payload, {
3521
+ targetTrackId: (Me = f.value) == null ? void 0 : Me.options.targetTrackId
3522
+ }) : f.key === pi ? E = await ka(v, (it = f.value) == null ? void 0 : it.payload, {
3519
3523
  scaleMode: w,
3520
3524
  scaleAspectRatio: A,
3521
3525
  targetTrackIndex: S,
3522
- targetTrackId: (ne = f.value) == null ? void 0 : ne.options.targetTrackId
3523
- }) : f.key === Ti ? E = await Ta(v, (se = f.value) == null ? void 0 : se.payload, {
3526
+ targetTrackId: (re = f.value) == null ? void 0 : re.options.targetTrackId
3527
+ }) : f.key === Ei ? E = await Ea(v, (ne = f.value) == null ? void 0 : ne.payload, {
3524
3528
  scaleMode: w,
3525
3529
  scaleAspectRatio: A,
3526
3530
  targetTrackIndex: S,
3527
- targetTrackId: (zt = f.value) == null ? void 0 : zt.options.targetTrackId
3528
- }) : f.key === li ? E = await ma(v, ($t = f.value) == null ? void 0 : $t.payload, {
3531
+ targetTrackId: (Dt = f.value) == null ? void 0 : Dt.options.targetTrackId
3532
+ }) : f.key === di ? E = await ga(v, (zt = f.value) == null ? void 0 : zt.payload, {
3529
3533
  scaleMode: w,
3530
3534
  scaleAspectRatio: A,
3531
3535
  targetTrackIndex: S,
3532
- targetTrackId: (ie = f.value) == null ? void 0 : ie.options.targetTrackId,
3533
- isNewTrack: (ae = (Ft = f.value) == null ? void 0 : Ft.options) == null ? void 0 : ae.isNewTrack
3534
- }) : f.key === ui ? E = await ga(v, (Nt = f.value) == null ? void 0 : Nt.payload, {
3536
+ targetTrackId: (se = f.value) == null ? void 0 : se.options.targetTrackId,
3537
+ isNewTrack: (ie = ($t = f.value) == null ? void 0 : $t.options) == null ? void 0 : ie.isNewTrack
3538
+ }) : f.key === li ? E = await ya(v, (Ft = f.value) == null ? void 0 : Ft.payload, {
3535
3539
  targetTrackIndex: S,
3536
- targetTrackId: (oe = f.value) == null ? void 0 : oe.options.targetTrackId,
3537
- isNewTrack: (Ce = (Oe = f.value) == null ? void 0 : Oe.options) == null ? void 0 : Ce.isNewTrack
3538
- }) : f.key === ci ? E = await ya(v, (wt = f.value) == null ? void 0 : wt.payload, {
3540
+ targetTrackId: (ae = f.value) == null ? void 0 : ae.options.targetTrackId,
3541
+ isNewTrack: (Oe = (xe = f.value) == null ? void 0 : xe.options) == null ? void 0 : Oe.isNewTrack
3542
+ }) : f.key === ui ? E = await Ia(v, (St = f.value) == null ? void 0 : St.payload, {
3539
3543
  scaleMode: w,
3540
3544
  scaleAspectRatio: A,
3541
3545
  targetTrackIndex: S,
3542
- targetTrackId: (Lt = f.value) == null ? void 0 : Lt.options.targetTrackId,
3543
- isNewTrack: (ue = (ce = f.value) == null ? void 0 : ce.options) == null ? void 0 : ue.isNewTrack
3544
- }) : f.key === yi ? E = await va(v, (ut = f.value) == null ? void 0 : ut.payload, {
3546
+ targetTrackId: (Nt = f.value) == null ? void 0 : Nt.options.targetTrackId,
3547
+ isNewTrack: (ce = (oe = f.value) == null ? void 0 : oe.options) == null ? void 0 : ce.isNewTrack
3548
+ }) : f.key === Ii ? E = await _a(v, (ut = f.value) == null ? void 0 : ut.payload, {
3545
3549
  scaleMode: w,
3546
3550
  scaleAspectRatio: A,
3547
3551
  targetTrackIndex: S,
3548
- targetTrackId: (Tt = f.value) == null ? void 0 : Tt.options.targetTrackId
3549
- }) : f.key === Ii ? E = await ge(
3552
+ targetTrackId: (wt = f.value) == null ? void 0 : wt.options.targetTrackId
3553
+ }) : f.key === bi ? E = await me(
3550
3554
  v,
3551
- (Re = f.value) == null ? void 0 : Re.payload,
3555
+ (Ce = f.value) == null ? void 0 : Ce.payload,
3552
3556
  {
3553
3557
  targetTrackIndex: S,
3554
- targetTrackId: (Et = (gt = f.value) == null ? void 0 : gt.options) == null ? void 0 : Et.targetTrackId
3558
+ targetTrackId: (Tt = (mt = f.value) == null ? void 0 : mt.options) == null ? void 0 : Tt.targetTrackId
3555
3559
  },
3556
3560
  "progress-bar"
3557
- ) : f.key === _i ? E = await ge(
3561
+ ) : f.key === Si ? E = await me(
3558
3562
  v,
3559
- (Ht = f.value) == null ? void 0 : Ht.payload,
3563
+ (Lt = f.value) == null ? void 0 : Lt.payload,
3560
3564
  {
3561
3565
  targetTrackIndex: S,
3562
- targetTrackId: (le = (et = f.value) == null ? void 0 : et.options) == null ? void 0 : le.targetTrackId
3566
+ targetTrackId: (ue = (et = f.value) == null ? void 0 : et.options) == null ? void 0 : ue.targetTrackId
3563
3567
  },
3564
3568
  "progress-square"
3565
- ) : f.key === bi ? E = await ge(
3569
+ ) : f.key === ki ? E = await me(
3566
3570
  v,
3567
- (de = f.value) == null ? void 0 : de.payload,
3571
+ (le = f.value) == null ? void 0 : le.payload,
3568
3572
  {
3569
3573
  targetTrackIndex: S,
3570
- targetTrackId: (Ut = (Pe = f.value) == null ? void 0 : Pe.options) == null ? void 0 : Ut.targetTrackId
3574
+ targetTrackId: (Ht = (Pe = f.value) == null ? void 0 : Pe.options) == null ? void 0 : Ht.targetTrackId
3571
3575
  },
3572
3576
  "progress-frame"
3573
- ) : f.key === ki ? E = await ge(
3577
+ ) : f.key === vi ? E = await me(
3574
3578
  v,
3575
- (At = f.value) == null ? void 0 : At.payload,
3579
+ (Et = f.value) == null ? void 0 : Et.payload,
3576
3580
  {
3577
3581
  targetTrackIndex: S,
3578
- targetTrackId: (Mt = (fe = f.value) == null ? void 0 : fe.options) == null ? void 0 : Mt.targetTrackId
3582
+ targetTrackId: (At = (de = f.value) == null ? void 0 : de.options) == null ? void 0 : At.targetTrackId
3579
3583
  },
3580
3584
  "radial-audio-bars"
3581
- ) : f.key === vi ? E = await ge(
3585
+ ) : f.key === _i ? E = await me(
3582
3586
  v,
3583
- (yt = f.value) == null ? void 0 : yt.payload,
3587
+ (gt = f.value) == null ? void 0 : gt.payload,
3584
3588
  {
3585
3589
  targetTrackIndex: S,
3586
- targetTrackId: (xt = (at = f.value) == null ? void 0 : at.options) == null ? void 0 : xt.targetTrackId
3590
+ targetTrackId: (Mt = (at = f.value) == null ? void 0 : at.options) == null ? void 0 : Mt.targetTrackId
3587
3591
  },
3588
3592
  "lineal-audio-bars"
3589
- ) : f.key === Si ? E = await ge(
3593
+ ) : f.key === wi ? E = await me(
3590
3594
  v,
3591
- (Wt = f.value) == null ? void 0 : Wt.payload,
3595
+ (Ut = f.value) == null ? void 0 : Ut.payload,
3592
3596
  {
3593
3597
  targetTrackIndex: S,
3594
- targetTrackId: (Bt = (It = f.value) == null ? void 0 : It.options) == null ? void 0 : Bt.targetTrackId
3598
+ targetTrackId: (Wt = (yt = f.value) == null ? void 0 : yt.options) == null ? void 0 : Wt.targetTrackId
3595
3599
  },
3596
3600
  "wave-audio-bars"
3597
- ) : f.key === wi && (E = await ge(
3601
+ ) : f.key === Ti && (E = await me(
3598
3602
  v,
3599
- (bt = f.value) == null ? void 0 : bt.payload,
3603
+ (It = f.value) == null ? void 0 : It.payload,
3600
3604
  {
3601
3605
  targetTrackIndex: S,
3602
- targetTrackId: (Yt = (jt = f.value) == null ? void 0 : jt.options) == null ? void 0 : Yt.targetTrackId
3606
+ targetTrackId: (Bt = (jt = f.value) == null ? void 0 : jt.options) == null ? void 0 : Bt.targetTrackId
3603
3607
  },
3604
3608
  "hill-audio-bars"
3605
3609
  )), T && E.trackItemIds && (E.activeIds = E.trackItemIds), t.updateState(E, {
@@ -3608,15 +3612,15 @@ function Ea(t) {
3608
3612
  });
3609
3613
  }), b = c.subscribe(async (f) => {
3610
3614
  var v;
3611
- if (f.key === Oi) {
3612
- const T = (v = f.value) == null ? void 0 : v.options.time, w = ua(t.getState(), T);
3615
+ if (f.key === Ci) {
3616
+ const T = (v = f.value) == null ? void 0 : v.options.time, w = la(t.getState(), T);
3613
3617
  Object.keys(w).length > 0 && t.updateState(w, {
3614
3618
  updateHistory: !0,
3615
3619
  kind: "update"
3616
3620
  });
3617
3621
  }
3618
- if (f.key === xi) {
3619
- const T = await ji(t.getState());
3622
+ if (f.key === Oi) {
3623
+ const T = await Yi(t.getState());
3620
3624
  t.updateState(T, {
3621
3625
  updateHistory: !0,
3622
3626
  kind: "update"
@@ -3624,8 +3628,8 @@ function Ea(t) {
3624
3628
  }
3625
3629
  }), _ = u.subscribe(async (f) => {
3626
3630
  var v, T, w;
3627
- if (f.key === Ei) {
3628
- const A = await la(
3631
+ if (f.key === Ai) {
3632
+ const A = await da(
3629
3633
  t.getState(),
3630
3634
  (v = f.value) == null ? void 0 : v.payload
3631
3635
  );
@@ -3634,8 +3638,8 @@ function Ea(t) {
3634
3638
  kind: "update:details"
3635
3639
  });
3636
3640
  }
3637
- if (f.key === Ai) {
3638
- const A = await da(
3641
+ if (f.key === Mi) {
3642
+ const A = await fa(
3639
3643
  t.getState(),
3640
3644
  (T = f.value) == null ? void 0 : T.payload
3641
3645
  );
@@ -3644,8 +3648,8 @@ function Ea(t) {
3644
3648
  kind: "update:details"
3645
3649
  });
3646
3650
  }
3647
- if (f.key === Mi) {
3648
- const A = fa(t.getState(), (w = f.value) == null ? void 0 : w.payload);
3651
+ if (f.key === xi) {
3652
+ const A = pa(t.getState(), (w = f.value) == null ? void 0 : w.payload);
3649
3653
  t.updateState(A, {
3650
3654
  updateHistory: !0,
3651
3655
  kind: "update:details"
@@ -3658,8 +3662,8 @@ function Ea(t) {
3658
3662
  }
3659
3663
  };
3660
3664
  }
3661
- const Aa = { Date: !0, RegExp: !0, String: !0, Number: !0 };
3662
- function Cs(t, r, e = { cyclesFix: !0 }, n = []) {
3665
+ const Ma = { Date: !0, RegExp: !0, String: !0, Number: !0 };
3666
+ function Ps(t, r, e = { cyclesFix: !0 }, n = []) {
3663
3667
  var u, d;
3664
3668
  let i = [];
3665
3669
  const o = Array.isArray(t);
@@ -3674,7 +3678,7 @@ function Cs(t, r, e = { cyclesFix: !0 }, n = []) {
3674
3678
  continue;
3675
3679
  }
3676
3680
  const h = r[p], k = typeof m == "object" && typeof h == "object" && Array.isArray(m) === Array.isArray(h);
3677
- m && h && k && !Aa[(d = (u = Object.getPrototypeOf(m)) == null ? void 0 : u.constructor) == null ? void 0 : d.name] && (!e.cyclesFix || !n.includes(m)) ? i.push.apply(i, Cs(m, h, e, e.cyclesFix ? n.concat([m]) : []).map((I) => (I.path.unshift(y), I))) : m !== h && // treat NaN values as equivalent
3681
+ m && h && k && !Ma[(d = (u = Object.getPrototypeOf(m)) == null ? void 0 : u.constructor) == null ? void 0 : d.name] && (!e.cyclesFix || !n.includes(m)) ? i.push.apply(i, Ps(m, h, e, e.cyclesFix ? n.concat([m]) : []).map((I) => (I.path.unshift(y), I))) : m !== h && // treat NaN values as equivalent
3678
3682
  !(Number.isNaN(m) && Number.isNaN(h)) && !(k && (isNaN(m) ? m + "" == h + "" : +m == +h)) && i.push({
3679
3683
  path: [y],
3680
3684
  type: "CHANGE",
@@ -3691,7 +3695,7 @@ function Cs(t, r, e = { cyclesFix: !0 }, n = []) {
3691
3695
  });
3692
3696
  return i;
3693
3697
  }
3694
- var zn = Symbol.for("immer-nothing"), Je = Symbol.for("immer-draftable"), lt = Symbol.for("immer-state"), Rs = process.env.NODE_ENV !== "production" ? [
3698
+ var $n = Symbol.for("immer-nothing"), Je = Symbol.for("immer-draftable"), lt = Symbol.for("immer-state"), Rs = process.env.NODE_ENV !== "production" ? [
3695
3699
  // All error codes, starting by 0:
3696
3700
  function(t) {
3697
3701
  return `The plugin for '${t}' has not been loaded into Immer. To enable the plugin, import and call \`enable${t}()\` when initializing your application.`;
@@ -3722,7 +3726,7 @@ var zn = Symbol.for("immer-nothing"), Je = Symbol.for("immer-draftable"), lt = S
3722
3726
  // Note: if more errors are added, the errorOffset in Patches.ts should be increased
3723
3727
  // See Patches.ts for additional errors
3724
3728
  ] : [];
3725
- function j(t, ...r) {
3729
+ function B(t, ...r) {
3726
3730
  if (process.env.NODE_ENV !== "production") {
3727
3731
  const e = Rs[t], n = typeof e == "function" ? e.apply(null, r) : e;
3728
3732
  throw new Error(`[Immer] ${n}`);
@@ -3731,63 +3735,63 @@ function j(t, ...r) {
3731
3735
  `[Immer] minified error nr: ${t}. Full error at: https://bit.ly/3cXEKWf`
3732
3736
  );
3733
3737
  }
3734
- var be = Object.getPrototypeOf;
3735
- function ke(t) {
3738
+ var Ie = Object.getPrototypeOf;
3739
+ function be(t) {
3736
3740
  return !!t && !!t[lt];
3737
3741
  }
3738
- function Jt(t) {
3742
+ function qt(t) {
3739
3743
  var r;
3740
- return t ? Ps(t) || Array.isArray(t) || !!t[Je] || !!((r = t.constructor) != null && r[Je]) || sr(t) || ir(t) : !1;
3744
+ return t ? Ds(t) || Array.isArray(t) || !!t[Je] || !!((r = t.constructor) != null && r[Je]) || Ue(t) || sr(t) : !1;
3741
3745
  }
3742
- var Ma = Object.prototype.constructor.toString();
3743
- function Ps(t) {
3746
+ var xa = Object.prototype.constructor.toString();
3747
+ function Ds(t) {
3744
3748
  if (!t || typeof t != "object")
3745
3749
  return !1;
3746
- const r = be(t);
3750
+ const r = Ie(t);
3747
3751
  if (r === null)
3748
3752
  return !0;
3749
3753
  const e = Object.hasOwnProperty.call(r, "constructor") && r.constructor;
3750
- return e === Object ? !0 : typeof e == "function" && Function.toString.call(e) === Ma;
3754
+ return e === Object ? !0 : typeof e == "function" && Function.toString.call(e) === xa;
3751
3755
  }
3752
3756
  function Ze(t, r) {
3753
- ve(t) === 0 ? Reflect.ownKeys(t).forEach((e) => {
3757
+ ke(t) === 0 ? Reflect.ownKeys(t).forEach((e) => {
3754
3758
  r(e, t[e], t);
3755
3759
  }) : t.forEach((e, n) => r(n, e, t));
3756
3760
  }
3757
- function ve(t) {
3761
+ function ke(t) {
3758
3762
  const r = t[lt];
3759
- return r ? r.type_ : Array.isArray(t) ? 1 : sr(t) ? 2 : ir(t) ? 3 : 0;
3763
+ return r ? r.type_ : Array.isArray(t) ? 1 : Ue(t) ? 2 : sr(t) ? 3 : 0;
3760
3764
  }
3761
3765
  function Qe(t, r) {
3762
- return ve(t) === 2 ? t.has(r) : Object.prototype.hasOwnProperty.call(t, r);
3766
+ return ke(t) === 2 ? t.has(r) : Object.prototype.hasOwnProperty.call(t, r);
3763
3767
  }
3764
3768
  function gn(t, r) {
3765
- return ve(t) === 2 ? t.get(r) : t[r];
3769
+ return ke(t) === 2 ? t.get(r) : t[r];
3766
3770
  }
3767
- function Ds(t, r, e) {
3768
- const n = ve(t);
3771
+ function zs(t, r, e) {
3772
+ const n = ke(t);
3769
3773
  n === 2 ? t.set(r, e) : n === 3 ? t.add(e) : t[r] = e;
3770
3774
  }
3771
- function xa(t, r) {
3775
+ function Oa(t, r) {
3772
3776
  return t === r ? t !== 0 || 1 / t === 1 / r : t !== t && r !== r;
3773
3777
  }
3774
- function sr(t) {
3778
+ function Ue(t) {
3775
3779
  return t instanceof Map;
3776
3780
  }
3777
- function ir(t) {
3781
+ function sr(t) {
3778
3782
  return t instanceof Set;
3779
3783
  }
3780
- function ye(t) {
3784
+ function ge(t) {
3781
3785
  return t.copy_ || t.base_;
3782
3786
  }
3783
3787
  function Tn(t, r) {
3784
- if (sr(t))
3788
+ if (Ue(t))
3785
3789
  return new Map(t);
3786
- if (ir(t))
3790
+ if (sr(t))
3787
3791
  return new Set(t);
3788
3792
  if (Array.isArray(t))
3789
3793
  return Array.prototype.slice.call(t);
3790
- const e = Ps(t);
3794
+ const e = Ds(t);
3791
3795
  if (r === !0 || r === "class_only" && !e) {
3792
3796
  const n = Object.getOwnPropertyDescriptors(t);
3793
3797
  delete n[lt];
@@ -3802,37 +3806,42 @@ function Tn(t, r) {
3802
3806
  value: t[c]
3803
3807
  });
3804
3808
  }
3805
- return Object.create(be(t), n);
3809
+ return Object.create(Ie(t), n);
3806
3810
  } else {
3807
- const n = be(t);
3811
+ const n = Ie(t);
3808
3812
  if (n !== null && e)
3809
3813
  return { ...t };
3810
3814
  const i = Object.create(n);
3811
3815
  return Object.assign(i, t);
3812
3816
  }
3813
3817
  }
3814
- function $n(t, r = !1) {
3815
- return Mr(t) || ke(t) || !Jt(t) || (ve(t) > 1 && (t.set = t.add = t.clear = t.delete = Oa), Object.freeze(t), r && Object.entries(t).forEach(([e, n]) => $n(n, !0))), t;
3818
+ function Fn(t, r = !1) {
3819
+ return Mr(t) || be(t) || !qt(t) || (ke(t) > 1 && Object.defineProperties(t, {
3820
+ set: { value: br },
3821
+ add: { value: br },
3822
+ clear: { value: br },
3823
+ delete: { value: br }
3824
+ }), Object.freeze(t), r && Object.values(t).forEach((e) => Fn(e, !0))), t;
3816
3825
  }
3817
- function Oa() {
3818
- j(2);
3826
+ function br() {
3827
+ B(2);
3819
3828
  }
3820
3829
  function Mr(t) {
3821
3830
  return Object.isFrozen(t);
3822
3831
  }
3823
3832
  var En = {};
3824
- function _e(t) {
3833
+ function ve(t) {
3825
3834
  const r = En[t];
3826
- return r || j(0, t), r;
3835
+ return r || B(0, t), r;
3827
3836
  }
3828
3837
  function Ca(t, r) {
3829
3838
  En[t] || (En[t] = r);
3830
3839
  }
3831
3840
  var tr;
3832
- function zs() {
3841
+ function $s() {
3833
3842
  return tr;
3834
3843
  }
3835
- function Ra(t, r) {
3844
+ function Pa(t, r) {
3836
3845
  return {
3837
3846
  drafts_: [],
3838
3847
  parent_: t,
@@ -3843,31 +3852,31 @@ function Ra(t, r) {
3843
3852
  unfinalizedDrafts_: 0
3844
3853
  };
3845
3854
  }
3846
- function qn(t, r) {
3847
- r && (_e("Patches"), t.patches_ = [], t.inversePatches_ = [], t.patchListener_ = r);
3855
+ function Jn(t, r) {
3856
+ r && (ve("Patches"), t.patches_ = [], t.inversePatches_ = [], t.patchListener_ = r);
3848
3857
  }
3849
3858
  function An(t) {
3850
- Mn(t), t.drafts_.forEach(Pa), t.drafts_ = null;
3859
+ Mn(t), t.drafts_.forEach(Ra), t.drafts_ = null;
3851
3860
  }
3852
3861
  function Mn(t) {
3853
3862
  t === tr && (tr = t.parent_);
3854
3863
  }
3855
- function Jn(t) {
3856
- return tr = Ra(tr, t);
3864
+ function Zn(t) {
3865
+ return tr = Pa(tr, t);
3857
3866
  }
3858
- function Pa(t) {
3867
+ function Ra(t) {
3859
3868
  const r = t[lt];
3860
3869
  r.type_ === 0 || r.type_ === 1 ? r.revoke_() : r.revoked_ = !0;
3861
3870
  }
3862
- function Zn(t, r) {
3871
+ function Qn(t, r) {
3863
3872
  r.unfinalizedDrafts_ = r.drafts_.length;
3864
3873
  const e = r.drafts_[0];
3865
- return t !== void 0 && t !== e ? (e[lt].modified_ && (An(r), j(4)), Jt(t) && (t = wr(r, t), r.parent_ || Tr(r, t)), r.patches_ && _e("Patches").generateReplacementPatches_(
3874
+ return t !== void 0 && t !== e ? (e[lt].modified_ && (An(r), B(4)), qt(t) && (t = wr(r, t), r.parent_ || Tr(r, t)), r.patches_ && ve("Patches").generateReplacementPatches_(
3866
3875
  e[lt].base_,
3867
3876
  t,
3868
3877
  r.patches_,
3869
3878
  r.inversePatches_
3870
- )) : t = wr(r, e, []), An(r), r.patches_ && r.patchListener_(r.patches_, r.inversePatches_), t !== zn ? t : void 0;
3879
+ )) : t = wr(r, e, []), An(r), r.patches_ && r.patchListener_(r.patches_, r.inversePatches_), t !== $n ? t : void 0;
3871
3880
  }
3872
3881
  function wr(t, r, e) {
3873
3882
  if (Mr(r))
@@ -3876,7 +3885,7 @@ function wr(t, r, e) {
3876
3885
  if (!n)
3877
3886
  return Ze(
3878
3887
  r,
3879
- (i, o) => Qn(t, n, r, i, o, e)
3888
+ (i, o) => ts(t, n, r, i, o, e)
3880
3889
  ), r;
3881
3890
  if (n.scope_ !== t)
3882
3891
  return r;
@@ -3888,8 +3897,8 @@ function wr(t, r, e) {
3888
3897
  let o = i, c = !1;
3889
3898
  n.type_ === 3 && (o = new Set(i), i.clear(), c = !0), Ze(
3890
3899
  o,
3891
- (u, d) => Qn(t, n, i, u, d, e, c)
3892
- ), Tr(t, i, !1), e && t.patches_ && _e("Patches").generatePatches_(
3900
+ (u, d) => ts(t, n, i, u, d, e, c)
3901
+ ), Tr(t, i, !1), e && t.patches_ && ve("Patches").generatePatches_(
3893
3902
  n,
3894
3903
  e,
3895
3904
  t.patches_,
@@ -3898,29 +3907,29 @@ function wr(t, r, e) {
3898
3907
  }
3899
3908
  return n.copy_;
3900
3909
  }
3901
- function Qn(t, r, e, n, i, o, c) {
3902
- if (process.env.NODE_ENV !== "production" && i === e && j(5), ke(i)) {
3910
+ function ts(t, r, e, n, i, o, c) {
3911
+ if (process.env.NODE_ENV !== "production" && i === e && B(5), be(i)) {
3903
3912
  const u = o && r && r.type_ !== 3 && // Set objects are atomic since they have no keys.
3904
3913
  !Qe(r.assigned_, n) ? o.concat(n) : void 0, d = wr(t, i, u);
3905
- if (Ds(e, n, d), ke(d))
3914
+ if (zs(e, n, d), be(d))
3906
3915
  t.canAutoFreeze_ = !1;
3907
3916
  else
3908
3917
  return;
3909
3918
  } else c && e.add(i);
3910
- if (Jt(i) && !Mr(i)) {
3919
+ if (qt(i) && !Mr(i)) {
3911
3920
  if (!t.immer_.autoFreeze_ && t.unfinalizedDrafts_ < 1)
3912
3921
  return;
3913
- wr(t, i), (!r || !r.scope_.parent_) && typeof n != "symbol" && Object.prototype.propertyIsEnumerable.call(e, n) && Tr(t, i);
3922
+ wr(t, i), (!r || !r.scope_.parent_) && typeof n != "symbol" && (Ue(e) ? e.has(n) : Object.prototype.propertyIsEnumerable.call(e, n)) && Tr(t, i);
3914
3923
  }
3915
3924
  }
3916
3925
  function Tr(t, r, e = !1) {
3917
- !t.parent_ && t.immer_.autoFreeze_ && t.canAutoFreeze_ && $n(r, e);
3926
+ !t.parent_ && t.immer_.autoFreeze_ && t.canAutoFreeze_ && Fn(r, e);
3918
3927
  }
3919
3928
  function Da(t, r) {
3920
3929
  const e = Array.isArray(t), n = {
3921
3930
  type_: e ? 1 : 0,
3922
3931
  // Track which produce call this is associated with.
3923
- scope_: r ? r.scope_ : zs(),
3932
+ scope_: r ? r.scope_ : $s(),
3924
3933
  // True for both shallow and deep changes.
3925
3934
  modified_: !1,
3926
3935
  // Used during finalization.
@@ -3940,36 +3949,36 @@ function Da(t, r) {
3940
3949
  revoke_: null,
3941
3950
  isManual_: !1
3942
3951
  };
3943
- let i = n, o = Fn;
3952
+ let i = n, o = Nn;
3944
3953
  e && (i = [n], o = er);
3945
3954
  const { revoke: c, proxy: u } = Proxy.revocable(i, o);
3946
3955
  return n.draft_ = u, n.revoke_ = c, u;
3947
3956
  }
3948
- var Fn = {
3957
+ var Nn = {
3949
3958
  get(t, r) {
3950
3959
  if (r === lt)
3951
3960
  return t;
3952
- const e = ye(t);
3961
+ const e = ge(t);
3953
3962
  if (!Qe(e, r))
3954
3963
  return za(t, e, r);
3955
3964
  const n = e[r];
3956
- return t.finalized_ || !Jt(n) ? n : n === yn(t.base_, r) ? (In(t), t.copy_[r] = On(n, t)) : n;
3965
+ return t.finalized_ || !qt(n) ? n : n === yn(t.base_, r) ? (In(t), t.copy_[r] = On(n, t)) : n;
3957
3966
  },
3958
3967
  has(t, r) {
3959
- return r in ye(t);
3968
+ return r in ge(t);
3960
3969
  },
3961
3970
  ownKeys(t) {
3962
- return Reflect.ownKeys(ye(t));
3971
+ return Reflect.ownKeys(ge(t));
3963
3972
  },
3964
3973
  set(t, r, e) {
3965
- const n = $s(ye(t), r);
3974
+ const n = Fs(ge(t), r);
3966
3975
  if (n != null && n.set)
3967
3976
  return n.set.call(t.draft_, e), !0;
3968
3977
  if (!t.modified_) {
3969
- const i = yn(ye(t), r), o = i == null ? void 0 : i[lt];
3978
+ const i = yn(ge(t), r), o = i == null ? void 0 : i[lt];
3970
3979
  if (o && o.base_ === e)
3971
3980
  return t.copy_[r] = e, t.assigned_[r] = !1, !0;
3972
- if (xa(e, i) && (e !== void 0 || Qe(t.base_, r)))
3981
+ if (Oa(e, i) && (e !== void 0 || Qe(t.base_, r)))
3973
3982
  return !0;
3974
3983
  In(t), xn(t);
3975
3984
  }
@@ -3983,7 +3992,7 @@ var Fn = {
3983
3992
  // Note: We never coerce `desc.value` into an Immer draft, because we can't make
3984
3993
  // the same guarantee in ES5 mode.
3985
3994
  getOwnPropertyDescriptor(t, r) {
3986
- const e = ye(t), n = Reflect.getOwnPropertyDescriptor(e, r);
3995
+ const e = ge(t), n = Reflect.getOwnPropertyDescriptor(e, r);
3987
3996
  return n && {
3988
3997
  writable: !0,
3989
3998
  configurable: t.type_ !== 1 || r !== "length",
@@ -3992,48 +4001,48 @@ var Fn = {
3992
4001
  };
3993
4002
  },
3994
4003
  defineProperty() {
3995
- j(11);
4004
+ B(11);
3996
4005
  },
3997
4006
  getPrototypeOf(t) {
3998
- return be(t.base_);
4007
+ return Ie(t.base_);
3999
4008
  },
4000
4009
  setPrototypeOf() {
4001
- j(12);
4010
+ B(12);
4002
4011
  }
4003
4012
  }, er = {};
4004
- Ze(Fn, (t, r) => {
4013
+ Ze(Nn, (t, r) => {
4005
4014
  er[t] = function() {
4006
4015
  return arguments[0] = arguments[0][0], r.apply(this, arguments);
4007
4016
  };
4008
4017
  });
4009
4018
  er.deleteProperty = function(t, r) {
4010
- return process.env.NODE_ENV !== "production" && isNaN(parseInt(r)) && j(13), er.set.call(this, t, r, void 0);
4019
+ return process.env.NODE_ENV !== "production" && isNaN(parseInt(r)) && B(13), er.set.call(this, t, r, void 0);
4011
4020
  };
4012
4021
  er.set = function(t, r, e) {
4013
- return process.env.NODE_ENV !== "production" && r !== "length" && isNaN(parseInt(r)) && j(14), Fn.set.call(this, t[0], r, e, t[0]);
4022
+ return process.env.NODE_ENV !== "production" && r !== "length" && isNaN(parseInt(r)) && B(14), Nn.set.call(this, t[0], r, e, t[0]);
4014
4023
  };
4015
4024
  function yn(t, r) {
4016
4025
  const e = t[lt];
4017
- return (e ? ye(e) : t)[r];
4026
+ return (e ? ge(e) : t)[r];
4018
4027
  }
4019
4028
  function za(t, r, e) {
4020
4029
  var i;
4021
- const n = $s(r, e);
4030
+ const n = Fs(r, e);
4022
4031
  return n ? "value" in n ? n.value : (
4023
4032
  // This is a very special case, if the prop is a getter defined by the
4024
4033
  // prototype, we should invoke it with the draft as context!
4025
4034
  (i = n.get) == null ? void 0 : i.call(t.draft_)
4026
4035
  ) : void 0;
4027
4036
  }
4028
- function $s(t, r) {
4037
+ function Fs(t, r) {
4029
4038
  if (!(r in t))
4030
4039
  return;
4031
- let e = be(t);
4040
+ let e = Ie(t);
4032
4041
  for (; e; ) {
4033
4042
  const n = Object.getOwnPropertyDescriptor(e, r);
4034
4043
  if (n)
4035
4044
  return n;
4036
- e = be(e);
4045
+ e = Ie(e);
4037
4046
  }
4038
4047
  }
4039
4048
  function xn(t) {
@@ -4056,25 +4065,25 @@ var $a = class {
4056
4065
  return c.produce(d, (m) => e.call(this, m, ...p));
4057
4066
  };
4058
4067
  }
4059
- typeof e != "function" && j(6), n !== void 0 && typeof n != "function" && j(7);
4068
+ typeof e != "function" && B(6), n !== void 0 && typeof n != "function" && B(7);
4060
4069
  let i;
4061
- if (Jt(r)) {
4062
- const o = Jn(this), c = On(r, void 0);
4070
+ if (qt(r)) {
4071
+ const o = Zn(this), c = On(r, void 0);
4063
4072
  let u = !0;
4064
4073
  try {
4065
4074
  i = e(c), u = !1;
4066
4075
  } finally {
4067
4076
  u ? An(o) : Mn(o);
4068
4077
  }
4069
- return qn(o, n), Zn(i, o);
4078
+ return Jn(o, n), Qn(i, o);
4070
4079
  } else if (!r || typeof r != "object") {
4071
- if (i = e(r), i === void 0 && (i = r), i === zn && (i = void 0), this.autoFreeze_ && $n(i, !0), n) {
4080
+ if (i = e(r), i === void 0 && (i = r), i === $n && (i = void 0), this.autoFreeze_ && Fn(i, !0), n) {
4072
4081
  const o = [], c = [];
4073
- _e("Patches").generateReplacementPatches_(r, i, o, c), n(o, c);
4082
+ ve("Patches").generateReplacementPatches_(r, i, o, c), n(o, c);
4074
4083
  }
4075
4084
  return i;
4076
4085
  } else
4077
- j(1, r);
4086
+ B(1, r);
4078
4087
  }, this.produceWithPatches = (r, e) => {
4079
4088
  if (typeof r == "function")
4080
4089
  return (c, ...u) => this.produceWithPatches(c, (d) => r(d, ...u));
@@ -4085,15 +4094,15 @@ var $a = class {
4085
4094
  }, typeof (t == null ? void 0 : t.autoFreeze) == "boolean" && this.setAutoFreeze(t.autoFreeze), typeof (t == null ? void 0 : t.useStrictShallowCopy) == "boolean" && this.setUseStrictShallowCopy(t.useStrictShallowCopy);
4086
4095
  }
4087
4096
  createDraft(t) {
4088
- Jt(t) || j(8), ke(t) && (t = Fa(t));
4089
- const r = Jn(this), e = On(t, void 0);
4097
+ qt(t) || B(8), be(t) && (t = Fa(t));
4098
+ const r = Zn(this), e = On(t, void 0);
4090
4099
  return e[lt].isManual_ = !0, Mn(r), e;
4091
4100
  }
4092
4101
  finishDraft(t, r) {
4093
4102
  const e = t && t[lt];
4094
- (!e || !e.isManual_) && j(9);
4103
+ (!e || !e.isManual_) && B(9);
4095
4104
  const { scope_: n } = e;
4096
- return qn(n, r), Zn(void 0, n);
4105
+ return Jn(n, r), Qn(void 0, n);
4097
4106
  }
4098
4107
  /**
4099
4108
  * Pass true to automatically freeze all copies created by Immer.
@@ -4121,22 +4130,22 @@ var $a = class {
4121
4130
  }
4122
4131
  }
4123
4132
  e > -1 && (r = r.slice(e + 1));
4124
- const n = _e("Patches").applyPatches_;
4125
- return ke(t) ? n(t, r) : this.produce(
4133
+ const n = ve("Patches").applyPatches_;
4134
+ return be(t) ? n(t, r) : this.produce(
4126
4135
  t,
4127
4136
  (i) => n(i, r)
4128
4137
  );
4129
4138
  }
4130
4139
  };
4131
4140
  function On(t, r) {
4132
- const e = sr(t) ? _e("MapSet").proxyMap_(t, r) : ir(t) ? _e("MapSet").proxySet_(t, r) : Da(t, r);
4133
- return (r ? r.scope_ : zs()).drafts_.push(e), e;
4141
+ const e = Ue(t) ? ve("MapSet").proxyMap_(t, r) : sr(t) ? ve("MapSet").proxySet_(t, r) : Da(t, r);
4142
+ return (r ? r.scope_ : $s()).drafts_.push(e), e;
4134
4143
  }
4135
4144
  function Fa(t) {
4136
- return ke(t) || j(10, t), Fs(t);
4145
+ return be(t) || B(10, t), Ns(t);
4137
4146
  }
4138
- function Fs(t) {
4139
- if (!Jt(t) || Mr(t))
4147
+ function Ns(t) {
4148
+ if (!qt(t) || Mr(t))
4140
4149
  return t;
4141
4150
  const r = t[lt];
4142
4151
  let e;
@@ -4147,10 +4156,10 @@ function Fs(t) {
4147
4156
  } else
4148
4157
  e = Tn(t, !0);
4149
4158
  return Ze(e, (n, i) => {
4150
- Ds(e, n, Fs(i));
4159
+ zs(e, n, Ns(i));
4151
4160
  }), r && (r.finalized_ = !1), e;
4152
4161
  }
4153
- function ts() {
4162
+ function es() {
4154
4163
  process.env.NODE_ENV !== "production" && Rs.push(
4155
4164
  'Sets cannot have "replace" patches.',
4156
4165
  function(h) {
@@ -4267,7 +4276,7 @@ function ts() {
4267
4276
  I.push({
4268
4277
  op: r,
4269
4278
  path: [],
4270
- value: k === zn ? void 0 : k
4279
+ value: k === $n ? void 0 : k
4271
4280
  }), b.push({
4272
4281
  op: r,
4273
4282
  path: [],
@@ -4279,18 +4288,18 @@ function ts() {
4279
4288
  const { path: b, op: _ } = I;
4280
4289
  let f = h;
4281
4290
  for (let A = 0; A < b.length - 1; A++) {
4282
- const S = ve(f);
4291
+ const S = ke(f);
4283
4292
  let E = b[A];
4284
- typeof E != "string" && typeof E != "number" && (E = "" + E), (S === 0 || S === 1) && (E === "__proto__" || E === "constructor") && j(19), typeof f == "function" && E === "prototype" && j(19), f = gn(f, E), typeof f != "object" && j(18, b.join("/"));
4293
+ typeof E != "string" && typeof E != "number" && (E = "" + E), (S === 0 || S === 1) && (E === "__proto__" || E === "constructor") && B(19), typeof f == "function" && E === "prototype" && B(19), f = gn(f, E), typeof f != "object" && B(18, b.join("/"));
4285
4294
  }
4286
- const v = ve(f), T = m(I.value), w = b[b.length - 1];
4295
+ const v = ke(f), T = m(I.value), w = b[b.length - 1];
4287
4296
  switch (_) {
4288
4297
  case r:
4289
4298
  switch (v) {
4290
4299
  case 2:
4291
4300
  return f.set(w, T);
4292
4301
  case 3:
4293
- j(16);
4302
+ B(16);
4294
4303
  default:
4295
4304
  return f[w] = T;
4296
4305
  }
@@ -4317,28 +4326,28 @@ function ts() {
4317
4326
  return delete f[w];
4318
4327
  }
4319
4328
  default:
4320
- j(17, _);
4329
+ B(17, _);
4321
4330
  }
4322
4331
  }), h;
4323
4332
  }
4324
4333
  function m(h) {
4325
- if (!Jt(h))
4334
+ if (!qt(h))
4326
4335
  return h;
4327
4336
  if (Array.isArray(h))
4328
4337
  return h.map(m);
4329
- if (sr(h))
4338
+ if (Ue(h))
4330
4339
  return new Map(
4331
4340
  Array.from(h.entries()).map(([I, b]) => [I, m(b)])
4332
4341
  );
4333
- if (ir(h))
4342
+ if (sr(h))
4334
4343
  return new Set(Array.from(h).map(m));
4335
- const k = Object.create(be(h));
4344
+ const k = Object.create(Ie(h));
4336
4345
  for (const I in h)
4337
4346
  k[I] = m(h[I]);
4338
4347
  return Qe(h, Je) && (k[Je] = h[Je]), k;
4339
4348
  }
4340
4349
  function y(h) {
4341
- return ke(h) ? m(h) : h;
4350
+ return be(h) ? m(h) : h;
4342
4351
  }
4343
4352
  Ca("Patches", {
4344
4353
  applyPatches_: p,
@@ -4346,16 +4355,7 @@ function ts() {
4346
4355
  generateReplacementPatches_: d
4347
4356
  });
4348
4357
  }
4349
- var dt = new $a(), Na = dt.produce;
4350
- dt.produceWithPatches.bind(
4351
- dt
4352
- );
4353
- dt.setAutoFreeze.bind(dt);
4354
- dt.setUseStrictShallowCopy.bind(dt);
4355
- var La = dt.applyPatches.bind(dt);
4356
- dt.createDraft.bind(dt);
4357
- dt.finishDraft.bind(dt);
4358
- var Ha = 9007199254740991, Ua = "[object Arguments]", Wa = "[object Function]", Ba = "[object GeneratorFunction]", ja = "[object Symbol]", Ya = typeof ft == "object" && ft && ft.Object === Object && ft, Ga = typeof self == "object" && self && self.Object === Object && self, Xa = Ya || Ga || Function("return this")();
4358
+ var Cn = new $a(), Na = Cn.produce, La = /* @__PURE__ */ Cn.applyPatches.bind(Cn), Ha = 9007199254740991, Ua = "[object Arguments]", Wa = "[object Function]", ja = "[object GeneratorFunction]", Ba = "[object Symbol]", Ya = typeof dt == "object" && dt && dt.Object === Object && dt, Ga = typeof self == "object" && self && self.Object === Object && self, Xa = Ya || Ga || Function("return this")();
4359
4359
  function Ka(t, r, e) {
4360
4360
  switch (e.length) {
4361
4361
  case 0:
@@ -4379,7 +4379,7 @@ function qa(t, r) {
4379
4379
  t[i + e] = r[e];
4380
4380
  return t;
4381
4381
  }
4382
- var Nn = Object.prototype, Ja = Nn.hasOwnProperty, Ln = Nn.toString, es = Xa.Symbol, Za = Nn.propertyIsEnumerable, rs = es ? es.isConcatSpreadable : void 0, ns = Math.max;
4382
+ var Ln = Object.prototype, Ja = Ln.hasOwnProperty, Hn = Ln.toString, rs = Xa.Symbol, Za = Ln.propertyIsEnumerable, ns = rs ? rs.isConcatSpreadable : void 0, ss = Math.max;
4383
4383
  function Qa(t, r, e, n, i) {
4384
4384
  var o = -1, c = t.length;
4385
4385
  for (e || (e = no), i || (i = []); ++o < c; ) {
@@ -4401,8 +4401,8 @@ function eo(t, r, e) {
4401
4401
  return o;
4402
4402
  }
4403
4403
  function ro(t, r) {
4404
- return r = ns(r === void 0 ? t.length - 1 : r, 0), function() {
4405
- for (var e = arguments, n = -1, i = ns(e.length - r, 0), o = Array(i); ++n < i; )
4404
+ return r = ss(r === void 0 ? t.length - 1 : r, 0), function() {
4405
+ for (var e = arguments, n = -1, i = ss(e.length - r, 0), o = Array(i); ++n < i; )
4406
4406
  o[n] = e[r + n];
4407
4407
  n = -1;
4408
4408
  for (var c = Array(r + 1); ++n < r; )
@@ -4411,7 +4411,7 @@ function ro(t, r) {
4411
4411
  };
4412
4412
  }
4413
4413
  function no(t) {
4414
- return ao(t) || io(t) || !!(rs && t && t[rs]);
4414
+ return ao(t) || io(t) || !!(ns && t && t[ns]);
4415
4415
  }
4416
4416
  function so(t) {
4417
4417
  if (typeof t == "string" || po(t))
@@ -4420,18 +4420,18 @@ function so(t) {
4420
4420
  return r == "0" && 1 / t == -1 / 0 ? "-0" : r;
4421
4421
  }
4422
4422
  function io(t) {
4423
- return co(t) && Ja.call(t, "callee") && (!Za.call(t, "callee") || Ln.call(t) == Ua);
4423
+ return co(t) && Ja.call(t, "callee") && (!Za.call(t, "callee") || Hn.call(t) == Ua);
4424
4424
  }
4425
4425
  var ao = Array.isArray;
4426
4426
  function oo(t) {
4427
4427
  return t != null && lo(t.length) && !uo(t);
4428
4428
  }
4429
4429
  function co(t) {
4430
- return Ns(t) && oo(t);
4430
+ return Ls(t) && oo(t);
4431
4431
  }
4432
4432
  function uo(t) {
4433
- var r = fo(t) ? Ln.call(t) : "";
4434
- return r == Wa || r == Ba;
4433
+ var r = fo(t) ? Hn.call(t) : "";
4434
+ return r == Wa || r == ja;
4435
4435
  }
4436
4436
  function lo(t) {
4437
4437
  return typeof t == "number" && t > -1 && t % 1 == 0 && t <= Ha;
@@ -4440,16 +4440,16 @@ function fo(t) {
4440
4440
  var r = typeof t;
4441
4441
  return !!t && (r == "object" || r == "function");
4442
4442
  }
4443
- function Ns(t) {
4443
+ function Ls(t) {
4444
4444
  return !!t && typeof t == "object";
4445
4445
  }
4446
4446
  function po(t) {
4447
- return typeof t == "symbol" || Ns(t) && Ln.call(t) == ja;
4447
+ return typeof t == "symbol" || Ls(t) && Hn.call(t) == Ba;
4448
4448
  }
4449
4449
  var ho = ro(function(t, r) {
4450
4450
  return t == null ? {} : to(t, Va(Qa(r), so));
4451
4451
  }), mo = ho;
4452
- const ss = /* @__PURE__ */ Cn(mo), go = {
4452
+ const is = /* @__PURE__ */ Pn(mo), go = {
4453
4453
  width: 1080,
4454
4454
  height: 1920
4455
4455
  }, yo = 30, Io = {
@@ -4474,7 +4474,7 @@ const ss = /* @__PURE__ */ Cn(mo), go = {
4474
4474
  type: "color",
4475
4475
  value: "transparent"
4476
4476
  }
4477
- }, is = [
4477
+ }, as = [
4478
4478
  "tracks",
4479
4479
  "trackItemsMap",
4480
4480
  "transitionIds",
@@ -4485,29 +4485,29 @@ const ss = /* @__PURE__ */ Cn(mo), go = {
4485
4485
  class Xo {
4486
4486
  // Clean constructor with clear configuration interface
4487
4487
  constructor(r, e) {
4488
- Kt(this, "stateSubject");
4489
- Kt(this, "stateHistorySubject");
4490
- Kt(this, "prevState");
4491
- Kt(this, "background");
4492
- Kt(this, "undos", []);
4493
- Kt(this, "redos", []);
4494
- Kt(this, "listener");
4488
+ Xt(this, "stateSubject");
4489
+ Xt(this, "stateHistorySubject");
4490
+ Xt(this, "prevState");
4491
+ Xt(this, "background");
4492
+ Xt(this, "undos", []);
4493
+ Xt(this, "redos", []);
4494
+ Xt(this, "listener");
4495
4495
  const n = Object.assign(
4496
4496
  {},
4497
4497
  Io,
4498
4498
  r,
4499
4499
  e != null && e.scale ? { scale: e.scale } : {}
4500
4500
  );
4501
- this.stateSubject = new Gn(n), this.stateHistorySubject = new Gn({
4501
+ this.stateSubject = new Xn(n), this.stateHistorySubject = new Xn({
4502
4502
  handleRedo: !1,
4503
4503
  handleUndo: !1
4504
- }), this.background = n.background, this.prevState = n, (e != null && e.cors || e != null && e.acceptsMap) && Yi({
4504
+ }), this.background = n.background, this.prevState = n, (e != null && e.cors || e != null && e.acceptsMap) && Gi({
4505
4505
  cors: e.cors,
4506
4506
  acceptsMap: e.acceptsMap
4507
4507
  }), this.initListeners();
4508
4508
  }
4509
4509
  initListeners() {
4510
- Ea(this);
4510
+ Aa(this);
4511
4511
  }
4512
4512
  destroyListeners() {
4513
4513
  this.listener && this.listener.unsubscribe();
@@ -4516,7 +4516,7 @@ class Xo {
4516
4516
  this.destroyListeners();
4517
4517
  }
4518
4518
  updateHistory(r, e) {
4519
- const n = ss(r, is), i = ss(this.getState(), is), o = Cs(i, n);
4519
+ const n = is(r, as), i = is(this.getState(), as), o = Ps(i, n);
4520
4520
  o.length && (this.undos.push({ undos: o, type: e }), this.redos = []);
4521
4521
  }
4522
4522
  getStateHistory() {
@@ -4539,12 +4539,12 @@ class Xo {
4539
4539
  ...C(n),
4540
4540
  ...C(r)
4541
4541
  };
4542
- B(n, i) || (e.updateHistory && this.updateHistory(i, e.kind), this.prevState = n, this.stateSubject.next(i));
4542
+ j(n, i) || (e.updateHistory && this.updateHistory(i, e.kind), this.prevState = n, this.stateSubject.next(i));
4543
4543
  }
4544
4544
  // emit changes for design size
4545
4545
  subscribeToUpdateStateDetails(r) {
4546
4546
  return this.stateSubject.asObservable().subscribe((e) => {
4547
- (!B(e.size, this.prevState.size) || !B(e.background, this.prevState.background)) && r({
4547
+ (!j(e.size, this.prevState.size) || !j(e.background, this.prevState.background)) && r({
4548
4548
  size: e.size,
4549
4549
  background: e.background
4550
4550
  });
@@ -4553,7 +4553,7 @@ class Xo {
4553
4553
  // Selectively subscribe to scale changes
4554
4554
  subscribeToScale(r) {
4555
4555
  return this.stateSubject.asObservable().subscribe((e) => {
4556
- B(e.scale, this.prevState.scale) || r({ scale: e.scale });
4556
+ j(e.scale, this.prevState.scale) || r({ scale: e.scale });
4557
4557
  });
4558
4558
  }
4559
4559
  // Selectively subscribe to fps changes
@@ -4564,7 +4564,7 @@ class Xo {
4564
4564
  }
4565
4565
  subscribeToUpdateTrackItem(r) {
4566
4566
  return this.stateSubject.asObservable().subscribe((e) => {
4567
- B(e.trackItemsMap, this.prevState.trackItemsMap) || r({ trackItemsMap: e.trackItemsMap });
4567
+ j(e.trackItemsMap, this.prevState.trackItemsMap) || r({ trackItemsMap: e.trackItemsMap });
4568
4568
  });
4569
4569
  }
4570
4570
  subscribeToUpdateAnimations(r) {
@@ -4572,7 +4572,7 @@ class Xo {
4572
4572
  const n = Object.keys(e.trackItemsMap).filter(
4573
4573
  (i) => {
4574
4574
  const o = this.prevState.trackItemsMap[i], c = e.trackItemsMap[i];
4575
- return o && c && !B(o.animations, c.animations);
4575
+ return o && c && !j(o.animations, c.animations);
4576
4576
  }
4577
4577
  );
4578
4578
  r({ trackItemsMap: e.trackItemsMap, changedAnimationIds: n });
@@ -4580,14 +4580,14 @@ class Xo {
4580
4580
  }
4581
4581
  subscribeToUpdateTrackItemTiming(r) {
4582
4582
  return this.stateSubject.asObservable().subscribe((e) => {
4583
- if (!B(e.trackItemsMap, this.prevState.trackItemsMap)) {
4583
+ if (!j(e.trackItemsMap, this.prevState.trackItemsMap)) {
4584
4584
  const n = Object.keys(e.trackItemsMap).filter((o) => {
4585
4585
  const c = this.prevState.trackItemsMap[o], u = e.trackItemsMap[o];
4586
- return c && u && !B(c.trim, u.trim);
4586
+ return c && u && !j(c.trim, u.trim);
4587
4587
  }), i = Object.keys(e.trackItemsMap).filter(
4588
4588
  (o) => {
4589
4589
  const c = this.prevState.trackItemsMap[o], u = e.trackItemsMap[o];
4590
- return c && u && !B(c.display, u.display);
4590
+ return c && u && !j(c.display, u.display);
4591
4591
  }
4592
4592
  );
4593
4593
  r({
@@ -4602,7 +4602,7 @@ class Xo {
4602
4602
  return this.stateSubject.asObservable().subscribe((e) => {
4603
4603
  Object.keys(e.trackItemsMap).some((i) => {
4604
4604
  const o = this.prevState.trackItemsMap[i], c = e.trackItemsMap[i];
4605
- return o && c && !B(o.details, c.details);
4605
+ return o && c && !j(o.details, c.details);
4606
4606
  }) && r({ trackItemsMap: e.trackItemsMap });
4607
4607
  });
4608
4608
  }
@@ -4627,13 +4627,13 @@ class Xo {
4627
4627
  subscribeToAddOrRemoveItems(r) {
4628
4628
  return this.stateSubject.asObservable().subscribe((e) => {
4629
4629
  const n = [...e.trackItemIds].sort(), i = [...this.prevState.trackItemIds].sort(), o = [...e.transitionIds].sort(), c = [...this.prevState.transitionIds].sort();
4630
- (!B(n, i) || !B(o, c)) && r({ trackItemIds: e.trackItemIds });
4630
+ (!j(n, i) || !j(o, c)) && r({ trackItemIds: e.trackItemIds });
4631
4631
  });
4632
4632
  }
4633
4633
  // Selectively subscribe to activeIds changes
4634
4634
  subscribeToActiveIds(r) {
4635
4635
  return this.stateSubject.asObservable().subscribe((e) => {
4636
- B(e.activeIds, this.prevState.activeIds) || r({ activeIds: e.activeIds });
4636
+ j(e.activeIds, this.prevState.activeIds) || r({ activeIds: e.activeIds });
4637
4637
  });
4638
4638
  }
4639
4639
  subscribeToTracks(r) {
@@ -4650,7 +4650,7 @@ class Xo {
4650
4650
  // Selectively subscribe to multiple track-related properties
4651
4651
  subscribeToState(r) {
4652
4652
  return this.stateSubject.asObservable().subscribe((e) => {
4653
- (!B(e.tracks, this.prevState.tracks) || !B(e.trackItemIds, this.prevState.trackItemIds) || !B(e.trackItemsMap, this.prevState.trackItemsMap) || !B(e.transitionIds, this.prevState.transitionIds) || !B(e.transitionsMap, this.prevState.transitionsMap) || !B(e.structure, this.prevState.structure)) && r({
4653
+ (!j(e.tracks, this.prevState.tracks) || !j(e.trackItemIds, this.prevState.trackItemIds) || !j(e.trackItemsMap, this.prevState.trackItemsMap) || !j(e.transitionIds, this.prevState.transitionIds) || !j(e.transitionsMap, this.prevState.transitionsMap) || !j(e.structure, this.prevState.structure)) && r({
4654
4654
  tracks: e.tracks,
4655
4655
  trackItemIds: e.trackItemIds,
4656
4656
  trackItemsMap: e.trackItemsMap,
@@ -4663,7 +4663,7 @@ class Xo {
4663
4663
  undo() {
4664
4664
  const r = this.undos.pop(), e = r == null ? void 0 : r.undos, n = r == null ? void 0 : r.type;
4665
4665
  if (!e || !n) return;
4666
- ts();
4666
+ es();
4667
4667
  const {
4668
4668
  trackItemIds: i,
4669
4669
  tracks: o,
@@ -4721,10 +4721,10 @@ class Xo {
4721
4721
  transitionsMap: w,
4722
4722
  trackItemsMap: A,
4723
4723
  structure: S
4724
- }), L = C(this.getState()), R = { ...L, ...E };
4724
+ }), L = C(this.getState()), P = { ...L, ...E };
4725
4725
  this.prevState = L, this.redos.push({ redos: e, type: n });
4726
- const Y = G(R.trackItemsMap);
4727
- this.stateSubject.next({ ...R, duration: Y }), this.stateHistorySubject.next({ handleRedo: !1, handleUndo: !0 }), this.updateState(R, { updateHistory: !1 });
4726
+ const Y = G(P.trackItemsMap);
4727
+ this.stateSubject.next({ ...P, duration: Y }), this.stateHistorySubject.next({ handleRedo: !1, handleUndo: !0 }), this.updateState(P, { updateHistory: !1 });
4728
4728
  }
4729
4729
  applyPatch(r, e) {
4730
4730
  return e.reverse().reduce((n, i) => Na(n, (o) => {
@@ -4734,7 +4734,7 @@ class Xo {
4734
4734
  redo() {
4735
4735
  const r = this.redos.pop(), e = r == null ? void 0 : r.redos, n = r == null ? void 0 : r.type;
4736
4736
  if (!e || !n) return;
4737
- ts();
4737
+ es();
4738
4738
  const {
4739
4739
  trackItemIds: i,
4740
4740
  tracks: o,
@@ -4792,10 +4792,10 @@ class Xo {
4792
4792
  transitionsMap: w,
4793
4793
  trackItemsMap: A,
4794
4794
  structure: S
4795
- }), L = C(this.getState()), R = { ...L, ...E };
4795
+ }), L = C(this.getState()), P = { ...L, ...E };
4796
4796
  this.prevState = L, this.undos.push({ undos: e, type: n });
4797
- const Y = G(R.trackItemsMap);
4798
- this.stateSubject.next({ ...R, duration: Y }), this.stateHistorySubject.next({ handleRedo: !0, handleUndo: !1 }), this.updateState(R, { updateHistory: !1 });
4797
+ const Y = G(P.trackItemsMap);
4798
+ this.stateSubject.next({ ...P, duration: Y }), this.stateHistorySubject.next({ handleRedo: !0, handleUndo: !1 }), this.updateState(P, { updateHistory: !1 });
4799
4799
  }
4800
4800
  toJSON() {
4801
4801
  const {
@@ -4821,76 +4821,76 @@ class Xo {
4821
4821
  export {
4822
4822
  zo as ACTIVE_CLONE,
4823
4823
  Do as ACTIVE_DELETE,
4824
- xi as ACTIVE_PASTE,
4825
- Le as ACTIVE_PREFIX,
4826
- Po as ACTIVE_SET,
4827
- Oi as ACTIVE_SPLIT,
4828
- pi as ADD_ANIMATION,
4829
- ui as ADD_AUDIO,
4830
- hi as ADD_CAPTIONS,
4831
- yi as ADD_COMPOSITION,
4832
- wi as ADD_HILL_AUDIO_BARS,
4833
- di as ADD_ILLUSTRATION,
4834
- li as ADD_IMAGE,
4835
- gi as ADD_ITEMS,
4836
- vi as ADD_LINEAL_AUDIO_BARS,
4824
+ Oi as ACTIVE_PASTE,
4825
+ Ne as ACTIVE_PREFIX,
4826
+ Ro as ACTIVE_SET,
4827
+ Ci as ACTIVE_SPLIT,
4828
+ hi as ADD_ANIMATION,
4829
+ li as ADD_AUDIO,
4830
+ mi as ADD_CAPTIONS,
4831
+ Ii as ADD_COMPOSITION,
4832
+ Ti as ADD_HILL_AUDIO_BARS,
4833
+ fi as ADD_ILLUSTRATION,
4834
+ di as ADD_IMAGE,
4835
+ yi as ADD_ITEMS,
4836
+ _i as ADD_LINEAL_AUDIO_BARS,
4837
4837
  Eo as ADD_MASK,
4838
4838
  To as ADD_PLACEHOLDER,
4839
4839
  H as ADD_PREFIX,
4840
- Ii as ADD_PROGRESS_BAR,
4841
- bi as ADD_PROGRESS_FRAME,
4842
- _i as ADD_PROGRESS_SQUARE,
4843
- ki as ADD_RADIAL_AUDIO_BARS,
4844
- Ti as ADD_RECT,
4845
- fi as ADD_SHAPE,
4840
+ bi as ADD_PROGRESS_BAR,
4841
+ ki as ADD_PROGRESS_FRAME,
4842
+ Si as ADD_PROGRESS_SQUARE,
4843
+ vi as ADD_RADIAL_AUDIO_BARS,
4844
+ Ei as ADD_RECT,
4845
+ pi as ADD_SHAPE,
4846
4846
  vo as ADD_SUFFIX,
4847
- mi as ADD_TEMPLATE,
4848
- oi as ADD_TEXT,
4847
+ gi as ADD_TEMPLATE,
4848
+ ci as ADD_TEXT,
4849
4849
  Ao as ADD_TRANSITION,
4850
- ci as ADD_VIDEO,
4851
- Si as ADD_WAVE_AUDIO_BARS,
4852
- si as BULK_PREFIX,
4850
+ ui as ADD_VIDEO,
4851
+ wi as ADD_WAVE_AUDIO_BARS,
4852
+ ii as BULK_PREFIX,
4853
4853
  Co as DELETE_TEMPLATE_ITEM,
4854
- ii as DESIGN_LOAD,
4854
+ ai as DESIGN_LOAD,
4855
4855
  Rn as DESIGN_PREFIX,
4856
- ai as DESIGN_RESIZE,
4857
- Mi as EDIT_BACKGROUND_EDITOR,
4858
- Xn as EDIT_BULK,
4859
- Ei as EDIT_OBJECT,
4860
- Zt as EDIT_PREFIX,
4856
+ oi as DESIGN_RESIZE,
4857
+ xi as EDIT_BACKGROUND_EDITOR,
4858
+ Kn as EDIT_BULK,
4859
+ Ai as EDIT_OBJECT,
4860
+ Jt as EDIT_PREFIX,
4861
4861
  xo as EDIT_SHAPE,
4862
4862
  Oo as EDIT_TEMPLATE_ITEM,
4863
4863
  Mo as EDIT_TEXT,
4864
- Ro as ENTER_EDIT_MODE,
4864
+ Po as ENTER_EDIT_MODE,
4865
4865
  Ar as HISTORY_PREFIX,
4866
- Fi as HISTORY_REDO,
4866
+ Ni as HISTORY_REDO,
4867
4867
  Go as HISTORY_RESET,
4868
- $i as HISTORY_UNDO,
4869
- Pi as LAYER_CLONE,
4868
+ Fi as HISTORY_UNDO,
4869
+ Di as LAYER_CLONE,
4870
4870
  Ri as LAYER_COPY,
4871
4871
  Yo as LAYER_CUT,
4872
- Di as LAYER_DELETE,
4872
+ zi as LAYER_DELETE,
4873
4873
  Wo as LAYER_EDITING_NAME,
4874
4874
  Fo as LAYER_HIDDEN,
4875
4875
  $o as LAYER_LOCKED,
4876
4876
  No as LAYER_MOVE,
4877
- Bo as LAYER_PASTE,
4877
+ jo as LAYER_PASTE,
4878
4878
  Q as LAYER_PREFIX,
4879
4879
  Uo as LAYER_RENAME,
4880
- zi as LAYER_REPLACE,
4881
- Ci as LAYER_SELECT,
4880
+ $i as LAYER_REPLACE,
4881
+ Pi as LAYER_SELECT,
4882
4882
  Lo as LAYER_SELECTION,
4883
4883
  Ho as LAYER_SEND_TO,
4884
- jo as LAYER_SPLIT,
4885
- Ai as REPLACE_MEDIA,
4884
+ Bo as LAYER_SPLIT,
4885
+ Mi as REPLACE_MEDIA,
4886
4886
  wo as STATE_CHANGED,
4887
- ni as STATE_PREFIX,
4888
- Ni as TIMELINE_SCALE_CHANGED,
4889
- ds as TIMELINE_SCALE_PREFIX,
4887
+ si as STATE_PREFIX,
4888
+ Li as TIMELINE_SCALE_CHANGED,
4889
+ fs as TIMELINE_SCALE_PREFIX,
4890
4890
  _o as TRACKS_CHANGED,
4891
4891
  So as TRACK_ITEMS_CHANGED,
4892
- ri as TRACK_ITEMS_PREFIX,
4893
- ei as TRACK_PREFIX,
4892
+ ni as TRACK_ITEMS_PREFIX,
4893
+ ri as TRACK_PREFIX,
4894
4894
  Xo as default,
4895
- Gi as getAcceptsMap
4895
+ Xi as getAcceptsMap
4896
4896
  };