@thatopen/components 2.3.7 → 2.3.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -2,15 +2,15 @@ var Ao = Object.defineProperty;
2
2
  var Fo = (c, i, t) => i in c ? Ao(c, i, { enumerable: !0, configurable: !0, writable: !0, value: t }) : c[i] = t;
3
3
  var C = (c, i, t) => (Fo(c, typeof i != "symbol" ? i + "" : i, t), t);
4
4
  import * as D from "three";
5
- import { BufferAttribute as Zr, Vector3 as Q, Vector2 as oi, Plane as Dn, Line3 as Ee, Triangle as ei, Sphere as So, Matrix4 as pe, Box3 as ae, BackSide as Oo, DoubleSide as jr, FrontSide as Xn, Mesh as rt, Ray as No, Raycaster as yo, Quaternion as de, Object3D as In, Euler as Lo, MeshBasicMaterial as qr, LineBasicMaterial as _o, CylinderGeometry as Vt, BoxGeometry as Ut, BufferGeometry as $n, Float32BufferAttribute as Zn, OctahedronGeometry as Yi, Line as Ae, SphereGeometry as Po, TorusGeometry as fi, PlaneGeometry as wo } from "three";
5
+ import { BufferAttribute as Zr, Vector3 as Q, Vector2 as ai, Plane as Dn, Line3 as Ee, Triangle as ii, Sphere as So, Matrix4 as pe, Box3 as ae, BackSide as Oo, DoubleSide as jr, FrontSide as Xn, Mesh as rt, Ray as No, Raycaster as yo, Quaternion as de, Object3D as In, Euler as Lo, MeshBasicMaterial as qr, LineBasicMaterial as _o, CylinderGeometry as Vt, BoxGeometry as Ut, BufferGeometry as $n, Float32BufferAttribute as Zn, OctahedronGeometry as Gi, Line as Ae, SphereGeometry as Po, TorusGeometry as Ii, PlaneGeometry as wo } from "three";
6
6
  import * as Qt from "@thatopen/fragments";
7
7
  import { FragmentsGroup as Mo, Serializer as Do } from "@thatopen/fragments";
8
8
  import * as z from "web-ifc";
9
- const Qr = 0, bo = 1, vo = 2, jn = 2, Ws = 1.25, qn = 1, fs = 6 * 4 + 4 + 4, Ys = 65535, Uo = Math.pow(2, -24), Xs = Symbol("SKIP_GENERATION");
9
+ const Qr = 0, bo = 1, vo = 2, jn = 2, Ws = 1.25, qn = 1, Is = 6 * 4 + 4 + 4, Ys = 65535, Uo = Math.pow(2, -24), Xs = Symbol("SKIP_GENERATION");
10
10
  function xo(c) {
11
11
  return c.index ? c.index.count : c.attributes.position.count;
12
12
  }
13
- function ci(c) {
13
+ function li(c) {
14
14
  return xo(c) / 3;
15
15
  }
16
16
  function Bo(c, i = ArrayBuffer) {
@@ -25,7 +25,7 @@ function Vo(c, i) {
25
25
  }
26
26
  }
27
27
  function Kr(c) {
28
- const i = ci(c), t = c.drawRange, e = t.start / 3, s = (t.start + t.count) / 3, n = Math.max(0, e), r = Math.min(i, s) - n;
28
+ const i = li(c), t = c.drawRange, e = t.start / 3, s = (t.start + t.count) / 3, n = Math.max(0, e), r = Math.min(i, s) - n;
29
29
  return [{
30
30
  offset: Math.floor(n),
31
31
  count: Math.floor(r)
@@ -52,7 +52,7 @@ function Jr(c) {
52
52
  function Yo(c) {
53
53
  if (c.groups.length === 0)
54
54
  return !1;
55
- const i = ci(c), t = Jr(c).sort((n, r) => n.offset - r.offset), e = t[t.length - 1];
55
+ const i = li(c), t = Jr(c).sort((n, r) => n.offset - r.offset), e = t[t.length - 1];
56
56
  e.count = Math.min(i - e.offset, e.count);
57
57
  let s = 0;
58
58
  return t.forEach(({ count: n }) => s += n), i !== s;
@@ -81,13 +81,13 @@ function Jn(c, i, t) {
81
81
  e = c[n], s = i[n], t[n] = e < s ? e : s, e = c[r], s = i[r], t[r] = e > s ? e : s;
82
82
  }
83
83
  }
84
- function Gi(c, i, t) {
84
+ function zi(c, i, t) {
85
85
  for (let e = 0; e < 3; e++) {
86
86
  const s = i[c + 2 * e], n = i[c + 2 * e + 1], r = s - n, o = s + n;
87
87
  r < t[e] && (t[e] = r), o > t[e + 3] && (t[e + 3] = o);
88
88
  }
89
89
  }
90
- function Ii(c) {
90
+ function di(c) {
91
91
  const i = c[3] - c[0], t = c[4] - c[1], e = c[5] - c[2];
92
92
  return 2 * (i * t + t * e + e * i);
93
93
  }
@@ -97,8 +97,8 @@ function $s(c, i, t, e, s = null) {
97
97
  for (let m = i * 6, F = (i + t) * 6; m < F; m += 6) {
98
98
  const R = c[m + 0], S = c[m + 1], N = R - S, y = R + S;
99
99
  N < n && (n = N), y > a && (a = y), p && R < f && (f = R), p && R > d && (d = R);
100
- const M = c[m + 2], L = c[m + 3], b = M - L, G = M + L;
101
- b < r && (r = b), G > l && (l = G), p && M < I && (I = M), p && M > E && (E = M);
100
+ const M = c[m + 2], L = c[m + 3], b = M - L, Y = M + L;
101
+ b < r && (r = b), Y > l && (l = Y), p && M < I && (I = M), p && M > E && (E = M);
102
102
  const O = c[m + 4], w = c[m + 5], g = O - w, v = O + w;
103
103
  g < o && (o = g), v > h && (h = v), p && O < u && (u = O), p && O > T && (T = O);
104
104
  }
@@ -118,7 +118,7 @@ function zo(c, i, t, e) {
118
118
  }
119
119
  function ko(c, i) {
120
120
  Go(i);
121
- const t = c.attributes.position, e = c.index ? c.index.array : null, s = ci(c), n = new Float32Array(s * 6), r = t.normalized, o = t.array, a = t.offset || 0;
121
+ const t = c.attributes.position, e = c.index ? c.index.array : null, s = li(c), n = new Float32Array(s * 6), r = t.normalized, o = t.array, a = t.offset || 0;
122
122
  let l = 3;
123
123
  t.isInterleavedBufferAttribute && (l = t.data.stride);
124
124
  const h = ["getX", "getY", "getZ"];
@@ -145,7 +145,7 @@ const Te = 32, Ho = (c, i) => c.candidate - i.candidate, Fe = new Array(Te).fill
145
145
  rightCacheBounds: new Float32Array(6),
146
146
  leftCacheBounds: new Float32Array(6),
147
147
  candidate: 0
148
- })), zi = new Float32Array(6);
148
+ })), ki = new Float32Array(6);
149
149
  function Wo(c, i, t, e, s, n) {
150
150
  let r = -1, o = 0;
151
151
  if (n === Qr)
@@ -153,7 +153,7 @@ function Wo(c, i, t, e, s, n) {
153
153
  else if (n === bo)
154
154
  r = Qn(c), r !== -1 && (o = Xo(t, e, s, r));
155
155
  else if (n === vo) {
156
- const a = Ii(c);
156
+ const a = di(c);
157
157
  let l = Ws * s;
158
158
  const h = e * 6, f = (e + s) * 6;
159
159
  for (let I = 0; I < 3; I++) {
@@ -172,7 +172,7 @@ function Wo(c, i, t, e, s, n) {
172
172
  } = S;
173
173
  for (let L = 0; L < 3; L++)
174
174
  M[L] = 1 / 0, M[L + 3] = -1 / 0, y[L] = 1 / 0, y[L + 3] = -1 / 0, N[L] = 1 / 0, N[L + 3] = -1 / 0;
175
- Gi(R, t, N);
175
+ zi(R, t, N);
176
176
  }
177
177
  p.sort(Ho);
178
178
  let F = s;
@@ -185,16 +185,16 @@ function Wo(c, i, t, e, s, n) {
185
185
  const S = t[R + 2 * I];
186
186
  for (let N = 0; N < F; N++) {
187
187
  const y = p[N];
188
- S >= y.candidate ? Gi(R, t, y.rightCacheBounds) : (Gi(R, t, y.leftCacheBounds), y.count++);
188
+ S >= y.candidate ? zi(R, t, y.rightCacheBounds) : (zi(R, t, y.leftCacheBounds), y.count++);
189
189
  }
190
190
  }
191
191
  for (let R = 0; R < F; R++) {
192
192
  const S = p[R], N = S.count, y = s - S.count, M = S.leftCacheBounds, L = S.rightCacheBounds;
193
193
  let b = 0;
194
- N !== 0 && (b = Ii(M) / a);
195
- let G = 0;
196
- y !== 0 && (G = Ii(L) / a);
197
- const O = qn + Ws * (b * N + G * y);
194
+ N !== 0 && (b = di(M) / a);
195
+ let Y = 0;
196
+ y !== 0 && (Y = di(L) / a);
197
+ const O = qn + Ws * (b * N + Y * y);
198
198
  O < l && (r = I, l = O, o = S.candidate);
199
199
  }
200
200
  } else {
@@ -209,7 +209,7 @@ function Wo(c, i, t, e, s, n) {
209
209
  let N = ~~((t[F + 2 * I] - u) / T);
210
210
  N >= Te && (N = Te - 1);
211
211
  const y = Fe[N];
212
- y.count++, Gi(F, t, y.bounds);
212
+ y.count++, zi(F, t, y.bounds);
213
213
  }
214
214
  const p = Fe[Te - 1];
215
215
  Kn(p.bounds, p.rightCacheBounds);
@@ -220,12 +220,12 @@ function Wo(c, i, t, e, s, n) {
220
220
  let m = 0;
221
221
  for (let F = 0; F < Te - 1; F++) {
222
222
  const R = Fe[F], S = R.count, N = R.bounds, M = Fe[F + 1].rightCacheBounds;
223
- S !== 0 && (m === 0 ? Kn(N, zi) : Jn(N, zi, zi)), m += S;
223
+ S !== 0 && (m === 0 ? Kn(N, ki) : Jn(N, ki, ki)), m += S;
224
224
  let L = 0, b = 0;
225
- m !== 0 && (L = Ii(zi) / a);
226
- const G = s - m;
227
- G !== 0 && (b = Ii(M) / a);
228
- const O = qn + Ws * (L * m + b * G);
225
+ m !== 0 && (L = di(ki) / a);
226
+ const Y = s - m;
227
+ Y !== 0 && (b = di(M) / a);
228
+ const O = qn + Ws * (L * m + b * Y);
229
229
  O < l && (r = I, l = O, o = R.candidate);
230
230
  }
231
231
  }
@@ -240,7 +240,7 @@ function Xo(c, i, t, e) {
240
240
  s += c[n * 6 + e * 2];
241
241
  return s / t;
242
242
  }
243
- class ki {
243
+ class Hi {
244
244
  constructor() {
245
245
  }
246
246
  }
@@ -293,15 +293,15 @@ function jo(c, i) {
293
293
  return r;
294
294
  }
295
295
  function qo(c, i) {
296
- const t = c.geometry, e = t.index ? t.index.array : null, s = i.maxDepth, n = i.verbose, r = i.maxLeafTris, o = i.strategy, a = i.onProgress, l = ci(t), h = c._indirectBuffer;
296
+ const t = c.geometry, e = t.index ? t.index.array : null, s = i.maxDepth, n = i.verbose, r = i.maxLeafTris, o = i.strategy, a = i.onProgress, l = li(t), h = c._indirectBuffer;
297
297
  let f = !1;
298
298
  const I = new Float32Array(6), u = new Float32Array(6), d = ko(t, I), E = i.indirect ? Zo : $o, T = [], p = i.indirect ? Kr(t) : Jr(t);
299
299
  if (p.length === 1) {
300
- const R = p[0], S = new ki();
300
+ const R = p[0], S = new Hi();
301
301
  S.boundingData = I, zo(d, R.offset, R.count, u), F(S, R.offset, R.count, u), T.push(S);
302
302
  } else
303
303
  for (let R of p) {
304
- const S = new ki();
304
+ const S = new Hi();
305
305
  S.boundingData = new Float32Array(6), $s(d, R.offset, R.count, S.boundingData, u), F(S, R.offset, R.count, u), T.push(S);
306
306
  }
307
307
  return T;
@@ -319,10 +319,10 @@ function qo(c, i) {
319
319
  m(S + N), R.offset = S, R.count = N;
320
320
  else {
321
321
  R.splitAxis = L.axis;
322
- const G = new ki(), O = S, w = b - S;
323
- R.left = G, G.boundingData = new Float32Array(6), $s(d, O, w, G.boundingData, u), F(G, O, w, u, M + 1);
324
- const g = new ki(), v = b, j = N - w;
325
- R.right = g, g.boundingData = new Float32Array(6), $s(d, v, j, g.boundingData, u), F(g, v, j, u, M + 1);
322
+ const Y = new Hi(), O = S, w = b - S;
323
+ R.left = Y, Y.boundingData = new Float32Array(6), $s(d, O, w, Y.boundingData, u), F(Y, O, w, u, M + 1);
324
+ const g = new Hi(), v = b, q = N - w;
325
+ R.right = g, g.boundingData = new Float32Array(6), $s(d, v, q, g.boundingData, u), F(g, v, q, u, M + 1);
326
326
  }
327
327
  return R;
328
328
  }
@@ -338,7 +338,7 @@ function Qo(c, i) {
338
338
  for (let f = 0; f < e.length; f++) {
339
339
  const I = e[f];
340
340
  let u = l(I);
341
- const d = new a(fs * u);
341
+ const d = new a(Is * u);
342
342
  s = new Float32Array(d), n = new Uint32Array(d), r = new Uint16Array(d), h(0, I), o.push(d);
343
343
  }
344
344
  c._roots = o;
@@ -352,11 +352,11 @@ function Qo(c, i) {
352
352
  s[u + p] = T[p];
353
353
  if (E) {
354
354
  const p = I.offset, m = I.count;
355
- return n[u + 6] = p, r[d + 14] = m, r[d + 15] = Ys, f + fs;
355
+ return n[u + 6] = p, r[d + 14] = m, r[d + 15] = Ys, f + Is;
356
356
  } else {
357
357
  const p = I.left, m = I.right, F = I.splitAxis;
358
358
  let R;
359
- if (R = h(f + fs, p), R / 4 > Math.pow(2, 32))
359
+ if (R = h(f + Is, p), R / 4 > Math.pow(2, 32))
360
360
  throw new Error("MeshBVH: Cannot store child pointer greater than 32 bits.");
361
361
  return n[u + 6] = R / 4, R = h(R, m), n[u + 7] = F, R;
362
362
  }
@@ -411,7 +411,7 @@ const Ko = function() {
411
411
  T !== 0 ? p = (f * I - d * u) / T : p = 0, m = (f + p * I) / u, r.x = p, r.y = m;
412
412
  };
413
413
  }(), bn = function() {
414
- const c = new oi(), i = new Q(), t = new Q();
414
+ const c = new ai(), i = new Q(), t = new Q();
415
415
  return function(s, n, r, o) {
416
416
  Ko(s, n, c);
417
417
  let a = c.x, l = c.y;
@@ -457,7 +457,7 @@ const Ko = function() {
457
457
  function Zs(c) {
458
458
  return Math.abs(c) < ta;
459
459
  }
460
- class ne extends ei {
460
+ class ne extends ii {
461
461
  constructor(...i) {
462
462
  super(...i), this.isExtendedTriangle = !0, this.satAxes = new Array(4).fill().map(() => new Q()), this.satBounds = new Array(4).fill().map(() => new ge()), this.points = [this.a, this.b, this.c], this.sphere = new So(), this.plane = new Dn(), this.needsUpdate = !0;
463
463
  }
@@ -521,21 +521,21 @@ ne.prototype.intersectsTriangle = function() {
521
521
  const S = this.satBounds, N = this.satAxes;
522
522
  t[0] = T.a, t[1] = T.b, t[2] = T.c;
523
523
  for (let L = 0; L < 4; L++) {
524
- const b = S[L], G = N[L];
525
- if (e.setFromPoints(G, t), b.isSeparated(e))
524
+ const b = S[L], Y = N[L];
525
+ if (e.setFromPoints(Y, t), b.isSeparated(e))
526
526
  return !1;
527
527
  }
528
528
  const y = T.satBounds, M = T.satAxes;
529
529
  i[0] = this.a, i[1] = this.b, i[2] = this.c;
530
530
  for (let L = 0; L < 4; L++) {
531
- const b = y[L], G = M[L];
532
- if (e.setFromPoints(G, i), b.isSeparated(e))
531
+ const b = y[L], Y = M[L];
532
+ if (e.setFromPoints(Y, i), b.isSeparated(e))
533
533
  return !1;
534
534
  }
535
535
  for (let L = 0; L < 4; L++) {
536
536
  const b = N[L];
537
- for (let G = 0; G < 4; G++) {
538
- const O = M[G];
537
+ for (let Y = 0; Y < 4; Y++) {
538
+ const O = M[Y];
539
539
  if (n.crossVectors(b, O), e.setFromPoints(n, i), s.setFromPoints(n, t), e.isSeparated(s))
540
540
  return !1;
541
541
  }
@@ -556,8 +556,8 @@ ne.prototype.intersectsTriangle = function() {
556
556
  let w = I.start;
557
557
  I.start = I.end, I.end = w;
558
558
  }
559
- const y = f.start.dot(o), M = f.end.dot(o), L = I.start.dot(o), b = I.end.dot(o), G = M < L, O = y < b;
560
- return y !== b && L !== M && G === O ? !1 : (p && (l.subVectors(f.start, I.start), l.dot(o) > 0 ? p.start.copy(f.start) : p.start.copy(I.start), l.subVectors(f.end, I.end), l.dot(o) < 0 ? p.end.copy(f.end) : p.end.copy(I.end)), !0);
559
+ const y = f.start.dot(o), M = f.end.dot(o), L = I.start.dot(o), b = I.end.dot(o), Y = M < L, O = y < b;
560
+ return y !== b && L !== M && Y === O ? !1 : (p && (l.subVectors(f.start, I.start), l.dot(o) > 0 ? p.start.copy(f.start) : p.start.copy(I.start), l.subVectors(f.end, I.end), l.dot(o) < 0 ? p.end.copy(f.end) : p.end.copy(I.end)), !0);
561
561
  }
562
562
  };
563
563
  }();
@@ -697,8 +697,8 @@ Bt.prototype.distanceToBox = function() {
697
697
  for (let m = 0; m <= 1; m++) {
698
698
  const F = (T + 1) % 3, R = (T + 2) % 3, S = p << F | m << R, N = 1 << T | p << F | m << R, y = u[S], M = u[N];
699
699
  i[E].set(y, M);
700
- const b = c[T], G = c[F], O = c[R], w = t[E], g = w.start, v = w.end;
701
- g[b] = f[b], g[G] = p ? f[G] : I[G], g[O] = m ? f[O] : I[G], v[b] = I[b], v[G] = p ? f[G] : I[G], v[O] = m ? f[O] : I[G], E++;
700
+ const b = c[T], Y = c[F], O = c[R], w = t[E], g = w.start, v = w.end;
701
+ g[b] = f[b], g[Y] = p ? f[Y] : I[Y], g[O] = m ? f[O] : I[Y], v[b] = I[b], v[Y] = p ? f[Y] : I[Y], v[O] = m ? f[O] : I[Y], E++;
702
702
  }
703
703
  for (let T = 0; T <= 1; T++)
704
704
  for (let p = 0; p <= 1; p++)
@@ -770,14 +770,14 @@ class ia {
770
770
  }
771
771
  }
772
772
  const Ft = new ia();
773
- let _e, ii;
774
- const Ge = [], Hi = /* @__PURE__ */ new vn(() => new ae());
773
+ let _e, si;
774
+ const ze = [], Wi = /* @__PURE__ */ new vn(() => new ae());
775
775
  function sa(c, i, t, e, s, n) {
776
- _e = Hi.getPrimitive(), ii = Hi.getPrimitive(), Ge.push(_e, ii), Ft.setBuffer(c._roots[i]);
776
+ _e = Wi.getPrimitive(), si = Wi.getPrimitive(), ze.push(_e, si), Ft.setBuffer(c._roots[i]);
777
777
  const r = dn(0, c.geometry, t, e, s, n);
778
- Ft.clearBuffer(), Hi.releasePrimitive(_e), Hi.releasePrimitive(ii), Ge.pop(), Ge.pop();
779
- const o = Ge.length;
780
- return o > 0 && (ii = Ge[o - 1], _e = Ge[o - 2]), r;
778
+ Ft.clearBuffer(), Wi.releasePrimitive(_e), Wi.releasePrimitive(si), ze.pop(), ze.pop();
779
+ const o = ze.length;
780
+ return o > 0 && (si = ze[o - 1], _e = ze[o - 2]), r;
781
781
  }
782
782
  function dn(c, i, t, e, s = null, n = 0, r = 0) {
783
783
  const { float32Array: o, uint16Array: a, uint32Array: l } = Ft;
@@ -792,7 +792,7 @@ function dn(c, i, t, e, s = null, n = 0, r = 0) {
792
792
  for (; !Gt(v, w); )
793
793
  O = jt(O), v = O * 2;
794
794
  return zt(O, g);
795
- }, G = function(O) {
795
+ }, Y = function(O) {
796
796
  const { uint16Array: w, uint32Array: g } = Ft;
797
797
  let v = O * 2;
798
798
  for (; !Gt(v, w); )
@@ -801,7 +801,7 @@ function dn(c, i, t, e, s = null, n = 0, r = 0) {
801
801
  };
802
802
  const I = jt(c), u = qt(c, l);
803
803
  let d = I, E = u, T, p, m, F;
804
- if (s && (m = _e, F = ii, Nt(d, o, m), Nt(E, o, F), T = s(m), p = s(F), p < T)) {
804
+ if (s && (m = _e, F = si, Nt(d, o, m), Nt(E, o, F), T = s(m), p = s(F), p < T)) {
805
805
  d = u, E = I;
806
806
  const O = T;
807
807
  T = p, p = O, m = F;
@@ -810,7 +810,7 @@ function dn(c, i, t, e, s = null, n = 0, r = 0) {
810
810
  const R = Gt(d * 2, a), S = t(m, R, T, r + 1, n + d);
811
811
  let N;
812
812
  if (S === jn) {
813
- const O = b(d), g = G(d) - O;
813
+ const O = b(d), g = Y(d) - O;
814
814
  N = e(O, g, !0, r + 1, n + d, m);
815
815
  } else
816
816
  N = S && dn(
@@ -824,11 +824,11 @@ function dn(c, i, t, e, s = null, n = 0, r = 0) {
824
824
  );
825
825
  if (N)
826
826
  return !0;
827
- F = ii, Nt(E, o, F);
827
+ F = si, Nt(E, o, F);
828
828
  const y = Gt(E * 2, a), M = t(F, y, p, r + 1, n + E);
829
829
  let L;
830
830
  if (M === jn) {
831
- const O = b(E), g = G(E) - O;
831
+ const O = b(E), g = Y(E) - O;
832
832
  L = e(O, g, !0, r + 1, n + E, F);
833
833
  } else
834
834
  L = M && dn(
@@ -843,18 +843,18 @@ function dn(c, i, t, e, s = null, n = 0, r = 0) {
843
843
  return !!L;
844
844
  }
845
845
  }
846
- const di = /* @__PURE__ */ new Q(), js = /* @__PURE__ */ new Q();
846
+ const Ei = /* @__PURE__ */ new Q(), js = /* @__PURE__ */ new Q();
847
847
  function na(c, i, t = {}, e = 0, s = 1 / 0) {
848
848
  const n = e * e, r = s * s;
849
849
  let o = 1 / 0, a = null;
850
850
  if (c.shapecast(
851
851
  {
852
- boundsTraverseOrder: (h) => (di.copy(i).clamp(h.min, h.max), di.distanceToSquared(i)),
852
+ boundsTraverseOrder: (h) => (Ei.copy(i).clamp(h.min, h.max), Ei.distanceToSquared(i)),
853
853
  intersectsBounds: (h, f, I) => I < o && I < r,
854
854
  intersectsTriangle: (h, f) => {
855
- h.closestPointToPoint(i, di);
856
- const I = i.distanceToSquared(di);
857
- return I < o && (js.copy(di), o = I, a = f), I < n;
855
+ h.closestPointToPoint(i, Ei);
856
+ const I = i.distanceToSquared(Ei);
857
+ return I < o && (js.copy(Ei), o = I, a = f), I < n;
858
858
  }
859
859
  }
860
860
  ), o === 1 / 0)
@@ -862,7 +862,7 @@ function na(c, i, t = {}, e = 0, s = 1 / 0) {
862
862
  const l = Math.sqrt(o);
863
863
  return t.point ? t.point.copy(js) : t.point = js.clone(), t.distance = l, t.faceIndex = a, t;
864
864
  }
865
- const ze = /* @__PURE__ */ new Q(), ke = /* @__PURE__ */ new Q(), He = /* @__PURE__ */ new Q(), Wi = /* @__PURE__ */ new oi(), Xi = /* @__PURE__ */ new oi(), $i = /* @__PURE__ */ new oi(), tr = /* @__PURE__ */ new Q(), er = /* @__PURE__ */ new Q(), ir = /* @__PURE__ */ new Q(), Zi = /* @__PURE__ */ new Q();
865
+ const ke = /* @__PURE__ */ new Q(), He = /* @__PURE__ */ new Q(), We = /* @__PURE__ */ new Q(), Xi = /* @__PURE__ */ new ai(), $i = /* @__PURE__ */ new ai(), Zi = /* @__PURE__ */ new ai(), tr = /* @__PURE__ */ new Q(), er = /* @__PURE__ */ new Q(), ir = /* @__PURE__ */ new Q(), ji = /* @__PURE__ */ new Q();
866
866
  function ra(c, i, t, e, s, n) {
867
867
  let r;
868
868
  return n === Oo ? r = c.intersectTriangle(e, t, i, !0, s) : r = c.intersectTriangle(i, t, e, n !== jr, s), r === null ? null : {
@@ -871,10 +871,10 @@ function ra(c, i, t, e, s, n) {
871
871
  };
872
872
  }
873
873
  function oa(c, i, t, e, s, n, r, o, a) {
874
- ze.fromBufferAttribute(i, n), ke.fromBufferAttribute(i, r), He.fromBufferAttribute(i, o);
875
- const l = ra(c, ze, ke, He, Zi, a);
874
+ ke.fromBufferAttribute(i, n), He.fromBufferAttribute(i, r), We.fromBufferAttribute(i, o);
875
+ const l = ra(c, ke, He, We, ji, a);
876
876
  if (l) {
877
- e && (Wi.fromBufferAttribute(e, n), Xi.fromBufferAttribute(e, r), $i.fromBufferAttribute(e, o), l.uv = ei.getInterpolation(Zi, ze, ke, He, Wi, Xi, $i, new oi())), s && (Wi.fromBufferAttribute(s, n), Xi.fromBufferAttribute(s, r), $i.fromBufferAttribute(s, o), l.uv1 = ei.getInterpolation(Zi, ze, ke, He, Wi, Xi, $i, new oi())), t && (tr.fromBufferAttribute(t, n), er.fromBufferAttribute(t, r), ir.fromBufferAttribute(t, o), l.normal = ei.getInterpolation(Zi, ze, ke, He, tr, er, ir, new Q()), l.normal.dot(c.direction) > 0 && l.normal.multiplyScalar(-1));
877
+ e && (Xi.fromBufferAttribute(e, n), $i.fromBufferAttribute(e, r), Zi.fromBufferAttribute(e, o), l.uv = ii.getInterpolation(ji, ke, He, We, Xi, $i, Zi, new ai())), s && (Xi.fromBufferAttribute(s, n), $i.fromBufferAttribute(s, r), Zi.fromBufferAttribute(s, o), l.uv1 = ii.getInterpolation(ji, ke, He, We, Xi, $i, Zi, new ai())), t && (tr.fromBufferAttribute(t, n), er.fromBufferAttribute(t, r), ir.fromBufferAttribute(t, o), l.normal = ii.getInterpolation(ji, ke, He, We, tr, er, ir, new Q()), l.normal.dot(c.direction) > 0 && l.normal.multiplyScalar(-1));
878
878
  const h = {
879
879
  a: n,
880
880
  b: r,
@@ -882,7 +882,7 @@ function oa(c, i, t, e, s, n, r, o, a) {
882
882
  normal: new Q(),
883
883
  materialIndex: 0
884
884
  };
885
- ei.getNormal(ze, ke, He, h.normal), l.face = h, l.faceIndex = n;
885
+ ii.getNormal(ke, He, We, h.normal), l.face = h, l.faceIndex = n;
886
886
  }
887
887
  return l;
888
888
  }
@@ -935,8 +935,8 @@ function ha(c, i = null) {
935
935
  const p = r[I + 6], m = o[E + 14];
936
936
  let F = 1 / 0, R = 1 / 0, S = 1 / 0, N = -1 / 0, y = -1 / 0, M = -1 / 0;
937
937
  for (let L = 3 * p, b = 3 * (p + m); L < b; L++) {
938
- let G = e[L];
939
- const O = s.getX(G), w = s.getY(G), g = s.getZ(G);
938
+ let Y = e[L];
939
+ const O = s.getX(Y), w = s.getY(Y), g = s.getZ(Y);
940
940
  O < F && (F = O), O > N && (N = O), w < R && (R = w), w > y && (y = w), g < S && (S = g), g > M && (M = g);
941
941
  }
942
942
  return a[I + 0] !== F || a[I + 1] !== R || a[I + 2] !== S || a[I + 3] !== N || a[I + 4] !== y || a[I + 5] !== M ? (a[I + 0] = F, a[I + 1] = R, a[I + 2] = S, a[I + 3] = N, a[I + 4] = y, a[I + 5] = M, !0) : !1;
@@ -947,20 +947,20 @@ function ha(c, i = null) {
947
947
  const M = S || N, L = S || y;
948
948
  let b = !1;
949
949
  M && (b = f(p, u, S));
950
- let G = !1;
951
- L && (G = f(m, u, S));
952
- const O = b || G;
950
+ let Y = !1;
951
+ L && (Y = f(m, u, S));
952
+ const O = b || Y;
953
953
  if (O)
954
954
  for (let w = 0; w < 3; w++) {
955
- const g = p + w, v = m + w, j = a[g], V = a[g + 3], et = a[v], W = a[v + 3];
956
- a[I + w] = j < et ? j : et, a[I + w + 3] = V > W ? V : W;
955
+ const g = p + w, v = m + w, q = a[g], G = a[g + 3], et = a[v], W = a[v + 3];
956
+ a[I + w] = q < et ? q : et, a[I + w + 3] = G > W ? G : W;
957
957
  }
958
958
  return O;
959
959
  }
960
960
  }
961
961
  }
962
962
  const sr = /* @__PURE__ */ new ae();
963
- function we(c, i, t, e) {
963
+ function Me(c, i, t, e) {
964
964
  return Nt(c, i, sr), t.intersectBox(sr, e);
965
965
  }
966
966
  function ua(c, i, t, e, s, n) {
@@ -999,9 +999,9 @@ function En(c, i, t, e, s) {
999
999
  aa(i, t, e, h, f, s);
1000
1000
  } else {
1001
1001
  const h = jt(c);
1002
- we(h, n, e, nr) && En(h, i, t, e, s);
1002
+ Me(h, n, e, nr) && En(h, i, t, e, s);
1003
1003
  const f = qt(c, o);
1004
- we(f, n, e, nr) && En(f, i, t, e, s);
1004
+ Me(f, n, e, nr) && En(f, i, t, e, s);
1005
1005
  }
1006
1006
  }
1007
1007
  const rr = /* @__PURE__ */ new Q(), Ea = ["x", "y", "z"];
@@ -1020,7 +1020,7 @@ function pn(c, i, t, e) {
1020
1020
  const l = to(c, r), h = Ea[l], I = e.direction[h] >= 0;
1021
1021
  let u, d;
1022
1022
  I ? (u = jt(c), d = qt(c, r)) : (u = qt(c, r), d = jt(c));
1023
- const T = we(u, s, e, rr) ? pn(u, i, t, e) : null;
1023
+ const T = Me(u, s, e, rr) ? pn(u, i, t, e) : null;
1024
1024
  if (T) {
1025
1025
  const F = T.point[h];
1026
1026
  if (I ? F <= s[d + l] : (
@@ -1029,11 +1029,11 @@ function pn(c, i, t, e) {
1029
1029
  ))
1030
1030
  return T;
1031
1031
  }
1032
- const m = we(d, s, e, rr) ? pn(d, i, t, e) : null;
1032
+ const m = Me(d, s, e, rr) ? pn(d, i, t, e) : null;
1033
1033
  return T && m ? T.distance <= m.distance ? T : m : T || m || null;
1034
1034
  }
1035
1035
  }
1036
- const ji = /* @__PURE__ */ new ae(), We = /* @__PURE__ */ new ne(), Xe = /* @__PURE__ */ new ne(), Ei = /* @__PURE__ */ new pe(), or = /* @__PURE__ */ new Bt(), qi = /* @__PURE__ */ new Bt();
1036
+ const qi = /* @__PURE__ */ new ae(), Xe = /* @__PURE__ */ new ne(), $e = /* @__PURE__ */ new ne(), pi = /* @__PURE__ */ new pe(), or = /* @__PURE__ */ new Bt(), Qi = /* @__PURE__ */ new Bt();
1037
1037
  function Ca(c, i, t, e) {
1038
1038
  Ft.setBuffer(c._roots[i]);
1039
1039
  const s = Cn(0, c, t, e);
@@ -1044,46 +1044,46 @@ function Cn(c, i, t, e, s = null) {
1044
1044
  let a = c * 2;
1045
1045
  if (s === null && (t.boundingBox || t.computeBoundingBox(), or.set(t.boundingBox.min, t.boundingBox.max, e), s = or), Gt(a, r)) {
1046
1046
  const h = i.geometry, f = h.index, I = h.attributes.position, u = t.index, d = t.attributes.position, E = zt(c, o), T = Zt(a, r);
1047
- if (Ei.copy(e).invert(), t.boundsTree)
1048
- return Nt(c, n, qi), qi.matrix.copy(Ei), qi.needsUpdate = !0, t.boundsTree.shapecast({
1049
- intersectsBounds: (m) => qi.intersectsBox(m),
1047
+ if (pi.copy(e).invert(), t.boundsTree)
1048
+ return Nt(c, n, Qi), Qi.matrix.copy(pi), Qi.needsUpdate = !0, t.boundsTree.shapecast({
1049
+ intersectsBounds: (m) => Qi.intersectsBox(m),
1050
1050
  intersectsTriangle: (m) => {
1051
1051
  m.a.applyMatrix4(e), m.b.applyMatrix4(e), m.c.applyMatrix4(e), m.needsUpdate = !0;
1052
1052
  for (let F = E * 3, R = (T + E) * 3; F < R; F += 3)
1053
- if (wt(Xe, F, f, I), Xe.needsUpdate = !0, m.intersectsTriangle(Xe))
1053
+ if (wt($e, F, f, I), $e.needsUpdate = !0, m.intersectsTriangle($e))
1054
1054
  return !0;
1055
1055
  return !1;
1056
1056
  }
1057
1057
  });
1058
1058
  for (let p = E * 3, m = (T + E) * 3; p < m; p += 3) {
1059
- wt(We, p, f, I), We.a.applyMatrix4(Ei), We.b.applyMatrix4(Ei), We.c.applyMatrix4(Ei), We.needsUpdate = !0;
1059
+ wt(Xe, p, f, I), Xe.a.applyMatrix4(pi), Xe.b.applyMatrix4(pi), Xe.c.applyMatrix4(pi), Xe.needsUpdate = !0;
1060
1060
  for (let F = 0, R = u.count; F < R; F += 3)
1061
- if (wt(Xe, F, u, d), Xe.needsUpdate = !0, We.intersectsTriangle(Xe))
1061
+ if (wt($e, F, u, d), $e.needsUpdate = !0, Xe.intersectsTriangle($e))
1062
1062
  return !0;
1063
1063
  }
1064
1064
  } else {
1065
1065
  const h = c + 8, f = o[c + 6];
1066
- return Nt(h, n, ji), !!(s.intersectsBox(ji) && Cn(h, i, t, e, s) || (Nt(f, n, ji), s.intersectsBox(ji) && Cn(f, i, t, e, s)));
1066
+ return Nt(h, n, qi), !!(s.intersectsBox(qi) && Cn(h, i, t, e, s) || (Nt(f, n, qi), s.intersectsBox(qi) && Cn(f, i, t, e, s)));
1067
1067
  }
1068
1068
  }
1069
- const Qi = /* @__PURE__ */ new pe(), qs = /* @__PURE__ */ new Bt(), pi = /* @__PURE__ */ new Bt(), Ta = /* @__PURE__ */ new Q(), ma = /* @__PURE__ */ new Q(), Ra = /* @__PURE__ */ new Q(), ga = /* @__PURE__ */ new Q();
1069
+ const Ki = /* @__PURE__ */ new pe(), qs = /* @__PURE__ */ new Bt(), Ci = /* @__PURE__ */ new Bt(), Ta = /* @__PURE__ */ new Q(), ma = /* @__PURE__ */ new Q(), Ra = /* @__PURE__ */ new Q(), ga = /* @__PURE__ */ new Q();
1070
1070
  function Aa(c, i, t, e = {}, s = {}, n = 0, r = 1 / 0) {
1071
1071
  i.boundingBox || i.computeBoundingBox(), qs.set(i.boundingBox.min, i.boundingBox.max, t), qs.needsUpdate = !0;
1072
1072
  const o = c.geometry, a = o.attributes.position, l = o.index, h = i.attributes.position, f = i.index, I = $t.getPrimitive(), u = $t.getPrimitive();
1073
1073
  let d = Ta, E = ma, T = null, p = null;
1074
1074
  s && (T = Ra, p = ga);
1075
1075
  let m = 1 / 0, F = null, R = null;
1076
- return Qi.copy(t).invert(), pi.matrix.copy(Qi), c.shapecast(
1076
+ return Ki.copy(t).invert(), Ci.matrix.copy(Ki), c.shapecast(
1077
1077
  {
1078
1078
  boundsTraverseOrder: (S) => qs.distanceToBox(S),
1079
- intersectsBounds: (S, N, y) => y < m && y < r ? (N && (pi.min.copy(S.min), pi.max.copy(S.max), pi.needsUpdate = !0), !0) : !1,
1079
+ intersectsBounds: (S, N, y) => y < m && y < r ? (N && (Ci.min.copy(S.min), Ci.max.copy(S.max), Ci.needsUpdate = !0), !0) : !1,
1080
1080
  intersectsRange: (S, N) => {
1081
1081
  if (i.boundsTree)
1082
1082
  return i.boundsTree.shapecast({
1083
- boundsTraverseOrder: (M) => pi.distanceToBox(M),
1083
+ boundsTraverseOrder: (M) => Ci.distanceToBox(M),
1084
1084
  intersectsBounds: (M, L, b) => b < m && b < r,
1085
1085
  intersectsRange: (M, L) => {
1086
- for (let b = M, G = M + L; b < G; b++) {
1086
+ for (let b = M, Y = M + L; b < Y; b++) {
1087
1087
  wt(u, 3 * b, f, h), u.a.applyMatrix4(t), u.b.applyMatrix4(t), u.c.applyMatrix4(t), u.needsUpdate = !0;
1088
1088
  for (let O = S, w = S + N; O < w; O++) {
1089
1089
  wt(I, 3 * O, l, a), I.needsUpdate = !0;
@@ -1095,10 +1095,10 @@ function Aa(c, i, t, e = {}, s = {}, n = 0, r = 1 / 0) {
1095
1095
  }
1096
1096
  });
1097
1097
  {
1098
- const y = ci(i);
1098
+ const y = li(i);
1099
1099
  for (let M = 0, L = y; M < L; M++) {
1100
1100
  wt(u, 3 * M, f, h), u.a.applyMatrix4(t), u.b.applyMatrix4(t), u.c.applyMatrix4(t), u.needsUpdate = !0;
1101
- for (let b = S, G = S + N; b < G; b++) {
1101
+ for (let b = S, Y = S + N; b < Y; b++) {
1102
1102
  wt(I, 3 * b, l, a), I.needsUpdate = !0;
1103
1103
  const O = I.distanceToTriangle(u, d, T);
1104
1104
  if (O < m && (E.copy(d), p && p.copy(T), m = O, F = b, R = M), O < n)
@@ -1108,7 +1108,7 @@ function Aa(c, i, t, e = {}, s = {}, n = 0, r = 1 / 0) {
1108
1108
  }
1109
1109
  }
1110
1110
  }
1111
- ), $t.releasePrimitive(I), $t.releasePrimitive(u), m === 1 / 0 ? null : (e.point ? e.point.copy(E) : e.point = E.clone(), e.distance = m, e.faceIndex = F, s && (s.point ? s.point.copy(p) : s.point = p.clone(), s.point.applyMatrix4(Qi), E.applyMatrix4(Qi), s.distance = E.sub(s.point).length(), s.faceIndex = R), e);
1111
+ ), $t.releasePrimitive(I), $t.releasePrimitive(u), m === 1 / 0 ? null : (e.point ? e.point.copy(E) : e.point = E.clone(), e.distance = m, e.faceIndex = F, s && (s.point ? s.point.copy(p) : s.point = p.clone(), s.point.applyMatrix4(Ki), E.applyMatrix4(Ki), s.distance = E.sub(s.point).length(), s.faceIndex = R), e);
1112
1112
  }
1113
1113
  function Fa(c, i = null) {
1114
1114
  i && Array.isArray(i) && (i = new Set(i));
@@ -1123,12 +1123,12 @@ function Fa(c, i = null) {
1123
1123
  const p = r[I + 6], m = o[E + 14];
1124
1124
  let F = 1 / 0, R = 1 / 0, S = 1 / 0, N = -1 / 0, y = -1 / 0, M = -1 / 0;
1125
1125
  for (let L = p, b = p + m; L < b; L++) {
1126
- const G = 3 * c.resolveTriangleIndex(L);
1126
+ const Y = 3 * c.resolveTriangleIndex(L);
1127
1127
  for (let O = 0; O < 3; O++) {
1128
- let w = G + O;
1128
+ let w = Y + O;
1129
1129
  w = e ? e[w] : w;
1130
- const g = s.getX(w), v = s.getY(w), j = s.getZ(w);
1131
- g < F && (F = g), g > N && (N = g), v < R && (R = v), v > y && (y = v), j < S && (S = j), j > M && (M = j);
1130
+ const g = s.getX(w), v = s.getY(w), q = s.getZ(w);
1131
+ g < F && (F = g), g > N && (N = g), v < R && (R = v), v > y && (y = v), q < S && (S = q), q > M && (M = q);
1132
1132
  }
1133
1133
  }
1134
1134
  return a[I + 0] !== F || a[I + 1] !== R || a[I + 2] !== S || a[I + 3] !== N || a[I + 4] !== y || a[I + 5] !== M ? (a[I + 0] = F, a[I + 1] = R, a[I + 2] = S, a[I + 3] = N, a[I + 4] = y, a[I + 5] = M, !0) : !1;
@@ -1139,13 +1139,13 @@ function Fa(c, i = null) {
1139
1139
  const M = S || N, L = S || y;
1140
1140
  let b = !1;
1141
1141
  M && (b = f(p, u, S));
1142
- let G = !1;
1143
- L && (G = f(m, u, S));
1144
- const O = b || G;
1142
+ let Y = !1;
1143
+ L && (Y = f(m, u, S));
1144
+ const O = b || Y;
1145
1145
  if (O)
1146
1146
  for (let w = 0; w < 3; w++) {
1147
- const g = p + w, v = m + w, j = a[g], V = a[g + 3], et = a[v], W = a[v + 3];
1148
- a[I + w] = j < et ? j : et, a[I + w + 3] = V > W ? V : W;
1147
+ const g = p + w, v = m + w, q = a[g], G = a[g + 3], et = a[v], W = a[v + 3];
1148
+ a[I + w] = q < et ? q : et, a[I + w + 3] = G > W ? G : W;
1149
1149
  }
1150
1150
  return O;
1151
1151
  }
@@ -1162,9 +1162,9 @@ function Tn(c, i, t, e, s) {
1162
1162
  ua(i, t, e, h, f, s);
1163
1163
  } else {
1164
1164
  const h = jt(c);
1165
- we(h, n, e, ar) && Tn(h, i, t, e, s);
1165
+ Me(h, n, e, ar) && Tn(h, i, t, e, s);
1166
1166
  const f = qt(c, o);
1167
- we(f, n, e, ar) && Tn(f, i, t, e, s);
1167
+ Me(f, n, e, ar) && Tn(f, i, t, e, s);
1168
1168
  }
1169
1169
  }
1170
1170
  const cr = /* @__PURE__ */ new Q(), Oa = ["x", "y", "z"];
@@ -1183,7 +1183,7 @@ function mn(c, i, t, e) {
1183
1183
  const l = to(c, r), h = Oa[l], I = e.direction[h] >= 0;
1184
1184
  let u, d;
1185
1185
  I ? (u = jt(c), d = qt(c, r)) : (u = qt(c, r), d = jt(c));
1186
- const T = we(u, s, e, cr) ? mn(u, i, t, e) : null;
1186
+ const T = Me(u, s, e, cr) ? mn(u, i, t, e) : null;
1187
1187
  if (T) {
1188
1188
  const F = T.point[h];
1189
1189
  if (I ? F <= s[d + l] : (
@@ -1192,11 +1192,11 @@ function mn(c, i, t, e) {
1192
1192
  ))
1193
1193
  return T;
1194
1194
  }
1195
- const m = we(d, s, e, cr) ? mn(d, i, t, e) : null;
1195
+ const m = Me(d, s, e, cr) ? mn(d, i, t, e) : null;
1196
1196
  return T && m ? T.distance <= m.distance ? T : m : T || m || null;
1197
1197
  }
1198
1198
  }
1199
- const Ki = /* @__PURE__ */ new ae(), $e = /* @__PURE__ */ new ne(), Ze = /* @__PURE__ */ new ne(), Ci = /* @__PURE__ */ new pe(), lr = /* @__PURE__ */ new Bt(), Ji = /* @__PURE__ */ new Bt();
1199
+ const Ji = /* @__PURE__ */ new ae(), Ze = /* @__PURE__ */ new ne(), je = /* @__PURE__ */ new ne(), Ti = /* @__PURE__ */ new pe(), lr = /* @__PURE__ */ new Bt(), ts = /* @__PURE__ */ new Bt();
1200
1200
  function ya(c, i, t, e) {
1201
1201
  Ft.setBuffer(c._roots[i]);
1202
1202
  const s = Rn(0, c, t, e);
@@ -1207,65 +1207,65 @@ function Rn(c, i, t, e, s = null) {
1207
1207
  let a = c * 2;
1208
1208
  if (s === null && (t.boundingBox || t.computeBoundingBox(), lr.set(t.boundingBox.min, t.boundingBox.max, e), s = lr), Gt(a, r)) {
1209
1209
  const h = i.geometry, f = h.index, I = h.attributes.position, u = t.index, d = t.attributes.position, E = zt(c, o), T = Zt(a, r);
1210
- if (Ci.copy(e).invert(), t.boundsTree)
1211
- return Nt(c, n, Ji), Ji.matrix.copy(Ci), Ji.needsUpdate = !0, t.boundsTree.shapecast({
1212
- intersectsBounds: (m) => Ji.intersectsBox(m),
1210
+ if (Ti.copy(e).invert(), t.boundsTree)
1211
+ return Nt(c, n, ts), ts.matrix.copy(Ti), ts.needsUpdate = !0, t.boundsTree.shapecast({
1212
+ intersectsBounds: (m) => ts.intersectsBox(m),
1213
1213
  intersectsTriangle: (m) => {
1214
1214
  m.a.applyMatrix4(e), m.b.applyMatrix4(e), m.c.applyMatrix4(e), m.needsUpdate = !0;
1215
1215
  for (let F = E, R = T + E; F < R; F++)
1216
- if (wt(Ze, 3 * i.resolveTriangleIndex(F), f, I), Ze.needsUpdate = !0, m.intersectsTriangle(Ze))
1216
+ if (wt(je, 3 * i.resolveTriangleIndex(F), f, I), je.needsUpdate = !0, m.intersectsTriangle(je))
1217
1217
  return !0;
1218
1218
  return !1;
1219
1219
  }
1220
1220
  });
1221
1221
  for (let p = E, m = T + E; p < m; p++) {
1222
1222
  const F = i.resolveTriangleIndex(p);
1223
- wt($e, 3 * F, f, I), $e.a.applyMatrix4(Ci), $e.b.applyMatrix4(Ci), $e.c.applyMatrix4(Ci), $e.needsUpdate = !0;
1223
+ wt(Ze, 3 * F, f, I), Ze.a.applyMatrix4(Ti), Ze.b.applyMatrix4(Ti), Ze.c.applyMatrix4(Ti), Ze.needsUpdate = !0;
1224
1224
  for (let R = 0, S = u.count; R < S; R += 3)
1225
- if (wt(Ze, R, u, d), Ze.needsUpdate = !0, $e.intersectsTriangle(Ze))
1225
+ if (wt(je, R, u, d), je.needsUpdate = !0, Ze.intersectsTriangle(je))
1226
1226
  return !0;
1227
1227
  }
1228
1228
  } else {
1229
1229
  const h = c + 8, f = o[c + 6];
1230
- return Nt(h, n, Ki), !!(s.intersectsBox(Ki) && Rn(h, i, t, e, s) || (Nt(f, n, Ki), s.intersectsBox(Ki) && Rn(f, i, t, e, s)));
1230
+ return Nt(h, n, Ji), !!(s.intersectsBox(Ji) && Rn(h, i, t, e, s) || (Nt(f, n, Ji), s.intersectsBox(Ji) && Rn(f, i, t, e, s)));
1231
1231
  }
1232
1232
  }
1233
- const ts = /* @__PURE__ */ new pe(), Qs = /* @__PURE__ */ new Bt(), Ti = /* @__PURE__ */ new Bt(), La = /* @__PURE__ */ new Q(), _a = /* @__PURE__ */ new Q(), Pa = /* @__PURE__ */ new Q(), wa = /* @__PURE__ */ new Q();
1233
+ const es = /* @__PURE__ */ new pe(), Qs = /* @__PURE__ */ new Bt(), mi = /* @__PURE__ */ new Bt(), La = /* @__PURE__ */ new Q(), _a = /* @__PURE__ */ new Q(), Pa = /* @__PURE__ */ new Q(), wa = /* @__PURE__ */ new Q();
1234
1234
  function Ma(c, i, t, e = {}, s = {}, n = 0, r = 1 / 0) {
1235
1235
  i.boundingBox || i.computeBoundingBox(), Qs.set(i.boundingBox.min, i.boundingBox.max, t), Qs.needsUpdate = !0;
1236
1236
  const o = c.geometry, a = o.attributes.position, l = o.index, h = i.attributes.position, f = i.index, I = $t.getPrimitive(), u = $t.getPrimitive();
1237
1237
  let d = La, E = _a, T = null, p = null;
1238
1238
  s && (T = Pa, p = wa);
1239
1239
  let m = 1 / 0, F = null, R = null;
1240
- return ts.copy(t).invert(), Ti.matrix.copy(ts), c.shapecast(
1240
+ return es.copy(t).invert(), mi.matrix.copy(es), c.shapecast(
1241
1241
  {
1242
1242
  boundsTraverseOrder: (S) => Qs.distanceToBox(S),
1243
- intersectsBounds: (S, N, y) => y < m && y < r ? (N && (Ti.min.copy(S.min), Ti.max.copy(S.max), Ti.needsUpdate = !0), !0) : !1,
1243
+ intersectsBounds: (S, N, y) => y < m && y < r ? (N && (mi.min.copy(S.min), mi.max.copy(S.max), mi.needsUpdate = !0), !0) : !1,
1244
1244
  intersectsRange: (S, N) => {
1245
1245
  if (i.boundsTree) {
1246
1246
  const y = i.boundsTree;
1247
1247
  return y.shapecast({
1248
- boundsTraverseOrder: (M) => Ti.distanceToBox(M),
1248
+ boundsTraverseOrder: (M) => mi.distanceToBox(M),
1249
1249
  intersectsBounds: (M, L, b) => b < m && b < r,
1250
1250
  intersectsRange: (M, L) => {
1251
- for (let b = M, G = M + L; b < G; b++) {
1251
+ for (let b = M, Y = M + L; b < Y; b++) {
1252
1252
  const O = y.resolveTriangleIndex(b);
1253
1253
  wt(u, 3 * O, f, h), u.a.applyMatrix4(t), u.b.applyMatrix4(t), u.c.applyMatrix4(t), u.needsUpdate = !0;
1254
1254
  for (let w = S, g = S + N; w < g; w++) {
1255
1255
  const v = c.resolveTriangleIndex(w);
1256
1256
  wt(I, 3 * v, l, a), I.needsUpdate = !0;
1257
- const j = I.distanceToTriangle(u, d, T);
1258
- if (j < m && (E.copy(d), p && p.copy(T), m = j, F = w, R = b), j < n)
1257
+ const q = I.distanceToTriangle(u, d, T);
1258
+ if (q < m && (E.copy(d), p && p.copy(T), m = q, F = w, R = b), q < n)
1259
1259
  return !0;
1260
1260
  }
1261
1261
  }
1262
1262
  }
1263
1263
  });
1264
1264
  } else {
1265
- const y = ci(i);
1265
+ const y = li(i);
1266
1266
  for (let M = 0, L = y; M < L; M++) {
1267
1267
  wt(u, 3 * M, f, h), u.a.applyMatrix4(t), u.b.applyMatrix4(t), u.c.applyMatrix4(t), u.needsUpdate = !0;
1268
- for (let b = S, G = S + N; b < G; b++) {
1268
+ for (let b = S, Y = S + N; b < Y; b++) {
1269
1269
  const O = c.resolveTriangleIndex(b);
1270
1270
  wt(I, 3 * O, l, a), I.needsUpdate = !0;
1271
1271
  const w = I.distanceToTriangle(u, d, T);
@@ -1276,12 +1276,12 @@ function Ma(c, i, t, e = {}, s = {}, n = 0, r = 1 / 0) {
1276
1276
  }
1277
1277
  }
1278
1278
  }
1279
- ), $t.releasePrimitive(I), $t.releasePrimitive(u), m === 1 / 0 ? null : (e.point ? e.point.copy(E) : e.point = E.clone(), e.distance = m, e.faceIndex = F, s && (s.point ? s.point.copy(p) : s.point = p.clone(), s.point.applyMatrix4(ts), E.applyMatrix4(ts), s.distance = E.sub(s.point).length(), s.faceIndex = R), e);
1279
+ ), $t.releasePrimitive(I), $t.releasePrimitive(u), m === 1 / 0 ? null : (e.point ? e.point.copy(E) : e.point = E.clone(), e.distance = m, e.faceIndex = F, s && (s.point ? s.point.copy(p) : s.point = p.clone(), s.point.applyMatrix4(es), E.applyMatrix4(es), s.distance = E.sub(s.point).length(), s.faceIndex = R), e);
1280
1280
  }
1281
1281
  function Da() {
1282
1282
  return typeof SharedArrayBuffer < "u";
1283
1283
  }
1284
- const Pi = new Ft.constructor(), ps = new Ft.constructor(), Ne = new vn(() => new ae()), je = new ae(), qe = new ae(), Ks = new ae(), Js = new ae();
1284
+ const wi = new Ft.constructor(), ps = new Ft.constructor(), Ne = new vn(() => new ae()), qe = new ae(), Qe = new ae(), Ks = new ae(), Js = new ae();
1285
1285
  let tn = !1;
1286
1286
  function ba(c, i, t, e) {
1287
1287
  if (tn)
@@ -1291,9 +1291,9 @@ function ba(c, i, t, e) {
1291
1291
  let r, o = 0, a = 0;
1292
1292
  const l = new pe().copy(t).invert();
1293
1293
  for (let h = 0, f = s.length; h < f; h++) {
1294
- Pi.setBuffer(s[h]), a = 0;
1294
+ wi.setBuffer(s[h]), a = 0;
1295
1295
  const I = Ne.getPrimitive();
1296
- Nt(0, Pi.float32Array, I), I.applyMatrix4(l);
1296
+ Nt(0, wi.float32Array, I), I.applyMatrix4(l);
1297
1297
  for (let u = 0, d = n.length; u < d && (ps.setBuffer(n[h]), r = Kt(
1298
1298
  0,
1299
1299
  0,
@@ -1307,14 +1307,14 @@ function ba(c, i, t, e) {
1307
1307
  I
1308
1308
  ), ps.clearBuffer(), a += n[u].length, !r); u++)
1309
1309
  ;
1310
- if (Ne.releasePrimitive(I), Pi.clearBuffer(), o += s[h].length, r)
1310
+ if (Ne.releasePrimitive(I), wi.clearBuffer(), o += s[h].length, r)
1311
1311
  break;
1312
1312
  }
1313
1313
  return tn = !1, r;
1314
1314
  }
1315
1315
  function Kt(c, i, t, e, s, n = 0, r = 0, o = 0, a = 0, l = null, h = !1) {
1316
1316
  let f, I;
1317
- h ? (f = ps, I = Pi) : (f = Pi, I = ps);
1317
+ h ? (f = ps, I = wi) : (f = wi, I = ps);
1318
1318
  const u = f.float32Array, d = f.uint32Array, E = f.uint16Array, T = I.float32Array, p = I.uint32Array, m = I.uint16Array, F = c * 2, R = i * 2, S = Gt(F, E), N = Gt(R, m);
1319
1319
  let y = !1;
1320
1320
  if (N && S)
@@ -1341,9 +1341,9 @@ function Kt(c, i, t, e, s, n = 0, r = 0, o = 0, a = 0, l = null, h = !1) {
1341
1341
  const M = Ne.getPrimitive();
1342
1342
  Nt(i, T, M), M.applyMatrix4(t);
1343
1343
  const L = jt(c), b = qt(c, d);
1344
- Nt(L, u, je), Nt(b, u, qe);
1345
- const G = M.intersectsBox(je), O = M.intersectsBox(qe);
1346
- y = G && Kt(
1344
+ Nt(L, u, qe), Nt(b, u, Qe);
1345
+ const Y = M.intersectsBox(qe), O = M.intersectsBox(Qe);
1346
+ y = Y && Kt(
1347
1347
  i,
1348
1348
  L,
1349
1349
  e,
@@ -1371,8 +1371,8 @@ function Kt(c, i, t, e, s, n = 0, r = 0, o = 0, a = 0, l = null, h = !1) {
1371
1371
  } else {
1372
1372
  const M = jt(i), L = qt(i, p);
1373
1373
  Nt(M, T, Ks), Nt(L, T, Js);
1374
- const b = l.intersectsBox(Ks), G = l.intersectsBox(Js);
1375
- if (b && G)
1374
+ const b = l.intersectsBox(Ks), Y = l.intersectsBox(Js);
1375
+ if (b && Y)
1376
1376
  y = Kt(
1377
1377
  c,
1378
1378
  M,
@@ -1417,8 +1417,8 @@ function Kt(c, i, t, e, s, n = 0, r = 0, o = 0, a = 0, l = null, h = !1) {
1417
1417
  const O = Ne.getPrimitive();
1418
1418
  O.copy(Ks).applyMatrix4(t);
1419
1419
  const w = jt(c), g = qt(c, d);
1420
- Nt(w, u, je), Nt(g, u, qe);
1421
- const v = O.intersectsBox(je), j = O.intersectsBox(qe);
1420
+ Nt(w, u, qe), Nt(g, u, Qe);
1421
+ const v = O.intersectsBox(qe), q = O.intersectsBox(Qe);
1422
1422
  y = v && Kt(
1423
1423
  M,
1424
1424
  w,
@@ -1431,7 +1431,7 @@ function Kt(c, i, t, e, s, n = 0, r = 0, o = 0, a = 0, l = null, h = !1) {
1431
1431
  o + 1,
1432
1432
  O,
1433
1433
  !h
1434
- ) || j && Kt(
1434
+ ) || q && Kt(
1435
1435
  M,
1436
1436
  g,
1437
1437
  e,
@@ -1445,7 +1445,7 @@ function Kt(c, i, t, e, s, n = 0, r = 0, o = 0, a = 0, l = null, h = !1) {
1445
1445
  !h
1446
1446
  ), Ne.releasePrimitive(O);
1447
1447
  }
1448
- else if (G)
1448
+ else if (Y)
1449
1449
  if (S)
1450
1450
  y = Kt(
1451
1451
  c,
@@ -1464,8 +1464,8 @@ function Kt(c, i, t, e, s, n = 0, r = 0, o = 0, a = 0, l = null, h = !1) {
1464
1464
  const O = Ne.getPrimitive();
1465
1465
  O.copy(Js).applyMatrix4(t);
1466
1466
  const w = jt(c), g = qt(c, d);
1467
- Nt(w, u, je), Nt(g, u, qe);
1468
- const v = O.intersectsBox(je), j = O.intersectsBox(qe);
1467
+ Nt(w, u, qe), Nt(g, u, Qe);
1468
+ const v = O.intersectsBox(qe), q = O.intersectsBox(Qe);
1469
1469
  y = v && Kt(
1470
1470
  L,
1471
1471
  w,
@@ -1478,7 +1478,7 @@ function Kt(c, i, t, e, s, n = 0, r = 0, o = 0, a = 0, l = null, h = !1) {
1478
1478
  o + 1,
1479
1479
  O,
1480
1480
  !h
1481
- ) || j && Kt(
1481
+ ) || q && Kt(
1482
1482
  L,
1483
1483
  g,
1484
1484
  e,
@@ -1495,7 +1495,7 @@ function Kt(c, i, t, e, s, n = 0, r = 0, o = 0, a = 0, l = null, h = !1) {
1495
1495
  }
1496
1496
  return y;
1497
1497
  }
1498
- const es = /* @__PURE__ */ new Bt(), hr = /* @__PURE__ */ new ae();
1498
+ const is = /* @__PURE__ */ new Bt(), hr = /* @__PURE__ */ new ae();
1499
1499
  class Un {
1500
1500
  static serialize(i, t = {}) {
1501
1501
  t = {
@@ -1570,7 +1570,7 @@ class Un {
1570
1570
  const f = s[o + 6], I = n[l + 14];
1571
1571
  i(a, h, new Float32Array(e, o * 4, 6), f, I);
1572
1572
  } else {
1573
- const f = o + fs / 4, I = s[o + 6], u = s[o + 7];
1573
+ const f = o + Is / 4, I = s[o + 6], u = s[o + 7];
1574
1574
  i(a, h, new Float32Array(e, o * 4, 6), u) || (r(f, a + 1), r(I, a + 1));
1575
1575
  }
1576
1576
  }
@@ -1666,10 +1666,10 @@ class Un {
1666
1666
  }
1667
1667
  /* Derived Cast Functions */
1668
1668
  intersectsBox(i, t) {
1669
- return es.set(i.min, i.max, t), es.needsUpdate = !0, this.shapecast(
1669
+ return is.set(i.min, i.max, t), is.needsUpdate = !0, this.shapecast(
1670
1670
  {
1671
- intersectsBounds: (e) => es.intersectsBox(e),
1672
- intersectsTriangle: (e) => es.intersectsTriangle(e)
1671
+ intersectsBounds: (e) => is.intersectsBox(e),
1672
+ intersectsTriangle: (e) => is.intersectsTriangle(e)
1673
1673
  }
1674
1674
  );
1675
1675
  }
@@ -1736,7 +1736,7 @@ function xa(c) {
1736
1736
  function Ba() {
1737
1737
  this.boundsTree = null;
1738
1738
  }
1739
- class Z {
1739
+ class j {
1740
1740
  constructor() {
1741
1741
  /** Triggers all the callbacks assigned to this event. */
1742
1742
  C(this, "trigger", (i) => {
@@ -1765,7 +1765,7 @@ class Z {
1765
1765
  this.handlers.length = 0;
1766
1766
  }
1767
1767
  }
1768
- class Is {
1768
+ class Pe {
1769
1769
  constructor() {
1770
1770
  /** Triggers all the callbacks assigned to this event. */
1771
1771
  C(this, "trigger", async (i) => {
@@ -1819,7 +1819,7 @@ class Bn extends xn {
1819
1819
  * Event that is triggered when a world is added or removed from the `worlds` map.
1820
1820
  * The event payload contains the world instance and the action ("added" or "removed").
1821
1821
  */
1822
- C(this, "onWorldChanged", new Z());
1822
+ C(this, "onWorldChanged", new j());
1823
1823
  /**
1824
1824
  * The current world this item is associated with. It can be null if no world is currently active.
1825
1825
  */
@@ -1844,18 +1844,18 @@ class Ya extends Bn {
1844
1844
  constructor() {
1845
1845
  super(...arguments);
1846
1846
  /** {@link Updateable.onBeforeUpdate} */
1847
- C(this, "onAfterUpdate", new Z());
1847
+ C(this, "onAfterUpdate", new j());
1848
1848
  /** {@link Updateable.onAfterUpdate} */
1849
- C(this, "onBeforeUpdate", new Z());
1849
+ C(this, "onBeforeUpdate", new j());
1850
1850
  /** {@link Disposable.onDisposed} */
1851
- C(this, "onDisposed", new Z());
1851
+ C(this, "onDisposed", new j());
1852
1852
  /** {@link Resizeable.onResize} */
1853
- C(this, "onResize", new Z());
1853
+ C(this, "onResize", new j());
1854
1854
  /**
1855
1855
  * Event that fires when there has been a change to the list of clipping
1856
1856
  * planes used by the active renderer.
1857
1857
  */
1858
- C(this, "onClippingPlanesUpdated", new Z());
1858
+ C(this, "onClippingPlanesUpdated", new j());
1859
1859
  /**
1860
1860
  * The list of [clipping planes](https://threejs.org/docs/#api/en/renderers/WebGLRenderer.clippingPlanes) used by this instance of the renderer.
1861
1861
  */
@@ -1893,13 +1893,13 @@ class Ya extends Bn {
1893
1893
  );
1894
1894
  }
1895
1895
  }
1896
- const wi = class wi extends At {
1896
+ const Mi = class Mi extends At {
1897
1897
  constructor(t) {
1898
1898
  super(t);
1899
1899
  C(this, "_disposedComponents", /* @__PURE__ */ new Set());
1900
1900
  /** {@link Component.enabled} */
1901
1901
  C(this, "enabled", !0);
1902
- t.add(wi.uuid, this);
1902
+ t.add(Mi.uuid, this);
1903
1903
  }
1904
1904
  // TODO: Remove this?
1905
1905
  /**
@@ -1937,7 +1937,7 @@ const wi = class wi extends At {
1937
1937
  }
1938
1938
  disposeGeometryAndMaterials(t, e) {
1939
1939
  const s = t;
1940
- s.geometry && this.disposeGeometry(s.geometry), e && s.material && wi.disposeMaterial(s), s.material = [], s.geometry = null;
1940
+ s.geometry && this.disposeGeometry(s.geometry), e && s.material && Mi.disposeMaterial(s), s.material = [], s.geometry = null;
1941
1941
  }
1942
1942
  disposeChildren(t) {
1943
1943
  for (const e of t.children)
@@ -1956,13 +1956,13 @@ const wi = class wi extends At {
1956
1956
  * A unique identifier for the component.
1957
1957
  * This UUID is used to register the component within the Components system.
1958
1958
  */
1959
- C(wi, "uuid", "76e9cd8e-ad8f-4753-9ef6-cbc60f7247fe");
1960
- let Me = wi;
1959
+ C(Mi, "uuid", "76e9cd8e-ad8f-4753-9ef6-cbc60f7247fe");
1960
+ let De = Mi;
1961
1961
  class Ga extends Bn {
1962
1962
  constructor(t) {
1963
1963
  super(t);
1964
1964
  /** {@link Disposable.onDisposed} */
1965
- C(this, "onDisposed", new Z());
1965
+ C(this, "onDisposed", new j());
1966
1966
  /** The set of directional lights managed by this scene component. */
1967
1967
  C(this, "directionalLights", /* @__PURE__ */ new Map());
1968
1968
  /** The set of ambient lights managed by this scene component. */
@@ -1970,7 +1970,7 @@ class Ga extends Bn {
1970
1970
  }
1971
1971
  /** {@link Disposable.dispose} */
1972
1972
  dispose() {
1973
- const t = this.components.get(Me);
1973
+ const t = this.components.get(De);
1974
1974
  for (const e of this.three.children) {
1975
1975
  const s = e;
1976
1976
  s.geometry && t.destroy(s);
@@ -1986,7 +1986,7 @@ class Ga extends Bn {
1986
1986
  this.ambientLights.clear();
1987
1987
  }
1988
1988
  }
1989
- class Pe extends Set {
1989
+ class we extends Set {
1990
1990
  /**
1991
1991
  * Constructs a new instance of the DataSet class.
1992
1992
  *
@@ -1997,15 +1997,15 @@ class Pe extends Set {
1997
1997
  /**
1998
1998
  * An event that is triggered when a new item is added to the set.
1999
1999
  */
2000
- C(this, "onItemAdded", new Z());
2000
+ C(this, "onItemAdded", new j());
2001
2001
  /**
2002
2002
  * An event that is triggered when an item is deleted from the set.
2003
2003
  */
2004
- C(this, "onItemDeleted", new Z());
2004
+ C(this, "onItemDeleted", new j());
2005
2005
  /**
2006
2006
  * An event that is triggered when the set is cleared.
2007
2007
  */
2008
- C(this, "onCleared", new Z());
2008
+ C(this, "onCleared", new j());
2009
2009
  /**
2010
2010
  * A function that acts as a guard for adding items to the set.
2011
2011
  * It determines whether a given value should be allowed to be added to the set.
@@ -2031,7 +2031,7 @@ class Pe extends Set {
2031
2031
  */
2032
2032
  add(...t) {
2033
2033
  for (const e of t)
2034
- this.has(e) || !this.guard(e) || (super.add(e), this.onItemAdded || (this.onItemAdded = new Z()), this.onItemAdded.trigger(e));
2034
+ this.has(e) || !this.guard(e) || (super.add(e), this.onItemAdded || (this.onItemAdded = new j()), this.onItemAdded.trigger(e));
2035
2035
  return this;
2036
2036
  }
2037
2037
  /**
@@ -2062,19 +2062,19 @@ class re extends Map {
2062
2062
  /**
2063
2063
  * An event triggered when a new item is set in the map.
2064
2064
  */
2065
- C(this, "onItemSet", new Z());
2065
+ C(this, "onItemSet", new j());
2066
2066
  /**
2067
2067
  * An event triggered when an existing item in the map is updated.
2068
2068
  */
2069
- C(this, "onItemUpdated", new Z());
2069
+ C(this, "onItemUpdated", new j());
2070
2070
  /**
2071
2071
  * An event triggered when an item is deleted from the map.
2072
2072
  */
2073
- C(this, "onItemDeleted", new Z());
2073
+ C(this, "onItemDeleted", new j());
2074
2074
  /**
2075
2075
  * An event triggered when the map is cleared.
2076
2076
  */
2077
- C(this, "onCleared", new Z());
2077
+ C(this, "onCleared", new j());
2078
2078
  /**
2079
2079
  * A function that acts as a guard for adding items to the set.
2080
2080
  * It determines whether a given value should be allowed to be added to the set.
@@ -2105,7 +2105,7 @@ class re extends Map {
2105
2105
  if (!(this.guard ?? (() => !0))(t, e))
2106
2106
  return this;
2107
2107
  const o = super.set(t, e);
2108
- return s ? (this.onItemUpdated || (this.onItemUpdated = new Z()), this.onItemUpdated.trigger({ key: t, value: e })) : (this.onItemSet || (this.onItemSet = new Z()), this.onItemSet.trigger({ key: t, value: e })), o;
2108
+ return s ? (this.onItemUpdated || (this.onItemUpdated = new j()), this.onItemUpdated.trigger({ key: t, value: e })) : (this.onItemSet || (this.onItemSet = new j()), this.onItemSet.trigger({ key: t, value: e })), o;
2109
2109
  }
2110
2110
  /**
2111
2111
  * Deletes the specified key from the map and triggers the onItemDeleted event if the key was found.
@@ -2126,7 +2126,7 @@ class re extends Map {
2126
2126
  }
2127
2127
  class ph extends At {
2128
2128
  }
2129
- const ds = 0, za = 1, ka = new Q(), Ir = new Ee(), sn = new Dn(), dr = new Q(), is = new ei();
2129
+ const ds = 0, za = 1, ka = new Q(), Ir = new Ee(), sn = new Dn(), dr = new Q(), ss = new ii();
2130
2130
  class Ha {
2131
2131
  constructor() {
2132
2132
  this.tolerance = -1, this.faces = [], this.newFaces = [], this.assigned = new Er(), this.unassigned = new Er(), this.vertices = [];
@@ -2400,7 +2400,7 @@ class te {
2400
2400
  }
2401
2401
  compute() {
2402
2402
  const i = this.edge.tail(), t = this.edge.head(), e = this.edge.next.head();
2403
- return is.set(i.point, t.point, e.point), is.getNormal(this.normal), is.getMidpoint(this.midpoint), this.area = is.getArea(), this.constant = this.normal.dot(this.midpoint), this;
2403
+ return ss.set(i.point, t.point, e.point), ss.getNormal(this.normal), ss.getMidpoint(this.midpoint), this.area = ss.getArea(), this.constant = this.normal.dot(this.midpoint), this;
2404
2404
  }
2405
2405
  distanceToPoint(i) {
2406
2406
  return this.normal.dot(i) - this.constant;
@@ -2558,24 +2558,24 @@ function qa(c) {
2558
2558
  N.elements[0] = T, N.elements[1] = p, N.elements[2] = m, N.elements[3] = p, N.elements[4] = F, N.elements[5] = R, N.elements[6] = m, N.elements[7] = R, N.elements[8] = S, ja(N, e);
2559
2559
  const y = e.unitary, M = new D.Vector3(), L = new D.Vector3(), b = new D.Vector3();
2560
2560
  y.extractBasis(M, L, b);
2561
- let G = -1 / 0, O = -1 / 0, w = -1 / 0, g = 1 / 0, v = 1 / 0, j = 1 / 0;
2561
+ let Y = -1 / 0, O = -1 / 0, w = -1 / 0, g = 1 / 0, v = 1 / 0, q = 1 / 0;
2562
2562
  for (let at = 0, It = i.length; at < It; at++) {
2563
2563
  const ft = i[at];
2564
- G = Math.max(M.dot(ft), G), O = Math.max(L.dot(ft), O), w = Math.max(b.dot(ft), w), g = Math.min(M.dot(ft), g), v = Math.min(L.dot(ft), v), j = Math.min(b.dot(ft), j);
2564
+ Y = Math.max(M.dot(ft), Y), O = Math.max(L.dot(ft), O), w = Math.max(b.dot(ft), w), g = Math.min(M.dot(ft), g), v = Math.min(L.dot(ft), v), q = Math.min(b.dot(ft), q);
2565
2565
  }
2566
- M.multiplyScalar(0.5 * (g + G)), L.multiplyScalar(0.5 * (v + O)), b.multiplyScalar(0.5 * (j + w));
2567
- const V = new D.Vector3(), et = new D.Vector3(), W = new D.Matrix3();
2568
- V.add(M).add(L).add(b), et.x = G - g, et.y = O - v, et.z = w - j, et.multiplyScalar(0.5), W.copy(y);
2569
- const { x: nt, y: Y, z: x } = et, ot = new D.Matrix4();
2570
- ot.makeScale(nt * 2, Y * 2, x * 2);
2566
+ M.multiplyScalar(0.5 * (g + Y)), L.multiplyScalar(0.5 * (v + O)), b.multiplyScalar(0.5 * (q + w));
2567
+ const G = new D.Vector3(), et = new D.Vector3(), W = new D.Matrix3();
2568
+ G.add(M).add(L).add(b), et.x = Y - g, et.y = O - v, et.z = w - q, et.multiplyScalar(0.5), W.copy(y);
2569
+ const { x: nt, y: V, z: x } = et, ot = new D.Matrix4();
2570
+ ot.makeScale(nt * 2, V * 2, x * 2);
2571
2571
  const it = new D.Matrix4();
2572
- it.makeTranslation(-nt, -Y, -x);
2572
+ it.makeTranslation(-nt, -V, -x);
2573
2573
  const tt = new D.Matrix4();
2574
- tt.makeTranslation(V.x, V.y, V.z);
2574
+ tt.makeTranslation(G.x, G.y, G.z);
2575
2575
  const St = new D.Matrix4();
2576
2576
  St.setFromMatrix3(W);
2577
2577
  const yt = new D.Matrix4();
2578
- return yt.multiply(tt), yt.multiply(St), yt.multiply(it), yt.multiply(ot), { center: V, halfSizes: et, rotation: W, transformation: yt };
2578
+ return yt.multiply(tt), yt.multiply(St), yt.multiply(it), yt.multiply(ot), { center: G, halfSizes: et, rotation: W, transformation: yt };
2579
2579
  }
2580
2580
  function Ch(c, i, t) {
2581
2581
  const e = [
@@ -2872,21 +2872,21 @@ class Th extends At {
2872
2872
  constructor(t, e) {
2873
2873
  super(t);
2874
2874
  /** {@link Disposable.onDisposed} */
2875
- C(this, "onDisposed", new Z());
2875
+ C(this, "onDisposed", new j());
2876
2876
  /**
2877
2877
  * An event that is triggered when a vertex is found.
2878
2878
  * The event passes a THREE.Vector3 representing the position of the found vertex.
2879
2879
  */
2880
- C(this, "onVertexFound", new Z());
2880
+ C(this, "onVertexFound", new j());
2881
2881
  /**
2882
2882
  * An event that is triggered when a vertex is lost.
2883
2883
  * The event passes a THREE.Vector3 representing the position of the lost vertex.
2884
2884
  */
2885
- C(this, "onVertexLost", new Z());
2885
+ C(this, "onVertexLost", new j());
2886
2886
  /**
2887
2887
  * An event that is triggered when the picker is enabled or disabled
2888
2888
  */
2889
- C(this, "onEnabled", new Z());
2889
+ C(this, "onEnabled", new j());
2890
2890
  /**
2891
2891
  * A reference to the Components instance associated with this VertexPicker.
2892
2892
  */
@@ -2977,7 +2977,7 @@ class Th extends At {
2977
2977
  get(t) {
2978
2978
  if (!this.enabled)
2979
2979
  return this._pickedPoint;
2980
- const n = this.components.get(ai).get(t).castRay();
2980
+ const n = this.components.get(ci).get(t).castRay();
2981
2981
  if (!n)
2982
2982
  return this._pickedPoint !== null && (this.onVertexLost.trigger(), this._pickedPoint = null), this._pickedPoint;
2983
2983
  const r = this.getClosestVertex(n);
@@ -3021,7 +3021,7 @@ class Th extends At {
3021
3021
  const Fs = class Fs {
3022
3022
  constructor() {
3023
3023
  /** {@link Disposable.onDisposed} */
3024
- C(this, "onDisposed", new Z());
3024
+ C(this, "onDisposed", new j());
3025
3025
  /**
3026
3026
  * The list of components created in this app.
3027
3027
  * The keys are UUIDs and the values are instances of the components.
@@ -3051,7 +3051,7 @@ const Fs = class Fs {
3051
3051
  * components.init();
3052
3052
  * ```
3053
3053
  */
3054
- C(this, "onInit", new Z());
3054
+ C(this, "onInit", new j());
3055
3055
  C(this, "update", () => {
3056
3056
  if (!this.enabled)
3057
3057
  return;
@@ -3137,7 +3137,7 @@ const Fs = class Fs {
3137
3137
  /**
3138
3138
  * The version of the @thatopen/components library.
3139
3139
  */
3140
- C(Fs, "release", "2.3.7");
3140
+ C(Fs, "release", "2.3.9");
3141
3141
  let Cs = Fs;
3142
3142
  class Qa extends xn {
3143
3143
  constructor() {
@@ -3147,11 +3147,11 @@ class Qa extends xn {
3147
3147
  */
3148
3148
  C(this, "meshes", /* @__PURE__ */ new Set());
3149
3149
  /** {@link Updateable.onAfterUpdate} */
3150
- C(this, "onAfterUpdate", new Z());
3150
+ C(this, "onAfterUpdate", new j());
3151
3151
  /** {@link Updateable.onBeforeUpdate} */
3152
- C(this, "onBeforeUpdate", new Z());
3152
+ C(this, "onBeforeUpdate", new j());
3153
3153
  /** {@link Disposable.onDisposed} */
3154
- C(this, "onDisposed", new Z());
3154
+ C(this, "onDisposed", new j());
3155
3155
  /**
3156
3156
  * Indicates whether the world is currently being disposed. This is useful to prevent trying to access world's elements when it's being disposed, which could cause errors when you dispose a world.
3157
3157
  */
@@ -3230,7 +3230,7 @@ class Qa extends xn {
3230
3230
  /** {@link Disposable.dispose} */
3231
3231
  dispose(t = !0) {
3232
3232
  if (this.enabled = !1, this.isDisposing = !0, this.scene.onWorldChanged.trigger({ world: this, action: "removed" }), this.camera.onWorldChanged.trigger({ world: this, action: "removed" }), this.renderer && this.renderer.onWorldChanged.trigger({ world: this, action: "removed" }), t) {
3233
- const s = this.components.get(Me);
3233
+ const s = this.components.get(De);
3234
3234
  this.scene.dispose(), this.camera.isDisposeable() && this.camera.dispose(), this.renderer && this.renderer.dispose();
3235
3235
  for (const n of this.meshes)
3236
3236
  s.destroy(n);
@@ -3239,12 +3239,12 @@ class Qa extends xn {
3239
3239
  this._scene = null, this._camera = null, this._renderer = null, this.components.get(Ts).list.delete(this.uuid), this.onDisposed.trigger(), this.onDisposed.reset();
3240
3240
  }
3241
3241
  }
3242
- class Ye {
3242
+ class Ge {
3243
3243
  constructor(i, t, e, s) {
3244
3244
  C(this, "_component");
3245
3245
  C(this, "name");
3246
3246
  C(this, "uuid");
3247
- this._component = i, this.name = e, this.uuid = s ?? oe.create(), t.get(Ve).list.set(this.uuid, this);
3247
+ this._component = i, this.name = e, this.uuid = s ?? oe.create(), t.get(Ye).list.set(this.uuid, this);
3248
3248
  }
3249
3249
  get controls() {
3250
3250
  const i = {};
@@ -3336,7 +3336,7 @@ const Ss = class Ss extends At {
3336
3336
  * This UUID is used to register the component within the Components system.
3337
3337
  */
3338
3338
  C(Ss, "uuid", "b8c764e0-6b24-4e77-9a32-35fa728ee5b4");
3339
- let Ve = Ss;
3339
+ let Ye = Ss;
3340
3340
  class Ka {
3341
3341
  constructor(i, t) {
3342
3342
  C(this, "_list");
@@ -3391,7 +3391,7 @@ class Ja {
3391
3391
  t.intensity = i;
3392
3392
  }
3393
3393
  }
3394
- class tc extends Ye {
3394
+ class tc extends Ge {
3395
3395
  constructor() {
3396
3396
  super(...arguments);
3397
3397
  C(this, "_config", {
@@ -3444,7 +3444,7 @@ class ec extends Ga {
3444
3444
  constructor(t) {
3445
3445
  super(t);
3446
3446
  /** {@link Configurable.onSetup} */
3447
- C(this, "onSetup", new Z());
3447
+ C(this, "onSetup", new j());
3448
3448
  /** {@link Configurable.isSetup} */
3449
3449
  C(this, "isSetup", !1);
3450
3450
  /**
@@ -3482,7 +3482,7 @@ class ec extends Ga {
3482
3482
  this.three.add(a, f), this.directionalLights.set(a.uuid, a), this.ambientLights.set(f.uuid, f), this.isSetup = !0, this.onSetup.trigger();
3483
3483
  }
3484
3484
  dispose() {
3485
- super.dispose(), this.components.get(Ve).list.delete(this.config.uuid);
3485
+ super.dispose(), this.components.get(Ye).list.delete(this.config.uuid);
3486
3486
  }
3487
3487
  }
3488
3488
  class mh extends Ya {
@@ -3511,7 +3511,7 @@ class mh extends Ya {
3511
3511
  C(this, "_canvas");
3512
3512
  C(this, "_parameters");
3513
3513
  C(this, "_resizeObserver", null);
3514
- C(this, "onContainerUpdated", new Z());
3514
+ C(this, "onContainerUpdated", new j());
3515
3515
  C(this, "_resizing", !1);
3516
3516
  /** {@link Resizeable.resize} */
3517
3517
  C(this, "resize", (t) => {
@@ -3607,18 +3607,18 @@ const ht = {
3607
3607
  TOUCH_ZOOM_TRUCK: 8192,
3608
3608
  TOUCH_ZOOM_OFFSET: 16384,
3609
3609
  TOUCH_ZOOM_ROTATE: 32768
3610
- }), Qe = {
3610
+ }), Ke = {
3611
3611
  NONE: 0,
3612
3612
  IN: 1,
3613
3613
  OUT: -1
3614
3614
  };
3615
- function be(c) {
3615
+ function ve(c) {
3616
3616
  return c.isPerspectiveCamera;
3617
3617
  }
3618
3618
  function Oe(c) {
3619
3619
  return c.isOrthographicCamera;
3620
3620
  }
3621
- const Ke = Math.PI * 2, Cr = Math.PI / 2, eo = 1e-5, mi = Math.PI / 180;
3621
+ const Je = Math.PI * 2, Cr = Math.PI / 2, eo = 1e-5, Ri = Math.PI / 180;
3622
3622
  function Jt(c, i, t) {
3623
3623
  return Math.max(i, Math.min(t, c));
3624
3624
  }
@@ -3631,13 +3631,13 @@ function pt(c, i, t = eo) {
3631
3631
  function Tr(c, i) {
3632
3632
  return Math.round(c / i) * i;
3633
3633
  }
3634
- function Ri(c) {
3634
+ function gi(c) {
3635
3635
  return isFinite(c) ? c : c < 0 ? -Number.MAX_VALUE : Number.MAX_VALUE;
3636
3636
  }
3637
- function gi(c) {
3637
+ function Ai(c) {
3638
3638
  return Math.abs(c) < Number.MAX_VALUE ? c : c * (1 / 0);
3639
3639
  }
3640
- function ss(c, i, t, e, s = 1 / 0, n) {
3640
+ function ns(c, i, t, e, s = 1 / 0, n) {
3641
3641
  e = Math.max(1e-4, e);
3642
3642
  const r = 2 / e, o = r * n, a = 1 / (1 + o + 0.48 * o * o + 0.235 * o * o * o);
3643
3643
  let l = c - i;
@@ -3660,8 +3660,8 @@ function mr(c, i, t, e, s = 1 / 0, n, r) {
3660
3660
  h = c.x - u, f = c.y - d, I = c.z - E;
3661
3661
  const N = (t.x + o * u) * n, y = (t.y + o * d) * n, M = (t.z + o * E) * n;
3662
3662
  t.x = (t.x - o * N) * l, t.y = (t.y - o * y) * l, t.z = (t.z - o * M) * l, r.x = h + (u + N) * l, r.y = f + (d + y) * l, r.z = I + (E + M) * l;
3663
- const L = T - c.x, b = p - c.y, G = m - c.z, O = r.x - T, w = r.y - p, g = r.z - m;
3664
- return L * O + b * w + G * g > 0 && (r.x = T, r.y = p, r.z = m, t.x = (r.x - T) / n, t.y = (r.y - p) / n, t.z = (r.z - m) / n), r;
3663
+ const L = T - c.x, b = p - c.y, Y = m - c.z, O = r.x - T, w = r.y - p, g = r.z - m;
3664
+ return L * O + b * w + Y * g > 0 && (r.x = T, r.y = p, r.z = m, t.x = (r.x - T) / n, t.y = (r.y - p) / n, t.z = (r.z - m) / n), r;
3665
3665
  }
3666
3666
  function rn(c, i) {
3667
3667
  i.set(0, 0), c.forEach((t) => {
@@ -3735,8 +3735,8 @@ class ic {
3735
3735
  }
3736
3736
  }
3737
3737
  }
3738
- const sc = "2.7.3", ns = 1 / 8, io = typeof window < "u", nc = io && /Mac/.test(navigator.platform), rc = !(io && "PointerEvent" in window);
3739
- let lt, Rr, rs, an, Yt, ut, Et, Je, Ai, le, he, ve, gr, Ar, Xt, Fi, ti, Fr, cn, Sr, ln, hn, os;
3738
+ const sc = "2.7.3", rs = 1 / 8, io = typeof window < "u", nc = io && /Mac/.test(navigator.platform), rc = !(io && "PointerEvent" in window);
3739
+ let lt, Rr, os, an, Yt, ut, Et, ti, Fi, le, he, Ue, gr, Ar, Xt, Si, ei, Fr, cn, Sr, ln, hn, as;
3740
3740
  class vt extends ic {
3741
3741
  /**
3742
3742
  * Injects THREE as the dependency. You can then proceed to use CameraControls.
@@ -3779,7 +3779,7 @@ class vt extends ic {
3779
3779
  * @category Statics
3780
3780
  */
3781
3781
  static install(i) {
3782
- lt = i.THREE, Rr = Object.freeze(new lt.Vector3(0, 0, 0)), rs = Object.freeze(new lt.Vector3(0, 1, 0)), an = Object.freeze(new lt.Vector3(0, 0, 1)), Yt = new lt.Vector2(), ut = new lt.Vector3(), Et = new lt.Vector3(), Je = new lt.Vector3(), Ai = new lt.Vector3(), le = new lt.Vector3(), he = new lt.Vector3(), ve = new lt.Vector3(), gr = new lt.Vector3(), Ar = new lt.Vector3(), Xt = new lt.Spherical(), Fi = new lt.Spherical(), ti = new lt.Box3(), Fr = new lt.Box3(), cn = new lt.Sphere(), Sr = new lt.Quaternion(), ln = new lt.Quaternion(), hn = new lt.Matrix4(), os = new lt.Raycaster();
3782
+ lt = i.THREE, Rr = Object.freeze(new lt.Vector3(0, 0, 0)), os = Object.freeze(new lt.Vector3(0, 1, 0)), an = Object.freeze(new lt.Vector3(0, 0, 1)), Yt = new lt.Vector2(), ut = new lt.Vector3(), Et = new lt.Vector3(), ti = new lt.Vector3(), Fi = new lt.Vector3(), le = new lt.Vector3(), he = new lt.Vector3(), Ue = new lt.Vector3(), gr = new lt.Vector3(), Ar = new lt.Vector3(), Xt = new lt.Spherical(), Si = new lt.Spherical(), ei = new lt.Box3(), Fr = new lt.Box3(), cn = new lt.Sphere(), Sr = new lt.Quaternion(), ln = new lt.Quaternion(), hn = new lt.Matrix4(), as = new lt.Raycaster();
3783
3783
  }
3784
3784
  /**
3785
3785
  * list all ACTIONs
@@ -3807,11 +3807,11 @@ class vt extends ic {
3807
3807
  */
3808
3808
  constructor(i, t) {
3809
3809
  super(), this.minPolarAngle = 0, this.maxPolarAngle = Math.PI, this.minAzimuthAngle = -1 / 0, this.maxAzimuthAngle = 1 / 0, this.minDistance = Number.EPSILON, this.maxDistance = 1 / 0, this.infinityDolly = !1, this.minZoom = 0.01, this.maxZoom = 1 / 0, this.smoothTime = 0.25, this.draggingSmoothTime = 0.125, this.maxSpeed = 1 / 0, this.azimuthRotateSpeed = 1, this.polarRotateSpeed = 1, this.dollySpeed = 1, this.dollyDragInverted = !1, this.truckSpeed = 2, this.dollyToCursor = !1, this.dragToOffset = !1, this.verticalDragToForward = !1, this.boundaryFriction = 0, this.restThreshold = 0.01, this.colliderMeshes = [], this.cancel = () => {
3810
- }, this._enabled = !0, this._state = H.NONE, this._viewport = null, this._changedDolly = 0, this._changedZoom = 0, this._hasRested = !0, this._boundaryEnclosesCamera = !1, this._needsUpdate = !0, this._updatedLastTime = !1, this._elementRect = new DOMRect(), this._isDragging = !1, this._dragNeedsUpdate = !0, this._activePointers = [], this._lockedPointer = null, this._interactiveArea = new DOMRect(0, 0, 1, 1), this._isUserControllingRotate = !1, this._isUserControllingDolly = !1, this._isUserControllingTruck = !1, this._isUserControllingOffset = !1, this._isUserControllingZoom = !1, this._lastDollyDirection = Qe.NONE, this._thetaVelocity = { value: 0 }, this._phiVelocity = { value: 0 }, this._radiusVelocity = { value: 0 }, this._targetVelocity = new lt.Vector3(), this._focalOffsetVelocity = new lt.Vector3(), this._zoomVelocity = { value: 0 }, this._truckInternal = (R, S, N) => {
3810
+ }, this._enabled = !0, this._state = H.NONE, this._viewport = null, this._changedDolly = 0, this._changedZoom = 0, this._hasRested = !0, this._boundaryEnclosesCamera = !1, this._needsUpdate = !0, this._updatedLastTime = !1, this._elementRect = new DOMRect(), this._isDragging = !1, this._dragNeedsUpdate = !0, this._activePointers = [], this._lockedPointer = null, this._interactiveArea = new DOMRect(0, 0, 1, 1), this._isUserControllingRotate = !1, this._isUserControllingDolly = !1, this._isUserControllingTruck = !1, this._isUserControllingOffset = !1, this._isUserControllingZoom = !1, this._lastDollyDirection = Ke.NONE, this._thetaVelocity = { value: 0 }, this._phiVelocity = { value: 0 }, this._radiusVelocity = { value: 0 }, this._targetVelocity = new lt.Vector3(), this._focalOffsetVelocity = new lt.Vector3(), this._zoomVelocity = { value: 0 }, this._truckInternal = (R, S, N) => {
3811
3811
  let y, M;
3812
- if (be(this._camera)) {
3813
- const L = ut.copy(this._camera.position).sub(this._target), b = this._camera.getEffectiveFOV() * mi, G = L.length() * Math.tan(b * 0.5);
3814
- y = this.truckSpeed * R * G / this._elementRect.height, M = this.truckSpeed * S * G / this._elementRect.height;
3812
+ if (ve(this._camera)) {
3813
+ const L = ut.copy(this._camera.position).sub(this._target), b = this._camera.getEffectiveFOV() * Ri, Y = L.length() * Math.tan(b * 0.5);
3814
+ y = this.truckSpeed * R * Y / this._elementRect.height, M = this.truckSpeed * S * Y / this._elementRect.height;
3815
3815
  } else if (Oe(this._camera)) {
3816
3816
  const L = this._camera;
3817
3817
  y = R * (L.right - L.left) / L.zoom / this._elementRect.width, M = S * (L.top - L.bottom) / L.zoom / this._elementRect.height;
@@ -3819,15 +3819,15 @@ class vt extends ic {
3819
3819
  return;
3820
3820
  this.verticalDragToForward ? (N ? this.setFocalOffset(this._focalOffsetEnd.x + y, this._focalOffsetEnd.y, this._focalOffsetEnd.z, !0) : this.truck(y, 0, !0), this.forward(-M, !0)) : N ? this.setFocalOffset(this._focalOffsetEnd.x + y, this._focalOffsetEnd.y + M, this._focalOffsetEnd.z, !0) : this.truck(y, M, !0);
3821
3821
  }, this._rotateInternal = (R, S) => {
3822
- const N = Ke * this.azimuthRotateSpeed * R / this._elementRect.height, y = Ke * this.polarRotateSpeed * S / this._elementRect.height;
3822
+ const N = Je * this.azimuthRotateSpeed * R / this._elementRect.height, y = Je * this.polarRotateSpeed * S / this._elementRect.height;
3823
3823
  this.rotate(N, y, !0);
3824
3824
  }, this._dollyInternal = (R, S, N) => {
3825
- const y = Math.pow(0.95, -R * this.dollySpeed), M = this._sphericalEnd.radius, L = this._sphericalEnd.radius * y, b = Jt(L, this.minDistance, this.maxDistance), G = b - L;
3826
- this.infinityDolly && this.dollyToCursor ? this._dollyToNoClamp(L, !0) : this.infinityDolly && !this.dollyToCursor ? (this.dollyInFixed(G, !0), this._dollyToNoClamp(b, !0)) : this._dollyToNoClamp(b, !0), this.dollyToCursor && (this._changedDolly += (this.infinityDolly ? L : b) - M, this._dollyControlCoord.set(S, N)), this._lastDollyDirection = Math.sign(-R);
3825
+ const y = Math.pow(0.95, -R * this.dollySpeed), M = this._sphericalEnd.radius, L = this._sphericalEnd.radius * y, b = Jt(L, this.minDistance, this.maxDistance), Y = b - L;
3826
+ this.infinityDolly && this.dollyToCursor ? this._dollyToNoClamp(L, !0) : this.infinityDolly && !this.dollyToCursor ? (this.dollyInFixed(Y, !0), this._dollyToNoClamp(b, !0)) : this._dollyToNoClamp(b, !0), this.dollyToCursor && (this._changedDolly += (this.infinityDolly ? L : b) - M, this._dollyControlCoord.set(S, N)), this._lastDollyDirection = Math.sign(-R);
3827
3827
  }, this._zoomInternal = (R, S, N) => {
3828
3828
  const y = Math.pow(0.95, R * this.dollySpeed), M = this._zoom, L = this._zoom * y;
3829
3829
  this.zoomTo(L, !0), this.dollyToCursor && (this._changedZoom += L - M, this._dollyControlCoord.set(S, N));
3830
- }, typeof lt > "u" && console.error("camera-controls: `THREE` is undefined. You must first run `CameraControls.install( { THREE: THREE } )`. Check the docs for further information."), this._camera = i, this._yAxisUpSpace = new lt.Quaternion().setFromUnitVectors(this._camera.up, rs), this._yAxisUpSpaceInverse = this._yAxisUpSpace.clone().invert(), this._state = H.NONE, this._target = new lt.Vector3(), this._targetEnd = this._target.clone(), this._focalOffset = new lt.Vector3(), this._focalOffsetEnd = this._focalOffset.clone(), this._spherical = new lt.Spherical().setFromVector3(ut.copy(this._camera.position).applyQuaternion(this._yAxisUpSpace)), this._sphericalEnd = this._spherical.clone(), this._lastDistance = this._spherical.radius, this._zoom = this._camera.zoom, this._zoomEnd = this._zoom, this._lastZoom = this._zoom, this._nearPlaneCorners = [
3830
+ }, typeof lt > "u" && console.error("camera-controls: `THREE` is undefined. You must first run `CameraControls.install( { THREE: THREE } )`. Check the docs for further information."), this._camera = i, this._yAxisUpSpace = new lt.Quaternion().setFromUnitVectors(this._camera.up, os), this._yAxisUpSpaceInverse = this._yAxisUpSpace.clone().invert(), this._state = H.NONE, this._target = new lt.Vector3(), this._targetEnd = this._target.clone(), this._focalOffset = new lt.Vector3(), this._focalOffsetEnd = this._focalOffset.clone(), this._spherical = new lt.Spherical().setFromVector3(ut.copy(this._camera.position).applyQuaternion(this._yAxisUpSpace)), this._sphericalEnd = this._spherical.clone(), this._lastDistance = this._spherical.radius, this._zoom = this._camera.zoom, this._zoomEnd = this._zoom, this._lastZoom = this._zoom, this._nearPlaneCorners = [
3831
3831
  new lt.Vector3(),
3832
3832
  new lt.Vector3(),
3833
3833
  new lt.Vector3(),
@@ -3836,10 +3836,10 @@ class vt extends ic {
3836
3836
  left: H.ROTATE,
3837
3837
  middle: H.DOLLY,
3838
3838
  right: H.TRUCK,
3839
- wheel: be(this._camera) ? H.DOLLY : Oe(this._camera) ? H.ZOOM : H.NONE
3839
+ wheel: ve(this._camera) ? H.DOLLY : Oe(this._camera) ? H.ZOOM : H.NONE
3840
3840
  }, this.touches = {
3841
3841
  one: H.TOUCH_ROTATE,
3842
- two: be(this._camera) ? H.TOUCH_DOLLY_TRUCK : Oe(this._camera) ? H.TOUCH_ZOOM_TRUCK : H.NONE,
3842
+ two: ve(this._camera) ? H.TOUCH_DOLLY_TRUCK : Oe(this._camera) ? H.TOUCH_ZOOM_TRUCK : H.NONE,
3843
3843
  three: H.TOUCH_TRUCK
3844
3844
  };
3845
3845
  const e = new lt.Vector2(), s = new lt.Vector2(), n = new lt.Vector2(), r = (R) => {
@@ -3942,8 +3942,8 @@ class vt extends ic {
3942
3942
  if (!this._domElement || !this._enabled || this.mouseButtons.wheel === H.NONE)
3943
3943
  return;
3944
3944
  if (this._interactiveArea.left !== 0 || this._interactiveArea.top !== 0 || this._interactiveArea.width !== 1 || this._interactiveArea.height !== 1) {
3945
- const L = this._domElement.getBoundingClientRect(), b = R.clientX / L.width, G = R.clientY / L.height;
3946
- if (b < this._interactiveArea.left || b > this._interactiveArea.right || G < this._interactiveArea.top || G > this._interactiveArea.bottom)
3945
+ const L = this._domElement.getBoundingClientRect(), b = R.clientX / L.width, Y = R.clientY / L.height;
3946
+ if (b < this._interactiveArea.left || b > this._interactiveArea.right || Y < this._interactiveArea.top || Y > this._interactiveArea.bottom)
3947
3947
  return;
3948
3948
  }
3949
3949
  if (R.preventDefault(), this.dollyToCursor || this.mouseButtons.wheel === H.ROTATE || this.mouseButtons.wheel === H.TRUCK) {
@@ -4016,13 +4016,13 @@ class vt extends ic {
4016
4016
  const S = this._domElement && document.pointerLockElement === this._domElement ? this._lockedPointer || this._activePointers[0] : null, N = S ? -S.deltaX : s.x - Yt.x, y = S ? -S.deltaY : s.y - Yt.y;
4017
4017
  if (s.copy(Yt), ((this._state & H.ROTATE) === H.ROTATE || (this._state & H.TOUCH_ROTATE) === H.TOUCH_ROTATE || (this._state & H.TOUCH_DOLLY_ROTATE) === H.TOUCH_DOLLY_ROTATE || (this._state & H.TOUCH_ZOOM_ROTATE) === H.TOUCH_ZOOM_ROTATE) && (this._rotateInternal(N, y), this._isUserControllingRotate = !0), (this._state & H.DOLLY) === H.DOLLY || (this._state & H.ZOOM) === H.ZOOM) {
4018
4018
  const M = this.dollyToCursor ? (e.x - this._elementRect.x) / this._elementRect.width * 2 - 1 : 0, L = this.dollyToCursor ? (e.y - this._elementRect.y) / this._elementRect.height * -2 + 1 : 0, b = this.dollyDragInverted ? -1 : 1;
4019
- (this._state & H.DOLLY) === H.DOLLY ? (this._dollyInternal(b * y * ns, M, L), this._isUserControllingDolly = !0) : (this._zoomInternal(b * y * ns, M, L), this._isUserControllingZoom = !0);
4019
+ (this._state & H.DOLLY) === H.DOLLY ? (this._dollyInternal(b * y * rs, M, L), this._isUserControllingDolly = !0) : (this._zoomInternal(b * y * rs, M, L), this._isUserControllingZoom = !0);
4020
4020
  }
4021
4021
  if ((this._state & H.TOUCH_DOLLY) === H.TOUCH_DOLLY || (this._state & H.TOUCH_ZOOM) === H.TOUCH_ZOOM || (this._state & H.TOUCH_DOLLY_TRUCK) === H.TOUCH_DOLLY_TRUCK || (this._state & H.TOUCH_ZOOM_TRUCK) === H.TOUCH_ZOOM_TRUCK || (this._state & H.TOUCH_DOLLY_OFFSET) === H.TOUCH_DOLLY_OFFSET || (this._state & H.TOUCH_ZOOM_OFFSET) === H.TOUCH_ZOOM_OFFSET || (this._state & H.TOUCH_DOLLY_ROTATE) === H.TOUCH_DOLLY_ROTATE || (this._state & H.TOUCH_ZOOM_ROTATE) === H.TOUCH_ZOOM_ROTATE) {
4022
- const M = Yt.x - this._activePointers[1].clientX, L = Yt.y - this._activePointers[1].clientY, b = Math.sqrt(M * M + L * L), G = n.y - b;
4022
+ const M = Yt.x - this._activePointers[1].clientX, L = Yt.y - this._activePointers[1].clientY, b = Math.sqrt(M * M + L * L), Y = n.y - b;
4023
4023
  n.set(0, b);
4024
4024
  const O = this.dollyToCursor ? (s.x - this._elementRect.x) / this._elementRect.width * 2 - 1 : 0, w = this.dollyToCursor ? (s.y - this._elementRect.y) / this._elementRect.height * -2 + 1 : 0;
4025
- (this._state & H.TOUCH_DOLLY) === H.TOUCH_DOLLY || (this._state & H.TOUCH_DOLLY_ROTATE) === H.TOUCH_DOLLY_ROTATE || (this._state & H.TOUCH_DOLLY_TRUCK) === H.TOUCH_DOLLY_TRUCK || (this._state & H.TOUCH_DOLLY_OFFSET) === H.TOUCH_DOLLY_OFFSET ? (this._dollyInternal(G * ns, O, w), this._isUserControllingDolly = !0) : (this._zoomInternal(G * ns, O, w), this._isUserControllingZoom = !0);
4025
+ (this._state & H.TOUCH_DOLLY) === H.TOUCH_DOLLY || (this._state & H.TOUCH_DOLLY_ROTATE) === H.TOUCH_DOLLY_ROTATE || (this._state & H.TOUCH_DOLLY_TRUCK) === H.TOUCH_DOLLY_TRUCK || (this._state & H.TOUCH_DOLLY_OFFSET) === H.TOUCH_DOLLY_OFFSET ? (this._dollyInternal(Y * rs, O, w), this._isUserControllingDolly = !0) : (this._zoomInternal(Y * rs, O, w), this._isUserControllingZoom = !0);
4026
4026
  }
4027
4027
  ((this._state & H.TRUCK) === H.TRUCK || (this._state & H.TOUCH_TRUCK) === H.TOUCH_TRUCK || (this._state & H.TOUCH_DOLLY_TRUCK) === H.TOUCH_DOLLY_TRUCK || (this._state & H.TOUCH_ZOOM_TRUCK) === H.TOUCH_ZOOM_TRUCK) && (this._truckInternal(N, y, !1), this._isUserControllingTruck = !0), ((this._state & H.OFFSET) === H.OFFSET || (this._state & H.TOUCH_OFFSET) === H.TOUCH_OFFSET || (this._state & H.TOUCH_DOLLY_OFFSET) === H.TOUCH_DOLLY_OFFSET || (this._state & H.TOUCH_ZOOM_OFFSET) === H.TOUCH_ZOOM_OFFSET) && (this._truckInternal(N, y, !0), this._isUserControllingOffset = !0), this.dispatchEvent({ type: "control" });
4028
4028
  }, p = () => {
@@ -4283,7 +4283,7 @@ class vt extends ic {
4283
4283
  * @category Methods
4284
4284
  */
4285
4285
  dollyTo(i, t = !1) {
4286
- return this._isUserControllingDolly = !1, this._lastDollyDirection = Qe.NONE, this._changedDolly = 0, this._dollyToNoClamp(Jt(i, this.minDistance, this.maxDistance), t);
4286
+ return this._isUserControllingDolly = !1, this._lastDollyDirection = Ke.NONE, this._changedDolly = 0, this._dollyToNoClamp(Jt(i, this.minDistance, this.maxDistance), t);
4287
4287
  }
4288
4288
  _dollyToNoClamp(i, t = !1) {
4289
4289
  const e = this._sphericalEnd.radius;
@@ -4306,7 +4306,7 @@ class vt extends ic {
4306
4306
  * @category Methods
4307
4307
  */
4308
4308
  dollyInFixed(i, t = !1) {
4309
- this._targetEnd.add(this._getCameraDirection(Ai).multiplyScalar(i)), t || this._target.copy(this._targetEnd);
4309
+ this._targetEnd.add(this._getCameraDirection(Fi).multiplyScalar(i)), t || this._target.copy(this._targetEnd);
4310
4310
  const e = !t || pt(this._target.x, this._targetEnd.x, this.restThreshold) && pt(this._target.y, this._targetEnd.y, this.restThreshold) && pt(this._target.z, this._targetEnd.z, this.restThreshold);
4311
4311
  return this._createOnRestPromise(e);
4312
4312
  }
@@ -4413,16 +4413,16 @@ class vt extends ic {
4413
4413
  * @category Methods
4414
4414
  */
4415
4415
  fitToBox(i, t, { cover: e = !1, paddingLeft: s = 0, paddingRight: n = 0, paddingBottom: r = 0, paddingTop: o = 0 } = {}) {
4416
- const a = [], l = i.isBox3 ? ti.copy(i) : ti.setFromObject(i);
4416
+ const a = [], l = i.isBox3 ? ei.copy(i) : ei.setFromObject(i);
4417
4417
  l.isEmpty() && (console.warn("camera-controls: fitTo() cannot be used with an empty box. Aborting"), Promise.resolve());
4418
4418
  const h = Tr(this._sphericalEnd.theta, Cr), f = Tr(this._sphericalEnd.phi, Cr);
4419
4419
  a.push(this.rotateTo(h, f, t));
4420
4420
  const I = ut.setFromSpherical(this._sphericalEnd).normalize(), u = Sr.setFromUnitVectors(I, an), d = pt(Math.abs(I.y), 1);
4421
- d && u.multiply(ln.setFromAxisAngle(rs, h)), u.multiply(this._yAxisUpSpaceInverse);
4421
+ d && u.multiply(ln.setFromAxisAngle(os, h)), u.multiply(this._yAxisUpSpaceInverse);
4422
4422
  const E = Fr.makeEmpty();
4423
4423
  Et.copy(l.min).applyQuaternion(u), E.expandByPoint(Et), Et.copy(l.min).setX(l.max.x).applyQuaternion(u), E.expandByPoint(Et), Et.copy(l.min).setY(l.max.y).applyQuaternion(u), E.expandByPoint(Et), Et.copy(l.max).setZ(l.min.z).applyQuaternion(u), E.expandByPoint(Et), Et.copy(l.min).setZ(l.max.z).applyQuaternion(u), E.expandByPoint(Et), Et.copy(l.max).setY(l.min.y).applyQuaternion(u), E.expandByPoint(Et), Et.copy(l.max).setX(l.min.x).applyQuaternion(u), E.expandByPoint(Et), Et.copy(l.max).applyQuaternion(u), E.expandByPoint(Et), E.min.x -= s, E.min.y -= r, E.max.x += n, E.max.y += o, u.setFromUnitVectors(an, I), d && u.premultiply(ln.invert()), u.premultiply(this._yAxisUpSpace);
4424
4424
  const T = E.getSize(ut), p = E.getCenter(Et).applyQuaternion(u);
4425
- if (be(this._camera)) {
4425
+ if (ve(this._camera)) {
4426
4426
  const m = this.getDistanceToFitBox(T.x, T.y, T.z, e);
4427
4427
  a.push(this.moveTo(p.x, p.y, p.z, t)), a.push(this.dollyTo(m, t)), a.push(this.setFocalOffset(0, 0, 0, t));
4428
4428
  } else if (Oe(this._camera)) {
@@ -4439,7 +4439,7 @@ class vt extends ic {
4439
4439
  */
4440
4440
  fitToSphere(i, t) {
4441
4441
  const e = [], n = i instanceof lt.Sphere ? cn.copy(i) : vt.createBoundingSphere(i, cn);
4442
- if (e.push(this.moveTo(n.center.x, n.center.y, n.center.z, t)), be(this._camera)) {
4442
+ if (e.push(this.moveTo(n.center.x, n.center.y, n.center.z, t)), ve(this._camera)) {
4443
4443
  const r = this.getDistanceToFitSphere(n.radius);
4444
4444
  e.push(this.dollyTo(r, t));
4445
4445
  } else if (Oe(this._camera)) {
@@ -4460,7 +4460,7 @@ class vt extends ic {
4460
4460
  * @category Methods
4461
4461
  */
4462
4462
  setLookAt(i, t, e, s, n, r, o = !1) {
4463
- this._isUserControllingRotate = !1, this._isUserControllingDolly = !1, this._isUserControllingTruck = !1, this._lastDollyDirection = Qe.NONE, this._changedDolly = 0;
4463
+ this._isUserControllingRotate = !1, this._isUserControllingDolly = !1, this._isUserControllingTruck = !1, this._lastDollyDirection = Ke.NONE, this._changedDolly = 0;
4464
4464
  const a = Et.set(s, n, r), l = ut.set(i, t, e);
4465
4465
  this._targetEnd.copy(a), this._sphericalEnd.setFromVector3(l.sub(a).applyQuaternion(this._yAxisUpSpace)), this.normalizeRotations(), this._needsUpdate = !0, o || (this._target.copy(this._targetEnd), this._spherical.copy(this._sphericalEnd));
4466
4466
  const h = !o || pt(this._target.x, this._targetEnd.x, this.restThreshold) && pt(this._target.y, this._targetEnd.y, this.restThreshold) && pt(this._target.z, this._targetEnd.z, this.restThreshold) && pt(this._spherical.theta, this._sphericalEnd.theta, this.restThreshold) && pt(this._spherical.phi, this._sphericalEnd.phi, this.restThreshold) && pt(this._spherical.radius, this._sphericalEnd.radius, this.restThreshold);
@@ -4485,12 +4485,12 @@ class vt extends ic {
4485
4485
  * @category Methods
4486
4486
  */
4487
4487
  lerpLookAt(i, t, e, s, n, r, o, a, l, h, f, I, u, d = !1) {
4488
- this._isUserControllingRotate = !1, this._isUserControllingDolly = !1, this._isUserControllingTruck = !1, this._lastDollyDirection = Qe.NONE, this._changedDolly = 0;
4488
+ this._isUserControllingRotate = !1, this._isUserControllingDolly = !1, this._isUserControllingTruck = !1, this._lastDollyDirection = Ke.NONE, this._changedDolly = 0;
4489
4489
  const E = ut.set(s, n, r), T = Et.set(i, t, e);
4490
4490
  Xt.setFromVector3(T.sub(E).applyQuaternion(this._yAxisUpSpace));
4491
- const p = Je.set(h, f, I), m = Et.set(o, a, l);
4492
- Fi.setFromVector3(m.sub(p).applyQuaternion(this._yAxisUpSpace)), this._targetEnd.copy(E.lerp(p, u));
4493
- const F = Fi.theta - Xt.theta, R = Fi.phi - Xt.phi, S = Fi.radius - Xt.radius;
4491
+ const p = ti.set(h, f, I), m = Et.set(o, a, l);
4492
+ Si.setFromVector3(m.sub(p).applyQuaternion(this._yAxisUpSpace)), this._targetEnd.copy(E.lerp(p, u));
4493
+ const F = Si.theta - Xt.theta, R = Si.phi - Xt.phi, S = Si.radius - Xt.radius;
4494
4494
  this._sphericalEnd.set(Xt.radius + S * u, Xt.phi + R * u, Xt.theta + F * u), this.normalizeRotations(), this._needsUpdate = !0, d || (this._target.copy(this._targetEnd), this._spherical.copy(this._sphericalEnd));
4495
4495
  const N = !d || pt(this._target.x, this._targetEnd.x, this.restThreshold) && pt(this._target.y, this._targetEnd.y, this.restThreshold) && pt(this._target.z, this._targetEnd.z, this.restThreshold) && pt(this._spherical.theta, this._sphericalEnd.theta, this.restThreshold) && pt(this._spherical.phi, this._sphericalEnd.phi, this.restThreshold) && pt(this._spherical.radius, this._sphericalEnd.radius, this.restThreshold);
4496
4496
  return this._createOnRestPromise(N);
@@ -4542,9 +4542,9 @@ class vt extends ic {
4542
4542
  * @category Methods
4543
4543
  */
4544
4544
  setOrbitPoint(i, t, e) {
4545
- this._camera.updateMatrixWorld(), le.setFromMatrixColumn(this._camera.matrixWorldInverse, 0), he.setFromMatrixColumn(this._camera.matrixWorldInverse, 1), ve.setFromMatrixColumn(this._camera.matrixWorldInverse, 2);
4545
+ this._camera.updateMatrixWorld(), le.setFromMatrixColumn(this._camera.matrixWorldInverse, 0), he.setFromMatrixColumn(this._camera.matrixWorldInverse, 1), Ue.setFromMatrixColumn(this._camera.matrixWorldInverse, 2);
4546
4546
  const s = ut.set(i, t, e), n = s.distanceTo(this._camera.position), r = s.sub(this._camera.position);
4547
- le.multiplyScalar(r.x), he.multiplyScalar(r.y), ve.multiplyScalar(r.z), ut.copy(le).add(he).add(ve), ut.z = ut.z + n, this.dollyTo(n, !1), this.setFocalOffset(-ut.x, ut.y, -ut.z, !1), this.moveTo(i, t, e, !1);
4547
+ le.multiplyScalar(r.x), he.multiplyScalar(r.y), Ue.multiplyScalar(r.z), ut.copy(le).add(he).add(Ue), ut.z = ut.z + n, this.dollyTo(n, !1), this.setFocalOffset(-ut.x, ut.y, -ut.z, !1), this.moveTo(i, t, e, !1);
4548
4548
  }
4549
4549
  /**
4550
4550
  * Set the boundary box that encloses the target of the camera. box3 is in THREE.Box3
@@ -4585,7 +4585,7 @@ class vt extends ic {
4585
4585
  getDistanceToFitBox(i, t, e, s = !1) {
4586
4586
  if (on(this._camera, "getDistanceToFitBox"))
4587
4587
  return this._spherical.radius;
4588
- const n = i / t, r = this._camera.getEffectiveFOV() * mi, o = this._camera.aspect;
4588
+ const n = i / t, r = this._camera.getEffectiveFOV() * Ri, o = this._camera.aspect;
4589
4589
  return ((s ? n > o : n < o) ? t : i / o) * 0.5 / Math.tan(r * 0.5) + e * 0.5;
4590
4590
  }
4591
4591
  /**
@@ -4597,7 +4597,7 @@ class vt extends ic {
4597
4597
  getDistanceToFitSphere(i) {
4598
4598
  if (on(this._camera, "getDistanceToFitSphere"))
4599
4599
  return this._spherical.radius;
4600
- const t = this._camera.getEffectiveFOV() * mi, e = Math.atan(Math.tan(t * 0.5) * this._camera.aspect) * 2, s = 1 < this._camera.aspect ? t : e;
4600
+ const t = this._camera.getEffectiveFOV() * Ri, e = Math.atan(Math.tan(t * 0.5) * this._camera.aspect) * 2, s = 1 < this._camera.aspect ? t : e;
4601
4601
  return i / Math.sin(s * 0.5);
4602
4602
  }
4603
4603
  /**
@@ -4641,7 +4641,7 @@ class vt extends ic {
4641
4641
  * @category Methods
4642
4642
  */
4643
4643
  normalizeRotations() {
4644
- this._sphericalEnd.theta = this._sphericalEnd.theta % Ke, this._sphericalEnd.theta < 0 && (this._sphericalEnd.theta += Ke), this._spherical.theta += Ke * Math.round((this._sphericalEnd.theta - this._spherical.theta) / Ke);
4644
+ this._sphericalEnd.theta = this._sphericalEnd.theta % Je, this._sphericalEnd.theta < 0 && (this._sphericalEnd.theta += Je), this._spherical.theta += Je * Math.round((this._sphericalEnd.theta - this._spherical.theta) / Je);
4645
4645
  }
4646
4646
  /**
4647
4647
  * Reset all rotation and position to defaults.
@@ -4674,7 +4674,7 @@ class vt extends ic {
4674
4674
  * @category Methods
4675
4675
  */
4676
4676
  updateCameraUp() {
4677
- this._yAxisUpSpace.setFromUnitVectors(this._camera.up, rs), this._yAxisUpSpaceInverse.copy(this._yAxisUpSpace).invert();
4677
+ this._yAxisUpSpace.setFromUnitVectors(this._camera.up, os), this._yAxisUpSpaceInverse.copy(this._yAxisUpSpace).invert();
4678
4678
  }
4679
4679
  /**
4680
4680
  * Apply current camera-up direction to the camera.
@@ -4700,19 +4700,19 @@ class vt extends ic {
4700
4700
  this._thetaVelocity.value = 0, this._spherical.theta = this._sphericalEnd.theta;
4701
4701
  else {
4702
4702
  const f = this._isUserControllingRotate ? this.draggingSmoothTime : this.smoothTime;
4703
- this._spherical.theta = ss(this._spherical.theta, this._sphericalEnd.theta, this._thetaVelocity, f, 1 / 0, i), this._needsUpdate = !0;
4703
+ this._spherical.theta = ns(this._spherical.theta, this._sphericalEnd.theta, this._thetaVelocity, f, 1 / 0, i), this._needsUpdate = !0;
4704
4704
  }
4705
4705
  if (gt(e))
4706
4706
  this._phiVelocity.value = 0, this._spherical.phi = this._sphericalEnd.phi;
4707
4707
  else {
4708
4708
  const f = this._isUserControllingRotate ? this.draggingSmoothTime : this.smoothTime;
4709
- this._spherical.phi = ss(this._spherical.phi, this._sphericalEnd.phi, this._phiVelocity, f, 1 / 0, i), this._needsUpdate = !0;
4709
+ this._spherical.phi = ns(this._spherical.phi, this._sphericalEnd.phi, this._phiVelocity, f, 1 / 0, i), this._needsUpdate = !0;
4710
4710
  }
4711
4711
  if (gt(s))
4712
4712
  this._radiusVelocity.value = 0, this._spherical.radius = this._sphericalEnd.radius;
4713
4713
  else {
4714
4714
  const f = this._isUserControllingDolly ? this.draggingSmoothTime : this.smoothTime;
4715
- this._spherical.radius = ss(this._spherical.radius, this._sphericalEnd.radius, this._radiusVelocity, f, this.maxSpeed, i), this._needsUpdate = !0;
4715
+ this._spherical.radius = ns(this._spherical.radius, this._sphericalEnd.radius, this._radiusVelocity, f, this.maxSpeed, i), this._needsUpdate = !0;
4716
4716
  }
4717
4717
  if (gt(n.x) && gt(n.y) && gt(n.z))
4718
4718
  this._targetVelocity.set(0, 0, 0), this._target.copy(this._targetEnd);
@@ -4730,13 +4730,13 @@ class vt extends ic {
4730
4730
  this._zoomVelocity.value = 0, this._zoom = this._zoomEnd;
4731
4731
  else {
4732
4732
  const f = this._isUserControllingZoom ? this.draggingSmoothTime : this.smoothTime;
4733
- this._zoom = ss(this._zoom, this._zoomEnd, this._zoomVelocity, f, 1 / 0, i);
4733
+ this._zoom = ns(this._zoom, this._zoomEnd, this._zoomVelocity, f, 1 / 0, i);
4734
4734
  }
4735
4735
  if (this.dollyToCursor) {
4736
- if (be(this._camera) && this._changedDolly !== 0) {
4737
- const f = this._spherical.radius - this._lastDistance, I = this._camera, u = this._getCameraDirection(Ai), d = ut.copy(u).cross(I.up).normalize();
4736
+ if (ve(this._camera) && this._changedDolly !== 0) {
4737
+ const f = this._spherical.radius - this._lastDistance, I = this._camera, u = this._getCameraDirection(Fi), d = ut.copy(u).cross(I.up).normalize();
4738
4738
  d.lengthSq() === 0 && (d.x = 1);
4739
- const E = Et.crossVectors(d, u), T = this._sphericalEnd.radius * Math.tan(I.getEffectiveFOV() * mi * 0.5), m = (this._sphericalEnd.radius - f - this._sphericalEnd.radius) / this._sphericalEnd.radius, F = Je.copy(this._targetEnd).add(d.multiplyScalar(this._dollyControlCoord.x * T * I.aspect)).add(E.multiplyScalar(this._dollyControlCoord.y * T)), R = ut.copy(this._targetEnd).lerp(F, m), S = this._lastDollyDirection === Qe.IN && this._spherical.radius <= this.minDistance, N = this._lastDollyDirection === Qe.OUT && this.maxDistance <= this._spherical.radius;
4739
+ const E = Et.crossVectors(d, u), T = this._sphericalEnd.radius * Math.tan(I.getEffectiveFOV() * Ri * 0.5), m = (this._sphericalEnd.radius - f - this._sphericalEnd.radius) / this._sphericalEnd.radius, F = ti.copy(this._targetEnd).add(d.multiplyScalar(this._dollyControlCoord.x * T * I.aspect)).add(E.multiplyScalar(this._dollyControlCoord.y * T)), R = ut.copy(this._targetEnd).lerp(F, m), S = this._lastDollyDirection === Ke.IN && this._spherical.radius <= this.minDistance, N = this._lastDollyDirection === Ke.OUT && this.maxDistance <= this._spherical.radius;
4740
4740
  if (this.infinityDolly && (S || N)) {
4741
4741
  this._sphericalEnd.radius -= f, this._spherical.radius -= f;
4742
4742
  const M = Et.copy(u).multiplyScalar(-f);
@@ -4746,7 +4746,7 @@ class vt extends ic {
4746
4746
  const y = Et.subVectors(R, this._targetEnd);
4747
4747
  this._targetEnd.copy(R), this._target.add(y), this._changedDolly -= f, gt(this._changedDolly) && (this._changedDolly = 0);
4748
4748
  } else if (Oe(this._camera) && this._changedZoom !== 0) {
4749
- const f = this._zoom - this._lastZoom, I = this._camera, u = ut.set(this._dollyControlCoord.x, this._dollyControlCoord.y, (I.near + I.far) / (I.near - I.far)).unproject(I), d = Et.set(0, 0, -1).applyQuaternion(I.quaternion), E = Je.copy(u).add(d.multiplyScalar(-u.dot(I.up))), p = -(this._zoom - f - this._zoom) / this._zoom, m = this._getCameraDirection(Ai), F = this._targetEnd.dot(m), R = ut.copy(this._targetEnd).lerp(E, p), S = R.dot(m), N = m.multiplyScalar(S - F);
4749
+ const f = this._zoom - this._lastZoom, I = this._camera, u = ut.set(this._dollyControlCoord.x, this._dollyControlCoord.y, (I.near + I.far) / (I.near - I.far)).unproject(I), d = Et.set(0, 0, -1).applyQuaternion(I.quaternion), E = ti.copy(u).add(d.multiplyScalar(-u.dot(I.up))), p = -(this._zoom - f - this._zoom) / this._zoom, m = this._getCameraDirection(Fi), F = this._targetEnd.dot(m), R = ut.copy(this._targetEnd).lerp(E, p), S = R.dot(m), N = m.multiplyScalar(S - F);
4750
4750
  R.sub(N), this._boundary.clampPoint(R, R);
4751
4751
  const y = Et.subVectors(R, this._targetEnd);
4752
4752
  this._targetEnd.copy(R), this._target.add(y), this._changedZoom -= f, gt(this._changedZoom) && (this._changedZoom = 0);
@@ -4754,7 +4754,7 @@ class vt extends ic {
4754
4754
  }
4755
4755
  this._camera.zoom !== this._zoom && (this._camera.zoom = this._zoom, this._camera.updateProjectionMatrix(), this._updateNearPlaneCorners(), this._needsUpdate = !0), this._dragNeedsUpdate = !0;
4756
4756
  const a = this._collisionTest();
4757
- this._spherical.radius = Math.min(this._spherical.radius, a), this._spherical.makeSafe(), this._camera.position.setFromSpherical(this._spherical).applyQuaternion(this._yAxisUpSpaceInverse).add(this._target), this._camera.lookAt(this._target), (!gt(this._focalOffset.x) || !gt(this._focalOffset.y) || !gt(this._focalOffset.z)) && (this._camera.updateMatrixWorld(), le.setFromMatrixColumn(this._camera.matrix, 0), he.setFromMatrixColumn(this._camera.matrix, 1), ve.setFromMatrixColumn(this._camera.matrix, 2), le.multiplyScalar(this._focalOffset.x), he.multiplyScalar(-this._focalOffset.y), ve.multiplyScalar(this._focalOffset.z), ut.copy(le).add(he).add(ve), this._camera.position.add(ut)), this._boundaryEnclosesCamera && this._encloseToBoundary(this._camera.position.copy(this._target), ut.setFromSpherical(this._spherical).applyQuaternion(this._yAxisUpSpaceInverse), 1);
4757
+ this._spherical.radius = Math.min(this._spherical.radius, a), this._spherical.makeSafe(), this._camera.position.setFromSpherical(this._spherical).applyQuaternion(this._yAxisUpSpaceInverse).add(this._target), this._camera.lookAt(this._target), (!gt(this._focalOffset.x) || !gt(this._focalOffset.y) || !gt(this._focalOffset.z)) && (this._camera.updateMatrixWorld(), le.setFromMatrixColumn(this._camera.matrix, 0), he.setFromMatrixColumn(this._camera.matrix, 1), Ue.setFromMatrixColumn(this._camera.matrix, 2), le.multiplyScalar(this._focalOffset.x), he.multiplyScalar(-this._focalOffset.y), Ue.multiplyScalar(this._focalOffset.z), ut.copy(le).add(he).add(Ue), this._camera.position.add(ut)), this._boundaryEnclosesCamera && this._encloseToBoundary(this._camera.position.copy(this._target), ut.setFromSpherical(this._spherical).applyQuaternion(this._yAxisUpSpaceInverse), 1);
4758
4758
  const h = this._needsUpdate;
4759
4759
  return h && !this._updatedLastTime ? (this._hasRested = !1, this.dispatchEvent({ type: "wake" }), this.dispatchEvent({ type: "update" })) : h ? (this.dispatchEvent({ type: "update" }), gt(t, this.restThreshold) && gt(e, this.restThreshold) && gt(s, this.restThreshold) && gt(n.x, this.restThreshold) && gt(n.y, this.restThreshold) && gt(n.z, this.restThreshold) && gt(r.x, this.restThreshold) && gt(r.y, this.restThreshold) && gt(r.z, this.restThreshold) && gt(o, this.restThreshold) && !this._hasRested && (this._hasRested = !0, this.dispatchEvent({ type: "rest" }))) : !h && this._updatedLastTime && this.dispatchEvent({ type: "sleep" }), this._lastDistance = this._spherical.radius, this._lastZoom = this._zoom, this._updatedLastTime = h, this._needsUpdate = !1, h;
4760
4760
  }
@@ -4766,13 +4766,13 @@ class vt extends ic {
4766
4766
  return JSON.stringify({
4767
4767
  enabled: this._enabled,
4768
4768
  minDistance: this.minDistance,
4769
- maxDistance: Ri(this.maxDistance),
4769
+ maxDistance: gi(this.maxDistance),
4770
4770
  minZoom: this.minZoom,
4771
- maxZoom: Ri(this.maxZoom),
4771
+ maxZoom: gi(this.maxZoom),
4772
4772
  minPolarAngle: this.minPolarAngle,
4773
- maxPolarAngle: Ri(this.maxPolarAngle),
4774
- minAzimuthAngle: Ri(this.minAzimuthAngle),
4775
- maxAzimuthAngle: Ri(this.maxAzimuthAngle),
4773
+ maxPolarAngle: gi(this.maxPolarAngle),
4774
+ minAzimuthAngle: gi(this.minAzimuthAngle),
4775
+ maxAzimuthAngle: gi(this.maxAzimuthAngle),
4776
4776
  smoothTime: this.smoothTime,
4777
4777
  draggingSmoothTime: this.draggingSmoothTime,
4778
4778
  dollySpeed: this.dollySpeed,
@@ -4797,7 +4797,7 @@ class vt extends ic {
4797
4797
  */
4798
4798
  fromJSON(i, t = !1) {
4799
4799
  const e = JSON.parse(i);
4800
- this.enabled = e.enabled, this.minDistance = e.minDistance, this.maxDistance = gi(e.maxDistance), this.minZoom = e.minZoom, this.maxZoom = gi(e.maxZoom), this.minPolarAngle = e.minPolarAngle, this.maxPolarAngle = gi(e.maxPolarAngle), this.minAzimuthAngle = gi(e.minAzimuthAngle), this.maxAzimuthAngle = gi(e.maxAzimuthAngle), this.smoothTime = e.smoothTime, this.draggingSmoothTime = e.draggingSmoothTime, this.dollySpeed = e.dollySpeed, this.truckSpeed = e.truckSpeed, this.dollyToCursor = e.dollyToCursor, this.verticalDragToForward = e.verticalDragToForward, this._target0.fromArray(e.target0), this._position0.fromArray(e.position0), this._zoom0 = e.zoom0, this._focalOffset0.fromArray(e.focalOffset0), this.moveTo(e.target[0], e.target[1], e.target[2], t), Xt.setFromVector3(ut.fromArray(e.position).sub(this._targetEnd).applyQuaternion(this._yAxisUpSpace)), this.rotateTo(Xt.theta, Xt.phi, t), this.dollyTo(Xt.radius, t), this.zoomTo(e.zoom, t), this.setFocalOffset(e.focalOffset[0], e.focalOffset[1], e.focalOffset[2], t), this._needsUpdate = !0;
4800
+ this.enabled = e.enabled, this.minDistance = e.minDistance, this.maxDistance = Ai(e.maxDistance), this.minZoom = e.minZoom, this.maxZoom = Ai(e.maxZoom), this.minPolarAngle = e.minPolarAngle, this.maxPolarAngle = Ai(e.maxPolarAngle), this.minAzimuthAngle = Ai(e.minAzimuthAngle), this.maxAzimuthAngle = Ai(e.maxAzimuthAngle), this.smoothTime = e.smoothTime, this.draggingSmoothTime = e.draggingSmoothTime, this.dollySpeed = e.dollySpeed, this.truckSpeed = e.truckSpeed, this.dollyToCursor = e.dollyToCursor, this.verticalDragToForward = e.verticalDragToForward, this._target0.fromArray(e.target0), this._position0.fromArray(e.position0), this._zoom0 = e.zoom0, this._focalOffset0.fromArray(e.focalOffset0), this.moveTo(e.target[0], e.target[1], e.target[2], t), Xt.setFromVector3(ut.fromArray(e.position).sub(this._targetEnd).applyQuaternion(this._yAxisUpSpace)), this.rotateTo(Xt.theta, Xt.phi, t), this.dollyTo(Xt.radius, t), this.zoomTo(e.zoom, t), this.setFocalOffset(e.focalOffset[0], e.focalOffset[1], e.focalOffset[2], t), this._needsUpdate = !0;
4801
4801
  }
4802
4802
  /**
4803
4803
  * Attach all internal event handlers to enable drag control.
@@ -4844,7 +4844,7 @@ class vt extends ic {
4844
4844
  const s = t.lengthSq();
4845
4845
  if (s === 0)
4846
4846
  return i;
4847
- const n = Et.copy(t).add(i), o = this._boundary.clampPoint(n, Je).sub(n), a = o.lengthSq();
4847
+ const n = Et.copy(t).add(i), o = this._boundary.clampPoint(n, ti).sub(n), a = o.lengthSq();
4848
4848
  if (a === 0)
4849
4849
  return i.add(t);
4850
4850
  if (a === s)
@@ -4857,8 +4857,8 @@ class vt extends ic {
4857
4857
  }
4858
4858
  }
4859
4859
  _updateNearPlaneCorners() {
4860
- if (be(this._camera)) {
4861
- const i = this._camera, t = i.near, e = i.getEffectiveFOV() * mi, s = Math.tan(e * 0.5) * t, n = s * i.aspect;
4860
+ if (ve(this._camera)) {
4861
+ const i = this._camera, t = i.near, e = i.getEffectiveFOV() * Ri, s = Math.tan(e * 0.5) * t, n = s * i.aspect;
4862
4862
  this._nearPlaneCorners[0].set(-n, -s, 0), this._nearPlaneCorners[1].set(n, -s, 0), this._nearPlaneCorners[2].set(n, s, 0), this._nearPlaneCorners[3].set(-n, s, 0);
4863
4863
  } else if (Oe(this._camera)) {
4864
4864
  const i = this._camera, t = 1 / i.zoom, e = i.left * t, s = i.right * t, n = i.top * t, r = i.bottom * t;
@@ -4870,14 +4870,14 @@ class vt extends ic {
4870
4870
  let i = 1 / 0;
4871
4871
  if (!(this.colliderMeshes.length >= 1) || on(this._camera, "_collisionTest"))
4872
4872
  return i;
4873
- const e = this._getTargetDirection(Ai);
4873
+ const e = this._getTargetDirection(Fi);
4874
4874
  hn.lookAt(Rr, e, this._camera.up);
4875
4875
  for (let s = 0; s < 4; s++) {
4876
4876
  const n = Et.copy(this._nearPlaneCorners[s]);
4877
4877
  n.applyMatrix4(hn);
4878
- const r = Je.addVectors(this._target, n);
4879
- os.set(r, e), os.far = this._spherical.radius + 1;
4880
- const o = os.intersectObjects(this.colliderMeshes);
4878
+ const r = ti.addVectors(this._target, n);
4879
+ as.set(r, e), as.far = this._spherical.radius + 1;
4880
+ const o = as.intersectObjects(this.colliderMeshes);
4881
4881
  o.length !== 0 && o[0].distance < i && (i = o[0].distance);
4882
4882
  }
4883
4883
  return i;
@@ -4938,9 +4938,9 @@ class vt extends ic {
4938
4938
  }
4939
4939
  static createBoundingSphere(i, t = new lt.Sphere()) {
4940
4940
  const e = t, s = e.center;
4941
- ti.makeEmpty(), i.traverseVisible((r) => {
4942
- r.isMesh && ti.expandByObject(r);
4943
- }), ti.getCenter(s);
4941
+ ei.makeEmpty(), i.traverseVisible((r) => {
4942
+ r.isMesh && ei.expandByObject(r);
4943
+ }), ei.getCenter(s);
4944
4944
  let n = 0;
4945
4945
  return i.traverseVisible((r) => {
4946
4946
  if (!r.isMesh)
@@ -4953,20 +4953,20 @@ class vt extends ic {
4953
4953
  }), e.radius = Math.sqrt(n), e;
4954
4954
  }
4955
4955
  }
4956
- class Ui extends Va {
4956
+ class xi extends Va {
4957
4957
  constructor(t) {
4958
4958
  super(t);
4959
4959
  /** {@link Updateable.onBeforeUpdate} */
4960
- C(this, "onBeforeUpdate", new Z());
4960
+ C(this, "onBeforeUpdate", new j());
4961
4961
  /** {@link Updateable.onAfterUpdate} */
4962
- C(this, "onAfterUpdate", new Z());
4962
+ C(this, "onAfterUpdate", new j());
4963
4963
  /**
4964
4964
  * Event that is triggered when the aspect of the camera has been updated.
4965
4965
  * This event is useful when you need to perform actions after the aspect of the camera has been changed.
4966
4966
  */
4967
- C(this, "onAspectUpdated", new Z());
4967
+ C(this, "onAspectUpdated", new j());
4968
4968
  /** {@link Disposable.onDisposed} */
4969
- C(this, "onDisposed", new Z());
4969
+ C(this, "onDisposed", new j());
4970
4970
  /**
4971
4971
  * A three.js PerspectiveCamera or OrthographicCamera instance.
4972
4972
  * This camera is used for rendering the scene.
@@ -5053,7 +5053,7 @@ class Ui extends Va {
5053
5053
  throw new Error("This camera needs a world to work!");
5054
5054
  if (!this.currentWorld.renderer)
5055
5055
  throw new Error("This camera needs a renderer to work!");
5056
- vt.install({ THREE: Ui.getSubsetOfThree() });
5056
+ vt.install({ THREE: xi.getSubsetOfThree() });
5057
5057
  const { domElement: t } = this.currentWorld.renderer.three, e = new vt(this.three, t);
5058
5058
  return e.smoothTime = 0.2, e.dollyToCursor = !0, e.infinityDolly = !0, e.minDistance = 6, e;
5059
5059
  }
@@ -5080,11 +5080,11 @@ const Os = class Os extends At {
5080
5080
  constructor(t) {
5081
5081
  super(t);
5082
5082
  /** {@link Updateable.onAfterUpdate} */
5083
- C(this, "onAfterUpdate", new Z());
5083
+ C(this, "onAfterUpdate", new j());
5084
5084
  /** {@link Updateable.onBeforeUpdate} */
5085
- C(this, "onBeforeUpdate", new Z());
5085
+ C(this, "onBeforeUpdate", new j());
5086
5086
  /** {@link Disposable.onDisposed} */
5087
- C(this, "onDisposed", new Z());
5087
+ C(this, "onDisposed", new j());
5088
5088
  /**
5089
5089
  * A collection of worlds managed by this component.
5090
5090
  * The key is the unique identifier (UUID) of the world, and the value is the World instance.
@@ -5170,7 +5170,7 @@ async function so(c, i, t, e, s, n, r, o) {
5170
5170
  const a = c.createBuffer();
5171
5171
  return c.bindBuffer(c.PIXEL_PACK_BUFFER, a), c.bufferData(c.PIXEL_PACK_BUFFER, o.byteLength, c.STREAM_READ), c.readPixels(i, t, e, s, n, r, 0), c.bindBuffer(c.PIXEL_PACK_BUFFER, null), await ac(c, c.PIXEL_PACK_BUFFER, a, 0, o), c.deleteBuffer(a), o;
5172
5172
  }
5173
- class cc extends Ye {
5173
+ class cc extends Ge {
5174
5174
  constructor() {
5175
5175
  super(...arguments);
5176
5176
  C(this, "_config", {
@@ -5288,15 +5288,15 @@ class cc extends Ye {
5288
5288
  class lc {
5289
5289
  constructor(i, t) {
5290
5290
  /** {@link Configurable.onSetup} */
5291
- C(this, "onSetup", new Z());
5291
+ C(this, "onSetup", new j());
5292
5292
  /** {@link Disposable.onDisposed} */
5293
- C(this, "onDisposed", new Z());
5293
+ C(this, "onDisposed", new j());
5294
5294
  /**
5295
5295
  * Fires after making the visibility check to the meshes. It lists the
5296
5296
  * meshes that are currently visible, and the ones that were visible
5297
5297
  * just before but not anymore.
5298
5298
  */
5299
- C(this, "onViewUpdated", new Is());
5299
+ C(this, "onViewUpdated", new Pe());
5300
5300
  /**
5301
5301
  * Whether this renderer is active or not. If not, it won't render anything.
5302
5302
  */
@@ -5401,7 +5401,7 @@ class lc {
5401
5401
  }
5402
5402
  /** {@link Disposable.dispose} */
5403
5403
  dispose() {
5404
- this.enabled = !1, this.config.autoUpdate = !1, this.components.get(Ve).list.delete(this.config.uuid);
5404
+ this.enabled = !1, this.config.autoUpdate = !1, this.components.get(Ye).list.delete(this.config.uuid);
5405
5405
  for (const t of this.scene.children)
5406
5406
  t.removeFromParent();
5407
5407
  this.onViewUpdated.reset(), this.worker.terminate(), this.renderer.forceContextLoss(), this.renderer.dispose(), this.renderTarget.dispose(), this.buffer = null, this.onDisposed.reset();
@@ -5445,7 +5445,7 @@ class hc extends lc {
5445
5445
  * Event triggered when the visibility of meshes is updated.
5446
5446
  * Contains two sets: seen and unseen.
5447
5447
  */
5448
- C(this, "onViewUpdated", new Z());
5448
+ C(this, "onViewUpdated", new j());
5449
5449
  /**
5450
5450
  * Map of color code to THREE.InstancedMesh.
5451
5451
  * Used to keep track of color-coded meshes.
@@ -5497,7 +5497,7 @@ class hc extends lc {
5497
5497
  /** {@link Disposable.dispose} */
5498
5498
  dispose() {
5499
5499
  super.dispose(), this._currentVisibleMeshes.clear(), this._recentlyHiddenMeshes.clear(), this._meshIDColorCodeMap.clear(), this._transparentMat.dispose(), this._colorCodeMeshMap.clear();
5500
- const t = this.components.get(Me);
5500
+ const t = this.components.get(De);
5501
5501
  for (const e in this.colorMeshes) {
5502
5502
  const s = this.colorMeshes.get(e);
5503
5503
  s && t.destroy(s, !0);
@@ -5548,7 +5548,7 @@ class hc extends lc {
5548
5548
  return;
5549
5549
  }
5550
5550
  this.preventUpdate = !0;
5551
- const e = this.components.get(Me);
5551
+ const e = this.components.get(De);
5552
5552
  this._currentVisibleMeshes.delete(t), this._recentlyHiddenMeshes.delete(t);
5553
5553
  const s = this.colorMeshes.get(t.uuid), n = this._meshIDColorCodeMap.get(t.uuid);
5554
5554
  if (!s || !n) {
@@ -5584,19 +5584,19 @@ class hc extends lc {
5584
5584
  return D.ColorManagement.enabled = r, { colorMaterial: l, code: n };
5585
5585
  }
5586
5586
  }
5587
- const Mi = class Mi extends At {
5587
+ const Di = class Di extends At {
5588
5588
  constructor(t) {
5589
5589
  super(t);
5590
5590
  /**
5591
5591
  * An event that is triggered when the Cullers component is disposed.
5592
5592
  */
5593
- C(this, "onDisposed", new Z());
5593
+ C(this, "onDisposed", new j());
5594
5594
  C(this, "_enabled", !0);
5595
5595
  /**
5596
5596
  * A map of MeshCullerRenderer instances, keyed by their world UUIDs.
5597
5597
  */
5598
5598
  C(this, "list", /* @__PURE__ */ new Map());
5599
- t.add(Mi.uuid, this);
5599
+ t.add(Di.uuid, this);
5600
5600
  }
5601
5601
  /** {@link Component.enabled} */
5602
5602
  get enabled() {
@@ -5636,7 +5636,7 @@ const Mi = class Mi extends At {
5636
5636
  }
5637
5637
  /** {@link Disposable.dispose} */
5638
5638
  dispose() {
5639
- this.enabled = !1, this.onDisposed.trigger(Mi.uuid), this.onDisposed.reset();
5639
+ this.enabled = !1, this.onDisposed.trigger(Di.uuid), this.onDisposed.reset();
5640
5640
  for (const [t, e] of this.list)
5641
5641
  e.dispose();
5642
5642
  this.list.clear();
@@ -5656,18 +5656,18 @@ const Mi = class Mi extends At {
5656
5656
  * A unique identifier for the component.
5657
5657
  * This UUID is used to register the component within the Components system.
5658
5658
  */
5659
- C(Mi, "uuid", "69f2a50d-c266-44fc-b1bd-fa4d34be89e6");
5660
- let Fn = Mi;
5659
+ C(Di, "uuid", "69f2a50d-c266-44fc-b1bd-fa4d34be89e6");
5660
+ let Fn = Di;
5661
5661
  class uc {
5662
5662
  constructor(i, t) {
5663
5663
  /** {@link Disposable.onDisposed} */
5664
- C(this, "onDisposed", new Z());
5664
+ C(this, "onDisposed", new j());
5665
5665
  /**
5666
5666
  * Fires after making the visibility check to the meshes. It lists the
5667
5667
  * meshes that are currently visible, and the ones that were visible
5668
5668
  * just before but not anymore.
5669
5669
  */
5670
- C(this, "onDistanceComputed", new Z());
5670
+ C(this, "onDistanceComputed", new j());
5671
5671
  /**
5672
5672
  * Objects that won't be taken into account in the distance check.
5673
5673
  */
@@ -5958,7 +5958,7 @@ class fc {
5958
5958
  C(this, "_event");
5959
5959
  C(this, "_position", new D.Vector2());
5960
5960
  /** {@link Disposable.onDisposed} */
5961
- C(this, "onDisposed", new Z());
5961
+ C(this, "onDisposed", new j());
5962
5962
  C(this, "updateMouseInfo", (i) => {
5963
5963
  this._event = i;
5964
5964
  });
@@ -5998,7 +5998,7 @@ class Ic {
5998
5998
  /** The components instance to which this Raycaster belongs. */
5999
5999
  C(this, "components");
6000
6000
  /** {@link Disposable.onDisposed} */
6001
- C(this, "onDisposed", new Z());
6001
+ C(this, "onDisposed", new j());
6002
6002
  /** The position of the mouse in the screen. */
6003
6003
  C(this, "mouse");
6004
6004
  /**
@@ -6074,7 +6074,7 @@ const Ns = class Ns extends At {
6074
6074
  */
6075
6075
  C(this, "list", /* @__PURE__ */ new Map());
6076
6076
  /** {@link Disposable.onDisposed} */
6077
- C(this, "onDisposed", new Z());
6077
+ C(this, "onDisposed", new j());
6078
6078
  t.add(Ns.uuid, this);
6079
6079
  }
6080
6080
  /**
@@ -6116,8 +6116,8 @@ const Ns = class Ns extends At {
6116
6116
  * This UUID is used to register the component within the Components system.
6117
6117
  */
6118
6118
  C(Ns, "uuid", "d5d8bdf0-db25-4952-b951-b643af207ace");
6119
- let ai = Ns;
6120
- class dc extends Ye {
6119
+ let ci = Ns;
6120
+ class dc extends Ge {
6121
6121
  constructor() {
6122
6122
  super(...arguments);
6123
6123
  C(this, "_config", {
@@ -6216,9 +6216,9 @@ class dc extends Ye {
6216
6216
  class Ec {
6217
6217
  constructor(i, t) {
6218
6218
  /** {@link Disposable.onDisposed} */
6219
- C(this, "onDisposed", new Z());
6219
+ C(this, "onDisposed", new j());
6220
6220
  /** {@link Configurable.onSetup} */
6221
- C(this, "onSetup", new Z());
6221
+ C(this, "onSetup", new j());
6222
6222
  /** {@link Configurable.isSetup} */
6223
6223
  C(this, "isSetup", !1);
6224
6224
  /** The world instance to which this Raycaster belongs. */
@@ -6238,7 +6238,7 @@ class Ec {
6238
6238
  C(this, "three");
6239
6239
  C(this, "_fade", 3);
6240
6240
  C(this, "updateZoom", () => {
6241
- this.world.camera instanceof Ui && (this.material.uniforms.uZoom.value = this.world.camera.three.zoom);
6241
+ this.world.camera instanceof xi && (this.material.uniforms.uZoom.value = this.world.camera.three.zoom);
6242
6242
  });
6243
6243
  this.world = t;
6244
6244
  const { color: e, primarySize: s, secondarySize: n, distance: r } = this._defaultConfig;
@@ -6368,10 +6368,10 @@ class Ec {
6368
6368
  }
6369
6369
  /** {@link Disposable.dispose} */
6370
6370
  dispose() {
6371
- this.setupEvents(!1), this.components.get(Ve).list.delete(this.config.uuid), this.components.get(Me).destroy(this.three), this.onDisposed.trigger(), this.onDisposed.reset(), this.world = null, this.components = null;
6371
+ this.setupEvents(!1), this.components.get(Ye).list.delete(this.config.uuid), this.components.get(De).destroy(this.three), this.onDisposed.trigger(), this.onDisposed.reset(), this.world = null, this.components = null;
6372
6372
  }
6373
6373
  setupEvents(i) {
6374
- if (this.world.isDisposing || !(this.world.camera instanceof Ui))
6374
+ if (this.world.isDisposing || !(this.world.camera instanceof xi))
6375
6375
  return;
6376
6376
  const t = this.world.camera.controls;
6377
6377
  i ? t.addEventListener("update", this.updateZoom) : t.removeEventListener("update", this.updateZoom);
@@ -6385,7 +6385,7 @@ const ys = class ys extends At {
6385
6385
  */
6386
6386
  C(this, "list", /* @__PURE__ */ new Map());
6387
6387
  /** {@link Disposable.onDisposed} */
6388
- C(this, "onDisposed", new Z());
6388
+ C(this, "onDisposed", new j());
6389
6389
  /** {@link Component.enabled} */
6390
6390
  C(this, "enabled", !0);
6391
6391
  t.add(ys.uuid, this);
@@ -6434,7 +6434,7 @@ const ys = class ys extends At {
6434
6434
  */
6435
6435
  C(ys, "uuid", "d1e814d5-b81c-4452-87a2-f039375e0489");
6436
6436
  let Or = ys;
6437
- const Ue = new yo(), bt = new Q(), Se = new Q(), Ot = new de(), Nr = {
6437
+ const xe = new yo(), bt = new Q(), Se = new Q(), Ot = new de(), Nr = {
6438
6438
  X: new Q(1, 0, 0),
6439
6439
  Y: new Q(0, 1, 0),
6440
6440
  Z: new Q(0, 0, 1)
@@ -6469,14 +6469,14 @@ class pc extends In {
6469
6469
  pointerHover(i) {
6470
6470
  if (this.object === void 0 || this.dragging === !0)
6471
6471
  return;
6472
- Ue.setFromCamera(i, this.camera);
6473
- const t = fn(this._gizmo.picker[this.mode], Ue);
6472
+ xe.setFromCamera(i, this.camera);
6473
+ const t = fn(this._gizmo.picker[this.mode], xe);
6474
6474
  t ? this.axis = t.object.name : this.axis = null;
6475
6475
  }
6476
6476
  pointerDown(i) {
6477
6477
  if (!(this.object === void 0 || this.dragging === !0 || i.button !== 0) && this.axis !== null) {
6478
- Ue.setFromCamera(i, this.camera);
6479
- const t = fn(this._plane, Ue, !0);
6478
+ xe.setFromCamera(i, this.camera);
6479
+ const t = fn(this._plane, xe, !0);
6480
6480
  t && (this.object.updateMatrixWorld(), this.object.parent.updateMatrixWorld(), this._positionStart.copy(this.object.position), this._quaternionStart.copy(this.object.quaternion), this._scaleStart.copy(this.object.scale), this.object.matrixWorld.decompose(this.worldPositionStart, this.worldQuaternionStart, this._worldScaleStart), this.pointStart.copy(t.point).sub(this.worldPositionStart)), this.dragging = !0, yr.mode = this.mode, this.dispatchEvent(yr);
6481
6481
  }
6482
6482
  }
@@ -6485,8 +6485,8 @@ class pc extends In {
6485
6485
  let n = this.space;
6486
6486
  if (e === "scale" ? n = "local" : (t === "E" || t === "XYZE" || t === "XYZ") && (n = "world"), s === void 0 || t === null || this.dragging === !1 || i.button !== -1)
6487
6487
  return;
6488
- Ue.setFromCamera(i, this.camera);
6489
- const r = fn(this._plane, Ue, !0);
6488
+ xe.setFromCamera(i, this.camera);
6489
+ const r = fn(this._plane, xe, !0);
6490
6490
  if (r) {
6491
6491
  if (this.pointEnd.copy(r.point).sub(this.worldPositionStart), e === "translate")
6492
6492
  this._offset.copy(this.pointEnd).sub(this.pointStart), n === "local" && t !== "XYZ" && this._offset.applyQuaternion(this._worldQuaternionInv), t.indexOf("X") === -1 && (this._offset.x = 0), t.indexOf("Y") === -1 && (this._offset.y = 0), t.indexOf("Z") === -1 && (this._offset.z = 0), n === "local" && t !== "XYZ" ? this._offset.applyQuaternion(this._quaternionStart).divide(this._parentScale) : this._offset.applyQuaternion(this._parentQuaternionInv).divide(this._parentScale), s.position.copy(this._offset).add(this._positionStart), this.translationSnap && (n === "local" && (s.position.applyQuaternion(Ot.copy(this._quaternionStart).invert()), t.search("X") !== -1 && (s.position.x = Math.round(s.position.x / this.translationSnap) * this.translationSnap), t.search("Y") !== -1 && (s.position.y = Math.round(s.position.y / this.translationSnap) * this.translationSnap), t.search("Z") !== -1 && (s.position.z = Math.round(s.position.z / this.translationSnap) * this.translationSnap), s.position.applyQuaternion(this._quaternionStart)), n === "world" && (s.parent && s.position.add(bt.setFromMatrixPosition(s.parent.matrixWorld)), t.search("X") !== -1 && (s.position.x = Math.round(s.position.x / this.translationSnap) * this.translationSnap), t.search("Y") !== -1 && (s.position.y = Math.round(s.position.y / this.translationSnap) * this.translationSnap), t.search("Z") !== -1 && (s.position.z = Math.round(s.position.z / this.translationSnap) * this.translationSnap), s.parent && s.position.sub(bt.setFromMatrixPosition(s.parent.matrixWorld))));
@@ -6526,7 +6526,7 @@ class pc extends In {
6526
6526
  this.enabled && this.dragging && (this.object.position.copy(this._positionStart), this.object.quaternion.copy(this._quaternionStart), this.object.scale.copy(this._scaleStart), this.dispatchEvent(un), this.dispatchEvent(_r), this.pointStart.copy(this.pointEnd));
6527
6527
  }
6528
6528
  getRaycaster() {
6529
- return Ue;
6529
+ return xe;
6530
6530
  }
6531
6531
  // TODO: deprecate
6532
6532
  getMode() {
@@ -6592,7 +6592,7 @@ function fn(c, i, t) {
6592
6592
  return e[s];
6593
6593
  return !1;
6594
6594
  }
6595
- const as = new Lo(), mt = new Q(0, 1, 0), Pr = new Q(0, 0, 0), wr = new pe(), cs = new de(), Es = new de(), ue = new Q(), Mr = new pe(), Li = new Q(1, 0, 0), xe = new Q(0, 1, 0), _i = new Q(0, 0, 1), ls = new Q(), Si = new Q(), Oi = new Q();
6595
+ const cs = new Lo(), mt = new Q(0, 1, 0), Pr = new Q(0, 0, 0), wr = new pe(), ls = new de(), Es = new de(), ue = new Q(), Mr = new pe(), _i = new Q(1, 0, 0), Be = new Q(0, 1, 0), Pi = new Q(0, 0, 1), hs = new Q(), Oi = new Q(), Ni = new Q();
6596
6596
  class Ac extends In {
6597
6597
  constructor() {
6598
6598
  super(), this.isTransformControlsGizmo = !0, this.type = "TransformControlsGizmo";
@@ -6638,9 +6638,9 @@ class Ac extends In {
6638
6638
  p.setAttribute("position", new Zn([0, 0, 0, 1, 0, 0], 3));
6639
6639
  const m = new Vt(75e-4, 75e-4, 0.5, 3);
6640
6640
  m.translate(0, 0.25, 0);
6641
- function F(v, j) {
6642
- const V = new fi(v, 75e-4, 3, 64, j * Math.PI * 2);
6643
- return V.rotateY(Math.PI / 2), V.rotateX(Math.PI / 2), V;
6641
+ function F(v, q) {
6642
+ const G = new Ii(v, 75e-4, 3, 64, q * Math.PI * 2);
6643
+ return G.rotateY(Math.PI / 2), G.rotateX(Math.PI / 2), G;
6644
6644
  }
6645
6645
  function R() {
6646
6646
  const v = new $n();
@@ -6663,7 +6663,7 @@ class Ac extends In {
6663
6663
  [new rt(m, o), null, [Math.PI / 2, 0, 0]]
6664
6664
  ],
6665
6665
  XYZ: [
6666
- [new rt(new Yi(0.1, 0), f.clone()), [0, 0, 0]]
6666
+ [new rt(new Gi(0.1, 0), f.clone()), [0, 0, 0]]
6667
6667
  ],
6668
6668
  XY: [
6669
6669
  [new rt(new Ut(0.15, 0.15, 0.01), h.clone()), [0.15, 0.15, 0]]
@@ -6688,7 +6688,7 @@ class Ac extends In {
6688
6688
  [new rt(new Vt(0.2, 0, 0.6, 4), e), [0, 0, -0.3], [-Math.PI / 2, 0, 0]]
6689
6689
  ],
6690
6690
  XYZ: [
6691
- [new rt(new Yi(0.2, 0), e)]
6691
+ [new rt(new Gi(0.2, 0), e)]
6692
6692
  ],
6693
6693
  XY: [
6694
6694
  [new rt(new Ut(0.2, 0.2, 0.01), e), [0.15, 0.15, 0]]
@@ -6701,10 +6701,10 @@ class Ac extends In {
6701
6701
  ]
6702
6702
  }, y = {
6703
6703
  START: [
6704
- [new rt(new Yi(0.01, 2), s), null, null, null, "helper"]
6704
+ [new rt(new Gi(0.01, 2), s), null, null, null, "helper"]
6705
6705
  ],
6706
6706
  END: [
6707
- [new rt(new Yi(0.01, 2), s), null, null, null, "helper"]
6707
+ [new rt(new Gi(0.01, 2), s), null, null, null, "helper"]
6708
6708
  ],
6709
6709
  DELTA: [
6710
6710
  [new Ae(R(), s), null, null, null, "helper"]
@@ -6743,18 +6743,18 @@ class Ac extends In {
6743
6743
  [new rt(new Po(0.25, 10, 8), e)]
6744
6744
  ],
6745
6745
  X: [
6746
- [new rt(new fi(0.5, 0.1, 4, 24), e), [0, 0, 0], [0, -Math.PI / 2, -Math.PI / 2]]
6746
+ [new rt(new Ii(0.5, 0.1, 4, 24), e), [0, 0, 0], [0, -Math.PI / 2, -Math.PI / 2]]
6747
6747
  ],
6748
6748
  Y: [
6749
- [new rt(new fi(0.5, 0.1, 4, 24), e), [0, 0, 0], [Math.PI / 2, 0, 0]]
6749
+ [new rt(new Ii(0.5, 0.1, 4, 24), e), [0, 0, 0], [Math.PI / 2, 0, 0]]
6750
6750
  ],
6751
6751
  Z: [
6752
- [new rt(new fi(0.5, 0.1, 4, 24), e), [0, 0, 0], [0, 0, -Math.PI / 2]]
6752
+ [new rt(new Ii(0.5, 0.1, 4, 24), e), [0, 0, 0], [0, 0, -Math.PI / 2]]
6753
6753
  ],
6754
6754
  E: [
6755
- [new rt(new fi(0.75, 0.1, 2, 24), e)]
6755
+ [new rt(new Ii(0.75, 0.1, 2, 24), e)]
6756
6756
  ]
6757
- }, G = {
6757
+ }, Y = {
6758
6758
  X: [
6759
6759
  [new rt(T, n), [0.5, 0, 0], [0, 0, -Math.PI / 2]],
6760
6760
  [new rt(m, n), [0, 0, 0], [0, 0, -Math.PI / 2]],
@@ -6819,17 +6819,17 @@ class Ac extends In {
6819
6819
  ]
6820
6820
  };
6821
6821
  function g(v) {
6822
- const j = new In();
6823
- for (const V in v)
6824
- for (let et = v[V].length; et--; ) {
6825
- const W = v[V][et][0].clone(), nt = v[V][et][1], Y = v[V][et][2], x = v[V][et][3], ot = v[V][et][4];
6826
- W.name = V, W.tag = ot, nt && W.position.set(nt[0], nt[1], nt[2]), Y && W.rotation.set(Y[0], Y[1], Y[2]), x && W.scale.set(x[0], x[1], x[2]), W.updateMatrix();
6822
+ const q = new In();
6823
+ for (const G in v)
6824
+ for (let et = v[G].length; et--; ) {
6825
+ const W = v[G][et][0].clone(), nt = v[G][et][1], V = v[G][et][2], x = v[G][et][3], ot = v[G][et][4];
6826
+ W.name = G, W.tag = ot, nt && W.position.set(nt[0], nt[1], nt[2]), V && W.rotation.set(V[0], V[1], V[2]), x && W.scale.set(x[0], x[1], x[2]), W.updateMatrix();
6827
6827
  const it = W.geometry.clone();
6828
- it.applyMatrix4(W.matrix), W.geometry = it, W.renderOrder = 1 / 0, W.position.set(0, 0, 0), W.rotation.set(0, 0, 0), W.scale.set(1, 1, 1), j.add(W);
6828
+ it.applyMatrix4(W.matrix), W.geometry = it, W.renderOrder = 1 / 0, W.position.set(0, 0, 0), W.rotation.set(0, 0, 0), W.scale.set(1, 1, 1), q.add(W);
6829
6829
  }
6830
- return j;
6830
+ return q;
6831
6831
  }
6832
- this.gizmo = {}, this.picker = {}, this.helper = {}, this.add(this.gizmo.translate = g(S)), this.add(this.gizmo.rotate = g(M)), this.add(this.gizmo.scale = g(G)), this.add(this.picker.translate = g(N)), this.add(this.picker.rotate = g(b)), this.add(this.picker.scale = g(O)), this.add(this.helper.translate = g(y)), this.add(this.helper.rotate = g(L)), this.add(this.helper.scale = g(w)), this.picker.translate.visible = !1, this.picker.rotate.visible = !1, this.picker.scale.visible = !1;
6832
+ this.gizmo = {}, this.picker = {}, this.helper = {}, this.add(this.gizmo.translate = g(S)), this.add(this.gizmo.rotate = g(M)), this.add(this.gizmo.scale = g(Y)), this.add(this.picker.translate = g(N)), this.add(this.picker.rotate = g(b)), this.add(this.picker.scale = g(O)), this.add(this.helper.translate = g(y)), this.add(this.helper.rotate = g(L)), this.add(this.helper.scale = g(w)), this.picker.translate.visible = !1, this.picker.rotate.visible = !1, this.picker.scale.visible = !1;
6833
6833
  }
6834
6834
  // updateMatrixWorld will update transformations and appearance of individual handles
6835
6835
  updateMatrixWorld(i) {
@@ -6842,10 +6842,10 @@ class Ac extends In {
6842
6842
  r.visible = !0, r.rotation.set(0, 0, 0), r.position.copy(this.worldPosition);
6843
6843
  let o;
6844
6844
  if (this.camera.isOrthographicCamera ? o = (this.camera.top - this.camera.bottom) / this.camera.zoom : o = this.worldPosition.distanceTo(this.cameraPosition) * Math.min(1.9 * Math.tan(Math.PI * this.camera.fov / 360) / this.camera.zoom, 7), r.scale.set(1, 1, 1).multiplyScalar(o * this.size / 4), r.tag === "helper") {
6845
- r.visible = !1, r.name === "AXIS" ? (r.visible = !!this.axis, this.axis === "X" && (Ot.setFromEuler(as.set(0, 0, 0)), r.quaternion.copy(e).multiply(Ot), Math.abs(mt.copy(Li).applyQuaternion(e).dot(this.eye)) > 0.9 && (r.visible = !1)), this.axis === "Y" && (Ot.setFromEuler(as.set(0, 0, Math.PI / 2)), r.quaternion.copy(e).multiply(Ot), Math.abs(mt.copy(xe).applyQuaternion(e).dot(this.eye)) > 0.9 && (r.visible = !1)), this.axis === "Z" && (Ot.setFromEuler(as.set(0, Math.PI / 2, 0)), r.quaternion.copy(e).multiply(Ot), Math.abs(mt.copy(_i).applyQuaternion(e).dot(this.eye)) > 0.9 && (r.visible = !1)), this.axis === "XYZE" && (Ot.setFromEuler(as.set(0, Math.PI / 2, 0)), mt.copy(this.rotationAxis), r.quaternion.setFromRotationMatrix(wr.lookAt(Pr, mt, xe)), r.quaternion.multiply(Ot), r.visible = this.dragging), this.axis === "E" && (r.visible = !1)) : r.name === "START" ? (r.position.copy(this.worldPositionStart), r.visible = this.dragging) : r.name === "END" ? (r.position.copy(this.worldPosition), r.visible = this.dragging) : r.name === "DELTA" ? (r.position.copy(this.worldPositionStart), r.quaternion.copy(this.worldQuaternionStart), bt.set(1e-10, 1e-10, 1e-10).add(this.worldPositionStart).sub(this.worldPosition).multiplyScalar(-1), bt.applyQuaternion(this.worldQuaternionStart.clone().invert()), r.scale.copy(bt), r.visible = this.dragging) : (r.quaternion.copy(e), this.dragging ? r.position.copy(this.worldPositionStart) : r.position.copy(this.worldPosition), this.axis && (r.visible = this.axis.search(r.name) !== -1));
6845
+ r.visible = !1, r.name === "AXIS" ? (r.visible = !!this.axis, this.axis === "X" && (Ot.setFromEuler(cs.set(0, 0, 0)), r.quaternion.copy(e).multiply(Ot), Math.abs(mt.copy(_i).applyQuaternion(e).dot(this.eye)) > 0.9 && (r.visible = !1)), this.axis === "Y" && (Ot.setFromEuler(cs.set(0, 0, Math.PI / 2)), r.quaternion.copy(e).multiply(Ot), Math.abs(mt.copy(Be).applyQuaternion(e).dot(this.eye)) > 0.9 && (r.visible = !1)), this.axis === "Z" && (Ot.setFromEuler(cs.set(0, Math.PI / 2, 0)), r.quaternion.copy(e).multiply(Ot), Math.abs(mt.copy(Pi).applyQuaternion(e).dot(this.eye)) > 0.9 && (r.visible = !1)), this.axis === "XYZE" && (Ot.setFromEuler(cs.set(0, Math.PI / 2, 0)), mt.copy(this.rotationAxis), r.quaternion.setFromRotationMatrix(wr.lookAt(Pr, mt, Be)), r.quaternion.multiply(Ot), r.visible = this.dragging), this.axis === "E" && (r.visible = !1)) : r.name === "START" ? (r.position.copy(this.worldPositionStart), r.visible = this.dragging) : r.name === "END" ? (r.position.copy(this.worldPosition), r.visible = this.dragging) : r.name === "DELTA" ? (r.position.copy(this.worldPositionStart), r.quaternion.copy(this.worldQuaternionStart), bt.set(1e-10, 1e-10, 1e-10).add(this.worldPositionStart).sub(this.worldPosition).multiplyScalar(-1), bt.applyQuaternion(this.worldQuaternionStart.clone().invert()), r.scale.copy(bt), r.visible = this.dragging) : (r.quaternion.copy(e), this.dragging ? r.position.copy(this.worldPositionStart) : r.position.copy(this.worldPosition), this.axis && (r.visible = this.axis.search(r.name) !== -1));
6846
6846
  continue;
6847
6847
  }
6848
- r.quaternion.copy(e), this.mode === "translate" || this.mode === "scale" ? (r.name === "X" && Math.abs(mt.copy(Li).applyQuaternion(e).dot(this.eye)) > 0.99 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "Y" && Math.abs(mt.copy(xe).applyQuaternion(e).dot(this.eye)) > 0.99 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "Z" && Math.abs(mt.copy(_i).applyQuaternion(e).dot(this.eye)) > 0.99 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "XY" && Math.abs(mt.copy(_i).applyQuaternion(e).dot(this.eye)) < 0.2 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "YZ" && Math.abs(mt.copy(Li).applyQuaternion(e).dot(this.eye)) < 0.2 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "XZ" && Math.abs(mt.copy(xe).applyQuaternion(e).dot(this.eye)) < 0.2 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1)) : this.mode === "rotate" && (cs.copy(e), mt.copy(this.eye).applyQuaternion(Ot.copy(e).invert()), r.name.search("E") !== -1 && r.quaternion.setFromRotationMatrix(wr.lookAt(this.eye, Pr, xe)), r.name === "X" && (Ot.setFromAxisAngle(Li, Math.atan2(-mt.y, mt.z)), Ot.multiplyQuaternions(cs, Ot), r.quaternion.copy(Ot)), r.name === "Y" && (Ot.setFromAxisAngle(xe, Math.atan2(mt.x, mt.z)), Ot.multiplyQuaternions(cs, Ot), r.quaternion.copy(Ot)), r.name === "Z" && (Ot.setFromAxisAngle(_i, Math.atan2(mt.y, mt.x)), Ot.multiplyQuaternions(cs, Ot), r.quaternion.copy(Ot))), r.visible = r.visible && (r.name.indexOf("X") === -1 || this.showX), r.visible = r.visible && (r.name.indexOf("Y") === -1 || this.showY), r.visible = r.visible && (r.name.indexOf("Z") === -1 || this.showZ), r.visible = r.visible && (r.name.indexOf("E") === -1 || this.showX && this.showY && this.showZ), r.material._color = r.material._color || r.material.color.clone(), r.material._opacity = r.material._opacity || r.material.opacity, r.material.color.copy(r.material._color), r.material.opacity = r.material._opacity, this.enabled && this.axis && (r.name === this.axis || this.axis.split("").some(function(a) {
6848
+ r.quaternion.copy(e), this.mode === "translate" || this.mode === "scale" ? (r.name === "X" && Math.abs(mt.copy(_i).applyQuaternion(e).dot(this.eye)) > 0.99 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "Y" && Math.abs(mt.copy(Be).applyQuaternion(e).dot(this.eye)) > 0.99 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "Z" && Math.abs(mt.copy(Pi).applyQuaternion(e).dot(this.eye)) > 0.99 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "XY" && Math.abs(mt.copy(Pi).applyQuaternion(e).dot(this.eye)) < 0.2 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "YZ" && Math.abs(mt.copy(_i).applyQuaternion(e).dot(this.eye)) < 0.2 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1), r.name === "XZ" && Math.abs(mt.copy(Be).applyQuaternion(e).dot(this.eye)) < 0.2 && (r.scale.set(1e-10, 1e-10, 1e-10), r.visible = !1)) : this.mode === "rotate" && (ls.copy(e), mt.copy(this.eye).applyQuaternion(Ot.copy(e).invert()), r.name.search("E") !== -1 && r.quaternion.setFromRotationMatrix(wr.lookAt(this.eye, Pr, Be)), r.name === "X" && (Ot.setFromAxisAngle(_i, Math.atan2(-mt.y, mt.z)), Ot.multiplyQuaternions(ls, Ot), r.quaternion.copy(Ot)), r.name === "Y" && (Ot.setFromAxisAngle(Be, Math.atan2(mt.x, mt.z)), Ot.multiplyQuaternions(ls, Ot), r.quaternion.copy(Ot)), r.name === "Z" && (Ot.setFromAxisAngle(Pi, Math.atan2(mt.y, mt.x)), Ot.multiplyQuaternions(ls, Ot), r.quaternion.copy(Ot))), r.visible = r.visible && (r.name.indexOf("X") === -1 || this.showX), r.visible = r.visible && (r.name.indexOf("Y") === -1 || this.showY), r.visible = r.visible && (r.name.indexOf("Z") === -1 || this.showZ), r.visible = r.visible && (r.name.indexOf("E") === -1 || this.showX && this.showY && this.showZ), r.material._color = r.material._color || r.material.color.clone(), r.material._opacity = r.material._opacity || r.material.opacity, r.material.color.copy(r.material._color), r.material.opacity = r.material._opacity, this.enabled && this.axis && (r.name === this.axis || this.axis.split("").some(function(a) {
6849
6849
  return r.name === a;
6850
6850
  })) && (r.material.color.setHex(16776960), r.material.opacity = 1);
6851
6851
  }
@@ -6861,27 +6861,27 @@ class Fc extends rt {
6861
6861
  }
6862
6862
  updateMatrixWorld(i) {
6863
6863
  let t = this.space;
6864
- switch (this.position.copy(this.worldPosition), this.mode === "scale" && (t = "local"), ls.copy(Li).applyQuaternion(t === "local" ? this.worldQuaternion : Es), Si.copy(xe).applyQuaternion(t === "local" ? this.worldQuaternion : Es), Oi.copy(_i).applyQuaternion(t === "local" ? this.worldQuaternion : Es), mt.copy(Si), this.mode) {
6864
+ switch (this.position.copy(this.worldPosition), this.mode === "scale" && (t = "local"), hs.copy(_i).applyQuaternion(t === "local" ? this.worldQuaternion : Es), Oi.copy(Be).applyQuaternion(t === "local" ? this.worldQuaternion : Es), Ni.copy(Pi).applyQuaternion(t === "local" ? this.worldQuaternion : Es), mt.copy(Oi), this.mode) {
6865
6865
  case "translate":
6866
6866
  case "scale":
6867
6867
  switch (this.axis) {
6868
6868
  case "X":
6869
- mt.copy(this.eye).cross(ls), ue.copy(ls).cross(mt);
6869
+ mt.copy(this.eye).cross(hs), ue.copy(hs).cross(mt);
6870
6870
  break;
6871
6871
  case "Y":
6872
- mt.copy(this.eye).cross(Si), ue.copy(Si).cross(mt);
6872
+ mt.copy(this.eye).cross(Oi), ue.copy(Oi).cross(mt);
6873
6873
  break;
6874
6874
  case "Z":
6875
- mt.copy(this.eye).cross(Oi), ue.copy(Oi).cross(mt);
6875
+ mt.copy(this.eye).cross(Ni), ue.copy(Ni).cross(mt);
6876
6876
  break;
6877
6877
  case "XY":
6878
- ue.copy(Oi);
6878
+ ue.copy(Ni);
6879
6879
  break;
6880
6880
  case "YZ":
6881
- ue.copy(ls);
6881
+ ue.copy(hs);
6882
6882
  break;
6883
6883
  case "XZ":
6884
- mt.copy(Oi), ue.copy(Si);
6884
+ mt.copy(Ni), ue.copy(Oi);
6885
6885
  break;
6886
6886
  case "XYZ":
6887
6887
  case "E":
@@ -6899,11 +6899,11 @@ class Fc extends rt {
6899
6899
  class Vn {
6900
6900
  constructor(i, t, e, s, n, r = 5, o = !0) {
6901
6901
  /** Event that fires when the user starts dragging a clipping plane. */
6902
- C(this, "onDraggingStarted", new Z());
6902
+ C(this, "onDraggingStarted", new j());
6903
6903
  /** Event that fires when the user stops dragging a clipping plane. */
6904
- C(this, "onDraggingEnded", new Z());
6904
+ C(this, "onDraggingEnded", new j());
6905
6905
  /** {@link Disposable.onDisposed} */
6906
- C(this, "onDisposed", new Z());
6906
+ C(this, "onDisposed", new j());
6907
6907
  /**
6908
6908
  * The normal vector of the clipping plane.
6909
6909
  */
@@ -7058,7 +7058,7 @@ class Vn {
7058
7058
  return s.scale.set(i, i, i), s;
7059
7059
  }
7060
7060
  }
7061
- class Sc extends Ye {
7061
+ class Sc extends Ge {
7062
7062
  constructor() {
7063
7063
  super(...arguments);
7064
7064
  C(this, "_config", {
@@ -7121,43 +7121,43 @@ class Sc extends Ye {
7121
7121
  this._config.size.value = t, this._component.size = t;
7122
7122
  }
7123
7123
  }
7124
- const si = class si extends At {
7124
+ const ni = class ni extends At {
7125
7125
  constructor(t) {
7126
7126
  super(t);
7127
7127
  /** {@link Configurable.onSetup} */
7128
- C(this, "onSetup", new Z());
7128
+ C(this, "onSetup", new j());
7129
7129
  /** Event that fires when the user starts dragging a clipping plane. */
7130
- C(this, "onBeforeDrag", new Z());
7130
+ C(this, "onBeforeDrag", new j());
7131
7131
  /** Event that fires when the user stops dragging a clipping plane. */
7132
- C(this, "onAfterDrag", new Z());
7132
+ C(this, "onAfterDrag", new j());
7133
7133
  /**
7134
7134
  * Event that fires when the user starts creating a clipping plane.
7135
7135
  */
7136
- C(this, "onBeforeCreate", new Z());
7136
+ C(this, "onBeforeCreate", new j());
7137
7137
  /**
7138
7138
  * Event that fires when the user cancels the creation of a clipping plane.
7139
7139
  */
7140
- C(this, "onBeforeCancel", new Z());
7140
+ C(this, "onBeforeCancel", new j());
7141
7141
  /**
7142
7142
  * Event that fires after the user cancels the creation of a clipping plane.
7143
7143
  */
7144
- C(this, "onAfterCancel", new Z());
7144
+ C(this, "onAfterCancel", new j());
7145
7145
  /**
7146
7146
  * Event that fires when the user starts deleting a clipping plane.
7147
7147
  */
7148
- C(this, "onBeforeDelete", new Z());
7148
+ C(this, "onBeforeDelete", new j());
7149
7149
  /**
7150
7150
  * Event that fires after a clipping plane has been created.
7151
7151
  * @param plane - The newly created clipping plane.
7152
7152
  */
7153
- C(this, "onAfterCreate", new Z());
7153
+ C(this, "onAfterCreate", new j());
7154
7154
  /**
7155
7155
  * Event that fires after a clipping plane has been deleted.
7156
7156
  * @param plane - The deleted clipping plane.
7157
7157
  */
7158
- C(this, "onAfterDelete", new Z());
7158
+ C(this, "onAfterDelete", new j());
7159
7159
  /** {@link Disposable.onDisposed} */
7160
- C(this, "onDisposed", new Z());
7160
+ C(this, "onDisposed", new j());
7161
7161
  /** {@link Configurable.isSetup} */
7162
7162
  C(this, "isSetup", !1);
7163
7163
  /**
@@ -7187,7 +7187,7 @@ const si = class si extends At {
7187
7187
  this,
7188
7188
  this.components,
7189
7189
  "Clipper",
7190
- si.uuid
7190
+ ni.uuid
7191
7191
  ));
7192
7192
  C(this, "_defaultConfig", {
7193
7193
  color: new D.Color(12255487),
@@ -7210,7 +7210,7 @@ const si = class si extends At {
7210
7210
  C(this, "_onEndDragging", () => {
7211
7211
  this.onAfterDrag.trigger();
7212
7212
  });
7213
- this.components.add(si.uuid, this);
7213
+ this.components.add(ni.uuid, this);
7214
7214
  }
7215
7215
  /** {@link Component.enabled} */
7216
7216
  get enabled() {
@@ -7255,14 +7255,14 @@ const si = class si extends At {
7255
7255
  }
7256
7256
  /** {@link Disposable.dispose} */
7257
7257
  dispose() {
7258
- this._enabled = !1, this.components.get(Ve).list.delete(this.config.uuid);
7258
+ this._enabled = !1, this.components.get(Ye).list.delete(this.config.uuid);
7259
7259
  for (const e of this.list)
7260
7260
  e.dispose();
7261
- this.list.length = 0, this._material.dispose(), this.onBeforeCreate.reset(), this.onBeforeCancel.reset(), this.onBeforeDelete.reset(), this.onBeforeDrag.reset(), this.onAfterCreate.reset(), this.onAfterCancel.reset(), this.onAfterDelete.reset(), this.onAfterDrag.reset(), this.onDisposed.trigger(si.uuid), this.onDisposed.reset();
7261
+ this.list.length = 0, this._material.dispose(), this.onBeforeCreate.reset(), this.onBeforeCancel.reset(), this.onBeforeDelete.reset(), this.onBeforeDrag.reset(), this.onAfterCreate.reset(), this.onAfterCancel.reset(), this.onAfterDelete.reset(), this.onAfterDrag.reset(), this.onDisposed.trigger(ni.uuid), this.onDisposed.reset();
7262
7262
  }
7263
7263
  /** {@link Createable.create} */
7264
7264
  create(t) {
7265
- const n = this.components.get(ai).get(t).castRay();
7265
+ const n = this.components.get(ci).get(t).castRay();
7266
7266
  return n ? this.createPlaneFromIntersection(t, n) : null;
7267
7267
  }
7268
7268
  /**
@@ -7316,7 +7316,7 @@ const si = class si extends At {
7316
7316
  }
7317
7317
  }
7318
7318
  pickPlane(t) {
7319
- const s = this.components.get(ai).get(t), n = this.getAllPlaneMeshes(), r = s.castRay(n);
7319
+ const s = this.components.get(ci).get(t), n = this.getAllPlaneMeshes(), r = s.castRay(n);
7320
7320
  if (r) {
7321
7321
  const o = r.object;
7322
7322
  return this.list.find((a) => a.meshes.includes(o));
@@ -7382,8 +7382,8 @@ const si = class si extends At {
7382
7382
  * A unique identifier for the component.
7383
7383
  * This UUID is used to register the component within the Components system.
7384
7384
  */
7385
- C(si, "uuid", "66290bc5-18c4-4cd1-9379-2e17a0617611");
7386
- let Sn = si;
7385
+ C(ni, "uuid", "66290bc5-18c4-4cd1-9379-2e17a0617611");
7386
+ let Sn = ni;
7387
7387
  class Oc {
7388
7388
  constructor(i) {
7389
7389
  /** {@link NavigationMode.enabled} */
@@ -7459,7 +7459,7 @@ class Lc {
7459
7459
  /**
7460
7460
  * Event that fires when the {@link CameraProjection} changes.
7461
7461
  */
7462
- C(this, "onChanged", new Z());
7462
+ C(this, "onChanged", new j());
7463
7463
  /**
7464
7464
  * Current projection mode of the camera.
7465
7465
  * Default is "Perspective".
@@ -7529,7 +7529,7 @@ class Lc {
7529
7529
  i.position.copy(t.position), i.quaternion.copy(t.quaternion), this._component.controls.mouseButtons.wheel = vt.ACTION.DOLLY, this.matchOrthoDistanceEnabled ? this._component.controls.distance = this.getDistance() : this._component.controls.distance = this._previousDistance, await this._component.controls.zoomTo(1), i.updateProjectionMatrix(), this._component.controls.camera = i, this.camera = i, this.current = "Perspective";
7530
7530
  }
7531
7531
  }
7532
- class _c extends Ui {
7532
+ class _c extends xi {
7533
7533
  constructor(t) {
7534
7534
  super(t);
7535
7535
  /**
@@ -9042,7 +9042,7 @@ const ms = {
9042
9042
  1390159747: "FILE_NAME",
9043
9043
  1109904537: "FILE_SCHEMA"
9044
9044
  };
9045
- class ri {
9045
+ class oi {
9046
9046
  static async getUnits(i) {
9047
9047
  var r, o, a;
9048
9048
  const { IFCUNITASSIGNMENT: t } = z, e = await i.getAllPropertiesOfType(t);
@@ -9119,7 +9119,7 @@ class ri {
9119
9119
  return r;
9120
9120
  }
9121
9121
  static async getQsetRel(i, t) {
9122
- return ri.getPsetRel(i, t);
9122
+ return oi.getPsetRel(i, t);
9123
9123
  }
9124
9124
  static async getEntityName(i, t) {
9125
9125
  var r;
@@ -10559,7 +10559,7 @@ class oo {
10559
10559
  const [I, u] = r;
10560
10560
  I != null && I.value && (t.author.name = I.value), u != null && u.value && (t.author.email = u.value);
10561
10561
  }
10562
- return (f = o[0]) != null && f.value && (t.organization = o[0].value), a != null && a.value && (t.preprocessorVersion = a == null ? void 0 : a.value), l != null && l.value && (t.originatingSystem = l == null ? void 0 : l.value), h != null && h.value && (t.authorization = h == null ? void 0 : h.value), t;
10562
+ return o && ((f = o[0]) != null && f.value) && (t.organization = o[0].value), a != null && a.value && (t.preprocessorVersion = a == null ? void 0 : a.value), l != null && l.value && (t.originatingSystem = l == null ? void 0 : l.value), h != null && h.value && (t.authorization = h == null ? void 0 : h.value), t;
10563
10563
  }
10564
10564
  getDescriptionInfo(i) {
10565
10565
  var r;
@@ -10777,19 +10777,19 @@ const co = /* @__PURE__ */ new Set([
10777
10777
  */
10778
10778
  C(Ls, "uuid", "b32c4332-cd67-436e-ba7f-196646c7a635");
10779
10779
  let On = Ls;
10780
- const Di = class Di extends At {
10780
+ const bi = class bi extends At {
10781
10781
  constructor(t) {
10782
10782
  super(t);
10783
10783
  /** {@link Disposable.onDisposed} */
10784
- C(this, "onDisposed", new Z());
10784
+ C(this, "onDisposed", new j());
10785
10785
  /**
10786
10786
  * An event triggered when the IFC file starts loading.
10787
10787
  */
10788
- C(this, "onIfcStartedLoading", new Z());
10788
+ C(this, "onIfcStartedLoading", new j());
10789
10789
  /**
10790
10790
  * An event triggered when the setup process is completed.
10791
10791
  */
10792
- C(this, "onSetup", new Z());
10792
+ C(this, "onSetup", new j());
10793
10793
  /**
10794
10794
  * The settings for the IfcLoader.
10795
10795
  * It includes options for excluding categories, setting WASM paths, and more.
@@ -10811,11 +10811,11 @@ const Di = class Di extends At {
10811
10811
  transparent: !0,
10812
10812
  opacity: 0.5
10813
10813
  }));
10814
- this.components.add(Di.uuid, this), this.settings.excludedCategories.add(z.IFCOPENINGELEMENT);
10814
+ this.components.add(bi.uuid, this), this.settings.excludedCategories.add(z.IFCOPENINGELEMENT);
10815
10815
  }
10816
10816
  /** {@link Disposable.dispose} */
10817
10817
  dispose() {
10818
- this.webIfc = null, this.onDisposed.trigger(Di.uuid), this.onDisposed.reset();
10818
+ this.webIfc = null, this.onDisposed.trigger(bi.uuid), this.onDisposed.reset();
10819
10819
  }
10820
10820
  /**
10821
10821
  * Sets up the IfcLoader component with the provided configuration.
@@ -11033,8 +11033,8 @@ const Di = class Di extends At {
11033
11033
  * A unique identifier for the component.
11034
11034
  * This UUID is used to register the component within the Components system.
11035
11035
  */
11036
- C(Di, "uuid", "a659add7-1418-4771-a0d6-7d4d438e4624");
11037
- let Nn = Di;
11036
+ C(bi, "uuid", "a659add7-1418-4771-a0d6-7d4d438e4624");
11037
+ let Nn = bi;
11038
11038
  const Dc = {
11039
11039
  // IfcRelAssigns
11040
11040
  IfcRelAssignsToControl: { related: 5, relating: 7 },
@@ -11083,11 +11083,11 @@ const Dc = {
11083
11083
  constructor(t) {
11084
11084
  super(t);
11085
11085
  /** {@link Disposable.onDisposed} */
11086
- C(this, "onDisposed", new Z());
11086
+ C(this, "onDisposed", new j());
11087
11087
  /**
11088
11088
  * Event triggered when a file is requested for export.
11089
11089
  */
11090
- C(this, "onRequestFile", new Z());
11090
+ C(this, "onRequestFile", new j());
11091
11091
  /**
11092
11092
  * ArrayBuffer containing the IFC data to be exported.
11093
11093
  */
@@ -11095,19 +11095,19 @@ const Dc = {
11095
11095
  /**
11096
11096
  * Event triggered when an element is added to a Pset.
11097
11097
  */
11098
- C(this, "onElementToPset", new Z());
11098
+ C(this, "onElementToPset", new j());
11099
11099
  /**
11100
11100
  * Event triggered when a property is added to a Pset.
11101
11101
  */
11102
- C(this, "onPropToPset", new Z());
11102
+ C(this, "onPropToPset", new j());
11103
11103
  /**
11104
11104
  * Event triggered when a Pset is removed.
11105
11105
  */
11106
- C(this, "onPsetRemoved", new Z());
11106
+ C(this, "onPsetRemoved", new j());
11107
11107
  /**
11108
11108
  * Event triggered when data in the model changes.
11109
11109
  */
11110
- C(this, "onDataChanged", new Z());
11110
+ C(this, "onDataChanged", new j());
11111
11111
  /**
11112
11112
  * Configuration for the WebAssembly module.
11113
11113
  */
@@ -11214,7 +11214,7 @@ const Dc = {
11214
11214
  const n = await t.getProperties(s);
11215
11215
  if ((n == null ? void 0 : n.type) !== z.IFCPROPERTYSET)
11216
11216
  continue;
11217
- const r = await ri.getPsetRel(t, s);
11217
+ const r = await oi.getPsetRel(t, s);
11218
11218
  if (r && (await t.setProperties(r, null), this.registerChange(t, r)), n) {
11219
11219
  for (const o of n.HasProperties)
11220
11220
  await t.setProperties(o.value, null);
@@ -11423,7 +11423,7 @@ const Dc = {
11423
11423
  const a = o.value;
11424
11424
  if (a === void 0 || a == null)
11425
11425
  throw new Error(`Attribute ${s} has a badly defined handle.`);
11426
- const l = new Z();
11426
+ const l = new j();
11427
11427
  return Object.defineProperty(r[s], "value", {
11428
11428
  get() {
11429
11429
  return this._value;
@@ -11470,11 +11470,11 @@ const Dc = {
11470
11470
  */
11471
11471
  C(ye, "uuid", "58c2d9f0-183c-48d6-a402-dfcf5b9a34df");
11472
11472
  let yn = ye;
11473
- const bi = class bi extends At {
11473
+ const vi = class vi extends At {
11474
11474
  constructor(t) {
11475
11475
  super(t);
11476
11476
  /** {@link Disposable.onDisposed} */
11477
- C(this, "onDisposed", new Z());
11477
+ C(this, "onDisposed", new j());
11478
11478
  /**
11479
11479
  * Event triggered when relations for a model have been indexed.
11480
11480
  * This event provides the model's UUID and the relations map generated for that model.
@@ -11483,7 +11483,7 @@ const bi = class bi extends At {
11483
11483
  * @property {RelationsMap} relationsMap - The relations map generated for the specified model.
11484
11484
  * The map keys are expressIDs of entities, and the values are maps where each key is a relation type ID and its value is an array of expressIDs of entities related through that relation type.
11485
11485
  */
11486
- C(this, "onRelationsIndexed", new Z());
11486
+ C(this, "onRelationsIndexed", new j());
11487
11487
  /**
11488
11488
  * Holds the relationship mappings for each model processed by the indexer.
11489
11489
  * The structure is a map where each key is a model's UUID, and the value is another map.
@@ -11550,8 +11550,8 @@ const bi = class bi extends At {
11550
11550
  * The event provides information about the type of relation, the inverse attribute,
11551
11551
  * the IDs of the entities related, and the IDs of the entities that are being related.
11552
11552
  */
11553
- C(this, "onEntitiesRelated", new Z());
11554
- this.components.add(bi.uuid, this), t.get(Tt).onFragmentsDisposed.add(this.onFragmentsDisposed);
11553
+ C(this, "onEntitiesRelated", new j());
11554
+ this.components.add(vi.uuid, this), t.get(Tt).onFragmentsDisposed.add(this.onFragmentsDisposed);
11555
11555
  }
11556
11556
  indexRelations(t, e, s, n) {
11557
11557
  const r = Object.keys(e).find(
@@ -11566,7 +11566,9 @@ const bi = class bi extends At {
11566
11566
  let f = t.get(a);
11567
11567
  f || (f = /* @__PURE__ */ new Map(), t.set(a, f));
11568
11568
  let I = f.get(h);
11569
- I || (I = [], f.set(h, I)), I.push(...l);
11569
+ I || (I = [], f.set(h, I));
11570
+ for (const u of l)
11571
+ I.push(u);
11570
11572
  }
11571
11573
  for (const f of l) {
11572
11574
  const I = this.getAttributeIndex(s);
@@ -11765,7 +11767,7 @@ const bi = class bi extends At {
11765
11767
  }
11766
11768
  /** {@link Disposable.dispose} */
11767
11769
  dispose() {
11768
- this.relationMaps = {}, this.components.get(Tt).onFragmentsDisposed.remove(this.onFragmentsDisposed), this.onDisposed.trigger(bi.uuid), this.onDisposed.reset();
11770
+ this.relationMaps = {}, this.components.get(Tt).onFragmentsDisposed.remove(this.onFragmentsDisposed), this.onDisposed.trigger(vi.uuid), this.onDisposed.reset();
11769
11771
  }
11770
11772
  /**
11771
11773
  * Retrieves the entities within a model that have a specific relation with a given entity.
@@ -11900,7 +11902,7 @@ const bi = class bi extends At {
11900
11902
  ), I.set(r, E));
11901
11903
  for (const T of u) {
11902
11904
  let p = E.get(T);
11903
- p || (p = { related: new Pe() }, E.set(T, p)), p.related.add(...d);
11905
+ p || (p = { related: new we() }, E.set(T, p)), p.related.add(...d);
11904
11906
  }
11905
11907
  for (const T of u) {
11906
11908
  let p = a.get(T);
@@ -11954,21 +11956,21 @@ const bi = class bi extends At {
11954
11956
  * A unique identifier for the component.
11955
11957
  * This UUID is used to register the component within the Components system.
11956
11958
  */
11957
- C(bi, "uuid", "23a889ab-83b3-44a4-8bee-ead83438370b");
11958
- let kt = bi;
11959
+ C(vi, "uuid", "23a889ab-83b3-44a4-8bee-ead83438370b");
11960
+ let kt = vi;
11959
11961
  const _s = class _s extends At {
11960
11962
  constructor(t) {
11961
11963
  super(t);
11962
11964
  /** {@link Disposable.onDisposed} */
11963
- C(this, "onDisposed", new Z());
11965
+ C(this, "onDisposed", new j());
11964
11966
  /**
11965
11967
  * Event triggered when fragments are loaded.
11966
11968
  */
11967
- C(this, "onFragmentsLoaded", new Z());
11969
+ C(this, "onFragmentsLoaded", new j());
11968
11970
  /**
11969
11971
  * Event triggered when fragments are disposed.
11970
11972
  */
11971
- C(this, "onFragmentsDisposed", new Z());
11973
+ C(this, "onFragmentsDisposed", new j());
11972
11974
  /**
11973
11975
  * DataMap containing all loaded fragments.
11974
11976
  * The key is the fragment's unique identifier, and the value is the fragment itself.
@@ -12182,11 +12184,11 @@ const _s = class _s extends At {
12182
12184
  */
12183
12185
  C(_s, "uuid", "fef46874-46a3-461b-8c44-2922ab77c806");
12184
12186
  let Tt = _s;
12185
- var hs = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
12187
+ var us = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
12186
12188
  function vc(c) {
12187
12189
  return c && c.__esModule && Object.prototype.hasOwnProperty.call(c, "default") ? c.default : c;
12188
12190
  }
12189
- function us(c) {
12191
+ function fs(c) {
12190
12192
  throw new Error('Could not dynamically require "' + c + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.');
12191
12193
  }
12192
12194
  var lo = { exports: {} };
@@ -12209,7 +12211,7 @@ https://github.com/nodeca/pako/blob/main/LICENSE
12209
12211
  function r(l, h) {
12210
12212
  if (!s[l]) {
12211
12213
  if (!e[l]) {
12212
- var f = typeof us == "function" && us;
12214
+ var f = typeof fs == "function" && fs;
12213
12215
  if (!h && f)
12214
12216
  return f(l, !0);
12215
12217
  if (o)
@@ -12225,7 +12227,7 @@ https://github.com/nodeca/pako/blob/main/LICENSE
12225
12227
  }
12226
12228
  return s[l].exports;
12227
12229
  }
12228
- for (var o = typeof us == "function" && us, a = 0; a < n.length; a++)
12230
+ for (var o = typeof fs == "function" && fs, a = 0; a < n.length; a++)
12229
12231
  r(n[a]);
12230
12232
  return r;
12231
12233
  }({ 1: [function(t, e, s) {
@@ -12328,20 +12330,20 @@ https://github.com/nodeca/pako/blob/main/LICENSE
12328
12330
  return T;
12329
12331
  }
12330
12332
  function r(u, d, E, T, p, m) {
12331
- var F, R, S = u.file, N = u.compression, y = m !== l.utf8encode, M = o.transformTo("string", m(S.name)), L = o.transformTo("string", l.utf8encode(S.name)), b = S.comment, G = o.transformTo("string", m(b)), O = o.transformTo("string", l.utf8encode(b)), w = L.length !== S.name.length, g = O.length !== b.length, v = "", j = "", V = "", et = S.dir, W = S.date, nt = { crc32: 0, compressedSize: 0, uncompressedSize: 0 };
12333
+ var F, R, S = u.file, N = u.compression, y = m !== l.utf8encode, M = o.transformTo("string", m(S.name)), L = o.transformTo("string", l.utf8encode(S.name)), b = S.comment, Y = o.transformTo("string", m(b)), O = o.transformTo("string", l.utf8encode(b)), w = L.length !== S.name.length, g = O.length !== b.length, v = "", q = "", G = "", et = S.dir, W = S.date, nt = { crc32: 0, compressedSize: 0, uncompressedSize: 0 };
12332
12334
  d && !E || (nt.crc32 = u.crc32, nt.compressedSize = u.compressedSize, nt.uncompressedSize = u.uncompressedSize);
12333
- var Y = 0;
12334
- d && (Y |= 8), y || !w && !g || (Y |= 2048);
12335
+ var V = 0;
12336
+ d && (V |= 8), y || !w && !g || (V |= 2048);
12335
12337
  var x = 0, ot = 0;
12336
12338
  et && (x |= 16), p === "UNIX" ? (ot = 798, x |= function(tt, St) {
12337
12339
  var yt = tt;
12338
12340
  return tt || (yt = St ? 16893 : 33204), (65535 & yt) << 16;
12339
12341
  }(S.unixPermissions, et)) : (ot = 20, x |= function(tt) {
12340
12342
  return 63 & (tt || 0);
12341
- }(S.dosPermissions)), F = W.getUTCHours(), F <<= 6, F |= W.getUTCMinutes(), F <<= 5, F |= W.getUTCSeconds() / 2, R = W.getUTCFullYear() - 1980, R <<= 4, R |= W.getUTCMonth() + 1, R <<= 5, R |= W.getUTCDate(), w && (j = n(1, 1) + n(h(M), 4) + L, v += "up" + n(j.length, 2) + j), g && (V = n(1, 1) + n(h(G), 4) + O, v += "uc" + n(V.length, 2) + V);
12343
+ }(S.dosPermissions)), F = W.getUTCHours(), F <<= 6, F |= W.getUTCMinutes(), F <<= 5, F |= W.getUTCSeconds() / 2, R = W.getUTCFullYear() - 1980, R <<= 4, R |= W.getUTCMonth() + 1, R <<= 5, R |= W.getUTCDate(), w && (q = n(1, 1) + n(h(M), 4) + L, v += "up" + n(q.length, 2) + q), g && (G = n(1, 1) + n(h(Y), 4) + O, v += "uc" + n(G.length, 2) + G);
12342
12344
  var it = "";
12343
12345
  return it += `
12344
- \0`, it += n(Y, 2), it += N.magic, it += n(F, 2), it += n(R, 2), it += n(nt.crc32, 4), it += n(nt.compressedSize, 4), it += n(nt.uncompressedSize, 4), it += n(M.length, 2), it += n(v.length, 2), { fileRecord: f.LOCAL_FILE_HEADER + it + M + v, dirRecord: f.CENTRAL_FILE_HEADER + n(ot, 2) + it + n(G.length, 2) + "\0\0\0\0" + n(x, 4) + n(T, 4) + M + v + G };
12346
+ \0`, it += n(V, 2), it += N.magic, it += n(F, 2), it += n(R, 2), it += n(nt.crc32, 4), it += n(nt.compressedSize, 4), it += n(nt.uncompressedSize, 4), it += n(M.length, 2), it += n(v.length, 2), { fileRecord: f.LOCAL_FILE_HEADER + it + M + v, dirRecord: f.CENTRAL_FILE_HEADER + n(ot, 2) + it + n(Y.length, 2) + "\0\0\0\0" + n(x, 4) + n(T, 4) + M + v + Y };
12345
12347
  }
12346
12348
  var o = t("../utils"), a = t("../stream/GenericWorker"), l = t("../utf8"), h = t("../crc32"), f = t("../signature");
12347
12349
  function I(u, d, E, T) {
@@ -12529,8 +12531,8 @@ https://github.com/nodeca/pako/blob/main/LICENSE
12529
12531
  function n(S, N, y) {
12530
12532
  var M, L = o.getTypeOf(N), b = o.extend(y || {}, h);
12531
12533
  b.date = b.date || /* @__PURE__ */ new Date(), b.compression !== null && (b.compression = b.compression.toUpperCase()), typeof b.unixPermissions == "string" && (b.unixPermissions = parseInt(b.unixPermissions, 8)), b.unixPermissions && 16384 & b.unixPermissions && (b.dir = !0), b.dosPermissions && 16 & b.dosPermissions && (b.dir = !0), b.dir && (S = p(S)), b.createFolders && (M = T(S)) && m.call(this, M, !0);
12532
- var G = L === "string" && b.binary === !1 && b.base64 === !1;
12533
- y && y.binary !== void 0 || (b.binary = !G), (N instanceof f && N.uncompressedSize === 0 || b.dir || !N || N.length === 0) && (b.base64 = !1, b.binary = !0, N = "", b.compression = "STORE", L = "string");
12534
+ var Y = L === "string" && b.binary === !1 && b.base64 === !1;
12535
+ y && y.binary !== void 0 || (b.binary = !Y), (N instanceof f && N.uncompressedSize === 0 || b.dir || !N || N.length === 0) && (b.base64 = !1, b.binary = !0, N = "", b.compression = "STORE", L = "string");
12534
12536
  var O = null;
12535
12537
  O = N instanceof f || N instanceof a ? N : d.isNode && d.isStream(N) ? new E(S, N) : o.prepareContent(S, N, b.binary, b.optimizedBinaryString, b.base64);
12536
12538
  var w = new I(S, O, b);
@@ -12564,8 +12566,8 @@ https://github.com/nodeca/pako/blob/main/LICENSE
12564
12566
  return S = this.root + S, n.call(this, S, N, y), this;
12565
12567
  if (F(S)) {
12566
12568
  var M = S;
12567
- return this.filter(function(b, G) {
12568
- return !G.dir && M.test(b);
12569
+ return this.filter(function(b, Y) {
12570
+ return !Y.dir && M.test(b);
12569
12571
  });
12570
12572
  }
12571
12573
  var L = this.files[this.root + S];
@@ -12862,7 +12864,7 @@ https://github.com/nodeca/pako/blob/main/LICENSE
12862
12864
  return n.transformTo(y, M);
12863
12865
  }
12864
12866
  }(R, function(y, M) {
12865
- var L, b = 0, G = null, O = 0;
12867
+ var L, b = 0, Y = null, O = 0;
12866
12868
  for (L = 0; L < M.length; L++)
12867
12869
  O += M[L].length;
12868
12870
  switch (y) {
@@ -12871,9 +12873,9 @@ https://github.com/nodeca/pako/blob/main/LICENSE
12871
12873
  case "array":
12872
12874
  return Array.prototype.concat.apply([], M);
12873
12875
  case "uint8array":
12874
- for (G = new Uint8Array(O), L = 0; L < M.length; L++)
12875
- G.set(M[L], b), b += M[L].length;
12876
- return G;
12876
+ for (Y = new Uint8Array(O), L = 0; L < M.length; L++)
12877
+ Y.set(M[L], b), b += M[L].length;
12878
+ return Y;
12877
12879
  case "nodebuffer":
12878
12880
  return Buffer.concat(M);
12879
12881
  default:
@@ -13361,7 +13363,7 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13361
13363
  e.exports = function(E) {
13362
13364
  u.push(E) !== 1 || o || r();
13363
13365
  };
13364
- }).call(this, typeof hs < "u" ? hs : typeof self < "u" ? self : typeof window < "u" ? window : {});
13366
+ }).call(this, typeof us < "u" ? us : typeof self < "u" ? self : typeof window < "u" ? window : {});
13365
13367
  }, {}], 37: [function(t, e, s) {
13366
13368
  var n = t("immediate");
13367
13369
  function r() {
@@ -13476,9 +13478,9 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13476
13478
  for (var S = new Array(F), N = 0, y = -1, M = new this(r); ++y < F; )
13477
13479
  L(p[y], y);
13478
13480
  return M;
13479
- function L(b, G) {
13481
+ function L(b, Y) {
13480
13482
  m.resolve(b).then(function(O) {
13481
- S[G] = O, ++N !== F || R || (R = !0, o.resolve(M, S));
13483
+ S[Y] = O, ++N !== F || R || (R = !0, o.resolve(M, S));
13482
13484
  }, function(O) {
13483
13485
  R || (R = !0, o.reject(M, O));
13484
13486
  });
@@ -13703,7 +13705,7 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13703
13705
  return -1 ^ r;
13704
13706
  };
13705
13707
  }, {}], 46: [function(t, e, s) {
13706
- var n, r = t("../utils/common"), o = t("./trees"), a = t("./adler32"), l = t("./crc32"), h = t("./messages"), f = 0, I = 4, u = 0, d = -2, E = -1, T = 4, p = 2, m = 8, F = 9, R = 286, S = 30, N = 19, y = 2 * R + 1, M = 15, L = 3, b = 258, G = b + L + 1, O = 42, w = 113, g = 1, v = 2, j = 3, V = 4;
13708
+ var n, r = t("../utils/common"), o = t("./trees"), a = t("./adler32"), l = t("./crc32"), h = t("./messages"), f = 0, I = 4, u = 0, d = -2, E = -1, T = 4, p = 2, m = 8, F = 9, R = 286, S = 30, N = 19, y = 2 * R + 1, M = 15, L = 3, b = 258, Y = b + L + 1, O = 42, w = 113, g = 1, v = 2, q = 3, G = 4;
13707
13709
  function et(A, X) {
13708
13710
  return A.msg = h[X], X;
13709
13711
  }
@@ -13714,12 +13716,12 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13714
13716
  for (var X = A.length; 0 <= --X; )
13715
13717
  A[X] = 0;
13716
13718
  }
13717
- function Y(A) {
13719
+ function V(A) {
13718
13720
  var X = A.state, k = X.pending;
13719
13721
  k > A.avail_out && (k = A.avail_out), k !== 0 && (r.arraySet(A.output, X.pending_buf, X.pending_out, k, A.next_out), A.next_out += k, X.pending_out += k, A.total_out += k, A.avail_out -= k, X.pending -= k, X.pending === 0 && (X.pending_out = 0));
13720
13722
  }
13721
13723
  function x(A, X) {
13722
- o._tr_flush_block(A, 0 <= A.block_start ? A.block_start : -1, A.strstart - A.block_start, X), A.block_start = A.strstart, Y(A.strm);
13724
+ o._tr_flush_block(A, 0 <= A.block_start ? A.block_start : -1, A.strstart - A.block_start, X), A.block_start = A.strstart, V(A.strm);
13723
13725
  }
13724
13726
  function ot(A, X) {
13725
13727
  A.pending_buf[A.pending++] = X;
@@ -13728,8 +13730,8 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13728
13730
  A.pending_buf[A.pending++] = X >>> 8 & 255, A.pending_buf[A.pending++] = 255 & X;
13729
13731
  }
13730
13732
  function tt(A, X) {
13731
- var k, P, _ = A.max_chain_length, U = A.strstart, $ = A.prev_length, q = A.nice_match, B = A.strstart > A.w_size - G ? A.strstart - (A.w_size - G) : 0, K = A.window, st = A.w_mask, J = A.prev, ct = A.strstart + b, Rt = K[U + $ - 1], dt = K[U + $];
13732
- A.prev_length >= A.good_match && (_ >>= 2), q > A.lookahead && (q = A.lookahead);
13733
+ var k, P, _ = A.max_chain_length, U = A.strstart, $ = A.prev_length, Z = A.nice_match, B = A.strstart > A.w_size - Y ? A.strstart - (A.w_size - Y) : 0, K = A.window, st = A.w_mask, J = A.prev, ct = A.strstart + b, Rt = K[U + $ - 1], dt = K[U + $];
13734
+ A.prev_length >= A.good_match && (_ >>= 2), Z > A.lookahead && (Z = A.lookahead);
13733
13735
  do
13734
13736
  if (K[(k = X) + $] === dt && K[k + $ - 1] === Rt && K[k] === K[U] && K[++k] === K[U + 1]) {
13735
13737
  U += 2, k++;
@@ -13737,7 +13739,7 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13737
13739
  ;
13738
13740
  while (K[++U] === K[++k] && K[++U] === K[++k] && K[++U] === K[++k] && K[++U] === K[++k] && K[++U] === K[++k] && K[++U] === K[++k] && K[++U] === K[++k] && K[++U] === K[++k] && U < ct);
13739
13741
  if (P = b - (ct - U), U = ct - b, $ < P) {
13740
- if (A.match_start = X, q <= ($ = P))
13742
+ if (A.match_start = X, Z <= ($ = P))
13741
13743
  break;
13742
13744
  Rt = K[U + $ - 1], dt = K[U + $];
13743
13745
  }
@@ -13746,9 +13748,9 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13746
13748
  return $ <= A.lookahead ? $ : A.lookahead;
13747
13749
  }
13748
13750
  function St(A) {
13749
- var X, k, P, _, U, $, q, B, K, st, J = A.w_size;
13751
+ var X, k, P, _, U, $, Z, B, K, st, J = A.w_size;
13750
13752
  do {
13751
- if (_ = A.window_size - A.lookahead - A.strstart, A.strstart >= J + (J - G)) {
13753
+ if (_ = A.window_size - A.lookahead - A.strstart, A.strstart >= J + (J - Y)) {
13752
13754
  for (r.arraySet(A.window, A.window, J, J, 0), A.match_start -= J, A.strstart -= J, A.block_start -= J, X = k = A.hash_size; P = A.head[--X], A.head[X] = J <= P ? P - J : 0, --k; )
13753
13755
  ;
13754
13756
  for (X = k = J; P = A.prev[--X], A.prev[X] = J <= P ? P - J : 0, --k; )
@@ -13757,20 +13759,20 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13757
13759
  }
13758
13760
  if (A.strm.avail_in === 0)
13759
13761
  break;
13760
- if ($ = A.strm, q = A.window, B = A.strstart + A.lookahead, K = _, st = void 0, st = $.avail_in, K < st && (st = K), k = st === 0 ? 0 : ($.avail_in -= st, r.arraySet(q, $.input, $.next_in, st, B), $.state.wrap === 1 ? $.adler = a($.adler, q, st, B) : $.state.wrap === 2 && ($.adler = l($.adler, q, st, B)), $.next_in += st, $.total_in += st, st), A.lookahead += k, A.lookahead + A.insert >= L)
13762
+ if ($ = A.strm, Z = A.window, B = A.strstart + A.lookahead, K = _, st = void 0, st = $.avail_in, K < st && (st = K), k = st === 0 ? 0 : ($.avail_in -= st, r.arraySet(Z, $.input, $.next_in, st, B), $.state.wrap === 1 ? $.adler = a($.adler, Z, st, B) : $.state.wrap === 2 && ($.adler = l($.adler, Z, st, B)), $.next_in += st, $.total_in += st, st), A.lookahead += k, A.lookahead + A.insert >= L)
13761
13763
  for (U = A.strstart - A.insert, A.ins_h = A.window[U], A.ins_h = (A.ins_h << A.hash_shift ^ A.window[U + 1]) & A.hash_mask; A.insert && (A.ins_h = (A.ins_h << A.hash_shift ^ A.window[U + L - 1]) & A.hash_mask, A.prev[U & A.w_mask] = A.head[A.ins_h], A.head[A.ins_h] = U, U++, A.insert--, !(A.lookahead + A.insert < L)); )
13762
13764
  ;
13763
- } while (A.lookahead < G && A.strm.avail_in !== 0);
13765
+ } while (A.lookahead < Y && A.strm.avail_in !== 0);
13764
13766
  }
13765
13767
  function yt(A, X) {
13766
13768
  for (var k, P; ; ) {
13767
- if (A.lookahead < G) {
13768
- if (St(A), A.lookahead < G && X === f)
13769
+ if (A.lookahead < Y) {
13770
+ if (St(A), A.lookahead < Y && X === f)
13769
13771
  return g;
13770
13772
  if (A.lookahead === 0)
13771
13773
  break;
13772
13774
  }
13773
- if (k = 0, A.lookahead >= L && (A.ins_h = (A.ins_h << A.hash_shift ^ A.window[A.strstart + L - 1]) & A.hash_mask, k = A.prev[A.strstart & A.w_mask] = A.head[A.ins_h], A.head[A.ins_h] = A.strstart), k !== 0 && A.strstart - k <= A.w_size - G && (A.match_length = tt(A, k)), A.match_length >= L)
13775
+ if (k = 0, A.lookahead >= L && (A.ins_h = (A.ins_h << A.hash_shift ^ A.window[A.strstart + L - 1]) & A.hash_mask, k = A.prev[A.strstart & A.w_mask] = A.head[A.ins_h], A.head[A.ins_h] = A.strstart), k !== 0 && A.strstart - k <= A.w_size - Y && (A.match_length = tt(A, k)), A.match_length >= L)
13774
13776
  if (P = o._tr_tally(A, A.strstart - A.match_start, A.match_length - L), A.lookahead -= A.match_length, A.match_length <= A.max_lazy_match && A.lookahead >= L) {
13775
13777
  for (A.match_length--; A.strstart++, A.ins_h = (A.ins_h << A.hash_shift ^ A.window[A.strstart + L - 1]) & A.hash_mask, k = A.prev[A.strstart & A.w_mask] = A.head[A.ins_h], A.head[A.ins_h] = A.strstart, --A.match_length != 0; )
13776
13778
  ;
@@ -13782,17 +13784,17 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13782
13784
  if (P && (x(A, !1), A.strm.avail_out === 0))
13783
13785
  return g;
13784
13786
  }
13785
- return A.insert = A.strstart < L - 1 ? A.strstart : L - 1, X === I ? (x(A, !0), A.strm.avail_out === 0 ? j : V) : A.last_lit && (x(A, !1), A.strm.avail_out === 0) ? g : v;
13787
+ return A.insert = A.strstart < L - 1 ? A.strstart : L - 1, X === I ? (x(A, !0), A.strm.avail_out === 0 ? q : G) : A.last_lit && (x(A, !1), A.strm.avail_out === 0) ? g : v;
13786
13788
  }
13787
13789
  function at(A, X) {
13788
13790
  for (var k, P, _; ; ) {
13789
- if (A.lookahead < G) {
13790
- if (St(A), A.lookahead < G && X === f)
13791
+ if (A.lookahead < Y) {
13792
+ if (St(A), A.lookahead < Y && X === f)
13791
13793
  return g;
13792
13794
  if (A.lookahead === 0)
13793
13795
  break;
13794
13796
  }
13795
- if (k = 0, A.lookahead >= L && (A.ins_h = (A.ins_h << A.hash_shift ^ A.window[A.strstart + L - 1]) & A.hash_mask, k = A.prev[A.strstart & A.w_mask] = A.head[A.ins_h], A.head[A.ins_h] = A.strstart), A.prev_length = A.match_length, A.prev_match = A.match_start, A.match_length = L - 1, k !== 0 && A.prev_length < A.max_lazy_match && A.strstart - k <= A.w_size - G && (A.match_length = tt(A, k), A.match_length <= 5 && (A.strategy === 1 || A.match_length === L && 4096 < A.strstart - A.match_start) && (A.match_length = L - 1)), A.prev_length >= L && A.match_length <= A.prev_length) {
13797
+ if (k = 0, A.lookahead >= L && (A.ins_h = (A.ins_h << A.hash_shift ^ A.window[A.strstart + L - 1]) & A.hash_mask, k = A.prev[A.strstart & A.w_mask] = A.head[A.ins_h], A.head[A.ins_h] = A.strstart), A.prev_length = A.match_length, A.prev_match = A.match_start, A.match_length = L - 1, k !== 0 && A.prev_length < A.max_lazy_match && A.strstart - k <= A.w_size - Y && (A.match_length = tt(A, k), A.match_length <= 5 && (A.strategy === 1 || A.match_length === L && 4096 < A.strstart - A.match_start) && (A.match_length = L - 1)), A.prev_length >= L && A.match_length <= A.prev_length) {
13796
13798
  for (_ = A.strstart + A.lookahead - L, P = o._tr_tally(A, A.strstart - 1 - A.prev_match, A.prev_length - L), A.lookahead -= A.prev_length - 1, A.prev_length -= 2; ++A.strstart <= _ && (A.ins_h = (A.ins_h << A.hash_shift ^ A.window[A.strstart + L - 1]) & A.hash_mask, k = A.prev[A.strstart & A.w_mask] = A.head[A.ins_h], A.head[A.ins_h] = A.strstart), --A.prev_length != 0; )
13797
13799
  ;
13798
13800
  if (A.match_available = 0, A.match_length = L - 1, A.strstart++, P && (x(A, !1), A.strm.avail_out === 0))
@@ -13803,7 +13805,7 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13803
13805
  } else
13804
13806
  A.match_available = 1, A.strstart++, A.lookahead--;
13805
13807
  }
13806
- return A.match_available && (P = o._tr_tally(A, 0, A.window[A.strstart - 1]), A.match_available = 0), A.insert = A.strstart < L - 1 ? A.strstart : L - 1, X === I ? (x(A, !0), A.strm.avail_out === 0 ? j : V) : A.last_lit && (x(A, !1), A.strm.avail_out === 0) ? g : v;
13808
+ return A.match_available && (P = o._tr_tally(A, 0, A.window[A.strstart - 1]), A.match_available = 0), A.insert = A.strstart < L - 1 ? A.strstart : L - 1, X === I ? (x(A, !0), A.strm.avail_out === 0 ? q : G) : A.last_lit && (x(A, !1), A.strm.avail_out === 0) ? g : v;
13807
13809
  }
13808
13810
  function It(A, X, k, P, _) {
13809
13811
  this.good_length = A, this.max_lazy = X, this.nice_length = k, this.max_chain = P, this.func = _;
@@ -13828,8 +13830,8 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13828
13830
  if (X === E && (X = 6), P < 0 ? ($ = 0, P = -P) : 15 < P && ($ = 2, P -= 16), _ < 1 || F < _ || k !== m || P < 8 || 15 < P || X < 0 || 9 < X || U < 0 || T < U)
13829
13831
  return et(A, d);
13830
13832
  P === 8 && (P = 9);
13831
- var q = new ft();
13832
- return (A.state = q).strm = A, q.wrap = $, q.gzhead = null, q.w_bits = P, q.w_size = 1 << q.w_bits, q.w_mask = q.w_size - 1, q.hash_bits = _ + 7, q.hash_size = 1 << q.hash_bits, q.hash_mask = q.hash_size - 1, q.hash_shift = ~~((q.hash_bits + L - 1) / L), q.window = new r.Buf8(2 * q.w_size), q.head = new r.Buf16(q.hash_size), q.prev = new r.Buf16(q.w_size), q.lit_bufsize = 1 << _ + 6, q.pending_buf_size = 4 * q.lit_bufsize, q.pending_buf = new r.Buf8(q.pending_buf_size), q.d_buf = 1 * q.lit_bufsize, q.l_buf = 3 * q.lit_bufsize, q.level = X, q.strategy = U, q.method = k, Ht(A);
13833
+ var Z = new ft();
13834
+ return (A.state = Z).strm = A, Z.wrap = $, Z.gzhead = null, Z.w_bits = P, Z.w_size = 1 << Z.w_bits, Z.w_mask = Z.w_size - 1, Z.hash_bits = _ + 7, Z.hash_size = 1 << Z.hash_bits, Z.hash_mask = Z.hash_size - 1, Z.hash_shift = ~~((Z.hash_bits + L - 1) / L), Z.window = new r.Buf8(2 * Z.w_size), Z.head = new r.Buf16(Z.hash_size), Z.prev = new r.Buf16(Z.w_size), Z.lit_bufsize = 1 << _ + 6, Z.pending_buf_size = 4 * Z.lit_bufsize, Z.pending_buf = new r.Buf8(Z.pending_buf_size), Z.d_buf = 1 * Z.lit_bufsize, Z.l_buf = 3 * Z.lit_bufsize, Z.level = X, Z.strategy = U, Z.method = k, Ht(A);
13833
13835
  }
13834
13836
  n = [new It(0, 0, 0, 0, function(A, X) {
13835
13837
  var k = 65535;
@@ -13842,10 +13844,10 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13842
13844
  }
13843
13845
  A.strstart += A.lookahead, A.lookahead = 0;
13844
13846
  var P = A.block_start + k;
13845
- if ((A.strstart === 0 || A.strstart >= P) && (A.lookahead = A.strstart - P, A.strstart = P, x(A, !1), A.strm.avail_out === 0) || A.strstart - A.block_start >= A.w_size - G && (x(A, !1), A.strm.avail_out === 0))
13847
+ if ((A.strstart === 0 || A.strstart >= P) && (A.lookahead = A.strstart - P, A.strstart = P, x(A, !1), A.strm.avail_out === 0) || A.strstart - A.block_start >= A.w_size - Y && (x(A, !1), A.strm.avail_out === 0))
13846
13848
  return g;
13847
13849
  }
13848
- return A.insert = 0, X === I ? (x(A, !0), A.strm.avail_out === 0 ? j : V) : (A.strstart > A.block_start && (x(A, !1), A.strm.avail_out), g);
13850
+ return A.insert = 0, X === I ? (x(A, !0), A.strm.avail_out === 0 ? q : G) : (A.strstart > A.block_start && (x(A, !1), A.strm.avail_out), g);
13849
13851
  }), new It(4, 4, 8, 4, yt), new It(4, 5, 16, 8, yt), new It(4, 6, 32, 32, yt), new It(4, 4, 16, 16, at), new It(8, 16, 32, 32, at), new It(8, 16, 128, 128, at), new It(8, 32, 128, 256, at), new It(32, 128, 258, 1024, at), new It(32, 258, 258, 4096, at)], s.deflateInit = function(A, X) {
13850
13852
  return Dt(A, X, m, 15, 8, 0);
13851
13853
  }, s.deflateInit2 = Dt, s.deflateReset = Ht, s.deflateResetKeep = Ct, s.deflateSetHeader = function(A, X) {
@@ -13865,7 +13867,7 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13865
13867
  }
13866
13868
  if (P.status === 69)
13867
13869
  if (P.gzhead.extra) {
13868
- for (_ = P.pending; P.gzindex < (65535 & P.gzhead.extra.length) && (P.pending !== P.pending_buf_size || (P.gzhead.hcrc && P.pending > _ && (A.adler = l(A.adler, P.pending_buf, P.pending - _, _)), Y(A), _ = P.pending, P.pending !== P.pending_buf_size)); )
13870
+ for (_ = P.pending; P.gzindex < (65535 & P.gzhead.extra.length) && (P.pending !== P.pending_buf_size || (P.gzhead.hcrc && P.pending > _ && (A.adler = l(A.adler, P.pending_buf, P.pending - _, _)), V(A), _ = P.pending, P.pending !== P.pending_buf_size)); )
13869
13871
  ot(P, 255 & P.gzhead.extra[P.gzindex]), P.gzindex++;
13870
13872
  P.gzhead.hcrc && P.pending > _ && (A.adler = l(A.adler, P.pending_buf, P.pending - _, _)), P.gzindex === P.gzhead.extra.length && (P.gzindex = 0, P.status = 73);
13871
13873
  } else
@@ -13874,7 +13876,7 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13874
13876
  if (P.gzhead.name) {
13875
13877
  _ = P.pending;
13876
13878
  do {
13877
- if (P.pending === P.pending_buf_size && (P.gzhead.hcrc && P.pending > _ && (A.adler = l(A.adler, P.pending_buf, P.pending - _, _)), Y(A), _ = P.pending, P.pending === P.pending_buf_size)) {
13879
+ if (P.pending === P.pending_buf_size && (P.gzhead.hcrc && P.pending > _ && (A.adler = l(A.adler, P.pending_buf, P.pending - _, _)), V(A), _ = P.pending, P.pending === P.pending_buf_size)) {
13878
13880
  U = 1;
13879
13881
  break;
13880
13882
  }
@@ -13887,7 +13889,7 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13887
13889
  if (P.gzhead.comment) {
13888
13890
  _ = P.pending;
13889
13891
  do {
13890
- if (P.pending === P.pending_buf_size && (P.gzhead.hcrc && P.pending > _ && (A.adler = l(A.adler, P.pending_buf, P.pending - _, _)), Y(A), _ = P.pending, P.pending === P.pending_buf_size)) {
13892
+ if (P.pending === P.pending_buf_size && (P.gzhead.hcrc && P.pending > _ && (A.adler = l(A.adler, P.pending_buf, P.pending - _, _)), V(A), _ = P.pending, P.pending === P.pending_buf_size)) {
13891
13893
  U = 1;
13892
13894
  break;
13893
13895
  }
@@ -13896,15 +13898,15 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13896
13898
  P.gzhead.hcrc && P.pending > _ && (A.adler = l(A.adler, P.pending_buf, P.pending - _, _)), U === 0 && (P.status = 103);
13897
13899
  } else
13898
13900
  P.status = 103;
13899
- if (P.status === 103 && (P.gzhead.hcrc ? (P.pending + 2 > P.pending_buf_size && Y(A), P.pending + 2 <= P.pending_buf_size && (ot(P, 255 & A.adler), ot(P, A.adler >> 8 & 255), A.adler = 0, P.status = w)) : P.status = w), P.pending !== 0) {
13900
- if (Y(A), A.avail_out === 0)
13901
+ if (P.status === 103 && (P.gzhead.hcrc ? (P.pending + 2 > P.pending_buf_size && V(A), P.pending + 2 <= P.pending_buf_size && (ot(P, 255 & A.adler), ot(P, A.adler >> 8 & 255), A.adler = 0, P.status = w)) : P.status = w), P.pending !== 0) {
13902
+ if (V(A), A.avail_out === 0)
13901
13903
  return P.last_flush = -1, u;
13902
13904
  } else if (A.avail_in === 0 && W(X) <= W(k) && X !== I)
13903
13905
  return et(A, -5);
13904
13906
  if (P.status === 666 && A.avail_in !== 0)
13905
13907
  return et(A, -5);
13906
13908
  if (A.avail_in !== 0 || P.lookahead !== 0 || X !== f && P.status !== 666) {
13907
- var q = P.strategy === 2 ? function(B, K) {
13909
+ var Z = P.strategy === 2 ? function(B, K) {
13908
13910
  for (var st; ; ) {
13909
13911
  if (B.lookahead === 0 && (St(B), B.lookahead === 0)) {
13910
13912
  if (K === f)
@@ -13914,7 +13916,7 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13914
13916
  if (B.match_length = 0, st = o._tr_tally(B, 0, B.window[B.strstart]), B.lookahead--, B.strstart++, st && (x(B, !1), B.strm.avail_out === 0))
13915
13917
  return g;
13916
13918
  }
13917
- return B.insert = 0, K === I ? (x(B, !0), B.strm.avail_out === 0 ? j : V) : B.last_lit && (x(B, !1), B.strm.avail_out === 0) ? g : v;
13919
+ return B.insert = 0, K === I ? (x(B, !0), B.strm.avail_out === 0 ? q : G) : B.last_lit && (x(B, !1), B.strm.avail_out === 0) ? g : v;
13918
13920
  }(P, X) : P.strategy === 3 ? function(B, K) {
13919
13921
  for (var st, J, ct, Rt, dt = B.window; ; ) {
13920
13922
  if (B.lookahead <= b) {
@@ -13933,27 +13935,27 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13933
13935
  if (B.match_length >= L ? (st = o._tr_tally(B, 1, B.match_length - L), B.lookahead -= B.match_length, B.strstart += B.match_length, B.match_length = 0) : (st = o._tr_tally(B, 0, B.window[B.strstart]), B.lookahead--, B.strstart++), st && (x(B, !1), B.strm.avail_out === 0))
13934
13936
  return g;
13935
13937
  }
13936
- return B.insert = 0, K === I ? (x(B, !0), B.strm.avail_out === 0 ? j : V) : B.last_lit && (x(B, !1), B.strm.avail_out === 0) ? g : v;
13938
+ return B.insert = 0, K === I ? (x(B, !0), B.strm.avail_out === 0 ? q : G) : B.last_lit && (x(B, !1), B.strm.avail_out === 0) ? g : v;
13937
13939
  }(P, X) : n[P.level].func(P, X);
13938
- if (q !== j && q !== V || (P.status = 666), q === g || q === j)
13940
+ if (Z !== q && Z !== G || (P.status = 666), Z === g || Z === q)
13939
13941
  return A.avail_out === 0 && (P.last_flush = -1), u;
13940
- if (q === v && (X === 1 ? o._tr_align(P) : X !== 5 && (o._tr_stored_block(P, 0, 0, !1), X === 3 && (nt(P.head), P.lookahead === 0 && (P.strstart = 0, P.block_start = 0, P.insert = 0))), Y(A), A.avail_out === 0))
13942
+ if (Z === v && (X === 1 ? o._tr_align(P) : X !== 5 && (o._tr_stored_block(P, 0, 0, !1), X === 3 && (nt(P.head), P.lookahead === 0 && (P.strstart = 0, P.block_start = 0, P.insert = 0))), V(A), A.avail_out === 0))
13941
13943
  return P.last_flush = -1, u;
13942
13944
  }
13943
- return X !== I ? u : P.wrap <= 0 ? 1 : (P.wrap === 2 ? (ot(P, 255 & A.adler), ot(P, A.adler >> 8 & 255), ot(P, A.adler >> 16 & 255), ot(P, A.adler >> 24 & 255), ot(P, 255 & A.total_in), ot(P, A.total_in >> 8 & 255), ot(P, A.total_in >> 16 & 255), ot(P, A.total_in >> 24 & 255)) : (it(P, A.adler >>> 16), it(P, 65535 & A.adler)), Y(A), 0 < P.wrap && (P.wrap = -P.wrap), P.pending !== 0 ? u : 1);
13945
+ return X !== I ? u : P.wrap <= 0 ? 1 : (P.wrap === 2 ? (ot(P, 255 & A.adler), ot(P, A.adler >> 8 & 255), ot(P, A.adler >> 16 & 255), ot(P, A.adler >> 24 & 255), ot(P, 255 & A.total_in), ot(P, A.total_in >> 8 & 255), ot(P, A.total_in >> 16 & 255), ot(P, A.total_in >> 24 & 255)) : (it(P, A.adler >>> 16), it(P, 65535 & A.adler)), V(A), 0 < P.wrap && (P.wrap = -P.wrap), P.pending !== 0 ? u : 1);
13944
13946
  }, s.deflateEnd = function(A) {
13945
13947
  var X;
13946
13948
  return A && A.state ? (X = A.state.status) !== O && X !== 69 && X !== 73 && X !== 91 && X !== 103 && X !== w && X !== 666 ? et(A, d) : (A.state = null, X === w ? et(A, -3) : u) : d;
13947
13949
  }, s.deflateSetDictionary = function(A, X) {
13948
- var k, P, _, U, $, q, B, K, st = X.length;
13950
+ var k, P, _, U, $, Z, B, K, st = X.length;
13949
13951
  if (!A || !A.state || (U = (k = A.state).wrap) === 2 || U === 1 && k.status !== O || k.lookahead)
13950
13952
  return d;
13951
- for (U === 1 && (A.adler = a(A.adler, X, st, 0)), k.wrap = 0, st >= k.w_size && (U === 0 && (nt(k.head), k.strstart = 0, k.block_start = 0, k.insert = 0), K = new r.Buf8(k.w_size), r.arraySet(K, X, st - k.w_size, k.w_size, 0), X = K, st = k.w_size), $ = A.avail_in, q = A.next_in, B = A.input, A.avail_in = st, A.next_in = 0, A.input = X, St(k); k.lookahead >= L; ) {
13953
+ for (U === 1 && (A.adler = a(A.adler, X, st, 0)), k.wrap = 0, st >= k.w_size && (U === 0 && (nt(k.head), k.strstart = 0, k.block_start = 0, k.insert = 0), K = new r.Buf8(k.w_size), r.arraySet(K, X, st - k.w_size, k.w_size, 0), X = K, st = k.w_size), $ = A.avail_in, Z = A.next_in, B = A.input, A.avail_in = st, A.next_in = 0, A.input = X, St(k); k.lookahead >= L; ) {
13952
13954
  for (P = k.strstart, _ = k.lookahead - (L - 1); k.ins_h = (k.ins_h << k.hash_shift ^ k.window[P + L - 1]) & k.hash_mask, k.prev[P & k.w_mask] = k.head[k.ins_h], k.head[k.ins_h] = P, P++, --_; )
13953
13955
  ;
13954
13956
  k.strstart = P, k.lookahead = L - 1, St(k);
13955
13957
  }
13956
- return k.strstart += k.lookahead, k.block_start = k.strstart, k.insert = k.lookahead, k.lookahead = 0, k.match_length = k.prev_length = L - 1, k.match_available = 0, A.next_in = q, A.input = B, A.avail_in = $, k.wrap = U, u;
13958
+ return k.strstart += k.lookahead, k.block_start = k.strstart, k.insert = k.lookahead, k.lookahead = 0, k.match_length = k.prev_length = L - 1, k.match_available = 0, A.next_in = Z, A.input = B, A.avail_in = $, k.wrap = U, u;
13957
13959
  }, s.deflateInfo = "pako deflate (from Nodeca project)";
13958
13960
  }, { "../utils/common": 41, "./adler32": 43, "./crc32": 45, "./messages": 51, "./trees": 52 }], 47: [function(t, e, s) {
13959
13961
  e.exports = function() {
@@ -13961,7 +13963,7 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13961
13963
  };
13962
13964
  }, {}], 48: [function(t, e, s) {
13963
13965
  e.exports = function(n, r) {
13964
- var o, a, l, h, f, I, u, d, E, T, p, m, F, R, S, N, y, M, L, b, G, O, w, g, v;
13966
+ var o, a, l, h, f, I, u, d, E, T, p, m, F, R, S, N, y, M, L, b, Y, O, w, g, v;
13965
13967
  o = n.state, a = n.next_in, g = n.input, l = a + (n.avail_in - 5), h = n.next_out, v = n.output, f = h - (r - n.avail_out), I = h + (n.avail_out - 257), u = o.dmax, d = o.wsize, E = o.whave, T = o.wnext, p = o.window, m = o.hold, F = o.bits, R = o.lencode, S = o.distcode, N = (1 << o.lenbits) - 1, y = (1 << o.distbits) - 1;
13966
13968
  t:
13967
13969
  do {
@@ -13994,12 +13996,12 @@ https://github.com/nodeca/pako/blob/main/LICENSE
13994
13996
  n.msg = "invalid distance code", o.mode = 30;
13995
13997
  break t;
13996
13998
  }
13997
- if (G = 65535 & M, F < (L &= 15) && (m += g[a++] << F, (F += 8) < L && (m += g[a++] << F, F += 8)), u < (G += m & (1 << L) - 1)) {
13999
+ if (Y = 65535 & M, F < (L &= 15) && (m += g[a++] << F, (F += 8) < L && (m += g[a++] << F, F += 8)), u < (Y += m & (1 << L) - 1)) {
13998
14000
  n.msg = "invalid distance too far back", o.mode = 30;
13999
14001
  break t;
14000
14002
  }
14001
- if (m >>>= L, F -= L, (L = h - f) < G) {
14002
- if (E < (L = G - L) && o.sane) {
14003
+ if (m >>>= L, F -= L, (L = h - f) < Y) {
14004
+ if (E < (L = Y - L) && o.sane) {
14003
14005
  n.msg = "invalid distance too far back", o.mode = 30;
14004
14006
  break t;
14005
14007
  }
@@ -14007,7 +14009,7 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14007
14009
  if (O += d - L, L < b) {
14008
14010
  for (b -= L; v[h++] = p[O++], --L; )
14009
14011
  ;
14010
- O = h - G, w = v;
14012
+ O = h - Y, w = v;
14011
14013
  }
14012
14014
  } else if (T < L) {
14013
14015
  if (O += d + T - L, (L -= T) < b) {
@@ -14016,19 +14018,19 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14016
14018
  if (O = 0, T < b) {
14017
14019
  for (b -= L = T; v[h++] = p[O++], --L; )
14018
14020
  ;
14019
- O = h - G, w = v;
14021
+ O = h - Y, w = v;
14020
14022
  }
14021
14023
  }
14022
14024
  } else if (O += T - L, L < b) {
14023
14025
  for (b -= L; v[h++] = p[O++], --L; )
14024
14026
  ;
14025
- O = h - G, w = v;
14027
+ O = h - Y, w = v;
14026
14028
  }
14027
14029
  for (; 2 < b; )
14028
14030
  v[h++] = w[O++], v[h++] = w[O++], v[h++] = w[O++], b -= 3;
14029
14031
  b && (v[h++] = w[O++], 1 < b && (v[h++] = w[O++]));
14030
14032
  } else {
14031
- for (O = h - G; v[h++] = v[O++], v[h++] = v[O++], v[h++] = v[O++], 2 < (b -= 3); )
14033
+ for (O = h - Y; v[h++] = v[O++], v[h++] = v[O++], v[h++] = v[O++], 2 < (b -= 3); )
14032
14034
  ;
14033
14035
  b && (v[h++] = v[O++], 1 < b && (v[h++] = v[O++]));
14034
14036
  }
@@ -14082,17 +14084,17 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14082
14084
  }
14083
14085
  O.lencode = y, O.lenbits = 9, O.distcode = M, O.distbits = 5;
14084
14086
  }
14085
- function G(O, w, g, v) {
14086
- var j, V = O.state;
14087
- return V.window === null && (V.wsize = 1 << V.wbits, V.wnext = 0, V.whave = 0, V.window = new n.Buf8(V.wsize)), v >= V.wsize ? (n.arraySet(V.window, w, g - V.wsize, V.wsize, 0), V.wnext = 0, V.whave = V.wsize) : (v < (j = V.wsize - V.wnext) && (j = v), n.arraySet(V.window, w, g - v, j, V.wnext), (v -= j) ? (n.arraySet(V.window, w, g - v, v, 0), V.wnext = v, V.whave = V.wsize) : (V.wnext += j, V.wnext === V.wsize && (V.wnext = 0), V.whave < V.wsize && (V.whave += j))), 0;
14087
+ function Y(O, w, g, v) {
14088
+ var q, G = O.state;
14089
+ return G.window === null && (G.wsize = 1 << G.wbits, G.wnext = 0, G.whave = 0, G.window = new n.Buf8(G.wsize)), v >= G.wsize ? (n.arraySet(G.window, w, g - G.wsize, G.wsize, 0), G.wnext = 0, G.whave = G.wsize) : (v < (q = G.wsize - G.wnext) && (q = v), n.arraySet(G.window, w, g - v, q, G.wnext), (v -= q) ? (n.arraySet(G.window, w, g - v, v, 0), G.wnext = v, G.whave = G.wsize) : (G.wnext += q, G.wnext === G.wsize && (G.wnext = 0), G.whave < G.wsize && (G.whave += q))), 0;
14088
14090
  }
14089
14091
  s.inflateReset = R, s.inflateReset2 = S, s.inflateResetKeep = F, s.inflateInit = function(O) {
14090
14092
  return N(O, 15);
14091
14093
  }, s.inflateInit2 = N, s.inflate = function(O, w) {
14092
- var g, v, j, V, et, W, nt, Y, x, ot, it, tt, St, yt, at, It, ft, Ct, Ht, Dt, A, X, k, P, _ = 0, U = new n.Buf8(4), $ = [16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15];
14094
+ var g, v, q, G, et, W, nt, V, x, ot, it, tt, St, yt, at, It, ft, Ct, Ht, Dt, A, X, k, P, _ = 0, U = new n.Buf8(4), $ = [16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15];
14093
14095
  if (!O || !O.state || !O.output || !O.input && O.avail_in !== 0)
14094
14096
  return u;
14095
- (g = O.state).mode === 12 && (g.mode = 13), et = O.next_out, j = O.output, nt = O.avail_out, V = O.next_in, v = O.input, W = O.avail_in, Y = g.hold, x = g.bits, ot = W, it = nt, X = I;
14097
+ (g = O.state).mode === 12 && (g.mode = 13), et = O.next_out, q = O.output, nt = O.avail_out, G = O.next_in, v = O.input, W = O.avail_in, V = g.hold, x = g.bits, ot = W, it = nt, X = I;
14096
14098
  t:
14097
14099
  for (; ; )
14098
14100
  switch (g.mode) {
@@ -14104,35 +14106,35 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14104
14106
  for (; x < 16; ) {
14105
14107
  if (W === 0)
14106
14108
  break t;
14107
- W--, Y += v[V++] << x, x += 8;
14109
+ W--, V += v[G++] << x, x += 8;
14108
14110
  }
14109
- if (2 & g.wrap && Y === 35615) {
14110
- U[g.check = 0] = 255 & Y, U[1] = Y >>> 8 & 255, g.check = o(g.check, U, 2, 0), x = Y = 0, g.mode = 2;
14111
+ if (2 & g.wrap && V === 35615) {
14112
+ U[g.check = 0] = 255 & V, U[1] = V >>> 8 & 255, g.check = o(g.check, U, 2, 0), x = V = 0, g.mode = 2;
14111
14113
  break;
14112
14114
  }
14113
- if (g.flags = 0, g.head && (g.head.done = !1), !(1 & g.wrap) || (((255 & Y) << 8) + (Y >> 8)) % 31) {
14115
+ if (g.flags = 0, g.head && (g.head.done = !1), !(1 & g.wrap) || (((255 & V) << 8) + (V >> 8)) % 31) {
14114
14116
  O.msg = "incorrect header check", g.mode = 30;
14115
14117
  break;
14116
14118
  }
14117
- if ((15 & Y) != 8) {
14119
+ if ((15 & V) != 8) {
14118
14120
  O.msg = "unknown compression method", g.mode = 30;
14119
14121
  break;
14120
14122
  }
14121
- if (x -= 4, A = 8 + (15 & (Y >>>= 4)), g.wbits === 0)
14123
+ if (x -= 4, A = 8 + (15 & (V >>>= 4)), g.wbits === 0)
14122
14124
  g.wbits = A;
14123
14125
  else if (A > g.wbits) {
14124
14126
  O.msg = "invalid window size", g.mode = 30;
14125
14127
  break;
14126
14128
  }
14127
- g.dmax = 1 << A, O.adler = g.check = 1, g.mode = 512 & Y ? 10 : 12, x = Y = 0;
14129
+ g.dmax = 1 << A, O.adler = g.check = 1, g.mode = 512 & V ? 10 : 12, x = V = 0;
14128
14130
  break;
14129
14131
  case 2:
14130
14132
  for (; x < 16; ) {
14131
14133
  if (W === 0)
14132
14134
  break t;
14133
- W--, Y += v[V++] << x, x += 8;
14135
+ W--, V += v[G++] << x, x += 8;
14134
14136
  }
14135
- if (g.flags = Y, (255 & g.flags) != 8) {
14137
+ if (g.flags = V, (255 & g.flags) != 8) {
14136
14138
  O.msg = "unknown compression method", g.mode = 30;
14137
14139
  break;
14138
14140
  }
@@ -14140,43 +14142,43 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14140
14142
  O.msg = "unknown header flags set", g.mode = 30;
14141
14143
  break;
14142
14144
  }
14143
- g.head && (g.head.text = Y >> 8 & 1), 512 & g.flags && (U[0] = 255 & Y, U[1] = Y >>> 8 & 255, g.check = o(g.check, U, 2, 0)), x = Y = 0, g.mode = 3;
14145
+ g.head && (g.head.text = V >> 8 & 1), 512 & g.flags && (U[0] = 255 & V, U[1] = V >>> 8 & 255, g.check = o(g.check, U, 2, 0)), x = V = 0, g.mode = 3;
14144
14146
  case 3:
14145
14147
  for (; x < 32; ) {
14146
14148
  if (W === 0)
14147
14149
  break t;
14148
- W--, Y += v[V++] << x, x += 8;
14150
+ W--, V += v[G++] << x, x += 8;
14149
14151
  }
14150
- g.head && (g.head.time = Y), 512 & g.flags && (U[0] = 255 & Y, U[1] = Y >>> 8 & 255, U[2] = Y >>> 16 & 255, U[3] = Y >>> 24 & 255, g.check = o(g.check, U, 4, 0)), x = Y = 0, g.mode = 4;
14152
+ g.head && (g.head.time = V), 512 & g.flags && (U[0] = 255 & V, U[1] = V >>> 8 & 255, U[2] = V >>> 16 & 255, U[3] = V >>> 24 & 255, g.check = o(g.check, U, 4, 0)), x = V = 0, g.mode = 4;
14151
14153
  case 4:
14152
14154
  for (; x < 16; ) {
14153
14155
  if (W === 0)
14154
14156
  break t;
14155
- W--, Y += v[V++] << x, x += 8;
14157
+ W--, V += v[G++] << x, x += 8;
14156
14158
  }
14157
- g.head && (g.head.xflags = 255 & Y, g.head.os = Y >> 8), 512 & g.flags && (U[0] = 255 & Y, U[1] = Y >>> 8 & 255, g.check = o(g.check, U, 2, 0)), x = Y = 0, g.mode = 5;
14159
+ g.head && (g.head.xflags = 255 & V, g.head.os = V >> 8), 512 & g.flags && (U[0] = 255 & V, U[1] = V >>> 8 & 255, g.check = o(g.check, U, 2, 0)), x = V = 0, g.mode = 5;
14158
14160
  case 5:
14159
14161
  if (1024 & g.flags) {
14160
14162
  for (; x < 16; ) {
14161
14163
  if (W === 0)
14162
14164
  break t;
14163
- W--, Y += v[V++] << x, x += 8;
14165
+ W--, V += v[G++] << x, x += 8;
14164
14166
  }
14165
- g.length = Y, g.head && (g.head.extra_len = Y), 512 & g.flags && (U[0] = 255 & Y, U[1] = Y >>> 8 & 255, g.check = o(g.check, U, 2, 0)), x = Y = 0;
14167
+ g.length = V, g.head && (g.head.extra_len = V), 512 & g.flags && (U[0] = 255 & V, U[1] = V >>> 8 & 255, g.check = o(g.check, U, 2, 0)), x = V = 0;
14166
14168
  } else
14167
14169
  g.head && (g.head.extra = null);
14168
14170
  g.mode = 6;
14169
14171
  case 6:
14170
- if (1024 & g.flags && (W < (tt = g.length) && (tt = W), tt && (g.head && (A = g.head.extra_len - g.length, g.head.extra || (g.head.extra = new Array(g.head.extra_len)), n.arraySet(g.head.extra, v, V, tt, A)), 512 & g.flags && (g.check = o(g.check, v, tt, V)), W -= tt, V += tt, g.length -= tt), g.length))
14172
+ if (1024 & g.flags && (W < (tt = g.length) && (tt = W), tt && (g.head && (A = g.head.extra_len - g.length, g.head.extra || (g.head.extra = new Array(g.head.extra_len)), n.arraySet(g.head.extra, v, G, tt, A)), 512 & g.flags && (g.check = o(g.check, v, tt, G)), W -= tt, G += tt, g.length -= tt), g.length))
14171
14173
  break t;
14172
14174
  g.length = 0, g.mode = 7;
14173
14175
  case 7:
14174
14176
  if (2048 & g.flags) {
14175
14177
  if (W === 0)
14176
14178
  break t;
14177
- for (tt = 0; A = v[V + tt++], g.head && A && g.length < 65536 && (g.head.name += String.fromCharCode(A)), A && tt < W; )
14179
+ for (tt = 0; A = v[G + tt++], g.head && A && g.length < 65536 && (g.head.name += String.fromCharCode(A)), A && tt < W; )
14178
14180
  ;
14179
- if (512 & g.flags && (g.check = o(g.check, v, tt, V)), W -= tt, V += tt, A)
14181
+ if (512 & g.flags && (g.check = o(g.check, v, tt, G)), W -= tt, G += tt, A)
14180
14182
  break t;
14181
14183
  } else
14182
14184
  g.head && (g.head.name = null);
@@ -14185,9 +14187,9 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14185
14187
  if (4096 & g.flags) {
14186
14188
  if (W === 0)
14187
14189
  break t;
14188
- for (tt = 0; A = v[V + tt++], g.head && A && g.length < 65536 && (g.head.comment += String.fromCharCode(A)), A && tt < W; )
14190
+ for (tt = 0; A = v[G + tt++], g.head && A && g.length < 65536 && (g.head.comment += String.fromCharCode(A)), A && tt < W; )
14189
14191
  ;
14190
- if (512 & g.flags && (g.check = o(g.check, v, tt, V)), W -= tt, V += tt, A)
14192
+ if (512 & g.flags && (g.check = o(g.check, v, tt, G)), W -= tt, G += tt, A)
14191
14193
  break t;
14192
14194
  } else
14193
14195
  g.head && (g.head.comment = null);
@@ -14197,13 +14199,13 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14197
14199
  for (; x < 16; ) {
14198
14200
  if (W === 0)
14199
14201
  break t;
14200
- W--, Y += v[V++] << x, x += 8;
14202
+ W--, V += v[G++] << x, x += 8;
14201
14203
  }
14202
- if (Y !== (65535 & g.check)) {
14204
+ if (V !== (65535 & g.check)) {
14203
14205
  O.msg = "header crc mismatch", g.mode = 30;
14204
14206
  break;
14205
14207
  }
14206
- x = Y = 0;
14208
+ x = V = 0;
14207
14209
  }
14208
14210
  g.head && (g.head.hcrc = g.flags >> 9 & 1, g.head.done = !0), O.adler = g.check = 0, g.mode = 12;
14209
14211
  break;
@@ -14211,34 +14213,34 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14211
14213
  for (; x < 32; ) {
14212
14214
  if (W === 0)
14213
14215
  break t;
14214
- W--, Y += v[V++] << x, x += 8;
14216
+ W--, V += v[G++] << x, x += 8;
14215
14217
  }
14216
- O.adler = g.check = p(Y), x = Y = 0, g.mode = 11;
14218
+ O.adler = g.check = p(V), x = V = 0, g.mode = 11;
14217
14219
  case 11:
14218
14220
  if (g.havedict === 0)
14219
- return O.next_out = et, O.avail_out = nt, O.next_in = V, O.avail_in = W, g.hold = Y, g.bits = x, 2;
14221
+ return O.next_out = et, O.avail_out = nt, O.next_in = G, O.avail_in = W, g.hold = V, g.bits = x, 2;
14220
14222
  O.adler = g.check = 1, g.mode = 12;
14221
14223
  case 12:
14222
14224
  if (w === 5 || w === 6)
14223
14225
  break t;
14224
14226
  case 13:
14225
14227
  if (g.last) {
14226
- Y >>>= 7 & x, x -= 7 & x, g.mode = 27;
14228
+ V >>>= 7 & x, x -= 7 & x, g.mode = 27;
14227
14229
  break;
14228
14230
  }
14229
14231
  for (; x < 3; ) {
14230
14232
  if (W === 0)
14231
14233
  break t;
14232
- W--, Y += v[V++] << x, x += 8;
14234
+ W--, V += v[G++] << x, x += 8;
14233
14235
  }
14234
- switch (g.last = 1 & Y, x -= 1, 3 & (Y >>>= 1)) {
14236
+ switch (g.last = 1 & V, x -= 1, 3 & (V >>>= 1)) {
14235
14237
  case 0:
14236
14238
  g.mode = 14;
14237
14239
  break;
14238
14240
  case 1:
14239
14241
  if (b(g), g.mode = 20, w !== 6)
14240
14242
  break;
14241
- Y >>>= 2, x -= 2;
14243
+ V >>>= 2, x -= 2;
14242
14244
  break t;
14243
14245
  case 2:
14244
14246
  g.mode = 17;
@@ -14246,19 +14248,19 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14246
14248
  case 3:
14247
14249
  O.msg = "invalid block type", g.mode = 30;
14248
14250
  }
14249
- Y >>>= 2, x -= 2;
14251
+ V >>>= 2, x -= 2;
14250
14252
  break;
14251
14253
  case 14:
14252
- for (Y >>>= 7 & x, x -= 7 & x; x < 32; ) {
14254
+ for (V >>>= 7 & x, x -= 7 & x; x < 32; ) {
14253
14255
  if (W === 0)
14254
14256
  break t;
14255
- W--, Y += v[V++] << x, x += 8;
14257
+ W--, V += v[G++] << x, x += 8;
14256
14258
  }
14257
- if ((65535 & Y) != (Y >>> 16 ^ 65535)) {
14259
+ if ((65535 & V) != (V >>> 16 ^ 65535)) {
14258
14260
  O.msg = "invalid stored block lengths", g.mode = 30;
14259
14261
  break;
14260
14262
  }
14261
- if (g.length = 65535 & Y, x = Y = 0, g.mode = 15, w === 6)
14263
+ if (g.length = 65535 & V, x = V = 0, g.mode = 15, w === 6)
14262
14264
  break t;
14263
14265
  case 15:
14264
14266
  g.mode = 16;
@@ -14266,7 +14268,7 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14266
14268
  if (tt = g.length) {
14267
14269
  if (W < tt && (tt = W), nt < tt && (tt = nt), tt === 0)
14268
14270
  break t;
14269
- n.arraySet(j, v, V, tt, et), W -= tt, V += tt, nt -= tt, et += tt, g.length -= tt;
14271
+ n.arraySet(q, v, G, tt, et), W -= tt, G += tt, nt -= tt, et += tt, g.length -= tt;
14270
14272
  break;
14271
14273
  }
14272
14274
  g.mode = 12;
@@ -14275,9 +14277,9 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14275
14277
  for (; x < 14; ) {
14276
14278
  if (W === 0)
14277
14279
  break t;
14278
- W--, Y += v[V++] << x, x += 8;
14280
+ W--, V += v[G++] << x, x += 8;
14279
14281
  }
14280
- if (g.nlen = 257 + (31 & Y), Y >>>= 5, x -= 5, g.ndist = 1 + (31 & Y), Y >>>= 5, x -= 5, g.ncode = 4 + (15 & Y), Y >>>= 4, x -= 4, 286 < g.nlen || 30 < g.ndist) {
14282
+ if (g.nlen = 257 + (31 & V), V >>>= 5, x -= 5, g.ndist = 1 + (31 & V), V >>>= 5, x -= 5, g.ncode = 4 + (15 & V), V >>>= 4, x -= 4, 286 < g.nlen || 30 < g.ndist) {
14281
14283
  O.msg = "too many length or distance symbols", g.mode = 30;
14282
14284
  break;
14283
14285
  }
@@ -14287,9 +14289,9 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14287
14289
  for (; x < 3; ) {
14288
14290
  if (W === 0)
14289
14291
  break t;
14290
- W--, Y += v[V++] << x, x += 8;
14292
+ W--, V += v[G++] << x, x += 8;
14291
14293
  }
14292
- g.lens[$[g.have++]] = 7 & Y, Y >>>= 3, x -= 3;
14294
+ g.lens[$[g.have++]] = 7 & V, V >>>= 3, x -= 3;
14293
14295
  }
14294
14296
  for (; g.have < 19; )
14295
14297
  g.lens[$[g.have++]] = 0;
@@ -14300,39 +14302,39 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14300
14302
  g.have = 0, g.mode = 19;
14301
14303
  case 19:
14302
14304
  for (; g.have < g.nlen + g.ndist; ) {
14303
- for (; It = (_ = g.lencode[Y & (1 << g.lenbits) - 1]) >>> 16 & 255, ft = 65535 & _, !((at = _ >>> 24) <= x); ) {
14305
+ for (; It = (_ = g.lencode[V & (1 << g.lenbits) - 1]) >>> 16 & 255, ft = 65535 & _, !((at = _ >>> 24) <= x); ) {
14304
14306
  if (W === 0)
14305
14307
  break t;
14306
- W--, Y += v[V++] << x, x += 8;
14308
+ W--, V += v[G++] << x, x += 8;
14307
14309
  }
14308
14310
  if (ft < 16)
14309
- Y >>>= at, x -= at, g.lens[g.have++] = ft;
14311
+ V >>>= at, x -= at, g.lens[g.have++] = ft;
14310
14312
  else {
14311
14313
  if (ft === 16) {
14312
14314
  for (P = at + 2; x < P; ) {
14313
14315
  if (W === 0)
14314
14316
  break t;
14315
- W--, Y += v[V++] << x, x += 8;
14317
+ W--, V += v[G++] << x, x += 8;
14316
14318
  }
14317
- if (Y >>>= at, x -= at, g.have === 0) {
14319
+ if (V >>>= at, x -= at, g.have === 0) {
14318
14320
  O.msg = "invalid bit length repeat", g.mode = 30;
14319
14321
  break;
14320
14322
  }
14321
- A = g.lens[g.have - 1], tt = 3 + (3 & Y), Y >>>= 2, x -= 2;
14323
+ A = g.lens[g.have - 1], tt = 3 + (3 & V), V >>>= 2, x -= 2;
14322
14324
  } else if (ft === 17) {
14323
14325
  for (P = at + 3; x < P; ) {
14324
14326
  if (W === 0)
14325
14327
  break t;
14326
- W--, Y += v[V++] << x, x += 8;
14328
+ W--, V += v[G++] << x, x += 8;
14327
14329
  }
14328
- x -= at, A = 0, tt = 3 + (7 & (Y >>>= at)), Y >>>= 3, x -= 3;
14330
+ x -= at, A = 0, tt = 3 + (7 & (V >>>= at)), V >>>= 3, x -= 3;
14329
14331
  } else {
14330
14332
  for (P = at + 7; x < P; ) {
14331
14333
  if (W === 0)
14332
14334
  break t;
14333
- W--, Y += v[V++] << x, x += 8;
14335
+ W--, V += v[G++] << x, x += 8;
14334
14336
  }
14335
- x -= at, A = 0, tt = 11 + (127 & (Y >>>= at)), Y >>>= 7, x -= 7;
14337
+ x -= at, A = 0, tt = 11 + (127 & (V >>>= at)), V >>>= 7, x -= 7;
14336
14338
  }
14337
14339
  if (g.have + tt > g.nlen + g.ndist) {
14338
14340
  O.msg = "invalid bit length repeat", g.mode = 30;
@@ -14362,23 +14364,23 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14362
14364
  g.mode = 21;
14363
14365
  case 21:
14364
14366
  if (6 <= W && 258 <= nt) {
14365
- O.next_out = et, O.avail_out = nt, O.next_in = V, O.avail_in = W, g.hold = Y, g.bits = x, a(O, it), et = O.next_out, j = O.output, nt = O.avail_out, V = O.next_in, v = O.input, W = O.avail_in, Y = g.hold, x = g.bits, g.mode === 12 && (g.back = -1);
14367
+ O.next_out = et, O.avail_out = nt, O.next_in = G, O.avail_in = W, g.hold = V, g.bits = x, a(O, it), et = O.next_out, q = O.output, nt = O.avail_out, G = O.next_in, v = O.input, W = O.avail_in, V = g.hold, x = g.bits, g.mode === 12 && (g.back = -1);
14366
14368
  break;
14367
14369
  }
14368
- for (g.back = 0; It = (_ = g.lencode[Y & (1 << g.lenbits) - 1]) >>> 16 & 255, ft = 65535 & _, !((at = _ >>> 24) <= x); ) {
14370
+ for (g.back = 0; It = (_ = g.lencode[V & (1 << g.lenbits) - 1]) >>> 16 & 255, ft = 65535 & _, !((at = _ >>> 24) <= x); ) {
14369
14371
  if (W === 0)
14370
14372
  break t;
14371
- W--, Y += v[V++] << x, x += 8;
14373
+ W--, V += v[G++] << x, x += 8;
14372
14374
  }
14373
14375
  if (It && !(240 & It)) {
14374
- for (Ct = at, Ht = It, Dt = ft; It = (_ = g.lencode[Dt + ((Y & (1 << Ct + Ht) - 1) >> Ct)]) >>> 16 & 255, ft = 65535 & _, !(Ct + (at = _ >>> 24) <= x); ) {
14376
+ for (Ct = at, Ht = It, Dt = ft; It = (_ = g.lencode[Dt + ((V & (1 << Ct + Ht) - 1) >> Ct)]) >>> 16 & 255, ft = 65535 & _, !(Ct + (at = _ >>> 24) <= x); ) {
14375
14377
  if (W === 0)
14376
14378
  break t;
14377
- W--, Y += v[V++] << x, x += 8;
14379
+ W--, V += v[G++] << x, x += 8;
14378
14380
  }
14379
- Y >>>= Ct, x -= Ct, g.back += Ct;
14381
+ V >>>= Ct, x -= Ct, g.back += Ct;
14380
14382
  }
14381
- if (Y >>>= at, x -= at, g.back += at, g.length = ft, It === 0) {
14383
+ if (V >>>= at, x -= at, g.back += at, g.length = ft, It === 0) {
14382
14384
  g.mode = 26;
14383
14385
  break;
14384
14386
  }
@@ -14396,26 +14398,26 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14396
14398
  for (P = g.extra; x < P; ) {
14397
14399
  if (W === 0)
14398
14400
  break t;
14399
- W--, Y += v[V++] << x, x += 8;
14401
+ W--, V += v[G++] << x, x += 8;
14400
14402
  }
14401
- g.length += Y & (1 << g.extra) - 1, Y >>>= g.extra, x -= g.extra, g.back += g.extra;
14403
+ g.length += V & (1 << g.extra) - 1, V >>>= g.extra, x -= g.extra, g.back += g.extra;
14402
14404
  }
14403
14405
  g.was = g.length, g.mode = 23;
14404
14406
  case 23:
14405
- for (; It = (_ = g.distcode[Y & (1 << g.distbits) - 1]) >>> 16 & 255, ft = 65535 & _, !((at = _ >>> 24) <= x); ) {
14407
+ for (; It = (_ = g.distcode[V & (1 << g.distbits) - 1]) >>> 16 & 255, ft = 65535 & _, !((at = _ >>> 24) <= x); ) {
14406
14408
  if (W === 0)
14407
14409
  break t;
14408
- W--, Y += v[V++] << x, x += 8;
14410
+ W--, V += v[G++] << x, x += 8;
14409
14411
  }
14410
14412
  if (!(240 & It)) {
14411
- for (Ct = at, Ht = It, Dt = ft; It = (_ = g.distcode[Dt + ((Y & (1 << Ct + Ht) - 1) >> Ct)]) >>> 16 & 255, ft = 65535 & _, !(Ct + (at = _ >>> 24) <= x); ) {
14413
+ for (Ct = at, Ht = It, Dt = ft; It = (_ = g.distcode[Dt + ((V & (1 << Ct + Ht) - 1) >> Ct)]) >>> 16 & 255, ft = 65535 & _, !(Ct + (at = _ >>> 24) <= x); ) {
14412
14414
  if (W === 0)
14413
14415
  break t;
14414
- W--, Y += v[V++] << x, x += 8;
14416
+ W--, V += v[G++] << x, x += 8;
14415
14417
  }
14416
- Y >>>= Ct, x -= Ct, g.back += Ct;
14418
+ V >>>= Ct, x -= Ct, g.back += Ct;
14417
14419
  }
14418
- if (Y >>>= at, x -= at, g.back += at, 64 & It) {
14420
+ if (V >>>= at, x -= at, g.back += at, 64 & It) {
14419
14421
  O.msg = "invalid distance code", g.mode = 30;
14420
14422
  break;
14421
14423
  }
@@ -14425,9 +14427,9 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14425
14427
  for (P = g.extra; x < P; ) {
14426
14428
  if (W === 0)
14427
14429
  break t;
14428
- W--, Y += v[V++] << x, x += 8;
14430
+ W--, V += v[G++] << x, x += 8;
14429
14431
  }
14430
- g.offset += Y & (1 << g.extra) - 1, Y >>>= g.extra, x -= g.extra, g.back += g.extra;
14432
+ g.offset += V & (1 << g.extra) - 1, V >>>= g.extra, x -= g.extra, g.back += g.extra;
14431
14433
  }
14432
14434
  if (g.offset > g.dmax) {
14433
14435
  O.msg = "invalid distance too far back", g.mode = 30;
@@ -14444,28 +14446,28 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14444
14446
  }
14445
14447
  St = tt > g.wnext ? (tt -= g.wnext, g.wsize - tt) : g.wnext - tt, tt > g.length && (tt = g.length), yt = g.window;
14446
14448
  } else
14447
- yt = j, St = et - g.offset, tt = g.length;
14448
- for (nt < tt && (tt = nt), nt -= tt, g.length -= tt; j[et++] = yt[St++], --tt; )
14449
+ yt = q, St = et - g.offset, tt = g.length;
14450
+ for (nt < tt && (tt = nt), nt -= tt, g.length -= tt; q[et++] = yt[St++], --tt; )
14449
14451
  ;
14450
14452
  g.length === 0 && (g.mode = 21);
14451
14453
  break;
14452
14454
  case 26:
14453
14455
  if (nt === 0)
14454
14456
  break t;
14455
- j[et++] = g.length, nt--, g.mode = 21;
14457
+ q[et++] = g.length, nt--, g.mode = 21;
14456
14458
  break;
14457
14459
  case 27:
14458
14460
  if (g.wrap) {
14459
14461
  for (; x < 32; ) {
14460
14462
  if (W === 0)
14461
14463
  break t;
14462
- W--, Y |= v[V++] << x, x += 8;
14464
+ W--, V |= v[G++] << x, x += 8;
14463
14465
  }
14464
- if (it -= nt, O.total_out += it, g.total += it, it && (O.adler = g.check = g.flags ? o(g.check, j, it, et - it) : r(g.check, j, it, et - it)), it = nt, (g.flags ? Y : p(Y)) !== g.check) {
14466
+ if (it -= nt, O.total_out += it, g.total += it, it && (O.adler = g.check = g.flags ? o(g.check, q, it, et - it) : r(g.check, q, it, et - it)), it = nt, (g.flags ? V : p(V)) !== g.check) {
14465
14467
  O.msg = "incorrect data check", g.mode = 30;
14466
14468
  break;
14467
14469
  }
14468
- x = Y = 0;
14470
+ x = V = 0;
14469
14471
  }
14470
14472
  g.mode = 28;
14471
14473
  case 28:
@@ -14473,13 +14475,13 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14473
14475
  for (; x < 32; ) {
14474
14476
  if (W === 0)
14475
14477
  break t;
14476
- W--, Y += v[V++] << x, x += 8;
14478
+ W--, V += v[G++] << x, x += 8;
14477
14479
  }
14478
- if (Y !== (4294967295 & g.total)) {
14480
+ if (V !== (4294967295 & g.total)) {
14479
14481
  O.msg = "incorrect length check", g.mode = 30;
14480
14482
  break;
14481
14483
  }
14482
- x = Y = 0;
14484
+ x = V = 0;
14483
14485
  }
14484
14486
  g.mode = 29;
14485
14487
  case 29:
@@ -14494,7 +14496,7 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14494
14496
  default:
14495
14497
  return u;
14496
14498
  }
14497
- return O.next_out = et, O.avail_out = nt, O.next_in = V, O.avail_in = W, g.hold = Y, g.bits = x, (g.wsize || it !== O.avail_out && g.mode < 30 && (g.mode < 27 || w !== 4)) && G(O, O.output, O.next_out, it - O.avail_out) ? (g.mode = 31, -4) : (ot -= O.avail_in, it -= O.avail_out, O.total_in += ot, O.total_out += it, g.total += it, g.wrap && it && (O.adler = g.check = g.flags ? o(g.check, j, it, O.next_out - it) : r(g.check, j, it, O.next_out - it)), O.data_type = g.bits + (g.last ? 64 : 0) + (g.mode === 12 ? 128 : 0) + (g.mode === 20 || g.mode === 15 ? 256 : 0), (ot == 0 && it === 0 || w === 4) && X === I && (X = -5), X);
14499
+ return O.next_out = et, O.avail_out = nt, O.next_in = G, O.avail_in = W, g.hold = V, g.bits = x, (g.wsize || it !== O.avail_out && g.mode < 30 && (g.mode < 27 || w !== 4)) && Y(O, O.output, O.next_out, it - O.avail_out) ? (g.mode = 31, -4) : (ot -= O.avail_in, it -= O.avail_out, O.total_in += ot, O.total_out += it, g.total += it, g.wrap && it && (O.adler = g.check = g.flags ? o(g.check, q, it, O.next_out - it) : r(g.check, q, it, O.next_out - it)), O.data_type = g.bits + (g.last ? 64 : 0) + (g.mode === 12 ? 128 : 0) + (g.mode === 20 || g.mode === 15 ? 256 : 0), (ot == 0 && it === 0 || w === 4) && X === I && (X = -5), X);
14498
14500
  }, s.inflateEnd = function(O) {
14499
14501
  if (!O || !O.state)
14500
14502
  return u;
@@ -14505,23 +14507,23 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14505
14507
  return O && O.state && 2 & (g = O.state).wrap ? ((g.head = w).done = !1, I) : u;
14506
14508
  }, s.inflateSetDictionary = function(O, w) {
14507
14509
  var g, v = w.length;
14508
- return O && O.state ? (g = O.state).wrap !== 0 && g.mode !== 11 ? u : g.mode === 11 && r(1, w, v, 0) !== g.check ? -3 : G(O, w, v, v) ? (g.mode = 31, -4) : (g.havedict = 1, I) : u;
14510
+ return O && O.state ? (g = O.state).wrap !== 0 && g.mode !== 11 ? u : g.mode === 11 && r(1, w, v, 0) !== g.check ? -3 : Y(O, w, v, v) ? (g.mode = 31, -4) : (g.havedict = 1, I) : u;
14509
14511
  }, s.inflateInfo = "pako inflate (from Nodeca project)";
14510
14512
  }, { "../utils/common": 41, "./adler32": 43, "./crc32": 45, "./inffast": 48, "./inftrees": 50 }], 50: [function(t, e, s) {
14511
14513
  var n = t("../utils/common"), r = [3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 15, 17, 19, 23, 27, 31, 35, 43, 51, 59, 67, 83, 99, 115, 131, 163, 195, 227, 258, 0, 0], o = [16, 16, 16, 16, 16, 16, 16, 16, 17, 17, 17, 17, 18, 18, 18, 18, 19, 19, 19, 19, 20, 20, 20, 20, 21, 21, 21, 21, 16, 72, 78], a = [1, 2, 3, 4, 5, 7, 9, 13, 17, 25, 33, 49, 65, 97, 129, 193, 257, 385, 513, 769, 1025, 1537, 2049, 3073, 4097, 6145, 8193, 12289, 16385, 24577, 0, 0], l = [16, 16, 16, 16, 17, 17, 18, 18, 19, 19, 20, 20, 21, 21, 22, 22, 23, 23, 24, 24, 25, 25, 26, 26, 27, 27, 28, 28, 29, 29, 64, 64];
14512
14514
  e.exports = function(h, f, I, u, d, E, T, p) {
14513
- var m, F, R, S, N, y, M, L, b, G = p.bits, O = 0, w = 0, g = 0, v = 0, j = 0, V = 0, et = 0, W = 0, nt = 0, Y = 0, x = null, ot = 0, it = new n.Buf16(16), tt = new n.Buf16(16), St = null, yt = 0;
14515
+ var m, F, R, S, N, y, M, L, b, Y = p.bits, O = 0, w = 0, g = 0, v = 0, q = 0, G = 0, et = 0, W = 0, nt = 0, V = 0, x = null, ot = 0, it = new n.Buf16(16), tt = new n.Buf16(16), St = null, yt = 0;
14514
14516
  for (O = 0; O <= 15; O++)
14515
14517
  it[O] = 0;
14516
14518
  for (w = 0; w < u; w++)
14517
14519
  it[f[I + w]]++;
14518
- for (j = G, v = 15; 1 <= v && it[v] === 0; v--)
14520
+ for (q = Y, v = 15; 1 <= v && it[v] === 0; v--)
14519
14521
  ;
14520
- if (v < j && (j = v), v === 0)
14522
+ if (v < q && (q = v), v === 0)
14521
14523
  return d[E++] = 20971520, d[E++] = 20971520, p.bits = 1, 0;
14522
14524
  for (g = 1; g < v && it[g] === 0; g++)
14523
14525
  ;
14524
- for (j < g && (j = g), O = W = 1; O <= 15; O++)
14526
+ for (q < g && (q = g), O = W = 1; O <= 15; O++)
14525
14527
  if (W <<= 1, (W -= it[O]) < 0)
14526
14528
  return -1;
14527
14529
  if (0 < W && (h === 0 || v !== 1))
@@ -14530,27 +14532,27 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14530
14532
  tt[O + 1] = tt[O] + it[O];
14531
14533
  for (w = 0; w < u; w++)
14532
14534
  f[I + w] !== 0 && (T[tt[f[I + w]]++] = w);
14533
- if (y = h === 0 ? (x = St = T, 19) : h === 1 ? (x = r, ot -= 257, St = o, yt -= 257, 256) : (x = a, St = l, -1), O = g, N = E, et = w = Y = 0, R = -1, S = (nt = 1 << (V = j)) - 1, h === 1 && 852 < nt || h === 2 && 592 < nt)
14535
+ if (y = h === 0 ? (x = St = T, 19) : h === 1 ? (x = r, ot -= 257, St = o, yt -= 257, 256) : (x = a, St = l, -1), O = g, N = E, et = w = V = 0, R = -1, S = (nt = 1 << (G = q)) - 1, h === 1 && 852 < nt || h === 2 && 592 < nt)
14534
14536
  return 1;
14535
14537
  for (; ; ) {
14536
- for (M = O - et, b = T[w] < y ? (L = 0, T[w]) : T[w] > y ? (L = St[yt + T[w]], x[ot + T[w]]) : (L = 96, 0), m = 1 << O - et, g = F = 1 << V; d[N + (Y >> et) + (F -= m)] = M << 24 | L << 16 | b | 0, F !== 0; )
14538
+ for (M = O - et, b = T[w] < y ? (L = 0, T[w]) : T[w] > y ? (L = St[yt + T[w]], x[ot + T[w]]) : (L = 96, 0), m = 1 << O - et, g = F = 1 << G; d[N + (V >> et) + (F -= m)] = M << 24 | L << 16 | b | 0, F !== 0; )
14537
14539
  ;
14538
- for (m = 1 << O - 1; Y & m; )
14540
+ for (m = 1 << O - 1; V & m; )
14539
14541
  m >>= 1;
14540
- if (m !== 0 ? (Y &= m - 1, Y += m) : Y = 0, w++, --it[O] == 0) {
14542
+ if (m !== 0 ? (V &= m - 1, V += m) : V = 0, w++, --it[O] == 0) {
14541
14543
  if (O === v)
14542
14544
  break;
14543
14545
  O = f[I + T[w]];
14544
14546
  }
14545
- if (j < O && (Y & S) !== R) {
14546
- for (et === 0 && (et = j), N += g, W = 1 << (V = O - et); V + et < v && !((W -= it[V + et]) <= 0); )
14547
- V++, W <<= 1;
14548
- if (nt += 1 << V, h === 1 && 852 < nt || h === 2 && 592 < nt)
14547
+ if (q < O && (V & S) !== R) {
14548
+ for (et === 0 && (et = q), N += g, W = 1 << (G = O - et); G + et < v && !((W -= it[G + et]) <= 0); )
14549
+ G++, W <<= 1;
14550
+ if (nt += 1 << G, h === 1 && 852 < nt || h === 2 && 592 < nt)
14549
14551
  return 1;
14550
- d[R = Y & S] = j << 24 | V << 16 | N - E | 0;
14552
+ d[R = V & S] = q << 24 | G << 16 | N - E | 0;
14551
14553
  }
14552
14554
  }
14553
- return Y !== 0 && (d[N + Y] = O - et << 24 | 64 << 16 | 0), p.bits = j, 0;
14555
+ return V !== 0 && (d[N + V] = O - et << 24 | 64 << 16 | 0), p.bits = q, 0;
14554
14556
  };
14555
14557
  }, { "../utils/common": 41 }], 51: [function(t, e, s) {
14556
14558
  e.exports = { 2: "need dictionary", 1: "stream end", 0: "", "-1": "file error", "-2": "stream error", "-3": "data error", "-4": "insufficient memory", "-5": "buffer error", "-6": "incompatible version" };
@@ -14560,8 +14562,8 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14560
14562
  for (var U = _.length; 0 <= --U; )
14561
14563
  _[U] = 0;
14562
14564
  }
14563
- var l = 0, h = 29, f = 256, I = f + 1 + h, u = 30, d = 19, E = 2 * I + 1, T = 15, p = 16, m = 7, F = 256, R = 16, S = 17, N = 18, y = [0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 0], M = [0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13], L = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 7], b = [16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15], G = new Array(2 * (I + 2));
14564
- a(G);
14565
+ var l = 0, h = 29, f = 256, I = f + 1 + h, u = 30, d = 19, E = 2 * I + 1, T = 15, p = 16, m = 7, F = 256, R = 16, S = 17, N = 18, y = [0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 0], M = [0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13], L = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 7], b = [16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15], Y = new Array(2 * (I + 2));
14566
+ a(Y);
14565
14567
  var O = new Array(2 * u);
14566
14568
  a(O);
14567
14569
  var w = new Array(512);
@@ -14570,11 +14572,11 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14570
14572
  a(g);
14571
14573
  var v = new Array(h);
14572
14574
  a(v);
14573
- var j, V, et, W = new Array(u);
14574
- function nt(_, U, $, q, B) {
14575
- this.static_tree = _, this.extra_bits = U, this.extra_base = $, this.elems = q, this.max_length = B, this.has_stree = _ && _.length;
14575
+ var q, G, et, W = new Array(u);
14576
+ function nt(_, U, $, Z, B) {
14577
+ this.static_tree = _, this.extra_bits = U, this.extra_base = $, this.elems = Z, this.max_length = B, this.has_stree = _ && _.length;
14576
14578
  }
14577
- function Y(_, U) {
14579
+ function V(_, U) {
14578
14580
  this.dyn_tree = _, this.max_code = 0, this.stat_desc = U;
14579
14581
  }
14580
14582
  function x(_) {
@@ -14595,9 +14597,9 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14595
14597
  return $ >>> 1;
14596
14598
  }
14597
14599
  function yt(_, U, $) {
14598
- var q, B, K = new Array(T + 1), st = 0;
14599
- for (q = 1; q <= T; q++)
14600
- K[q] = st = st + $[q - 1] << 1;
14600
+ var Z, B, K = new Array(T + 1), st = 0;
14601
+ for (Z = 1; Z <= T; Z++)
14602
+ K[Z] = st = st + $[Z - 1] << 1;
14601
14603
  for (B = 0; B <= U; B++) {
14602
14604
  var J = _[2 * B + 1];
14603
14605
  J !== 0 && (_[2 * B] = St(K[J]++, J));
@@ -14616,59 +14618,59 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14616
14618
  function It(_) {
14617
14619
  8 < _.bi_valid ? ot(_, _.bi_buf) : 0 < _.bi_valid && (_.pending_buf[_.pending++] = _.bi_buf), _.bi_buf = 0, _.bi_valid = 0;
14618
14620
  }
14619
- function ft(_, U, $, q) {
14621
+ function ft(_, U, $, Z) {
14620
14622
  var B = 2 * U, K = 2 * $;
14621
- return _[B] < _[K] || _[B] === _[K] && q[U] <= q[$];
14623
+ return _[B] < _[K] || _[B] === _[K] && Z[U] <= Z[$];
14622
14624
  }
14623
14625
  function Ct(_, U, $) {
14624
- for (var q = _.heap[$], B = $ << 1; B <= _.heap_len && (B < _.heap_len && ft(U, _.heap[B + 1], _.heap[B], _.depth) && B++, !ft(U, q, _.heap[B], _.depth)); )
14626
+ for (var Z = _.heap[$], B = $ << 1; B <= _.heap_len && (B < _.heap_len && ft(U, _.heap[B + 1], _.heap[B], _.depth) && B++, !ft(U, Z, _.heap[B], _.depth)); )
14625
14627
  _.heap[$] = _.heap[B], $ = B, B <<= 1;
14626
- _.heap[$] = q;
14628
+ _.heap[$] = Z;
14627
14629
  }
14628
14630
  function Ht(_, U, $) {
14629
- var q, B, K, st, J = 0;
14631
+ var Z, B, K, st, J = 0;
14630
14632
  if (_.last_lit !== 0)
14631
- for (; q = _.pending_buf[_.d_buf + 2 * J] << 8 | _.pending_buf[_.d_buf + 2 * J + 1], B = _.pending_buf[_.l_buf + J], J++, q === 0 ? tt(_, B, U) : (tt(_, (K = g[B]) + f + 1, U), (st = y[K]) !== 0 && it(_, B -= v[K], st), tt(_, K = x(--q), $), (st = M[K]) !== 0 && it(_, q -= W[K], st)), J < _.last_lit; )
14633
+ for (; Z = _.pending_buf[_.d_buf + 2 * J] << 8 | _.pending_buf[_.d_buf + 2 * J + 1], B = _.pending_buf[_.l_buf + J], J++, Z === 0 ? tt(_, B, U) : (tt(_, (K = g[B]) + f + 1, U), (st = y[K]) !== 0 && it(_, B -= v[K], st), tt(_, K = x(--Z), $), (st = M[K]) !== 0 && it(_, Z -= W[K], st)), J < _.last_lit; )
14632
14634
  ;
14633
14635
  tt(_, F, U);
14634
14636
  }
14635
14637
  function Dt(_, U) {
14636
- var $, q, B, K = U.dyn_tree, st = U.stat_desc.static_tree, J = U.stat_desc.has_stree, ct = U.stat_desc.elems, Rt = -1;
14638
+ var $, Z, B, K = U.dyn_tree, st = U.stat_desc.static_tree, J = U.stat_desc.has_stree, ct = U.stat_desc.elems, Rt = -1;
14637
14639
  for (_.heap_len = 0, _.heap_max = E, $ = 0; $ < ct; $++)
14638
14640
  K[2 * $] !== 0 ? (_.heap[++_.heap_len] = Rt = $, _.depth[$] = 0) : K[2 * $ + 1] = 0;
14639
14641
  for (; _.heap_len < 2; )
14640
14642
  K[2 * (B = _.heap[++_.heap_len] = Rt < 2 ? ++Rt : 0)] = 1, _.depth[B] = 0, _.opt_len--, J && (_.static_len -= st[2 * B + 1]);
14641
14643
  for (U.max_code = Rt, $ = _.heap_len >> 1; 1 <= $; $--)
14642
14644
  Ct(_, K, $);
14643
- for (B = ct; $ = _.heap[1], _.heap[1] = _.heap[_.heap_len--], Ct(_, K, 1), q = _.heap[1], _.heap[--_.heap_max] = $, _.heap[--_.heap_max] = q, K[2 * B] = K[2 * $] + K[2 * q], _.depth[B] = (_.depth[$] >= _.depth[q] ? _.depth[$] : _.depth[q]) + 1, K[2 * $ + 1] = K[2 * q + 1] = B, _.heap[1] = B++, Ct(_, K, 1), 2 <= _.heap_len; )
14645
+ for (B = ct; $ = _.heap[1], _.heap[1] = _.heap[_.heap_len--], Ct(_, K, 1), Z = _.heap[1], _.heap[--_.heap_max] = $, _.heap[--_.heap_max] = Z, K[2 * B] = K[2 * $] + K[2 * Z], _.depth[B] = (_.depth[$] >= _.depth[Z] ? _.depth[$] : _.depth[Z]) + 1, K[2 * $ + 1] = K[2 * Z + 1] = B, _.heap[1] = B++, Ct(_, K, 1), 2 <= _.heap_len; )
14644
14646
  ;
14645
14647
  _.heap[--_.heap_max] = _.heap[1], function(dt, Wt) {
14646
- var li, ce, hi, Lt, Bi, Hs, Ce = Wt.dyn_tree, Hn = Wt.max_code, mo = Wt.stat_desc.static_tree, Ro = Wt.stat_desc.has_stree, go = Wt.stat_desc.extra_bits, Wn = Wt.stat_desc.extra_base, ui = Wt.stat_desc.max_length, Vi = 0;
14648
+ var hi, ce, ui, Lt, Vi, Hs, Ce = Wt.dyn_tree, Hn = Wt.max_code, mo = Wt.stat_desc.static_tree, Ro = Wt.stat_desc.has_stree, go = Wt.stat_desc.extra_bits, Wn = Wt.stat_desc.extra_base, fi = Wt.stat_desc.max_length, Yi = 0;
14647
14649
  for (Lt = 0; Lt <= T; Lt++)
14648
14650
  dt.bl_count[Lt] = 0;
14649
- for (Ce[2 * dt.heap[dt.heap_max] + 1] = 0, li = dt.heap_max + 1; li < E; li++)
14650
- ui < (Lt = Ce[2 * Ce[2 * (ce = dt.heap[li]) + 1] + 1] + 1) && (Lt = ui, Vi++), Ce[2 * ce + 1] = Lt, Hn < ce || (dt.bl_count[Lt]++, Bi = 0, Wn <= ce && (Bi = go[ce - Wn]), Hs = Ce[2 * ce], dt.opt_len += Hs * (Lt + Bi), Ro && (dt.static_len += Hs * (mo[2 * ce + 1] + Bi)));
14651
- if (Vi !== 0) {
14651
+ for (Ce[2 * dt.heap[dt.heap_max] + 1] = 0, hi = dt.heap_max + 1; hi < E; hi++)
14652
+ fi < (Lt = Ce[2 * Ce[2 * (ce = dt.heap[hi]) + 1] + 1] + 1) && (Lt = fi, Yi++), Ce[2 * ce + 1] = Lt, Hn < ce || (dt.bl_count[Lt]++, Vi = 0, Wn <= ce && (Vi = go[ce - Wn]), Hs = Ce[2 * ce], dt.opt_len += Hs * (Lt + Vi), Ro && (dt.static_len += Hs * (mo[2 * ce + 1] + Vi)));
14653
+ if (Yi !== 0) {
14652
14654
  do {
14653
- for (Lt = ui - 1; dt.bl_count[Lt] === 0; )
14655
+ for (Lt = fi - 1; dt.bl_count[Lt] === 0; )
14654
14656
  Lt--;
14655
- dt.bl_count[Lt]--, dt.bl_count[Lt + 1] += 2, dt.bl_count[ui]--, Vi -= 2;
14656
- } while (0 < Vi);
14657
- for (Lt = ui; Lt !== 0; Lt--)
14657
+ dt.bl_count[Lt]--, dt.bl_count[Lt + 1] += 2, dt.bl_count[fi]--, Yi -= 2;
14658
+ } while (0 < Yi);
14659
+ for (Lt = fi; Lt !== 0; Lt--)
14658
14660
  for (ce = dt.bl_count[Lt]; ce !== 0; )
14659
- Hn < (hi = dt.heap[--li]) || (Ce[2 * hi + 1] !== Lt && (dt.opt_len += (Lt - Ce[2 * hi + 1]) * Ce[2 * hi], Ce[2 * hi + 1] = Lt), ce--);
14661
+ Hn < (ui = dt.heap[--hi]) || (Ce[2 * ui + 1] !== Lt && (dt.opt_len += (Lt - Ce[2 * ui + 1]) * Ce[2 * ui], Ce[2 * ui + 1] = Lt), ce--);
14660
14662
  }
14661
14663
  }(_, U), yt(K, Rt, _.bl_count);
14662
14664
  }
14663
14665
  function A(_, U, $) {
14664
- var q, B, K = -1, st = U[1], J = 0, ct = 7, Rt = 4;
14665
- for (st === 0 && (ct = 138, Rt = 3), U[2 * ($ + 1) + 1] = 65535, q = 0; q <= $; q++)
14666
- B = st, st = U[2 * (q + 1) + 1], ++J < ct && B === st || (J < Rt ? _.bl_tree[2 * B] += J : B !== 0 ? (B !== K && _.bl_tree[2 * B]++, _.bl_tree[2 * R]++) : J <= 10 ? _.bl_tree[2 * S]++ : _.bl_tree[2 * N]++, K = B, Rt = (J = 0) === st ? (ct = 138, 3) : B === st ? (ct = 6, 3) : (ct = 7, 4));
14666
+ var Z, B, K = -1, st = U[1], J = 0, ct = 7, Rt = 4;
14667
+ for (st === 0 && (ct = 138, Rt = 3), U[2 * ($ + 1) + 1] = 65535, Z = 0; Z <= $; Z++)
14668
+ B = st, st = U[2 * (Z + 1) + 1], ++J < ct && B === st || (J < Rt ? _.bl_tree[2 * B] += J : B !== 0 ? (B !== K && _.bl_tree[2 * B]++, _.bl_tree[2 * R]++) : J <= 10 ? _.bl_tree[2 * S]++ : _.bl_tree[2 * N]++, K = B, Rt = (J = 0) === st ? (ct = 138, 3) : B === st ? (ct = 6, 3) : (ct = 7, 4));
14667
14669
  }
14668
14670
  function X(_, U, $) {
14669
- var q, B, K = -1, st = U[1], J = 0, ct = 7, Rt = 4;
14670
- for (st === 0 && (ct = 138, Rt = 3), q = 0; q <= $; q++)
14671
- if (B = st, st = U[2 * (q + 1) + 1], !(++J < ct && B === st)) {
14671
+ var Z, B, K = -1, st = U[1], J = 0, ct = 7, Rt = 4;
14672
+ for (st === 0 && (ct = 138, Rt = 3), Z = 0; Z <= $; Z++)
14673
+ if (B = st, st = U[2 * (Z + 1) + 1], !(++J < ct && B === st)) {
14672
14674
  if (J < Rt)
14673
14675
  for (; tt(_, B, _.bl_tree), --J != 0; )
14674
14676
  ;
@@ -14679,18 +14681,18 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14679
14681
  }
14680
14682
  a(W);
14681
14683
  var k = !1;
14682
- function P(_, U, $, q) {
14683
- it(_, (l << 1) + (q ? 1 : 0), 3), function(B, K, st, J) {
14684
+ function P(_, U, $, Z) {
14685
+ it(_, (l << 1) + (Z ? 1 : 0), 3), function(B, K, st, J) {
14684
14686
  It(B), ot(B, st), ot(B, ~st), n.arraySet(B.pending_buf, B.window, K, st, B.pending), B.pending += st;
14685
14687
  }(_, U, $);
14686
14688
  }
14687
14689
  s._tr_init = function(_) {
14688
14690
  k || (function() {
14689
- var U, $, q, B, K, st = new Array(T + 1);
14690
- for (B = q = 0; B < h - 1; B++)
14691
- for (v[B] = q, U = 0; U < 1 << y[B]; U++)
14692
- g[q++] = B;
14693
- for (g[q - 1] = B, B = K = 0; B < 16; B++)
14691
+ var U, $, Z, B, K, st = new Array(T + 1);
14692
+ for (B = Z = 0; B < h - 1; B++)
14693
+ for (v[B] = Z, U = 0; U < 1 << y[B]; U++)
14694
+ g[Z++] = B;
14695
+ for (g[Z - 1] = B, B = K = 0; B < 16; B++)
14694
14696
  for (W[B] = K, U = 0; U < 1 << M[B]; U++)
14695
14697
  w[K++] = B;
14696
14698
  for (K >>= 7; B < u; B++)
@@ -14699,18 +14701,18 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14699
14701
  for ($ = 0; $ <= T; $++)
14700
14702
  st[$] = 0;
14701
14703
  for (U = 0; U <= 143; )
14702
- G[2 * U + 1] = 8, U++, st[8]++;
14704
+ Y[2 * U + 1] = 8, U++, st[8]++;
14703
14705
  for (; U <= 255; )
14704
- G[2 * U + 1] = 9, U++, st[9]++;
14706
+ Y[2 * U + 1] = 9, U++, st[9]++;
14705
14707
  for (; U <= 279; )
14706
- G[2 * U + 1] = 7, U++, st[7]++;
14708
+ Y[2 * U + 1] = 7, U++, st[7]++;
14707
14709
  for (; U <= 287; )
14708
- G[2 * U + 1] = 8, U++, st[8]++;
14709
- for (yt(G, I + 1, st), U = 0; U < u; U++)
14710
+ Y[2 * U + 1] = 8, U++, st[8]++;
14711
+ for (yt(Y, I + 1, st), U = 0; U < u; U++)
14710
14712
  O[2 * U + 1] = 5, O[2 * U] = St(U, 5);
14711
- j = new nt(G, y, f + 1, I, T), V = new nt(O, M, 0, u, T), et = new nt(new Array(0), L, 0, d, m);
14712
- }(), k = !0), _.l_desc = new Y(_.dyn_ltree, j), _.d_desc = new Y(_.dyn_dtree, V), _.bl_desc = new Y(_.bl_tree, et), _.bi_buf = 0, _.bi_valid = 0, at(_);
14713
- }, s._tr_stored_block = P, s._tr_flush_block = function(_, U, $, q) {
14713
+ q = new nt(Y, y, f + 1, I, T), G = new nt(O, M, 0, u, T), et = new nt(new Array(0), L, 0, d, m);
14714
+ }(), k = !0), _.l_desc = new V(_.dyn_ltree, q), _.d_desc = new V(_.dyn_dtree, G), _.bl_desc = new V(_.bl_tree, et), _.bi_buf = 0, _.bi_valid = 0, at(_);
14715
+ }, s._tr_stored_block = P, s._tr_flush_block = function(_, U, $, Z) {
14714
14716
  var B, K, st = 0;
14715
14717
  0 < _.level ? (_.strm.data_type === 2 && (_.strm.data_type = function(J) {
14716
14718
  var ct, Rt = 4093624447;
@@ -14728,16 +14730,16 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14728
14730
  for (A(J, J.dyn_ltree, J.l_desc.max_code), A(J, J.dyn_dtree, J.d_desc.max_code), Dt(J, J.bl_desc), ct = d - 1; 3 <= ct && J.bl_tree[2 * b[ct] + 1] === 0; ct--)
14729
14731
  ;
14730
14732
  return J.opt_len += 3 * (ct + 1) + 5 + 5 + 4, ct;
14731
- }(_), B = _.opt_len + 3 + 7 >>> 3, (K = _.static_len + 3 + 7 >>> 3) <= B && (B = K)) : B = K = $ + 5, $ + 4 <= B && U !== -1 ? P(_, U, $, q) : _.strategy === 4 || K === B ? (it(_, 2 + (q ? 1 : 0), 3), Ht(_, G, O)) : (it(_, 4 + (q ? 1 : 0), 3), function(J, ct, Rt, dt) {
14733
+ }(_), B = _.opt_len + 3 + 7 >>> 3, (K = _.static_len + 3 + 7 >>> 3) <= B && (B = K)) : B = K = $ + 5, $ + 4 <= B && U !== -1 ? P(_, U, $, Z) : _.strategy === 4 || K === B ? (it(_, 2 + (Z ? 1 : 0), 3), Ht(_, Y, O)) : (it(_, 4 + (Z ? 1 : 0), 3), function(J, ct, Rt, dt) {
14732
14734
  var Wt;
14733
14735
  for (it(J, ct - 257, 5), it(J, Rt - 1, 5), it(J, dt - 4, 4), Wt = 0; Wt < dt; Wt++)
14734
14736
  it(J, J.bl_tree[2 * b[Wt] + 1], 3);
14735
14737
  X(J, J.dyn_ltree, ct - 1), X(J, J.dyn_dtree, Rt - 1);
14736
- }(_, _.l_desc.max_code + 1, _.d_desc.max_code + 1, st + 1), Ht(_, _.dyn_ltree, _.dyn_dtree)), at(_), q && It(_);
14738
+ }(_, _.l_desc.max_code + 1, _.d_desc.max_code + 1, st + 1), Ht(_, _.dyn_ltree, _.dyn_dtree)), at(_), Z && It(_);
14737
14739
  }, s._tr_tally = function(_, U, $) {
14738
14740
  return _.pending_buf[_.d_buf + 2 * _.last_lit] = U >>> 8 & 255, _.pending_buf[_.d_buf + 2 * _.last_lit + 1] = 255 & U, _.pending_buf[_.l_buf + _.last_lit] = 255 & $, _.last_lit++, U === 0 ? _.dyn_ltree[2 * $]++ : (_.matches++, U--, _.dyn_ltree[2 * (g[$] + f + 1)]++, _.dyn_dtree[2 * x(U)]++), _.last_lit === _.lit_bufsize - 1;
14739
14741
  }, s._tr_align = function(_) {
14740
- it(_, 2, 3), tt(_, F, G), function(U) {
14742
+ it(_, 2, 3), tt(_, F, Y), function(U) {
14741
14743
  U.bi_valid === 16 ? (ot(U, U.bi_buf), U.bi_buf = 0, U.bi_valid = 0) : 8 <= U.bi_valid && (U.pending_buf[U.pending++] = 255 & U.bi_buf, U.bi_buf >>= 8, U.bi_valid -= 8);
14742
14744
  }(_);
14743
14745
  };
@@ -14822,7 +14824,7 @@ https://github.com/nodeca/pako/blob/main/LICENSE
14822
14824
  R.source === r && typeof R.data == "string" && R.data.indexOf(f) === 0 && m(+R.data.slice(f.length));
14823
14825
  }
14824
14826
  })(typeof self > "u" ? n === void 0 ? this : n : self);
14825
- }).call(this, typeof hs < "u" ? hs : typeof self < "u" ? self : typeof window < "u" ? window : {});
14827
+ }).call(this, typeof us < "u" ? us : typeof self < "u" ? self : typeof window < "u" ? window : {});
14826
14828
  }, {}] }, {}, [10])(10);
14827
14829
  });
14828
14830
  })(lo);
@@ -15028,18 +15030,18 @@ function Br(c, i) {
15028
15030
  const t = zn.getAllMatches(c, Gc), e = {};
15029
15031
  for (let s = 0; s < t.length; s++) {
15030
15032
  if (t[s][1].length === 0)
15031
- return Pt("InvalidAttr", "Attribute '" + t[s][2] + "' has no space in starting.", Ni(t[s]));
15033
+ return Pt("InvalidAttr", "Attribute '" + t[s][2] + "' has no space in starting.", yi(t[s]));
15032
15034
  if (t[s][3] !== void 0 && t[s][4] === void 0)
15033
- return Pt("InvalidAttr", "Attribute '" + t[s][2] + "' is without value.", Ni(t[s]));
15035
+ return Pt("InvalidAttr", "Attribute '" + t[s][2] + "' is without value.", yi(t[s]));
15034
15036
  if (t[s][3] === void 0 && !i.allowBooleanAttributes)
15035
- return Pt("InvalidAttr", "boolean attribute '" + t[s][2] + "' is not allowed.", Ni(t[s]));
15037
+ return Pt("InvalidAttr", "boolean attribute '" + t[s][2] + "' is not allowed.", yi(t[s]));
15036
15038
  const n = t[s][2];
15037
15039
  if (!Hc(n))
15038
- return Pt("InvalidAttr", "Attribute '" + n + "' is an invalid name.", Ni(t[s]));
15040
+ return Pt("InvalidAttr", "Attribute '" + n + "' is an invalid name.", yi(t[s]));
15039
15041
  if (!e.hasOwnProperty(n))
15040
15042
  e[n] = 1;
15041
15043
  else
15042
- return Pt("InvalidAttr", "Attribute '" + n + "' is repeated.", Ni(t[s]));
15044
+ return Pt("InvalidAttr", "Attribute '" + n + "' is repeated.", yi(t[s]));
15043
15045
  }
15044
15046
  return !0;
15045
15047
  }
@@ -15091,7 +15093,7 @@ function xt(c, i) {
15091
15093
  col: t[t.length - 1].length + 1
15092
15094
  };
15093
15095
  }
15094
- function Ni(c) {
15096
+ function yi(c) {
15095
15097
  return c.startIndex + c[1].length;
15096
15098
  }
15097
15099
  var kn = {};
@@ -15263,7 +15265,7 @@ function ll(c) {
15263
15265
  return c && c.indexOf(".") !== -1 && (c = c.replace(/0+$/, ""), c === "." ? c = "0" : c[0] === "." ? c = "0" + c : c[c.length - 1] === "." && (c = c.substr(0, c.length - 1))), c;
15264
15266
  }
15265
15267
  var hl = cl;
15266
- const uo = zs, yi = Zc, ul = nl, fl = hl;
15268
+ const uo = zs, Li = Zc, ul = nl, fl = hl;
15267
15269
  let Il = class {
15268
15270
  constructor(i) {
15269
15271
  this.options = i, this.currentNode = null, this.tagsNodeStack = [], this.docTypeEntities = {}, this.lastEntities = {
@@ -15347,12 +15349,12 @@ function Tl(c, i, t) {
15347
15349
  const ml = function(c) {
15348
15350
  c = c.replace(/\r\n?/g, `
15349
15351
  `);
15350
- const i = new yi("!xml");
15352
+ const i = new Li("!xml");
15351
15353
  let t = i, e = "", s = "";
15352
15354
  for (let n = 0; n < c.length; n++)
15353
15355
  if (c[n] === "<")
15354
15356
  if (c[n + 1] === "/") {
15355
- const o = Be(c, ">", n, "Closing Tag is not closed.");
15357
+ const o = Ve(c, ">", n, "Closing Tag is not closed.");
15356
15358
  let a = c.substring(n + 2, o).trim();
15357
15359
  if (this.options.removeNSPrefix) {
15358
15360
  const f = a.indexOf(":");
@@ -15369,12 +15371,12 @@ const ml = function(c) {
15369
15371
  if (!o)
15370
15372
  throw new Error("Pi Tag is not closed.");
15371
15373
  if (e = this.saveTextToParentTag(e, t, s), !(this.options.ignoreDeclaration && o.tagName === "?xml" || this.options.ignorePiTags)) {
15372
- const a = new yi(o.tagName);
15374
+ const a = new Li(o.tagName);
15373
15375
  a.add(this.options.textNodeName, ""), o.tagName !== o.tagExp && o.attrExpPresent && (a[":@"] = this.buildAttributesMap(o.tagExp, s, o.tagName)), this.addChild(t, a, s);
15374
15376
  }
15375
15377
  n = o.closeIndex + 1;
15376
15378
  } else if (c.substr(n + 1, 3) === "!--") {
15377
- const o = Be(c, "-->", n + 4, "Comment is not closed.");
15379
+ const o = Ve(c, "-->", n + 4, "Comment is not closed.");
15378
15380
  if (this.options.commentPropName) {
15379
15381
  const a = c.substring(n + 4, o - 2);
15380
15382
  e = this.saveTextToParentTag(e, t, s), t.add(this.options.commentPropName, [{ [this.options.textNodeName]: a }]);
@@ -15384,7 +15386,7 @@ const ml = function(c) {
15384
15386
  const o = ul(c, n);
15385
15387
  this.docTypeEntities = o.entities, n = o.i;
15386
15388
  } else if (c.substr(n + 1, 2) === "![") {
15387
- const o = Be(c, "]]>", n, "CDATA is not closed.") - 2, a = c.substring(n + 9, o);
15389
+ const o = Ve(c, "]]>", n, "CDATA is not closed.") - 2, a = c.substring(n + 9, o);
15388
15390
  e = this.saveTextToParentTag(e, t, s);
15389
15391
  let l = this.parseTextData(a, t.tagname, s, !0, !1, !0, !0);
15390
15392
  l == null && (l = ""), this.options.cdataPropName ? t.add(this.options.cdataPropName, [{ [this.options.textNodeName]: a }]) : t.add(this.options.textNodeName, l), n = o + 2;
@@ -15406,15 +15408,15 @@ const ml = function(c) {
15406
15408
  throw new Error(`Unexpected end of ${l}`);
15407
15409
  n = T.i, d = T.tagContent;
15408
15410
  }
15409
- const E = new yi(a);
15411
+ const E = new Li(a);
15410
15412
  a !== h && f && (E[":@"] = this.buildAttributesMap(h, s, a)), d && (d = this.parseTextData(d, a, s, !0, f, !0, !0)), s = s.substr(0, s.lastIndexOf(".")), E.add(this.options.textNodeName, d), this.addChild(t, E, s);
15411
15413
  } else {
15412
15414
  if (h.length > 0 && h.lastIndexOf("/") === h.length - 1) {
15413
15415
  a[a.length - 1] === "/" ? (a = a.substr(0, a.length - 1), s = s.substr(0, s.length - 1), h = a) : h = h.substr(0, h.length - 1), this.options.transformTagName && (a = this.options.transformTagName(a));
15414
- const d = new yi(a);
15416
+ const d = new Li(a);
15415
15417
  a !== h && f && (d[":@"] = this.buildAttributesMap(h, s, a)), this.addChild(t, d, s), s = s.substr(0, s.lastIndexOf("."));
15416
15418
  } else {
15417
- const d = new yi(a);
15419
+ const d = new Li(a);
15418
15420
  this.tagsNodeStack.push(t), a !== h && f && (d[":@"] = this.buildAttributesMap(h, s, a)), this.addChild(t, d, s), t = d;
15419
15421
  }
15420
15422
  e = "", n = I;
@@ -15491,7 +15493,7 @@ function Sl(c, i, t = ">") {
15491
15493
  s += r;
15492
15494
  }
15493
15495
  }
15494
- function Be(c, i, t, e) {
15496
+ function Ve(c, i, t, e) {
15495
15497
  const s = c.indexOf(i, t);
15496
15498
  if (s === -1)
15497
15499
  throw new Error(e);
@@ -15524,7 +15526,7 @@ function Ol(c, i, t) {
15524
15526
  for (; t < c.length; t++)
15525
15527
  if (c[t] === "<")
15526
15528
  if (c[t + 1] === "/") {
15527
- const n = Be(c, ">", t, `${i} is not closed`);
15529
+ const n = Ve(c, ">", t, `${i} is not closed`);
15528
15530
  if (c.substring(t + 2, n).trim() === i && (s--, s === 0))
15529
15531
  return {
15530
15532
  tagContent: c.substring(e, t),
@@ -15532,11 +15534,11 @@ function Ol(c, i, t) {
15532
15534
  };
15533
15535
  t = n;
15534
15536
  } else if (c[t + 1] === "?")
15535
- t = Be(c, "?>", t + 1, "StopNode is not closed.");
15537
+ t = Ve(c, "?>", t + 1, "StopNode is not closed.");
15536
15538
  else if (c.substr(t + 1, 3) === "!--")
15537
- t = Be(c, "-->", t + 3, "StopNode is not closed.");
15539
+ t = Ve(c, "-->", t + 3, "StopNode is not closed.");
15538
15540
  else if (c.substr(t + 1, 2) === "![")
15539
- t = Be(c, "]]>", t, "StopNode is not closed.") - 2;
15541
+ t = Ve(c, "]]>", t, "StopNode is not closed.") - 2;
15540
15542
  else {
15541
15543
  const n = Ln(c, t, ">");
15542
15544
  n && ((n && n.tagName) === i && n.tagExp[n.tagExp.length - 1] !== "/" && s++, t = n.closeIndex);
@@ -15744,7 +15746,7 @@ const zl = Gl, kl = {
15744
15746
  // transformAttributeName: false,
15745
15747
  oneListGroup: !1
15746
15748
  };
15747
- function De(c) {
15749
+ function be(c) {
15748
15750
  this.options = Object.assign({}, kl, c), this.options.ignoreAttributes || this.options.attributesGroupName ? this.isAttribute = function() {
15749
15751
  return !1;
15750
15752
  } : (this.attrPrefixLen = this.options.attributeNamePrefix.length, this.isAttribute = Xl), this.processTextOrObjNode = Hl, this.options.format ? (this.indentate = Wl, this.tagEndChar = `>
@@ -15753,12 +15755,12 @@ function De(c) {
15753
15755
  return "";
15754
15756
  }, this.tagEndChar = ">", this.newLine = "");
15755
15757
  }
15756
- De.prototype.build = function(c) {
15758
+ be.prototype.build = function(c) {
15757
15759
  return this.options.preserveOrder ? zl(c, this.options) : (Array.isArray(c) && this.options.arrayNodeName && this.options.arrayNodeName.length > 1 && (c = {
15758
15760
  [this.options.arrayNodeName]: c
15759
15761
  }), this.j2x(c, 0).val);
15760
15762
  };
15761
- De.prototype.j2x = function(c, i) {
15763
+ be.prototype.j2x = function(c, i) {
15762
15764
  let t = "", e = "";
15763
15765
  for (let s in c)
15764
15766
  if (Object.prototype.hasOwnProperty.call(c, s))
@@ -15806,14 +15808,14 @@ De.prototype.j2x = function(c, i) {
15806
15808
  e += this.processTextOrObjNode(c[s], s, i);
15807
15809
  return { attrStr: t, val: e };
15808
15810
  };
15809
- De.prototype.buildAttrPairStr = function(c, i) {
15811
+ be.prototype.buildAttrPairStr = function(c, i) {
15810
15812
  return i = this.options.attributeValueProcessor(c, "" + i), i = this.replaceEntitiesValue(i), this.options.suppressBooleanAttributes && i === "true" ? " " + c : " " + c + '="' + i + '"';
15811
15813
  };
15812
15814
  function Hl(c, i, t) {
15813
15815
  const e = this.j2x(c, t + 1);
15814
15816
  return c[this.options.textNodeName] !== void 0 && Object.keys(c).length === 1 ? this.buildTextValNode(c[this.options.textNodeName], i, e.attrStr, t) : this.buildObjectNode(e.val, i, e.attrStr, t);
15815
15817
  }
15816
- De.prototype.buildObjectNode = function(c, i, t, e) {
15818
+ be.prototype.buildObjectNode = function(c, i, t, e) {
15817
15819
  if (c === "")
15818
15820
  return i[0] === "?" ? this.indentate(e) + "<" + i + t + "?" + this.tagEndChar : this.indentate(e) + "<" + i + t + this.closeTag(i) + this.tagEndChar;
15819
15821
  {
@@ -15821,11 +15823,11 @@ De.prototype.buildObjectNode = function(c, i, t, e) {
15821
15823
  return i[0] === "?" && (n = "?", s = ""), (t || t === "") && c.indexOf("<") === -1 ? this.indentate(e) + "<" + i + t + n + ">" + c + s : this.options.commentPropName !== !1 && i === this.options.commentPropName && n.length === 0 ? this.indentate(e) + `<!--${c}-->` + this.newLine : this.indentate(e) + "<" + i + t + n + this.tagEndChar + c + this.indentate(e) + s;
15822
15824
  }
15823
15825
  };
15824
- De.prototype.closeTag = function(c) {
15826
+ be.prototype.closeTag = function(c) {
15825
15827
  let i = "";
15826
15828
  return this.options.unpairedTags.indexOf(c) !== -1 ? this.options.suppressUnpairedNode || (i = "/") : this.options.suppressEmptyNode ? i = "/" : i = `></${c}`, i;
15827
15829
  };
15828
- De.prototype.buildTextValNode = function(c, i, t, e) {
15830
+ be.prototype.buildTextValNode = function(c, i, t, e) {
15829
15831
  if (this.options.cdataPropName !== !1 && i === this.options.cdataPropName)
15830
15832
  return this.indentate(e) + `<![CDATA[${c}]]>` + this.newLine;
15831
15833
  if (this.options.commentPropName !== !1 && i === this.options.commentPropName)
@@ -15837,7 +15839,7 @@ De.prototype.buildTextValNode = function(c, i, t, e) {
15837
15839
  return s = this.replaceEntitiesValue(s), s === "" ? this.indentate(e) + "<" + i + t + this.closeTag(i) + this.tagEndChar : this.indentate(e) + "<" + i + t + ">" + s + "</" + i + this.tagEndChar;
15838
15840
  }
15839
15841
  };
15840
- De.prototype.replaceEntitiesValue = function(c) {
15842
+ be.prototype.replaceEntitiesValue = function(c) {
15841
15843
  if (c && c.length > 0 && this.options.processEntities)
15842
15844
  for (let i = 0; i < this.options.entities.length; i++) {
15843
15845
  const t = this.options.entities[i];
@@ -15851,7 +15853,7 @@ function Wl(c) {
15851
15853
  function Xl(c) {
15852
15854
  return c.startsWith(this.options.attributeNamePrefix) && c !== this.options.textNodeName ? c.substr(this.attrPrefixLen) : !1;
15853
15855
  }
15854
- var $l = De;
15856
+ var $l = be;
15855
15857
  const Zl = Gn, jl = Ul, ql = $l;
15856
15858
  var Co = {
15857
15859
  XMLParser: jl,
@@ -15941,9 +15943,9 @@ const Ie = class Ie {
15941
15943
  C(this, "creationDate", /* @__PURE__ */ new Date());
15942
15944
  C(this, "creationAuthor", "");
15943
15945
  // Store viewpoint guids instead of the actual Viewpoint to prevent a possible memory leak
15944
- C(this, "viewpoints", new Pe());
15946
+ C(this, "viewpoints", new we());
15945
15947
  // Store topic guids instead of the actual Topic to prevent a possible memory leak
15946
- C(this, "relatedTopics", new Pe());
15948
+ C(this, "relatedTopics", new we());
15947
15949
  // There is no problem to store the comment it-self as it is not referenced anywhere else
15948
15950
  C(this, "comments", new re());
15949
15951
  C(this, "customData", {});
@@ -16230,7 +16232,7 @@ const Ql = (c, i) => {
16230
16232
  c.config.users.add(a);
16231
16233
  }
16232
16234
  };
16233
- class Kl extends Ye {
16235
+ class Kl extends Ge {
16234
16236
  constructor() {
16235
16237
  super(...arguments);
16236
16238
  C(this, "_config", {
@@ -16416,10 +16418,10 @@ const Le = class Le extends At {
16416
16418
  Le.uuid
16417
16419
  ));
16418
16420
  C(this, "list", new re());
16419
- C(this, "onSetup", new Z());
16421
+ C(this, "onSetup", new j());
16420
16422
  C(this, "isSetup", !1);
16421
- C(this, "onBCFImported", new Z());
16422
- C(this, "onDisposed", new Z());
16423
+ C(this, "onBCFImported", new j());
16424
+ C(this, "onDisposed", new j());
16423
16425
  }
16424
16426
  setup(t) {
16425
16427
  if (this.isSetup)
@@ -16681,33 +16683,33 @@ ${o}
16681
16683
  ClippingPlanes: M,
16682
16684
  Components: L,
16683
16685
  OrthogonalCamera: b,
16684
- PerspectiveCamera: G
16686
+ PerspectiveCamera: Y
16685
16687
  } = S;
16686
16688
  if (y && (N.guid = y), L) {
16687
16689
  const { Selection: w, Visibility: g } = L;
16688
16690
  if (w && w.Component) {
16689
- const j = Array.isArray(w.Component) ? w.Component : [w.Component];
16690
- N.selectionComponents = j.map((V) => V.IfcGuid).filter((V) => V);
16691
+ const q = Array.isArray(w.Component) ? w.Component : [w.Component];
16692
+ N.selectionComponents = q.map((G) => G.IfcGuid).filter((G) => G);
16691
16693
  }
16692
16694
  if (g && "DefaultVisibility" in g && (N.defaultVisibility = g.DefaultVisibility), g && g.Exceptions && "Component" in g.Exceptions) {
16693
- const { Component: j } = g.Exceptions, V = Array.isArray(j) ? j : [j];
16694
- N.exceptionComponents = V.map((et) => et.IfcGuid).filter((et) => et);
16695
+ const { Component: q } = g.Exceptions, G = Array.isArray(q) ? q : [q];
16696
+ N.exceptionComponents = G.map((et) => et.IfcGuid).filter((et) => et);
16695
16697
  }
16696
16698
  let v;
16697
16699
  l === "2.1" && (v = L.ViewSetupHints), l === "3" && (v = (m = L.Visibility) == null ? void 0 : m.ViewSetupHints), v && ("OpeningsVisible" in v && (N.openingsVisible = v.OpeningsVisible), "SpacesVisible" in v && (N.spacesVisible = v.SpacesVisible), "SpaceBoundariesVisible" in v && (N.spaceBoundariesVisible = v.SpaceBoundariesVisible));
16698
16700
  }
16699
- if (b || G) {
16700
- const w = S.PerspectiveCamera ?? S.OrthogonalCamera, { CameraViewPoint: g, CameraDirection: v } = w, j = new D.Vector3(
16701
+ if (b || Y) {
16702
+ const w = S.PerspectiveCamera ?? S.OrthogonalCamera, { CameraViewPoint: g, CameraDirection: v } = w, q = new D.Vector3(
16701
16703
  Number(g.X),
16702
16704
  Number(g.Z),
16703
16705
  Number(-g.Y)
16704
- ), V = new D.Vector3(
16706
+ ), G = new D.Vector3(
16705
16707
  Number(v.X),
16706
16708
  Number(v.Z),
16707
16709
  Number(-v.Y)
16708
16710
  ), et = {
16709
- position: { x: j.x, y: j.y, z: j.z },
16710
- direction: { x: V.x, y: V.y, z: V.z },
16711
+ position: { x: q.x, y: q.y, z: q.z },
16712
+ direction: { x: G.x, y: G.y, z: G.z },
16711
16713
  aspectRatio: "AspectRatio" in w ? w.AspectRatio : 1
16712
16714
  // Temporal simplification
16713
16715
  };
@@ -16728,25 +16730,25 @@ ${o}
16728
16730
  if (w && w.Color) {
16729
16731
  const g = Array.isArray(w.Color) ? w.Color : [w.Color];
16730
16732
  for (const v of g) {
16731
- const { Color: j, Component: V } = v, W = (Array.isArray(V) ? V : [V]).map((nt) => nt.IfcGuid);
16732
- O.componentColors.set(j, W);
16733
+ const { Color: q, Component: G } = v, W = (Array.isArray(G) ? G : [G]).map((nt) => nt.IfcGuid);
16734
+ O.componentColors.set(q, W);
16733
16735
  }
16734
16736
  }
16735
16737
  }
16736
16738
  if (I.push(O), M) {
16737
16739
  const w = this.components.get(Sn), g = Array.isArray(M.ClippingPlane) ? M.ClippingPlane : [M.ClippingPlane];
16738
16740
  for (const v of g) {
16739
- const { Location: j, Direction: V } = v;
16740
- if (!(j && V))
16741
+ const { Location: q, Direction: G } = v;
16742
+ if (!(q && G))
16741
16743
  continue;
16742
16744
  const et = new D.Vector3(
16743
- j.X,
16744
- j.Z,
16745
- -j.Y
16745
+ q.X,
16746
+ q.Z,
16747
+ -q.Y
16746
16748
  ), W = new D.Vector3(
16747
- V.X,
16748
- -V.Z,
16749
- V.Y
16749
+ G.X,
16750
+ -G.Z,
16751
+ G.Y
16750
16752
  ), nt = w.createFromNormalAndCoplanarPoint(
16751
16753
  e,
16752
16754
  W,
@@ -16763,23 +16765,23 @@ ${o}
16763
16765
  TopicType: M,
16764
16766
  TopicStatus: L,
16765
16767
  Title: b,
16766
- CreationDate: G,
16768
+ CreationDate: Y,
16767
16769
  CreationAuthor: O
16768
16770
  } = N;
16769
- if (n && !(y && M && L && b && G && O))
16771
+ if (n && !(y && M && L && b && Y && O))
16770
16772
  continue;
16771
16773
  const w = new Rs(this.components);
16772
16774
  w.guid = y ?? w.guid;
16773
16775
  const g = this.getMarkupRelatedTopics(S, l);
16774
- E[w.guid] = new Set(g), w.type = M ?? w.type, w.status = L ?? w.status, w.title = b ?? w.title, w.creationDate = G ? new Date(G) : w.creationDate, w.creationAuthor = O ?? w.creationAuthor, w.serverAssignedId = N.ServerAssignedId, w.priority = N.Priority, w.index = N.Index, w.modifiedDate = N.ModifiedDate ? new Date(N.ModifiedDate) : void 0, w.modifiedAuthor = N.ModifiedAuthor, w.dueDate = N.DueDate ? new Date(N.DueDate) : void 0, w.assignedTo = N.AssignedTo, w.description = N.Description, w.stage = N.Stage;
16776
+ E[w.guid] = new Set(g), w.type = M ?? w.type, w.status = L ?? w.status, w.title = b ?? w.title, w.creationDate = Y ? new Date(Y) : w.creationDate, w.creationAuthor = O ?? w.creationAuthor, w.serverAssignedId = N.ServerAssignedId, w.priority = N.Priority, w.index = N.Index, w.modifiedDate = N.ModifiedDate ? new Date(N.ModifiedDate) : void 0, w.modifiedAuthor = N.ModifiedAuthor, w.dueDate = N.DueDate ? new Date(N.DueDate) : void 0, w.assignedTo = N.AssignedTo, w.description = N.Description, w.stage = N.Stage;
16775
16777
  const v = this.getMarkupLabels(S, l);
16776
16778
  for (const et of v)
16777
16779
  w.labels.add(et);
16778
- const j = this.getMarkupComments(S, l);
16779
- for (const et of j)
16780
+ const q = this.getMarkupComments(S, l);
16781
+ for (const et of q)
16780
16782
  w.comments.set(et.guid, et);
16781
- const V = this.getMarkupViewpoints(S, l);
16782
- for (const et of V) {
16783
+ const G = this.getMarkupViewpoints(S, l);
16784
+ for (const et of G) {
16783
16785
  if (!(et && et.Guid))
16784
16786
  continue;
16785
16787
  const W = u.list.get(et.Guid);
@@ -16818,7 +16820,7 @@ const ee = class ee extends At {
16818
16820
  /** {@link Component.enabled} */
16819
16821
  C(this, "enabled", !0);
16820
16822
  /** {@link Disposable.onDisposed} */
16821
- C(this, "onDisposed", new Z());
16823
+ C(this, "onDisposed", new j());
16822
16824
  C(this, "_absoluteMin");
16823
16825
  C(this, "_absoluteMax");
16824
16826
  C(this, "_meshes", []);
@@ -16894,7 +16896,7 @@ const ee = class ee extends At {
16894
16896
  }
16895
16897
  /** {@link Disposable.dispose} */
16896
16898
  dispose() {
16897
- const t = this.components.get(Me);
16899
+ const t = this.components.get(De);
16898
16900
  for (const e of this._meshes)
16899
16901
  t.destroy(e);
16900
16902
  this._meshes = [], this.onDisposed.trigger(ee.uuid), this.onDisposed.reset();
@@ -17094,7 +17096,7 @@ const Ps = class Ps {
17094
17096
  /**
17095
17097
  * Event used to notify the progress when performing a query on an IFC file.
17096
17098
  */
17097
- C(this, "onProgress", new Z());
17099
+ C(this, "onProgress", new j());
17098
17100
  /**
17099
17101
  * If false, ALL rules of the query must comply to make a match. If true, ANY rule will be enough to make a match.
17100
17102
  */
@@ -17654,7 +17656,7 @@ const bs = class bs extends At {
17654
17656
  */
17655
17657
  C(this, "list", {});
17656
17658
  /** {@link Disposable.onDisposed} */
17657
- C(this, "onDisposed", new Z());
17659
+ C(this, "onDisposed", new j());
17658
17660
  C(this, "onFragmentsDisposed", (t) => {
17659
17661
  const { groupID: e, fragmentIDs: s } = t;
17660
17662
  for (const n in this.list) {
@@ -17843,11 +17845,11 @@ const bs = class bs extends At {
17843
17845
  * @throws Will throw an error if the fragment ID is not found or if the IFC relationship is not valid.
17844
17846
  */
17845
17847
  async byIfcRel(t, e, s) {
17846
- ri.isRel(e) && await ri.getRelationMap(
17848
+ oi.isRel(e) && await oi.getRelationMap(
17847
17849
  t,
17848
17850
  e,
17849
17851
  async (n, r) => {
17850
- const { name: o } = await ri.getEntityName(
17852
+ const { name: o } = await oi.getEntityName(
17851
17853
  t,
17852
17854
  n
17853
17855
  );
@@ -17999,12 +18001,12 @@ const bs = class bs extends At {
17999
18001
  * This UUID is used to register the component within the Components system.
18000
18002
  */
18001
18003
  C(bs, "uuid", "e25a7f3c-46c4-4a14-9d3d-5115f24ebeb7");
18002
- let xi = bs;
18004
+ let Bi = bs;
18003
18005
  const vs = class vs extends At {
18004
18006
  constructor(t) {
18005
18007
  super(t);
18006
18008
  /** {@link Disposable.onDisposed} */
18007
- C(this, "onDisposed", new Z());
18009
+ C(this, "onDisposed", new j());
18008
18010
  /** {@link Component.enabled} */
18009
18011
  C(this, "enabled", !0);
18010
18012
  /**
@@ -18047,7 +18049,7 @@ const vs = class vs extends At {
18047
18049
  set(t) {
18048
18050
  if (!this.enabled)
18049
18051
  return;
18050
- const e = this.components.get(xi), s = this.components.get(Tt), n = t ? 1 : -1;
18052
+ const e = this.components.get(Bi), s = this.components.get(Tt), n = t ? 1 : -1;
18051
18053
  let r = 0;
18052
18054
  const o = e.list[this.groupName], a = new D.Matrix4();
18053
18055
  for (const l in o) {
@@ -18152,24 +18154,24 @@ const xs = class xs extends At {
18152
18154
  * Event triggered when geometry is streamed.
18153
18155
  * Contains the streamed geometry data and its buffer.
18154
18156
  */
18155
- C(this, "onGeometryStreamed", new Z());
18157
+ C(this, "onGeometryStreamed", new Pe());
18156
18158
  /**
18157
18159
  * Event triggered when assets are streamed.
18158
18160
  * Contains the streamed assets.
18159
18161
  */
18160
- C(this, "onAssetStreamed", new Z());
18162
+ C(this, "onAssetStreamed", new Pe());
18161
18163
  /**
18162
18164
  * Event triggered to indicate the progress of the streaming process.
18163
18165
  * Contains the progress percentage.
18164
18166
  */
18165
- C(this, "onProgress", new Z());
18167
+ C(this, "onProgress", new Pe());
18166
18168
  /**
18167
18169
  * Event triggered when the IFC file is loaded.
18168
18170
  * Contains the loaded IFC file data.
18169
18171
  */
18170
- C(this, "onIfcLoaded", new Z());
18172
+ C(this, "onIfcLoaded", new Pe());
18171
18173
  /** {@link Disposable.onDisposed} */
18172
- C(this, "onDisposed", new Z());
18174
+ C(this, "onDisposed", new j());
18173
18175
  /**
18174
18176
  * Settings for the IfcGeometryTiler.
18175
18177
  */
@@ -18274,9 +18276,9 @@ const xs = class xs extends At {
18274
18276
  for (const E of n) {
18275
18277
  h++, this.webIfc.StreamMeshes(0, E, (p) => {
18276
18278
  this.getMesh(this.webIfc, p, r);
18277
- }), this._assets.length > e && await this.streamAssets();
18279
+ }), this._geometryCount > this.settings.minGeometrySize && await this.streamGeometries(), this._assets.length > e && await this.streamAssets();
18278
18280
  const T = h / n.length;
18279
- T > l && (l += 0.01, l = Math.max(l, T), this.onProgress.trigger(Math.round(l * 100) / 100));
18281
+ T > l && (l += 0.01, l = Math.max(l, T), await this.onProgress.trigger(Math.round(l * 100) / 100));
18280
18282
  }
18281
18283
  this._geometryCount && await this.streamGeometries(), this._assets.length && await this.streamAssets();
18282
18284
  const { opaque: f, transparent: I } = r.geometryIDs;
@@ -18286,7 +18288,7 @@ const xs = class xs extends At {
18286
18288
  const u = this.webIfc.GetCoordinationMatrix(0);
18287
18289
  r.coordinationMatrix.fromArray(u), r.civilData = this._civil.read(this.webIfc);
18288
18290
  const d = this._groupSerializer.export(r);
18289
- this.onIfcLoaded.trigger(d), r.dispose(!0);
18291
+ await this.onIfcLoaded.trigger(d), r.dispose(!0);
18290
18292
  }
18291
18293
  cleanUp() {
18292
18294
  try {
@@ -18298,8 +18300,8 @@ const xs = class xs extends At {
18298
18300
  getMesh(t, e, s) {
18299
18301
  const n = e.geometries.size(), r = e.expressID, o = { id: r, geometries: [] };
18300
18302
  for (let a = 0; a < n; a++) {
18301
- const l = e.geometries.get(a), h = l.geometryExpressID, f = l.color.w === 1, u = h * (f ? 1 : -1);
18302
- this._visitedGeometries.has(u) || this.getGeometry(t, h, f), this.registerGeometryData(
18303
+ const l = e.geometries.get(a), h = l.geometryExpressID, I = l.color.w === 1 ? 1 : -1, u = h * I;
18304
+ this._visitedGeometries.has(u) || this.getGeometry(t, h, u), this.registerGeometryData(
18303
18305
  s,
18304
18306
  r,
18305
18307
  l,
@@ -18324,37 +18326,67 @@ const xs = class xs extends At {
18324
18326
  ), a = new Float32Array(o.length / 2), l = new Float32Array(o.length / 2);
18325
18327
  for (let u = 0; u < o.length; u += 6)
18326
18328
  a[u / 2] = o[u], a[u / 2 + 1] = o[u + 1], a[u / 2 + 2] = o[u + 2], l[u / 2] = o[u + 3], l[u / 2 + 1] = o[u + 4], l[u / 2 + 2] = o[u + 5];
18329
+ if (r.length === 0) {
18330
+ const u = new Float32Array([
18331
+ 0,
18332
+ 0,
18333
+ 0,
18334
+ 0,
18335
+ 0,
18336
+ 0,
18337
+ 0,
18338
+ 0,
18339
+ 0,
18340
+ 0,
18341
+ 0,
18342
+ 0,
18343
+ 0,
18344
+ 0,
18345
+ 0,
18346
+ 1
18347
+ ]);
18348
+ this._geometries.set(e, {
18349
+ position: a,
18350
+ normal: l,
18351
+ index: r,
18352
+ boundingBox: u,
18353
+ hasHoles: !1
18354
+ });
18355
+ const d = this._visitedGeometries.size, E = D.MathUtils.generateUUID();
18356
+ this._visitedGeometries.set(s, { uuid: E, index: d }), this._geometryCount++, n.delete();
18357
+ return;
18358
+ }
18327
18359
  const f = (this.settings.maxTriangles || r.length / 3) * 3;
18328
18360
  let I = !0;
18329
18361
  for (let u = 0; u < r.length; u += f) {
18330
18362
  const d = r.length - u, E = Math.min(d, f), T = u + E, p = [], m = [], F = [];
18331
18363
  let R = 0;
18332
- for (let j = u; j < T; j++) {
18364
+ for (let g = u; g < T; g++) {
18333
18365
  p.push(R++);
18334
- const V = r[j];
18335
- m.push(a[V * 3]), m.push(a[V * 3 + 1]), m.push(a[V * 3 + 2]), F.push(l[V * 3]), F.push(l[V * 3 + 1]), F.push(l[V * 3 + 2]);
18366
+ const v = r[g];
18367
+ m.push(a[v * 3]), m.push(a[v * 3 + 1]), m.push(a[v * 3 + 2]), F.push(l[v * 3]), F.push(l[v * 3 + 1]), F.push(l[v * 3 + 2]);
18336
18368
  }
18337
- const S = new Uint32Array(p), N = new Float32Array(m), y = new Float32Array(F), M = qa(N), L = new Float32Array(M.transformation.elements), b = !1, G = I ? e : this._nextAvailableID++;
18338
- this._geometries.set(G, {
18369
+ const S = new Uint32Array(p), N = new Float32Array(m), y = new Float32Array(F), M = qa(N), L = new Float32Array(M.transformation.elements), b = !1, Y = I ? e : this._nextAvailableID++;
18370
+ this._geometries.set(Y, {
18339
18371
  position: N,
18340
18372
  normal: y,
18341
18373
  index: S,
18342
18374
  boundingBox: L,
18343
18375
  hasHoles: b
18344
- }), I || (this._splittedGeometries.has(e) || this._splittedGeometries.set(e, /* @__PURE__ */ new Set()), this._splittedGeometries.get(e).add(G));
18345
- const w = G * (s ? 1 : -1), g = this._visitedGeometries.size, v = D.MathUtils.generateUUID();
18346
- this._visitedGeometries.set(w, { uuid: v, index: g }), this._geometryCount++, I = !1, this._geometryCount > this.settings.minGeometrySize && this.streamGeometries();
18376
+ }), I || (this._splittedGeometries.has(e) || this._splittedGeometries.set(e, /* @__PURE__ */ new Set()), this._splittedGeometries.get(e).add(Y));
18377
+ const O = this._visitedGeometries.size, w = D.MathUtils.generateUUID();
18378
+ this._visitedGeometries.set(s, { uuid: w, index: O }), this._geometryCount++, I = !1;
18347
18379
  }
18348
18380
  n.delete();
18349
18381
  }
18350
18382
  async streamAssets() {
18351
18383
  await this.onAssetStreamed.trigger(this._assets), this._assets = null, this._assets = [];
18352
18384
  }
18353
- streamGeometries() {
18385
+ async streamGeometries() {
18354
18386
  let t = this._streamSerializer.export(this._geometries), e = {};
18355
18387
  for (const [s, { boundingBox: n, hasHoles: r }] of this._geometries)
18356
18388
  e[s] = { boundingBox: n, hasHoles: r };
18357
- this.onGeometryStreamed.trigger({ data: e, buffer: t }), e = null, t = null, this._geometries.clear(), this._geometryCount = 0;
18389
+ await this.onGeometryStreamed.trigger({ data: e, buffer: t }), e = null, t = null, this._geometries.clear(), this._geometryCount = 0;
18358
18390
  }
18359
18391
  registerGeometryData(t, e, s, n, r, o) {
18360
18392
  const a = this._visitedGeometries.get(o);
@@ -18391,19 +18423,19 @@ class eh extends At {
18391
18423
  * An event that is triggered when properties are streamed from the IFC file.
18392
18424
  * The event provides the type of the IFC entity and the corresponding data.
18393
18425
  */
18394
- C(this, "onPropertiesStreamed", new Is());
18426
+ C(this, "onPropertiesStreamed", new Pe());
18395
18427
  /**
18396
18428
  * An event that is triggered to indicate the progress of the streaming process.
18397
18429
  * The event provides a number between 0 and 1 representing the progress percentage.
18398
18430
  */
18399
- C(this, "onProgress", new Is());
18431
+ C(this, "onProgress", new Pe());
18400
18432
  /**
18401
18433
  * An event that is triggered when indices are streamed from the IFC file.
18402
18434
  * The event provides a map of indices, where the key is the entity type and the value is another map of indices.
18403
18435
  */
18404
- C(this, "onIndicesStreamed", new Is());
18436
+ C(this, "onIndicesStreamed", new Pe());
18405
18437
  /** {@link Disposable.onDisposed} */
18406
- C(this, "onDisposed", new Z());
18438
+ C(this, "onDisposed", new j());
18407
18439
  /** {@link Component.enabled} */
18408
18440
  C(this, "enabled", !0);
18409
18441
  /**
@@ -18513,7 +18545,7 @@ class To {
18513
18545
  * The Direction vector points in the invisible direction meaning the half-space that is clipped.
18514
18546
  * @experimental
18515
18547
  */
18516
- C(this, "clippingPlanes", new Pe());
18548
+ C(this, "clippingPlanes", new we());
18517
18549
  C(this, "camera", {
18518
18550
  aspectRatio: 0,
18519
18551
  fov: 0,
@@ -18523,11 +18555,11 @@ class To {
18523
18555
  /**
18524
18556
  * A list of components GUIDs to hide when defaultVisibility = true or to show when defaultVisibility = false
18525
18557
  */
18526
- C(this, "exceptionComponents", new Pe());
18558
+ C(this, "exceptionComponents", new we());
18527
18559
  /**
18528
18560
  * A list of components GUIDs that should be selected (highlighted) when displaying a viewpoint.
18529
18561
  */
18530
- C(this, "selectionComponents", new Pe());
18562
+ C(this, "selectionComponents", new we());
18531
18563
  /**
18532
18564
  * A map of colors and components GUIDs that should be colorized when displaying a viewpoint.
18533
18565
  * For this to work, call viewpoint.colorize()
@@ -18723,7 +18755,7 @@ class To {
18723
18755
  };
18724
18756
  const r = this.selection;
18725
18757
  if (Object.keys(r).length === 0) {
18726
- const h = this._components.get(ai).get(this.world).castRayFromVector(e, this.direction);
18758
+ const h = this._components.get(ci).get(this.world).castRayFromVector(e, this.direction);
18727
18759
  h && (n = h.point);
18728
18760
  } else {
18729
18761
  const a = this._components.get(wn);
@@ -18790,7 +18822,7 @@ class To {
18790
18822
  * The color is provided as a hexadecimal string, prefixed with a '#'.
18791
18823
  */
18792
18824
  colorize() {
18793
- const i = this._components.get(ie), t = this._components.get(Tt), e = this._components.get(xi);
18825
+ const i = this._components.get(ie), t = this._components.get(Tt), e = this._components.get(Bi);
18794
18826
  for (const [s, n] of this.componentColors) {
18795
18827
  const r = t.guidToFragmentIdMap(n), o = new D.Color(`#${s}`);
18796
18828
  e.setColor(
@@ -18806,7 +18838,7 @@ class To {
18806
18838
  * corresponding to each color, and then uses the `Classifier` to reset the color of those fragments.
18807
18839
  */
18808
18840
  resetColors() {
18809
- const i = this._components.get(Tt), t = this._components.get(xi);
18841
+ const i = this._components.get(Tt), t = this._components.get(Bi);
18810
18842
  for (const [e, s] of this.componentColors) {
18811
18843
  const n = i.guidToFragmentIdMap(s);
18812
18844
  t.resetColor(n);
@@ -18902,7 +18934,7 @@ class To {
18902
18934
  </VisualizationInfo>`;
18903
18935
  }
18904
18936
  }
18905
- class ih extends Ye {
18937
+ class ih extends Ge {
18906
18938
  constructor() {
18907
18939
  super(...arguments);
18908
18940
  C(this, "_config", {
@@ -18919,7 +18951,7 @@ class ih extends Ye {
18919
18951
  this._config.overwriteColors.value = t;
18920
18952
  }
18921
18953
  }
18922
- const vi = class vi extends At {
18954
+ const Ui = class Ui extends At {
18923
18955
  constructor(t) {
18924
18956
  super(t);
18925
18957
  C(this, "enabled", !0);
@@ -18929,16 +18961,16 @@ const vi = class vi extends At {
18929
18961
  */
18930
18962
  C(this, "list", new re());
18931
18963
  C(this, "isSetup", !1);
18932
- C(this, "onSetup", new Z());
18964
+ C(this, "onSetup", new j());
18933
18965
  C(this, "config", new ih(
18934
18966
  this,
18935
18967
  this.components,
18936
18968
  "Viewpoints",
18937
- vi.uuid
18969
+ Ui.uuid
18938
18970
  ));
18939
18971
  /** {@link Disposable.onDisposed} */
18940
- C(this, "onDisposed", new Z());
18941
- t.add(vi.uuid, this);
18972
+ C(this, "onDisposed", new j());
18973
+ t.add(Ui.uuid, this);
18942
18974
  }
18943
18975
  /**
18944
18976
  * Creates a new Viewpoint instance and adds it to the list.
@@ -18965,9 +18997,9 @@ const vi = class vi extends At {
18965
18997
  this.list.dispose(), this.onDisposed.trigger(), this.onDisposed.reset();
18966
18998
  }
18967
18999
  };
18968
- C(vi, "uuid", "ee867824-a796-408d-8aa0-4e5962a83c66");
18969
- let ie = vi;
18970
- class sh extends Ye {
19000
+ C(Ui, "uuid", "ee867824-a796-408d-8aa0-4e5962a83c66");
19001
+ let ie = Ui;
19002
+ class sh extends Ge {
18971
19003
  constructor() {
18972
19004
  super(...arguments);
18973
19005
  C(this, "_config", {
@@ -19111,15 +19143,15 @@ class sh extends Ye {
19111
19143
  class nh {
19112
19144
  constructor(i, t) {
19113
19145
  /** {@link Disposable.onDisposed} */
19114
- C(this, "onDisposed", new Z());
19146
+ C(this, "onDisposed", new j());
19115
19147
  /** {@link Updateable.onAfterUpdate} */
19116
- C(this, "onAfterUpdate", new Z());
19148
+ C(this, "onAfterUpdate", new j());
19117
19149
  /** {@link Updateable.onBeforeUpdate} */
19118
- C(this, "onBeforeUpdate", new Z());
19150
+ C(this, "onBeforeUpdate", new j());
19119
19151
  /** {@link Resizeable.onResize} */
19120
- C(this, "onResize", new Z());
19152
+ C(this, "onResize", new j());
19121
19153
  /** {@link Configurable.onSetup} */
19122
- C(this, "onSetup", new Z());
19154
+ C(this, "onSetup", new j());
19123
19155
  /**
19124
19156
  * The front offset of the minimap.
19125
19157
  * It determines how much the minimap's view is offset from the camera's view.
@@ -19273,13 +19305,13 @@ const Bs = class Bs extends At {
19273
19305
  constructor(t) {
19274
19306
  super(t);
19275
19307
  /** {@link Updateable.onAfterUpdate} */
19276
- C(this, "onAfterUpdate", new Z());
19308
+ C(this, "onAfterUpdate", new j());
19277
19309
  /** {@link Updateable.onBeforeUpdate} */
19278
- C(this, "onBeforeUpdate", new Z());
19310
+ C(this, "onBeforeUpdate", new j());
19279
19311
  /** {@link Disposable.onDisposed} */
19280
- C(this, "onDisposed", new Z());
19312
+ C(this, "onDisposed", new j());
19281
19313
  /** {@link Configurable.onSetup} */
19282
- C(this, "onSetup", new Z());
19314
+ C(this, "onSetup", new j());
19283
19315
  /** {@link Component.enabled} */
19284
19316
  C(this, "enabled", !0);
19285
19317
  /**
@@ -19413,11 +19445,11 @@ const Vs = class Vs extends At {
19413
19445
  N.add(S);
19414
19446
  }
19415
19447
  for (const S of p) {
19416
- const N = f.get(S), { edges: y, indices: M } = N, L = f.get(T), { edges: b, indices: G } = L;
19448
+ const N = f.get(S), { edges: y, indices: M } = N, L = f.get(T), { edges: b, indices: Y } = L;
19417
19449
  for (const O of y)
19418
19450
  b.add(O), h.set(O, T);
19419
19451
  for (const O of M)
19420
- G.add(O);
19452
+ Y.add(O);
19421
19453
  f.delete(S);
19422
19454
  }
19423
19455
  }
@@ -20314,8 +20346,8 @@ class lh {
20314
20346
  C(this, "description");
20315
20347
  C(this, "instructions");
20316
20348
  C(this, "requirementsDescription");
20317
- C(this, "applicability", new Pe());
20318
- C(this, "requirements", new Pe());
20349
+ C(this, "applicability", new we());
20350
+ C(this, "requirements", new we());
20319
20351
  C(this, "components");
20320
20352
  this.components = i, this.name = t;
20321
20353
  for (const s of e)
@@ -20416,12 +20448,12 @@ const Re = (c) => {
20416
20448
  (l == null ? void 0 : l.type) === "enumeration" && Array.isArray(l.parameter) && (l.parameter = l.parameter.map(String)), a.value = l, a.dataType = e.dataType, a.uri = e.uri, t.push(a);
20417
20449
  }
20418
20450
  return t;
20419
- }, ni = class ni extends At {
20451
+ }, ri = class ri extends At {
20420
20452
  constructor(t) {
20421
20453
  super(t);
20422
20454
  C(this, "enabled", !0);
20423
20455
  C(this, "list", new re());
20424
- t.add(ni.uuid, this);
20456
+ t.add(ri.uuid, this);
20425
20457
  }
20426
20458
  /**
20427
20459
  * Retrieves a FragmentIdMap based on the given IDSCheckResult array.
@@ -20464,7 +20496,7 @@ const Re = (c) => {
20464
20496
  * @returns An array of IDSSpecification instances created from the parsed data.
20465
20497
  */
20466
20498
  load(t) {
20467
- const e = [], s = ni.xmlParser.parse(t).ids, { specifications: n } = s;
20499
+ const e = [], s = ri.xmlParser.parse(t).ids, { specifications: n } = s;
20468
20500
  if (n && n.specification) {
20469
20501
  const r = Array.isArray(n.specification) ? n.specification : [n.specification];
20470
20502
  for (const o of r) {
@@ -20547,7 +20579,7 @@ const Re = (c) => {
20547
20579
  </ids:ids>`;
20548
20580
  }
20549
20581
  };
20550
- C(ni, "uuid", "9f0b9f78-9b2e-481a-b766-2fbfd01f342c"), C(ni, "xmlParser", new Co.XMLParser({
20582
+ C(ri, "uuid", "9f0b9f78-9b2e-481a-b766-2fbfd01f342c"), C(ri, "xmlParser", new Co.XMLParser({
20551
20583
  allowBooleanAttributes: !0,
20552
20584
  attributeNamePrefix: "",
20553
20585
  ignoreAttributes: !1,
@@ -20560,9 +20592,9 @@ C(ni, "uuid", "9f0b9f78-9b2e-481a-b766-2fbfd01f342c"), C(ni, "xmlParser", new Co
20560
20592
  removeNSPrefix: !0,
20561
20593
  trimValues: !0
20562
20594
  }));
20563
- let $r = ni;
20595
+ let $r = ri;
20564
20596
  export {
20565
- Is as AsyncEvent,
20597
+ Pe as AsyncEvent,
20566
20598
  Mt as BCFTopics,
20567
20599
  Kl as BCFTopicsConfigManager,
20568
20600
  xn as Base,
@@ -20571,20 +20603,20 @@ export {
20571
20603
  Ga as BaseScene,
20572
20604
  Bn as BaseWorldItem,
20573
20605
  wn as BoundingBoxer,
20574
- xi as Classifier,
20606
+ Bi as Classifier,
20575
20607
  Sn as Clipper,
20576
20608
  Pn as Comment,
20577
20609
  At as Component,
20578
20610
  ph as ComponentWithUI,
20579
20611
  Cs as Components,
20580
- Ve as ConfigManager,
20581
- Ye as Configurator,
20612
+ Ye as ConfigManager,
20613
+ Ge as Configurator,
20582
20614
  lc as CullerRenderer,
20583
20615
  Fn as Cullers,
20584
20616
  re as DataMap,
20585
- Pe as DataSet,
20586
- Me as Disposer,
20587
- Z as Event,
20617
+ we as DataSet,
20618
+ De as Disposer,
20619
+ j as Event,
20588
20620
  zr as Exploder,
20589
20621
  Oc as FirstPersonMode,
20590
20622
  Tt as FragmentsManager,
@@ -20610,7 +20642,7 @@ export {
20610
20642
  Nn as IfcLoader,
20611
20643
  yn as IfcPropertiesManager,
20612
20644
  eh as IfcPropertiesTiler,
20613
- ri as IfcPropertiesUtils,
20645
+ oi as IfcPropertiesUtils,
20614
20646
  As as IfcPropertyQuery,
20615
20647
  kt as IfcRelationsIndexer,
20616
20648
  Jl as IfcStreamingSettings,
@@ -20626,9 +20658,9 @@ export {
20626
20658
  yc as PlanMode,
20627
20659
  Lc as ProjectionManager,
20628
20660
  th as PropertiesStreamingSettings,
20629
- ai as Raycasters,
20661
+ ci as Raycasters,
20630
20662
  Rh as ShadowedScene,
20631
- Ui as SimpleCamera,
20663
+ xi as SimpleCamera,
20632
20664
  Ec as SimpleGrid,
20633
20665
  dc as SimpleGridConfigManager,
20634
20666
  Vn as SimplePlane,