@osamash/floor-planner 1.0.5 → 1.0.6

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.
@@ -1,7 +1,7 @@
1
1
  var k0 = Object.defineProperty;
2
2
  var I0 = (n, t, e) => t in n ? k0(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e;
3
3
  var kt = (n, t, e) => I0(n, typeof t != "symbol" ? t + "" : t, e);
4
- import X, { useRef as jn, useEffect as Vn, useState as re, useMemo as P0, useCallback as R0 } from "react";
4
+ import X, { useRef as Vn, useEffect as wn, useState as ee, useMemo as P0, useCallback as R0 } from "react";
5
5
  function mo(n) {
6
6
  return n && n.__esModule && Object.prototype.hasOwnProperty.call(n, "default") ? n.default : n;
7
7
  }
@@ -83,7 +83,7 @@ function N0() {
83
83
  return "StrictMode";
84
84
  case M:
85
85
  return "Suspense";
86
- case z:
86
+ case O:
87
87
  return "SuspenseList";
88
88
  case L:
89
89
  return "Activity";
@@ -94,11 +94,11 @@ function N0() {
94
94
  ), k.$$typeof) {
95
95
  case m:
96
96
  return "Portal";
97
- case C:
97
+ case T:
98
98
  return (k.displayName || "Context") + ".Provider";
99
99
  case A:
100
100
  return (k._context.displayName || "Context") + ".Consumer";
101
- case O:
101
+ case C:
102
102
  var F = k.render;
103
103
  return k = k.displayName, k || (k = F.displayName || F.name || "", k = k !== "" ? "ForwardRef(" + k + ")" : "ForwardRef"), k;
104
104
  case R:
@@ -260,7 +260,7 @@ React keys must be passed directly to JSX without using spread:
260
260
  function f(k) {
261
261
  typeof k == "object" && k !== null && k.$$typeof === p && k._store && (k._store.validated = 1);
262
262
  }
263
- var g = X, p = Symbol.for("react.transitional.element"), m = Symbol.for("react.portal"), v = Symbol.for("react.fragment"), _ = Symbol.for("react.strict_mode"), S = Symbol.for("react.profiler"), A = Symbol.for("react.consumer"), C = Symbol.for("react.context"), O = Symbol.for("react.forward_ref"), M = Symbol.for("react.suspense"), z = Symbol.for("react.suspense_list"), R = Symbol.for("react.memo"), I = Symbol.for("react.lazy"), L = Symbol.for("react.activity"), U = Symbol.for("react.client.reference"), Y = g.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, it = Object.prototype.hasOwnProperty, rt = Array.isArray, yt = console.createTask ? console.createTask : function() {
263
+ var g = X, p = Symbol.for("react.transitional.element"), m = Symbol.for("react.portal"), v = Symbol.for("react.fragment"), _ = Symbol.for("react.strict_mode"), S = Symbol.for("react.profiler"), A = Symbol.for("react.consumer"), T = Symbol.for("react.context"), C = Symbol.for("react.forward_ref"), M = Symbol.for("react.suspense"), O = Symbol.for("react.suspense_list"), R = Symbol.for("react.memo"), I = Symbol.for("react.lazy"), L = Symbol.for("react.activity"), U = Symbol.for("react.client.reference"), Y = g.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, it = Object.prototype.hasOwnProperty, rt = Array.isArray, yt = console.createTask ? console.createTask : function() {
264
264
  return null;
265
265
  };
266
266
  g = {
@@ -462,7 +462,7 @@ It.prototype.inspect = It.prototype.toSource = function() {
462
462
  It.prototype[tu] = function() {
463
463
  return this;
464
464
  };
465
- function Xt(n, t, e, r) {
465
+ function Jt(n, t, e, r) {
466
466
  var i = n === hs ? t : n === er ? e : [t, e];
467
467
  return r ? r.value = i : r = {
468
468
  value: i,
@@ -539,7 +539,7 @@ var me = /* @__PURE__ */ (function(n) {
539
539
  if (a === o)
540
540
  return ze();
541
541
  var l = s[i ? o - ++a : a++];
542
- return Xt(r, l[0], l[1]);
542
+ return Jt(r, l[0], l[1]);
543
543
  });
544
544
  }
545
545
  return this.__iteratorUncached(r, i);
@@ -596,7 +596,7 @@ var Xi = /* @__PURE__ */ (function(n) {
596
596
  if (a === o)
597
597
  return ze();
598
598
  var l = i ? o - ++a : a++;
599
- return Xt(r, l, s[l]);
599
+ return Jt(r, l, s[l]);
600
600
  });
601
601
  }, t;
602
602
  })(yr), Dc = /* @__PURE__ */ (function(n) {
@@ -623,7 +623,7 @@ var Xi = /* @__PURE__ */ (function(n) {
623
623
  if (l === a)
624
624
  return ze();
625
625
  var c = o[i ? a - ++l : l++];
626
- return Xt(r, c, s[c]);
626
+ return Jt(r, c, s[c]);
627
627
  });
628
628
  }, t;
629
629
  })(Hn);
@@ -649,7 +649,7 @@ var H0 = /* @__PURE__ */ (function(n) {
649
649
  var a = 0;
650
650
  return new It(function() {
651
651
  var l = o.next();
652
- return l.done ? l : Xt(r, a++, l.value);
652
+ return l.done ? l : Jt(r, a++, l.value);
653
653
  });
654
654
  }, t;
655
655
  })(yr), Vf;
@@ -880,7 +880,7 @@ var Bg = /* @__PURE__ */ (function(n) {
880
880
  var s = this, o = this._iter.__iterator(er, i), a = 0;
881
881
  return i && Yi(this), new It(function() {
882
882
  var l = o.next();
883
- return l.done ? l : Xt(
883
+ return l.done ? l : Jt(
884
884
  r,
885
885
  i ? s.size - ++a : a++,
886
886
  l.value,
@@ -903,7 +903,7 @@ var Bg = /* @__PURE__ */ (function(n) {
903
903
  var s = this._iter.__iterator(er, i);
904
904
  return new It(function() {
905
905
  var o = s.next();
906
- return o.done ? o : Xt(r, o.value, o.value, o);
906
+ return o.done ? o : Jt(r, o.value, o.value, o);
907
907
  });
908
908
  }, t;
909
909
  })(ds), $g = /* @__PURE__ */ (function(n) {
@@ -936,7 +936,7 @@ var Bg = /* @__PURE__ */ (function(n) {
936
936
  if (a) {
937
937
  Gf(a);
938
938
  var l = De(a);
939
- return Xt(
939
+ return Jt(
940
940
  r,
941
941
  l ? a.get(0) : a[0],
942
942
  l ? a.get(1) : a[1],
@@ -1006,7 +1006,7 @@ function Gg(n, t, e) {
1006
1006
  if (a.done)
1007
1007
  return a;
1008
1008
  var l = a.value, c = l[0];
1009
- return Xt(
1009
+ return Jt(
1010
1010
  i,
1011
1011
  c,
1012
1012
  t.call(e, l[1], c, n),
@@ -1047,7 +1047,7 @@ function Gc(n, t) {
1047
1047
  if (l.done)
1048
1048
  return l;
1049
1049
  var c = l.value;
1050
- return Xt(
1050
+ return Jt(
1051
1051
  i,
1052
1052
  t ? c[0] : s ? e.size - ++o : o++,
1053
1053
  c[1],
@@ -1079,7 +1079,7 @@ function Wg(n, t, e, r) {
1079
1079
  return c;
1080
1080
  var h = c.value, f = h[0], g = h[1];
1081
1081
  if (t.call(e, g, f, n))
1082
- return Xt(s, r ? f : l++, g, c);
1082
+ return Jt(s, r ? f : l++, g, c);
1083
1083
  }
1084
1084
  });
1085
1085
  }, i;
@@ -1153,7 +1153,7 @@ function Wc(n, t, e, r) {
1153
1153
  if (++m > l)
1154
1154
  return ze();
1155
1155
  var v = g.next();
1156
- return r || h === er || v.done ? v : h === hs ? Xt(h, m - 1, void 0, v) : Xt(h, m - 1, v.value[1], v);
1156
+ return r || h === er || v.done ? v : h === hs ? Jt(h, m - 1, void 0, v) : Jt(h, m - 1, v.value[1], v);
1157
1157
  });
1158
1158
  }, c;
1159
1159
  }
@@ -1181,7 +1181,7 @@ function iv(n, t, e) {
1181
1181
  if (c.done)
1182
1182
  return c;
1183
1183
  var h = c.value, f = h[0], g = h[1];
1184
- return t.call(e, g, f, o) ? i === rr ? c : Xt(i, f, g, c) : (l = !1, ze());
1184
+ return t.call(e, g, f, o) ? i === rr ? c : Jt(i, f, g, c) : (l = !1, ze());
1185
1185
  });
1186
1186
  }, r;
1187
1187
  }
@@ -1205,11 +1205,11 @@ function Ug(n, t, e, r) {
1205
1205
  var f, g, p;
1206
1206
  do {
1207
1207
  if (f = l.next(), f.done)
1208
- return r || s === er ? f : s === hs ? Xt(s, h++, void 0, f) : Xt(s, h++, f.value[1], f);
1208
+ return r || s === er ? f : s === hs ? Jt(s, h++, void 0, f) : Jt(s, h++, f.value[1], f);
1209
1209
  var m = f.value;
1210
1210
  g = m[0], p = m[1], c && (c = t.call(e, p, g, a));
1211
1211
  } while (c);
1212
- return s === rr ? f : Xt(s, g, p, f);
1212
+ return s === rr ? f : Jt(s, g, p, f);
1213
1213
  });
1214
1214
  }, i;
1215
1215
  }
@@ -1311,7 +1311,7 @@ function Yg(n, t, e) {
1311
1311
  if (i === rr && (h = h[1]), (!t || a.length < t) && De(h))
1312
1312
  a.push(o), o = h.__iterator(i, s);
1313
1313
  else
1314
- return e ? c : Xt(i, l++, h, c);
1314
+ return e ? c : Jt(i, l++, h, c);
1315
1315
  }
1316
1316
  return ze();
1317
1317
  });
@@ -1336,7 +1336,7 @@ function uv(n, t) {
1336
1336
  }, e.__iteratorUncached = function(r, i) {
1337
1337
  var s = n.__iterator(er, i), o = 0, a;
1338
1338
  return new It(function() {
1339
- return (!a || o % 2) && (a = s.next(), a.done) ? a : o % 2 ? Xt(r, o++, t) : Xt(r, o++, a.value, a);
1339
+ return (!a || o % 2) && (a = s.next(), a.done) ? a : o % 2 ? Jt(r, o++, t) : Jt(r, o++, a.value, a);
1340
1340
  });
1341
1341
  }, e;
1342
1342
  }
@@ -1394,7 +1394,7 @@ function Go(n, t, e, r) {
1394
1394
  return g.done;
1395
1395
  }) : f.some(function(g) {
1396
1396
  return g.done;
1397
- })), h ? ze() : Xt(
1397
+ })), h ? ze() : Jt(
1398
1398
  o,
1399
1399
  c++,
1400
1400
  t.apply(
@@ -1750,28 +1750,28 @@ var Z = /* @__PURE__ */ (function(n) {
1750
1750
  }, t;
1751
1751
  })(gr);
1752
1752
  Z.isMap = ru;
1753
- var Jt = Z.prototype;
1754
- Jt[Vg] = !0;
1755
- Jt[yo] = Jt.remove;
1756
- Jt.removeAll = Jt.deleteAll;
1757
- Jt.setIn = Zc;
1758
- Jt.removeIn = Jt.deleteIn = Kc;
1759
- Jt.update = th;
1760
- Jt.updateIn = eh;
1761
- Jt.merge = Jt.concat = nm;
1762
- Jt.mergeWith = im;
1763
- Jt.mergeDeep = om;
1764
- Jt.mergeDeepWith = am;
1765
- Jt.mergeIn = rh;
1766
- Jt.mergeDeepIn = nh;
1767
- Jt.withMutations = wo;
1768
- Jt.wasAltered = ih;
1769
- Jt.asImmutable = Mo;
1770
- Jt["@@transducer/init"] = Jt.asMutable = So;
1771
- Jt["@@transducer/step"] = function(n, t) {
1753
+ var Zt = Z.prototype;
1754
+ Zt[Vg] = !0;
1755
+ Zt[yo] = Zt.remove;
1756
+ Zt.removeAll = Zt.deleteAll;
1757
+ Zt.setIn = Zc;
1758
+ Zt.removeIn = Zt.deleteIn = Kc;
1759
+ Zt.update = th;
1760
+ Zt.updateIn = eh;
1761
+ Zt.merge = Zt.concat = nm;
1762
+ Zt.mergeWith = im;
1763
+ Zt.mergeDeep = om;
1764
+ Zt.mergeDeepWith = am;
1765
+ Zt.mergeIn = rh;
1766
+ Zt.mergeDeepIn = nh;
1767
+ Zt.withMutations = wo;
1768
+ Zt.wasAltered = ih;
1769
+ Zt.asImmutable = Mo;
1770
+ Zt["@@transducer/init"] = Zt.asMutable = So;
1771
+ Zt["@@transducer/step"] = function(n, t) {
1772
1772
  return n.set(t[0], t[1]);
1773
1773
  };
1774
- Jt["@@transducer/result"] = function(n) {
1774
+ Zt["@@transducer/result"] = function(n) {
1775
1775
  return n.asImmutable();
1776
1776
  };
1777
1777
  var uo = function(t, e) {
@@ -1888,17 +1888,17 @@ Ki.prototype.update = function(t, e, r, i, s, o, a) {
1888
1888
  if (g ? c[h][1] === s : l)
1889
1889
  return this;
1890
1890
  if (cr(a), (l || !g) && cr(o), l && f === 2)
1891
- return new wn(t, this.keyHash, c[h ^ 1]);
1891
+ return new Sn(t, this.keyHash, c[h ^ 1]);
1892
1892
  var p = t && t === this.ownerID, m = p ? c : Ur(c);
1893
1893
  return g ? l ? h === f - 1 ? m.pop() : m[h] = m.pop() : m[h] = [i, s] : m.push([i, s]), p ? (this.entries = m, this) : new Ki(t, this.keyHash, m);
1894
1894
  };
1895
- var wn = function(t, e, r) {
1895
+ var Sn = function(t, e, r) {
1896
1896
  this.ownerID = t, this.keyHash = e, this.entry = r;
1897
1897
  };
1898
- wn.prototype.get = function(t, e, r, i) {
1898
+ Sn.prototype.get = function(t, e, r, i) {
1899
1899
  return _e(r, this.entry[0]) ? this.entry[1] : i;
1900
1900
  };
1901
- wn.prototype.update = function(t, e, r, i, s, o, a) {
1901
+ Sn.prototype.update = function(t, e, r, i, s, o, a) {
1902
1902
  var l = s === Tt, c = _e(i, this.entry[0]);
1903
1903
  if (c ? s === this.entry[1] : l)
1904
1904
  return this;
@@ -1906,7 +1906,7 @@ wn.prototype.update = function(t, e, r, i, s, o, a) {
1906
1906
  cr(o);
1907
1907
  return;
1908
1908
  }
1909
- return c ? t && t === this.ownerID ? (this.entry[1] = s, this) : new wn(t, this.keyHash, [i, s]) : (cr(o), ah(this, t, e, je(i), [i, s]));
1909
+ return c ? t && t === this.ownerID ? (this.entry[1] = s, this) : new Sn(t, this.keyHash, [i, s]) : (cr(o), ah(this, t, e, je(i), [i, s]));
1910
1910
  };
1911
1911
  uo.prototype.iterate = Ki.prototype.iterate = function(n, t) {
1912
1912
  for (var e = this.entries, r = 0, i = e.length - 1; r <= i; r++)
@@ -1920,7 +1920,7 @@ Zi.prototype.iterate = lo.prototype.iterate = function(n, t) {
1920
1920
  return !1;
1921
1921
  }
1922
1922
  };
1923
- wn.prototype.iterate = function(n, t) {
1923
+ Sn.prototype.iterate = function(n, t) {
1924
1924
  return n(this.entry);
1925
1925
  };
1926
1926
  var mv = /* @__PURE__ */ (function(n) {
@@ -1954,7 +1954,7 @@ var mv = /* @__PURE__ */ (function(n) {
1954
1954
  }, t;
1955
1955
  })(It);
1956
1956
  function Wu(n, t) {
1957
- return Xt(n, t[0], t[1]);
1957
+ return Jt(n, t[0], t[1]);
1958
1958
  }
1959
1959
  function Wf(n, t) {
1960
1960
  return {
@@ -1964,7 +1964,7 @@ function Wf(n, t) {
1964
1964
  };
1965
1965
  }
1966
1966
  function sh(n, t, e, r) {
1967
- var i = Object.create(Jt);
1967
+ var i = Object.create(Zt);
1968
1968
  return i.size = n, i._root = t, i.__ownerID = e, i.__hash = r, i.__altered = !1, i;
1969
1969
  }
1970
1970
  var Uf;
@@ -2003,20 +2003,20 @@ function oh(n, t, e, r, i, s, o, a) {
2003
2003
  s,
2004
2004
  o,
2005
2005
  a
2006
- ) : s === Tt ? n : (cr(a), cr(o), new wn(t, r, [i, s]));
2006
+ ) : s === Tt ? n : (cr(a), cr(o), new Sn(t, r, [i, s]));
2007
2007
  }
2008
2008
  function Xf(n) {
2009
- return n.constructor === wn || n.constructor === Ki;
2009
+ return n.constructor === Sn || n.constructor === Ki;
2010
2010
  }
2011
2011
  function ah(n, t, e, r, i) {
2012
2012
  if (n.keyHash === r)
2013
2013
  return new Ki(t, r, [n.entry, i]);
2014
- var s = (e === 0 ? n.keyHash : n.keyHash >>> e) & Pe, o = (e === 0 ? r : r >>> e) & Pe, a, l = s === o ? [ah(n, t, e + $t, r, i)] : (a = new wn(t, r, i), s < o ? [n, a] : [a, n]);
2014
+ var s = (e === 0 ? n.keyHash : n.keyHash >>> e) & Pe, o = (e === 0 ? r : r >>> e) & Pe, a, l = s === o ? [ah(n, t, e + $t, r, i)] : (a = new Sn(t, r, i), s < o ? [n, a] : [a, n]);
2015
2015
  return new Zi(t, 1 << s | 1 << o, l);
2016
2016
  }
2017
2017
  function yv(n, t, e, r) {
2018
2018
  n || (n = new Fc());
2019
- for (var i = new wn(n, je(e), [e, r]), s = 0; s < t.length; s++) {
2019
+ for (var i = new Sn(n, je(e), [e, r]), s = 0; s < t.length; s++) {
2020
2020
  var o = t[s];
2021
2021
  i = i.update(n, 0, void 0, o[0], o[1]);
2022
2022
  }
@@ -2070,7 +2070,7 @@ var st = /* @__PURE__ */ (function(n) {
2070
2070
  if (uh(e))
2071
2071
  return e;
2072
2072
  var i = n(e), s = i.size;
2073
- return s === 0 ? r : (Xe(s), s > 0 && s < Je ? co(0, s, $t, null, new Nn(i.toArray())) : r.withMutations(function(o) {
2073
+ return s === 0 ? r : (Xe(s), s > 0 && s < Je ? co(0, s, $t, null, new Fn(i.toArray())) : r.withMutations(function(o) {
2074
2074
  o.setSize(s), i.forEach(function(a, l) {
2075
2075
  return o.set(l, a);
2076
2076
  });
@@ -2098,21 +2098,21 @@ var st = /* @__PURE__ */ (function(n) {
2098
2098
  }, t.prototype.push = function() {
2099
2099
  var r = arguments, i = this.size;
2100
2100
  return this.withMutations(function(s) {
2101
- Ln(s, 0, i + r.length);
2101
+ Nn(s, 0, i + r.length);
2102
2102
  for (var o = 0; o < r.length; o++)
2103
2103
  s.set(i + o, r[o]);
2104
2104
  });
2105
2105
  }, t.prototype.pop = function() {
2106
- return Ln(this, 0, -1);
2106
+ return Nn(this, 0, -1);
2107
2107
  }, t.prototype.unshift = function() {
2108
2108
  var r = arguments;
2109
2109
  return this.withMutations(function(i) {
2110
- Ln(i, -r.length);
2110
+ Nn(i, -r.length);
2111
2111
  for (var s = 0; s < r.length; s++)
2112
2112
  i.set(s, r[s]);
2113
2113
  });
2114
2114
  }, t.prototype.shift = function() {
2115
- return Ln(this, 1);
2115
+ return Nn(this, 1);
2116
2116
  }, t.prototype.shuffle = function(r) {
2117
2117
  return r === void 0 && (r = Math.random), this.withMutations(function(i) {
2118
2118
  for (var s = i.size, o, a; s; )
@@ -2133,7 +2133,7 @@ var st = /* @__PURE__ */ (function(n) {
2133
2133
  });
2134
2134
  });
2135
2135
  }, t.prototype.setSize = function(r) {
2136
- return Ln(this, 0, r);
2136
+ return Nn(this, 0, r);
2137
2137
  }, t.prototype.map = function(r, i) {
2138
2138
  var s = this;
2139
2139
  return this.withMutations(function(o) {
@@ -2142,7 +2142,7 @@ var st = /* @__PURE__ */ (function(n) {
2142
2142
  });
2143
2143
  }, t.prototype.slice = function(r, i) {
2144
2144
  var s = this.size;
2145
- return vo(r, i, s) ? this : Ln(
2145
+ return vo(r, i, s) ? this : Nn(
2146
2146
  this,
2147
2147
  ls(r, s),
2148
2148
  xo(i, s)
@@ -2151,7 +2151,7 @@ var st = /* @__PURE__ */ (function(n) {
2151
2151
  var s = i ? this.size : 0, o = Jf(this, i);
2152
2152
  return new It(function() {
2153
2153
  var a = o();
2154
- return a === eo ? ze() : Xt(r, i ? --s : s++, a);
2154
+ return a === eo ? ze() : Jt(r, i ? --s : s++, a);
2155
2155
  });
2156
2156
  }, t.prototype.__iterate = function(r, i) {
2157
2157
  for (var s = i ? this.size : 0, o = Jf(this, i), a; (a = o()) !== eo && r(a, i ? --s : s++, this) !== !1; )
@@ -2190,15 +2190,15 @@ de["@@transducer/step"] = function(n, t) {
2190
2190
  de["@@transducer/result"] = function(n) {
2191
2191
  return n.asImmutable();
2192
2192
  };
2193
- var Nn = function(t, e) {
2193
+ var Fn = function(t, e) {
2194
2194
  this.array = t, this.ownerID = e;
2195
2195
  };
2196
- Nn.prototype.removeBefore = function(t, e, r) {
2196
+ Fn.prototype.removeBefore = function(t, e, r) {
2197
2197
  if ((r & (1 << e + $t) - 1) === 0 || this.array.length === 0)
2198
2198
  return this;
2199
2199
  var i = r >>> e & Pe;
2200
2200
  if (i >= this.array.length)
2201
- return new Nn([], t);
2201
+ return new Fn([], t);
2202
2202
  var s = i === 0, o;
2203
2203
  if (e > 0) {
2204
2204
  var a = this.array[i];
@@ -2213,7 +2213,7 @@ Nn.prototype.removeBefore = function(t, e, r) {
2213
2213
  l.array[c] = void 0;
2214
2214
  return o && (l.array[i] = o), l;
2215
2215
  };
2216
- Nn.prototype.removeAfter = function(t, e, r) {
2216
+ Fn.prototype.removeAfter = function(t, e, r) {
2217
2217
  if (r === (e ? 1 << e + $t : Je) || this.array.length === 0)
2218
2218
  return this;
2219
2219
  var i = r - 1 >>> e & Pe;
@@ -2278,7 +2278,7 @@ function Ev(n, t, e) {
2278
2278
  return n;
2279
2279
  if (t >= n.size || t < 0)
2280
2280
  return n.withMutations(function(o) {
2281
- t < 0 ? Ln(o, t).set(0, e) : Ln(o, 0, t + 1).set(t, e);
2281
+ t < 0 ? Nn(o, t).set(0, e) : Nn(o, 0, t + 1).set(t, e);
2282
2282
  });
2283
2283
  t += n._origin;
2284
2284
  var r = n._tail, i = n._root, s = lc();
@@ -2310,7 +2310,7 @@ function mc(n, t, e, r, i, s) {
2310
2310
  return a && n.array[o] === i ? n : (s && cr(s), l = Qi(n, t), i === void 0 && o === l.array.length - 1 ? l.array.pop() : l.array[o] = i, l);
2311
2311
  }
2312
2312
  function Qi(n, t) {
2313
- return t && n && t === n.ownerID ? n : new Nn(n ? n.array.slice() : [], t);
2313
+ return t && n && t === n.ownerID ? n : new Fn(n ? n.array.slice() : [], t);
2314
2314
  }
2315
2315
  function hm(n, t) {
2316
2316
  if (t >= ho(n._capacity))
@@ -2321,7 +2321,7 @@ function hm(n, t) {
2321
2321
  return e;
2322
2322
  }
2323
2323
  }
2324
- function Ln(n, t, e) {
2324
+ function Nn(n, t, e) {
2325
2325
  t !== void 0 && (t |= 0), e !== void 0 && (e |= 0);
2326
2326
  var r = n.__ownerID || new Fc(), i = n._origin, s = n._capacity, o = i + t, a = e === void 0 ? s : e < 0 ? s + e : i + e;
2327
2327
  if (o === i && a === s)
@@ -2329,17 +2329,17 @@ function Ln(n, t, e) {
2329
2329
  if (o >= a)
2330
2330
  return n.clear();
2331
2331
  for (var l = n._level, c = n._root, h = 0; o + h < 0; )
2332
- c = new Nn(
2332
+ c = new Fn(
2333
2333
  c && c.array.length ? [void 0, c] : [],
2334
2334
  r
2335
2335
  ), l += $t, h += 1 << l;
2336
2336
  h && (o += h, i += h, a += h, s += h);
2337
2337
  for (var f = ho(s), g = ho(a); g >= 1 << l + $t; )
2338
- c = new Nn(
2338
+ c = new Fn(
2339
2339
  c && c.array.length ? [c] : [],
2340
2340
  r
2341
2341
  ), l += $t;
2342
- var p = n._tail, m = g < f ? hm(n, a - 1) : g > f ? new Nn([], r) : p;
2342
+ var p = n._tail, m = g < f ? hm(n, a - 1) : g > f ? new Fn([], r) : p;
2343
2343
  if (p && g > f && o < s && p.array.length) {
2344
2344
  c = Qi(c, r);
2345
2345
  for (var v = c, _ = l; _ > $t; _ -= $t) {
@@ -2517,7 +2517,7 @@ var su = /* @__PURE__ */ (function(n) {
2517
2517
  return new It(function() {
2518
2518
  if (o) {
2519
2519
  var a = o.value;
2520
- return o = o.next, Xt(r, s++, a);
2520
+ return o = o.next, Jt(r, s++, a);
2521
2521
  }
2522
2522
  return ze();
2523
2523
  });
@@ -2804,7 +2804,7 @@ var gm = /* @__PURE__ */ (function(n) {
2804
2804
  if (l === s)
2805
2805
  return ze();
2806
2806
  var c = a;
2807
- return a += i ? -o : o, Xt(r, i ? s - ++l : l++, c);
2807
+ return a += i ? -o : o, Jt(r, i ? s - ++l : l++, c);
2808
2808
  });
2809
2809
  }, t.prototype.equals = function(r) {
2810
2810
  return r instanceof t ? this._start === r._start && this._end === r._end && this._step === r._step : hh(this, r);
@@ -3558,7 +3558,7 @@ var Rv = /* @__PURE__ */ (function(n) {
3558
3558
  var s = this, o = this.size, a = 0;
3559
3559
  return new It(
3560
3560
  function() {
3561
- return a === o ? ze() : Xt(r, i ? o - ++a : a++, s._value);
3561
+ return a === o ? ze() : Jt(r, i ? o - ++a : a++, s._value);
3562
3562
  }
3563
3563
  );
3564
3564
  }, t.prototype.equals = function(r) {
@@ -3647,7 +3647,7 @@ const jv = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
3647
3647
  update: Qc,
3648
3648
  updateIn: hi,
3649
3649
  version: Nv
3650
- }, Symbol.toStringTag, { value: "Module" })), ae = "MODE_IDLE", pi = "MODE_2D_ZOOM_IN", gi = "MODE_2D_ZOOM_OUT", mi = "MODE_2D_PAN", ai = "MODE_3D_VIEW", gs = "MODE_3D_FIRST_PERSON", kr = "MODE_WAITING_DRAWING_LINE", Ir = "MODE_DRAGGING_LINE", Pr = "MODE_DRAGGING_VERTEX", Rr = "MODE_DRAGGING_ITEM", Lr = "MODE_DRAGGING_HOLE", Ze = "MODE_DRAWING_LINE", Ke = "MODE_DRAWING_HOLE", fr = "MODE_DRAWING_ITEM", Sn = "MODE_ROTATING_ITEM", gh = "MODE_UPLOADING_IMAGE", mh = "MODE_FITTING_IMAGE", yh = "MODE_VIEWING_CATALOG", bm = "MODE_CONFIGURING_PROJECT", vc = [
3650
+ }, Symbol.toStringTag, { value: "Module" })), ae = "MODE_IDLE", pi = "MODE_2D_ZOOM_IN", gi = "MODE_2D_ZOOM_OUT", mi = "MODE_2D_PAN", ai = "MODE_3D_VIEW", gs = "MODE_3D_FIRST_PERSON", kr = "MODE_WAITING_DRAWING_LINE", Ir = "MODE_DRAGGING_LINE", Pr = "MODE_DRAGGING_VERTEX", Rr = "MODE_DRAGGING_ITEM", Lr = "MODE_DRAGGING_HOLE", Ze = "MODE_DRAWING_LINE", Ke = "MODE_DRAWING_HOLE", fr = "MODE_DRAWING_ITEM", Mn = "MODE_ROTATING_ITEM", gh = "MODE_UPLOADING_IMAGE", mh = "MODE_FITTING_IMAGE", yh = "MODE_VIEWING_CATALOG", bm = "MODE_CONFIGURING_PROJECT", vc = [
3651
3651
  ae,
3652
3652
  pi,
3653
3653
  gi,
@@ -3662,7 +3662,7 @@ const jv = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
3662
3662
  Lr,
3663
3663
  mh,
3664
3664
  gh,
3665
- Sn
3665
+ Mn
3666
3666
  ], Vv = "mm", Qr = "cm", Dv = "m", Bv = "in", qv = "ft", $v = "mi", wm = [
3667
3667
  Vv,
3668
3668
  Qr,
@@ -3731,10 +3731,10 @@ function Wv(n, t, e, r) {
3731
3731
  let { x: i, y: s } = n, { x: o, y: a } = t, { x: l, y: c } = e, { x: h, y: f } = r, g = (f - c) * (o - i) - (h - l) * (a - s), p = (h - l) * (s - c) - (f - c) * (i - l), m = (o - i) * (s - c) - (a - s) * (i - l);
3732
3732
  if ($i(g) <= Gr) {
3733
3733
  if ($i(p) <= Gr && $i(m) <= Gr) {
3734
- let S = (z, R) => z.x === R.x ? z.y - R.y : z.x - R.x, A = [n, t].sort(S), C = [e.toJS(), r.toJS()].sort(S), [O, M] = [A, C].sort(
3735
- (z, R) => S(z[0], R[0])
3734
+ let S = (O, R) => O.x === R.x ? O.y - R.y : O.x - R.x, A = [n, t].sort(S), T = [e.toJS(), r.toJS()].sort(S), [C, M] = [A, T].sort(
3735
+ (O, R) => S(O[0], R[0])
3736
3736
  );
3737
- return O[1].x === M[0].x ? { type: M[0].y <= O[1].y ? "colinear" : "none" } : { type: M[0].x <= O[1].x ? "colinear" : "none" };
3737
+ return C[1].x === M[0].x ? { type: M[0].y <= C[1].y ? "colinear" : "none" } : { type: M[0].x <= C[1].x ? "colinear" : "none" };
3738
3738
  }
3739
3739
  return { type: "parallel" };
3740
3740
  }
@@ -4622,7 +4622,7 @@ function Mh() {
4622
4622
  return !!(u && u[_]);
4623
4623
  }
4624
4624
  i.isIterable = l, i.isKeyed = c, i.isIndexed = h, i.isAssociative = f, i.isOrdered = g, i.Keyed = s, i.Indexed = o, i.Set = a;
4625
- var p = "@@__IMMUTABLE_ITERABLE__@@", m = "@@__IMMUTABLE_KEYED__@@", v = "@@__IMMUTABLE_INDEXED__@@", _ = "@@__IMMUTABLE_ORDERED__@@", S = "delete", A = 5, C = 1 << A, O = C - 1, M = {}, z = { value: !1 }, R = { value: !1 };
4625
+ var p = "@@__IMMUTABLE_ITERABLE__@@", m = "@@__IMMUTABLE_KEYED__@@", v = "@@__IMMUTABLE_INDEXED__@@", _ = "@@__IMMUTABLE_ORDERED__@@", S = "delete", A = 5, T = 1 << A, C = T - 1, M = {}, O = { value: !1 }, R = { value: !1 };
4626
4626
  function I(u) {
4627
4627
  return u.value = !1, u;
4628
4628
  }
@@ -4778,16 +4778,16 @@ function Mh() {
4778
4778
  return this._object.hasOwnProperty(u);
4779
4779
  }, vt.prototype.__iterate = function(u, d) {
4780
4780
  for (var y = this._object, x = this._keys, b = x.length - 1, E = 0; E <= b; E++) {
4781
- var T = x[d ? b - E : E];
4782
- if (u(y[T], T, this) === !1)
4781
+ var z = x[d ? b - E : E];
4782
+ if (u(y[z], z, this) === !1)
4783
4783
  return E + 1;
4784
4784
  }
4785
4785
  return E;
4786
4786
  }, vt.prototype.__iterator = function(u, d) {
4787
4787
  var y = this._object, x = this._keys, b = x.length - 1, E = 0;
4788
4788
  return new W(function() {
4789
- var T = x[d ? b - E : E];
4790
- return E++ > b ? H() : Q(u, T, y[T]);
4789
+ var z = x[d ? b - E : E];
4790
+ return E++ > b ? H() : Q(u, z, y[z]);
4791
4791
  });
4792
4792
  }, vt.prototype[_] = !0, r(Rt, Pt);
4793
4793
  function Rt(u) {
@@ -4823,8 +4823,8 @@ function Mh() {
4823
4823
  if (u(x[b], b++, this) === !1)
4824
4824
  return b;
4825
4825
  for (var E; !(E = y.next()).done; ) {
4826
- var T = E.value;
4827
- if (x[b] = T, u(T, b++, this) === !1)
4826
+ var z = E.value;
4827
+ if (x[b] = z, u(z, b++, this) === !1)
4828
4828
  break;
4829
4829
  }
4830
4830
  return b;
@@ -4879,22 +4879,22 @@ function Mh() {
4879
4879
  function ne(u, d, y, x) {
4880
4880
  var b = u._cache;
4881
4881
  if (b) {
4882
- for (var E = b.length - 1, T = 0; T <= E; T++) {
4883
- var P = b[y ? E - T : T];
4884
- if (d(P[1], x ? P[0] : T, u) === !1)
4885
- return T + 1;
4882
+ for (var E = b.length - 1, z = 0; z <= E; z++) {
4883
+ var P = b[y ? E - z : z];
4884
+ if (d(P[1], x ? P[0] : z, u) === !1)
4885
+ return z + 1;
4886
4886
  }
4887
- return T;
4887
+ return z;
4888
4888
  }
4889
4889
  return u.__iterateUncached(d, y);
4890
4890
  }
4891
4891
  function ir(u, d, y, x) {
4892
4892
  var b = u._cache;
4893
4893
  if (b) {
4894
- var E = b.length - 1, T = 0;
4894
+ var E = b.length - 1, z = 0;
4895
4895
  return new W(function() {
4896
- var P = b[y ? E - T : T];
4897
- return T++ > E ? H() : Q(d, x ? P[0] : T - 1, P[1]);
4896
+ var P = b[y ? E - z : z];
4897
+ return z++ > E ? H() : Q(d, x ? P[0] : z - 1, P[1]);
4898
4898
  });
4899
4899
  }
4900
4900
  return u.__iteratorUncached(d, y);
@@ -4915,7 +4915,7 @@ function Mh() {
4915
4915
  function Yn(u) {
4916
4916
  return u && (u.constructor === Object || u.constructor === void 0);
4917
4917
  }
4918
- function ee(u, d) {
4918
+ function re(u, d) {
4919
4919
  if (u === d || u !== u && d !== d)
4920
4920
  return !0;
4921
4921
  if (!u || !d)
@@ -4940,7 +4940,7 @@ function Mh() {
4940
4940
  var x = u.entries();
4941
4941
  return d.every(function(N, j) {
4942
4942
  var B = x.next().value;
4943
- return B && ee(B[1], N) && (y || ee(B[0], j));
4943
+ return B && re(B[1], N) && (y || re(B[0], j));
4944
4944
  }) && x.next().done;
4945
4945
  }
4946
4946
  var b = !1;
@@ -4952,11 +4952,11 @@ function Mh() {
4952
4952
  var E = u;
4953
4953
  u = d, d = E;
4954
4954
  }
4955
- var T = !0, P = d.__iterate(function(N, j) {
4956
- if (y ? !u.has(N) : b ? !ee(N, u.get(j, M)) : !ee(u.get(j, M), N))
4957
- return T = !1, !1;
4955
+ var z = !0, P = d.__iterate(function(N, j) {
4956
+ if (y ? !u.has(N) : b ? !re(N, u.get(j, M)) : !re(u.get(j, M), N))
4957
+ return z = !1, !1;
4958
4958
  });
4959
- return T && u.size === P;
4959
+ return z && u.size === P;
4960
4960
  }
4961
4961
  r(ye, Pt);
4962
4962
  function ye(u, d) {
@@ -4973,16 +4973,16 @@ function Mh() {
4973
4973
  }, ye.prototype.get = function(u, d) {
4974
4974
  return this.has(u) ? this._value : d;
4975
4975
  }, ye.prototype.includes = function(u) {
4976
- return ee(this._value, u);
4976
+ return re(this._value, u);
4977
4977
  }, ye.prototype.slice = function(u, d) {
4978
4978
  var y = this.size;
4979
4979
  return mt(u, d, y) ? this : new ye(this._value, ot(d, y) - dt(u, y));
4980
4980
  }, ye.prototype.reverse = function() {
4981
4981
  return this;
4982
4982
  }, ye.prototype.indexOf = function(u) {
4983
- return ee(this._value, u) ? 0 : -1;
4983
+ return re(this._value, u) ? 0 : -1;
4984
4984
  }, ye.prototype.lastIndexOf = function(u) {
4985
- return ee(this._value, u) ? this.size : -1;
4985
+ return re(this._value, u) ? this.size : -1;
4986
4986
  }, ye.prototype.__iterate = function(u, d) {
4987
4987
  for (var y = 0; y < this.size; y++)
4988
4988
  if (u(this._value, y, this) === !1)
@@ -4996,7 +4996,7 @@ function Mh() {
4996
4996
  }
4997
4997
  );
4998
4998
  }, ye.prototype.equals = function(u) {
4999
- return u instanceof ye ? ee(this._value, u._value) : Xn(u);
4999
+ return u instanceof ye ? re(this._value, u._value) : Xn(u);
5000
5000
  };
5001
5001
  var mu;
5002
5002
  function Io(u, d) {
@@ -5041,27 +5041,27 @@ function Mh() {
5041
5041
  }, we.prototype.__iterator = function(u, d) {
5042
5042
  var y = this.size - 1, x = this._step, b = d ? this._start + y * x : this._start, E = 0;
5043
5043
  return new W(function() {
5044
- var T = b;
5045
- return b += d ? -x : x, E > y ? H() : Q(u, E++, T);
5044
+ var z = b;
5045
+ return b += d ? -x : x, E > y ? H() : Q(u, E++, z);
5046
5046
  });
5047
5047
  }, we.prototype.equals = function(u) {
5048
5048
  return u instanceof we ? this._start === u._start && this._end === u._end && this._step === u._step : Xn(this, u);
5049
5049
  };
5050
5050
  var yu;
5051
- r(En, i);
5052
- function En() {
5051
+ r(An, i);
5052
+ function An() {
5053
5053
  throw TypeError("Abstract");
5054
5054
  }
5055
- r(Os, En);
5055
+ r(Os, An);
5056
5056
  function Os() {
5057
5057
  }
5058
- r(vi, En);
5058
+ r(vi, An);
5059
5059
  function vi() {
5060
5060
  }
5061
- r(Po, En);
5061
+ r(Po, An);
5062
5062
  function Po() {
5063
5063
  }
5064
- En.Keyed = Os, En.Indexed = vi, En.Set = Po;
5064
+ An.Keyed = Os, An.Indexed = vi, An.Set = Po;
5065
5065
  var zs = typeof Math.imul == "function" && Math.imul(4294967295, 2) === -2 ? Math.imul : function(d, y) {
5066
5066
  d = d | 0, y = y | 0;
5067
5067
  var x = d & 65535, b = y & 65535;
@@ -5265,17 +5265,17 @@ function Mh() {
5265
5265
  this.ownerID = u, this.entries = d;
5266
5266
  }
5267
5267
  Ts.prototype.get = function(u, d, y, x) {
5268
- for (var b = this.entries, E = 0, T = b.length; E < T; E++)
5269
- if (ee(y, b[E][0]))
5268
+ for (var b = this.entries, E = 0, z = b.length; E < z; E++)
5269
+ if (re(y, b[E][0]))
5270
5270
  return b[E][1];
5271
5271
  return x;
5272
- }, Ts.prototype.update = function(u, d, y, x, b, E, T) {
5273
- for (var P = b === M, N = this.entries, j = 0, B = N.length; j < B && !ee(x, N[j][0]); j++)
5272
+ }, Ts.prototype.update = function(u, d, y, x, b, E, z) {
5273
+ for (var P = b === M, N = this.entries, j = 0, B = N.length; j < B && !re(x, N[j][0]); j++)
5274
5274
  ;
5275
5275
  var nt = j < B;
5276
5276
  if (nt ? N[j][1] === b : P)
5277
5277
  return this;
5278
- if (L(T), (P || !nt) && L(E), !(P && N.length === 1)) {
5278
+ if (L(z), (P || !nt) && L(E), !(P && N.length === 1)) {
5279
5279
  if (!nt && !P && N.length >= d0)
5280
5280
  return u0(u, N, x, b);
5281
5281
  var at = u && u === this.ownerID, bt = at ? N : Y(N);
@@ -5287,14 +5287,14 @@ function Mh() {
5287
5287
  }
5288
5288
  xi.prototype.get = function(u, d, y, x) {
5289
5289
  d === void 0 && (d = $e(y));
5290
- var b = 1 << ((u === 0 ? d : d >>> u) & O), E = this.bitmap;
5290
+ var b = 1 << ((u === 0 ? d : d >>> u) & C), E = this.bitmap;
5291
5291
  return (E & b) === 0 ? x : this.nodes[Zh(E & b - 1)].get(u + A, d, y, x);
5292
- }, xi.prototype.update = function(u, d, y, x, b, E, T) {
5292
+ }, xi.prototype.update = function(u, d, y, x, b, E, z) {
5293
5293
  y === void 0 && (y = $e(x));
5294
- var P = (d === 0 ? y : y >>> d) & O, N = 1 << P, j = this.bitmap, B = (j & N) !== 0;
5294
+ var P = (d === 0 ? y : y >>> d) & C, N = 1 << P, j = this.bitmap, B = (j & N) !== 0;
5295
5295
  if (!B && b === M)
5296
5296
  return this;
5297
- var nt = Zh(j & N - 1), at = this.nodes, bt = B ? at[nt] : void 0, Mt = Tu(bt, u, d + A, y, x, b, E, T);
5297
+ var nt = Zh(j & N - 1), at = this.nodes, bt = B ? at[nt] : void 0, Mt = Tu(bt, u, d + A, y, x, b, E, z);
5298
5298
  if (Mt === bt)
5299
5299
  return this;
5300
5300
  if (!B && Mt && at.length >= p0)
@@ -5311,14 +5311,14 @@ function Mh() {
5311
5311
  }
5312
5312
  Cs.prototype.get = function(u, d, y, x) {
5313
5313
  d === void 0 && (d = $e(y));
5314
- var b = (u === 0 ? d : d >>> u) & O, E = this.nodes[b];
5314
+ var b = (u === 0 ? d : d >>> u) & C, E = this.nodes[b];
5315
5315
  return E ? E.get(u + A, d, y, x) : x;
5316
- }, Cs.prototype.update = function(u, d, y, x, b, E, T) {
5316
+ }, Cs.prototype.update = function(u, d, y, x, b, E, z) {
5317
5317
  y === void 0 && (y = $e(x));
5318
- var P = (d === 0 ? y : y >>> d) & O, N = b === M, j = this.nodes, B = j[P];
5318
+ var P = (d === 0 ? y : y >>> d) & C, N = b === M, j = this.nodes, B = j[P];
5319
5319
  if (N && !B)
5320
5320
  return this;
5321
- var nt = Tu(B, u, d + A, y, x, b, E, T);
5321
+ var nt = Tu(B, u, d + A, y, x, b, E, z);
5322
5322
  if (nt === B)
5323
5323
  return this;
5324
5324
  var at = this.count;
@@ -5333,21 +5333,21 @@ function Mh() {
5333
5333
  this.ownerID = u, this.keyHash = d, this.entries = y;
5334
5334
  }
5335
5335
  _i.prototype.get = function(u, d, y, x) {
5336
- for (var b = this.entries, E = 0, T = b.length; E < T; E++)
5337
- if (ee(y, b[E][0]))
5336
+ for (var b = this.entries, E = 0, z = b.length; E < z; E++)
5337
+ if (re(y, b[E][0]))
5338
5338
  return b[E][1];
5339
5339
  return x;
5340
- }, _i.prototype.update = function(u, d, y, x, b, E, T) {
5340
+ }, _i.prototype.update = function(u, d, y, x, b, E, z) {
5341
5341
  y === void 0 && (y = $e(x));
5342
5342
  var P = b === M;
5343
5343
  if (y !== this.keyHash)
5344
- return P ? this : (L(T), L(E), Cu(this, u, d, y, [x, b]));
5345
- for (var N = this.entries, j = 0, B = N.length; j < B && !ee(x, N[j][0]); j++)
5344
+ return P ? this : (L(z), L(E), Cu(this, u, d, y, [x, b]));
5345
+ for (var N = this.entries, j = 0, B = N.length; j < B && !re(x, N[j][0]); j++)
5346
5346
  ;
5347
5347
  var nt = j < B;
5348
5348
  if (nt ? N[j][1] === b : P)
5349
5349
  return this;
5350
- if (L(T), (P || !nt) && L(E), P && B === 2)
5350
+ if (L(z), (P || !nt) && L(E), P && B === 2)
5351
5351
  return new ln(u, this.keyHash, N[j ^ 1]);
5352
5352
  var at = u && u === this.ownerID, bt = at ? N : Y(N);
5353
5353
  return nt ? P ? j === B - 1 ? bt.pop() : bt[j] = bt.pop() : bt[j] = [x, b] : bt.push([x, b]), at ? (this.entries = bt, this) : new _i(u, this.keyHash, bt);
@@ -5356,12 +5356,12 @@ function Mh() {
5356
5356
  this.ownerID = u, this.keyHash = d, this.entry = y;
5357
5357
  }
5358
5358
  ln.prototype.get = function(u, d, y, x) {
5359
- return ee(y, this.entry[0]) ? this.entry[1] : x;
5360
- }, ln.prototype.update = function(u, d, y, x, b, E, T) {
5361
- var P = b === M, N = ee(x, this.entry[0]);
5359
+ return re(y, this.entry[0]) ? this.entry[1] : x;
5360
+ }, ln.prototype.update = function(u, d, y, x, b, E, z) {
5361
+ var P = b === M, N = re(x, this.entry[0]);
5362
5362
  if (N ? b === this.entry[1] : P)
5363
5363
  return this;
5364
- if (L(T), P) {
5364
+ if (L(z), P) {
5365
5365
  L(E);
5366
5366
  return;
5367
5367
  }
@@ -5425,8 +5425,8 @@ function Mh() {
5425
5425
  function Gh(u, d, y) {
5426
5426
  var x, b;
5427
5427
  if (u._root) {
5428
- var E = I(z), T = I(R);
5429
- if (x = Tu(u._root, u.__ownerID, 0, void 0, d, y, E, T), !T.value)
5428
+ var E = I(O), z = I(R);
5429
+ if (x = Tu(u._root, u.__ownerID, 0, void 0, d, y, E, z), !z.value)
5430
5430
  return u;
5431
5431
  b = u.size + (E.value ? y === M ? -1 : 1 : 0);
5432
5432
  } else {
@@ -5436,8 +5436,8 @@ function Mh() {
5436
5436
  }
5437
5437
  return u.__ownerID ? (u.size = b, u._root = x, u.__hash = void 0, u.__altered = !0, u) : x ? zu(b, x) : xr();
5438
5438
  }
5439
- function Tu(u, d, y, x, b, E, T, P) {
5440
- return u ? u.update(d, y, x, b, E, T, P) : E === M ? u : (L(P), L(T), new ln(d, x, [b, E]));
5439
+ function Tu(u, d, y, x, b, E, z, P) {
5440
+ return u ? u.update(d, y, x, b, E, z, P) : E === M ? u : (L(P), L(z), new ln(d, x, [b, E]));
5441
5441
  }
5442
5442
  function Wh(u) {
5443
5443
  return u.constructor === ln || u.constructor === _i;
@@ -5445,63 +5445,63 @@ function Mh() {
5445
5445
  function Cu(u, d, y, x, b) {
5446
5446
  if (u.keyHash === x)
5447
5447
  return new _i(d, x, [u.entry, b]);
5448
- var E = (y === 0 ? u.keyHash : u.keyHash >>> y) & O, T = (y === 0 ? x : x >>> y) & O, P, N = E === T ? [Cu(u, d, y + A, x, b)] : (P = new ln(d, x, b), E < T ? [u, P] : [P, u]);
5449
- return new xi(d, 1 << E | 1 << T, N);
5448
+ var E = (y === 0 ? u.keyHash : u.keyHash >>> y) & C, z = (y === 0 ? x : x >>> y) & C, P, N = E === z ? [Cu(u, d, y + A, x, b)] : (P = new ln(d, x, b), E < z ? [u, P] : [P, u]);
5449
+ return new xi(d, 1 << E | 1 << z, N);
5450
5450
  }
5451
5451
  function u0(u, d, y, x) {
5452
5452
  u || (u = new U());
5453
5453
  for (var b = new ln(u, $e(y), [y, x]), E = 0; E < d.length; E++) {
5454
- var T = d[E];
5455
- b = b.update(u, 0, void 0, T[0], T[1]);
5454
+ var z = d[E];
5455
+ b = b.update(u, 0, void 0, z[0], z[1]);
5456
5456
  }
5457
5457
  return b;
5458
5458
  }
5459
5459
  function l0(u, d, y, x) {
5460
- for (var b = 0, E = 0, T = new Array(y), P = 0, N = 1, j = d.length; P < j; P++, N <<= 1) {
5460
+ for (var b = 0, E = 0, z = new Array(y), P = 0, N = 1, j = d.length; P < j; P++, N <<= 1) {
5461
5461
  var B = d[P];
5462
- B !== void 0 && P !== x && (b |= N, T[E++] = B);
5462
+ B !== void 0 && P !== x && (b |= N, z[E++] = B);
5463
5463
  }
5464
- return new xi(u, b, T);
5464
+ return new xi(u, b, z);
5465
5465
  }
5466
5466
  function c0(u, d, y, x, b) {
5467
- for (var E = 0, T = new Array(C), P = 0; y !== 0; P++, y >>>= 1)
5468
- T[P] = y & 1 ? d[E++] : void 0;
5469
- return T[x] = b, new Cs(u, E + 1, T);
5467
+ for (var E = 0, z = new Array(T), P = 0; y !== 0; P++, y >>>= 1)
5468
+ z[P] = y & 1 ? d[E++] : void 0;
5469
+ return z[x] = b, new Cs(u, E + 1, z);
5470
5470
  }
5471
5471
  function Ro(u, d, y) {
5472
5472
  for (var x = [], b = 0; b < y.length; b++) {
5473
- var E = y[b], T = s(E);
5474
- l(E) || (T = T.map(function(P) {
5473
+ var E = y[b], z = s(E);
5474
+ l(E) || (z = z.map(function(P) {
5475
5475
  return Dr(P);
5476
- })), x.push(T);
5476
+ })), x.push(z);
5477
5477
  }
5478
5478
  return Xh(u, d, x);
5479
5479
  }
5480
5480
  function Uh(u, d, y) {
5481
- return u && u.mergeDeep && l(d) ? u.mergeDeep(d) : ee(u, d) ? u : d;
5481
+ return u && u.mergeDeep && l(d) ? u.mergeDeep(d) : re(u, d) ? u : d;
5482
5482
  }
5483
5483
  function Yh(u) {
5484
5484
  return function(d, y, x) {
5485
5485
  if (d && d.mergeDeepWith && l(y))
5486
5486
  return d.mergeDeepWith(u, y);
5487
5487
  var b = u(d, y, x);
5488
- return ee(d, b) ? d : b;
5488
+ return re(d, b) ? d : b;
5489
5489
  };
5490
5490
  }
5491
5491
  function Xh(u, d, y) {
5492
5492
  return y = y.filter(function(x) {
5493
5493
  return x.size !== 0;
5494
5494
  }), y.length === 0 ? u : u.size === 0 && !u.__ownerID && y.length === 1 ? u.constructor(y[0]) : u.withMutations(function(x) {
5495
- for (var b = d ? function(T, P) {
5495
+ for (var b = d ? function(z, P) {
5496
5496
  x.update(
5497
5497
  P,
5498
5498
  M,
5499
5499
  function(N) {
5500
- return N === M ? T : d(N, T, P);
5500
+ return N === M ? z : d(N, z, P);
5501
5501
  }
5502
5502
  );
5503
- } : function(T, P) {
5504
- x.set(P, T);
5503
+ } : function(z, P) {
5504
+ x.set(P, z);
5505
5505
  }, E = 0; E < y.length; E++)
5506
5506
  y[E].forEach(b);
5507
5507
  });
@@ -5509,8 +5509,8 @@ function Mh() {
5509
5509
  function Jh(u, d, y, x) {
5510
5510
  var b = u === M, E = d.next();
5511
5511
  if (E.done) {
5512
- var T = b ? y : u, P = x(T);
5513
- return P === T ? u : P;
5512
+ var z = b ? y : u, P = x(z);
5513
+ return P === z ? u : P;
5514
5514
  }
5515
5515
  Io(
5516
5516
  b || u && u.set,
@@ -5535,121 +5535,121 @@ function Mh() {
5535
5535
  var b = u.length + 1;
5536
5536
  if (x && d + 1 === b)
5537
5537
  return u[d] = y, u;
5538
- for (var E = new Array(b), T = 0, P = 0; P < b; P++)
5539
- P === d ? (E[P] = y, T = -1) : E[P] = u[P + T];
5538
+ for (var E = new Array(b), z = 0, P = 0; P < b; P++)
5539
+ P === d ? (E[P] = y, z = -1) : E[P] = u[P + z];
5540
5540
  return E;
5541
5541
  }
5542
5542
  function f0(u, d, y) {
5543
5543
  var x = u.length - 1;
5544
5544
  if (y && d === x)
5545
5545
  return u.pop(), u;
5546
- for (var b = new Array(x), E = 0, T = 0; T < x; T++)
5547
- T === d && (E = 1), b[T] = u[T + E];
5546
+ for (var b = new Array(x), E = 0, z = 0; z < x; z++)
5547
+ z === d && (E = 1), b[z] = u[z + E];
5548
5548
  return b;
5549
5549
  }
5550
- var d0 = C / 4, p0 = C / 2, g0 = C / 4;
5551
- r(Yt, vi);
5552
- function Yt(u) {
5550
+ var d0 = T / 4, p0 = T / 2, g0 = T / 4;
5551
+ r(Xt, vi);
5552
+ function Xt(u) {
5553
5553
  var d = ku();
5554
5554
  if (u == null)
5555
5555
  return d;
5556
5556
  if (Qh(u))
5557
5557
  return u;
5558
5558
  var y = o(u), x = y.size;
5559
- return x === 0 ? d : (He(x), x > 0 && x < C ? Is(0, x, A, null, new An(y.toArray())) : d.withMutations(function(b) {
5560
- b.setSize(x), y.forEach(function(E, T) {
5561
- return b.set(T, E);
5559
+ return x === 0 ? d : (He(x), x > 0 && x < T ? Is(0, x, A, null, new On(y.toArray())) : d.withMutations(function(b) {
5560
+ b.setSize(x), y.forEach(function(E, z) {
5561
+ return b.set(z, E);
5562
5562
  });
5563
5563
  }));
5564
5564
  }
5565
- Yt.of = function() {
5565
+ Xt.of = function() {
5566
5566
  return this(arguments);
5567
- }, Yt.prototype.toString = function() {
5567
+ }, Xt.prototype.toString = function() {
5568
5568
  return this.__toString("List [", "]");
5569
- }, Yt.prototype.get = function(u, d) {
5569
+ }, Xt.prototype.get = function(u, d) {
5570
5570
  if (u = rt(this, u), u >= 0 && u < this.size) {
5571
5571
  u += this._origin;
5572
5572
  var y = nf(this, u);
5573
- return y && y.array[u & O];
5573
+ return y && y.array[u & C];
5574
5574
  }
5575
5575
  return d;
5576
- }, Yt.prototype.set = function(u, d) {
5576
+ }, Xt.prototype.set = function(u, d) {
5577
5577
  return m0(this, u, d);
5578
- }, Yt.prototype.remove = function(u) {
5578
+ }, Xt.prototype.remove = function(u) {
5579
5579
  return this.has(u) ? u === 0 ? this.shift() : u === this.size - 1 ? this.pop() : this.splice(u, 1) : this;
5580
- }, Yt.prototype.insert = function(u, d) {
5580
+ }, Xt.prototype.insert = function(u, d) {
5581
5581
  return this.splice(u, 0, d);
5582
- }, Yt.prototype.clear = function() {
5582
+ }, Xt.prototype.clear = function() {
5583
5583
  return this.size === 0 ? this : this.__ownerID ? (this.size = this._origin = this._capacity = 0, this._level = A, this._root = this._tail = null, this.__hash = void 0, this.__altered = !0, this) : ku();
5584
- }, Yt.prototype.push = function() {
5584
+ }, Xt.prototype.push = function() {
5585
5585
  var u = arguments, d = this.size;
5586
5586
  return this.withMutations(function(y) {
5587
- On(y, 0, d + u.length);
5587
+ zn(y, 0, d + u.length);
5588
5588
  for (var x = 0; x < u.length; x++)
5589
5589
  y.set(d + x, u[x]);
5590
5590
  });
5591
- }, Yt.prototype.pop = function() {
5592
- return On(this, 0, -1);
5593
- }, Yt.prototype.unshift = function() {
5591
+ }, Xt.prototype.pop = function() {
5592
+ return zn(this, 0, -1);
5593
+ }, Xt.prototype.unshift = function() {
5594
5594
  var u = arguments;
5595
5595
  return this.withMutations(function(d) {
5596
- On(d, -u.length);
5596
+ zn(d, -u.length);
5597
5597
  for (var y = 0; y < u.length; y++)
5598
5598
  d.set(y, u[y]);
5599
5599
  });
5600
- }, Yt.prototype.shift = function() {
5601
- return On(this, 1);
5602
- }, Yt.prototype.merge = function() {
5600
+ }, Xt.prototype.shift = function() {
5601
+ return zn(this, 1);
5602
+ }, Xt.prototype.merge = function() {
5603
5603
  return Lo(this, void 0, arguments);
5604
- }, Yt.prototype.mergeWith = function(u) {
5604
+ }, Xt.prototype.mergeWith = function(u) {
5605
5605
  var d = e.call(arguments, 1);
5606
5606
  return Lo(this, u, d);
5607
- }, Yt.prototype.mergeDeep = function() {
5607
+ }, Xt.prototype.mergeDeep = function() {
5608
5608
  return Lo(this, Uh, arguments);
5609
- }, Yt.prototype.mergeDeepWith = function(u) {
5609
+ }, Xt.prototype.mergeDeepWith = function(u) {
5610
5610
  var d = e.call(arguments, 1);
5611
5611
  return Lo(this, Yh(u), d);
5612
- }, Yt.prototype.setSize = function(u) {
5613
- return On(this, 0, u);
5614
- }, Yt.prototype.slice = function(u, d) {
5612
+ }, Xt.prototype.setSize = function(u) {
5613
+ return zn(this, 0, u);
5614
+ }, Xt.prototype.slice = function(u, d) {
5615
5615
  var y = this.size;
5616
- return mt(u, d, y) ? this : On(
5616
+ return mt(u, d, y) ? this : zn(
5617
5617
  this,
5618
5618
  dt(u, y),
5619
5619
  ot(d, y)
5620
5620
  );
5621
- }, Yt.prototype.__iterator = function(u, d) {
5621
+ }, Xt.prototype.__iterator = function(u, d) {
5622
5622
  var y = 0, x = ef(this, d);
5623
5623
  return new W(function() {
5624
5624
  var b = x();
5625
5625
  return b === ks ? H() : Q(u, y++, b);
5626
5626
  });
5627
- }, Yt.prototype.__iterate = function(u, d) {
5627
+ }, Xt.prototype.__iterate = function(u, d) {
5628
5628
  for (var y = 0, x = ef(this, d), b; (b = x()) !== ks && u(b, y++, this) !== !1; )
5629
5629
  ;
5630
5630
  return y;
5631
- }, Yt.prototype.__ensureOwner = function(u) {
5631
+ }, Xt.prototype.__ensureOwner = function(u) {
5632
5632
  return u === this.__ownerID ? this : u ? Is(this._origin, this._capacity, this._level, this._root, this._tail, u, this.__hash) : (this.__ownerID = u, this);
5633
5633
  };
5634
5634
  function Qh(u) {
5635
5635
  return !!(u && u[tf]);
5636
5636
  }
5637
- Yt.isList = Qh;
5638
- var tf = "@@__IMMUTABLE_LIST__@@", ke = Yt.prototype;
5637
+ Xt.isList = Qh;
5638
+ var tf = "@@__IMMUTABLE_LIST__@@", ke = Xt.prototype;
5639
5639
  ke[tf] = !0, ke[S] = ke.remove, ke.setIn = zt.setIn, ke.deleteIn = ke.removeIn = zt.removeIn, ke.update = zt.update, ke.updateIn = zt.updateIn, ke.mergeIn = zt.mergeIn, ke.mergeDeepIn = zt.mergeDeepIn, ke.withMutations = zt.withMutations, ke.asMutable = zt.asMutable, ke.asImmutable = zt.asImmutable, ke.wasAltered = zt.wasAltered;
5640
- function An(u, d) {
5640
+ function On(u, d) {
5641
5641
  this.array = u, this.ownerID = d;
5642
5642
  }
5643
- An.prototype.removeBefore = function(u, d, y) {
5643
+ On.prototype.removeBefore = function(u, d, y) {
5644
5644
  if (y === d ? 1 << d : this.array.length === 0)
5645
5645
  return this;
5646
- var x = y >>> d & O;
5646
+ var x = y >>> d & C;
5647
5647
  if (x >= this.array.length)
5648
- return new An([], u);
5648
+ return new On([], u);
5649
5649
  var b = x === 0, E;
5650
5650
  if (d > 0) {
5651
- var T = this.array[x];
5652
- if (E = T && T.removeBefore(u, d - A, y), E === T && b)
5651
+ var z = this.array[x];
5652
+ if (E = z && z.removeBefore(u, d - A, y), E === z && b)
5653
5653
  return this;
5654
5654
  }
5655
5655
  if (b && !E)
@@ -5659,10 +5659,10 @@ function Mh() {
5659
5659
  for (var N = 0; N < x; N++)
5660
5660
  P.array[N] = void 0;
5661
5661
  return E && (P.array[x] = E), P;
5662
- }, An.prototype.removeAfter = function(u, d, y) {
5662
+ }, On.prototype.removeAfter = function(u, d, y) {
5663
5663
  if (y === (d ? 1 << d : 0) || this.array.length === 0)
5664
5664
  return this;
5665
- var x = y - 1 >>> d & O;
5665
+ var x = y - 1 >>> d & C;
5666
5666
  if (x >= this.array.length)
5667
5667
  return this;
5668
5668
  var b;
@@ -5671,19 +5671,19 @@ function Mh() {
5671
5671
  if (b = E && E.removeAfter(u, d - A, y), b === E && x === this.array.length - 1)
5672
5672
  return this;
5673
5673
  }
5674
- var T = bi(this, u);
5675
- return T.array.splice(x + 1), b && (T.array[x] = b), T;
5674
+ var z = bi(this, u);
5675
+ return z.array.splice(x + 1), b && (z.array[x] = b), z;
5676
5676
  };
5677
5677
  var ks = {};
5678
5678
  function ef(u, d) {
5679
5679
  var y = u._origin, x = u._capacity, b = Ps(x), E = u._tail;
5680
- return T(u._root, u._level, 0);
5681
- function T(j, B, nt) {
5680
+ return z(u._root, u._level, 0);
5681
+ function z(j, B, nt) {
5682
5682
  return B === 0 ? P(j, nt) : N(j, B, nt);
5683
5683
  }
5684
5684
  function P(j, B) {
5685
5685
  var nt = B === b ? E && E.array : j && j.array, at = B > y ? 0 : y - B, bt = x - B;
5686
- return bt > C && (bt = C), function() {
5686
+ return bt > T && (bt = T), function() {
5687
5687
  if (at === bt)
5688
5688
  return ks;
5689
5689
  var Mt = d ? --bt : at++;
@@ -5692,7 +5692,7 @@ function Mh() {
5692
5692
  }
5693
5693
  function N(j, B, nt) {
5694
5694
  var at, bt = j && j.array, Mt = nt > y ? 0 : y - nt >> B, Qt = (x - nt >> B) + 1;
5695
- return Qt > C && (Qt = C), function() {
5695
+ return Qt > T && (Qt = T), function() {
5696
5696
  do {
5697
5697
  if (at) {
5698
5698
  var _r = at();
@@ -5703,7 +5703,7 @@ function Mh() {
5703
5703
  if (Mt === Qt)
5704
5704
  return ks;
5705
5705
  var Hr = d ? --Qt : Mt++;
5706
- at = T(
5706
+ at = z(
5707
5707
  bt && bt[Hr],
5708
5708
  B - A,
5709
5709
  nt + (Hr << B)
@@ -5712,9 +5712,9 @@ function Mh() {
5712
5712
  };
5713
5713
  }
5714
5714
  }
5715
- function Is(u, d, y, x, b, E, T) {
5715
+ function Is(u, d, y, x, b, E, z) {
5716
5716
  var P = Object.create(ke);
5717
- return P.size = d - u, P._origin = u, P._capacity = d, P._level = y, P._root = x, P._tail = b, P.__ownerID = E, P.__hash = T, P.__altered = !1, P;
5717
+ return P.size = d - u, P._origin = u, P._capacity = d, P._level = y, P._root = x, P._tail = b, P.__ownerID = E, P.__hash = z, P.__altered = !1, P;
5718
5718
  }
5719
5719
  var rf;
5720
5720
  function ku() {
@@ -5724,81 +5724,81 @@ function Mh() {
5724
5724
  if (d = rt(u, d), d !== d)
5725
5725
  return u;
5726
5726
  if (d >= u.size || d < 0)
5727
- return u.withMutations(function(T) {
5728
- d < 0 ? On(T, d).set(0, y) : On(T, 0, d + 1).set(d, y);
5727
+ return u.withMutations(function(z) {
5728
+ d < 0 ? zn(z, d).set(0, y) : zn(z, 0, d + 1).set(d, y);
5729
5729
  });
5730
5730
  d += u._origin;
5731
5731
  var x = u._tail, b = u._root, E = I(R);
5732
5732
  return d >= Ps(u._capacity) ? x = Iu(x, u.__ownerID, 0, d, y, E) : b = Iu(b, u.__ownerID, u._level, d, y, E), E.value ? u.__ownerID ? (u._root = b, u._tail = x, u.__hash = void 0, u.__altered = !0, u) : Is(u._origin, u._capacity, u._level, b, x) : u;
5733
5733
  }
5734
5734
  function Iu(u, d, y, x, b, E) {
5735
- var T = x >>> y & O, P = u && T < u.array.length;
5735
+ var z = x >>> y & C, P = u && z < u.array.length;
5736
5736
  if (!P && b === void 0)
5737
5737
  return u;
5738
5738
  var N;
5739
5739
  if (y > 0) {
5740
- var j = u && u.array[T], B = Iu(j, d, y - A, x, b, E);
5741
- return B === j ? u : (N = bi(u, d), N.array[T] = B, N);
5740
+ var j = u && u.array[z], B = Iu(j, d, y - A, x, b, E);
5741
+ return B === j ? u : (N = bi(u, d), N.array[z] = B, N);
5742
5742
  }
5743
- return P && u.array[T] === b ? u : (L(E), N = bi(u, d), b === void 0 && T === N.array.length - 1 ? N.array.pop() : N.array[T] = b, N);
5743
+ return P && u.array[z] === b ? u : (L(E), N = bi(u, d), b === void 0 && z === N.array.length - 1 ? N.array.pop() : N.array[z] = b, N);
5744
5744
  }
5745
5745
  function bi(u, d) {
5746
- return d && u && d === u.ownerID ? u : new An(u ? u.array.slice() : [], d);
5746
+ return d && u && d === u.ownerID ? u : new On(u ? u.array.slice() : [], d);
5747
5747
  }
5748
5748
  function nf(u, d) {
5749
5749
  if (d >= Ps(u._capacity))
5750
5750
  return u._tail;
5751
5751
  if (d < 1 << u._level + A) {
5752
5752
  for (var y = u._root, x = u._level; y && x > 0; )
5753
- y = y.array[d >>> x & O], x -= A;
5753
+ y = y.array[d >>> x & C], x -= A;
5754
5754
  return y;
5755
5755
  }
5756
5756
  }
5757
- function On(u, d, y) {
5757
+ function zn(u, d, y) {
5758
5758
  d !== void 0 && (d = d | 0), y !== void 0 && (y = y | 0);
5759
- var x = u.__ownerID || new U(), b = u._origin, E = u._capacity, T = b + d, P = y === void 0 ? E : y < 0 ? E + y : b + y;
5760
- if (T === b && P === E)
5759
+ var x = u.__ownerID || new U(), b = u._origin, E = u._capacity, z = b + d, P = y === void 0 ? E : y < 0 ? E + y : b + y;
5760
+ if (z === b && P === E)
5761
5761
  return u;
5762
- if (T >= P)
5762
+ if (z >= P)
5763
5763
  return u.clear();
5764
- for (var N = u._level, j = u._root, B = 0; T + B < 0; )
5765
- j = new An(j && j.array.length ? [void 0, j] : [], x), N += A, B += 1 << N;
5766
- B && (T += B, b += B, P += B, E += B);
5764
+ for (var N = u._level, j = u._root, B = 0; z + B < 0; )
5765
+ j = new On(j && j.array.length ? [void 0, j] : [], x), N += A, B += 1 << N;
5766
+ B && (z += B, b += B, P += B, E += B);
5767
5767
  for (var nt = Ps(E), at = Ps(P); at >= 1 << N + A; )
5768
- j = new An(j && j.array.length ? [j] : [], x), N += A;
5769
- var bt = u._tail, Mt = at < nt ? nf(u, P - 1) : at > nt ? new An([], x) : bt;
5770
- if (bt && at > nt && T < E && bt.array.length) {
5768
+ j = new On(j && j.array.length ? [j] : [], x), N += A;
5769
+ var bt = u._tail, Mt = at < nt ? nf(u, P - 1) : at > nt ? new On([], x) : bt;
5770
+ if (bt && at > nt && z < E && bt.array.length) {
5771
5771
  j = bi(j, x);
5772
5772
  for (var Qt = j, _r = N; _r > A; _r -= A) {
5773
- var Hr = nt >>> _r & O;
5773
+ var Hr = nt >>> _r & C;
5774
5774
  Qt = Qt.array[Hr] = bi(Qt.array[Hr], x);
5775
5775
  }
5776
- Qt.array[nt >>> A & O] = bt;
5776
+ Qt.array[nt >>> A & C] = bt;
5777
5777
  }
5778
- if (P < E && (Mt = Mt && Mt.removeAfter(x, 0, P)), T >= at)
5779
- T -= at, P -= at, N = A, j = null, Mt = Mt && Mt.removeBefore(x, 0, T);
5780
- else if (T > b || at < nt) {
5778
+ if (P < E && (Mt = Mt && Mt.removeAfter(x, 0, P)), z >= at)
5779
+ z -= at, P -= at, N = A, j = null, Mt = Mt && Mt.removeBefore(x, 0, z);
5780
+ else if (z > b || at < nt) {
5781
5781
  for (B = 0; j; ) {
5782
- var qo = T >>> N & O;
5783
- if (qo !== at >>> N & O)
5782
+ var qo = z >>> N & C;
5783
+ if (qo !== at >>> N & C)
5784
5784
  break;
5785
5785
  qo && (B += (1 << N) * qo), N -= A, j = j.array[qo];
5786
5786
  }
5787
- j && T > b && (j = j.removeBefore(x, N, T - B)), j && at < nt && (j = j.removeAfter(x, N, at - B)), B && (T -= B, P -= B);
5787
+ j && z > b && (j = j.removeBefore(x, N, z - B)), j && at < nt && (j = j.removeAfter(x, N, at - B)), B && (z -= B, P -= B);
5788
5788
  }
5789
- return u.__ownerID ? (u.size = P - T, u._origin = T, u._capacity = P, u._level = N, u._root = j, u._tail = Mt, u.__hash = void 0, u.__altered = !0, u) : Is(T, P, N, j, Mt);
5789
+ return u.__ownerID ? (u.size = P - z, u._origin = z, u._capacity = P, u._level = N, u._root = j, u._tail = Mt, u.__hash = void 0, u.__altered = !0, u) : Is(z, P, N, j, Mt);
5790
5790
  }
5791
5791
  function Lo(u, d, y) {
5792
5792
  for (var x = [], b = 0, E = 0; E < y.length; E++) {
5793
- var T = y[E], P = o(T);
5794
- P.size > b && (b = P.size), l(T) || (P = P.map(function(N) {
5793
+ var z = y[E], P = o(z);
5794
+ P.size > b && (b = P.size), l(z) || (P = P.map(function(N) {
5795
5795
  return Dr(N);
5796
5796
  })), x.push(P);
5797
5797
  }
5798
5798
  return b > u.size && (u = u.setSize(b)), Xh(u, d, x);
5799
5799
  }
5800
5800
  function Ps(u) {
5801
- return u < C ? 0 : u - 1 >>> A << A;
5801
+ return u < T ? 0 : u - 1 >>> A << A;
5802
5802
  }
5803
5803
  r(ie, Ct);
5804
5804
  function ie(u) {
@@ -5853,16 +5853,16 @@ function Mh() {
5853
5853
  return of || (of = Pu(xr(), ku()));
5854
5854
  }
5855
5855
  function af(u, d, y) {
5856
- var x = u._map, b = u._list, E = x.get(d), T = E !== void 0, P, N;
5856
+ var x = u._map, b = u._list, E = x.get(d), z = E !== void 0, P, N;
5857
5857
  if (y === M) {
5858
- if (!T)
5858
+ if (!z)
5859
5859
  return u;
5860
- b.size >= C && b.size >= x.size * 2 ? (N = b.filter(function(j, B) {
5860
+ b.size >= T && b.size >= x.size * 2 ? (N = b.filter(function(j, B) {
5861
5861
  return j !== void 0 && E !== B;
5862
5862
  }), P = N.toKeyedSeq().map(function(j) {
5863
5863
  return j[0];
5864
5864
  }).flip().toMap(), u.__ownerID && (P.__ownerID = N.__ownerID = u.__ownerID)) : (P = x.remove(d), N = E === b.size - 1 ? b.pop() : b.set(E, void 0));
5865
- } else if (T) {
5865
+ } else if (z) {
5866
5866
  if (y === b.get(E)[1])
5867
5867
  return u;
5868
5868
  P = x, N = b.set(E, [d, y]);
@@ -5997,8 +5997,8 @@ function Mh() {
5997
5997
  return u.has(y);
5998
5998
  }, d.cacheResult = Fu, d.__iterateUncached = function(y, x) {
5999
5999
  var b = this;
6000
- return u.__iterate(function(E, T) {
6001
- return y(T, E, b) !== !1;
6000
+ return u.__iterate(function(E, z) {
6001
+ return y(z, E, b) !== !1;
6002
6002
  }, x);
6003
6003
  }, d.__iteratorUncached = function(y, x) {
6004
6004
  if (y === F) {
@@ -6006,8 +6006,8 @@ function Mh() {
6006
6006
  return new W(function() {
6007
6007
  var E = b.next();
6008
6008
  if (!E.done) {
6009
- var T = E.value[0];
6010
- E.value[0] = E.value[1], E.value[1] = T;
6009
+ var z = E.value[0];
6010
+ E.value[0] = E.value[1], E.value[1] = z;
6011
6011
  }
6012
6012
  return E;
6013
6013
  });
@@ -6023,20 +6023,20 @@ function Mh() {
6023
6023
  return x.size = u.size, x.has = function(b) {
6024
6024
  return u.has(b);
6025
6025
  }, x.get = function(b, E) {
6026
- var T = u.get(b, M);
6027
- return T === M ? E : d.call(y, T, b, u);
6026
+ var z = u.get(b, M);
6027
+ return z === M ? E : d.call(y, z, b, u);
6028
6028
  }, x.__iterateUncached = function(b, E) {
6029
- var T = this;
6029
+ var z = this;
6030
6030
  return u.__iterate(
6031
6031
  function(P, N, j) {
6032
- return b(d.call(y, P, N, j), N, T) !== !1;
6032
+ return b(d.call(y, P, N, j), N, z) !== !1;
6033
6033
  },
6034
6034
  E
6035
6035
  );
6036
6036
  }, x.__iteratorUncached = function(b, E) {
6037
- var T = u.__iterator(F, E);
6037
+ var z = u.__iterator(F, E);
6038
6038
  return new W(function() {
6039
- var P = T.next();
6039
+ var P = z.next();
6040
6040
  if (P.done)
6041
6041
  return P;
6042
6042
  var N = P.value, j = N[0];
@@ -6066,8 +6066,8 @@ function Mh() {
6066
6066
  return u.includes(x);
6067
6067
  }, y.cacheResult = Fu, y.__iterate = function(x, b) {
6068
6068
  var E = this;
6069
- return u.__iterate(function(T, P) {
6070
- return x(T, P, E);
6069
+ return u.__iterate(function(z, P) {
6070
+ return x(z, P, E);
6071
6071
  }, !b);
6072
6072
  }, y.__iterator = function(x, b) {
6073
6073
  return u.__iterator(x, !b);
@@ -6076,19 +6076,19 @@ function Mh() {
6076
6076
  function cf(u, d, y, x) {
6077
6077
  var b = Br(u);
6078
6078
  return x && (b.has = function(E) {
6079
- var T = u.get(E, M);
6080
- return T !== M && !!d.call(y, T, E, u);
6081
- }, b.get = function(E, T) {
6079
+ var z = u.get(E, M);
6080
+ return z !== M && !!d.call(y, z, E, u);
6081
+ }, b.get = function(E, z) {
6082
6082
  var P = u.get(E, M);
6083
- return P !== M && d.call(y, P, E, u) ? P : T;
6084
- }), b.__iterateUncached = function(E, T) {
6083
+ return P !== M && d.call(y, P, E, u) ? P : z;
6084
+ }), b.__iterateUncached = function(E, z) {
6085
6085
  var P = this, N = 0;
6086
6086
  return u.__iterate(function(j, B, nt) {
6087
6087
  if (d.call(y, j, B, nt))
6088
6088
  return N++, E(j, x ? B : N - 1, P);
6089
- }, T), N;
6090
- }, b.__iteratorUncached = function(E, T) {
6091
- var P = u.__iterator(F, T), N = 0;
6089
+ }, z), N;
6090
+ }, b.__iteratorUncached = function(E, z) {
6091
+ var P = u.__iterator(F, z), N = 0;
6092
6092
  return new W(function() {
6093
6093
  for (; ; ) {
6094
6094
  var j = P.next();
@@ -6107,35 +6107,35 @@ function Mh() {
6107
6107
  x.update(
6108
6108
  d.call(y, b, E, u),
6109
6109
  0,
6110
- function(T) {
6111
- return T + 1;
6110
+ function(z) {
6111
+ return z + 1;
6112
6112
  }
6113
6113
  );
6114
6114
  }), x.asImmutable();
6115
6115
  }
6116
6116
  function v0(u, d, y) {
6117
6117
  var x = c(u), b = (g(u) ? ie() : Ct()).asMutable();
6118
- u.__iterate(function(T, P) {
6118
+ u.__iterate(function(z, P) {
6119
6119
  b.update(
6120
- d.call(y, T, P, u),
6120
+ d.call(y, z, P, u),
6121
6121
  function(N) {
6122
- return N = N || [], N.push(x ? [P, T] : T), N;
6122
+ return N = N || [], N.push(x ? [P, z] : z), N;
6123
6123
  }
6124
6124
  );
6125
6125
  });
6126
6126
  var E = mf(u);
6127
- return b.map(function(T) {
6128
- return Dt(u, E(T));
6127
+ return b.map(function(z) {
6128
+ return Dt(u, E(z));
6129
6129
  });
6130
6130
  }
6131
6131
  function Lu(u, d, y, x) {
6132
6132
  var b = u.size;
6133
6133
  if (d !== void 0 && (d = d | 0), y !== void 0 && (y === 1 / 0 ? y = b : y = y | 0), mt(d, y, b))
6134
6134
  return u;
6135
- var E = dt(d, b), T = ot(y, b);
6136
- if (E !== E || T !== T)
6135
+ var E = dt(d, b), z = ot(y, b);
6136
+ if (E !== E || z !== z)
6137
6137
  return Lu(u.toSeq().cacheResult(), d, y, x);
6138
- var P = T - E, N;
6138
+ var P = z - E, N;
6139
6139
  P === P && (N = P < 0 ? 0 : P);
6140
6140
  var j = Br(u);
6141
6141
  return j.size = N === 0 ? N : u.size && N || void 0, !x && qe(u) && N >= 0 && (j.get = function(B, nt) {
@@ -6168,17 +6168,17 @@ function Mh() {
6168
6168
  function x0(u, d, y) {
6169
6169
  var x = Br(u);
6170
6170
  return x.__iterateUncached = function(b, E) {
6171
- var T = this;
6171
+ var z = this;
6172
6172
  if (E)
6173
6173
  return this.cacheResult().__iterate(b, E);
6174
6174
  var P = 0;
6175
6175
  return u.__iterate(
6176
6176
  function(N, j, B) {
6177
- return d.call(y, N, j, B) && ++P && b(N, j, T);
6177
+ return d.call(y, N, j, B) && ++P && b(N, j, z);
6178
6178
  }
6179
6179
  ), P;
6180
6180
  }, x.__iteratorUncached = function(b, E) {
6181
- var T = this;
6181
+ var z = this;
6182
6182
  if (E)
6183
6183
  return this.cacheResult().__iterator(b, E);
6184
6184
  var P = u.__iterator(F, E), N = !0;
@@ -6189,26 +6189,26 @@ function Mh() {
6189
6189
  if (j.done)
6190
6190
  return j;
6191
6191
  var B = j.value, nt = B[0], at = B[1];
6192
- return d.call(y, at, nt, T) ? b === F ? j : Q(b, nt, at, j) : (N = !1, H());
6192
+ return d.call(y, at, nt, z) ? b === F ? j : Q(b, nt, at, j) : (N = !1, H());
6193
6193
  });
6194
6194
  }, x;
6195
6195
  }
6196
6196
  function hf(u, d, y, x) {
6197
6197
  var b = Br(u);
6198
- return b.__iterateUncached = function(E, T) {
6198
+ return b.__iterateUncached = function(E, z) {
6199
6199
  var P = this;
6200
- if (T)
6201
- return this.cacheResult().__iterate(E, T);
6200
+ if (z)
6201
+ return this.cacheResult().__iterate(E, z);
6202
6202
  var N = !0, j = 0;
6203
6203
  return u.__iterate(function(B, nt, at) {
6204
6204
  if (!(N && (N = d.call(y, B, nt, at))))
6205
6205
  return j++, E(B, x ? nt : j - 1, P);
6206
6206
  }), j;
6207
- }, b.__iteratorUncached = function(E, T) {
6207
+ }, b.__iteratorUncached = function(E, z) {
6208
6208
  var P = this;
6209
- if (T)
6210
- return this.cacheResult().__iterator(E, T);
6211
- var N = u.__iterator(F, T), j = !0, B = 0;
6209
+ if (z)
6210
+ return this.cacheResult().__iterator(E, z);
6211
+ var N = u.__iterator(F, z), j = !0, B = 0;
6212
6212
  return new W(function() {
6213
6213
  var nt, at, bt;
6214
6214
  do {
@@ -6222,10 +6222,10 @@ function Mh() {
6222
6222
  }, b;
6223
6223
  }
6224
6224
  function _0(u, d) {
6225
- var y = c(u), x = [u].concat(d).map(function(T) {
6226
- return l(T) ? y && (T = s(T)) : T = y ? Un(T) : yi(Array.isArray(T) ? T : [T]), T;
6227
- }).filter(function(T) {
6228
- return T.size !== 0;
6225
+ var y = c(u), x = [u].concat(d).map(function(z) {
6226
+ return l(z) ? y && (z = s(z)) : z = y ? Un(z) : yi(Array.isArray(z) ? z : [z]), z;
6227
+ }).filter(function(z) {
6228
+ return z.size !== 0;
6229
6229
  });
6230
6230
  if (x.length === 0)
6231
6231
  return u;
@@ -6236,11 +6236,11 @@ function Mh() {
6236
6236
  }
6237
6237
  var E = new ft(x);
6238
6238
  return y ? E = E.toKeyedSeq() : h(u) || (E = E.toSetSeq()), E = E.flatten(!0), E.size = x.reduce(
6239
- function(T, P) {
6240
- if (T !== void 0) {
6239
+ function(z, P) {
6240
+ if (z !== void 0) {
6241
6241
  var N = P.size;
6242
6242
  if (N !== void 0)
6243
- return T + N;
6243
+ return z + N;
6244
6244
  }
6245
6245
  },
6246
6246
  0
@@ -6249,26 +6249,26 @@ function Mh() {
6249
6249
  function ff(u, d, y) {
6250
6250
  var x = Br(u);
6251
6251
  return x.__iterateUncached = function(b, E) {
6252
- var T = 0, P = !1;
6252
+ var z = 0, P = !1;
6253
6253
  function N(j, B) {
6254
6254
  var nt = this;
6255
6255
  j.__iterate(function(at, bt) {
6256
- return (!d || B < d) && l(at) ? N(at, B + 1) : b(at, y ? bt : T++, nt) === !1 && (P = !0), !P;
6256
+ return (!d || B < d) && l(at) ? N(at, B + 1) : b(at, y ? bt : z++, nt) === !1 && (P = !0), !P;
6257
6257
  }, E);
6258
6258
  }
6259
- return N(u, 0), T;
6259
+ return N(u, 0), z;
6260
6260
  }, x.__iteratorUncached = function(b, E) {
6261
- var T = u.__iterator(b, E), P = [], N = 0;
6261
+ var z = u.__iterator(b, E), P = [], N = 0;
6262
6262
  return new W(function() {
6263
- for (; T; ) {
6264
- var j = T.next();
6263
+ for (; z; ) {
6264
+ var j = z.next();
6265
6265
  if (j.done !== !1) {
6266
- T = P.pop();
6266
+ z = P.pop();
6267
6267
  continue;
6268
6268
  }
6269
6269
  var B = j.value;
6270
6270
  if (b === F && (B = B[1]), (!d || P.length < d) && l(B))
6271
- P.push(T), T = B.__iterator(b, E);
6271
+ P.push(z), z = B.__iterator(b, E);
6272
6272
  else
6273
6273
  return y ? j : Q(b, N++, B, j);
6274
6274
  }
@@ -6287,34 +6287,34 @@ function Mh() {
6287
6287
  function w0(u, d) {
6288
6288
  var y = Br(u);
6289
6289
  return y.size = u.size && u.size * 2 - 1, y.__iterateUncached = function(x, b) {
6290
- var E = this, T = 0;
6290
+ var E = this, z = 0;
6291
6291
  return u.__iterate(
6292
6292
  function(P, N) {
6293
- return (!T || x(d, T++, E) !== !1) && x(P, T++, E) !== !1;
6293
+ return (!z || x(d, z++, E) !== !1) && x(P, z++, E) !== !1;
6294
6294
  },
6295
6295
  b
6296
- ), T;
6296
+ ), z;
6297
6297
  }, y.__iteratorUncached = function(x, b) {
6298
- var E = u.__iterator(k, b), T = 0, P;
6298
+ var E = u.__iterator(k, b), z = 0, P;
6299
6299
  return new W(function() {
6300
- return (!P || T % 2) && (P = E.next(), P.done) ? P : T % 2 ? Q(x, T++, d) : Q(x, T++, P.value, P);
6300
+ return (!P || z % 2) && (P = E.next(), P.done) ? P : z % 2 ? Q(x, z++, d) : Q(x, z++, P.value, P);
6301
6301
  });
6302
6302
  }, y;
6303
6303
  }
6304
6304
  function Ei(u, d, y) {
6305
6305
  d || (d = yf);
6306
6306
  var x = c(u), b = 0, E = u.toSeq().map(
6307
- function(T, P) {
6308
- return [P, T, b++, y ? y(T, P, u) : T];
6307
+ function(z, P) {
6308
+ return [P, z, b++, y ? y(z, P, u) : z];
6309
6309
  }
6310
6310
  ).toArray();
6311
- return E.sort(function(T, P) {
6312
- return d(T[3], P[3]) || T[2] - P[2];
6311
+ return E.sort(function(z, P) {
6312
+ return d(z[3], P[3]) || z[2] - P[2];
6313
6313
  }).forEach(
6314
- x ? function(T, P) {
6314
+ x ? function(z, P) {
6315
6315
  E[P].length = 2;
6316
- } : function(T, P) {
6317
- E[P] = T[1];
6316
+ } : function(z, P) {
6317
+ E[P] = z[1];
6318
6318
  }
6319
6319
  ), x ? Ft(E) : h(u) ? Pt(E) : Ot(E);
6320
6320
  }
@@ -6340,18 +6340,18 @@ function Mh() {
6340
6340
  return x.size = new ft(y).map(function(b) {
6341
6341
  return b.size;
6342
6342
  }).min(), x.__iterate = function(b, E) {
6343
- for (var T = this.__iterator(k, E), P, N = 0; !(P = T.next()).done && b(P.value, N++, this) !== !1; )
6343
+ for (var z = this.__iterator(k, E), P, N = 0; !(P = z.next()).done && b(P.value, N++, this) !== !1; )
6344
6344
  ;
6345
6345
  return N;
6346
6346
  }, x.__iteratorUncached = function(b, E) {
6347
- var T = y.map(
6347
+ var z = y.map(
6348
6348
  function(j) {
6349
6349
  return j = i(j), D(E ? j.reverse() : j);
6350
6350
  }
6351
6351
  ), P = 0, N = !1;
6352
6352
  return new W(function() {
6353
6353
  var j;
6354
- return N || (j = T.map(function(B) {
6354
+ return N || (j = z.map(function(B) {
6355
6355
  return B.next();
6356
6356
  }), N = j.some(function(B) {
6357
6357
  return B.done;
@@ -6400,17 +6400,17 @@ function Mh() {
6400
6400
  }
6401
6401
  r(Ge, Os);
6402
6402
  function Ge(u, d) {
6403
- var y, x = function(T) {
6404
- if (T instanceof x)
6405
- return T;
6403
+ var y, x = function(z) {
6404
+ if (z instanceof x)
6405
+ return z;
6406
6406
  if (!(this instanceof x))
6407
- return new x(T);
6407
+ return new x(z);
6408
6408
  if (!y) {
6409
6409
  y = !0;
6410
6410
  var P = Object.keys(u);
6411
6411
  S0(b, P), b.size = P.length, b._name = d, b._keys = P, b._defaultValues = u;
6412
6412
  }
6413
- this._map = Ct(T);
6413
+ this._map = Ct(z);
6414
6414
  }, b = x.prototype = Object.create(Se);
6415
6415
  return b.constructor = x, x;
6416
6416
  }
@@ -6774,7 +6774,7 @@ function Mh() {
6774
6774
  return le(c(this) ? this.valueSeq() : this);
6775
6775
  },
6776
6776
  toList: function() {
6777
- return Yt(c(this) ? this.valueSeq() : this);
6777
+ return Xt(c(this) ? this.valueSeq() : this);
6778
6778
  },
6779
6779
  // ### Common JavaScript methods and properties
6780
6780
  toString: function() {
@@ -6790,7 +6790,7 @@ function Mh() {
6790
6790
  },
6791
6791
  includes: function(u) {
6792
6792
  return this.some(function(d) {
6793
- return ee(d, u);
6793
+ return re(d, u);
6794
6794
  });
6795
6795
  },
6796
6796
  entries: function() {
@@ -6830,8 +6830,8 @@ function Mh() {
6830
6830
  reduce: function(u, d, y) {
6831
6831
  He(this.size);
6832
6832
  var x, b;
6833
- return arguments.length < 2 ? b = !0 : x = d, this.__iterate(function(E, T, P) {
6834
- b ? (b = !1, x = E) : x = u.call(y, x, E, T, P);
6833
+ return arguments.length < 2 ? b = !0 : x = d, this.__iterate(function(E, z, P) {
6834
+ b ? (b = !1, x = E) : x = u.call(y, x, E, z, P);
6835
6835
  }), x;
6836
6836
  },
6837
6837
  reduceRight: function(u, d, y) {
@@ -6887,8 +6887,8 @@ function Mh() {
6887
6887
  },
6888
6888
  findEntry: function(u, d, y) {
6889
6889
  var x = y;
6890
- return this.__iterate(function(b, E, T) {
6891
- if (u.call(d, b, E, T))
6890
+ return this.__iterate(function(b, E, z) {
6891
+ if (u.call(d, b, E, z))
6892
6892
  return x = [E, b], !1;
6893
6893
  }), x;
6894
6894
  },
@@ -6919,7 +6919,7 @@ function Mh() {
6919
6919
  },
6920
6920
  get: function(u, d) {
6921
6921
  return this.find(function(y, x) {
6922
- return ee(x, u);
6922
+ return re(x, u);
6923
6923
  }, void 0, d);
6924
6924
  },
6925
6925
  getIn: function(u, d) {
@@ -6949,7 +6949,7 @@ function Mh() {
6949
6949
  },
6950
6950
  keyOf: function(u) {
6951
6951
  return this.findKey(function(d) {
6952
- return ee(d, u);
6952
+ return re(d, u);
6953
6953
  });
6954
6954
  },
6955
6955
  keySeq: function() {
@@ -7171,10 +7171,10 @@ function Mh() {
7171
7171
  if (u.size === 1 / 0)
7172
7172
  return 0;
7173
7173
  var d = g(u), y = c(u), x = d ? 1 : 0, b = u.__iterate(
7174
- y ? d ? function(E, T) {
7175
- x = 31 * x + If($e(E), $e(T)) | 0;
7176
- } : function(E, T) {
7177
- x = x + If($e(E), $e(T)) | 0;
7174
+ y ? d ? function(E, z) {
7175
+ x = 31 * x + If($e(E), $e(z)) | 0;
7176
+ } : function(E, z) {
7177
+ x = x + If($e(E), $e(z)) | 0;
7178
7178
  } : d ? function(E) {
7179
7179
  x = 31 * x + $e(E) | 0;
7180
7180
  } : function(E) {
@@ -7192,17 +7192,17 @@ function Mh() {
7192
7192
  var C0 = {
7193
7193
  Iterable: i,
7194
7194
  Seq: _t,
7195
- Collection: En,
7195
+ Collection: An,
7196
7196
  Map: Ct,
7197
7197
  OrderedMap: ie,
7198
- List: Yt,
7198
+ List: Xt,
7199
7199
  Stack: le,
7200
7200
  Set: Kt,
7201
7201
  OrderedSet: qr,
7202
7202
  Record: Ge,
7203
7203
  Range: we,
7204
7204
  Repeat: ye,
7205
- is: ee,
7205
+ is: re,
7206
7206
  fromJS: Dr
7207
7207
  };
7208
7208
  return C0;
@@ -7306,21 +7306,21 @@ function zx() {
7306
7306
  var _ = [], S = v || "";
7307
7307
  if (n.is(p, m) || p == m == null)
7308
7308
  return _;
7309
- var A = l(p) && l(m), C = null, O = null;
7310
- return p.forEach && p.forEach(function(M, z) {
7311
- if (m.has(z))
7312
- if (a(M) && a(m.get(z)))
7313
- _ = _.concat(c(M, m.get(z), i(S, s(z))));
7314
- else if (l(m.get(z)) && l(M))
7315
- _ = _.concat(h(M, m.get(z), i(S, s(z))));
7309
+ var A = l(p) && l(m), T = null, C = null;
7310
+ return p.forEach && p.forEach(function(M, O) {
7311
+ if (m.has(O))
7312
+ if (a(M) && a(m.get(O)))
7313
+ _ = _.concat(c(M, m.get(O), i(S, s(O))));
7314
+ else if (l(m.get(O)) && l(M))
7315
+ _ = _.concat(h(M, m.get(O), i(S, s(O))));
7316
7316
  else {
7317
- var R = m.get ? m.get(z) : m, I = M !== R;
7318
- I && _.push(o("replace", i(S, s(z)), R));
7317
+ var R = m.get ? m.get(O) : m, I = M !== R;
7318
+ I && _.push(o("replace", i(S, s(O)), R));
7319
7319
  }
7320
7320
  else
7321
- A ? (O = C != null && C + 1 === z ? O : z, _.push(o("remove", i(S, s(O)))), C = z) : _.push(o("remove", i(S, s(z))));
7322
- }), m.forEach(function(M, z) {
7323
- p.has && !p.has(z) && _.push(o("add", i(S, s(z)), M));
7321
+ A ? (C = T != null && T + 1 === O ? C : O, _.push(o("remove", i(S, s(C)))), T = O) : _.push(o("remove", i(S, s(O))));
7322
+ }), m.forEach(function(M, O) {
7323
+ p.has && !p.has(O) && _.push(o("add", i(S, s(O)), M));
7324
7324
  }), _;
7325
7325
  }, h = function(p, m, v) {
7326
7326
  var _ = [], S = v || "";
@@ -7328,18 +7328,18 @@ function zx() {
7328
7328
  return _;
7329
7329
  if ((p.count() + 1) * (m.count() + 1) >= 1e4)
7330
7330
  return c(p, m, v);
7331
- var A = e.diff(p, m), C = 0;
7332
- return A.forEach(function(O) {
7333
- if (O.op === "=")
7334
- C++;
7335
- else if (O.op === "!=") {
7336
- if (a(O.val) && a(O.newVal)) {
7337
- var M = c(O.val, O.newVal, i(S, C));
7331
+ var A = e.diff(p, m), T = 0;
7332
+ return A.forEach(function(C) {
7333
+ if (C.op === "=")
7334
+ T++;
7335
+ else if (C.op === "!=") {
7336
+ if (a(C.val) && a(C.newVal)) {
7337
+ var M = c(C.val, C.newVal, i(S, T));
7338
7338
  _ = _.concat(M);
7339
7339
  } else
7340
- _.push(o("replace", i(S, C), O.newVal));
7341
- C++;
7342
- } else O.op === "+" ? (_.push(o("add", i(S, C), O.val)), C++) : O.op === "-" && _.push(o("remove", i(S, C)));
7340
+ _.push(o("replace", i(S, T), C.newVal));
7341
+ T++;
7342
+ } else C.op === "+" ? (_.push(o("add", i(S, T), C.val)), T++) : C.op === "-" && _.push(o("remove", i(S, T)));
7343
7343
  }), _;
7344
7344
  }, f = function(p, m, v) {
7345
7345
  var _ = v || "";
@@ -7740,12 +7740,12 @@ class fe {
7740
7740
  ), v = xc(
7741
7741
  { x: h, y: f },
7742
7742
  { x: g, y: p }
7743
- ), _ = s.factoryElement(t.drawingSupport.get("type")).properties.getIn(["width", "length"]), S = Ce(h, f, g, p), A = Zv(h, f, g, p), C = Qv(A, 1e-7), O = tx(A, 1e-7), M = {
7744
- x: m.x + _ / 2 * C,
7745
- y: m.y + _ / 2 * O
7746
- }, z = {
7747
- x: m.x + S * C - _ / 2 * C,
7748
- y: m.y + S * O - _ / 2 * O
7743
+ ), _ = s.factoryElement(t.drawingSupport.get("type")).properties.getIn(["width", "length"]), S = Ce(h, f, g, p), A = Zv(h, f, g, p), T = Qv(A, 1e-7), C = tx(A, 1e-7), M = {
7744
+ x: m.x + _ / 2 * T,
7745
+ y: m.y + _ / 2 * C
7746
+ }, O = {
7747
+ x: m.x + S * T - _ / 2 * T,
7748
+ y: m.y + S * C - _ / 2 * C
7749
7749
  }, R;
7750
7750
  if (r < M.x ? R = Oe(
7751
7751
  m.x,
@@ -7754,27 +7754,27 @@ class fe {
7754
7754
  v.y,
7755
7755
  M.x,
7756
7756
  M.y
7757
- ) : r > z.x ? R = Oe(
7757
+ ) : r > O.x ? R = Oe(
7758
7758
  m.x,
7759
7759
  m.y,
7760
7760
  v.x,
7761
7761
  v.y,
7762
- z.x,
7763
- z.y
7764
- ) : r === M.x && r === z.x ? i < M.y ? (R = Oe(
7762
+ O.x,
7763
+ O.y
7764
+ ) : r === M.x && r === O.x ? i < M.y ? (R = Oe(
7765
7765
  m.x,
7766
7766
  m.y,
7767
7767
  v.x,
7768
7768
  v.y,
7769
7769
  M.x,
7770
7770
  M.y
7771
- ), R = m.x === h && m.y === f ? R : 1 - R) : i > z.y ? (R = Oe(
7771
+ ), R = m.x === h && m.y === f ? R : 1 - R) : i > O.y ? (R = Oe(
7772
7772
  m.x,
7773
7773
  m.y,
7774
7774
  v.x,
7775
7775
  v.y,
7776
- z.x,
7777
- z.y
7776
+ O.x,
7777
+ O.y
7778
7778
  ), R = m.x === h && m.y === f ? R : 1 - R) : R = Oe(
7779
7779
  h,
7780
7780
  f,
@@ -7862,18 +7862,18 @@ class fe {
7862
7862
  if (!i) return t;
7863
7863
  let { draggingSupport: s, scene: o } = t, a = s.get("layerID"), l = s.get("holeID"), c = t.getIn(["scene", "layers", a]), h = c.getIn(["holes", l]), f = c.getIn(["lines", h.line]), g = c.getIn(["vertices", f.vertices.get(0)]), p = c.getIn(["vertices", f.vertices.get(1)]);
7864
7864
  ({ x: e, y: r } = i.point);
7865
- let m = Ra(g, p), v = xc(g, p), _ = h.properties.get("width").get("length"), S = Ce(g.x, g.y, p.x, p.y), A = Math.atan2(Math.abs(p.y - g.y), Math.abs(p.x - g.x)), C = (U) => {
7865
+ let m = Ra(g, p), v = xc(g, p), _ = h.properties.get("width").get("length"), S = Ce(g.x, g.y, p.x, p.y), A = Math.atan2(Math.abs(p.y - g.y), Math.abs(p.x - g.x)), T = (U) => {
7866
7866
  let Y = Math.cos(U);
7867
7867
  return Y < 1e-7 ? 0 : Y;
7868
- }, O = (U) => {
7868
+ }, C = (U) => {
7869
7869
  let Y = Math.sin(U);
7870
7870
  return Y < 1e-7 ? 0 : Y;
7871
- }, M = C(A), z = O(A), R = {
7871
+ }, M = T(A), O = C(A), R = {
7872
7872
  x: m.x + _ / 2 * M,
7873
- y: m.y + _ / 2 * z
7873
+ y: m.y + _ / 2 * O
7874
7874
  }, I = {
7875
7875
  x: m.x + S * M - _ / 2 * M,
7876
- y: m.y + S * z - _ / 2 * z
7876
+ y: m.y + S * O - _ / 2 * O
7877
7877
  }, L;
7878
7878
  return e < R.x ? L = Oe(
7879
7879
  m.x,
@@ -8066,7 +8066,7 @@ let ge = class Lm {
8066
8066
  }
8067
8067
  static beginRotatingItem(t, e, r, i, s) {
8068
8068
  return t = t.merge({
8069
- mode: Sn,
8069
+ mode: Mn,
8070
8070
  rotatingSupport: Z({
8071
8071
  layerID: e,
8072
8072
  itemID: r
@@ -8209,8 +8209,8 @@ let ge = class Lm {
8209
8209
  "vertices"
8210
8210
  ]).map(
8211
8211
  (M) => t.getIn(["scene", "layers", a, "vertices", M])
8212
- ), { x: v, y: _ } = m.get(0), { x: S, y: A } = m.get(1), { x: C, y: O } = ex(v, _, S, A);
8213
- i += C, s += O, o++;
8212
+ ), { x: v, y: _ } = m.get(0), { x: S, y: A } = m.get(1), { x: T, y: C } = ex(v, _, S, A);
8213
+ i += T, s += C, o++;
8214
8214
  }), h && h.forEach((p) => {
8215
8215
  let m = t.getIn([
8216
8216
  "scene",
@@ -8226,15 +8226,15 @@ let ge = class Lm {
8226
8226
  m.line,
8227
8227
  "vertices"
8228
8228
  ]).map(
8229
- (z) => t.getIn(["scene", "layers", a, "vertices", z])
8230
- ), { x: _, y: S } = v.get(0), { x: A, y: C } = v.get(1), { x: O, y: M } = uu(
8229
+ (O) => t.getIn(["scene", "layers", a, "vertices", O])
8230
+ ), { x: _, y: S } = v.get(0), { x: A, y: T } = v.get(1), { x: C, y: M } = uu(
8231
8231
  _,
8232
8232
  S,
8233
8233
  A,
8234
- C,
8235
- m.offset * Ce(_, S, A, C)
8234
+ T,
8235
+ m.offset * Ce(_, S, A, T)
8236
8236
  );
8237
- i += O, s += M, o++;
8237
+ i += C, s += M, o++;
8238
8238
  }), f && f.forEach((p) => {
8239
8239
  let { x: m, y: v } = t.getIn([
8240
8240
  "scene",
@@ -8424,7 +8424,7 @@ let ge = class Lm {
8424
8424
  g && (t = g.map(
8425
8425
  (p) => t.getIn(["scene", "layers", c, "items", p])
8426
8426
  ).reduce((p, m) => {
8427
- let { x: v, y: _, rotation: S } = m, { x: A, y: C } = ad(
8427
+ let { x: v, y: _, rotation: S } = m, { x: A, y: T } = ad(
8428
8428
  v,
8429
8429
  _,
8430
8430
  i,
@@ -8435,7 +8435,7 @@ let ge = class Lm {
8435
8435
  p,
8436
8436
  c,
8437
8437
  m.id,
8438
- Z({ x: A, y: C, rotation: S + a })
8438
+ Z({ x: A, y: T, rotation: S + a })
8439
8439
  ).updatedState;
8440
8440
  }, t)), t = gt.detectAndUpdateAreas(t, c).updatedState;
8441
8441
  }), t = Oa.select(t, e).updatedState, { updatedState: t };
@@ -8565,10 +8565,10 @@ let ge = class Lm {
8565
8565
  i,
8566
8566
  s
8567
8567
  ), A = Ra(a, l);
8568
- return o.holes.forEach((O) => {
8569
- let M = t.getIn(["scene", "layers", e, "holes", O]), z = M.offset;
8570
- if (A.x === f && A.y === g && (S = 1 - S, z = 1 - M.offset), z < S) {
8571
- let R = z / S;
8568
+ return o.holes.forEach((C) => {
8569
+ let M = t.getIn(["scene", "layers", e, "holes", C]), O = M.offset;
8570
+ if (A.x === f && A.y === g && (S = 1 - S, O = 1 - M.offset), O < S) {
8571
+ let R = O / S;
8572
8572
  A.x === f && A.y === g && (R = 1 - R), t = fe.create(
8573
8573
  t,
8574
8574
  e,
@@ -8578,7 +8578,7 @@ let ge = class Lm {
8578
8578
  M.properties
8579
8579
  ).updatedState;
8580
8580
  } else {
8581
- let R = (z - S) / (1 - S);
8581
+ let R = (O - S) / (1 - S);
8582
8582
  A.x === f && A.y === g && (R = 1 - R), t = fe.create(
8583
8583
  t,
8584
8584
  e,
@@ -8588,19 +8588,19 @@ let ge = class Lm {
8588
8588
  M.properties
8589
8589
  ).updatedState;
8590
8590
  }
8591
- }), t.getIn(["scene", "groups"]).filter((O) => {
8592
- const M = O.getIn(["elements", e, "lines"]);
8591
+ }), t.getIn(["scene", "groups"]).filter((C) => {
8592
+ const M = C.getIn(["elements", e, "lines"]);
8593
8593
  return M && M.contains(r);
8594
- }).forEach((O) => {
8594
+ }).forEach((C) => {
8595
8595
  t = he.addElement(
8596
8596
  t,
8597
- O.id,
8597
+ C.id,
8598
8598
  e,
8599
8599
  "lines",
8600
8600
  m.id
8601
8601
  ).updatedState, t = he.addElement(
8602
8602
  t,
8603
- O.id,
8603
+ C.id,
8604
8604
  e,
8605
8605
  "lines",
8606
8606
  _.id
@@ -8654,7 +8654,7 @@ let ge = class Lm {
8654
8654
  { x: o, y: a }
8655
8655
  ];
8656
8656
  t = t.getIn(["scene", "layers", e, "lines"]).reduce((p, m) => {
8657
- var C, O;
8657
+ var T, C;
8658
8658
  let [v, _] = m.vertices.map(
8659
8659
  (M) => p.getIn(["scene", "layers", e, "vertices"]).get(M)
8660
8660
  ).toArray(), S = Or(v, h[0]) || Or(v, h[1]) || Or(_, h[0]) || Or(_, h[1]), A = Wv(
@@ -8666,13 +8666,13 @@ let ge = class Lm {
8666
8666
  if (A.type === "colinear") {
8667
8667
  c || (c = []);
8668
8668
  const M = ro(h);
8669
- p.getIn(["scene", "layers", e, "lines", m.id, "holes"]).forEach((z) => {
8669
+ p.getIn(["scene", "layers", e, "lines", m.id, "holes"]).forEach((O) => {
8670
8670
  let R = p.getIn([
8671
8671
  "scene",
8672
8672
  "layers",
8673
8673
  e,
8674
8674
  "holes",
8675
- z
8675
+ O
8676
8676
  ]), I = Ce(
8677
8677
  v.x,
8678
8678
  v.y,
@@ -8699,8 +8699,8 @@ let ge = class Lm {
8699
8699
  p,
8700
8700
  e,
8701
8701
  m.id,
8702
- ((C = A.point) == null ? void 0 : C.x) ?? 0,
8703
- ((O = A.point) == null ? void 0 : O.y) ?? 0
8702
+ ((T = A.point) == null ? void 0 : T.x) ?? 0,
8703
+ ((C = A.point) == null ? void 0 : C.y) ?? 0
8704
8704
  ).updatedState, h.push(A.point ?? { x: 0, y: 0 })), p;
8705
8705
  }, t);
8706
8706
  let { updatedState: f, lines: g } = ur.addFromPoints(
@@ -8863,15 +8863,15 @@ let ge = class Lm {
8863
8863
  activeSnapElement: m,
8864
8864
  scene: t.scene.updateIn(
8865
8865
  ["layers", o],
8866
- (C) => C.withMutations((O) => {
8867
- let M = O.getIn(["lines", a, "vertices"]);
8868
- return O.updateIn(
8866
+ (T) => T.withMutations((C) => {
8867
+ let M = C.getIn(["lines", a, "vertices"]);
8868
+ return C.updateIn(
8869
8869
  ["vertices", M.get(0)],
8870
- (z) => z.merge({ x: h, y: f })
8871
- ), O.updateIn(
8870
+ (O) => O.merge({ x: h, y: f })
8871
+ ), C.updateIn(
8872
8872
  ["vertices", M.get(1)],
8873
- (z) => z.merge({ x: g, y: p })
8874
- ), O;
8873
+ (O) => O.merge({ x: g, y: p })
8874
+ ), C;
8875
8875
  })
8876
8876
  )
8877
8877
  }), { updatedState: t };
@@ -8885,22 +8885,22 @@ let ge = class Lm {
8885
8885
  };
8886
8886
  v.push({ hole: I, offsetPosition: U });
8887
8887
  });
8888
- let _ = e - i.get("startPointX"), S = r - i.get("startPointY"), A = i.get("startVertex0X") + _, C = i.get("startVertex0Y") + S, O = i.get("startVertex1X") + _, M = i.get("startVertex1Y") + S;
8888
+ let _ = e - i.get("startPointX"), S = r - i.get("startPointY"), A = i.get("startVertex0X") + _, T = i.get("startVertex0Y") + S, C = i.get("startVertex1X") + _, M = i.get("startVertex1Y") + S;
8889
8889
  if (t.snapMask && !t.snapMask.isEmpty()) {
8890
8890
  let R = Wr(
8891
8891
  t.snapElements,
8892
8892
  A,
8893
- C,
8893
+ T,
8894
8894
  t.snapMask
8895
8895
  ), I = Wr(
8896
8896
  t.snapElements,
8897
- O,
8897
+ C,
8898
8898
  M,
8899
8899
  t.snapMask
8900
8900
  ), L = 0, U = 0;
8901
- R && I ? R.point.distance < I.point.distance ? (L = R.point.x - A, U = R.point.y - C) : (L = I.point.x - O, U = I.point.y - M) : (R && (L = R.point.x - A, U = R.point.y - C), I && (L = I.point.x - O, U = I.point.y - M)), A += L, C += U, O += L, M += U;
8901
+ R && I ? R.point.distance < I.point.distance ? (L = R.point.x - A, U = R.point.y - T) : (L = I.point.x - C, U = I.point.y - M) : (R && (L = R.point.x - A, U = R.point.y - T), I && (L = I.point.x - C, U = I.point.y - M)), A += L, T += U, C += L, M += U;
8902
8902
  }
8903
- let z = t.getIn(["scene", "groups"]).filter((R) => {
8903
+ let O = t.getIn(["scene", "groups"]).filter((R) => {
8904
8904
  const I = R.getIn(["elements", s, "lines"]);
8905
8905
  return I && I.contains(a);
8906
8906
  });
@@ -8913,22 +8913,22 @@ let ge = class Lm {
8913
8913
  s,
8914
8914
  l.vertices.get(1)
8915
8915
  ).updatedState, t = ur.remove(t, s, a).updatedState, !Or(
8916
- { x: A, y: C },
8917
- { x: O, y: M }
8916
+ { x: A, y: T },
8917
+ { x: C, y: M }
8918
8918
  )) {
8919
8919
  let R = ur.createAvoidingIntersections(
8920
8920
  t,
8921
8921
  s,
8922
8922
  l.type,
8923
8923
  A,
8924
+ T,
8924
8925
  C,
8925
- O,
8926
8926
  M,
8927
8927
  l.properties,
8928
8928
  v
8929
8929
  );
8930
8930
  t = R.updatedState, R.lines.forEach((I) => {
8931
- z.forEach((L) => {
8931
+ O.forEach((L) => {
8932
8932
  t = he.addElement(
8933
8933
  t,
8934
8934
  L.id,
@@ -9159,13 +9159,13 @@ let ge = class Lm {
9159
9159
  i
9160
9160
  ]), p = [], m = ro([f, g]);
9161
9161
  o.getIn(["scene", "layers", r, "lines", a, "holes"]).forEach((A) => {
9162
- let C = o.getIn([
9162
+ let T = o.getIn([
9163
9163
  "scene",
9164
9164
  "layers",
9165
9165
  r,
9166
9166
  "holes",
9167
9167
  A
9168
- ]), O = Ce(
9168
+ ]), C = Ce(
9169
9169
  f.x,
9170
9170
  f.y,
9171
9171
  g.x,
@@ -9181,14 +9181,14 @@ let ge = class Lm {
9181
9181
  "vertices",
9182
9182
  1
9183
9183
  ])
9184
- ) ? 1 - C.offset : C.offset, z = uu(
9184
+ ) ? 1 - T.offset : T.offset, O = uu(
9185
9185
  f.x,
9186
9186
  f.y,
9187
9187
  g.x,
9188
9188
  g.y,
9189
- O * M
9189
+ C * M
9190
9190
  );
9191
- p.push({ hole: C, offsetPosition: z });
9191
+ p.push({ hole: T, offsetPosition: O });
9192
9192
  });
9193
9193
  let v = o.getIn([
9194
9194
  "scene",
@@ -9205,8 +9205,8 @@ let ge = class Lm {
9205
9205
  a,
9206
9206
  "properties"
9207
9207
  ]), S = o.getIn(["scene", "groups"]).filter((A) => {
9208
- const C = A.getIn(["elements", r, "lines"]);
9209
- return C && C.contains(a);
9208
+ const T = A.getIn(["elements", r, "lines"]);
9209
+ return T && T.contains(a);
9210
9210
  });
9211
9211
  if (o = gt.removeZeroLengthLines(
9212
9212
  o,
@@ -9227,14 +9227,14 @@ let ge = class Lm {
9227
9227
  _,
9228
9228
  p
9229
9229
  );
9230
- o = A.updatedState, A.lines.forEach((C) => {
9231
- S.forEach((O) => {
9230
+ o = A.updatedState, A.lines.forEach((T) => {
9231
+ S.forEach((C) => {
9232
9232
  o = he.addElement(
9233
9233
  o,
9234
- O.id,
9234
+ C.id,
9235
9235
  r,
9236
9236
  "lines",
9237
- C.id
9237
+ T.id
9238
9238
  ).updatedState;
9239
9239
  });
9240
9240
  });
@@ -9891,10 +9891,10 @@ function Zx() {
9891
9891
  if (kd) return Lt;
9892
9892
  kd = 1;
9893
9893
  var n = typeof Symbol == "function" && Symbol.for, t = n ? Symbol.for("react.element") : 60103, e = n ? Symbol.for("react.portal") : 60106, r = n ? Symbol.for("react.fragment") : 60107, i = n ? Symbol.for("react.strict_mode") : 60108, s = n ? Symbol.for("react.profiler") : 60114, o = n ? Symbol.for("react.provider") : 60109, a = n ? Symbol.for("react.context") : 60110, l = n ? Symbol.for("react.async_mode") : 60111, c = n ? Symbol.for("react.concurrent_mode") : 60111, h = n ? Symbol.for("react.forward_ref") : 60112, f = n ? Symbol.for("react.suspense") : 60113, g = n ? Symbol.for("react.suspense_list") : 60120, p = n ? Symbol.for("react.memo") : 60115, m = n ? Symbol.for("react.lazy") : 60116, v = n ? Symbol.for("react.block") : 60121, _ = n ? Symbol.for("react.fundamental") : 60117, S = n ? Symbol.for("react.responder") : 60118, A = n ? Symbol.for("react.scope") : 60119;
9894
- function C(M) {
9894
+ function T(M) {
9895
9895
  if (typeof M == "object" && M !== null) {
9896
- var z = M.$$typeof;
9897
- switch (z) {
9896
+ var O = M.$$typeof;
9897
+ switch (O) {
9898
9898
  case t:
9899
9899
  switch (M = M.type, M) {
9900
9900
  case l:
@@ -9913,44 +9913,44 @@ function Zx() {
9913
9913
  case o:
9914
9914
  return M;
9915
9915
  default:
9916
- return z;
9916
+ return O;
9917
9917
  }
9918
9918
  }
9919
9919
  case e:
9920
- return z;
9920
+ return O;
9921
9921
  }
9922
9922
  }
9923
9923
  }
9924
- function O(M) {
9925
- return C(M) === c;
9924
+ function C(M) {
9925
+ return T(M) === c;
9926
9926
  }
9927
9927
  return Lt.AsyncMode = l, Lt.ConcurrentMode = c, Lt.ContextConsumer = a, Lt.ContextProvider = o, Lt.Element = t, Lt.ForwardRef = h, Lt.Fragment = r, Lt.Lazy = m, Lt.Memo = p, Lt.Portal = e, Lt.Profiler = s, Lt.StrictMode = i, Lt.Suspense = f, Lt.isAsyncMode = function(M) {
9928
- return O(M) || C(M) === l;
9929
- }, Lt.isConcurrentMode = O, Lt.isContextConsumer = function(M) {
9930
- return C(M) === a;
9928
+ return C(M) || T(M) === l;
9929
+ }, Lt.isConcurrentMode = C, Lt.isContextConsumer = function(M) {
9930
+ return T(M) === a;
9931
9931
  }, Lt.isContextProvider = function(M) {
9932
- return C(M) === o;
9932
+ return T(M) === o;
9933
9933
  }, Lt.isElement = function(M) {
9934
9934
  return typeof M == "object" && M !== null && M.$$typeof === t;
9935
9935
  }, Lt.isForwardRef = function(M) {
9936
- return C(M) === h;
9936
+ return T(M) === h;
9937
9937
  }, Lt.isFragment = function(M) {
9938
- return C(M) === r;
9938
+ return T(M) === r;
9939
9939
  }, Lt.isLazy = function(M) {
9940
- return C(M) === m;
9940
+ return T(M) === m;
9941
9941
  }, Lt.isMemo = function(M) {
9942
- return C(M) === p;
9942
+ return T(M) === p;
9943
9943
  }, Lt.isPortal = function(M) {
9944
- return C(M) === e;
9944
+ return T(M) === e;
9945
9945
  }, Lt.isProfiler = function(M) {
9946
- return C(M) === s;
9946
+ return T(M) === s;
9947
9947
  }, Lt.isStrictMode = function(M) {
9948
- return C(M) === i;
9948
+ return T(M) === i;
9949
9949
  }, Lt.isSuspense = function(M) {
9950
- return C(M) === f;
9950
+ return T(M) === f;
9951
9951
  }, Lt.isValidElementType = function(M) {
9952
9952
  return typeof M == "string" || typeof M == "function" || M === r || M === c || M === s || M === i || M === f || M === g || typeof M == "object" && M !== null && (M.$$typeof === m || M.$$typeof === p || M.$$typeof === o || M.$$typeof === a || M.$$typeof === h || M.$$typeof === _ || M.$$typeof === S || M.$$typeof === A || M.$$typeof === v);
9953
- }, Lt.typeOf = C, Lt;
9953
+ }, Lt.typeOf = T, Lt;
9954
9954
  }
9955
9955
  var Nt = {};
9956
9956
  /** @license React v16.13.1
@@ -9965,11 +9965,11 @@ var Id;
9965
9965
  function Kx() {
9966
9966
  return Id || (Id = 1, process.env.NODE_ENV !== "production" && (function() {
9967
9967
  var n = typeof Symbol == "function" && Symbol.for, t = n ? Symbol.for("react.element") : 60103, e = n ? Symbol.for("react.portal") : 60106, r = n ? Symbol.for("react.fragment") : 60107, i = n ? Symbol.for("react.strict_mode") : 60108, s = n ? Symbol.for("react.profiler") : 60114, o = n ? Symbol.for("react.provider") : 60109, a = n ? Symbol.for("react.context") : 60110, l = n ? Symbol.for("react.async_mode") : 60111, c = n ? Symbol.for("react.concurrent_mode") : 60111, h = n ? Symbol.for("react.forward_ref") : 60112, f = n ? Symbol.for("react.suspense") : 60113, g = n ? Symbol.for("react.suspense_list") : 60120, p = n ? Symbol.for("react.memo") : 60115, m = n ? Symbol.for("react.lazy") : 60116, v = n ? Symbol.for("react.block") : 60121, _ = n ? Symbol.for("react.fundamental") : 60117, S = n ? Symbol.for("react.responder") : 60118, A = n ? Symbol.for("react.scope") : 60119;
9968
- function C($) {
9968
+ function T($) {
9969
9969
  return typeof $ == "string" || typeof $ == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
9970
9970
  $ === r || $ === c || $ === s || $ === i || $ === f || $ === g || typeof $ == "object" && $ !== null && ($.$$typeof === m || $.$$typeof === p || $.$$typeof === o || $.$$typeof === a || $.$$typeof === h || $.$$typeof === _ || $.$$typeof === S || $.$$typeof === A || $.$$typeof === v);
9971
9971
  }
9972
- function O($) {
9972
+ function C($) {
9973
9973
  if (typeof $ == "object" && $ !== null) {
9974
9974
  var _t = $.$$typeof;
9975
9975
  switch (_t) {
@@ -10001,47 +10001,47 @@ function Kx() {
10001
10001
  }
10002
10002
  }
10003
10003
  }
10004
- var M = l, z = c, R = a, I = o, L = t, U = h, Y = r, it = m, rt = p, yt = e, mt = s, dt = i, ot = f, G = !1;
10004
+ var M = l, O = c, R = a, I = o, L = t, U = h, Y = r, it = m, rt = p, yt = e, mt = s, dt = i, ot = f, G = !1;
10005
10005
  function pt($) {
10006
- return G || (G = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), k($) || O($) === l;
10006
+ return G || (G = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), k($) || C($) === l;
10007
10007
  }
10008
10008
  function k($) {
10009
- return O($) === c;
10009
+ return C($) === c;
10010
10010
  }
10011
10011
  function F($) {
10012
- return O($) === a;
10012
+ return C($) === a;
10013
10013
  }
10014
10014
  function K($) {
10015
- return O($) === o;
10015
+ return C($) === o;
10016
10016
  }
10017
10017
  function J($) {
10018
10018
  return typeof $ == "object" && $ !== null && $.$$typeof === t;
10019
10019
  }
10020
10020
  function et($) {
10021
- return O($) === h;
10021
+ return C($) === h;
10022
10022
  }
10023
10023
  function W($) {
10024
- return O($) === r;
10024
+ return C($) === r;
10025
10025
  }
10026
10026
  function Q($) {
10027
- return O($) === m;
10027
+ return C($) === m;
10028
10028
  }
10029
10029
  function H($) {
10030
- return O($) === p;
10030
+ return C($) === p;
10031
10031
  }
10032
10032
  function tt($) {
10033
- return O($) === e;
10033
+ return C($) === e;
10034
10034
  }
10035
10035
  function ht($) {
10036
- return O($) === s;
10036
+ return C($) === s;
10037
10037
  }
10038
10038
  function D($) {
10039
- return O($) === i;
10039
+ return C($) === i;
10040
10040
  }
10041
10041
  function ct($) {
10042
- return O($) === f;
10042
+ return C($) === f;
10043
10043
  }
10044
- Nt.AsyncMode = M, Nt.ConcurrentMode = z, Nt.ContextConsumer = R, Nt.ContextProvider = I, Nt.Element = L, Nt.ForwardRef = U, Nt.Fragment = Y, Nt.Lazy = it, Nt.Memo = rt, Nt.Portal = yt, Nt.Profiler = mt, Nt.StrictMode = dt, Nt.Suspense = ot, Nt.isAsyncMode = pt, Nt.isConcurrentMode = k, Nt.isContextConsumer = F, Nt.isContextProvider = K, Nt.isElement = J, Nt.isForwardRef = et, Nt.isFragment = W, Nt.isLazy = Q, Nt.isMemo = H, Nt.isPortal = tt, Nt.isProfiler = ht, Nt.isStrictMode = D, Nt.isSuspense = ct, Nt.isValidElementType = C, Nt.typeOf = O;
10044
+ Nt.AsyncMode = M, Nt.ConcurrentMode = O, Nt.ContextConsumer = R, Nt.ContextProvider = I, Nt.Element = L, Nt.ForwardRef = U, Nt.Fragment = Y, Nt.Lazy = it, Nt.Memo = rt, Nt.Portal = yt, Nt.Profiler = mt, Nt.StrictMode = dt, Nt.Suspense = ot, Nt.isAsyncMode = pt, Nt.isConcurrentMode = k, Nt.isContextConsumer = F, Nt.isContextProvider = K, Nt.isElement = J, Nt.isForwardRef = et, Nt.isFragment = W, Nt.isLazy = Q, Nt.isMemo = H, Nt.isPortal = tt, Nt.isProfiler = ht, Nt.isStrictMode = D, Nt.isSuspense = ct, Nt.isValidElementType = T, Nt.typeOf = C;
10045
10045
  })()), Nt;
10046
10046
  }
10047
10047
  var Pd;
@@ -10193,10 +10193,10 @@ function e_() {
10193
10193
  string: S("string"),
10194
10194
  symbol: S("symbol"),
10195
10195
  any: A(),
10196
- arrayOf: C,
10197
- element: O(),
10196
+ arrayOf: T,
10197
+ element: C(),
10198
10198
  elementType: M(),
10199
- instanceOf: z,
10199
+ instanceOf: O,
10200
10200
  node: U(),
10201
10201
  objectOf: I,
10202
10202
  oneOf: R,
@@ -10251,7 +10251,7 @@ function e_() {
10251
10251
  function A() {
10252
10252
  return _(o);
10253
10253
  }
10254
- function C(k) {
10254
+ function T(k) {
10255
10255
  function F(K, J, et, W, Q) {
10256
10256
  if (typeof k != "function")
10257
10257
  return new v("Property `" + Q + "` of component `" + et + "` has invalid PropType notation inside arrayOf.");
@@ -10269,7 +10269,7 @@ function e_() {
10269
10269
  }
10270
10270
  return _(F);
10271
10271
  }
10272
- function O() {
10272
+ function C() {
10273
10273
  function k(F, K, J, et, W) {
10274
10274
  var Q = F[K];
10275
10275
  if (!a(Q)) {
@@ -10291,7 +10291,7 @@ function e_() {
10291
10291
  }
10292
10292
  return _(k);
10293
10293
  }
10294
- function z(k) {
10294
+ function O(k) {
10295
10295
  function F(K, J, et, W, Q) {
10296
10296
  if (!(K[J] instanceof k)) {
10297
10297
  var H = k.name || g, tt = pt(K[J]);
@@ -10596,7 +10596,7 @@ function Qe(n, t = 0) {
10596
10596
  f: t
10597
10597
  };
10598
10598
  }
10599
- function Mn(...n) {
10599
+ function En(...n) {
10600
10600
  n = Array.isArray(n[0]) ? n[0] : n;
10601
10601
  const t = (e, r) => ({
10602
10602
  a: e.a * r.a + e.c * r.b,
@@ -10615,7 +10615,7 @@ function Mn(...n) {
10615
10615
  return t(n[0], n[1]);
10616
10616
  default: {
10617
10617
  const [e, r, ...i] = n, s = t(e, r);
10618
- return Mn(s, ...i);
10618
+ return En(s, ...i);
10619
10619
  }
10620
10620
  }
10621
10621
  }
@@ -10629,7 +10629,7 @@ function ii(n, t = void 0, e = void 0, r = void 0) {
10629
10629
  d: t,
10630
10630
  f: 0
10631
10631
  };
10632
- return yl(e) || yl(r) ? i : Mn([
10632
+ return yl(e) || yl(r) ? i : En([
10633
10633
  Qe(e, r),
10634
10634
  i,
10635
10635
  Qe(-e, -r)
@@ -10857,7 +10857,7 @@ function g_(n, t, e, r) {
10857
10857
  let {
10858
10858
  viewerWidth: i,
10859
10859
  viewerHeight: s
10860
- } = n, o = Mn(
10860
+ } = n, o = En(
10861
10861
  Qe(-t + i / 2, -e + s / 2),
10862
10862
  //4
10863
10863
  Qe(t, e),
@@ -10944,7 +10944,7 @@ function __(n, t) {
10944
10944
  return (t === "string" ? String : Number)(n);
10945
10945
  }
10946
10946
  function zh(n, t, e) {
10947
- let r = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : void 0, i = Mn(
10947
+ let r = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : void 0, i = En(
10948
10948
  Oo(n),
10949
10949
  //2
10950
10950
  Qe(t, e)
@@ -10966,7 +10966,7 @@ function zh(n, t, e) {
10966
10966
  }]), c = 0;
10967
10967
  n.viewerWidth - s < 0 ? c = n.viewerWidth - s : a < 0 && (c = -a);
10968
10968
  let h = 0;
10969
- n.viewerHeight - o < 0 ? h = n.viewerHeight - o : l < 0 && (h = -l), i = Mn(Qe(c, h), i);
10969
+ n.viewerHeight - o < 0 ? h = n.viewerHeight - o : l < 0 && (h = -l), i = En(Qe(c, h), i);
10970
10970
  }
10971
10971
  return Ut(n, y_({
10972
10972
  mode: nr
@@ -11090,7 +11090,7 @@ function Th(n, t) {
11090
11090
  function ys(n, t, e, r) {
11091
11091
  if (du(n, r))
11092
11092
  return n;
11093
- const i = Mn(Oo(n), Qe(t, e), ii(r, r), Qe(-t, -e));
11093
+ const i = En(Oo(n), Qe(t, e), ii(r, r), Qe(-t, -e));
11094
11094
  return Ut(n, os(os({
11095
11095
  mode: nr
11096
11096
  }, i), {}, {
@@ -11105,7 +11105,7 @@ function Ym(n, t, e, r, i) {
11105
11105
  viewerWidth: s,
11106
11106
  viewerHeight: o
11107
11107
  } = n, a = s / r, l = o / i, c = Math.min(a, l);
11108
- const h = Mn(
11108
+ const h = En(
11109
11109
  ii(c, c),
11110
11110
  //2
11111
11111
  Qe(-t, -e)
@@ -11172,7 +11172,7 @@ function Xm(n) {
11172
11172
  break;
11173
11173
  }
11174
11174
  }
11175
- const v = Qe(p, m), _ = Mn(
11175
+ const v = Qe(p, m), _ = En(
11176
11176
  v,
11177
11177
  //2
11178
11178
  g
@@ -11548,7 +11548,7 @@ function ey(n, t, e, r, i) {
11548
11548
  if (du(r, m))
11549
11549
  return r;
11550
11550
  n.cancelable && n.preventDefault();
11551
- let v = Mn(Oo(r), Qe(p.x, p.y), ii(m, m), Qe(-p.x, -p.y));
11551
+ let v = En(Oo(r), Qe(p.x, p.y), ii(m, m), Qe(-p.x, -p.y));
11552
11552
  return Ut(r, Ut(Kd(Kd({
11553
11553
  mode: Fr
11554
11554
  }, Th(r, v)), {}, {
@@ -12039,23 +12039,23 @@ function fy(n) {
12039
12039
  x: S,
12040
12040
  y: A
12041
12041
  }, {
12042
- x: C,
12043
- y: O
12042
+ x: T,
12043
+ y: C
12044
12044
  }] = Vm(Bm(t), [{
12045
12045
  x: 0,
12046
12046
  y: 0
12047
12047
  }, {
12048
12048
  x: p,
12049
12049
  y: m
12050
- }]), M, z;
12051
- t.miniatureOpen ? (M = a, z = l) : (M = 24, z = 24);
12050
+ }]), M, O;
12051
+ t.miniatureOpen ? (M = a, O = l) : (M = 24, O = 24);
12052
12052
  let R = {
12053
12053
  position: "absolute",
12054
12054
  overflow: "hidden",
12055
12055
  outline: "1px solid rgba(19, 20, 22, 0.90)",
12056
12056
  transition: "width 200ms ease, height 200ms ease, bottom 200ms ease",
12057
12057
  width: M + "px",
12058
- height: z + "px",
12058
+ height: O + "px",
12059
12059
  bottom: "6px",
12060
12060
  [o === Ne ? "left" : "right"]: "6px",
12061
12061
  background: s
@@ -12086,8 +12086,8 @@ function fy(n) {
12086
12086
  SVGMinY: h,
12087
12087
  x1: S,
12088
12088
  y1: A,
12089
- x2: C,
12090
- y2: O,
12089
+ x2: T,
12090
+ y2: C,
12091
12091
  zoomToFit: _
12092
12092
  })))), /* @__PURE__ */ X.createElement(cy, {
12093
12093
  value: t,
@@ -12757,14 +12757,18 @@ b1.propTypes = {
12757
12757
  defaultValue: q.object,
12758
12758
  defaultTool: q.string
12759
12759
  };
12760
- const Zt = B0((n) => ({
12760
+ const Yt = B0((n) => ({
12761
12761
  planner: new Va(),
12762
12762
  viewer: null,
12763
12763
  plan: null,
12764
+ toast: null,
12764
12765
  activeFloor: 0,
12765
12766
  setViewer: (t) => {
12766
12767
  n((e) => ({ ...e, viewer: t }));
12767
12768
  },
12769
+ setToast: (t) => {
12770
+ n((e) => ({ ...e, toast: t }));
12771
+ },
12768
12772
  setActiveFloor: (t) => {
12769
12773
  n((e) => ({
12770
12774
  ...e,
@@ -13848,18 +13852,18 @@ function k1(n, t = 1, e = !1) {
13848
13852
  const g = new Wa(r + a / 2, i + l / 2, 0, n);
13849
13853
  g.d > f.d && (f = g);
13850
13854
  let p = 2;
13851
- function m(S, A, C) {
13852
- const O = new Wa(S, A, C, n);
13853
- p++, O.max > f.d + t && h.push(O), O.d > f.d && (f = O, e && console.log(`found best ${Math.round(1e4 * O.d) / 1e4} after ${p} probes`));
13855
+ function m(S, A, T) {
13856
+ const C = new Wa(S, A, T, n);
13857
+ p++, C.max > f.d + t && h.push(C), C.d > f.d && (f = C, e && console.log(`found best ${Math.round(1e4 * C.d) / 1e4} after ${p} probes`));
13854
13858
  }
13855
13859
  let v = c / 2;
13856
13860
  for (let S = r; S < s; S += c)
13857
13861
  for (let A = i; A < o; A += c)
13858
13862
  m(S + v, A + v, v);
13859
13863
  for (; h.length; ) {
13860
- const { max: S, x: A, y: C, h: O } = h.pop();
13864
+ const { max: S, x: A, y: T, h: C } = h.pop();
13861
13865
  if (S - f.d <= t) break;
13862
- v = O / 2, m(A - v, C - v, v), m(A + v, C - v, v), m(A - v, C + v, v), m(A + v, C + v, v);
13866
+ v = C / 2, m(A - v, T - v, v), m(A + v, T - v, v), m(A - v, T + v, v), m(A + v, T + v, v);
13863
13867
  }
13864
13868
  e && console.log(`num probes: ${p}
13865
13869
  best distance: ${f.d}`);
@@ -14078,17 +14082,17 @@ const Y1 = ({ line: n, layer: t, scene: e, catalog: r }) => {
14078
14082
  let { x: o, y: a } = i, { x: l, y: c } = s;
14079
14083
  o > l && ({ x: o, y: a } = s, { x: l, y: c } = i);
14080
14084
  let h = Ce(o, a, l, c), f = Jv(o, a, l, c), g = n.holes.map((S) => {
14081
- let A = t.holes.get(S), C = h * A.offset, O = r.getElement(A.type).render2D(A, t, e);
14085
+ let A = t.holes.get(S), T = h * A.offset, C = r.getElement(A.type).render2D(A, t, e);
14082
14086
  return /* @__PURE__ */ w.jsx(
14083
14087
  "g",
14084
14088
  {
14085
- transform: `translate(${C}, 0)`,
14089
+ transform: `translate(${T}, 0)`,
14086
14090
  "data-element-root": !0,
14087
14091
  "data-prototype": A.prototype,
14088
14092
  "data-id": A.id,
14089
14093
  "data-selected": A.selected,
14090
14094
  "data-layer": t.id,
14091
- children: O
14095
+ children: C
14092
14096
  },
14093
14097
  S
14094
14098
  );
@@ -14199,7 +14203,7 @@ const Z1 = ({ scene: n, catalog: t }) => {
14199
14203
  stroke: jt.SECONDARY_COLOR.main,
14200
14204
  strokeWidth: "2.5px"
14201
14205
  }, Q1 = ({ catalog: n }) => {
14202
- const { planner: t } = Zt(), { activeSnapElement: e, snapElements: r, scene: i } = t, { width: s, height: o } = i;
14206
+ const { planner: t } = Yt(), { activeSnapElement: e, snapElements: r, scene: i } = t, { width: s, height: o } = i;
14203
14207
  return /* @__PURE__ */ w.jsxs("g", { children: [
14204
14208
  /* @__PURE__ */ w.jsx(
14205
14209
  "rect",
@@ -14293,7 +14297,7 @@ function ib(n) {
14293
14297
  case Pr:
14294
14298
  case Rr:
14295
14299
  return { cursor: "move" };
14296
- case Sn:
14300
+ case Mn:
14297
14301
  return { cursor: "ew-resize" };
14298
14302
  case kr:
14299
14303
  case Ze:
@@ -14328,7 +14332,7 @@ function up(n) {
14328
14332
  };
14329
14333
  }
14330
14334
  const ob = ({ width: n, height: t, catalog: e }) => {
14331
- const r = jn(null), {
14335
+ const r = Vn(null), {
14332
14336
  planner: i,
14333
14337
  selectToolZoomOut: s,
14334
14338
  selectToolZoomIn: o,
@@ -14344,10 +14348,10 @@ const ob = ({ width: n, height: t, catalog: e }) => {
14344
14348
  updateDraggingLine: _,
14345
14349
  updateDraggingVertex: S,
14346
14350
  updateDraggingItem: A,
14347
- updateRotatingItem: C,
14348
- beginDraggingLine: O,
14351
+ updateRotatingItem: T,
14352
+ beginDraggingLine: C,
14349
14353
  beginDraggingVertex: M,
14350
- beginRotatingItem: z,
14354
+ beginRotatingItem: O,
14351
14355
  beginDraggingItem: R,
14352
14356
  beginDraggingHole: I,
14353
14357
  selectArea: L,
@@ -14366,8 +14370,8 @@ const ob = ({ width: n, height: t, catalog: e }) => {
14366
14370
  selectItem: K,
14367
14371
  rollback: J,
14368
14372
  setViewer: et
14369
- } = Zt(), { viewer2D: W, scene: Q, mode: H } = i, tt = Q.selectedLayer ?? "";
14370
- Vn(() => {
14373
+ } = Yt(), { viewer2D: W, scene: Q, mode: H } = i, tt = Q.selectedLayer ?? "";
14374
+ wn(() => {
14371
14375
  r.current && (et(r.current), r.current.fitToViewer());
14372
14376
  }, []);
14373
14377
  const ht = ({ x: Ot, y: Vt }) => ({ x: Ot, y: -Vt + Q.height }), D = (Ot) => {
@@ -14396,8 +14400,8 @@ const ob = ({ width: n, height: t, catalog: e }) => {
14396
14400
  case Rr:
14397
14401
  A(ft, vt);
14398
14402
  break;
14399
- case Sn:
14400
- C(ft, vt);
14403
+ case Mn:
14404
+ T(ft, vt);
14401
14405
  break;
14402
14406
  }
14403
14407
  Ot.originalEvent.stopPropagation();
@@ -14410,7 +14414,7 @@ const ob = ({ width: n, height: t, catalog: e }) => {
14410
14414
  if (!wt || !wt.selected) return;
14411
14415
  switch (wt.prototype) {
14412
14416
  case "lines":
14413
- O(
14417
+ C(
14414
14418
  wt.layer,
14415
14419
  wt.id,
14416
14420
  vt,
@@ -14428,7 +14432,7 @@ const ob = ({ width: n, height: t, catalog: e }) => {
14428
14432
  );
14429
14433
  break;
14430
14434
  case "items":
14431
- wt.part === "rotation-anchor" ? z(wt.layer, wt.id, vt, Rt) : R(wt.layer, wt.id, vt, Rt);
14435
+ wt.part === "rotation-anchor" ? O(wt.layer, wt.id, vt, Rt) : R(wt.layer, wt.id, vt, Rt);
14432
14436
  break;
14433
14437
  case "holes":
14434
14438
  I(wt.layer, wt.id, vt, Rt);
@@ -14486,7 +14490,7 @@ const ob = ({ width: n, height: t, catalog: e }) => {
14486
14490
  case Lr:
14487
14491
  G(vt, Rt);
14488
14492
  break;
14489
- case Sn:
14493
+ case Mn:
14490
14494
  pt(vt, Rt);
14491
14495
  break;
14492
14496
  }
@@ -14813,7 +14817,7 @@ const my = {
14813
14817
  selectToolDrawingItem: i,
14814
14818
  selectToolDrawingHole: s,
14815
14819
  pushLastSelectedCatalogElementToHistory: o
14816
- } = Zt(), a = () => {
14820
+ } = Yt(), a = () => {
14817
14821
  switch (n.prototype) {
14818
14822
  case "lines":
14819
14823
  r(n.name);
@@ -14941,7 +14945,7 @@ const Vb = {
14941
14945
  alignItems: "center",
14942
14946
  justifyContent: "center"
14943
14947
  }, Wb = ({ page: n }) => {
14944
- const [t, e] = X.useState(!1), { goBackToCatalogPage: r } = Zt(), i = (s) => {
14948
+ const [t, e] = X.useState(!1), { goBackToCatalogPage: r } = Yt(), i = (s) => {
14945
14949
  r(s);
14946
14950
  };
14947
14951
  return /* @__PURE__ */ w.jsx(
@@ -15015,13 +15019,13 @@ const Vb = {
15015
15019
  selectToolDrawingItem: a,
15016
15020
  selectToolDrawingLine: l,
15017
15021
  pushLastSelectedCatalogElementToHistory: c
15018
- } = Zt();
15022
+ } = Yt();
15019
15023
  let h = i.catalog.page;
15020
15024
  const f = r.getCategory(h);
15021
15025
  let g = f.elements.filter(
15022
15026
  (L) => L.info.visibility ? L.info.visibility.catalog : !0
15023
15027
  );
15024
- const [p, m] = re(""), [v, _] = re([]);
15028
+ const [p, m] = ee(""), [v, _] = ee([]);
15025
15029
  let S = null;
15026
15030
  if (h !== "root") {
15027
15031
  let L = [];
@@ -15032,13 +15036,13 @@ const Vb = {
15032
15036
  });
15033
15037
  }), L.push({ name: f.label, action: "" }), S = /* @__PURE__ */ w.jsx(qb, { names: L });
15034
15038
  }
15035
- let A = i.catalog.path.size, C = A > 0 ? /* @__PURE__ */ w.jsx(
15039
+ let A = i.catalog.path.size, T = A > 0 ? /* @__PURE__ */ w.jsx(
15036
15040
  Wb,
15037
15041
  {
15038
15042
  page: r.categories[i.catalog.path.get(A - 1)]
15039
15043
  },
15040
15044
  A
15041
- ) : null, O = i.get("selectedElementsHistory"), M = O.map((L, U) => /* @__PURE__ */ w.jsx(
15045
+ ) : null, C = i.get("selectedElementsHistory"), M = C.map((L, U) => /* @__PURE__ */ w.jsx(
15042
15046
  "div",
15043
15047
  {
15044
15048
  style: Kb,
@@ -15048,16 +15052,16 @@ const Vb = {
15048
15052
  },
15049
15053
  U
15050
15054
  ));
15051
- const z = (L) => {
15055
+ const O = (L) => {
15052
15056
  let U = [];
15053
15057
  for (let Y = 0; Y < L.length; Y++) {
15054
15058
  let it = L[Y];
15055
- U = U.concat(it.elements), it.categories.length && (U = U.concat(z(it.categories)));
15059
+ U = U.concat(it.elements), it.categories.length && (U = U.concat(O(it.categories)));
15056
15060
  }
15057
15061
  return U;
15058
15062
  }, R = (L) => {
15059
15063
  let U = g.concat(
15060
- z(f.categories)
15064
+ O(f.categories)
15061
15065
  ), Y = [];
15062
15066
  if (L != "") {
15063
15067
  let it = new RegExp(L, "i");
@@ -15101,12 +15105,12 @@ const Vb = {
15101
15105
  }
15102
15106
  )
15103
15107
  ] }),
15104
- O.size ? /* @__PURE__ */ w.jsxs("div", { style: Zb, children: [
15108
+ C.size ? /* @__PURE__ */ w.jsxs("div", { style: Zb, children: [
15105
15109
  /* @__PURE__ */ w.jsx("span", { children: "Last Selected" }),
15106
15110
  M
15107
15111
  ] }) : null,
15108
15112
  /* @__PURE__ */ w.jsx("div", { style: Yb, children: p === "" ? [
15109
- C,
15113
+ T,
15110
15114
  // currentCategory.categories.map((cat) => (
15111
15115
  // <CatalogPageItem
15112
15116
  // key={cat.name}
@@ -15132,10 +15136,10 @@ const Vb = {
15132
15136
  MODE_DRAWING_HOLE: Ke,
15133
15137
  MODE_DRAWING_ITEM: fr,
15134
15138
  MODE_DRAGGING_HOLE: Lr,
15135
- MODE_ROTATING_ITEM: Sn
15139
+ MODE_ROTATING_ITEM: Mn
15136
15140
  };
15137
15141
  function ew({ width: n, height: t, catalog: e }) {
15138
- const { planner: r } = Zt(), { mode: i } = r;
15142
+ const { planner: r } = Yt(), { mode: i } = r;
15139
15143
  return i === ai ? /* @__PURE__ */ w.jsx(w.Fragment, {}) : i === gs ? /* @__PURE__ */ w.jsx(w.Fragment, {}) : i === yh ? /* @__PURE__ */ w.jsx(Qb, { width: n, height: t, catalog: e }) : tw[i] ? /* @__PURE__ */ w.jsx(ob, { width: n, height: t, catalog: e }) : i === bm ? /* @__PURE__ */ w.jsx(w.Fragment, {}) : null;
15140
15144
  }
15141
15145
  function My(n) {
@@ -15346,14 +15350,14 @@ const Ph = "-", nw = (n) => {
15346
15350
  }
15347
15351
  _ = !1;
15348
15352
  }
15349
- const A = s(g).join(":"), C = p ? A + Cc : A, O = C + S;
15350
- if (o.includes(O))
15353
+ const A = s(g).join(":"), T = p ? A + Cc : A, C = T + S;
15354
+ if (o.includes(C))
15351
15355
  continue;
15352
- o.push(O);
15356
+ o.push(C);
15353
15357
  const M = i(S, _);
15354
- for (let z = 0; z < M.length; ++z) {
15355
- const R = M[z];
15356
- o.push(C + R);
15358
+ for (let O = 0; O < M.length; ++O) {
15359
+ const R = M[O];
15360
+ o.push(T + R);
15357
15361
  }
15358
15362
  l = h + (l.length > 0 ? " " + l : l);
15359
15363
  }
@@ -15393,7 +15397,7 @@ function mw(n, ...t) {
15393
15397
  const pe = (n) => {
15394
15398
  const t = (e) => e[n] || [];
15395
15399
  return t.isThemeGetter = !0, t;
15396
- }, Oy = /^\[(?:(\w[\w-]*):)?(.+)\]$/i, zy = /^\((?:(\w[\w-]*):)?(.+)\)$/i, yw = /^\d+\/\d+$/, vw = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/, xw = /\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/, _w = /^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/, bw = /^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/, ww = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/, Oi = (n) => yw.test(n), St = (n) => !!n && !Number.isNaN(Number(n)), zn = (n) => !!n && Number.isInteger(Number(n)), bl = (n) => n.endsWith("%") && St(n.slice(0, -1)), cn = (n) => vw.test(n), Sw = () => !0, Mw = (n) => (
15400
+ }, Oy = /^\[(?:(\w[\w-]*):)?(.+)\]$/i, zy = /^\((?:(\w[\w-]*):)?(.+)\)$/i, yw = /^\d+\/\d+$/, vw = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/, xw = /\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/, _w = /^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/, bw = /^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/, ww = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/, Oi = (n) => yw.test(n), St = (n) => !!n && !Number.isNaN(Number(n)), Tn = (n) => !!n && Number.isInteger(Number(n)), bl = (n) => n.endsWith("%") && St(n.slice(0, -1)), cn = (n) => vw.test(n), Sw = () => !0, Mw = (n) => (
15397
15401
  // `colorFunctionRegex` check is necessary because color functions can have percentages in them which which would be incorrectly classified as lengths.
15398
15402
  // For example, `hsl(0 0% 0%)` would be classified as a length without this check.
15399
15403
  // I could also use lookbehind assertion in `lengthUnitRegex` but that isn't supported widely enough.
@@ -15405,7 +15409,7 @@ const pe = (n) => {
15405
15409
  const r = zy.exec(n);
15406
15410
  return r ? r[1] ? t(r[1]) : e : !1;
15407
15411
  }, Cy = (n) => n === "position" || n === "percentage", ky = (n) => n === "image" || n === "url", Iy = (n) => n === "length" || n === "size" || n === "bg-size", Py = (n) => n === "length", Pw = (n) => n === "number", Rw = (n) => n === "family-name", Ry = (n) => n === "shadow", Lw = () => {
15408
- const n = pe("color"), t = pe("font"), e = pe("text"), r = pe("font-weight"), i = pe("tracking"), s = pe("leading"), o = pe("breakpoint"), a = pe("container"), l = pe("spacing"), c = pe("radius"), h = pe("shadow"), f = pe("inset-shadow"), g = pe("text-shadow"), p = pe("drop-shadow"), m = pe("blur"), v = pe("perspective"), _ = pe("aspect"), S = pe("ease"), A = pe("animate"), C = () => ["auto", "avoid", "all", "avoid-page", "page", "left", "right", "column"], O = () => [
15412
+ const n = pe("color"), t = pe("font"), e = pe("text"), r = pe("font-weight"), i = pe("tracking"), s = pe("leading"), o = pe("breakpoint"), a = pe("container"), l = pe("spacing"), c = pe("radius"), h = pe("shadow"), f = pe("inset-shadow"), g = pe("text-shadow"), p = pe("drop-shadow"), m = pe("blur"), v = pe("perspective"), _ = pe("aspect"), S = pe("ease"), A = pe("animate"), T = () => ["auto", "avoid", "all", "avoid-page", "page", "left", "right", "column"], C = () => [
15409
15413
  "center",
15410
15414
  "top",
15411
15415
  "bottom",
@@ -15423,9 +15427,9 @@ const pe = (n) => {
15423
15427
  "bottom-left",
15424
15428
  // Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378
15425
15429
  "left-bottom"
15426
- ], M = () => [...O(), lt, ut], z = () => ["auto", "hidden", "clip", "visible", "scroll"], R = () => ["auto", "contain", "none"], I = () => [lt, ut, l], L = () => [Oi, "full", "auto", ...I()], U = () => [zn, "none", "subgrid", lt, ut], Y = () => ["auto", {
15427
- span: ["full", zn, lt, ut]
15428
- }, zn, lt, ut], it = () => [zn, "auto", lt, ut], rt = () => ["auto", "min", "max", "fr", lt, ut], yt = () => ["start", "end", "center", "between", "around", "evenly", "stretch", "baseline", "center-safe", "end-safe"], mt = () => ["start", "end", "center", "stretch", "center-safe", "end-safe"], dt = () => ["auto", ...I()], ot = () => [Oi, "auto", "full", "dvw", "dvh", "lvw", "lvh", "svw", "svh", "min", "max", "fit", ...I()], G = () => [n, lt, ut], pt = () => [...O(), gp, pp, {
15430
+ ], M = () => [...C(), lt, ut], O = () => ["auto", "hidden", "clip", "visible", "scroll"], R = () => ["auto", "contain", "none"], I = () => [lt, ut, l], L = () => [Oi, "full", "auto", ...I()], U = () => [Tn, "none", "subgrid", lt, ut], Y = () => ["auto", {
15431
+ span: ["full", Tn, lt, ut]
15432
+ }, Tn, lt, ut], it = () => [Tn, "auto", lt, ut], rt = () => ["auto", "min", "max", "fr", lt, ut], yt = () => ["start", "end", "center", "between", "around", "evenly", "stretch", "baseline", "center-safe", "end-safe"], mt = () => ["start", "end", "center", "stretch", "center-safe", "end-safe"], dt = () => ["auto", ...I()], ot = () => [Oi, "auto", "full", "dvw", "dvh", "lvw", "lvh", "svw", "svh", "min", "max", "fit", ...I()], G = () => [n, lt, ut], pt = () => [...C(), gp, pp, {
15429
15433
  position: [lt, ut]
15430
15434
  }], k = () => ["no-repeat", {
15431
15435
  repeat: ["", "x", "y", "space", "round"]
@@ -15499,14 +15503,14 @@ const pe = (n) => {
15499
15503
  * @see https://tailwindcss.com/docs/break-after
15500
15504
  */
15501
15505
  "break-after": [{
15502
- "break-after": C()
15506
+ "break-after": T()
15503
15507
  }],
15504
15508
  /**
15505
15509
  * Break Before
15506
15510
  * @see https://tailwindcss.com/docs/break-before
15507
15511
  */
15508
15512
  "break-before": [{
15509
- "break-before": C()
15513
+ "break-before": T()
15510
15514
  }],
15511
15515
  /**
15512
15516
  * Break Inside
@@ -15577,21 +15581,21 @@ const pe = (n) => {
15577
15581
  * @see https://tailwindcss.com/docs/overflow
15578
15582
  */
15579
15583
  overflow: [{
15580
- overflow: z()
15584
+ overflow: O()
15581
15585
  }],
15582
15586
  /**
15583
15587
  * Overflow X
15584
15588
  * @see https://tailwindcss.com/docs/overflow
15585
15589
  */
15586
15590
  "overflow-x": [{
15587
- "overflow-x": z()
15591
+ "overflow-x": O()
15588
15592
  }],
15589
15593
  /**
15590
15594
  * Overflow Y
15591
15595
  * @see https://tailwindcss.com/docs/overflow
15592
15596
  */
15593
15597
  "overflow-y": [{
15594
- "overflow-y": z()
15598
+ "overflow-y": O()
15595
15599
  }],
15596
15600
  /**
15597
15601
  * Overscroll Behavior
@@ -15692,7 +15696,7 @@ const pe = (n) => {
15692
15696
  * @see https://tailwindcss.com/docs/z-index
15693
15697
  */
15694
15698
  z: [{
15695
- z: [zn, "auto", lt, ut]
15699
+ z: [Tn, "auto", lt, ut]
15696
15700
  }],
15697
15701
  // ------------------------
15698
15702
  // --- Flexbox and Grid ---
@@ -15744,7 +15748,7 @@ const pe = (n) => {
15744
15748
  * @see https://tailwindcss.com/docs/order
15745
15749
  */
15746
15750
  order: [{
15747
- order: [zn, "first", "last", "none", lt, ut]
15751
+ order: [Tn, "first", "last", "none", lt, ut]
15748
15752
  }],
15749
15753
  /**
15750
15754
  * Grid Template Columns
@@ -16422,9 +16426,9 @@ const pe = (n) => {
16422
16426
  bg: ["none", {
16423
16427
  linear: [{
16424
16428
  to: ["t", "tr", "r", "br", "b", "bl", "l", "tl"]
16425
- }, zn, lt, ut],
16429
+ }, Tn, lt, ut],
16426
16430
  radial: ["", lt, ut],
16427
- conic: [zn, lt, ut]
16431
+ conic: [Tn, lt, ut]
16428
16432
  }, Iw, Tw]
16429
16433
  }],
16430
16434
  /**
@@ -17039,7 +17043,7 @@ const pe = (n) => {
17039
17043
  }]
17040
17044
  }],
17041
17045
  "mask-image-radial-pos": [{
17042
- "mask-radial-at": O()
17046
+ "mask-radial-at": C()
17043
17047
  }],
17044
17048
  "mask-image-conic-pos": [{
17045
17049
  "mask-conic": [St]
@@ -17885,7 +17889,7 @@ const Ds = ({
17885
17889
  toggleOn: r,
17886
17890
  toggleOff: i
17887
17891
  }) => {
17888
- const [s, o] = re(!1), [a, l] = re(e || !1), c = () => {
17892
+ const [s, o] = ee(!1), [a, l] = ee(e || !1), c = () => {
17889
17893
  l(!a), a ? i() : r();
17890
17894
  };
17891
17895
  return /* @__PURE__ */ w.jsx(
@@ -17910,7 +17914,7 @@ const Ds = ({
17910
17914
  titleStyle: i,
17911
17915
  content: s
17912
17916
  }) => {
17913
- const [o, a] = re(!1), [l, c] = re(!1);
17917
+ const [o, a] = ee(!1), [l, c] = ee(!1);
17914
17918
  return /* @__PURE__ */ w.jsxs("div", { className: "w-auto inline-block m-0 pr-1.5", children: [
17915
17919
  /* @__PURE__ */ w.jsxs(
17916
17920
  "div",
@@ -17973,18 +17977,18 @@ function Vw(n, t, e, r, i) {
17973
17977
  return r + (i - r) * (n - t) / (e - t);
17974
17978
  }
17975
17979
  const Dw = () => {
17976
- const { planner: n, toggleSnap: t, viewer: e } = Zt(), { mode: r, mouse: i, zoom: s, snapMask: o } = n, a = n.get("warnings").toArray(), l = n.get("errors").toArray(), c = (f) => t(o.merge(f)), h = (f) => {
17980
+ const { planner: n, toggleSnap: t, viewer: e } = Yt(), { mode: r, mouse: i, zoom: s, snapMask: o } = n, a = n.get("warnings").toArray(), l = n.get("errors").toArray(), c = (f) => t(o.merge(f)), h = (f) => {
17977
17981
  const g = parseInt(ap(s).toFixed());
17978
17982
  if (g === 0 && f === "out" || g === 100 && f === "in" || !e)
17979
17983
  return;
17980
- const p = e == null ? void 0 : e.getValue(), m = p.viewerWidth / 2, v = p.viewerHeight / 2, _ = f === "in" ? -1 : 1, S = 1.06, A = Math.max(-1, Math.min(1, _)), C = Vw(
17984
+ const p = e == null ? void 0 : e.getValue(), m = p.viewerWidth / 2, v = p.viewerHeight / 2, _ = f === "in" ? -1 : 1, S = 1.06, A = Math.max(-1, Math.min(1, _)), T = Vw(
17981
17985
  A,
17982
17986
  -1,
17983
17987
  1,
17984
17988
  S,
17985
17989
  1 / S
17986
17990
  );
17987
- e.zoom(m, v, C);
17991
+ e.zoom(m, v, T);
17988
17992
  };
17989
17993
  return /* @__PURE__ */ w.jsxs("div", { className: "floor_planner-footerbar absolute z-[9001] py-[3px] px-[1em] text-xs bg-[#424242] h-5 w-full select-none cursor-default bottom-0 leading-[14px] text-white m-0", children: [
17990
17994
  vc.includes(r) && /* @__PURE__ */ w.jsxs(w.Fragment, { children: [
@@ -18172,7 +18176,7 @@ const Dw = () => {
18172
18176
  ] })
18173
18177
  ] });
18174
18178
  }, Ly = ({ children: n, name: t, ...e }) => {
18175
- const [r, i] = re(e.opened || !1);
18179
+ const [r, i] = ee(e.opened || !1);
18176
18180
  return /* @__PURE__ */ w.jsxs("div", { className: "select-none", style: { borderBottom: "1px solid #5e5e5e" }, children: [
18177
18181
  /* @__PURE__ */ w.jsxs(
18178
18182
  "div",
@@ -18227,9 +18231,9 @@ const xn = ({
18227
18231
  style: a,
18228
18232
  placeholder: l
18229
18233
  }) => {
18230
- const [c, h] = re(!0), [f, g] = re(n);
18234
+ const [c, h] = ee(!0), [f, g] = ee(n);
18231
18235
  let p = new RegExp(`^-?([0-9]+)?\\.?([0-9]{0,${r}})?$`);
18232
- Vn(() => {
18236
+ wn(() => {
18233
18237
  t !== void 0 && !isNaN(t) && isFinite(t) && Number(f) < t && g(t), e && !isNaN(e) && isFinite(e) && Number(f) > e && g(e);
18234
18238
  }, [t, e, f]);
18235
18239
  const m = P0(
@@ -19780,7 +19784,7 @@ const xn = ({
19780
19784
  ratio: 1
19781
19785
  }
19782
19786
  }
19783
- }, Tn = {
19787
+ }, Cn = {
19784
19788
  length: $w,
19785
19789
  area: Ww,
19786
19790
  mass: Xw,
@@ -19843,7 +19847,7 @@ class VS {
19843
19847
  );
19844
19848
  let e = this.val * this.origin.unit.to_anchor;
19845
19849
  if (this.origin.unit.anchor_shift && (e -= this.origin.unit.anchor_shift), this.origin.system !== this.destination.system) {
19846
- const r = Tn[this.origin.measure]._anchors[this.origin.system];
19850
+ const r = Cn[this.origin.measure]._anchors[this.origin.system];
19847
19851
  e = typeof r.transform == "function" ? r.transform(e) : e * r.ratio;
19848
19852
  }
19849
19853
  return this.destination.unit.anchor_shift && (e += this.destination.unit.anchor_shift), e / this.destination.unit.to_anchor;
@@ -19867,7 +19871,7 @@ class VS {
19867
19871
  }
19868
19872
  getUnit(t) {
19869
19873
  let e = null;
19870
- return or(Tn, (r, i) => {
19874
+ return or(Cn, (r, i) => {
19871
19875
  or(r, (s, o) => {
19872
19876
  o !== "_anchors" && or(s, (a, l) => {
19873
19877
  l === t && (e = { abbr: t, measure: i, system: o, unit: a });
@@ -19881,7 +19885,7 @@ class VS {
19881
19885
  }
19882
19886
  list(t) {
19883
19887
  const e = [];
19884
- return or(Tn, (r, i) => {
19888
+ return or(Cn, (r, i) => {
19885
19889
  t && t !== i || or(r, (s, o) => {
19886
19890
  o !== "_anchors" && or(s, (a, l) => {
19887
19891
  e.push(vp({ abbr: l, measure: i, system: o, unit: a }));
@@ -19891,7 +19895,7 @@ class VS {
19891
19895
  }
19892
19896
  throwUnsupportedUnitError(t) {
19893
19897
  const e = [];
19894
- throw or(Tn, (r) => {
19898
+ throw or(Cn, (r) => {
19895
19899
  or(r, (i, s) => {
19896
19900
  s !== "_anchors" && e.push(...Bs(i));
19897
19901
  });
@@ -19902,21 +19906,21 @@ class VS {
19902
19906
  possibilities(t) {
19903
19907
  const e = [];
19904
19908
  if (!this.origin && !t)
19905
- or(Bs(Tn), (r) => {
19906
- or(Tn[r], (i, s) => {
19909
+ or(Bs(Cn), (r) => {
19910
+ or(Cn[r], (i, s) => {
19907
19911
  s !== "_anchors" && e.push(...Bs(i));
19908
19912
  });
19909
19913
  });
19910
19914
  else {
19911
19915
  const r = t || this.origin.measure;
19912
- or(Tn[r], (i, s) => {
19916
+ or(Cn[r], (i, s) => {
19913
19917
  s !== "_anchors" && e.push(...Bs(i));
19914
19918
  });
19915
19919
  }
19916
19920
  return e;
19917
19921
  }
19918
19922
  measures() {
19919
- return Bs(Tn);
19923
+ return Bs(Cn);
19920
19924
  }
19921
19925
  }
19922
19926
  function Yr(n) {
@@ -19945,7 +19949,7 @@ const Ic = ({
19945
19949
  sourceElement: i,
19946
19950
  internalState: s
19947
19951
  }) => {
19948
- const { planner: o } = Zt(), a = n.get("length") || 0, l = n.get("_length") || a, c = n.get("_unit") || Qr, { hook: h, label: f, ...g } = r, p = (m, v) => {
19952
+ const { planner: o } = Yt(), a = n.get("length") || 0, l = n.get("_length") || a, c = n.get("_unit") || Qr, { hook: h, label: f, ...g } = r, p = (m, v) => {
19949
19953
  let _ = Ve(m), S = n.merge({
19950
19954
  length: v !== Qr ? Yr(_).from(v).to(Qr) : _,
19951
19955
  _length: m,
@@ -20003,7 +20007,7 @@ const Ic = ({
20003
20007
  sourceElement: r,
20004
20008
  internalState: i
20005
20009
  }) => {
20006
- const { planner: s } = Zt(), o = (a) => e.hook ? e.hook(a, r, i, s).then((l) => t(l)) : t(a);
20010
+ const { planner: s } = Yt(), o = (a) => e.hook ? e.hook(a, r, i, s).then((l) => t(l)) : t(a);
20007
20011
  return /* @__PURE__ */ w.jsxs("div", { className: "PropertyString w-full mb-2", children: [
20008
20012
  /* @__PURE__ */ w.jsx(Vr, { children: e.label }),
20009
20013
  /* @__PURE__ */ w.jsx(
@@ -20234,9 +20238,9 @@ const Ic = ({
20234
20238
  // pasteProperties,
20235
20239
  setLinesAttributes: o,
20236
20240
  setHolesAttributes: a
20237
- } = Zt(), [l, c] = re(
20241
+ } = Yt(), [l, c] = ee(
20238
20242
  WS(n, t, e)
20239
- ), [h, f] = re(
20243
+ ), [h, f] = ee(
20240
20244
  US(n, e)
20241
20245
  ), g = ({ propertiesFormData: v, attributesFormData: _ }) => {
20242
20246
  if (v) {
@@ -20272,9 +20276,9 @@ const Ic = ({
20272
20276
  case "lines": {
20273
20277
  switch (v) {
20274
20278
  case "lineLength": {
20275
- let A = l.get("vertexOne"), C = l.get("vertexTwo"), [O, M] = ro([A, C]), z = uu(
20276
- O.x,
20277
- O.y,
20279
+ let A = l.get("vertexOne"), T = l.get("vertexTwo"), [C, M] = ro([A, T]), O = uu(
20280
+ C.x,
20281
+ C.y,
20278
20282
  M.x,
20279
20283
  M.y,
20280
20284
  _.get("length"),
@@ -20282,8 +20286,8 @@ const Ic = ({
20282
20286
  );
20283
20287
  S = l.withMutations((R) => {
20284
20288
  R.set(
20285
- A === O ? "vertexTwo" : "vertexOne",
20286
- M.merge(z)
20289
+ A === C ? "vertexTwo" : "vertexOne",
20290
+ M.merge(O)
20287
20291
  ), R.set("lineLength", _);
20288
20292
  });
20289
20293
  break;
@@ -20292,15 +20296,15 @@ const Ic = ({
20292
20296
  case "vertexTwo": {
20293
20297
  S = l.withMutations((A) => {
20294
20298
  A.set(v, A.get(v).merge(_));
20295
- let C = au(
20299
+ let T = au(
20296
20300
  A.get("vertexOne"),
20297
20301
  A.get("vertexTwo")
20298
20302
  );
20299
20303
  A.mergeIn(
20300
20304
  ["lineLength"],
20301
20305
  A.get("lineLength").merge({
20302
- length: C,
20303
- _length: Yr(C).from(e.unit).to(A.get("lineLength").get("_unit"))
20306
+ length: T,
20307
+ _length: Yr(T).from(e.unit).to(A.get("lineLength").get("_unit"))
20304
20308
  })
20305
20309
  );
20306
20310
  });
@@ -20319,15 +20323,15 @@ const Ic = ({
20319
20323
  case "holes": {
20320
20324
  switch (v) {
20321
20325
  case "offsetA": {
20322
- let A = t.lines.get(n.line), C = ro([
20326
+ let A = t.lines.get(n.line), T = ro([
20323
20327
  t.vertices.get(A.vertices.get(0)),
20324
20328
  t.vertices.get(A.vertices.get(1))
20325
- ]), [{ x: O, y: M }, { x: z, y: R }] = C, I = _c(O, M, z, R), L = Ce(O, M, z, R), U = n.properties.get("width").get("length"), Y = U / 2, it = _.get("length");
20329
+ ]), [{ x: C, y: M }, { x: O, y: R }] = T, I = _c(C, M, O, R), L = Ce(C, M, O, R), U = n.properties.get("width").get("length"), Y = U / 2, it = _.get("length");
20326
20330
  it = Math.max(it, 0), it = Math.min(it, L - U);
20327
- let rt = (it + Y) * Math.cos(I) + O, yt = (it + Y) * Math.sin(I) + M, mt = Oe(
20328
- O,
20331
+ let rt = (it + Y) * Math.cos(I) + C, yt = (it + Y) * Math.sin(I) + M, mt = Oe(
20332
+ C,
20329
20333
  M,
20330
- z,
20334
+ O,
20331
20335
  R,
20332
20336
  rt,
20333
20337
  yt
@@ -20355,15 +20359,15 @@ const Ic = ({
20355
20359
  break;
20356
20360
  }
20357
20361
  case "offsetB": {
20358
- let A = t.lines.get(n.line), C = ro([
20362
+ let A = t.lines.get(n.line), T = ro([
20359
20363
  t.vertices.get(A.vertices.get(0)),
20360
20364
  t.vertices.get(A.vertices.get(1))
20361
- ]), [{ x: O, y: M }, { x: z, y: R }] = C, I = _c(O, M, z, R), L = Ce(O, M, z, R), U = n.properties.get("width").get("length"), Y = U / 2, it = _.get("length");
20365
+ ]), [{ x: C, y: M }, { x: O, y: R }] = T, I = _c(C, M, O, R), L = Ce(C, M, O, R), U = n.properties.get("width").get("length"), Y = U / 2, it = _.get("length");
20362
20366
  it = Math.max(it, 0), it = Math.min(it, L - U);
20363
- let rt = z - (it + Y) * Math.cos(I), yt = R - (it + Y) * Math.sin(I), mt = Oe(
20364
- O,
20367
+ let rt = O - (it + Y) * Math.cos(I), yt = R - (it + Y) * Math.sin(I), mt = Oe(
20368
+ C,
20365
20369
  M,
20366
- z,
20370
+ O,
20367
20371
  R,
20368
20372
  rt,
20369
20373
  yt
@@ -20421,14 +20425,14 @@ const Ic = ({
20421
20425
  }
20422
20426
  ),
20423
20427
  h.entrySeq().map(([v, _]) => {
20424
- let S = _.get("currentValue"), A = _.get("configs"), { Editor: C } = e.getPropertyType(A.type);
20428
+ let S = _.get("currentValue"), A = _.get("configs"), { Editor: T } = e.getPropertyType(A.type);
20425
20429
  return /* @__PURE__ */ w.jsx(
20426
- C,
20430
+ T,
20427
20431
  {
20428
20432
  propertyName: v,
20429
20433
  value: S,
20430
20434
  configs: A,
20431
- onUpdate: (O) => m(v, O),
20435
+ onUpdate: (C) => m(v, C),
20432
20436
  state: r,
20433
20437
  sourceElement: n,
20434
20438
  internalState: {
@@ -20466,11 +20470,11 @@ const Ic = ({
20466
20470
  Pr,
20467
20471
  Rr,
20468
20472
  Lr,
20469
- Sn,
20473
+ Mn,
20470
20474
  gh,
20471
20475
  mh
20472
20476
  ], ZS = ({ catalog: n }) => {
20473
- const { planner: t } = Zt(), { scene: e, mode: r } = t;
20477
+ const { planner: t } = Yt(), { scene: e, mode: r } = t;
20474
20478
  return JS.includes(r) ? e.layers.valueSeq().flatMap(
20475
20479
  (s) => me().concat(s.lines, s.holes, s.areas, s.items).filter((o) => o.selected).map((o) => ({ element: o, layer: s }))
20476
20480
  ).toArray().length === 0 ? /* @__PURE__ */ w.jsx(XS, {}) : /* @__PURE__ */ w.jsx("div", { children: e.layers.valueSeq().map(
@@ -20508,7 +20512,7 @@ const Ic = ({
20508
20512
  MODE_DRAGGING_HOLE: Lr,
20509
20513
  MODE_FITTING_IMAGE: mh,
20510
20514
  MODE_UPLOADING_IMAGE: gh,
20511
- MODE_ROTATING_ITEM: Sn
20515
+ MODE_ROTATING_ITEM: Mn
20512
20516
  }, QS = { width: "100%" }, ea = { width: "6em" }, ra = { textAlign: "left" }, t2 = {
20513
20517
  marginLeft: "5px",
20514
20518
  border: "0px",
@@ -20529,7 +20533,7 @@ const Ic = ({
20529
20533
  groupTranslate: r,
20530
20534
  groupRotate: i,
20531
20535
  removeFromGroup: s
20532
- } = Zt(), { mode: o } = t;
20536
+ } = Yt(), { mode: o } = t;
20533
20537
  if (!n || !KS[o]) return null;
20534
20538
  const a = t.getIn(["scene", "groups", n]), l = a.get("elements");
20535
20539
  return /* @__PURE__ */ w.jsx(Ly, { name: `Group [${a.get("name")}]`, opened: !0, children: /* @__PURE__ */ w.jsxs("div", { style: { padding: "5px 15px" }, children: [
@@ -20655,7 +20659,7 @@ const Ic = ({
20655
20659
  ] }) : null
20656
20660
  ] }) });
20657
20661
  }, n2 = ({ catalog: n }) => {
20658
- const { planner: t } = Zt(), e = t.getIn(["scene", "selectedLayer"]), r = t.getIn([
20662
+ const { planner: t } = Yt(), e = t.getIn(["scene", "selectedLayer"]), r = t.getIn([
20659
20663
  "scene",
20660
20664
  "layers",
20661
20665
  e,
@@ -20680,7 +20684,7 @@ const Ic = ({
20680
20684
  children: r,
20681
20685
  className: i
20682
20686
  }) => {
20683
- const [s, o] = re(!1), a = n || s ? "text-[#1CA6FC]" : "text-[#C2C2C2]";
20687
+ const [s, o] = ee(!1), a = n || s ? "text-[#1CA6FC]" : "text-[#C2C2C2]";
20684
20688
  return /* @__PURE__ */ w.jsxs(
20685
20689
  "div",
20686
20690
  {
@@ -20769,7 +20773,7 @@ function i2({ mode: n }) {
20769
20773
  Ke,
20770
20774
  fr,
20771
20775
  Lr,
20772
- Sn
20776
+ Mn
20773
20777
  ].includes(n) ? /* @__PURE__ */ w.jsx(
20774
20778
  vn,
20775
20779
  {
@@ -20788,8 +20792,8 @@ function a2({
20788
20792
  onChange: n,
20789
20793
  ...t
20790
20794
  }) {
20791
- const [e, r] = re(""), i = jn(null);
20792
- Vn(() => {
20795
+ const [e, r] = ee(""), i = Vn(null);
20796
+ wn(() => {
20793
20797
  r(t.value);
20794
20798
  }, [t.value]);
20795
20799
  const s = (a) => {
@@ -20840,7 +20844,7 @@ function wp({
20840
20844
  sourceElement: r,
20841
20845
  internalState: i
20842
20846
  }) {
20843
- const { planner: s } = Zt(), o = (a) => e.hook ? e.hook(a, r, i, s).then((l) => t(l)) : t(a);
20847
+ const { planner: s } = Yt(), o = (a) => e.hook ? e.hook(a, r, i, s).then((l) => t(l)) : t(a);
20844
20848
  return /* @__PURE__ */ w.jsxs("div", { className: "PropertyColor w-full mb-2", children: [
20845
20849
  /* @__PURE__ */ w.jsx(Vr, { children: e.label }),
20846
20850
  /* @__PURE__ */ w.jsx(
@@ -20859,7 +20863,7 @@ function Sp({
20859
20863
  sourceElement: r,
20860
20864
  internalState: i
20861
20865
  }) {
20862
- const { planner: s } = Zt(), o = (a) => e.hook ? e.hook(a, r, i, s).then((l) => t(l)) : t(a);
20866
+ const { planner: s } = Yt(), o = (a) => e.hook ? e.hook(a, r, i, s).then((l) => t(l)) : t(a);
20863
20867
  return /* @__PURE__ */ w.jsxs("div", { className: "PropertyEnum w-full mb-2", children: [
20864
20868
  /* @__PURE__ */ w.jsx(Vr, { children: e.label }),
20865
20869
  /* @__PURE__ */ w.jsx(
@@ -20879,7 +20883,7 @@ function Mp({
20879
20883
  sourceElement: r,
20880
20884
  internalState: i
20881
20885
  }) {
20882
- const { planner: s } = Zt();
20886
+ const { planner: s } = Yt();
20883
20887
  let o = (a) => e.hook ? e.hook(a, r, i, s).then((l) => t(l)) : t(a);
20884
20888
  return /* @__PURE__ */ w.jsxs("div", { className: "PropertyString w-full mb-2", children: [
20885
20889
  /* @__PURE__ */ w.jsx(Vr, { children: e.label }),
@@ -20900,7 +20904,7 @@ function Ep({
20900
20904
  sourceElement: i,
20901
20905
  internalState: s
20902
20906
  }) {
20903
- const { planner: o } = Zt(), a = (l) => {
20907
+ const { planner: o } = Yt(), a = (l) => {
20904
20908
  let c = parseFloat(l);
20905
20909
  return isNaN(c) && (c = 0), r.hook ? r.hook(c, i, s, o).then((h) => t(h)) : t(c);
20906
20910
  };
@@ -20926,7 +20930,7 @@ function Ap({
20926
20930
  sourceElement: i,
20927
20931
  internalState: s
20928
20932
  }) {
20929
- const { planner: o } = Zt();
20933
+ const { planner: o } = Yt();
20930
20934
  let a = n.get("length") || 0, l = n.get("_length") || a, c = n.get("_unit") || Qr, { hook: h, label: f, ...g } = r;
20931
20935
  const p = (m, v) => {
20932
20936
  let _ = Ve(m), S = n.merge({
@@ -20978,7 +20982,7 @@ function u2({
20978
20982
  children: i,
20979
20983
  ...s
20980
20984
  }) {
20981
- const [o, a] = re(!1), l = "inline-block font-normal leading-[1.25] text-center whitespace-nowrap align-middle cursor-pointer select-none outline-none border border-solid w-full transition-colors duration-175 ease-linear rounded-[2px]", c = t === "small" ? "text-[12px] px-2 py-[3px]" : t === "large" ? "px-5 py-2" : "text-[14px] px-3 py-[5px]", h = {
20985
+ const [o, a] = ee(!1), l = "inline-block font-normal leading-[1.25] text-center whitespace-nowrap align-middle cursor-pointer select-none outline-none border border-solid w-full transition-colors duration-175 ease-linear rounded-[2px]", c = t === "small" ? "text-[12px] px-2 py-[3px]" : t === "large" ? "px-5 py-2" : "text-[14px] px-3 py-[5px]", h = {
20982
20986
  backgroundColor: "#e6e6e6",
20983
20987
  borderColor: "#adadad"
20984
20988
  }, f = {
@@ -21018,7 +21022,7 @@ function Op({
21018
21022
  sourceElement: r,
21019
21023
  internalState: i
21020
21024
  }) {
21021
- const { planner: s } = Zt(), o = (a) => e.hook ? e.hook(a, r, i, s).then((l) => t(l)) : t(a);
21025
+ const { planner: s } = Yt(), o = (a) => e.hook ? e.hook(a, r, i, s).then((l) => t(l)) : t(a);
21022
21026
  return /* @__PURE__ */ w.jsx("table", { className: "PropertyToggle", style: Xa.tableStyle, children: /* @__PURE__ */ w.jsx("tbody", { children: /* @__PURE__ */ w.jsxs("tr", { children: [
21023
21027
  /* @__PURE__ */ w.jsx("td", { style: Xa.firstTdStyle, children: /* @__PURE__ */ w.jsx(Vr, { children: e.label }) }),
21024
21028
  /* @__PURE__ */ w.jsx("td", { children: /* @__PURE__ */ w.jsx(u2, { onClick: () => o(!n), size: "small", children: e.actionName }) })
@@ -21031,7 +21035,7 @@ function zp({
21031
21035
  sourceElement: r,
21032
21036
  internalState: i
21033
21037
  }) {
21034
- const { planner: s } = Zt(), o = (a) => e.hook ? e.hook(a, r, i, s).then((l) => t(l)) : t(a);
21038
+ const { planner: s } = Yt(), o = (a) => e.hook ? e.hook(a, r, i, s).then((l) => t(l)) : t(a);
21035
21039
  return /* @__PURE__ */ w.jsxs("div", { className: "PropertyCheckbox w-full flex items-center gap-2 mb-2", children: [
21036
21040
  /* @__PURE__ */ w.jsx(
21037
21041
  "input",
@@ -21750,13 +21754,13 @@ class ws {
21750
21754
  }
21751
21755
  if (f !== v || l !== g || c !== p || h !== m) {
21752
21756
  let _ = 1 - a;
21753
- const S = l * g + c * p + h * m + f * v, A = S >= 0 ? 1 : -1, C = 1 - S * S;
21754
- if (C > Number.EPSILON) {
21755
- const M = Math.sqrt(C), z = Math.atan2(M, S * A);
21756
- _ = Math.sin(_ * z) / M, a = Math.sin(a * z) / M;
21757
+ const S = l * g + c * p + h * m + f * v, A = S >= 0 ? 1 : -1, T = 1 - S * S;
21758
+ if (T > Number.EPSILON) {
21759
+ const M = Math.sqrt(T), O = Math.atan2(M, S * A);
21760
+ _ = Math.sin(_ * O) / M, a = Math.sin(a * O) / M;
21757
21761
  }
21758
- const O = a * A;
21759
- if (l = l * _ + g * O, c = c * _ + p * O, h = h * _ + m * O, f = f * _ + v * O, _ === 1 - a) {
21762
+ const C = a * A;
21763
+ if (l = l * _ + g * C, c = c * _ + p * C, h = h * _ + m * C, f = f * _ + v * C, _ === 1 - a) {
21760
21764
  const M = 1 / Math.sqrt(l * l + c * c + h * h + f * f);
21761
21765
  l *= M, c *= M, h *= M, f *= M;
21762
21766
  }
@@ -23056,8 +23060,8 @@ class Gn {
23056
23060
  * @return {Matrix3} A reference to this matrix.
23057
23061
  */
23058
23062
  multiplyMatrices(t, e) {
23059
- const r = t.elements, i = e.elements, s = this.elements, o = r[0], a = r[3], l = r[6], c = r[1], h = r[4], f = r[7], g = r[2], p = r[5], m = r[8], v = i[0], _ = i[3], S = i[6], A = i[1], C = i[4], O = i[7], M = i[2], z = i[5], R = i[8];
23060
- return s[0] = o * v + a * A + l * M, s[3] = o * _ + a * C + l * z, s[6] = o * S + a * O + l * R, s[1] = c * v + h * A + f * M, s[4] = c * _ + h * C + f * z, s[7] = c * S + h * O + f * R, s[2] = g * v + p * A + m * M, s[5] = g * _ + p * C + m * z, s[8] = g * S + p * O + m * R, this;
23063
+ const r = t.elements, i = e.elements, s = this.elements, o = r[0], a = r[3], l = r[6], c = r[1], h = r[4], f = r[7], g = r[2], p = r[5], m = r[8], v = i[0], _ = i[3], S = i[6], A = i[1], T = i[4], C = i[7], M = i[2], O = i[5], R = i[8];
23064
+ return s[0] = o * v + a * A + l * M, s[3] = o * _ + a * T + l * O, s[6] = o * S + a * C + l * R, s[1] = c * v + h * A + f * M, s[4] = c * _ + h * T + f * O, s[7] = c * S + h * C + f * R, s[2] = g * v + p * A + m * M, s[5] = g * _ + p * T + m * O, s[8] = g * S + p * C + m * R, this;
23061
23065
  }
23062
23066
  /**
23063
23067
  * Multiplies every component of the matrix by the given scalar.
@@ -23538,7 +23542,7 @@ function Ol(n) {
23538
23542
  }
23539
23543
  let E2 = 0;
23540
23544
  const zl = /* @__PURE__ */ new V();
23541
- class Fn extends gu {
23545
+ class jn extends gu {
23542
23546
  /**
23543
23547
  * Constructs a new texture.
23544
23548
  *
@@ -23553,7 +23557,7 @@ class Fn extends gu {
23553
23557
  * @param {number} [anisotropy=Texture.DEFAULT_ANISOTROPY] - The anisotropy value.
23554
23558
  * @param {string} [colorSpace=NoColorSpace] - The color space.
23555
23559
  */
23556
- constructor(t = Fn.DEFAULT_IMAGE, e = Fn.DEFAULT_MAPPING, r = na, i = na, s = d2, o = p2, a = y2, l = g2, c = Fn.DEFAULT_ANISOTROPY, h = Dy) {
23560
+ constructor(t = jn.DEFAULT_IMAGE, e = jn.DEFAULT_MAPPING, r = na, i = na, s = d2, o = p2, a = y2, l = g2, c = jn.DEFAULT_ANISOTROPY, h = Dy) {
23557
23561
  super(), this.isTexture = !0, Object.defineProperty(this, "id", { value: E2++ }), this.uuid = bs(), this.name = "", this.source = new M2(t), this.mipmaps = [], this.mapping = e, this.channel = 0, this.wrapS = r, this.wrapT = i, this.magFilter = s, this.minFilter = o, this.anisotropy = c, this.format = a, this.internalFormat = null, this.type = l, this.offset = new xt(0, 0), this.repeat = new xt(1, 1), this.center = new xt(0, 0), this.rotation = 0, this.matrixAutoUpdate = !0, this.matrix = new Gn(), this.generateMipmaps = !0, this.premultiplyAlpha = !1, this.flipY = !0, this.unpackAlignment = 4, this.colorSpace = h, this.userData = {}, this.updateRanges = [], this.version = 0, this.onUpdate = null, this.renderTarget = null, this.isRenderTargetTexture = !1, this.isArrayTexture = !!(t && t.depth && t.depth > 1), this.pmremVersion = 0;
23558
23562
  }
23559
23563
  /**
@@ -23751,9 +23755,9 @@ class Fn extends gu {
23751
23755
  t === !0 && this.pmremVersion++;
23752
23756
  }
23753
23757
  }
23754
- Fn.DEFAULT_IMAGE = null;
23755
- Fn.DEFAULT_MAPPING = Vy;
23756
- Fn.DEFAULT_ANISOTROPY = 1;
23758
+ jn.DEFAULT_IMAGE = null;
23759
+ jn.DEFAULT_MAPPING = Vy;
23760
+ jn.DEFAULT_ANISOTROPY = 1;
23757
23761
  class Co {
23758
23762
  /**
23759
23763
  * Constructs a new 4D vector.
@@ -24048,8 +24052,8 @@ class Co {
24048
24052
  if (Math.abs(h + g) < 0.1 && Math.abs(f + v) < 0.1 && Math.abs(m + _) < 0.1 && Math.abs(c + p + S - 3) < 0.1)
24049
24053
  return this.set(1, 0, 0, 0), this;
24050
24054
  e = Math.PI;
24051
- const C = (c + 1) / 2, O = (p + 1) / 2, M = (S + 1) / 2, z = (h + g) / 4, R = (f + v) / 4, I = (m + _) / 4;
24052
- return C > O && C > M ? C < 0.01 ? (r = 0, i = 0.707106781, s = 0.707106781) : (r = Math.sqrt(C), i = z / r, s = R / r) : O > M ? O < 0.01 ? (r = 0.707106781, i = 0, s = 0.707106781) : (i = Math.sqrt(O), r = z / i, s = I / i) : M < 0.01 ? (r = 0.707106781, i = 0.707106781, s = 0) : (s = Math.sqrt(M), r = R / s, i = I / s), this.set(r, i, s, e), this;
24055
+ const T = (c + 1) / 2, C = (p + 1) / 2, M = (S + 1) / 2, O = (h + g) / 4, R = (f + v) / 4, I = (m + _) / 4;
24056
+ return T > C && T > M ? T < 0.01 ? (r = 0, i = 0.707106781, s = 0.707106781) : (r = Math.sqrt(T), i = O / r, s = R / r) : C > M ? C < 0.01 ? (r = 0.707106781, i = 0, s = 0.707106781) : (i = Math.sqrt(C), r = O / i, s = I / i) : M < 0.01 ? (r = 0.707106781, i = 0.707106781, s = 0) : (s = Math.sqrt(M), r = R / s, i = I / s), this.set(r, i, s, e), this;
24053
24057
  }
24054
24058
  let A = Math.sqrt((_ - m) * (_ - m) + (f - v) * (f - v) + (g - h) * (g - h));
24055
24059
  return Math.abs(A) < 1e-3 && (A = 1), this.x = (_ - m) / A, this.y = (f - v) / A, this.z = (g - h) / A, this.w = Math.acos((c + p + S - 1) / 2), this;
@@ -24566,37 +24570,37 @@ class Ss {
24566
24570
  intersectsTriangle(t) {
24567
24571
  if (this.isEmpty())
24568
24572
  return !1;
24569
- this.getCenter($s), oa.subVectors(this.max, $s), Ci.subVectors(t.a, $s), ki.subVectors(t.b, $s), Ii.subVectors(t.c, $s), Cn.subVectors(ki, Ci), kn.subVectors(Ii, ki), Qn.subVectors(Ci, Ii);
24573
+ this.getCenter($s), oa.subVectors(this.max, $s), Ci.subVectors(t.a, $s), ki.subVectors(t.b, $s), Ii.subVectors(t.c, $s), kn.subVectors(ki, Ci), In.subVectors(Ii, ki), Qn.subVectors(Ci, Ii);
24570
24574
  let e = [
24571
- 0,
24572
- -Cn.z,
24573
- Cn.y,
24574
24575
  0,
24575
24576
  -kn.z,
24576
24577
  kn.y,
24577
24578
  0,
24579
+ -In.z,
24580
+ In.y,
24581
+ 0,
24578
24582
  -Qn.z,
24579
24583
  Qn.y,
24580
- Cn.z,
24581
- 0,
24582
- -Cn.x,
24583
24584
  kn.z,
24584
24585
  0,
24585
24586
  -kn.x,
24587
+ In.z,
24588
+ 0,
24589
+ -In.x,
24586
24590
  Qn.z,
24587
24591
  0,
24588
24592
  -Qn.x,
24589
- -Cn.y,
24590
- Cn.x,
24591
- 0,
24592
24593
  -kn.y,
24593
24594
  kn.x,
24594
24595
  0,
24596
+ -In.y,
24597
+ In.x,
24598
+ 0,
24595
24599
  -Qn.y,
24596
24600
  Qn.x,
24597
24601
  0
24598
24602
  ];
24599
- return !Tl(e, Ci, ki, Ii, oa) || (e = [1, 0, 0, 0, 1, 0, 0, 0, 1], !Tl(e, Ci, ki, Ii, oa)) ? !1 : (aa.crossVectors(Cn, kn), e = [aa.x, aa.y, aa.z], Tl(e, Ci, ki, Ii, oa));
24603
+ return !Tl(e, Ci, ki, Ii, oa) || (e = [1, 0, 0, 0, 1, 0, 0, 0, 1], !Tl(e, Ci, ki, Ii, oa)) ? !1 : (aa.crossVectors(kn, In), e = [aa.x, aa.y, aa.z], Tl(e, Ci, ki, Ii, oa));
24600
24604
  }
24601
24605
  /**
24602
24606
  * Clamps the given point within the bounds of this box.
@@ -24708,7 +24712,7 @@ const hn = [
24708
24712
  /* @__PURE__ */ new V(),
24709
24713
  /* @__PURE__ */ new V(),
24710
24714
  /* @__PURE__ */ new V()
24711
- ], wr = /* @__PURE__ */ new V(), sa = /* @__PURE__ */ new Ss(), Ci = /* @__PURE__ */ new V(), ki = /* @__PURE__ */ new V(), Ii = /* @__PURE__ */ new V(), Cn = /* @__PURE__ */ new V(), kn = /* @__PURE__ */ new V(), Qn = /* @__PURE__ */ new V(), $s = /* @__PURE__ */ new V(), oa = /* @__PURE__ */ new V(), aa = /* @__PURE__ */ new V(), ti = /* @__PURE__ */ new V();
24715
+ ], wr = /* @__PURE__ */ new V(), sa = /* @__PURE__ */ new Ss(), Ci = /* @__PURE__ */ new V(), ki = /* @__PURE__ */ new V(), Ii = /* @__PURE__ */ new V(), kn = /* @__PURE__ */ new V(), In = /* @__PURE__ */ new V(), Qn = /* @__PURE__ */ new V(), $s = /* @__PURE__ */ new V(), oa = /* @__PURE__ */ new V(), aa = /* @__PURE__ */ new V(), ti = /* @__PURE__ */ new V();
24712
24716
  function Tl(n, t, e, r, i) {
24713
24717
  for (let s = 0, o = n.length - 3; s <= o; s += 3) {
24714
24718
  ti.fromArray(n, s);
@@ -24938,7 +24942,7 @@ class By {
24938
24942
  return this.radius = t.radius, this.center.fromArray(t.center), this;
24939
24943
  }
24940
24944
  }
24941
- const fn = /* @__PURE__ */ new V(), kl = /* @__PURE__ */ new V(), ua = /* @__PURE__ */ new V(), In = /* @__PURE__ */ new V(), Il = /* @__PURE__ */ new V(), la = /* @__PURE__ */ new V(), Pl = /* @__PURE__ */ new V();
24945
+ const fn = /* @__PURE__ */ new V(), kl = /* @__PURE__ */ new V(), ua = /* @__PURE__ */ new V(), Pn = /* @__PURE__ */ new V(), Il = /* @__PURE__ */ new V(), la = /* @__PURE__ */ new V(), Pl = /* @__PURE__ */ new V();
24942
24946
  class O2 {
24943
24947
  /**
24944
24948
  * Constructs a new ray.
@@ -25037,8 +25041,8 @@ class O2 {
25037
25041
  * @return {number} The squared distance.
25038
25042
  */
25039
25043
  distanceSqToSegment(t, e, r, i) {
25040
- kl.copy(t).add(e).multiplyScalar(0.5), ua.copy(e).sub(t).normalize(), In.copy(this.origin).sub(kl);
25041
- const s = t.distanceTo(e) * 0.5, o = -this.direction.dot(ua), a = In.dot(this.direction), l = -In.dot(ua), c = In.lengthSq(), h = Math.abs(1 - o * o);
25044
+ kl.copy(t).add(e).multiplyScalar(0.5), ua.copy(e).sub(t).normalize(), Pn.copy(this.origin).sub(kl);
25045
+ const s = t.distanceTo(e) * 0.5, o = -this.direction.dot(ua), a = Pn.dot(this.direction), l = -Pn.dot(ua), c = Pn.lengthSq(), h = Math.abs(1 - o * o);
25042
25046
  let f, g, p, m;
25043
25047
  if (h > 0)
25044
25048
  if (f = o * l - a, g = o * a - l, m = s * h, f >= 0)
@@ -25159,14 +25163,14 @@ class O2 {
25159
25163
  a = -1, o = -o;
25160
25164
  else
25161
25165
  return null;
25162
- In.subVectors(this.origin, t);
25163
- const l = a * this.direction.dot(la.crossVectors(In, la));
25166
+ Pn.subVectors(this.origin, t);
25167
+ const l = a * this.direction.dot(la.crossVectors(Pn, la));
25164
25168
  if (l < 0)
25165
25169
  return null;
25166
- const c = a * this.direction.dot(Il.cross(In));
25170
+ const c = a * this.direction.dot(Il.cross(Pn));
25167
25171
  if (c < 0 || l + c > o)
25168
25172
  return null;
25169
- const h = -a * In.dot(Pl);
25173
+ const h = -a * Pn.dot(Pl);
25170
25174
  return h < 0 ? null : this.at(h / o, s);
25171
25175
  }
25172
25176
  /**
@@ -25453,7 +25457,7 @@ class Re {
25453
25457
  */
25454
25458
  lookAt(t, e, r) {
25455
25459
  const i = this.elements;
25456
- return Ue.subVectors(t, e), Ue.lengthSq() === 0 && (Ue.z = 1), Ue.normalize(), Pn.crossVectors(r, Ue), Pn.lengthSq() === 0 && (Math.abs(r.z) === 1 ? Ue.x += 1e-4 : Ue.z += 1e-4, Ue.normalize(), Pn.crossVectors(r, Ue)), Pn.normalize(), ca.crossVectors(Ue, Pn), i[0] = Pn.x, i[4] = ca.x, i[8] = Ue.x, i[1] = Pn.y, i[5] = ca.y, i[9] = Ue.y, i[2] = Pn.z, i[6] = ca.z, i[10] = Ue.z, this;
25460
+ return Ue.subVectors(t, e), Ue.lengthSq() === 0 && (Ue.z = 1), Ue.normalize(), Rn.crossVectors(r, Ue), Rn.lengthSq() === 0 && (Math.abs(r.z) === 1 ? Ue.x += 1e-4 : Ue.z += 1e-4, Ue.normalize(), Rn.crossVectors(r, Ue)), Rn.normalize(), ca.crossVectors(Ue, Rn), i[0] = Rn.x, i[4] = ca.x, i[8] = Ue.x, i[1] = Rn.y, i[5] = ca.y, i[9] = Ue.y, i[2] = Rn.z, i[6] = ca.z, i[10] = Ue.z, this;
25457
25461
  }
25458
25462
  /**
25459
25463
  * Post-multiplies this matrix by the given 4x4 matrix.
@@ -25482,8 +25486,8 @@ class Re {
25482
25486
  * @return {Matrix4} A reference to this matrix.
25483
25487
  */
25484
25488
  multiplyMatrices(t, e) {
25485
- const r = t.elements, i = e.elements, s = this.elements, o = r[0], a = r[4], l = r[8], c = r[12], h = r[1], f = r[5], g = r[9], p = r[13], m = r[2], v = r[6], _ = r[10], S = r[14], A = r[3], C = r[7], O = r[11], M = r[15], z = i[0], R = i[4], I = i[8], L = i[12], U = i[1], Y = i[5], it = i[9], rt = i[13], yt = i[2], mt = i[6], dt = i[10], ot = i[14], G = i[3], pt = i[7], k = i[11], F = i[15];
25486
- return s[0] = o * z + a * U + l * yt + c * G, s[4] = o * R + a * Y + l * mt + c * pt, s[8] = o * I + a * it + l * dt + c * k, s[12] = o * L + a * rt + l * ot + c * F, s[1] = h * z + f * U + g * yt + p * G, s[5] = h * R + f * Y + g * mt + p * pt, s[9] = h * I + f * it + g * dt + p * k, s[13] = h * L + f * rt + g * ot + p * F, s[2] = m * z + v * U + _ * yt + S * G, s[6] = m * R + v * Y + _ * mt + S * pt, s[10] = m * I + v * it + _ * dt + S * k, s[14] = m * L + v * rt + _ * ot + S * F, s[3] = A * z + C * U + O * yt + M * G, s[7] = A * R + C * Y + O * mt + M * pt, s[11] = A * I + C * it + O * dt + M * k, s[15] = A * L + C * rt + O * ot + M * F, this;
25489
+ const r = t.elements, i = e.elements, s = this.elements, o = r[0], a = r[4], l = r[8], c = r[12], h = r[1], f = r[5], g = r[9], p = r[13], m = r[2], v = r[6], _ = r[10], S = r[14], A = r[3], T = r[7], C = r[11], M = r[15], O = i[0], R = i[4], I = i[8], L = i[12], U = i[1], Y = i[5], it = i[9], rt = i[13], yt = i[2], mt = i[6], dt = i[10], ot = i[14], G = i[3], pt = i[7], k = i[11], F = i[15];
25490
+ return s[0] = o * O + a * U + l * yt + c * G, s[4] = o * R + a * Y + l * mt + c * pt, s[8] = o * I + a * it + l * dt + c * k, s[12] = o * L + a * rt + l * ot + c * F, s[1] = h * O + f * U + g * yt + p * G, s[5] = h * R + f * Y + g * mt + p * pt, s[9] = h * I + f * it + g * dt + p * k, s[13] = h * L + f * rt + g * ot + p * F, s[2] = m * O + v * U + _ * yt + S * G, s[6] = m * R + v * Y + _ * mt + S * pt, s[10] = m * I + v * it + _ * dt + S * k, s[14] = m * L + v * rt + _ * ot + S * F, s[3] = A * O + T * U + C * yt + M * G, s[7] = A * R + T * Y + C * mt + M * pt, s[11] = A * I + T * it + C * dt + M * k, s[15] = A * L + T * rt + C * ot + M * F, this;
25487
25491
  }
25488
25492
  /**
25489
25493
  * Multiplies every component of the matrix by the given scalar.
@@ -25537,10 +25541,10 @@ class Re {
25537
25541
  * @return {Matrix4} A reference to this matrix.
25538
25542
  */
25539
25543
  invert() {
25540
- const t = this.elements, e = t[0], r = t[1], i = t[2], s = t[3], o = t[4], a = t[5], l = t[6], c = t[7], h = t[8], f = t[9], g = t[10], p = t[11], m = t[12], v = t[13], _ = t[14], S = t[15], A = f * _ * c - v * g * c + v * l * p - a * _ * p - f * l * S + a * g * S, C = m * g * c - h * _ * c - m * l * p + o * _ * p + h * l * S - o * g * S, O = h * v * c - m * f * c + m * a * p - o * v * p - h * a * S + o * f * S, M = m * f * l - h * v * l - m * a * g + o * v * g + h * a * _ - o * f * _, z = e * A + r * C + i * O + s * M;
25541
- if (z === 0) return this.set(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
25542
- const R = 1 / z;
25543
- return t[0] = A * R, t[1] = (v * g * s - f * _ * s - v * i * p + r * _ * p + f * i * S - r * g * S) * R, t[2] = (a * _ * s - v * l * s + v * i * c - r * _ * c - a * i * S + r * l * S) * R, t[3] = (f * l * s - a * g * s - f * i * c + r * g * c + a * i * p - r * l * p) * R, t[4] = C * R, t[5] = (h * _ * s - m * g * s + m * i * p - e * _ * p - h * i * S + e * g * S) * R, t[6] = (m * l * s - o * _ * s - m * i * c + e * _ * c + o * i * S - e * l * S) * R, t[7] = (o * g * s - h * l * s + h * i * c - e * g * c - o * i * p + e * l * p) * R, t[8] = O * R, t[9] = (m * f * s - h * v * s - m * r * p + e * v * p + h * r * S - e * f * S) * R, t[10] = (o * v * s - m * a * s + m * r * c - e * v * c - o * r * S + e * a * S) * R, t[11] = (h * a * s - o * f * s - h * r * c + e * f * c + o * r * p - e * a * p) * R, t[12] = M * R, t[13] = (h * v * i - m * f * i + m * r * g - e * v * g - h * r * _ + e * f * _) * R, t[14] = (m * a * i - o * v * i - m * r * l + e * v * l + o * r * _ - e * a * _) * R, t[15] = (o * f * i - h * a * i + h * r * l - e * f * l - o * r * g + e * a * g) * R, this;
25544
+ const t = this.elements, e = t[0], r = t[1], i = t[2], s = t[3], o = t[4], a = t[5], l = t[6], c = t[7], h = t[8], f = t[9], g = t[10], p = t[11], m = t[12], v = t[13], _ = t[14], S = t[15], A = f * _ * c - v * g * c + v * l * p - a * _ * p - f * l * S + a * g * S, T = m * g * c - h * _ * c - m * l * p + o * _ * p + h * l * S - o * g * S, C = h * v * c - m * f * c + m * a * p - o * v * p - h * a * S + o * f * S, M = m * f * l - h * v * l - m * a * g + o * v * g + h * a * _ - o * f * _, O = e * A + r * T + i * C + s * M;
25545
+ if (O === 0) return this.set(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
25546
+ const R = 1 / O;
25547
+ return t[0] = A * R, t[1] = (v * g * s - f * _ * s - v * i * p + r * _ * p + f * i * S - r * g * S) * R, t[2] = (a * _ * s - v * l * s + v * i * c - r * _ * c - a * i * S + r * l * S) * R, t[3] = (f * l * s - a * g * s - f * i * c + r * g * c + a * i * p - r * l * p) * R, t[4] = T * R, t[5] = (h * _ * s - m * g * s + m * i * p - e * _ * p - h * i * S + e * g * S) * R, t[6] = (m * l * s - o * _ * s - m * i * c + e * _ * c + o * i * S - e * l * S) * R, t[7] = (o * g * s - h * l * s + h * i * c - e * g * c - o * i * p + e * l * p) * R, t[8] = C * R, t[9] = (m * f * s - h * v * s - m * r * p + e * v * p + h * r * S - e * f * S) * R, t[10] = (o * v * s - m * a * s + m * r * c - e * v * c - o * r * S + e * a * S) * R, t[11] = (h * a * s - o * f * s - h * r * c + e * f * c + o * r * p - e * a * p) * R, t[12] = M * R, t[13] = (h * v * i - m * f * i + m * r * g - e * v * g - h * r * _ + e * f * _) * R, t[14] = (m * a * i - o * v * i - m * r * l + e * v * l + o * r * _ - e * a * _) * R, t[15] = (o * f * i - h * a * i + h * r * l - e * f * l - o * r * g + e * a * g) * R, this;
25544
25548
  }
25545
25549
  /**
25546
25550
  * Multiplies the columns of this matrix by the given vector.
@@ -25791,8 +25795,8 @@ class Re {
25791
25795
  * @return {Matrix4} A reference to this matrix.
25792
25796
  */
25793
25797
  compose(t, e, r) {
25794
- const i = this.elements, s = e._x, o = e._y, a = e._z, l = e._w, c = s + s, h = o + o, f = a + a, g = s * c, p = s * h, m = s * f, v = o * h, _ = o * f, S = a * f, A = l * c, C = l * h, O = l * f, M = r.x, z = r.y, R = r.z;
25795
- return i[0] = (1 - (v + S)) * M, i[1] = (p + O) * M, i[2] = (m - C) * M, i[3] = 0, i[4] = (p - O) * z, i[5] = (1 - (g + S)) * z, i[6] = (_ + A) * z, i[7] = 0, i[8] = (m + C) * R, i[9] = (_ - A) * R, i[10] = (1 - (g + v)) * R, i[11] = 0, i[12] = t.x, i[13] = t.y, i[14] = t.z, i[15] = 1, this;
25798
+ const i = this.elements, s = e._x, o = e._y, a = e._z, l = e._w, c = s + s, h = o + o, f = a + a, g = s * c, p = s * h, m = s * f, v = o * h, _ = o * f, S = a * f, A = l * c, T = l * h, C = l * f, M = r.x, O = r.y, R = r.z;
25799
+ return i[0] = (1 - (v + S)) * M, i[1] = (p + C) * M, i[2] = (m - T) * M, i[3] = 0, i[4] = (p - C) * O, i[5] = (1 - (g + S)) * O, i[6] = (_ + A) * O, i[7] = 0, i[8] = (m + T) * R, i[9] = (_ - A) * R, i[10] = (1 - (g + v)) * R, i[11] = 0, i[12] = t.x, i[13] = t.y, i[14] = t.z, i[15] = 1, this;
25796
25800
  }
25797
25801
  /**
25798
25802
  * Decomposes this matrix into its position, rotation and scale components
@@ -25906,7 +25910,7 @@ class Re {
25906
25910
  return t[e] = r[0], t[e + 1] = r[1], t[e + 2] = r[2], t[e + 3] = r[3], t[e + 4] = r[4], t[e + 5] = r[5], t[e + 6] = r[6], t[e + 7] = r[7], t[e + 8] = r[8], t[e + 9] = r[9], t[e + 10] = r[10], t[e + 11] = r[11], t[e + 12] = r[12], t[e + 13] = r[13], t[e + 14] = r[14], t[e + 15] = r[15], t;
25907
25911
  }
25908
25912
  }
25909
- const Pi = /* @__PURE__ */ new V(), Sr = /* @__PURE__ */ new Re(), z2 = /* @__PURE__ */ new V(0, 0, 0), T2 = /* @__PURE__ */ new V(1, 1, 1), Pn = /* @__PURE__ */ new V(), ca = /* @__PURE__ */ new V(), Ue = /* @__PURE__ */ new V(), Up = /* @__PURE__ */ new Re(), Yp = /* @__PURE__ */ new ws();
25913
+ const Pi = /* @__PURE__ */ new V(), Sr = /* @__PURE__ */ new Re(), z2 = /* @__PURE__ */ new V(0, 0, 0), T2 = /* @__PURE__ */ new V(1, 1, 1), Rn = /* @__PURE__ */ new V(), ca = /* @__PURE__ */ new V(), Ue = /* @__PURE__ */ new V(), Up = /* @__PURE__ */ new Re(), Yp = /* @__PURE__ */ new ws();
25910
25914
  class Ms {
25911
25915
  /**
25912
25916
  * Constructs a new euler instance.
@@ -27272,7 +27276,7 @@ const qy = {
27272
27276
  whitesmoke: 16119285,
27273
27277
  yellow: 16776960,
27274
27278
  yellowgreen: 10145074
27275
- }, Rn = { h: 0, s: 0, l: 0 }, fa = { h: 0, s: 0, l: 0 };
27279
+ }, Ln = { h: 0, s: 0, l: 0 }, fa = { h: 0, s: 0, l: 0 };
27276
27280
  function ql(n, t, e) {
27277
27281
  return e < 0 && (e += 1), e > 1 && (e -= 1), e < 1 / 6 ? n + (t - n) * 6 * e : e < 1 / 2 ? t : e < 2 / 3 ? n + (t - n) * 6 * (2 / 3 - e) : n;
27278
27282
  }
@@ -27574,7 +27578,7 @@ class si {
27574
27578
  * @return {Color} A reference to this color.
27575
27579
  */
27576
27580
  offsetHSL(t, e, r) {
27577
- return this.getHSL(Rn), this.setHSL(Rn.h + t, Rn.s + e, Rn.l + r);
27581
+ return this.getHSL(Ln), this.setHSL(Ln.h + t, Ln.s + e, Ln.l + r);
27578
27582
  }
27579
27583
  /**
27580
27584
  * Adds the RGB values of the given color to the RGB values of this color.
@@ -27668,8 +27672,8 @@ class si {
27668
27672
  * @return {Color} A reference to this color.
27669
27673
  */
27670
27674
  lerpHSL(t, e) {
27671
- this.getHSL(Rn), t.getHSL(fa);
27672
- const r = Ml(Rn.h, fa.h, e), i = Ml(Rn.s, fa.s, e), s = Ml(Rn.l, fa.l, e);
27675
+ this.getHSL(Ln), t.getHSL(fa);
27676
+ const r = Ml(Ln.h, fa.h, e), i = Ml(Ln.s, fa.s, e), s = Ml(Ln.l, fa.l, e);
27673
27677
  return this.setHSL(r, i, s), this;
27674
27678
  }
27675
27679
  /**
@@ -28631,13 +28635,13 @@ class ui extends gu {
28631
28635
  t.getX(rt + 2)
28632
28636
  );
28633
28637
  }
28634
- const C = new V(), O = new V(), M = new V(), z = new V();
28638
+ const T = new V(), C = new V(), M = new V(), O = new V();
28635
28639
  function R(I) {
28636
- M.fromBufferAttribute(i, I), z.copy(M);
28640
+ M.fromBufferAttribute(i, I), O.copy(M);
28637
28641
  const L = a[I];
28638
- C.copy(L), C.sub(M.multiplyScalar(M.dot(L))).normalize(), O.crossVectors(z, L);
28639
- const Y = O.dot(l[I]) < 0 ? -1 : 1;
28640
- o.setXYZW(I, C.x, C.y, C.z, Y);
28642
+ T.copy(L), T.sub(M.multiplyScalar(M.dot(L))).normalize(), C.crossVectors(O, L);
28643
+ const Y = C.dot(l[I]) < 0 ? -1 : 1;
28644
+ o.setXYZW(I, T.x, T.y, T.z, Y);
28641
28645
  }
28642
28646
  for (let I = 0, L = A.length; I < L; ++I) {
28643
28647
  const U = A[I], Y = U.start, it = U.count;
@@ -28890,33 +28894,33 @@ class as extends en {
28890
28894
  if (a !== null)
28891
28895
  if (Array.isArray(o))
28892
28896
  for (let m = 0, v = g.length; m < v; m++) {
28893
- const _ = g[m], S = o[_.materialIndex], A = Math.max(_.start, p.start), C = Math.min(a.count, Math.min(_.start + _.count, p.start + p.count));
28894
- for (let O = A, M = C; O < M; O += 3) {
28895
- const z = a.getX(O), R = a.getX(O + 1), I = a.getX(O + 2);
28896
- i = _a(this, S, t, r, c, h, f, z, R, I), i && (i.faceIndex = Math.floor(O / 3), i.face.materialIndex = _.materialIndex, e.push(i));
28897
+ const _ = g[m], S = o[_.materialIndex], A = Math.max(_.start, p.start), T = Math.min(a.count, Math.min(_.start + _.count, p.start + p.count));
28898
+ for (let C = A, M = T; C < M; C += 3) {
28899
+ const O = a.getX(C), R = a.getX(C + 1), I = a.getX(C + 2);
28900
+ i = _a(this, S, t, r, c, h, f, O, R, I), i && (i.faceIndex = Math.floor(C / 3), i.face.materialIndex = _.materialIndex, e.push(i));
28897
28901
  }
28898
28902
  }
28899
28903
  else {
28900
28904
  const m = Math.max(0, p.start), v = Math.min(a.count, p.start + p.count);
28901
28905
  for (let _ = m, S = v; _ < S; _ += 3) {
28902
- const A = a.getX(_), C = a.getX(_ + 1), O = a.getX(_ + 2);
28903
- i = _a(this, o, t, r, c, h, f, A, C, O), i && (i.faceIndex = Math.floor(_ / 3), e.push(i));
28906
+ const A = a.getX(_), T = a.getX(_ + 1), C = a.getX(_ + 2);
28907
+ i = _a(this, o, t, r, c, h, f, A, T, C), i && (i.faceIndex = Math.floor(_ / 3), e.push(i));
28904
28908
  }
28905
28909
  }
28906
28910
  else if (l !== void 0)
28907
28911
  if (Array.isArray(o))
28908
28912
  for (let m = 0, v = g.length; m < v; m++) {
28909
- const _ = g[m], S = o[_.materialIndex], A = Math.max(_.start, p.start), C = Math.min(l.count, Math.min(_.start + _.count, p.start + p.count));
28910
- for (let O = A, M = C; O < M; O += 3) {
28911
- const z = O, R = O + 1, I = O + 2;
28912
- i = _a(this, S, t, r, c, h, f, z, R, I), i && (i.faceIndex = Math.floor(O / 3), i.face.materialIndex = _.materialIndex, e.push(i));
28913
+ const _ = g[m], S = o[_.materialIndex], A = Math.max(_.start, p.start), T = Math.min(l.count, Math.min(_.start + _.count, p.start + p.count));
28914
+ for (let C = A, M = T; C < M; C += 3) {
28915
+ const O = C, R = C + 1, I = C + 2;
28916
+ i = _a(this, S, t, r, c, h, f, O, R, I), i && (i.faceIndex = Math.floor(C / 3), i.face.materialIndex = _.materialIndex, e.push(i));
28913
28917
  }
28914
28918
  }
28915
28919
  else {
28916
28920
  const m = Math.max(0, p.start), v = Math.min(l.count, p.start + p.count);
28917
28921
  for (let _ = m, S = v; _ < S; _ += 3) {
28918
- const A = _, C = _ + 1, O = _ + 2;
28919
- i = _a(this, o, t, r, c, h, f, A, C, O), i && (i.faceIndex = Math.floor(_ / 3), e.push(i));
28922
+ const A = _, T = _ + 1, C = _ + 2;
28923
+ i = _a(this, o, t, r, c, h, f, A, T, C), i && (i.faceIndex = Math.floor(_ / 3), e.push(i));
28920
28924
  }
28921
28925
  }
28922
28926
  }
@@ -28974,15 +28978,15 @@ class Ja extends ui {
28974
28978
  const l = [], c = [], h = [], f = [];
28975
28979
  let g = 0, p = 0;
28976
28980
  m("z", "y", "x", -1, -1, r, e, t, o, s, 0), m("z", "y", "x", 1, -1, r, e, -t, o, s, 1), m("x", "z", "y", 1, 1, t, r, e, i, o, 2), m("x", "z", "y", 1, -1, t, r, -e, i, o, 3), m("x", "y", "z", 1, -1, t, e, r, i, s, 4), m("x", "y", "z", -1, -1, t, e, -r, i, s, 5), this.setIndex(l), this.setAttribute("position", new bn(c, 3)), this.setAttribute("normal", new bn(h, 3)), this.setAttribute("uv", new bn(f, 2));
28977
- function m(v, _, S, A, C, O, M, z, R, I, L) {
28978
- const U = O / R, Y = M / I, it = O / 2, rt = M / 2, yt = z / 2, mt = R + 1, dt = I + 1;
28981
+ function m(v, _, S, A, T, C, M, O, R, I, L) {
28982
+ const U = C / R, Y = M / I, it = C / 2, rt = M / 2, yt = O / 2, mt = R + 1, dt = I + 1;
28979
28983
  let ot = 0, G = 0;
28980
28984
  const pt = new V();
28981
28985
  for (let k = 0; k < dt; k++) {
28982
28986
  const F = k * Y - rt;
28983
28987
  for (let K = 0; K < mt; K++) {
28984
28988
  const J = K * U - it;
28985
- pt[v] = J * A, pt[_] = F * C, pt[S] = yt, c.push(pt.x, pt.y, pt.z), pt[v] = 0, pt[_] = 0, pt[S] = z > 0 ? 1 : -1, h.push(pt.x, pt.y, pt.z), f.push(K / R), f.push(1 - k / I), ot += 1;
28989
+ pt[v] = J * A, pt[_] = F * T, pt[S] = yt, c.push(pt.x, pt.y, pt.z), pt[v] = 0, pt[_] = 0, pt[S] = O > 0 ? 1 : -1, h.push(pt.x, pt.y, pt.z), f.push(K / R), f.push(1 - k / I), ot += 1;
28986
28990
  }
28987
28991
  }
28988
28992
  for (let k = 0; k < I; k++)
@@ -30148,18 +30152,18 @@ function nM(n, t, e, r) {
30148
30152
  const i = n.prev, s = n, o = n.next;
30149
30153
  if (te(i, s, o) >= 0) return !1;
30150
30154
  const a = i.x, l = s.x, c = o.x, h = i.y, f = s.y, g = o.y, p = Math.min(a, l, c), m = Math.min(h, f, g), v = Math.max(a, l, c), _ = Math.max(h, f, g), S = Lc(p, m, t, e, r), A = Lc(v, _, t, e, r);
30151
- let C = n.prevZ, O = n.nextZ;
30152
- for (; C && C.z >= S && O && O.z <= A; ) {
30153
- if (C.x >= p && C.x <= v && C.y >= m && C.y <= _ && C !== i && C !== o && Qs(a, h, l, f, c, g, C.x, C.y) && te(C.prev, C, C.next) >= 0 || (C = C.prevZ, O.x >= p && O.x <= v && O.y >= m && O.y <= _ && O !== i && O !== o && Qs(a, h, l, f, c, g, O.x, O.y) && te(O.prev, O, O.next) >= 0)) return !1;
30154
- O = O.nextZ;
30155
+ let T = n.prevZ, C = n.nextZ;
30156
+ for (; T && T.z >= S && C && C.z <= A; ) {
30157
+ if (T.x >= p && T.x <= v && T.y >= m && T.y <= _ && T !== i && T !== o && Qs(a, h, l, f, c, g, T.x, T.y) && te(T.prev, T, T.next) >= 0 || (T = T.prevZ, C.x >= p && C.x <= v && C.y >= m && C.y <= _ && C !== i && C !== o && Qs(a, h, l, f, c, g, C.x, C.y) && te(C.prev, C, C.next) >= 0)) return !1;
30158
+ C = C.nextZ;
30155
30159
  }
30156
- for (; C && C.z >= S; ) {
30157
- if (C.x >= p && C.x <= v && C.y >= m && C.y <= _ && C !== i && C !== o && Qs(a, h, l, f, c, g, C.x, C.y) && te(C.prev, C, C.next) >= 0) return !1;
30158
- C = C.prevZ;
30160
+ for (; T && T.z >= S; ) {
30161
+ if (T.x >= p && T.x <= v && T.y >= m && T.y <= _ && T !== i && T !== o && Qs(a, h, l, f, c, g, T.x, T.y) && te(T.prev, T, T.next) >= 0) return !1;
30162
+ T = T.prevZ;
30159
30163
  }
30160
- for (; O && O.z <= A; ) {
30161
- if (O.x >= p && O.x <= v && O.y >= m && O.y <= _ && O !== i && O !== o && Qs(a, h, l, f, c, g, O.x, O.y) && te(O.prev, O, O.next) >= 0) return !1;
30162
- O = O.nextZ;
30164
+ for (; C && C.z <= A; ) {
30165
+ if (C.x >= p && C.x <= v && C.y >= m && C.y <= _ && C !== i && C !== o && Qs(a, h, l, f, c, g, C.x, C.y) && te(C.prev, C, C.next) >= 0) return !1;
30166
+ C = C.nextZ;
30163
30167
  }
30164
30168
  return !0;
30165
30169
  }
@@ -30466,8 +30470,8 @@ class jh extends ui {
30466
30470
  i.push(A.x, A.y, 0), s.push(0, 0, 1), o.push(A.x, A.y);
30467
30471
  }
30468
30472
  for (let _ = 0, S = v.length; _ < S; _++) {
30469
- const A = v[_], C = A[0] + f, O = A[1] + f, M = A[2] + f;
30470
- r.push(C, O, M), l += 3;
30473
+ const A = v[_], T = A[0] + f, C = A[1] + f, M = A[2] + f;
30474
+ r.push(T, C, M), l += 3;
30471
30475
  }
30472
30476
  }
30473
30477
  }
@@ -30805,7 +30809,7 @@ class Ky extends Vh {
30805
30809
  * @return {Texture} The texture.
30806
30810
  */
30807
30811
  load(t, e, r, i) {
30808
- const s = new Fn(), o = new SM(this.manager);
30812
+ const s = new jn(), o = new SM(this.manager);
30809
30813
  return o.setCrossOrigin(this.crossOrigin), o.setPath(this.path), o.load(t, function(a) {
30810
30814
  s.image = a, s.needsUpdate = !0, e !== void 0 && e(s);
30811
30815
  }, r, i), s;
@@ -30815,7 +30819,7 @@ typeof __THREE_DEVTOOLS__ < "u" && __THREE_DEVTOOLS__.dispatchEvent(new CustomEv
30815
30819
  revision: Fy
30816
30820
  } }));
30817
30821
  typeof window < "u" && (window.__THREE__ ? console.warn("WARNING: Multiple instances of Three.js being imported.") : window.__THREE__ = Fy);
30818
- class AE {
30822
+ class OE {
30819
30823
  constructor(t = Qr) {
30820
30824
  kt(this, "elements");
30821
30825
  kt(this, "categories");
@@ -30945,7 +30949,7 @@ const EM = ({
30945
30949
  onSearch: o,
30946
30950
  className: a
30947
30951
  }) => {
30948
- const [l, c] = re("");
30952
+ const [l, c] = ee("");
30949
30953
  return /* @__PURE__ */ w.jsxs(
30950
30954
  "div",
30951
30955
  {
@@ -31037,68 +31041,69 @@ const EM = ({
31037
31041
  ] });
31038
31042
  }, OM = ({ catalog: n, popupEvent: t, onClose: e }) => {
31039
31043
  const {
31040
- selectToolDrawingLine: r,
31041
- selectToolDrawingItem: i,
31042
- selectToolDrawingHole: s,
31043
- pushLastSelectedCatalogElementToHistory: o
31044
- } = Zt(), [a, l] = re([]), [c, h] = re(["all"]), [f, g] = re([]), [p, m] = re(""), v = jn(null), _ = jn(null);
31045
- Vn(() => {
31044
+ setToast: r,
31045
+ selectToolDrawingLine: i,
31046
+ selectToolDrawingItem: s,
31047
+ selectToolDrawingHole: o,
31048
+ pushLastSelectedCatalogElementToHistory: a
31049
+ } = Yt(), [l, c] = ee([]), [h, f] = ee(["all"]), [g, p] = ee([]), [m, v] = ee(""), _ = Vn(null), S = Vn(null);
31050
+ wn(() => {
31046
31051
  if (t) {
31047
- const M = n.getCategory(t.page).elements.filter(
31048
- (I) => I.info.visibility ? I.info.visibility.catalog : !0
31052
+ const O = n.getCategory(t.page).elements.filter(
31053
+ (L) => L.info.visibility ? L.info.visibility.catalog : !0
31049
31054
  );
31050
- v.current = t.page, g(M);
31051
- const { x: z, y: R } = t.rect;
31052
- _.current = {
31053
- top: R + cg,
31054
- left: z + hg
31055
- }, t.page === "objects" && l(AM(M));
31055
+ _.current = t.page, p(O);
31056
+ const { x: R, y: I } = t.rect;
31057
+ S.current = {
31058
+ top: I + cg,
31059
+ left: R + hg
31060
+ }, t.page === "objects" && c(AM(O));
31056
31061
  }
31057
31062
  }, [t]);
31058
- const S = () => {
31063
+ const A = () => {
31059
31064
  e();
31060
- }, A = (O) => {
31061
- S(), setTimeout(() => {
31062
- switch (O.prototype) {
31065
+ }, T = (M) => {
31066
+ A(), t && r({ text: `Cancel placing ${t.page}` }), setTimeout(() => {
31067
+ switch (M.prototype) {
31063
31068
  case "lines":
31064
- r(O.name);
31069
+ i(M.name);
31065
31070
  break;
31066
31071
  case "items":
31067
- i(O.name);
31072
+ s(M.name);
31068
31073
  break;
31069
31074
  case "holes":
31070
- s(O.name);
31075
+ o(M.name);
31071
31076
  break;
31072
31077
  }
31073
- o(O);
31078
+ a(M);
31074
31079
  }, 0);
31075
- }, C = (O, M) => {
31076
- const z = [...c.slice(0, O), M];
31077
- h(z);
31080
+ }, C = (M, O) => {
31081
+ const R = [...h.slice(0, M), O];
31082
+ f(R);
31078
31083
  };
31079
31084
  return /* @__PURE__ */ w.jsxs(w.Fragment, { children: [
31080
- t && /* @__PURE__ */ w.jsx("div", { className: "fixed inset-0 bg-black/30 z-10", onClick: S }),
31085
+ t && /* @__PURE__ */ w.jsx("div", { className: "fixed inset-0 bg-black/30 z-10", onClick: A }),
31081
31086
  /* @__PURE__ */ w.jsxs(
31082
31087
  "div",
31083
31088
  {
31084
31089
  style: t && t.rect ? {
31085
31090
  top: t.rect.y + cg,
31086
31091
  left: t.rect.x + hg
31087
- } : _.current ? _.current : {},
31092
+ } : S.current ? S.current : {},
31088
31093
  className: Cr(
31089
31094
  "fixed select-none z-10 shadow-md !gap-0 rounded-lg pt-5 fp_side-bar !min-h-[250px] !max-h-[510px] transition-all duration-200 ease-out transform",
31090
31095
  t ? "opacity-100 scale-100" : "opacity-0 scale-95 pointer-events-none"
31091
31096
  ),
31092
31097
  children: [
31093
31098
  /* @__PURE__ */ w.jsxs("header", { className: "px-[18px] sticky top-0 left-0 gap-3 flex flex-col", children: [
31094
- /* @__PURE__ */ w.jsx("div", { className: "flex items-center gap-1", children: /* @__PURE__ */ w.jsx("span", { className: Cr("flex flex-col gap-0.5"), children: /* @__PURE__ */ w.jsx("span", { className: "fp-sidebar-label capitalize", children: (t == null ? void 0 : t.page) ?? v.current }) }) }),
31099
+ /* @__PURE__ */ w.jsx("div", { className: "flex items-center gap-1", children: /* @__PURE__ */ w.jsx("span", { className: Cr("flex flex-col gap-0.5"), children: /* @__PURE__ */ w.jsx("span", { className: "fp-sidebar-label capitalize", children: (t == null ? void 0 : t.page) ?? _.current }) }) }),
31095
31100
  /* @__PURE__ */ w.jsxs("div", { className: Cr("fp-highlight"), children: [
31096
31101
  /* @__PURE__ */ w.jsx(
31097
31102
  Qy,
31098
31103
  {
31099
- options: a,
31104
+ options: l,
31100
31105
  level: 0,
31101
- selections: c,
31106
+ selections: h,
31102
31107
  onChange: C
31103
31108
  }
31104
31109
  ),
@@ -31107,27 +31112,27 @@ const EM = ({
31107
31112
  {
31108
31113
  className: "mt-0",
31109
31114
  placeholder: "Search",
31110
- onSearch: (O, M) => {
31111
- M.preventDefault(), M.stopPropagation(), m(O);
31115
+ onSearch: (M, O) => {
31116
+ O.preventDefault(), O.stopPropagation(), v(M);
31112
31117
  }
31113
31118
  }
31114
31119
  )
31115
31120
  ] })
31116
31121
  ] }),
31117
- f.filter(
31118
- (O) => O.info.title.toLowerCase().includes(p.toLowerCase()) && c.every(
31119
- (M) => M === "all" || O.info.tag.includes(M)
31122
+ g.filter(
31123
+ (M) => M.info.title.toLowerCase().includes(m.toLowerCase()) && h.every(
31124
+ (O) => O === "all" || M.info.tag.includes(O)
31120
31125
  )
31121
31126
  ).length > 0 ? /* @__PURE__ */ w.jsx(
31122
31127
  "div",
31123
31128
  {
31124
31129
  className: "grid grid-cols-2 gap-x-4 gap-y-6 pb-5 overflow-auto w-full pt-[18px] px-4",
31125
- onWheel: (O) => O.stopPropagation(),
31126
- children: f.filter(
31127
- (O) => O.info.title.toLowerCase().includes(p.toLowerCase()) && c.every(
31128
- (M) => M === "all" || O.info.tag.includes(M)
31130
+ onWheel: (M) => M.stopPropagation(),
31131
+ children: g.filter(
31132
+ (M) => M.info.title.toLowerCase().includes(m.toLowerCase()) && h.every(
31133
+ (O) => O === "all" || M.info.tag.includes(O)
31129
31134
  )
31130
- ).map((O) => /* @__PURE__ */ w.jsxs(
31135
+ ).map((M) => /* @__PURE__ */ w.jsxs(
31131
31136
  "div",
31132
31137
  {
31133
31138
  className: "w-full space-y-1.5",
@@ -31136,22 +31141,22 @@ const EM = ({
31136
31141
  "div",
31137
31142
  {
31138
31143
  className: "fp-aspect-ratio-content",
31139
- onMouseDown: () => A(O),
31144
+ onMouseDown: () => T(M),
31140
31145
  children: /* @__PURE__ */ w.jsx(
31141
31146
  "img",
31142
31147
  {
31143
31148
  draggable: !1,
31144
31149
  className: "fp-item-image",
31145
- alt: O.info.title,
31146
- src: O.info.image
31150
+ alt: M.info.title,
31151
+ src: M.info.image
31147
31152
  }
31148
31153
  )
31149
31154
  }
31150
31155
  ) }),
31151
- /* @__PURE__ */ w.jsx("p", { className: "text-xs font-semibold capitalize", children: O.info.description })
31156
+ /* @__PURE__ */ w.jsx("p", { className: "text-xs font-semibold capitalize", children: M.info.description })
31152
31157
  ]
31153
31158
  },
31154
- O.name.replace(/\s+/g, "_")
31159
+ M.name.replace(/\s+/g, "_")
31155
31160
  ))
31156
31161
  }
31157
31162
  ) : /* @__PURE__ */ w.jsx("div", { className: "min-h-28 w-full flex items-center justify-center", children: /* @__PURE__ */ w.jsx("p", { className: "text-sm font-medium text-gray-400 text-center", children: "No records found" }) })
@@ -31171,28 +31176,31 @@ function CM({ catalog: n }) {
31171
31176
  planner: t,
31172
31177
  selectTool3DView: e,
31173
31178
  setMode: r,
31174
- selectTool3DFirstPerson: i,
31175
- selectToolDrawingLine: s
31176
- } = Zt(), { mode: o, alterate: a } = t, [l, c] = re(null);
31179
+ setToast: i,
31180
+ selectTool3DFirstPerson: s,
31181
+ selectToolDrawingLine: o
31182
+ } = Yt(), { mode: a, alterate: l } = t, [c, h] = ee(null);
31177
31183
  return /* @__PURE__ */ w.jsxs(w.Fragment, { children: [
31178
31184
  /* @__PURE__ */ w.jsxs("aside", { className: "floor_planner-toolbar max-h-full max-w-[50px] p-2.5 space-y-4 bg-[#2b2b2b]", children: [
31179
31185
  /* @__PURE__ */ w.jsx(
31180
31186
  vn,
31181
31187
  {
31182
- active: [kr, Ze].includes(o),
31188
+ active: [kr, Ze].includes(a),
31183
31189
  tooltip: "Draw wall",
31184
- onClick: () => s("wall"),
31190
+ onClick: () => {
31191
+ i({ text: "Cancel drawing" }), o("wall");
31192
+ },
31185
31193
  children: /* @__PURE__ */ w.jsx(s2, {})
31186
31194
  }
31187
31195
  ),
31188
31196
  /* @__PURE__ */ w.jsx(
31189
31197
  vn,
31190
31198
  {
31191
- active: !!([Ke].includes(o) && l && l.page === "windows"),
31199
+ active: !!([Ke].includes(a) && c && c.page === "windows"),
31192
31200
  tooltip: "Place windows",
31193
- onClick: (h) => {
31194
- c({
31195
- rect: h.currentTarget.getBoundingClientRect(),
31201
+ onClick: (f) => {
31202
+ h({
31203
+ rect: f.currentTarget.getBoundingClientRect(),
31196
31204
  page: "windows"
31197
31205
  });
31198
31206
  },
@@ -31202,11 +31210,11 @@ function CM({ catalog: n }) {
31202
31210
  /* @__PURE__ */ w.jsx(
31203
31211
  vn,
31204
31212
  {
31205
- active: !!([Ke].includes(o) && l && l.page === "doors"),
31213
+ active: !!([Ke].includes(a) && c && c.page === "doors"),
31206
31214
  tooltip: "Place doors",
31207
- onClick: (h) => {
31208
- c({
31209
- rect: h.currentTarget.getBoundingClientRect(),
31215
+ onClick: (f) => {
31216
+ h({
31217
+ rect: f.currentTarget.getBoundingClientRect(),
31210
31218
  page: "doors"
31211
31219
  });
31212
31220
  },
@@ -31216,25 +31224,25 @@ function CM({ catalog: n }) {
31216
31224
  /* @__PURE__ */ w.jsx(
31217
31225
  vn,
31218
31226
  {
31219
- active: !!([fr].includes(o) && l && l.page === "objects"),
31227
+ active: !!([fr].includes(a) && c && c.page === "objects"),
31220
31228
  tooltip: "Place objects",
31221
- onClick: (h) => {
31222
- c({
31223
- rect: h.currentTarget.getBoundingClientRect(),
31229
+ onClick: (f) => {
31230
+ h({
31231
+ rect: f.currentTarget.getBoundingClientRect(),
31224
31232
  page: "objects"
31225
31233
  });
31226
31234
  },
31227
31235
  children: /* @__PURE__ */ w.jsx(TM, { size: 26 })
31228
31236
  }
31229
31237
  ),
31230
- /* @__PURE__ */ w.jsx(i2, { mode: o })
31238
+ /* @__PURE__ */ w.jsx(i2, { mode: a })
31231
31239
  ] }),
31232
31240
  /* @__PURE__ */ w.jsx(
31233
31241
  OM,
31234
31242
  {
31235
31243
  catalog: n,
31236
- popupEvent: l,
31237
- onClose: () => c(null)
31244
+ popupEvent: c,
31245
+ onClose: () => h(null)
31238
31246
  }
31239
31247
  )
31240
31248
  ] });
@@ -31253,7 +31261,7 @@ function IM(n, t) {
31253
31261
  const o = Us.getItem(n);
31254
31262
  s = JSON.parse(o);
31255
31263
  }
31256
- s && e.loadProject(s), Zt.subscribe((o) => {
31264
+ s && e.loadProject(s), Yt.subscribe((o) => {
31257
31265
  Xl && clearTimeout(Xl), Xl = setTimeout(() => {
31258
31266
  const a = Us.getItem(n), l = JSON.stringify(o.planner.scene.toJS());
31259
31267
  if (a !== l && (Us.setItem(n, l), o.plan))
@@ -31382,7 +31390,7 @@ function PM() {
31382
31390
  };
31383
31391
  }
31384
31392
  const RM = ({ onBack: n, onSave: t }) => {
31385
- const { undo: e, redo: r, plan: i, setPlan: s } = Zt(), [o, a] = re(!1), l = () => {
31393
+ const { undo: e, redo: r, plan: i, setPlan: s } = Yt(), [o, a] = ee(!1), l = () => {
31386
31394
  a(!0);
31387
31395
  }, c = (h) => {
31388
31396
  if (!i) return;
@@ -31726,13 +31734,13 @@ function $M() {
31726
31734
  function a(h, f, g) {
31727
31735
  g || (g = f, f = h, h = null), h = h || {}, h.debug;
31728
31736
  function p(m, v) {
31729
- var _ = o(["display: block", "position: absolute", "top: 0", "left: 0", "width: 100%", "height: 100%", "border: none", "padding: 0", "margin: 0", "opacity: 0", "z-index: -1000", "pointer-events: none"]), S = !1, A = window.getComputedStyle(m), C = m.offsetWidth, O = m.offsetHeight;
31737
+ var _ = o(["display: block", "position: absolute", "top: 0", "left: 0", "width: 100%", "height: 100%", "border: none", "padding: 0", "margin: 0", "opacity: 0", "z-index: -1000", "pointer-events: none"]), S = !1, A = window.getComputedStyle(m), T = m.offsetWidth, C = m.offsetHeight;
31730
31738
  i(m).startSize = {
31731
- width: C,
31732
- height: O
31739
+ width: T,
31740
+ height: C
31733
31741
  };
31734
31742
  function M() {
31735
- function z() {
31743
+ function O() {
31736
31744
  if (A.position === "static") {
31737
31745
  m.style.setProperty("position", "relative", h.important ? "important" : "");
31738
31746
  var L = function(U, Y, it, rt) {
@@ -31746,7 +31754,7 @@ function $M() {
31746
31754
  }
31747
31755
  }
31748
31756
  function R() {
31749
- S || z();
31757
+ S || O();
31750
31758
  function L(Y, it) {
31751
31759
  if (!Y.contentDocument) {
31752
31760
  var rt = i(Y);
@@ -31762,7 +31770,7 @@ function $M() {
31762
31770
  v(m);
31763
31771
  });
31764
31772
  }
31765
- A.position !== "" && (z(), S = !0);
31773
+ A.position !== "" && (O(), S = !0);
31766
31774
  var I = document.createElement("object");
31767
31775
  I.style.cssText = _, I.tabIndex = -1, I.type = "text/html", I.setAttribute("aria-hidden", "true"), I.onload = R, n.isIE() || (I.data = "about:blank"), i(m) && (m.appendChild(I), i(m).object = I, n.isIE() && (I.data = "about:blank"));
31768
31776
  }
@@ -31806,29 +31814,29 @@ function HM() {
31806
31814
  }
31807
31815
  c(window.document);
31808
31816
  function h(M) {
31809
- var z = t.important ? " !important; " : "; ";
31810
- return (M.join(z) + z).trim();
31817
+ var O = t.important ? " !important; " : "; ";
31818
+ return (M.join(O) + O).trim();
31811
31819
  }
31812
31820
  function f() {
31813
- var M = 500, z = 500, R = document.createElement("div");
31814
- R.style.cssText = h(["position: absolute", "width: " + M * 2 + "px", "height: " + z * 2 + "px", "visibility: hidden", "margin: 0", "padding: 0"]);
31821
+ var M = 500, O = 500, R = document.createElement("div");
31822
+ R.style.cssText = h(["position: absolute", "width: " + M * 2 + "px", "height: " + O * 2 + "px", "visibility: hidden", "margin: 0", "padding: 0"]);
31815
31823
  var I = document.createElement("div");
31816
- I.style.cssText = h(["position: absolute", "width: " + M + "px", "height: " + z + "px", "overflow: scroll", "visibility: none", "top: " + -M * 3 + "px", "left: " + -z * 3 + "px", "visibility: hidden", "margin: 0", "padding: 0"]), I.appendChild(R), document.body.insertBefore(I, document.body.firstChild);
31817
- var L = M - I.clientWidth, U = z - I.clientHeight;
31824
+ I.style.cssText = h(["position: absolute", "width: " + M + "px", "height: " + O + "px", "overflow: scroll", "visibility: none", "top: " + -M * 3 + "px", "left: " + -O * 3 + "px", "visibility: hidden", "margin: 0", "padding: 0"]), I.appendChild(R), document.body.insertBefore(I, document.body.firstChild);
31825
+ var L = M - I.clientWidth, U = O - I.clientHeight;
31818
31826
  return document.body.removeChild(I), {
31819
31827
  width: L,
31820
31828
  height: U
31821
31829
  };
31822
31830
  }
31823
- function g(M, z, R) {
31831
+ function g(M, O, R) {
31824
31832
  function I(it, rt) {
31825
31833
  rt = rt || function(mt) {
31826
31834
  M.head.appendChild(mt);
31827
31835
  };
31828
31836
  var yt = M.createElement("style");
31829
- return yt.innerHTML = it, yt.id = z, rt(yt), yt;
31837
+ return yt.innerHTML = it, yt.id = O, rt(yt), yt;
31830
31838
  }
31831
- if (!M.getElementById(z)) {
31839
+ if (!M.getElementById(O)) {
31832
31840
  var L = R + "_animation", U = R + "_animation_active", Y = `/* Created by the element-resize-detector library. */
31833
31841
  `;
31834
31842
  Y += "." + R + " > div::-webkit-scrollbar { " + h(["display: none"]) + ` }
@@ -31841,19 +31849,19 @@ function HM() {
31841
31849
  function p(M) {
31842
31850
  M.className += " " + l + "_animation_active";
31843
31851
  }
31844
- function m(M, z, R) {
31852
+ function m(M, O, R) {
31845
31853
  if (M.addEventListener)
31846
- M.addEventListener(z, R);
31854
+ M.addEventListener(O, R);
31847
31855
  else if (M.attachEvent)
31848
- M.attachEvent("on" + z, R);
31856
+ M.attachEvent("on" + O, R);
31849
31857
  else
31850
31858
  return e.error("[scroll] Don't know how to add event listeners.");
31851
31859
  }
31852
- function v(M, z, R) {
31860
+ function v(M, O, R) {
31853
31861
  if (M.removeEventListener)
31854
- M.removeEventListener(z, R);
31862
+ M.removeEventListener(O, R);
31855
31863
  else if (M.detachEvent)
31856
- M.detachEvent("on" + z, R);
31864
+ M.detachEvent("on" + O, R);
31857
31865
  else
31858
31866
  return e.error("[scroll] Don't know how to remove event listeners.");
31859
31867
  }
@@ -31863,18 +31871,18 @@ function HM() {
31863
31871
  function S(M) {
31864
31872
  return i(M).container.childNodes[0].childNodes[0].childNodes[1];
31865
31873
  }
31866
- function A(M, z) {
31874
+ function A(M, O) {
31867
31875
  var R = i(M).listeners;
31868
31876
  if (!R.push)
31869
31877
  throw new Error("Cannot add listener to an element that is not detectable.");
31870
- i(M).listeners.push(z);
31878
+ i(M).listeners.push(O);
31871
31879
  }
31872
- function C(M, z, R) {
31873
- R || (R = z, z = M, M = null), M = M || {};
31880
+ function T(M, O, R) {
31881
+ R || (R = O, O = M, M = null), M = M || {};
31874
31882
  function I() {
31875
31883
  if (M.debug) {
31876
31884
  var D = Array.prototype.slice.call(arguments);
31877
- if (D.unshift(s.get(z), "Scroll: "), e.log.apply)
31885
+ if (D.unshift(s.get(O), "Scroll: "), e.log.apply)
31878
31886
  e.log.apply(null, D);
31879
31887
  else
31880
31888
  for (var ct = 0; ct < D.length; ct++)
@@ -31893,26 +31901,26 @@ function HM() {
31893
31901
  return !$.width || $.width.indexOf("px") === -1;
31894
31902
  }
31895
31903
  function Y() {
31896
- var D = window.getComputedStyle(z), ct = {};
31897
- return ct.position = D.position, ct.width = z.offsetWidth, ct.height = z.offsetHeight, ct.top = D.top, ct.right = D.right, ct.bottom = D.bottom, ct.left = D.left, ct.widthCSS = D.width, ct.heightCSS = D.height, ct;
31904
+ var D = window.getComputedStyle(O), ct = {};
31905
+ return ct.position = D.position, ct.width = O.offsetWidth, ct.height = O.offsetHeight, ct.top = D.top, ct.right = D.right, ct.bottom = D.bottom, ct.left = D.left, ct.widthCSS = D.width, ct.heightCSS = D.height, ct;
31898
31906
  }
31899
31907
  function it() {
31900
31908
  var D = Y();
31901
- i(z).startSize = {
31909
+ i(O).startSize = {
31902
31910
  width: D.width,
31903
31911
  height: D.height
31904
- }, I("Element start size", i(z).startSize);
31912
+ }, I("Element start size", i(O).startSize);
31905
31913
  }
31906
31914
  function rt() {
31907
- i(z).listeners = [];
31915
+ i(O).listeners = [];
31908
31916
  }
31909
31917
  function yt() {
31910
- if (I("storeStyle invoked."), !i(z)) {
31918
+ if (I("storeStyle invoked."), !i(O)) {
31911
31919
  I("Aborting because element has been uninstalled");
31912
31920
  return;
31913
31921
  }
31914
31922
  var D = Y();
31915
- i(z).style = D;
31923
+ i(O).style = D;
31916
31924
  }
31917
31925
  function mt(D, ct, $) {
31918
31926
  i(D).lastWidth = ct, i(D).lastHeight = $;
@@ -31943,52 +31951,52 @@ function HM() {
31943
31951
  _t.scrollLeft = Pt, _t.scrollTop = Ot, Ft.scrollLeft = Vt, Ft.scrollTop = ft;
31944
31952
  }
31945
31953
  function et() {
31946
- var D = i(z).container;
31954
+ var D = i(O).container;
31947
31955
  if (!D) {
31948
- D = document.createElement("div"), D.className = l, D.style.cssText = h(["visibility: hidden", "display: inline", "width: 0px", "height: 0px", "z-index: -1", "overflow: hidden", "margin: 0", "padding: 0"]), i(z).container = D, p(D), z.appendChild(D);
31956
+ D = document.createElement("div"), D.className = l, D.style.cssText = h(["visibility: hidden", "display: inline", "width: 0px", "height: 0px", "z-index: -1", "overflow: hidden", "margin: 0", "padding: 0"]), i(O).container = D, p(D), O.appendChild(D);
31949
31957
  var ct = function() {
31950
- i(z).onRendered && i(z).onRendered();
31958
+ i(O).onRendered && i(O).onRendered();
31951
31959
  };
31952
- m(D, "animationstart", ct), i(z).onAnimationStart = ct;
31960
+ m(D, "animationstart", ct), i(O).onAnimationStart = ct;
31953
31961
  }
31954
31962
  return D;
31955
31963
  }
31956
31964
  function W() {
31957
31965
  function D() {
31958
- var ne = i(z).style;
31966
+ var ne = i(O).style;
31959
31967
  if (ne.position === "static") {
31960
- z.style.setProperty("position", "relative", M.important ? "important" : "");
31968
+ O.style.setProperty("position", "relative", M.important ? "important" : "");
31961
31969
  var ir = function(Dr, vr, As, Yn) {
31962
- function ee(ye) {
31970
+ function re(ye) {
31963
31971
  return ye.replace(/[^-\d\.]/g, "");
31964
31972
  }
31965
31973
  var Xn = As[Yn];
31966
- Xn !== "auto" && ee(Xn) !== "0" && (Dr.warn("An element that is positioned static has style." + Yn + "=" + Xn + " which is ignored due to the static positioning. The element will need to be positioned relative, so the style." + Yn + " will be set to 0. Element: ", vr), vr.style[Yn] = 0);
31974
+ Xn !== "auto" && re(Xn) !== "0" && (Dr.warn("An element that is positioned static has style." + Yn + "=" + Xn + " which is ignored due to the static positioning. The element will need to be positioned relative, so the style." + Yn + " will be set to 0. Element: ", vr), vr.style[Yn] = 0);
31967
31975
  };
31968
- ir(e, z, ne, "top"), ir(e, z, ne, "right"), ir(e, z, ne, "bottom"), ir(e, z, ne, "left");
31976
+ ir(e, O, ne, "top"), ir(e, O, ne, "right"), ir(e, O, ne, "bottom"), ir(e, O, ne, "left");
31969
31977
  }
31970
31978
  }
31971
31979
  function ct(ne, ir, Dr, vr) {
31972
31980
  return ne = ne ? ne + "px" : "0", ir = ir ? ir + "px" : "0", Dr = Dr ? Dr + "px" : "0", vr = vr ? vr + "px" : "0", ["left: " + ne, "top: " + ir, "right: " + vr, "bottom: " + Dr];
31973
31981
  }
31974
- if (I("Injecting elements"), !i(z)) {
31982
+ if (I("Injecting elements"), !i(O)) {
31975
31983
  I("Aborting because element has been uninstalled");
31976
31984
  return;
31977
31985
  }
31978
31986
  D();
31979
- var $ = i(z).container;
31987
+ var $ = i(O).container;
31980
31988
  $ || ($ = et());
31981
31989
  var _t = o.width, Ft = o.height, Pt = h(["position: absolute", "flex: none", "overflow: hidden", "z-index: -1", "visibility: hidden", "width: 100%", "height: 100%", "left: 0px", "top: 0px"]), Ot = h(["position: absolute", "flex: none", "overflow: hidden", "z-index: -1", "visibility: hidden"].concat(ct(-(1 + _t), -(1 + Ft), -Ft, -_t))), Vt = h(["position: absolute", "flex: none", "overflow: scroll", "z-index: -1", "visibility: hidden", "width: 100%", "height: 100%"]), ft = h(["position: absolute", "flex: none", "overflow: scroll", "z-index: -1", "visibility: hidden", "width: 100%", "height: 100%"]), vt = h(["position: absolute", "left: 0", "top: 0"]), Rt = h(["position: absolute", "width: 200%", "height: 200%"]), wt = document.createElement("div"), qe = document.createElement("div"), un = document.createElement("div"), Wn = document.createElement("div"), Un = document.createElement("div"), yi = document.createElement("div");
31982
31990
  wt.dir = "ltr", wt.style.cssText = Pt, wt.className = l, qe.className = l, qe.style.cssText = Ot, un.style.cssText = Vt, Wn.style.cssText = vt, Un.style.cssText = ft, yi.style.cssText = Rt, un.appendChild(Wn), Un.appendChild(yi), qe.appendChild(un), qe.appendChild(Un), wt.appendChild(qe), $.appendChild(wt);
31983
31991
  function ko() {
31984
- var ne = i(z);
31992
+ var ne = i(O);
31985
31993
  ne && ne.onExpand ? ne.onExpand() : I("Aborting expand scroll handler: element has been uninstalled");
31986
31994
  }
31987
31995
  function Es() {
31988
- var ne = i(z);
31996
+ var ne = i(O);
31989
31997
  ne && ne.onShrink ? ne.onShrink() : I("Aborting shrink scroll handler: element has been uninstalled");
31990
31998
  }
31991
- m(un, "scroll", ko), m(Un, "scroll", Es), i(z).onExpandScroll = ko, i(z).onShrinkScroll = Es;
31999
+ m(un, "scroll", ko), m(Un, "scroll", Es), i(O).onExpandScroll = ko, i(O).onShrinkScroll = Es;
31992
32000
  }
31993
32001
  function Q() {
31994
32002
  function D(Vt, ft, vt) {
@@ -31996,10 +32004,10 @@ function HM() {
31996
32004
  Rt.style.setProperty("width", wt + "px", M.important ? "important" : ""), Rt.style.setProperty("height", qe + "px", M.important ? "important" : "");
31997
32005
  }
31998
32006
  function ct(Vt) {
31999
- var ft = z.offsetWidth, vt = z.offsetHeight, Rt = ft !== i(z).lastWidth || vt !== i(z).lastHeight;
32000
- I("Storing current size", ft, vt), mt(z, ft, vt), r.add(0, function() {
32007
+ var ft = O.offsetWidth, vt = O.offsetHeight, Rt = ft !== i(O).lastWidth || vt !== i(O).lastHeight;
32008
+ I("Storing current size", ft, vt), mt(O, ft, vt), r.add(0, function() {
32001
32009
  if (Rt) {
32002
- if (!i(z)) {
32010
+ if (!i(O)) {
32003
32011
  I("Aborting because element has been uninstalled");
32004
32012
  return;
32005
32013
  }
@@ -32008,13 +32016,13 @@ function HM() {
32008
32016
  return;
32009
32017
  }
32010
32018
  if (M.debug) {
32011
- var qe = z.offsetWidth, un = z.offsetHeight;
32012
- (qe !== ft || un !== vt) && e.warn(s.get(z), "Scroll: Size changed before updating detector elements.");
32019
+ var qe = O.offsetWidth, un = O.offsetHeight;
32020
+ (qe !== ft || un !== vt) && e.warn(s.get(O), "Scroll: Size changed before updating detector elements.");
32013
32021
  }
32014
- D(z, ft, vt);
32022
+ D(O, ft, vt);
32015
32023
  }
32016
32024
  }), r.add(1, function() {
32017
- if (!i(z)) {
32025
+ if (!i(O)) {
32018
32026
  I("Aborting because element has been uninstalled");
32019
32027
  return;
32020
32028
  }
@@ -32022,9 +32030,9 @@ function HM() {
32022
32030
  I("Aborting because element container has not been initialized");
32023
32031
  return;
32024
32032
  }
32025
- J(z, ft, vt);
32033
+ J(O, ft, vt);
32026
32034
  }), Rt && Vt && r.add(2, function() {
32027
- if (!i(z)) {
32035
+ if (!i(O)) {
32028
32036
  I("Aborting because element has been uninstalled");
32029
32037
  return;
32030
32038
  }
@@ -32036,72 +32044,72 @@ function HM() {
32036
32044
  });
32037
32045
  }
32038
32046
  function $() {
32039
- return !!i(z).container;
32047
+ return !!i(O).container;
32040
32048
  }
32041
32049
  function _t() {
32042
32050
  function Vt() {
32043
- return i(z).lastNotifiedWidth === void 0;
32051
+ return i(O).lastNotifiedWidth === void 0;
32044
32052
  }
32045
32053
  I("notifyListenersIfNeeded invoked");
32046
- var ft = i(z);
32054
+ var ft = i(O);
32047
32055
  if (Vt() && ft.lastWidth === ft.startSize.width && ft.lastHeight === ft.startSize.height)
32048
32056
  return I("Not notifying: Size is the same as the start size, and there has been no notification yet.");
32049
32057
  if (ft.lastWidth === ft.lastNotifiedWidth && ft.lastHeight === ft.lastNotifiedHeight)
32050
32058
  return I("Not notifying: Size already notified");
32051
- I("Current size not notified, notifying..."), ft.lastNotifiedWidth = ft.lastWidth, ft.lastNotifiedHeight = ft.lastHeight, n(i(z).listeners, function(vt) {
32052
- vt(z);
32059
+ I("Current size not notified, notifying..."), ft.lastNotifiedWidth = ft.lastWidth, ft.lastNotifiedHeight = ft.lastHeight, n(i(O).listeners, function(vt) {
32060
+ vt(O);
32053
32061
  });
32054
32062
  }
32055
32063
  function Ft() {
32056
- if (I("startanimation triggered."), U(z)) {
32064
+ if (I("startanimation triggered."), U(O)) {
32057
32065
  I("Ignoring since element is still unrendered...");
32058
32066
  return;
32059
32067
  }
32060
32068
  I("Element rendered.");
32061
- var Vt = _(z), ft = S(z);
32069
+ var Vt = _(O), ft = S(O);
32062
32070
  (Vt.scrollLeft === 0 || Vt.scrollTop === 0 || ft.scrollLeft === 0 || ft.scrollTop === 0) && (I("Scrollbars out of sync. Updating detector elements..."), ct(_t));
32063
32071
  }
32064
32072
  function Pt() {
32065
- if (I("Scroll detected."), U(z)) {
32073
+ if (I("Scroll detected."), U(O)) {
32066
32074
  I("Scroll event fired while unrendered. Ignoring...");
32067
32075
  return;
32068
32076
  }
32069
32077
  ct(_t);
32070
32078
  }
32071
- if (I("registerListenersAndPositionElements invoked."), !i(z)) {
32079
+ if (I("registerListenersAndPositionElements invoked."), !i(O)) {
32072
32080
  I("Aborting because element has been uninstalled");
32073
32081
  return;
32074
32082
  }
32075
- i(z).onRendered = Ft, i(z).onExpand = Pt, i(z).onShrink = Pt;
32076
- var Ot = i(z).style;
32077
- D(z, Ot.width, Ot.height);
32083
+ i(O).onRendered = Ft, i(O).onExpand = Pt, i(O).onShrink = Pt;
32084
+ var Ot = i(O).style;
32085
+ D(O, Ot.width, Ot.height);
32078
32086
  }
32079
32087
  function H() {
32080
- if (I("finalizeDomMutation invoked."), !i(z)) {
32088
+ if (I("finalizeDomMutation invoked."), !i(O)) {
32081
32089
  I("Aborting because element has been uninstalled");
32082
32090
  return;
32083
32091
  }
32084
- var D = i(z).style;
32085
- mt(z, D.width, D.height), J(z, D.width, D.height);
32092
+ var D = i(O).style;
32093
+ mt(O, D.width, D.height), J(O, D.width, D.height);
32086
32094
  }
32087
32095
  function tt() {
32088
- R(z);
32096
+ R(O);
32089
32097
  }
32090
32098
  function ht() {
32091
32099
  I("Installing..."), rt(), it(), r.add(0, yt), r.add(1, W), r.add(2, Q), r.add(3, H), r.add(4, tt);
32092
32100
  }
32093
- I("Making detectable..."), L(z) ? (I("Element is detached"), et(), I("Waiting until element is attached..."), i(z).onRendered = function() {
32101
+ I("Making detectable..."), L(O) ? (I("Element is detached"), et(), I("Waiting until element is attached..."), i(O).onRendered = function() {
32094
32102
  I("Element is now attached"), ht();
32095
32103
  }) : ht();
32096
32104
  }
32097
- function O(M) {
32098
- var z = i(M);
32099
- z && (z.onExpandScroll && v(_(M), "scroll", z.onExpandScroll), z.onShrinkScroll && v(S(M), "scroll", z.onShrinkScroll), z.onAnimationStart && v(z.container, "animationstart", z.onAnimationStart), z.container && M.removeChild(z.container));
32105
+ function C(M) {
32106
+ var O = i(M);
32107
+ O && (O.onExpandScroll && v(_(M), "scroll", O.onExpandScroll), O.onShrinkScroll && v(S(M), "scroll", O.onShrinkScroll), O.onAnimationStart && v(O.container, "animationstart", O.onAnimationStart), O.container && M.removeChild(O.container));
32100
32108
  }
32101
32109
  return {
32102
- makeDetectable: C,
32110
+ makeDetectable: T,
32103
32111
  addListener: A,
32104
- uninstall: O,
32112
+ uninstall: C,
32105
32113
  initDocument: c
32106
32114
  };
32107
32115
  }, ac;
@@ -32142,23 +32150,23 @@ function GM() {
32142
32150
  });
32143
32151
  _ = A;
32144
32152
  }
32145
- var C = v.reporter;
32146
- if (!C) {
32147
- var O = C === !1;
32148
- C = s(O);
32153
+ var T = v.reporter;
32154
+ if (!T) {
32155
+ var C = T === !1;
32156
+ T = s(C);
32149
32157
  }
32150
- var M = m(v, "batchProcessor", a({ reporter: C })), z = {};
32151
- z.callOnAdd = !!m(v, "callOnAdd", !0), z.debug = !!m(v, "debug", !1);
32158
+ var M = m(v, "batchProcessor", a({ reporter: T })), O = {};
32159
+ O.callOnAdd = !!m(v, "callOnAdd", !0), O.debug = !!m(v, "debug", !1);
32152
32160
  var R = e(_), I = t({
32153
32161
  stateHandler: l
32154
32162
  }), L, U = m(v, "strategy", "object"), Y = m(v, "important", !1), it = {
32155
- reporter: C,
32163
+ reporter: T,
32156
32164
  batchProcessor: M,
32157
32165
  stateHandler: l,
32158
32166
  idHandler: _,
32159
32167
  important: Y
32160
32168
  };
32161
- if (U === "scroll" && (o.isLegacyOpera() ? (C.warn("Scroll strategy is not supported on legacy Opera. Changing to object strategy."), U = "object") : o.isIE(9) && (C.warn("Scroll strategy is not supported on IE9. Changing to object strategy."), U = "object")), U === "scroll")
32169
+ if (U === "scroll" && (o.isLegacyOpera() ? (T.warn("Scroll strategy is not supported on legacy Opera. Changing to object strategy."), U = "object") : o.isIE(9) && (T.warn("Scroll strategy is not supported on IE9. Changing to object strategy."), U = "object")), U === "scroll")
32162
32170
  L = h(it);
32163
32171
  else if (U === "object")
32164
32172
  L = c(it);
@@ -32184,21 +32192,21 @@ function GM() {
32184
32192
  else if (f(G))
32185
32193
  G = g(G);
32186
32194
  else
32187
- return C.error("Invalid arguments. Must be a DOM element or a collection of DOM elements.");
32188
- var K = 0, J = m(ot, "callOnAdd", z.callOnAdd), et = m(ot, "onReady", function() {
32189
- }), W = m(ot, "debug", z.debug);
32195
+ return T.error("Invalid arguments. Must be a DOM element or a collection of DOM elements.");
32196
+ var K = 0, J = m(ot, "callOnAdd", O.callOnAdd), et = m(ot, "onReady", function() {
32197
+ }), W = m(ot, "debug", O.debug);
32190
32198
  n(G, function(H) {
32191
32199
  l.getState(H) || (l.initState(H), _.set(H));
32192
32200
  var tt = _.get(H);
32193
- if (W && C.log("Attaching listener to element", tt, H), !I.isDetectable(H)) {
32194
- if (W && C.log(tt, "Not detectable."), I.isBusy(H)) {
32195
- W && C.log(tt, "System busy making it detectable"), F(J, H, pt), rt[tt] = rt[tt] || [], rt[tt].push(function() {
32201
+ if (W && T.log("Attaching listener to element", tt, H), !I.isDetectable(H)) {
32202
+ if (W && T.log(tt, "Not detectable."), I.isBusy(H)) {
32203
+ W && T.log(tt, "System busy making it detectable"), F(J, H, pt), rt[tt] = rt[tt] || [], rt[tt].push(function() {
32196
32204
  K++, K === G.length && et();
32197
32205
  });
32198
32206
  return;
32199
32207
  }
32200
- return W && C.log(tt, "Making detectable..."), I.markBusy(H, !0), L.makeDetectable({ debug: W, important: Y }, H, function(D) {
32201
- if (W && C.log(tt, "onElementDetectable"), l.getState(D)) {
32208
+ return W && T.log(tt, "Making detectable..."), I.markBusy(H, !0), L.makeDetectable({ debug: W, important: Y }, H, function(D) {
32209
+ if (W && T.log(tt, "onElementDetectable"), l.getState(D)) {
32202
32210
  I.markAsDetectable(D), I.markBusy(D, !1), L.addListener(D, k), F(J, D, pt);
32203
32211
  var ct = l.getState(D);
32204
32212
  if (ct && ct.startSize) {
@@ -32209,22 +32217,22 @@ function GM() {
32209
32217
  Ft();
32210
32218
  });
32211
32219
  } else
32212
- W && C.log(tt, "Element uninstalled before being detectable.");
32220
+ W && T.log(tt, "Element uninstalled before being detectable.");
32213
32221
  delete rt[tt], K++, K === G.length && et();
32214
32222
  });
32215
32223
  }
32216
- W && C.log(tt, "Already detecable, adding listener."), F(J, H, pt), K++;
32224
+ W && T.log(tt, "Already detecable, adding listener."), F(J, H, pt), K++;
32217
32225
  }), K === G.length && et();
32218
32226
  }
32219
32227
  function mt(ot) {
32220
32228
  if (!ot)
32221
- return C.error("At least one element is required.");
32229
+ return T.error("At least one element is required.");
32222
32230
  if (p(ot))
32223
32231
  ot = [ot];
32224
32232
  else if (f(ot))
32225
32233
  ot = g(ot);
32226
32234
  else
32227
- return C.error("Invalid arguments. Must be a DOM element or a collection of DOM elements.");
32235
+ return T.error("Invalid arguments. Must be a DOM element or a collection of DOM elements.");
32228
32236
  n(ot, function(G) {
32229
32237
  R.removeAllListeners(G), L.uninstall(G), l.cleanState(G);
32230
32238
  });
@@ -32255,8 +32263,8 @@ function YM(n) {
32255
32263
  const XM = ({
32256
32264
  children: n
32257
32265
  }) => {
32258
- const [t, e] = re(null), r = jn(null), i = jn(null);
32259
- return Vn(() => {
32266
+ const [t, e] = ee(null), r = Vn(null), i = Vn(null);
32267
+ return wn(() => {
32260
32268
  if (!r.current) return;
32261
32269
  const s = r.current.parentElement;
32262
32270
  if (!s) return;
@@ -32274,7 +32282,7 @@ const XM = ({
32274
32282
  }, []), t ? typeof n == "function" ? n(t) : X.cloneElement(n, t) : /* @__PURE__ */ w.jsx("div", { ref: r });
32275
32283
  };
32276
32284
  function JM(n) {
32277
- const t = jn(!1), e = jn(!1), r = R0(async () => {
32285
+ const t = Vn(!1), e = Vn(!1), r = R0(async () => {
32278
32286
  if (!(e.current || t.current)) {
32279
32287
  e.current = !0;
32280
32288
  try {
@@ -32286,7 +32294,7 @@ function JM(n) {
32286
32294
  }
32287
32295
  }
32288
32296
  }, [n]);
32289
- return Vn(() => {
32297
+ return wn(() => {
32290
32298
  const i = (s) => {
32291
32299
  if (!t.current)
32292
32300
  return r(), s.preventDefault(), s.returnValue = "", "";
@@ -32296,17 +32304,37 @@ function JM(n) {
32296
32304
  };
32297
32305
  }, [r]), { ensureScreenshot: r, screenshotDone: t };
32298
32306
  }
32299
- const ZM = 50, KM = 300, QM = 20, tE = [IM("pub_planner_v0"), PM()], OE = ({ plan: n, catalog: t, onSave: e, onBack: r }) => {
32300
- const i = Zt();
32301
- return Vn(() => {
32302
- i.initCatalog(t), tE.forEach((s) => s(i, n, e));
32303
- }, []), Vn(() => {
32307
+ const ZM = () => {
32308
+ const { toast: n, setToast: t } = Yt(), [e, r] = ee(!1);
32309
+ return wn(() => {
32310
+ let i;
32311
+ return n && (r(!0), i = setTimeout(() => {
32312
+ r(!1), setTimeout(() => t(null), 300);
32313
+ }, 2500)), () => clearTimeout(i);
32314
+ }, [n, t]), n ? /* @__PURE__ */ w.jsx(
32315
+ "div",
32316
+ {
32317
+ className: `absolute top-6 left-1/2 -translate-x-1/2 z-[9999] transition-all duration-300 ease-in-out
32318
+ ${e ? "opacity-100 translate-y-0" : "opacity-0 -translate-y-2"}
32319
+ `,
32320
+ children: /* @__PURE__ */ w.jsx("div", { className: "p-1 px-3 shadow-md rounded-md bg-white text-slate-600", children: /* @__PURE__ */ w.jsxs("div", { className: "flex gap-1 justify-center items-center h-8 rounded", children: [
32321
+ /* @__PURE__ */ w.jsx("span", { className: "text-xs", children: n.text }),
32322
+ /* @__PURE__ */ w.jsx("div", { className: "text-xs bg-gray-50 border rounded-md px-1 py-0.5 font-medium", children: "ESC" })
32323
+ ] }) })
32324
+ }
32325
+ ) : null;
32326
+ }, KM = 50, QM = 300, tE = 20, eE = [IM("pub_planner_v0"), PM()], zE = ({ plan: n, catalog: t, onSave: e, onBack: r }) => {
32327
+ const i = Yt();
32328
+ return wn(() => {
32329
+ i.initCatalog(t), eE.forEach((s) => s(i, n, e));
32330
+ }, []), wn(() => {
32304
32331
  i.planner.getIn(["catalog", "ready"]) || i.initCatalog(t);
32305
32332
  }, [t]), JM((s) => {
32306
32333
  e && e({ imageURI: s });
32307
32334
  }), /* @__PURE__ */ w.jsx(XM, { children: ({ width: s, height: o }) => {
32308
- const a = s - ZM - KM, l = o - QM;
32335
+ const a = s - KM - QM, l = o - tE;
32309
32336
  return /* @__PURE__ */ w.jsxs("div", { className: "flex flex-nowrap flex-row h-full floor_planner", children: [
32337
+ /* @__PURE__ */ w.jsx(ZM, {}),
32310
32338
  /* @__PURE__ */ w.jsx(RM, { onSave: e, onBack: r }),
32311
32339
  /* @__PURE__ */ w.jsx(CM, { catalog: t }),
32312
32340
  /* @__PURE__ */ w.jsx(ew, { width: a, height: l, catalog: t }),
@@ -32314,7 +32342,7 @@ const ZM = 50, KM = 300, QM = 20, tE = [IM("pub_planner_v0"), PM()], OE = ({ pla
32314
32342
  /* @__PURE__ */ w.jsx(Dw, {})
32315
32343
  ] });
32316
32344
  } });
32317
- }, zE = () => /* @__PURE__ */ w.jsxs("div", { className: "fixed inset-0 z-[100] flex flex-col bg-[#2b2d35] overflow-hidden", children: [
32345
+ }, TE = () => /* @__PURE__ */ w.jsxs("div", { className: "fixed inset-0 z-[100] flex flex-col bg-[#2b2d35] overflow-hidden", children: [
32318
32346
  /* @__PURE__ */ w.jsxs("div", { className: "flex h-[45px] items-center justify-between border border-[#424242] bg-[#2b2d35] px-2", children: [
32319
32347
  /* @__PURE__ */ w.jsx("div", { className: "flex flex-1 items-center", children: /* @__PURE__ */ w.jsx("div", { className: "h-[30px] w-[30px] rounded bg-[#424242] animate-pulse" }) }),
32320
32348
  /* @__PURE__ */ w.jsx("div", { className: "flex items-center", children: /* @__PURE__ */ w.jsx("div", { className: "h-[18px] w-[175px] bg-[#424242] animate-pulse" }) }),
@@ -32595,7 +32623,7 @@ const qi = Math.PI / 2, Og = (n, t, e, r) => {
32595
32623
  r * t.normal.heightRepeatScale
32596
32624
  )));
32597
32625
  };
32598
- function eE(n, t, e, r) {
32626
+ function rE(n, t, e, r) {
32599
32627
  let i = t.vertices.get(n.vertices.get(0)), s = t.vertices.get(n.vertices.get(1)), o = !1;
32600
32628
  if (i.x > s.x) {
32601
32629
  let U = i;
@@ -32613,26 +32641,26 @@ function eE(n, t, e, r) {
32613
32641
  let pt = new oi(v), k = new oi(G);
32614
32642
  v = pt.subtract(k).toMesh(m);
32615
32643
  }), v.name = "soul";
32616
- let C = new Gi(), O = new Gi();
32644
+ let T = new Gi(), C = new Gi();
32617
32645
  Og(
32618
- C,
32646
+ T,
32619
32647
  r[n.properties.get("textureB")],
32620
32648
  g,
32621
32649
  a
32622
32650
  ), Og(
32623
- O,
32651
+ C,
32624
32652
  r[n.properties.get("textureA")],
32625
32653
  g,
32626
32654
  a
32627
32655
  );
32628
- let M = h / l, z = c + f, R = v.clone();
32629
- R.material = C, R.scale.set(1, 1, M), R.position.x += z * Math.cos(_ - qi), R.position.z -= z * Math.sin(_ - qi), R.name = "frontFace";
32656
+ let M = h / l, O = c + f, R = v.clone();
32657
+ R.material = T, R.scale.set(1, 1, M), R.position.x += O * Math.cos(_ - qi), R.position.z -= O * Math.sin(_ - qi), R.name = "frontFace";
32630
32658
  let I = v.clone();
32631
- I.material = O, I.scale.set(1, 1, M), I.position.x += z * Math.cos(_ + qi), I.position.z -= z * Math.sin(_ + qi), I.name = "backFace";
32659
+ I.material = C, I.scale.set(1, 1, M), I.position.x += O * Math.cos(_ + qi), I.position.z -= O * Math.sin(_ + qi), I.name = "backFace";
32632
32660
  let L = new B2();
32633
32661
  return L.add(v, R, I), Promise.resolve(L);
32634
32662
  }
32635
- function rE(n, t, e, r, i, s, o, a, l) {
32663
+ function nE(n, t, e, r, i, s, o, a, l) {
32636
32664
  let c = () => (a(), l()), h = i.getObjectByName("soul"), f = i.getObjectByName("frontFace"), g = i.getObjectByName("backFace");
32637
32665
  if (o[0] == "selected")
32638
32666
  h.material = new Gi({
@@ -32644,24 +32672,24 @@ function rE(n, t, e, r, i, s, o, a, l) {
32644
32672
  "properties",
32645
32673
  "thickness",
32646
32674
  "length"
32647
- ]), _ = p / 2 + 1, S = m / h.scale.z, A = h.rotation.y, C = _ * Math.cos(A - qi), O = _ * Math.sin(A - qi);
32648
- h.scale.set(1, 1, p / S), f.position.x = h.position.x + C, f.position.z = h.position.z + O, g.position.x = h.position.x - C, g.position.z = h.position.z - O;
32675
+ ]), _ = p / 2 + 1, S = m / h.scale.z, A = h.rotation.y, T = _ * Math.cos(A - qi), C = _ * Math.sin(A - qi);
32676
+ h.scale.set(1, 1, p / S), f.position.x = h.position.x + T, f.position.z = h.position.z + C, g.position.x = h.position.x - T, g.position.z = h.position.z - C;
32649
32677
  } else return c();
32650
32678
  else return c();
32651
32679
  return Promise.resolve(i);
32652
32680
  }
32653
- const zg = 20, Tg = { textAnchor: "middle" }, nE = {
32681
+ const zg = 20, Tg = { textAnchor: "middle" }, iE = {
32654
32682
  stroke: jt.LINE_MESH_COLOR.selected
32655
32683
  }, r0 = {
32656
32684
  strokeWidth: 1,
32657
32685
  stroke: jt.COLORS.black
32658
32686
  // stroke: SharedStyle.LINE_MESH_COLOR.unselected,
32659
32687
  // fill: "url(#diagonalFill)",
32660
- }, iE = {
32688
+ }, sE = {
32661
32689
  ...r0,
32662
32690
  stroke: jt.LINE_MESH_COLOR.selected
32663
32691
  };
32664
- function TE(n, t, e) {
32692
+ function CE(n, t, e) {
32665
32693
  let r = {
32666
32694
  name: n,
32667
32695
  prototype: "lines",
@@ -32694,7 +32722,7 @@ function TE(n, t, e) {
32694
32722
  y: -m,
32695
32723
  width: f,
32696
32724
  height: p,
32697
- style: iE
32725
+ style: sE
32698
32726
  }
32699
32727
  ),
32700
32728
  /* @__PURE__ */ w.jsx(
@@ -32704,7 +32732,7 @@ function TE(n, t, e) {
32704
32732
  y1: -v,
32705
32733
  x2: g,
32706
32734
  y2: v,
32707
- style: nE
32735
+ style: iE
32708
32736
  }
32709
32737
  ),
32710
32738
  /* @__PURE__ */ w.jsx("text", { x: g, y: A + _, style: Tg, children: "A" }),
@@ -32721,9 +32749,9 @@ function TE(n, t, e) {
32721
32749
  );
32722
32750
  },
32723
32751
  render3D: function(i, s, o) {
32724
- return eE(i, s, o, e);
32752
+ return rE(i, s, o, e);
32725
32753
  },
32726
- updateRender3D: (i, s, o, a, l, c, h, f) => rE(
32754
+ updateRender3D: (i, s, o, a, l, c, h, f) => nE(
32727
32755
  i,
32728
32756
  s,
32729
32757
  o,
@@ -32753,7 +32781,7 @@ function TE(n, t, e) {
32753
32781
  }
32754
32782
  return r;
32755
32783
  }
32756
- const sE = (n, t, e, r) => {
32784
+ const oE = (n, t, e, r) => {
32757
32785
  let i = new Ky();
32758
32786
  t && (n.map = i.load(t.uri), n.needsUpdate = !0, n.map.wrapS = Kr, n.map.wrapT = Kr, n.map.repeat.set(
32759
32787
  e * t.lengthRepeatScale,
@@ -32765,7 +32793,7 @@ const sE = (n, t, e, r) => {
32765
32793
  e * t.normal.lengthRepeatScale,
32766
32794
  r * t.normal.heightRepeatScale
32767
32795
  )));
32768
- }, oE = (n) => {
32796
+ }, aE = (n) => {
32769
32797
  n.computeBoundingBox();
32770
32798
  let { min: t, max: e } = n.boundingBox, r = new xt(0 - t.x, 0 - t.y), i = new xt(e.x - t.x, e.y - t.y);
32771
32799
  n.faceVertexUvs[0] = n.faces.map((s) => {
@@ -32777,7 +32805,7 @@ const sE = (n, t, e, r) => {
32777
32805
  ];
32778
32806
  }), n.uvsNeedUpdate = !0;
32779
32807
  };
32780
- function aE(n, t, e, r) {
32808
+ function uE(n, t, e, r) {
32781
32809
  let i = [];
32782
32810
  n.vertices.forEach((v) => {
32783
32811
  i.push(t.vertices.get(v));
@@ -32792,22 +32820,22 @@ function aE(n, t, e, r) {
32792
32820
  n.holes.forEach((v) => {
32793
32821
  let _ = [];
32794
32822
  t.getIn(["areas", v, "vertices"]).forEach((A) => {
32795
- let { x: C, y: O } = t.getIn(["vertices", A]);
32796
- _.push([C, O]);
32823
+ let { x: T, y: C } = t.getIn(["vertices", A]);
32824
+ _.push([T, C]);
32797
32825
  }), _ = _.reverse();
32798
- let S = lE(_);
32826
+ let S = cE(_);
32799
32827
  a.holes.push(S);
32800
32828
  });
32801
32829
  let c = new jh(a);
32802
- oE(c);
32830
+ aE(c);
32803
32831
  let h = new Ss().setFromObject(
32804
32832
  new as(c, new Gi())
32805
32833
  ), f = h.max.x - h.min.x, g = h.max.y - h.min.y, p = r[s];
32806
- sE(l, p, f, g);
32834
+ oE(l, p, f, g);
32807
32835
  let m = new as(c, l);
32808
32836
  return m.rotation.x -= Math.PI / 2, m.name = "floor", Promise.resolve(m);
32809
32837
  }
32810
- function uE(n, t, e, r, i, s, o, a, l) {
32838
+ function lE(n, t, e, r, i, s, o, a, l) {
32811
32839
  let c = () => (a(), l()), h = i.getObjectByName("floor");
32812
32840
  if (o[0] == "selected") {
32813
32841
  let f = n.selected ? jt.AREA_MESH_COLOR.selected : n.properties.get("patternColor") || jt.AREA_MESH_COLOR.unselected;
@@ -32818,14 +32846,14 @@ function uE(n, t, e, r, i, s, o, a, l) {
32818
32846
  } else return c();
32819
32847
  return Promise.resolve(i);
32820
32848
  }
32821
- const lE = (n) => {
32849
+ const cE = (n) => {
32822
32850
  let t = new Fh();
32823
32851
  t.moveTo(n[0][0], n[0][1]);
32824
32852
  for (let e = 1; e < n.length; e++)
32825
32853
  t.lineTo(n[e][0], n[e][1]);
32826
32854
  return t;
32827
32855
  };
32828
- function CE(n, t, e) {
32856
+ function kE(n, t, e) {
32829
32857
  let r = {
32830
32858
  name: n,
32831
32859
  prototype: "areas",
@@ -32855,16 +32883,16 @@ function CE(n, t, e) {
32855
32883
  render2D: function(i, s, o) {
32856
32884
  let a = "";
32857
32885
  const l = i.properties.get("texture"), c = e[l], h = [];
32858
- i.vertices.forEach((C, O) => {
32859
- const M = s.vertices.get(C);
32860
- h.push(M), a += (O ? "L" : "M") + M.x + " " + M.y + " ";
32861
- }), i.holes.forEach((C) => {
32862
- s.areas.get(C).vertices.reverse().forEach((M, z) => {
32886
+ i.vertices.forEach((T, C) => {
32887
+ const M = s.vertices.get(T);
32888
+ h.push(M), a += (C ? "L" : "M") + M.x + " " + M.y + " ";
32889
+ }), i.holes.forEach((T) => {
32890
+ s.areas.get(T).vertices.reverse().forEach((M, O) => {
32863
32891
  const R = s.vertices.get(M);
32864
- a += (z ? "L" : "M") + R.x + " " + R.y + " ";
32892
+ a += (O ? "L" : "M") + R.x + " " + R.y + " ";
32865
32893
  });
32866
32894
  });
32867
- const f = Math.min(...h.map((C) => C.x)), g = Math.max(...h.map((C) => C.x)), p = Math.min(...h.map((C) => C.y)), m = Math.max(...h.map((C) => C.y)), v = g - f, _ = m - p;
32895
+ const f = Math.min(...h.map((T) => T.x)), g = Math.max(...h.map((T) => T.x)), p = Math.min(...h.map((T) => T.y)), m = Math.max(...h.map((T) => T.y)), v = g - f, _ = m - p;
32868
32896
  i.properties.get("patternColor"), i.selected;
32869
32897
  const S = i.selected ? jt.AREA_MESH_COLOR.selected : i.properties.get("patternColor"), A = `pattern-${i.id}`;
32870
32898
  return /* @__PURE__ */ w.jsxs("g", { children: [
@@ -32900,9 +32928,9 @@ function CE(n, t, e) {
32900
32928
  ] });
32901
32929
  },
32902
32930
  render3D: function(i, s, o) {
32903
- return aE(i, s, o, e);
32931
+ return uE(i, s, o, e);
32904
32932
  },
32905
- updateRender3D: (i, s, o, a, l, c, h, f) => uE(
32933
+ updateRender3D: (i, s, o, a, l, c, h, f) => lE(
32906
32934
  i,
32907
32935
  s,
32908
32936
  o,
@@ -32928,10 +32956,10 @@ function CE(n, t, e) {
32928
32956
  return r;
32929
32957
  }
32930
32958
  export {
32931
- CE as AreaFactory,
32932
- AE as Catalog,
32933
- zE as ReactPlannerLoader,
32934
- TE as WallFactory,
32959
+ kE as AreaFactory,
32960
+ OE as Catalog,
32961
+ TE as ReactPlannerLoader,
32962
+ CE as WallFactory,
32935
32963
  Yr as convertUnits,
32936
- OE as default
32964
+ zE as default
32937
32965
  };