gl-draw 0.15.13 → 0.15.14

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.
@@ -26,13 +26,13 @@ var se = (h, e, t) => new Promise((s, i) => {
26
26
  }, n = (a) => a.done ? s(a.value) : Promise.resolve(a.value).then(r, o);
27
27
  n((t = t.apply(h, e)).next());
28
28
  });
29
- import { WebGLRenderer as Ut, Vector3 as H, PerspectiveCamera as zt, Matrix4 as W, Scene as nt, AxesHelper as De, CameraHelper as kt, PointLightHelper as Ft, DirectionalLightHelper as Nt, SpotLightHelper as jt, HemisphereLightHelper as Ht, Box3 as at, Box3Helper as Ue, MathUtils as It, Vector2 as B, Vector4 as Bt, Quaternion as lt, Spherical as Vt, Sphere as Yt, Raycaster as ht, REVISION as Zt, Object3D as Wt, UniformsUtils as Kt, RawShaderMaterial as $t, ShaderMaterial as Gt, MeshBasicMaterial as Xt, PointsMaterial as ct, SpriteMaterial as dt, Layers as qt, WebGLRenderTarget as Qt, HalfFloatType as Jt, Loader as mt, Texture as ue, VideoTexture as pt, FileLoader as Ae, LoadingManager as es, DataTexture as ts, Group as ze } from "three";
29
+ import { WebGLRenderer as Ut, Vector3 as H, PerspectiveCamera as zt, Matrix4 as W, Scene as nt, AxesHelper as De, CameraHelper as kt, PointLightHelper as Ft, DirectionalLightHelper as Nt, SpotLightHelper as jt, HemisphereLightHelper as Ht, Box3 as at, Box3Helper as Ue, MathUtils as It, Vector2 as B, Vector4 as Bt, Quaternion as lt, Spherical as Vt, Sphere as Yt, Raycaster as ht, REVISION as Zt, Object3D as Wt, UniformsUtils as Kt, RawShaderMaterial as $t, ShaderMaterial as Gt, MeshBasicMaterial as Xt, PointsMaterial as ct, SpriteMaterial as dt, Layers as qt, WebGLRenderTarget as Qt, HalfFloatType as Jt, Loader as mt, Texture as fe, VideoTexture as pt, FileLoader as Ae, LoadingManager as es, DataTexture as ts, Group as ze } from "three";
30
30
  import { Timer as ss } from "three/examples/jsm/misc/Timer";
31
31
  import * as Ce from "@tweenjs/tween.js";
32
32
  import is from "deepmerge";
33
33
  import rs from "stats-gl";
34
34
  import { C as os, c as ns, i as as } from "./isPlainObject.module.js";
35
- import { R as Pe, M as ft, B as ls } from "./index.module2.js";
35
+ import { R as Pe, M as ut, B as Oe, a as ls, I as he } from "./index.module2.js";
36
36
  import { RectAreaLightHelper as hs } from "three/examples/jsm/helpers/RectAreaLightHelper";
37
37
  import { ViewHelper as cs } from "three/examples/jsm/helpers/ViewHelper";
38
38
  import { TransformControls as ds } from "three/examples/jsm/controls/TransformControls";
@@ -40,8 +40,8 @@ import { EffectComposer as ke } from "three/examples/jsm/postprocessing/EffectCo
40
40
  import { RenderPass as ms } from "three/examples/jsm/postprocessing/RenderPass";
41
41
  import { SSAOPass as ps } from "three/examples/jsm/postprocessing/SSAOPass";
42
42
  import { FullScreenQuad as Fe } from "three/examples/jsm/postprocessing/Pass";
43
- import { OutputPass as fs } from "three/examples/jsm/postprocessing/OutputPass";
44
- import { ShaderPass as us } from "three/examples/jsm/postprocessing/ShaderPass";
43
+ import { OutputPass as us } from "three/examples/jsm/postprocessing/OutputPass";
44
+ import { ShaderPass as fs } from "three/examples/jsm/postprocessing/ShaderPass";
45
45
  import { UnrealBloomPass as _s } from "three/examples/jsm/postprocessing/UnrealBloomPass";
46
46
  import "three/examples/jsm/renderers/CSS2DRenderer";
47
47
  import "three/examples/jsm/renderers/CSS3DRenderer";
@@ -95,14 +95,14 @@ function Y(h) {
95
95
  function I(h) {
96
96
  return h.isOrthographicCamera;
97
97
  }
98
- const $ = Math.PI * 2, He = Math.PI / 2, ut = 1e-5, ie = Math.PI / 180;
98
+ const $ = Math.PI * 2, He = Math.PI / 2, ft = 1e-5, ie = Math.PI / 180;
99
99
  function k(h, e, t) {
100
100
  return Math.max(e, Math.min(t, h));
101
101
  }
102
- function S(h, e = ut) {
102
+ function S(h, e = ft) {
103
103
  return Math.abs(h) < e;
104
104
  }
105
- function P(h, e, t = ut) {
105
+ function P(h, e, t = ft) {
106
106
  return S(h - e, t);
107
107
  }
108
108
  function Ie(h, e) {
@@ -114,38 +114,38 @@ function re(h) {
114
114
  function oe(h) {
115
115
  return Math.abs(h) < Number.MAX_VALUE ? h : h * (1 / 0);
116
116
  }
117
- function he(h, e, t, s, i = 1 / 0, r) {
117
+ function ce(h, e, t, s, i = 1 / 0, r) {
118
118
  s = Math.max(1e-4, s);
119
119
  const o = 2 / s, n = o * r, a = 1 / (1 + n + 0.48 * n * n + 0.235 * n * n * n);
120
120
  let c = h - e;
121
- const u = e, m = i * s;
121
+ const f = e, m = i * s;
122
122
  c = k(c, -m, m), e = h - c;
123
123
  const v = (t.value + o * c) * r;
124
124
  t.value = (t.value - o * v) * a;
125
125
  let p = e + (c + v) * a;
126
- return u - h > 0 == p > u && (p = u, t.value = (p - u) / r), p;
126
+ return f - h > 0 == p > f && (p = f, t.value = (p - f) / r), p;
127
127
  }
128
128
  function Be(h, e, t, s, i = 1 / 0, r, o) {
129
129
  s = Math.max(1e-4, s);
130
130
  const n = 2 / s, a = n * r, c = 1 / (1 + a + 0.48 * a * a + 0.235 * a * a * a);
131
- let u = e.x, m = e.y, v = e.z, p = h.x - u, f = h.y - m, g = h.z - v;
132
- const y = u, l = m, _ = v, O = i * s, C = O * O, w = p * p + f * f + g * g;
131
+ let f = e.x, m = e.y, v = e.z, p = h.x - f, u = h.y - m, g = h.z - v;
132
+ const y = f, l = m, _ = v, O = i * s, C = O * O, w = p * p + u * u + g * g;
133
133
  if (w > C) {
134
134
  const ve = Math.sqrt(w);
135
- p = p / ve * O, f = f / ve * O, g = g / ve * O;
135
+ p = p / ve * O, u = u / ve * O, g = g / ve * O;
136
136
  }
137
- u = h.x - p, m = h.y - f, v = h.z - g;
138
- const E = (t.x + n * p) * r, x = (t.y + n * f) * r, R = (t.z + n * g) * r;
139
- t.x = (t.x - n * E) * c, t.y = (t.y - n * x) * c, t.z = (t.z - n * R) * c, o.x = u + (p + E) * c, o.y = m + (f + x) * c, o.z = v + (g + R) * c;
137
+ f = h.x - p, m = h.y - u, v = h.z - g;
138
+ const E = (t.x + n * p) * r, x = (t.y + n * u) * r, R = (t.z + n * g) * r;
139
+ t.x = (t.x - n * E) * c, t.y = (t.y - n * x) * c, t.z = (t.z - n * R) * c, o.x = f + (p + E) * c, o.y = m + (u + x) * c, o.z = v + (g + R) * c;
140
140
  const V = y - h.x, le = l - h.y, bt = _ - h.z, xt = o.x - y, Lt = o.y - l, Pt = o.z - _;
141
141
  return V * xt + le * Lt + bt * Pt > 0 && (o.x = y, o.y = l, o.z = _, t.x = (o.x - y) / r, t.y = (o.y - l) / r, t.z = (o.z - _) / r), o;
142
142
  }
143
- function Oe(h, e) {
143
+ function Ee(h, e) {
144
144
  e.set(0, 0), h.forEach((t) => {
145
145
  e.x += t.clientX, e.y += t.clientY;
146
146
  }), e.x /= h.length, e.y /= h.length;
147
147
  }
148
- function Ee(h, e) {
148
+ function Te(h, e) {
149
149
  return I(h) ? (console.warn(`${e} is not supported in OrthographicCamera`), !0) : !1;
150
150
  }
151
151
  class Os {
@@ -212,11 +212,11 @@ class Os {
212
212
  }
213
213
  }
214
214
  }
215
- const ce = 1 / 8, Es = /Mac/.test(navigator.platform);
216
- let T, Ve, de, Te, D, b, L, G, ne, F, N, Z, Ye, Ze, z, ae, X, We, we, Ke, be, xe, me;
215
+ const de = 1 / 8, Es = /Mac/.test(navigator.platform);
216
+ let T, Ve, me, we, D, b, L, G, ne, F, N, Z, Ye, Ze, z, ae, X, We, be, Ke, xe, Le, pe;
217
217
  class J extends Os {
218
218
  static install(e) {
219
- T = e.THREE, Ve = Object.freeze(new T.Vector3(0, 0, 0)), de = Object.freeze(new T.Vector3(0, 1, 0)), Te = Object.freeze(new T.Vector3(0, 0, 1)), D = new T.Vector2(), b = new T.Vector3(), L = new T.Vector3(), G = new T.Vector3(), ne = new T.Vector3(), F = new T.Vector3(), N = new T.Vector3(), Z = new T.Vector3(), Ye = new T.Vector3(), Ze = new T.Vector3(), z = new T.Spherical(), ae = new T.Spherical(), X = new T.Box3(), We = new T.Box3(), we = new T.Sphere(), Ke = new T.Quaternion(), be = new T.Quaternion(), xe = new T.Matrix4(), me = new T.Raycaster();
219
+ T = e.THREE, Ve = Object.freeze(new T.Vector3(0, 0, 0)), me = Object.freeze(new T.Vector3(0, 1, 0)), we = Object.freeze(new T.Vector3(0, 0, 1)), D = new T.Vector2(), b = new T.Vector3(), L = new T.Vector3(), G = new T.Vector3(), ne = new T.Vector3(), F = new T.Vector3(), N = new T.Vector3(), Z = new T.Vector3(), Ye = new T.Vector3(), Ze = new T.Vector3(), z = new T.Spherical(), ae = new T.Spherical(), X = new T.Box3(), We = new T.Box3(), be = new T.Sphere(), Ke = new T.Quaternion(), xe = new T.Quaternion(), Le = new T.Matrix4(), pe = new T.Raycaster();
220
220
  }
221
221
  /**
222
222
  * list all ACTIONs
@@ -282,7 +282,7 @@ class J extends Os {
282
282
  "camera-controls: `THREE` is undefined. You must first run `CameraControls.install( { THREE: THREE } )`. Check the docs for further information."
283
283
  ), this._camera = e, this._yAxisUpSpace = new T.Quaternion().setFromUnitVectors(
284
284
  this._camera.up,
285
- de
285
+ me
286
286
  ), this._yAxisUpSpaceInverse = this._yAxisUpSpace.clone().invert(), this._state = d.NONE, this._target = new T.Vector3(), this._targetEnd = this._target.clone(), this._focalOffset = new T.Vector3(), this._focalOffsetEnd = this._focalOffset.clone(), this._spherical = new T.Spherical().setFromVector3(
287
287
  b.copy(this._camera.position).applyQuaternion(this._yAxisUpSpace)
288
288
  ), 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 = [
@@ -377,11 +377,11 @@ class J extends Os {
377
377
  }
378
378
  else
379
379
  this._state = d.NONE;
380
- f();
380
+ u();
381
381
  }
382
382
  };
383
383
  let c = -1;
384
- const u = (l) => {
384
+ const f = (l) => {
385
385
  if (!this._domElement || !this._enabled || this.mouseButtons.wheel === d.NONE) return;
386
386
  if (this._interactiveArea.left !== 0 || this._interactiveArea.top !== 0 || this._interactiveArea.width !== 1 || this._interactiveArea.height !== 1) {
387
387
  const E = this._domElement.getBoundingClientRect(), x = (l.clientX - E.left) / (E.right - E.left), R = (l.clientY - E.top) / (E.bottom - E.top);
@@ -438,7 +438,7 @@ class J extends Os {
438
438
  }
439
439
  }, v = (l) => {
440
440
  if (!this._enabled) return;
441
- if (Oe(this._activePointers, D), this._getClientRect(this._elementRect), s.copy(D), i.copy(D), this._activePointers.length >= 2) {
441
+ if (Ee(this._activePointers, D), this._getClientRect(this._elementRect), s.copy(D), i.copy(D), this._activePointers.length >= 2) {
442
442
  const O = D.x - this._activePointers[1].clientX, C = D.y - this._activePointers[1].clientY, w = Math.sqrt(O * O + C * C);
443
443
  r.set(0, w);
444
444
  const E = (this._activePointers[0].clientX + this._activePointers[1].clientX) * 0.5, x = (this._activePointers[0].clientY + this._activePointers[1].clientY) * 0.5;
@@ -463,16 +463,16 @@ class J extends Os {
463
463
  ((this._state & d.ROTATE) === d.ROTATE || (this._state & d.TOUCH_ROTATE) === d.TOUCH_ROTATE || (this._state & d.TOUCH_DOLLY_ROTATE) === d.TOUCH_DOLLY_ROTATE || (this._state & d.TOUCH_ZOOM_ROTATE) === d.TOUCH_ZOOM_ROTATE) && (this._sphericalEnd.theta = this._spherical.theta, this._sphericalEnd.phi = this._spherical.phi, this._thetaVelocity.value = 0, this._phiVelocity.value = 0), ((this._state & d.TRUCK) === d.TRUCK || (this._state & d.SCREEN_PAN) === d.SCREEN_PAN || (this._state & d.TOUCH_TRUCK) === d.TOUCH_TRUCK || (this._state & d.TOUCH_SCREEN_PAN) === d.TOUCH_SCREEN_PAN || (this._state & d.TOUCH_DOLLY_TRUCK) === d.TOUCH_DOLLY_TRUCK || (this._state & d.TOUCH_DOLLY_SCREEN_PAN) === d.TOUCH_DOLLY_SCREEN_PAN || (this._state & d.TOUCH_ZOOM_TRUCK) === d.TOUCH_ZOOM_TRUCK || (this._state & d.TOUCH_ZOOM_SCREEN_PAN) === d.TOUCH_DOLLY_SCREEN_PAN) && (this._targetEnd.copy(this._target), this._targetVelocity.set(0, 0, 0)), ((this._state & d.DOLLY) === d.DOLLY || (this._state & d.TOUCH_DOLLY) === d.TOUCH_DOLLY || (this._state & d.TOUCH_DOLLY_TRUCK) === d.TOUCH_DOLLY_TRUCK || (this._state & d.TOUCH_DOLLY_SCREEN_PAN) === d.TOUCH_DOLLY_SCREEN_PAN || (this._state & d.TOUCH_DOLLY_OFFSET) === d.TOUCH_DOLLY_OFFSET || (this._state & d.TOUCH_DOLLY_ROTATE) === d.TOUCH_DOLLY_ROTATE) && (this._sphericalEnd.radius = this._spherical.radius, this._radiusVelocity.value = 0), ((this._state & d.ZOOM) === d.ZOOM || (this._state & d.TOUCH_ZOOM) === d.TOUCH_ZOOM || (this._state & d.TOUCH_ZOOM_TRUCK) === d.TOUCH_ZOOM_TRUCK || (this._state & d.TOUCH_ZOOM_SCREEN_PAN) === d.TOUCH_ZOOM_SCREEN_PAN || (this._state & d.TOUCH_ZOOM_OFFSET) === d.TOUCH_ZOOM_OFFSET || (this._state & d.TOUCH_ZOOM_ROTATE) === d.TOUCH_ZOOM_ROTATE) && (this._zoomEnd = this._zoom, this._zoomVelocity.value = 0), ((this._state & d.OFFSET) === d.OFFSET || (this._state & d.TOUCH_OFFSET) === d.TOUCH_OFFSET || (this._state & d.TOUCH_DOLLY_OFFSET) === d.TOUCH_DOLLY_OFFSET || (this._state & d.TOUCH_ZOOM_OFFSET) === d.TOUCH_ZOOM_OFFSET) && (this._focalOffsetEnd.copy(this._focalOffset), this._focalOffsetVelocity.set(0, 0, 0)), this.dispatchEvent({ type: "controlstart" });
464
464
  }, p = () => {
465
465
  if (!this._enabled || !this._dragNeedsUpdate) return;
466
- this._dragNeedsUpdate = !1, Oe(this._activePointers, D);
466
+ this._dragNeedsUpdate = !1, Ee(this._activePointers, D);
467
467
  const _ = this._domElement && this._domElement.ownerDocument.pointerLockElement === this._domElement ? this._lockedPointer || this._activePointers[0] : null, O = _ ? -_.deltaX : i.x - D.x, C = _ ? -_.deltaY : i.y - D.y;
468
468
  if (i.copy(D), ((this._state & d.ROTATE) === d.ROTATE || (this._state & d.TOUCH_ROTATE) === d.TOUCH_ROTATE || (this._state & d.TOUCH_DOLLY_ROTATE) === d.TOUCH_DOLLY_ROTATE || (this._state & d.TOUCH_ZOOM_ROTATE) === d.TOUCH_ZOOM_ROTATE) && (this._rotateInternal(O, C), this._isUserControllingRotate = !0), (this._state & d.DOLLY) === d.DOLLY || (this._state & d.ZOOM) === d.ZOOM) {
469
469
  const w = this.dollyToCursor ? (s.x - this._elementRect.x) / this._elementRect.width * 2 - 1 : 0, E = this.dollyToCursor ? (s.y - this._elementRect.y) / this._elementRect.height * -2 + 1 : 0, x = this.dollyDragInverted ? -1 : 1;
470
470
  (this._state & d.DOLLY) === d.DOLLY ? (this._dollyInternal(
471
- x * C * ce,
471
+ x * C * de,
472
472
  w,
473
473
  E
474
474
  ), this._isUserControllingDolly = !0) : (this._zoomInternal(
475
- x * C * ce,
475
+ x * C * de,
476
476
  w,
477
477
  E
478
478
  ), this._isUserControllingZoom = !0);
@@ -481,11 +481,11 @@ class J extends Os {
481
481
  const w = D.x - this._activePointers[1].clientX, E = D.y - this._activePointers[1].clientY, x = Math.sqrt(w * w + E * E), R = r.y - x;
482
482
  r.set(0, x);
483
483
  const V = this.dollyToCursor ? (i.x - this._elementRect.x) / this._elementRect.width * 2 - 1 : 0, le = this.dollyToCursor ? (i.y - this._elementRect.y) / this._elementRect.height * -2 + 1 : 0;
484
- (this._state & d.TOUCH_DOLLY) === d.TOUCH_DOLLY || (this._state & d.TOUCH_DOLLY_ROTATE) === d.TOUCH_DOLLY_ROTATE || (this._state & d.TOUCH_DOLLY_TRUCK) === d.TOUCH_DOLLY_TRUCK || (this._state & d.TOUCH_DOLLY_SCREEN_PAN) === d.TOUCH_DOLLY_SCREEN_PAN || (this._state & d.TOUCH_DOLLY_OFFSET) === d.TOUCH_DOLLY_OFFSET ? (this._dollyInternal(R * ce, V, le), this._isUserControllingDolly = !0) : (this._zoomInternal(R * ce, V, le), this._isUserControllingZoom = !0);
484
+ (this._state & d.TOUCH_DOLLY) === d.TOUCH_DOLLY || (this._state & d.TOUCH_DOLLY_ROTATE) === d.TOUCH_DOLLY_ROTATE || (this._state & d.TOUCH_DOLLY_TRUCK) === d.TOUCH_DOLLY_TRUCK || (this._state & d.TOUCH_DOLLY_SCREEN_PAN) === d.TOUCH_DOLLY_SCREEN_PAN || (this._state & d.TOUCH_DOLLY_OFFSET) === d.TOUCH_DOLLY_OFFSET ? (this._dollyInternal(R * de, V, le), this._isUserControllingDolly = !0) : (this._zoomInternal(R * de, V, le), this._isUserControllingZoom = !0);
485
485
  }
486
486
  ((this._state & d.TRUCK) === d.TRUCK || (this._state & d.TOUCH_TRUCK) === d.TOUCH_TRUCK || (this._state & d.TOUCH_DOLLY_TRUCK) === d.TOUCH_DOLLY_TRUCK || (this._state & d.TOUCH_ZOOM_TRUCK) === d.TOUCH_ZOOM_TRUCK) && (this._truckInternal(O, C, !1, !1), this._isUserControllingTruck = !0), ((this._state & d.SCREEN_PAN) === d.SCREEN_PAN || (this._state & d.TOUCH_SCREEN_PAN) === d.TOUCH_SCREEN_PAN || (this._state & d.TOUCH_DOLLY_SCREEN_PAN) === d.TOUCH_DOLLY_SCREEN_PAN || (this._state & d.TOUCH_ZOOM_SCREEN_PAN) === d.TOUCH_ZOOM_SCREEN_PAN) && (this._truckInternal(O, C, !1, !0), this._isUserControllingTruck = !0), ((this._state & d.OFFSET) === d.OFFSET || (this._state & d.TOUCH_OFFSET) === d.TOUCH_OFFSET || (this._state & d.TOUCH_DOLLY_OFFSET) === d.TOUCH_DOLLY_OFFSET || (this._state & d.TOUCH_ZOOM_OFFSET) === d.TOUCH_ZOOM_OFFSET) && (this._truckInternal(O, C, !0, !1), this._isUserControllingOffset = !0), this.dispatchEvent({ type: "control" });
487
- }, f = () => {
488
- Oe(this._activePointers, D), i.copy(D), this._dragNeedsUpdate = !1, (this._activePointers.length === 0 || this._activePointers.length === 1 && this._activePointers[0] === this._lockedPointer) && (this._isDragging = !1), this._activePointers.length === 0 && this._domElement && (this._domElement.ownerDocument.removeEventListener(
487
+ }, u = () => {
488
+ Ee(this._activePointers, D), i.copy(D), this._dragNeedsUpdate = !1, (this._activePointers.length === 0 || this._activePointers.length === 1 && this._activePointers[0] === this._lockedPointer) && (this._isDragging = !1), this._activePointers.length === 0 && this._domElement && (this._domElement.ownerDocument.removeEventListener(
489
489
  "pointermove",
490
490
  n,
491
491
  { passive: !1 }
@@ -536,11 +536,11 @@ class J extends Os {
536
536
  this.unlockPointer();
537
537
  };
538
538
  this._addAllEventListeners = (l) => {
539
- this._domElement = l, this._domElement.style.touchAction = "none", this._domElement.style.userSelect = "none", this._domElement.style.webkitUserSelect = "none", this._domElement.addEventListener("pointerdown", o), this._domElement.addEventListener("pointercancel", a), this._domElement.addEventListener("wheel", u, {
539
+ this._domElement = l, this._domElement.style.touchAction = "none", this._domElement.style.userSelect = "none", this._domElement.style.webkitUserSelect = "none", this._domElement.addEventListener("pointerdown", o), this._domElement.addEventListener("pointercancel", a), this._domElement.addEventListener("wheel", f, {
540
540
  passive: !1
541
541
  }), this._domElement.addEventListener("contextmenu", m);
542
542
  }, this._removeAllEventListeners = () => {
543
- this._domElement && (this._domElement.style.touchAction = "", this._domElement.style.userSelect = "", this._domElement.style.webkitUserSelect = "", this._domElement.removeEventListener("pointerdown", o), this._domElement.removeEventListener("pointercancel", a), this._domElement.removeEventListener("wheel", u, {
543
+ this._domElement && (this._domElement.style.touchAction = "", this._domElement.style.userSelect = "", this._domElement.style.webkitUserSelect = "", this._domElement.removeEventListener("pointerdown", o), this._domElement.removeEventListener("pointercancel", a), this._domElement.removeEventListener("wheel", f, {
544
544
  passive: !1
545
545
  }), this._domElement.removeEventListener("contextmenu", m), this._domElement.ownerDocument.removeEventListener(
546
546
  "pointermove",
@@ -557,7 +557,7 @@ class J extends Os {
557
557
  y
558
558
  ));
559
559
  }, this.cancel = () => {
560
- this._state !== d.NONE && (this._state = d.NONE, this._activePointers.length = 0, f());
560
+ this._state !== d.NONE && (this._state = d.NONE, this._activePointers.length = 0, u());
561
561
  }, t && this.connect(t), this.update(0);
562
562
  }
563
563
  /**
@@ -986,12 +986,12 @@ class J extends Os {
986
986
  c.isEmpty() && (console.warn(
987
987
  "camera-controls: fitTo() cannot be used with an empty box. Aborting"
988
988
  ), Promise.resolve());
989
- const u = Ie(this._sphericalEnd.theta, He), m = Ie(this._sphericalEnd.phi, He);
990
- a.push(this.rotateTo(u, m, t));
991
- const v = b.setFromSpherical(this._sphericalEnd).normalize(), p = Ke.setFromUnitVectors(v, Te), f = P(Math.abs(v.y), 1);
992
- f && p.multiply(be.setFromAxisAngle(de, u)), p.multiply(this._yAxisUpSpaceInverse);
989
+ const f = Ie(this._sphericalEnd.theta, He), m = Ie(this._sphericalEnd.phi, He);
990
+ a.push(this.rotateTo(f, m, t));
991
+ const v = b.setFromSpherical(this._sphericalEnd).normalize(), p = Ke.setFromUnitVectors(v, we), u = P(Math.abs(v.y), 1);
992
+ u && p.multiply(xe.setFromAxisAngle(me, f)), p.multiply(this._yAxisUpSpaceInverse);
993
993
  const g = We.makeEmpty();
994
- L.copy(c.min).applyQuaternion(p), g.expandByPoint(L), L.copy(c.min).setX(c.max.x).applyQuaternion(p), g.expandByPoint(L), L.copy(c.min).setY(c.max.y).applyQuaternion(p), g.expandByPoint(L), L.copy(c.max).setZ(c.min.z).applyQuaternion(p), g.expandByPoint(L), L.copy(c.min).setZ(c.max.z).applyQuaternion(p), g.expandByPoint(L), L.copy(c.max).setY(c.min.y).applyQuaternion(p), g.expandByPoint(L), L.copy(c.max).setX(c.min.x).applyQuaternion(p), g.expandByPoint(L), L.copy(c.max).applyQuaternion(p), g.expandByPoint(L), g.min.x -= i, g.min.y -= o, g.max.x += r, g.max.y += n, p.setFromUnitVectors(Te, v), f && p.premultiply(be.invert()), p.premultiply(this._yAxisUpSpace);
994
+ L.copy(c.min).applyQuaternion(p), g.expandByPoint(L), L.copy(c.min).setX(c.max.x).applyQuaternion(p), g.expandByPoint(L), L.copy(c.min).setY(c.max.y).applyQuaternion(p), g.expandByPoint(L), L.copy(c.max).setZ(c.min.z).applyQuaternion(p), g.expandByPoint(L), L.copy(c.min).setZ(c.max.z).applyQuaternion(p), g.expandByPoint(L), L.copy(c.max).setY(c.min.y).applyQuaternion(p), g.expandByPoint(L), L.copy(c.max).setX(c.min.x).applyQuaternion(p), g.expandByPoint(L), L.copy(c.max).applyQuaternion(p), g.expandByPoint(L), g.min.x -= i, g.min.y -= o, g.max.x += r, g.max.y += n, p.setFromUnitVectors(we, v), u && p.premultiply(xe.invert()), p.premultiply(this._yAxisUpSpace);
995
995
  const y = g.getSize(b), l = g.getCenter(L).applyQuaternion(p);
996
996
  if (Y(this._camera)) {
997
997
  const _ = this.getDistanceToFitBox(
@@ -1018,7 +1018,7 @@ class J extends Os {
1018
1018
  * @category Methods
1019
1019
  */
1020
1020
  fitToSphere(e, t) {
1021
- const s = [], r = "isObject3D" in e ? J.createBoundingSphere(e, we) : we.copy(e);
1021
+ const s = [], r = "isObject3D" in e ? J.createBoundingSphere(e, be) : be.copy(e);
1022
1022
  if (s.push(
1023
1023
  this.moveTo(
1024
1024
  r.center.x,
@@ -1052,7 +1052,7 @@ class J extends Os {
1052
1052
  this._targetEnd.copy(a), this._sphericalEnd.setFromVector3(
1053
1053
  c.sub(a).applyQuaternion(this._yAxisUpSpace)
1054
1054
  ), this.normalizeRotations(), this._needsUpdate = !0, n || (this._target.copy(this._targetEnd), this._spherical.copy(this._sphericalEnd));
1055
- const u = !n || P(this._target.x, this._targetEnd.x, this.restThreshold) && P(this._target.y, this._targetEnd.y, this.restThreshold) && P(this._target.z, this._targetEnd.z, this.restThreshold) && P(
1055
+ const f = !n || P(this._target.x, this._targetEnd.x, this.restThreshold) && P(this._target.y, this._targetEnd.y, this.restThreshold) && P(this._target.z, this._targetEnd.z, this.restThreshold) && P(
1056
1056
  this._spherical.theta,
1057
1057
  this._sphericalEnd.theta,
1058
1058
  this.restThreshold
@@ -1065,7 +1065,7 @@ class J extends Os {
1065
1065
  this._sphericalEnd.radius,
1066
1066
  this.restThreshold
1067
1067
  );
1068
- return this._createOnRestPromise(u);
1068
+ return this._createOnRestPromise(f);
1069
1069
  }
1070
1070
  /**
1071
1071
  * Similar to setLookAt, but it interpolates between two states.
@@ -1085,13 +1085,13 @@ class J extends Os {
1085
1085
  * @param enableTransition
1086
1086
  * @category Methods
1087
1087
  */
1088
- lerpLookAt(e, t, s, i, r, o, n, a, c, u, m, v, p, f = !1) {
1088
+ lerpLookAt(e, t, s, i, r, o, n, a, c, f, m, v, p, u = !1) {
1089
1089
  this._isUserControllingRotate = !1, this._isUserControllingDolly = !1, this._isUserControllingTruck = !1, this._lastDollyDirection = K.NONE, this._changedDolly = 0;
1090
1090
  const g = b.set(i, r, o), y = L.set(e, t, s);
1091
1091
  z.setFromVector3(
1092
1092
  y.sub(g).applyQuaternion(this._yAxisUpSpace)
1093
1093
  );
1094
- const l = G.set(u, m, v), _ = L.set(n, a, c);
1094
+ const l = G.set(f, m, v), _ = L.set(n, a, c);
1095
1095
  ae.setFromVector3(
1096
1096
  _.sub(l).applyQuaternion(this._yAxisUpSpace)
1097
1097
  ), this._targetEnd.copy(g.lerp(l, p));
@@ -1100,8 +1100,8 @@ class J extends Os {
1100
1100
  z.radius + w * p,
1101
1101
  z.phi + C * p,
1102
1102
  z.theta + O * p
1103
- ), this.normalizeRotations(), this._needsUpdate = !0, f || (this._target.copy(this._targetEnd), this._spherical.copy(this._sphericalEnd));
1104
- const E = !f || P(this._target.x, this._targetEnd.x, this.restThreshold) && P(this._target.y, this._targetEnd.y, this.restThreshold) && P(this._target.z, this._targetEnd.z, this.restThreshold) && P(
1103
+ ), this.normalizeRotations(), this._needsUpdate = !0, u || (this._target.copy(this._targetEnd), this._spherical.copy(this._sphericalEnd));
1104
+ const E = !u || P(this._target.x, this._targetEnd.x, this.restThreshold) && P(this._target.y, this._targetEnd.y, this.restThreshold) && P(this._target.z, this._targetEnd.z, this.restThreshold) && P(
1105
1105
  this._spherical.theta,
1106
1106
  this._sphericalEnd.theta,
1107
1107
  this.restThreshold
@@ -1236,7 +1236,7 @@ class J extends Os {
1236
1236
  * @category Methods
1237
1237
  */
1238
1238
  getDistanceToFitBox(e, t, s, i = !1) {
1239
- if (Ee(this._camera, "getDistanceToFitBox"))
1239
+ if (Te(this._camera, "getDistanceToFitBox"))
1240
1240
  return this._spherical.radius;
1241
1241
  const r = e / t, o = this._camera.getEffectiveFOV() * ie, n = this._camera.aspect;
1242
1242
  return ((i ? r > n : r < n) ? t : e / n) * 0.5 / Math.tan(o * 0.5) + s * 0.5;
@@ -1248,7 +1248,7 @@ class J extends Os {
1248
1248
  * @category Methods
1249
1249
  */
1250
1250
  getDistanceToFitSphere(e) {
1251
- if (Ee(this._camera, "getDistanceToFitSphere"))
1251
+ if (Te(this._camera, "getDistanceToFitSphere"))
1252
1252
  return this._spherical.radius;
1253
1253
  const t = this._camera.getEffectiveFOV() * ie, s = Math.atan(Math.tan(t * 0.5) * this._camera.aspect) * 2, i = 1 < this._camera.aspect ? t : s;
1254
1254
  return e / Math.sin(i * 0.5);
@@ -1348,7 +1348,7 @@ class J extends Os {
1348
1348
  * @category Methods
1349
1349
  */
1350
1350
  updateCameraUp() {
1351
- this._yAxisUpSpace.setFromUnitVectors(this._camera.up, de), this._yAxisUpSpaceInverse.copy(this._yAxisUpSpace).invert();
1351
+ this._yAxisUpSpace.setFromUnitVectors(this._camera.up, me), this._yAxisUpSpaceInverse.copy(this._yAxisUpSpace).invert();
1352
1352
  }
1353
1353
  /**
1354
1354
  * Apply current camera-up direction to the camera.
@@ -1377,7 +1377,7 @@ class J extends Os {
1377
1377
  this._thetaVelocity.value = 0, this._spherical.theta = this._sphericalEnd.theta;
1378
1378
  else {
1379
1379
  const m = this._isUserControllingRotate ? this.draggingSmoothTime : this.smoothTime;
1380
- this._spherical.theta = he(
1380
+ this._spherical.theta = ce(
1381
1381
  this._spherical.theta,
1382
1382
  this._sphericalEnd.theta,
1383
1383
  this._thetaVelocity,
@@ -1390,7 +1390,7 @@ class J extends Os {
1390
1390
  this._phiVelocity.value = 0, this._spherical.phi = this._sphericalEnd.phi;
1391
1391
  else {
1392
1392
  const m = this._isUserControllingRotate ? this.draggingSmoothTime : this.smoothTime;
1393
- this._spherical.phi = he(
1393
+ this._spherical.phi = ce(
1394
1394
  this._spherical.phi,
1395
1395
  this._sphericalEnd.phi,
1396
1396
  this._phiVelocity,
@@ -1403,7 +1403,7 @@ class J extends Os {
1403
1403
  this._radiusVelocity.value = 0, this._spherical.radius = this._sphericalEnd.radius;
1404
1404
  else {
1405
1405
  const m = this._isUserControllingDolly ? this.draggingSmoothTime : this.smoothTime;
1406
- this._spherical.radius = he(
1406
+ this._spherical.radius = ce(
1407
1407
  this._spherical.radius,
1408
1408
  this._sphericalEnd.radius,
1409
1409
  this._radiusVelocity,
@@ -1444,7 +1444,7 @@ class J extends Os {
1444
1444
  this._zoomVelocity.value = 0, this._zoom = this._zoomEnd;
1445
1445
  else {
1446
1446
  const m = this._isUserControllingZoom ? this.draggingSmoothTime : this.smoothTime;
1447
- this._zoom = he(
1447
+ this._zoom = ce(
1448
1448
  this._zoom,
1449
1449
  this._zoomEnd,
1450
1450
  this._zoomVelocity,
@@ -1455,10 +1455,10 @@ class J extends Os {
1455
1455
  }
1456
1456
  if (this.dollyToCursor) {
1457
1457
  if (Y(this._camera) && this._changedDolly !== 0) {
1458
- const m = this._spherical.radius - this._lastDistance, v = this._camera, p = this._getCameraDirection(ne), f = b.copy(p).cross(v.up).normalize();
1459
- f.lengthSq() === 0 && (f.x = 1);
1460
- const g = L.crossVectors(f, p), y = this._sphericalEnd.radius * Math.tan(v.getEffectiveFOV() * ie * 0.5), _ = (this._sphericalEnd.radius - m - this._sphericalEnd.radius) / this._sphericalEnd.radius, O = G.copy(this._targetEnd).add(
1461
- f.multiplyScalar(
1458
+ const m = this._spherical.radius - this._lastDistance, v = this._camera, p = this._getCameraDirection(ne), u = b.copy(p).cross(v.up).normalize();
1459
+ u.lengthSq() === 0 && (u.x = 1);
1460
+ const g = L.crossVectors(u, p), y = this._sphericalEnd.radius * Math.tan(v.getEffectiveFOV() * ie * 0.5), _ = (this._sphericalEnd.radius - m - this._sphericalEnd.radius) / this._sphericalEnd.radius, O = G.copy(this._targetEnd).add(
1461
+ u.multiplyScalar(
1462
1462
  this._dollyControlCoord.x * y * v.aspect
1463
1463
  )
1464
1464
  ).add(
@@ -1477,7 +1477,7 @@ class J extends Os {
1477
1477
  this._dollyControlCoord.x,
1478
1478
  this._dollyControlCoord.y,
1479
1479
  (v.near + v.far) / (v.near - v.far)
1480
- ).unproject(v), f = L.set(0, 0, -1).applyQuaternion(v.quaternion), g = G.copy(p).add(f.multiplyScalar(-p.dot(v.up))), l = -(this._zoom - m - this._zoom) / this._zoom, _ = this._getCameraDirection(ne), O = this._targetEnd.dot(_), C = b.copy(this._targetEnd).lerp(g, l), w = C.dot(_), E = _.multiplyScalar(
1480
+ ).unproject(v), u = L.set(0, 0, -1).applyQuaternion(v.quaternion), g = G.copy(p).add(u.multiplyScalar(-p.dot(v.up))), l = -(this._zoom - m - this._zoom) / this._zoom, _ = this._getCameraDirection(ne), O = this._targetEnd.dot(_), C = b.copy(this._targetEnd).lerp(g, l), w = C.dot(_), E = _.multiplyScalar(
1481
1481
  w - O
1482
1482
  );
1483
1483
  C.sub(E), this._boundary.clampPoint(C, C);
@@ -1492,8 +1492,8 @@ class J extends Os {
1492
1492
  b.setFromSpherical(this._spherical).applyQuaternion(this._yAxisUpSpaceInverse),
1493
1493
  1
1494
1494
  );
1495
- const u = this._needsUpdate;
1496
- return u && !this._updatedLastTime ? (this._hasRested = !1, this.dispatchEvent({ type: "wake" }), this.dispatchEvent({ type: "update" })) : u ? (this.dispatchEvent({ type: "update" }), S(t, this.restThreshold) && S(s, this.restThreshold) && S(i, this.restThreshold) && S(r.x, this.restThreshold) && S(r.y, this.restThreshold) && S(r.z, this.restThreshold) && S(o.x, this.restThreshold) && S(o.y, this.restThreshold) && S(o.z, this.restThreshold) && S(n, this.restThreshold) && !this._hasRested && (this._hasRested = !0, this.dispatchEvent({ type: "rest" }))) : !u && this._updatedLastTime && (this._hasRested || (this._hasRested = !0, this.dispatchEvent({ type: "rest" })), this.dispatchEvent({ type: "sleep" })), this._lastDistance = this._spherical.radius, this._lastZoom = this._zoom, this._updatedLastTime = u, this._needsUpdate = !1, u;
1495
+ const f = this._needsUpdate;
1496
+ return f && !this._updatedLastTime ? (this._hasRested = !1, this.dispatchEvent({ type: "wake" }), this.dispatchEvent({ type: "update" })) : f ? (this.dispatchEvent({ type: "update" }), S(t, this.restThreshold) && S(s, this.restThreshold) && S(i, this.restThreshold) && S(r.x, this.restThreshold) && S(r.y, this.restThreshold) && S(r.z, this.restThreshold) && S(o.x, this.restThreshold) && S(o.y, this.restThreshold) && S(o.z, this.restThreshold) && S(n, this.restThreshold) && !this._hasRested && (this._hasRested = !0, this.dispatchEvent({ type: "rest" }))) : !f && this._updatedLastTime && (this._hasRested || (this._hasRested = !0, this.dispatchEvent({ type: "rest" })), this.dispatchEvent({ type: "sleep" })), this._lastDistance = this._spherical.radius, this._lastZoom = this._zoom, this._updatedLastTime = f, this._needsUpdate = !1, f;
1497
1497
  }
1498
1498
  /**
1499
1499
  * Get all state in JSON string
@@ -1615,16 +1615,16 @@ class J extends Os {
1615
1615
  // lateUpdate
1616
1616
  _collisionTest() {
1617
1617
  let e = 1 / 0;
1618
- if (!(this.colliderMeshes.length >= 1) || Ee(this._camera, "_collisionTest"))
1618
+ if (!(this.colliderMeshes.length >= 1) || Te(this._camera, "_collisionTest"))
1619
1619
  return e;
1620
1620
  const s = this._getTargetDirection(ne);
1621
- xe.lookAt(Ve, s, this._camera.up);
1621
+ Le.lookAt(Ve, s, this._camera.up);
1622
1622
  for (let i = 0; i < 4; i++) {
1623
1623
  const r = L.copy(this._nearPlaneCorners[i]);
1624
- r.applyMatrix4(xe);
1624
+ r.applyMatrix4(Le);
1625
1625
  const o = G.addVectors(this._target, r);
1626
- me.set(o, s), me.far = this._spherical.radius + 1;
1627
- const n = me.intersectObjects(this.colliderMeshes);
1626
+ pe.set(o, s), pe.far = this._spherical.radius + 1;
1627
+ const n = pe.intersectObjects(this.colliderMeshes);
1628
1628
  n.length !== 0 && n[0].distance < e && (e = n[0].distance);
1629
1629
  }
1630
1630
  return e;
@@ -1702,18 +1702,18 @@ class J extends Os {
1702
1702
  if (!n.geometry) return;
1703
1703
  const a = n.geometry.clone();
1704
1704
  a.applyMatrix4(n.matrixWorld);
1705
- const u = a.attributes.position;
1706
- for (let m = 0, v = u.count; m < v; m++)
1707
- b.fromBufferAttribute(u, m), r = Math.max(r, i.distanceToSquared(b));
1705
+ const f = a.attributes.position;
1706
+ for (let m = 0, v = f.count; m < v; m++)
1707
+ b.fromBufferAttribute(f, m), r = Math.max(r, i.distanceToSquared(b));
1708
1708
  }), s.radius = Math.sqrt(r), s;
1709
1709
  }
1710
1710
  }
1711
1711
  var Se = { exports: {} }, Q = typeof Reflect == "object" ? Reflect : null, $e = Q && typeof Q.apply == "function" ? Q.apply : function(e, t, s) {
1712
1712
  return Function.prototype.apply.call(e, t, s);
1713
- }, fe;
1714
- Q && typeof Q.ownKeys == "function" ? fe = Q.ownKeys : Object.getOwnPropertySymbols ? fe = function(e) {
1713
+ }, ue;
1714
+ Q && typeof Q.ownKeys == "function" ? ue = Q.ownKeys : Object.getOwnPropertySymbols ? ue = function(e) {
1715
1715
  return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e));
1716
- } : fe = function(e) {
1716
+ } : ue = function(e) {
1717
1717
  return Object.getOwnPropertyNames(e);
1718
1718
  };
1719
1719
  function Ts(h) {
@@ -1781,8 +1781,8 @@ A.prototype.emit = function(e) {
1781
1781
  if (typeof a == "function")
1782
1782
  $e(a, this, t);
1783
1783
  else
1784
- for (var c = a.length, u = Et(a, c), s = 0; s < c; ++s)
1785
- $e(u[s], this, t);
1784
+ for (var c = a.length, f = Et(a, c), s = 0; s < c; ++s)
1785
+ $e(f[s], this, t);
1786
1786
  return !0;
1787
1787
  };
1788
1788
  function yt(h, e, t, s) {
@@ -1890,7 +1890,7 @@ function Ot(h) {
1890
1890
  return 0;
1891
1891
  }
1892
1892
  A.prototype.eventNames = function() {
1893
- return this._eventsCount > 0 ? fe(this._events) : [];
1893
+ return this._eventsCount > 0 ? ue(this._events) : [];
1894
1894
  };
1895
1895
  function Et(h, e) {
1896
1896
  for (var t = new Array(e), s = 0; s < e; ++s)
@@ -1953,11 +1953,11 @@ class Ss {
1953
1953
  antialias: n,
1954
1954
  powerPreference: a,
1955
1955
  toneMappingExposure: c,
1956
- outputColorSpace: u,
1956
+ outputColorSpace: f,
1957
1957
  logarithmicDepthBuffer: m,
1958
1958
  preserveDrawingBuffer: v,
1959
1959
  stencil: p,
1960
- depth: f
1960
+ depth: u
1961
1961
  } = i, g = new Ut({
1962
1962
  alpha: r,
1963
1963
  antialias: n,
@@ -1965,9 +1965,9 @@ class Ss {
1965
1965
  logarithmicDepthBuffer: m,
1966
1966
  preserveDrawingBuffer: v,
1967
1967
  stencil: p,
1968
- depth: f
1968
+ depth: u
1969
1969
  });
1970
- g.setSize(t, s), g.setPixelRatio(o), g.toneMappingExposure = c, g.outputColorSpace = u, this.renderer = g;
1970
+ g.setSize(t, s), g.setPixelRatio(o), g.toneMappingExposure = c, g.outputColorSpace = f, this.renderer = g;
1971
1971
  }
1972
1972
  setSize(e, t) {
1973
1973
  this.renderer.setSize(e, t);
@@ -2401,8 +2401,8 @@ class Bs {
2401
2401
  a.style.overflow = "hidden", this.domElement = a;
2402
2402
  const c = document.createElement("div");
2403
2403
  c.style.transformOrigin = "0 0", c.style.pointerEvents = "none", a.appendChild(c);
2404
- const u = document.createElement("div");
2405
- u.style.transformStyle = "preserve-3d", c.appendChild(u), this.getSize = function() {
2404
+ const f = document.createElement("div");
2405
+ f.style.transformStyle = "preserve-3d", c.appendChild(f), this.getSize = function() {
2406
2406
  return {
2407
2407
  width: s,
2408
2408
  height: i
@@ -2413,9 +2413,9 @@ class Bs {
2413
2413
  let O, C;
2414
2414
  l.isOrthographicCamera && (O = -(l.right + l.left) / 2, C = (l.top + l.bottom) / 2);
2415
2415
  const w = l.view && l.view.enabled ? l.view.height / l.view.fullHeight : 1, E = l.isOrthographicCamera ? `scale( ${w} )scale(` + _ + ")translate(" + m(O) + "px," + m(C) + "px)" + v(l.matrixWorldInverse) : `scale( ${w} )translateZ(` + _ + "px)" + v(l.matrixWorldInverse), R = (l.isPerspectiveCamera ? "perspective(" + _ + "px) " : "") + E + "translate(" + r + "px," + o + "px)";
2416
- n.camera.style !== R && (u.style.transform = R, n.camera.style = R), g(y, y, l);
2416
+ n.camera.style !== R && (f.style.transform = R, n.camera.style = R), g(y, y, l);
2417
2417
  }, this.setSize = function(y, l) {
2418
- s = y, i = l, r = s / 2, o = i / 2, a.style.width = y + "px", a.style.height = l + "px", c.style.width = y + "px", c.style.height = l + "px", u.style.width = y + "px", u.style.height = l + "px";
2418
+ s = y, i = l, r = s / 2, o = i / 2, a.style.width = y + "px", a.style.height = l + "px", c.style.width = y + "px", c.style.height = l + "px", f.style.width = y + "px", f.style.height = l + "px";
2419
2419
  };
2420
2420
  function m(y) {
2421
2421
  return Math.abs(y) < 1e-10 ? 0 : y;
@@ -2428,14 +2428,14 @@ class Bs {
2428
2428
  const l = y.elements;
2429
2429
  return "translate(-50%,-50%)" + ("matrix3d(" + m(l[0]) + "," + m(l[1]) + "," + m(l[2]) + "," + m(l[3]) + "," + m(-l[4]) + "," + m(-l[5]) + "," + m(-l[6]) + "," + m(-l[7]) + "," + m(l[8]) + "," + m(l[9]) + "," + m(l[10]) + "," + m(l[11]) + "," + m(l[12]) + "," + m(l[13]) + "," + m(l[14]) + "," + m(l[15]) + ")");
2430
2430
  }
2431
- function f(y) {
2431
+ function u(y) {
2432
2432
  y.isCSS3DObject && (y.element.style.display = "none");
2433
2433
  for (let l = 0, _ = y.children.length; l < _; l++)
2434
- f(y.children[l]);
2434
+ u(y.children[l]);
2435
2435
  }
2436
2436
  function g(y, l, _, O) {
2437
2437
  if (y.visible === !1) {
2438
- f(y);
2438
+ u(y);
2439
2439
  return;
2440
2440
  }
2441
2441
  if (y.isCSS3DObject) {
@@ -2450,7 +2450,7 @@ class Bs {
2450
2450
  const R = { style: E };
2451
2451
  n.objects.set(y, R);
2452
2452
  }
2453
- w.parentNode !== u && u.appendChild(w), y.onAfterRender(t, l, _);
2453
+ w.parentNode !== f && f.appendChild(w), y.onAfterRender(t, l, _);
2454
2454
  }
2455
2455
  }
2456
2456
  for (let C = 0, w = y.children.length; C < w; C++)
@@ -2476,44 +2476,44 @@ class Vs {
2476
2476
  width: s,
2477
2477
  height: i
2478
2478
  };
2479
- }, this.render = function(f, g) {
2480
- f.matrixWorldAutoUpdate === !0 && f.updateMatrixWorld(), g.parent === null && g.matrixWorldAutoUpdate === !0 && g.updateMatrixWorld(), Qe.copy(g.matrixWorldInverse), Je.multiplyMatrices(g.projectionMatrix, Qe), u(f, f, g), p(f);
2481
- }, this.setSize = function(f, g) {
2482
- s = f, i = g, r = s / 2, o = i / 2, a.style.width = f + "px", a.style.height = g + "px";
2479
+ }, this.render = function(u, g) {
2480
+ u.matrixWorldAutoUpdate === !0 && u.updateMatrixWorld(), g.parent === null && g.matrixWorldAutoUpdate === !0 && g.updateMatrixWorld(), Qe.copy(g.matrixWorldInverse), Je.multiplyMatrices(g.projectionMatrix, Qe), f(u, u, g), p(u);
2481
+ }, this.setSize = function(u, g) {
2482
+ s = u, i = g, r = s / 2, o = i / 2, a.style.width = u + "px", a.style.height = g + "px";
2483
2483
  };
2484
- function c(f) {
2485
- f.isCSS2DObject && (f.element.style.display = "none");
2486
- for (let g = 0, y = f.children.length; g < y; g++)
2487
- c(f.children[g]);
2484
+ function c(u) {
2485
+ u.isCSS2DObject && (u.element.style.display = "none");
2486
+ for (let g = 0, y = u.children.length; g < y; g++)
2487
+ c(u.children[g]);
2488
2488
  }
2489
- function u(f, g, y) {
2490
- if (f.visible === !1) {
2491
- c(f);
2489
+ function f(u, g, y) {
2490
+ if (u.visible === !1) {
2491
+ c(u);
2492
2492
  return;
2493
2493
  }
2494
- if (f.isCSS2DObject) {
2495
- q.setFromMatrixPosition(f.matrixWorld), q.applyMatrix4(Je);
2496
- const l = q.z >= -1 && q.z <= 1 && f.layers.test(y.layers) === !0, _ = f.element;
2497
- _.style.display = l === !0 ? "" : "none", l === !0 && (f.onBeforeRender(t, g, y), _.style.transform = "translate(" + -100 * f.center.x + "%," + -100 * f.center.y + "%)translate(" + (q.x * r + r) + "px," + (-q.y * o + o) + "px)", _.parentNode !== a && a.appendChild(_), f.onAfterRender(t, g, y));
2494
+ if (u.isCSS2DObject) {
2495
+ q.setFromMatrixPosition(u.matrixWorld), q.applyMatrix4(Je);
2496
+ const l = q.z >= -1 && q.z <= 1 && u.layers.test(y.layers) === !0, _ = u.element;
2497
+ _.style.display = l === !0 ? "" : "none", l === !0 && (u.onBeforeRender(t, g, y), _.style.transform = "translate(" + -100 * u.center.x + "%," + -100 * u.center.y + "%)translate(" + (q.x * r + r) + "px," + (-q.y * o + o) + "px)", _.parentNode !== a && a.appendChild(_), u.onAfterRender(t, g, y));
2498
2498
  const O = {
2499
- distanceToCameraSquared: m(y, f)
2499
+ distanceToCameraSquared: m(y, u)
2500
2500
  };
2501
- n.objects.set(f, O);
2501
+ n.objects.set(u, O);
2502
2502
  }
2503
- for (let l = 0, _ = f.children.length; l < _; l++)
2504
- u(f.children[l], g, y);
2503
+ for (let l = 0, _ = u.children.length; l < _; l++)
2504
+ f(u.children[l], g, y);
2505
2505
  }
2506
- function m(f, g) {
2507
- return et.setFromMatrixPosition(f.matrixWorld), tt.setFromMatrixPosition(g.matrixWorld), et.distanceToSquared(tt);
2506
+ function m(u, g) {
2507
+ return et.setFromMatrixPosition(u.matrixWorld), tt.setFromMatrixPosition(g.matrixWorld), et.distanceToSquared(tt);
2508
2508
  }
2509
- function v(f) {
2509
+ function v(u) {
2510
2510
  const g = [];
2511
- return f.traverseVisible(function(y) {
2511
+ return u.traverseVisible(function(y) {
2512
2512
  y.isCSS2DObject && g.push(y);
2513
2513
  }), g;
2514
2514
  }
2515
- function p(f) {
2516
- const g = v(f).sort(function(l, _) {
2515
+ function p(u) {
2516
+ const g = v(u).sort(function(l, _) {
2517
2517
  if (l.renderOrder !== _.renderOrder)
2518
2518
  return _.renderOrder - l.renderOrder;
2519
2519
  const O = n.objects.get(l).distanceToCameraSquared, C = n.objects.get(_).distanceToCameraSquared;
@@ -2642,7 +2642,7 @@ const Zs = {
2642
2642
  }`
2643
2643
  )
2644
2644
  };
2645
- class Ws extends fs {
2645
+ class Ws extends us {
2646
2646
  constructor() {
2647
2647
  super();
2648
2648
  const e = Zs;
@@ -2655,7 +2655,7 @@ class Ws extends fs {
2655
2655
  }
2656
2656
  }
2657
2657
  const Ks = (h) => {
2658
- const e = new us(
2658
+ const e = new fs(
2659
2659
  new Gt({
2660
2660
  uniforms: {
2661
2661
  baseTexture: { value: null },
@@ -2690,7 +2690,7 @@ const Ks = (h) => {
2690
2690
  "baseTexture"
2691
2691
  );
2692
2692
  return e.needsSwap = !0, e;
2693
- }, Le = 1, pe = !1, $s = new Xt({ color: "black" }), Gs = new ct({
2693
+ }, $s = new Xt({ color: "black" }), Gs = new ct({
2694
2694
  color: "black",
2695
2695
  sizeAttenuation: !1
2696
2696
  }), Xs = new ct({
@@ -2702,7 +2702,7 @@ const Ks = (h) => {
2702
2702
  }), Qs = new dt({
2703
2703
  color: "black",
2704
2704
  sizeAttenuation: !1
2705
- }), Js = new ft({
2705
+ }), Js = new ut({
2706
2706
  color: "black",
2707
2707
  sizeAttenuation: 0,
2708
2708
  lineWidth: 0
@@ -2729,23 +2729,23 @@ class ii {
2729
2729
  composerParams: r
2730
2730
  } = e, { renderer: o } = t;
2731
2731
  this.renderer = o;
2732
- const { multisampling: n } = r, { maxSamples: a } = o.capabilities, c = o.getDrawingBufferSize(new B()), u = new Qt(
2732
+ const { multisampling: n } = r, { maxSamples: a } = o.capabilities, c = o.getDrawingBufferSize(new B()), f = new Qt(
2733
2733
  c.width,
2734
2734
  c.height,
2735
2735
  {
2736
2736
  samples: Math.min(n, a),
2737
2737
  type: Jt
2738
2738
  }
2739
- ), m = new ke(o, u), v = this.getSize();
2739
+ ), m = new ke(o, f), v = this.getSize();
2740
2740
  m.setSize(v.width, v.height);
2741
2741
  const p = new ms(
2742
2742
  s.scene,
2743
2743
  i.camera
2744
2744
  );
2745
- m.addPass(p), this.scene = s.scene, this.camera = i.camera, this.finalComposer = m, this.renderPass = p, i.event.on("pageChange", (f) => {
2746
- this.changeCamera(f);
2747
- }), s.event.on("pageChange", (f) => {
2748
- this.changeScene(f);
2745
+ m.addPass(p), this.scene = s.scene, this.camera = i.camera, this.finalComposer = m, this.renderPass = p, i.event.on("pageChange", (u) => {
2746
+ this.changeCamera(u);
2747
+ }), s.event.on("pageChange", (u) => {
2748
+ this.changeScene(u);
2749
2749
  });
2750
2750
  }
2751
2751
  changeCamera(e) {
@@ -2776,7 +2776,7 @@ class ii {
2776
2776
  const a = new ke(t);
2777
2777
  a.renderToScreen = !1, a.addPass(this.renderPass), a.addPass(n), this.bloomComposer = a;
2778
2778
  const c = Ks(a);
2779
- c.uniforms.bloomAlphaType.value = o, this.bloomComposer = a, this.finalComposer.addPass(c), this.mixPass = c, this.bloomLayer.set(Le);
2779
+ c.uniforms.bloomAlphaType.value = o, this.bloomComposer = a, this.finalComposer.addPass(c), this.mixPass = c, this.bloomLayer.set(Oe);
2780
2780
  }
2781
2781
  setBloomSelection(e, t) {
2782
2782
  if (!this.bloomComposer) {
@@ -2785,7 +2785,7 @@ class ii {
2785
2785
  }
2786
2786
  e.traverse((s) => {
2787
2787
  const { object3d: i } = s;
2788
- i && (t ? (this.bloomSelection.add(s), i.layers.enable(Le)) : (this.bloomSelection.delete(s), i.layers.disable(Le)));
2788
+ i && (t ? (this.bloomSelection.add(s), i.layers.enable(Oe)) : (this.bloomSelection.delete(s), i.layers.disable(Oe)));
2789
2789
  }), this.bloomSelection.size === 0 ? this.bloomComposerActive = !1 : this.bloomComposerActive = !0;
2790
2790
  }
2791
2791
  enable() {
@@ -2810,7 +2810,7 @@ class ii {
2810
2810
  s.traverse((i) => {
2811
2811
  var a;
2812
2812
  const r = i, o = i, n = i;
2813
- (a = r.material) != null && a.isShadowMaterial ? e.push(r) : r.material && this.bloomLayer.test(r.layers) === !1 && (this.bloomMaterials[r.uuid] = r.material, o.isSprite ? o.material.sizeAttenuation ? o.material = qs : o.material = Qs : r.material instanceof ft ? r.material = Js : n.isPoints ? n.material.sizeAttenuation ? n.material = Xs : n.material = Gs : r.material = $s);
2813
+ (a = r.material) != null && a.isShadowMaterial ? e.push(r) : r.material && this.bloomLayer.test(r.layers) === !1 && (this.bloomMaterials[r.uuid] = r.material, o.isSprite ? o.material.sizeAttenuation ? o.material = qs : o.material = Qs : r.material instanceof ut ? r.material = Js : n.isPoints ? n.material.sizeAttenuation ? n.material = Xs : n.material = Gs : r.material = $s);
2814
2814
  });
2815
2815
  }), e.forEach((s) => {
2816
2816
  this.bloomVisible[s.uuid] = s.visible, s.visible = !1;
@@ -2863,22 +2863,22 @@ class it extends mt {
2863
2863
  }
2864
2864
  load(e, t, s, i) {
2865
2865
  let r, o;
2866
- this.options.type === "image" ? (o = document.createElement("img"), r = new ue(o)) : this.options.type === "video" ? (o = document.createElement("video"), o.preload = "auto", o.autoplay = !1, o.loop = !1, o.muted = !0, o.setAttribute("webkit-playsinline", "webkit-playsinline"), o.setAttribute("playsinline", ""), r = new pt(o)) : r = new ue();
2866
+ this.options.type === "image" ? (o = document.createElement("img"), r = new fe(o)) : this.options.type === "video" ? (o = document.createElement("video"), o.preload = "auto", o.autoplay = !1, o.loop = !1, o.muted = !0, o.setAttribute("webkit-playsinline", "webkit-playsinline"), o.setAttribute("playsinline", ""), r = new pt(o)) : r = new fe();
2867
2867
  const n = new Ae(this.manager);
2868
2868
  return n.setResponseType("blob"), n.setRequestHeader(this.requestHeader), n.setPath(this.path), n.setWithCredentials(this.withCredentials), n.load(
2869
2869
  e,
2870
2870
  (a) => {
2871
2871
  let c = a;
2872
- const u = e.split(".").pop(), m = this.options.type === "image" ? `image/${u || "png"}` : `video/${u || "mp4"}`;
2872
+ const f = e.split(".").pop(), m = this.options.type === "image" ? `image/${f || "png"}` : `video/${f || "mp4"}`;
2873
2873
  c = c.slice(0, a.size, m);
2874
2874
  const v = () => {
2875
- o.removeEventListener("load", p, !1), o.removeEventListener("error", f, !1);
2875
+ o.removeEventListener("load", p, !1), o.removeEventListener("error", u, !1);
2876
2876
  }, p = () => {
2877
2877
  v(), r.needsUpdate = !0, t && t(r);
2878
- }, f = (y) => {
2878
+ }, u = (y) => {
2879
2879
  v(), i && i(y), this.manager.itemError(e), this.manager.itemEnd(e);
2880
2880
  };
2881
- o.addEventListener("load", p, !1), o.addEventListener("error", f, !1);
2881
+ o.addEventListener("load", p, !1), o.addEventListener("error", u, !1);
2882
2882
  const g = window.URL.createObjectURL(c);
2883
2883
  o.src = g;
2884
2884
  },
@@ -2946,7 +2946,7 @@ class ni {
2946
2946
  const s = this.assets.get(e);
2947
2947
  if (!s) {
2948
2948
  if ((t === "images" || t === "media" || t === "exr") && this.options.simpleTexture4deleted && this.delLoadArr.includes(e))
2949
- return new ue();
2949
+ return new fe();
2950
2950
  console.warn(`Asset ${e} not found`);
2951
2951
  }
2952
2952
  return s;
@@ -2999,7 +2999,7 @@ class ni {
2999
2999
  get textureAssets() {
3000
3000
  const e = /* @__PURE__ */ new Map();
3001
3001
  return this.assets.forEach((t, s) => {
3002
- (t instanceof ue || t instanceof ts || t instanceof pt) && e.set(s, t);
3002
+ (t instanceof fe || t instanceof ts || t instanceof pt) && e.set(s, t);
3003
3003
  }), e;
3004
3004
  }
3005
3005
  loadAll() {
@@ -3027,8 +3027,8 @@ class ni {
3027
3027
  const c = yield o.loadAsync(e);
3028
3028
  if (this.assets.set(e, c), r.resolve(c), s === "images" || s === "media" || s === "exr" || s === "lottie") {
3029
3029
  (t == null ? void 0 : t.colorCorrection) !== !1 && ns({ texture: c });
3030
- const u = (a = t == null ? void 0 : t.anisotropy) != null ? a : this.options.anisotropy;
3031
- c.anisotropy = u;
3030
+ const f = (a = t == null ? void 0 : t.anisotropy) != null ? a : this.options.anisotropy;
3031
+ c.anisotropy = f;
3032
3032
  }
3033
3033
  return c;
3034
3034
  } catch (c) {
@@ -3054,8 +3054,8 @@ class ni {
3054
3054
  a.aoMap
3055
3055
  ].forEach((c) => {
3056
3056
  if (c) {
3057
- const u = this.getSrcByAsset(c, s);
3058
- u && t.add(u);
3057
+ const f = this.getSrcByAsset(c, s);
3058
+ f && t.add(f);
3059
3059
  }
3060
3060
  });
3061
3061
  });
@@ -3123,20 +3123,20 @@ class hi {
3123
3123
  this.activeObjects.clear(), this.objCallbackMap.clear(), this.activeObject = null;
3124
3124
  const a = this.objCallbackMap;
3125
3125
  for (const p of n)
3126
- for (const f of p.objArr) {
3127
- if (!f.object3d || !f.visibleWithAncestors) continue;
3128
- a.has(f) || a.set(f, /* @__PURE__ */ new Map());
3129
- const g = a.get(f);
3126
+ for (const u of p.objArr) {
3127
+ if (!u.object3d || !u.visibleWithAncestors) continue;
3128
+ a.has(u) || a.set(u, /* @__PURE__ */ new Map());
3129
+ const g = a.get(u);
3130
3130
  g.has(p.type) || g.set(p.type, []), g.get(p.type).push(p.cb);
3131
3131
  }
3132
3132
  if (a.size === 0) return;
3133
3133
  const c = [...a.keys()].map((p) => p.object3d);
3134
3134
  console.time(`Pick:listener:${e}:pick`);
3135
- const u = (v = this.pencil.pick(r, c, !0)) == null ? void 0 : v.intersects;
3136
- if (console.timeEnd(`Pick:listener:${e}:pick`), !u || u.length === 0)
3135
+ const f = (v = this.pencil.pick(r, c, !0)) == null ? void 0 : v.intersects;
3136
+ if (console.timeEnd(`Pick:listener:${e}:pick`), !f || f.length === 0)
3137
3137
  e === "down" ? this.handleDownOutside(r) : e === "move" && this.handleLeaveEvents(r);
3138
3138
  else {
3139
- const p = u[0];
3139
+ const p = f[0];
3140
3140
  this.processIntersection(p, r, e);
3141
3141
  }
3142
3142
  const m = this.prevActiveObjects;
@@ -3178,9 +3178,9 @@ class hi {
3178
3178
  sp: o,
3179
3179
  intersectionIndex: s
3180
3180
  });
3181
- const u = a.get("move");
3182
- if (u)
3183
- for (const m of u)
3181
+ const f = a.get("move");
3182
+ if (f)
3183
+ for (const m of f)
3184
3184
  m({
3185
3185
  baseObject: n,
3186
3186
  realBaseObject: this.activeObject,
@@ -3199,14 +3199,14 @@ class hi {
3199
3199
  sp: o,
3200
3200
  intersectionIndex: s
3201
3201
  });
3202
- const u = a.get("click");
3203
- if (u) {
3202
+ const f = a.get("click");
3203
+ if (f) {
3204
3204
  const m = (v) => {
3205
3205
  v.preventDefault();
3206
3206
  const p = 5;
3207
3207
  if (!r && Math.abs(v.clientX - e.clientX) <= p && Math.abs(v.clientY - e.clientY) <= p)
3208
- for (const f of u)
3209
- f({
3208
+ for (const u of f)
3209
+ u({
3210
3210
  baseObject: n,
3211
3211
  realBaseObject: this.activeObject,
3212
3212
  mouseEvent: e,
@@ -3268,8 +3268,8 @@ class hi {
3268
3268
  baseObject: a,
3269
3269
  mouseEvent: m
3270
3270
  }));
3271
- }, u = `pointer${t}`;
3272
- a.element.addEventListener(u, rt(c), !1), o.push({ arr: a, type: u, listener: c });
3271
+ }, f = `pointer${t}`;
3272
+ a.element.addEventListener(f, rt(c), !1), o.push({ arr: a, type: f, listener: c });
3273
3273
  }
3274
3274
  return this.pickNodeFunctionsMap.set(i, o), i;
3275
3275
  }
@@ -3350,18 +3350,18 @@ class ci extends hi {
3350
3350
  const i = this.objectNamesToFactories.get(e);
3351
3351
  if (i) {
3352
3352
  t || (t = {}), t.target === void 0 && (t.target = s);
3353
- const c = t.target, u = (r = t.onTop) != null ? r : 0, m = (o = t.prefab) != null ? o : !1, v = (n = t.create) != null ? n : !0, p = new i().create(t);
3354
- let f;
3355
- return c === null ? f = null : typeof c == "string" ? f = this.objects.get(c) : (a = c == null ? void 0 : c.objectType) != null && a.startsWith("BaseObject") || c ? f = c : m ? f = this.prefabGroup : f = this.group, v === !1 ? p.create = () => {
3353
+ const c = t.target, f = (r = t.onTop) != null ? r : 0, m = (o = t.prefab) != null ? o : !1, v = (n = t.create) != null ? n : !0, p = new i().create(t);
3354
+ let u;
3355
+ return c === null ? u = null : typeof c == "string" ? u = this.objects.get(c) : (a = c == null ? void 0 : c.objectType) != null && a.startsWith("BaseObject") || c ? u = c : m ? u = this.prefabGroup : u = this.group, v === !1 ? p.create = () => {
3356
3356
  } : v !== !0 && (p.create = () => {
3357
3357
  v(p);
3358
3358
  }), p.pencil = this.pencil, p.lead = this, p.mList = this.mList, p.prefab = m, p.objectType = `BaseObject#${e}`, p.objectOptions = t, this.setBaseObjectKey(
3359
3359
  p,
3360
3360
  t.key ? `$t:#${t.key}` : "$t:",
3361
- f == null ? void 0 : f.key
3361
+ u == null ? void 0 : u.key
3362
3362
  ), this.objectsPm.set(
3363
3363
  p,
3364
- this.addBaseObject(p, f, u)
3364
+ this.addBaseObject(p, u, f)
3365
3365
  ), yield this.objectsPm.get(p), this.objectsPm.delete(p), p;
3366
3366
  }
3367
3367
  throw new Error(`Unrecognized:${e}`);
@@ -3576,15 +3576,15 @@ class mi {
3576
3576
  if (o.hasOwnProperty("__isProxy"))
3577
3577
  return o;
3578
3578
  const n = new Proxy(o, {
3579
- set: (a, c, u) => {
3579
+ set: (a, c, f) => {
3580
3580
  if (typeof c == "string" && !isNaN(Number(c))) {
3581
3581
  const m = Number(c);
3582
3582
  if (m >= 0 && m < a.length) {
3583
3583
  const v = a[m];
3584
- return this.rmBaseObjectMap(e, v), a[m] = u, u && this.addBaseObjectMap(e), !0;
3584
+ return this.rmBaseObjectMap(e, v), a[m] = f, f && this.addBaseObjectMap(e), !0;
3585
3585
  }
3586
3586
  }
3587
- return a[c] = u, !0;
3587
+ return a[c] = f, !0;
3588
3588
  }
3589
3589
  });
3590
3590
  return Object.defineProperty(n, "__isProxy", {
@@ -3797,7 +3797,7 @@ const _e = class _e {
3797
3797
  renderer: r,
3798
3798
  controls: o,
3799
3799
  loader: n
3800
- } = this.options, { width: a, height: c } = this.getSize(), u = t ? new Rs({
3800
+ } = this.options, { width: a, height: c } = this.getSize(), f = t ? new Rs({
3801
3801
  width: a,
3802
3802
  height: c,
3803
3803
  renderer: t.WebGPURenderer,
@@ -3813,18 +3813,18 @@ const _e = class _e {
3813
3813
  height: c
3814
3814
  }), v = new ks({}), p = new Ns({
3815
3815
  controlsParams: {
3816
- domElement: (_ = o == null ? void 0 : o.domElement) != null ? _ : u.renderer.domElement
3816
+ domElement: (_ = o == null ? void 0 : o.domElement) != null ? _ : f.renderer.domElement
3817
3817
  }
3818
- }), f = new li({
3818
+ }), u = new li({
3819
3819
  loaderParams: U({
3820
- anisotropy: u.renderer.capabilities.getMaxAnisotropy()
3820
+ anisotropy: f.renderer.capabilities.getMaxAnisotropy()
3821
3821
  }, n)
3822
3822
  }), g = new pi({
3823
3823
  pencil: this
3824
3824
  }), y = new di({
3825
3825
  pencil: this
3826
3826
  });
3827
- this.sceneController = v, this.cameraController = m, this.controlsController = p, this.rendererController = u, this.loaderController = f, this.mListController = g, this.leadController = y;
3827
+ this.sceneController = v, this.cameraController = m, this.controlsController = p, this.rendererController = f, this.loaderController = u, this.mListController = g, this.leadController = y;
3828
3828
  const l = this.addPage({
3829
3829
  sceneOptions: this.options.scene,
3830
3830
  cameraOptions: this.options.camera
@@ -3837,7 +3837,7 @@ const _e = class _e {
3837
3837
  });
3838
3838
  O.add(v.scene), this.helperController = O, i && O.addViewHelper();
3839
3839
  }
3840
- e.appendChild(u.renderer.domElement);
3840
+ e.appendChild(f.renderer.domElement);
3841
3841
  }
3842
3842
  initComposer() {
3843
3843
  const {
@@ -3907,10 +3907,10 @@ const _e = class _e {
3907
3907
  cssRendererController: n,
3908
3908
  leadController: a
3909
3909
  } = this, c = this.renderer.getSize(new B());
3910
- c.x === e && c.y === t || (r.setSize(e, t), i.setSize(e, t), o == null || o.setSize(e, t), n == null || n.setSize(e, t), a.setSize(e, t), this.installPlugins.forEach((u) => {
3910
+ c.x === e && c.y === t || (r.setSize(e, t), i.setSize(e, t), o == null || o.setSize(e, t), n == null || n.setSize(e, t), a.setSize(e, t), this.installPlugins.forEach((f) => {
3911
3911
  var m;
3912
- (m = u.setSize) == null || m.call(u, e, t);
3913
- }), this.viewPadding.some((u) => u !== 0) && this.setViewPadding(...this.viewPadding), this.render(), s && this.event.emit("resize", { width: e, height: t }));
3912
+ (m = f.setSize) == null || m.call(f, e, t);
3913
+ }), this.viewPadding.some((f) => f !== 0) && this.setViewPadding(...this.viewPadding), this.render(), s && this.event.emit("resize", { width: e, height: t }));
3914
3914
  }
3915
3915
  setDevicePixelRatio(e) {
3916
3916
  var n;
@@ -3960,8 +3960,8 @@ const _e = class _e {
3960
3960
  this.timer.update(), Ce.update();
3961
3961
  const e = this.timer.getDelta(), t = this.timer.getElapsed();
3962
3962
  this.controlsController.update(e, t), this.leadController.update(e, t), this.installPlugins.forEach((c) => {
3963
- var u;
3964
- (u = c.update) == null || u.call(c, e, t);
3963
+ var f;
3964
+ (f = c.update) == null || f.call(c, e, t);
3965
3965
  }), (s = this.helperController) == null || s.update(
3966
3966
  e,
3967
3967
  this.controlsController,
@@ -4004,19 +4004,19 @@ const _e = class _e {
4004
4004
  }
4005
4005
  }
4006
4006
  dispose() {
4007
- var e, t, s, i, r, o, n, a, c, u, m, v, p, f;
4007
+ var e, t, s, i, r, o, n, a, c, f, m, v, p, u;
4008
4008
  this.stop(), this.timer.dispose(), Ce.removeAll(), this.event.removeAllListeners(), (e = this.resizeObserver) == null || e.unobserve(this.options.container), this.installPlugins.forEach((g) => {
4009
4009
  var y;
4010
4010
  (y = g.dispose) == null || y.call(g);
4011
- }), (t = this.controlsController) == null || t.dispose(), (s = this.transformController) == null || s.dispose(), (i = this.cssRendererController) == null || i.dispose(), (r = this.sceneController) == null || r.dispose(), (o = this.cameraController) == null || o.dispose(), (n = this.helperController) == null || n.dispose(), (a = this.composerController) == null || a.dispose(), (c = this.rendererController) == null || c.dispose(), (u = this.loaderController) == null || u.dispose(), (m = this.leadController) == null || m.dispose(), (v = this.mListController) == null || v.dispose(), this.cssRendererController = void 0, this.installPlugins.clear(), (p = this.stats) == null || p.dom.remove(), (f = this.renderer) == null || f.domElement.remove();
4011
+ }), (t = this.controlsController) == null || t.dispose(), (s = this.transformController) == null || s.dispose(), (i = this.cssRendererController) == null || i.dispose(), (r = this.sceneController) == null || r.dispose(), (o = this.cameraController) == null || o.dispose(), (n = this.helperController) == null || n.dispose(), (a = this.composerController) == null || a.dispose(), (c = this.rendererController) == null || c.dispose(), (f = this.loaderController) == null || f.dispose(), (m = this.leadController) == null || m.dispose(), (v = this.mListController) == null || v.dispose(), this.cssRendererController = void 0, this.installPlugins.clear(), (p = this.stats) == null || p.dom.remove(), (u = this.renderer) == null || u.domElement.remove();
4012
4012
  }
4013
4013
  };
4014
4014
  _e.options = {
4015
- stats: pe,
4016
- helper: pe,
4017
- viewHelper: pe,
4015
+ stats: he,
4016
+ helper: he,
4017
+ viewHelper: he,
4018
4018
  controls: !0,
4019
- transformControls: pe,
4019
+ transformControls: he,
4020
4020
  renderer: As,
4021
4021
  composer: si,
4022
4022
  scene: zs,