@tomorrowevening/hermes 0.0.72 → 0.0.74

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/hermes.es.js CHANGED
@@ -1,24 +1,24 @@
1
- import { EventDispatcher as pn, Texture as gn, CubeTexture as Hn, RepeatWrapping as qt, WebGLRenderTarget as Yn, Color as $t, FrontSide as Vn, BackSide as vn, DoubleSide as bn, NoBlending as qn, NormalBlending as Kn, AdditiveBlending as Xn, SubtractiveBlending as Zn, MultiplyBlending as Jn, CustomBlending as Qn, AddEquation as ea, SubtractEquation as ta, ReverseSubtractEquation as na, MinEquation as aa, MaxEquation as ia, ZeroFactor as yn, OneFactor as En, SrcColorFactor as xn, OneMinusSrcColorFactor as Sn, SrcAlphaFactor as Cn, OneMinusSrcAlphaFactor as wn, DstAlphaFactor as Mn, OneMinusDstAlphaFactor as On, DstColorFactor as Tn, OneMinusDstColorFactor as Rn, SrcAlphaSaturateFactor as ra, ConstantColorFactor as _n, OneMinusConstantColorFactor as kn, ConstantAlphaFactor as Dn, OneMinusConstantAlphaFactor as Pn, Matrix4 as sa, Vector3 as J, Euler as oa, Line as ca, BufferGeometry as Kt, Float32BufferAttribute as Xt, LineBasicMaterial as la, Mesh as An, MeshBasicMaterial as jn, Ray as ua, Plane as da, MathUtils as ha, MOUSE as nt, TOUCH as at, Quaternion as Zt, Spherical as Jt, Vector2 as me, ShaderMaterial as In, GLSL3 as fa, PlaneGeometry as ma, Scene as pa, Group as ga, AxesHelper as Qt, MeshDepthMaterial as va, MeshNormalMaterial as ba, WebGLRenderer as ya, PerspectiveCamera as At, Raycaster as Ea, OrthographicCamera as en, CameraHelper as xa, SpotLightHelper as Sa, PointLightHelper as Ca, HemisphereLightHelper as wa, DirectionalLightHelper as Ma } from "three";
1
+ import { EventDispatcher as pn, Texture as gn, CubeTexture as Hn, RepeatWrapping as Vt, WebGLRenderTarget as Yn, Color as Ut, FrontSide as Vn, BackSide as vn, DoubleSide as bn, NoBlending as qn, NormalBlending as Kn, AdditiveBlending as Xn, SubtractiveBlending as Zn, MultiplyBlending as Jn, CustomBlending as Qn, AddEquation as ea, SubtractEquation as ta, ReverseSubtractEquation as na, MinEquation as aa, MaxEquation as ia, ZeroFactor as yn, OneFactor as En, SrcColorFactor as xn, OneMinusSrcColorFactor as Sn, SrcAlphaFactor as Cn, OneMinusSrcAlphaFactor as wn, DstAlphaFactor as Mn, OneMinusDstAlphaFactor as On, DstColorFactor as Tn, OneMinusDstColorFactor as Rn, SrcAlphaSaturateFactor as ra, ConstantColorFactor as _n, OneMinusConstantColorFactor as kn, ConstantAlphaFactor as Dn, OneMinusConstantAlphaFactor as Pn, Matrix4 as sa, Vector3 as J, Euler as oa, Line as ca, BufferGeometry as qt, Float32BufferAttribute as Kt, LineBasicMaterial as la, Mesh as An, MeshBasicMaterial as jn, Ray as ua, Plane as da, MathUtils as ha, MOUSE as it, TOUCH as rt, Quaternion as Xt, Spherical as Zt, Vector2 as pe, ShaderMaterial as In, GLSL3 as fa, PlaneGeometry as ma, Scene as pa, Group as ga, AxesHelper as Jt, MeshDepthMaterial as va, MeshNormalMaterial as ba, WebGLRenderer as ya, PerspectiveCamera as Pt, Raycaster as Ea, OrthographicCamera as Qt, CameraHelper as xa, SpotLightHelper as Sa, PointLightHelper as Ca, HemisphereLightHelper as wa, DirectionalLightHelper as Ma } from "three";
2
2
  import { Pane as Oa } from "tweakpane";
3
3
  import * as Ta from "@tweakpane/plugin-essentials";
4
- import Nn, { useState as H, useRef as Y, useEffect as Re, useMemo as se, forwardRef as Ra } from "react";
4
+ import Nn, { useState as W, useRef as V, useEffect as Re, useMemo as se, forwardRef as Ra } from "react";
5
5
  import { Reorder as Ln } from "framer-motion";
6
- const zt = () => {
7
- }, Di = () => {
6
+ const $t = () => {
7
+ }, ki = () => {
8
8
  };
9
- function Ot(e) {
9
+ function Mt(e) {
10
10
  return e.substring(0, 1).toUpperCase() + e.substring(1);
11
11
  }
12
- function Ke(e, n, a) {
12
+ function Je(e, n, a) {
13
13
  return Math.min(n, Math.max(e, a));
14
14
  }
15
- function tn(e, n, a) {
15
+ function en(e, n, a) {
16
16
  return (a - e) / (n - e);
17
17
  }
18
- function nn(e, n, a) {
18
+ function tn(e, n, a) {
19
19
  return e * (1 - a) + n * a;
20
20
  }
21
- function Pi(e, n) {
21
+ function Di(e, n) {
22
22
  const a = e - n;
23
23
  return Math.sqrt(a * a);
24
24
  }
@@ -35,17 +35,17 @@ function Da(e) {
35
35
  }, o = i(n), d = i(a), r = i(t);
36
36
  return "#" + o + d + r;
37
37
  }
38
- function an(e, n = 1) {
38
+ function nn(e, n = 1) {
39
39
  return Number(e.toFixed(n));
40
40
  }
41
- let Lt = 0;
42
- const rn = () => {
43
- Lt = 0;
44
- }, Bt = (e) => {
41
+ let Nt = 0;
42
+ const an = () => {
43
+ Nt = 0;
44
+ }, Lt = (e) => {
45
45
  if (!e)
46
46
  return;
47
47
  let n = e.name.replaceAll(" ", "").replaceAll("/", ".");
48
- if (n.length === 0 && (n = `obj_${Lt}`, Lt++), e.parent !== null && e.parent.uuid.length > 0 && (n = `${e.parent.uuid}.${n}`), e.uuid = n, e.isMesh !== void 0) {
48
+ if (n.length === 0 && (n = `obj_${Nt}`, Nt++), e.parent !== null && e.parent.uuid.length > 0 && (n = `${e.parent.uuid}.${n}`), e.uuid = n, e.isMesh !== void 0) {
49
49
  const a = e;
50
50
  if (Array.isArray(a.material))
51
51
  a.material.forEach((t, i) => {
@@ -56,16 +56,16 @@ const rn = () => {
56
56
  t.uuid = `${n}.material`;
57
57
  }
58
58
  }
59
- e.children.forEach((a) => Bt(a));
60
- }, Ai = (e) => {
59
+ e.children.forEach((a) => Lt(a));
60
+ }, Pi = (e) => {
61
61
  e?.dispose();
62
62
  }, Pa = (e) => {
63
63
  e && (Array.isArray(e) ? e.forEach((n) => n.dispose()) : e.dispose());
64
- }, Tt = (e) => {
64
+ }, Ot = (e) => {
65
65
  if (e) {
66
66
  for (; e.children.length > 0; ) {
67
67
  const n = e.children[0];
68
- n.type === "Audio" ? (n.pause(), n.parent && n.parent.remove(n)) : Tt(n);
68
+ n.type === "Audio" ? (n.pause(), n.parent && n.parent.remove(n)) : Ot(n);
69
69
  }
70
70
  if (e.parent && e.parent.remove(e), e.isMesh) {
71
71
  const n = e;
@@ -74,7 +74,7 @@ const rn = () => {
74
74
  e.dispose !== void 0 && e.dispose();
75
75
  }
76
76
  };
77
- class ji {
77
+ class Ai {
78
78
  components = /* @__PURE__ */ new Map();
79
79
  listen;
80
80
  // Protected
@@ -132,7 +132,7 @@ class ji {
132
132
  n && (this._mode = "editor");
133
133
  }
134
134
  }
135
- const D = new pn(), P = {
135
+ const P = new pn(), A = {
136
136
  CUSTOM: "ToolEvents::custom",
137
137
  // Components
138
138
  SELECT_DROPDOWN: "ToolEvents::selectDropdown",
@@ -150,7 +150,7 @@ const D = new pn(), P = {
150
150
  ADD_CAMERA: "ToolEvents::addCamera",
151
151
  REMOVE_CAMERA: "ToolEvents::removeCamera"
152
152
  };
153
- class Rt {
153
+ class Tt {
154
154
  app;
155
155
  constructor(n) {
156
156
  this.app = n;
@@ -162,7 +162,7 @@ class Rt {
162
162
  handleEditor(n, a, t) {
163
163
  }
164
164
  }
165
- class Ii extends Rt {
165
+ class ji extends Tt {
166
166
  selectDropdown(n, a) {
167
167
  this.app.send({
168
168
  event: "selectComponent",
@@ -186,15 +186,15 @@ class Ii extends Rt {
186
186
  handleApp(n, a, t) {
187
187
  switch (t.event) {
188
188
  case "selectComponent":
189
- D.dispatchEvent({ type: P.SELECT_DROPDOWN, value: t.data });
189
+ P.dispatchEvent({ type: A.SELECT_DROPDOWN, value: t.data });
190
190
  break;
191
191
  case "draggableListUpdate":
192
- D.dispatchEvent({ type: P.DRAG_UPDATE, value: t.data });
192
+ P.dispatchEvent({ type: A.DRAG_UPDATE, value: t.data });
193
193
  break;
194
194
  }
195
195
  }
196
196
  }
197
- class Gt extends Rt {
197
+ class zt extends Tt {
198
198
  project;
199
199
  sheets = /* @__PURE__ */ new Map();
200
200
  sheetObjects = /* @__PURE__ */ new Map();
@@ -254,16 +254,16 @@ class Gt extends Rt {
254
254
  return;
255
255
  const h = `${this.getSheetInstance(n, o)}_${a}`;
256
256
  let u = this.sheetObjects.get(h);
257
- u !== void 0 ? u = d.object(a, { ...t, ...u.value }, { reconfigure: !0 }) : u = d.object(a, t), this.sheetObjects.set(h, u), this.sheetObjectCBs.set(h, i !== void 0 ? i : zt);
257
+ u !== void 0 ? u = d.object(a, { ...t, ...u.value }, { reconfigure: !0 }) : u = d.object(a, t), this.sheetObjects.set(h, u), this.sheetObjectCBs.set(h, i !== void 0 ? i : $t);
258
258
  const f = u.onValuesChange((m) => {
259
259
  if (this.app.editor) {
260
- for (const S in m) {
261
- const A = m[S];
262
- typeof A == "object" && ka(A) && (m[S] = {
263
- r: A.r,
264
- g: A.g,
265
- b: A.b,
266
- a: A.a
260
+ for (const E in m) {
261
+ const D = m[E];
262
+ typeof D == "object" && ka(D) && (m[E] = {
263
+ r: D.r,
264
+ g: D.g,
265
+ b: D.b,
266
+ a: D.a
267
267
  });
268
268
  }
269
269
  this.app.send({
@@ -276,8 +276,8 @@ class Gt extends Rt {
276
276
  }
277
277
  });
278
278
  }
279
- const v = this.sheetObjectCBs.get(h);
280
- v !== void 0 && v(m);
279
+ const b = this.sheetObjectCBs.get(h);
280
+ b !== void 0 && b(m);
281
281
  });
282
282
  return this.sheetObjectUnsubscribe.set(h, f), u;
283
283
  }
@@ -346,7 +346,7 @@ class Gt extends Rt {
346
346
  });
347
347
  let t = -1;
348
348
  const i = () => {
349
- if (Gt.rafDriver?.tick(performance.now()), a.activeSheet !== void 0 && t !== a.activeSheet.sequence.position) {
349
+ if (zt.rafDriver?.tick(performance.now()), a.activeSheet !== void 0 && t !== a.activeSheet.sequence.position) {
350
350
  t = a.activeSheet.sequence.position;
351
351
  const d = a.activeSheet;
352
352
  n.send({
@@ -366,7 +366,7 @@ class Gt extends Rt {
366
366
  this.studio?.ui.hide();
367
367
  }
368
368
  }
369
- function Ni(e, n, a) {
369
+ function Ii(e, n, a) {
370
370
  if (e.editor) {
371
371
  a.ui.restore(), a.onSelectionChange((d) => {
372
372
  d.length < 1 || d.forEach((r) => {
@@ -390,7 +390,7 @@ function Ni(e, n, a) {
390
390
  });
391
391
  let t = -1;
392
392
  const i = () => {
393
- if (Gt.rafDriver?.tick(performance.now()), n.activeSheet !== void 0 && t !== n.activeSheet.sequence.position) {
393
+ if (zt.rafDriver?.tick(performance.now()), n.activeSheet !== void 0 && t !== n.activeSheet.sequence.position) {
394
394
  t = n.activeSheet.sequence.position;
395
395
  const d = n.activeSheet;
396
396
  e.send({
@@ -423,7 +423,7 @@ function Aa(e) {
423
423
  const n = e.type;
424
424
  return n.search("Helper") > -1 ? "icon_utils" : n.search("Camera") > -1 ? "camera" : n.search("Light") > -1 ? "light" : "obj3D";
425
425
  }
426
- function Ct(e) {
426
+ function St(e) {
427
427
  const n = {
428
428
  name: e.name,
429
429
  type: e.type,
@@ -431,7 +431,7 @@ function Ct(e) {
431
431
  children: []
432
432
  };
433
433
  return e.children.forEach((a) => {
434
- n.children.push(Ct(a));
434
+ n.children.push(St(a));
435
435
  }), n;
436
436
  }
437
437
  function ja(e) {
@@ -462,7 +462,7 @@ function Ia(e) {
462
462
  }
463
463
  return !1;
464
464
  }
465
- function it(e) {
465
+ function st(e) {
466
466
  const n = {};
467
467
  for (const a in e) {
468
468
  if (a.substring(0, 1) === "_" || a.substring(0, 2) === "is" || Ia(a))
@@ -503,7 +503,7 @@ function it(e) {
503
503
  }
504
504
  return n;
505
505
  }
506
- function jt(e) {
506
+ function At(e) {
507
507
  e.updateMatrix();
508
508
  const n = {
509
509
  name: e.name,
@@ -531,28 +531,28 @@ function jt(e) {
531
531
  if (Array.isArray(t.material)) {
532
532
  const i = [];
533
533
  t.material.forEach((o) => {
534
- i.push(it(o));
534
+ i.push(st(o));
535
535
  }), n.material = i;
536
536
  } else
537
- n.material = it(t.material);
537
+ n.material = st(t.material);
538
538
  } else if (a.search("points") > -1) {
539
539
  const t = e;
540
540
  if (Array.isArray(t.material)) {
541
541
  const i = [];
542
542
  t.material.forEach((o) => {
543
- i.push(it(o));
543
+ i.push(st(o));
544
544
  }), n.material = i;
545
545
  } else
546
- n.material = it(t.material);
546
+ n.material = st(t.material);
547
547
  } else if (a.search("line") > -1) {
548
548
  const t = e;
549
549
  if (Array.isArray(t.material)) {
550
550
  const i = [];
551
551
  t.material.forEach((o) => {
552
- i.push(it(o));
552
+ i.push(st(o));
553
553
  }), n.material = i;
554
554
  } else
555
- n.material = it(t.material);
555
+ n.material = st(t.material);
556
556
  } else
557
557
  a.search("camera") > -1 ? e.type === "PerspectiveCamera" ? n.perspectiveCameraInfo = {
558
558
  fov: e.fov,
@@ -605,7 +605,7 @@ function La(e, n) {
605
605
  for (const a in n)
606
606
  e[a] = n[a];
607
607
  }
608
- function ee(e, n, a) {
608
+ function te(e, n, a) {
609
609
  if (e === void 0) {
610
610
  console.log(`Hermes - Can't set props: ${n}`, a);
611
611
  return;
@@ -656,19 +656,19 @@ function Bn(e) {
656
656
  const t = new Image();
657
657
  t.onload = () => {
658
658
  const i = new gn(t);
659
- i.wrapS = qt, i.wrapT = qt, i.needsUpdate = !0, n(i);
659
+ i.wrapS = Vt, i.wrapT = Vt, i.needsUpdate = !0, n(i);
660
660
  }, t.onerror = a, t.src = e;
661
661
  });
662
662
  }
663
- class Li extends Rt {
663
+ class Ni extends Tt {
664
664
  scene = void 0;
665
665
  scenes = /* @__PURE__ */ new Map();
666
666
  renderer = void 0;
667
667
  renderTargets = /* @__PURE__ */ new Map();
668
668
  dispose() {
669
669
  this.scenes.forEach((n) => {
670
- Tt(n);
671
- }), this.scenes.clear(), this.scene && Tt(this.scene), this.renderTargets.forEach((n) => {
670
+ Ot(n);
671
+ }), this.scenes.clear(), this.scene && Ot(this.scene), this.renderTargets.forEach((n) => {
672
672
  n.dispose();
673
673
  }), this.renderTargets.clear(), this.renderer?.dispose();
674
674
  }
@@ -680,7 +680,7 @@ class Li extends Rt {
680
680
  });
681
681
  }
682
682
  setObject(n) {
683
- const a = jt(n);
683
+ const a = At(n);
684
684
  this.app.send({
685
685
  event: "setObject",
686
686
  target: "editor",
@@ -724,8 +724,8 @@ class Li extends Rt {
724
724
  addScene(n) {
725
725
  if (n === void 0 || (this.scenes.set(n.name, n), !this.app.debugEnabled))
726
726
  return;
727
- rn(), Bt(n);
728
- const a = Ct(n);
727
+ an(), Lt(n);
728
+ const a = St(n);
729
729
  this.app.send({
730
730
  event: "addScene",
731
731
  target: "editor",
@@ -735,7 +735,7 @@ class Li extends Rt {
735
735
  removeScene(n) {
736
736
  if (n === void 0 || (this.scenes.delete(n.name), !this.app.debugEnabled))
737
737
  return;
738
- const a = Ct(n);
738
+ const a = St(n);
739
739
  this.app.send({
740
740
  event: "removeScene",
741
741
  target: "editor",
@@ -754,8 +754,8 @@ class Li extends Rt {
754
754
  setScene(n) {
755
755
  if (n === void 0 || (this.scene = n, !this.app.debugEnabled))
756
756
  return;
757
- rn(), Bt(n);
758
- const a = Ct(n);
757
+ an(), Lt(n);
758
+ const a = St(n);
759
759
  this.app.send({
760
760
  event: "setScene",
761
761
  target: "editor",
@@ -765,7 +765,7 @@ class Li extends Rt {
765
765
  addCamera(n) {
766
766
  if (!this.app.debugEnabled)
767
767
  return;
768
- const a = jt(n);
768
+ const a = At(n);
769
769
  this.app.send({
770
770
  event: "addCamera",
771
771
  target: "editor",
@@ -775,7 +775,7 @@ class Li extends Rt {
775
775
  removeCamera(n) {
776
776
  if (!this.app.debugEnabled)
777
777
  return;
778
- const a = jt(n);
778
+ const a = At(n);
779
779
  this.app.send({
780
780
  event: "removeCamera",
781
781
  target: "editor",
@@ -785,38 +785,38 @@ class Li extends Rt {
785
785
  handleApp(n, a, t) {
786
786
  switch (t.event) {
787
787
  case "getObject":
788
- D.dispatchEvent({ type: P.GET_OBJECT, value: t.data });
788
+ P.dispatchEvent({ type: A.GET_OBJECT, value: t.data });
789
789
  break;
790
790
  case "updateObject":
791
- D.dispatchEvent({ type: P.UPDATE_OBJECT, value: t.data });
791
+ P.dispatchEvent({ type: A.UPDATE_OBJECT, value: t.data });
792
792
  break;
793
793
  case "createTexture":
794
- D.dispatchEvent({ type: P.CREATE_TEXTURE, value: t.data });
794
+ P.dispatchEvent({ type: A.CREATE_TEXTURE, value: t.data });
795
795
  break;
796
796
  case "requestMethod":
797
- D.dispatchEvent({ type: P.REQUEST_METHOD, value: t.data });
797
+ P.dispatchEvent({ type: A.REQUEST_METHOD, value: t.data });
798
798
  break;
799
799
  }
800
800
  }
801
801
  handleEditor(n, a, t) {
802
802
  switch (t.event) {
803
803
  case "setObject":
804
- D.dispatchEvent({ type: P.SET_OBJECT, value: t.data });
804
+ P.dispatchEvent({ type: A.SET_OBJECT, value: t.data });
805
805
  break;
806
806
  case "addScene":
807
- D.dispatchEvent({ type: P.ADD_SCENE, value: t.data });
807
+ P.dispatchEvent({ type: A.ADD_SCENE, value: t.data });
808
808
  break;
809
809
  case "removeScene":
810
- D.dispatchEvent({ type: P.REMOVE_SCENE, value: t.data });
810
+ P.dispatchEvent({ type: A.REMOVE_SCENE, value: t.data });
811
811
  break;
812
812
  case "setScene":
813
- D.dispatchEvent({ type: P.SET_SCENE, value: t.data });
813
+ P.dispatchEvent({ type: A.SET_SCENE, value: t.data });
814
814
  break;
815
815
  case "addCamera":
816
- D.dispatchEvent({ type: P.ADD_CAMERA, value: t.data });
816
+ P.dispatchEvent({ type: A.ADD_CAMERA, value: t.data });
817
817
  break;
818
818
  case "removeCamera":
819
- D.dispatchEvent({ type: P.REMOVE_CAMERA, value: t.data });
819
+ P.dispatchEvent({ type: A.REMOVE_CAMERA, value: t.data });
820
820
  break;
821
821
  }
822
822
  }
@@ -834,7 +834,7 @@ class Li extends Rt {
834
834
  }), this.renderer?.setSize(n, a);
835
835
  }
836
836
  set dpr(n) {
837
- this.renderer?.setPixelRatio(Ke(1, 2, n));
837
+ this.renderer?.setPixelRatio(Je(1, 2, n));
838
838
  }
839
839
  get dpr() {
840
840
  return this.renderer !== void 0 ? this.renderer?.getPixelRatio() : 1;
@@ -849,7 +849,7 @@ class Li extends Rt {
849
849
  return this.renderer !== void 0 ? this.renderer?.domElement : null;
850
850
  }
851
851
  }
852
- class Bi extends Rt {
852
+ class Li extends Tt {
853
853
  bindCBs;
854
854
  buttonCBs;
855
855
  pane = void 0;
@@ -886,7 +886,7 @@ class Bi extends Rt {
886
886
  }
887
887
  // Binding
888
888
  bind(n, a, t, i = void 0) {
889
- const o = this.bindID, d = t.onChange !== void 0 ? t.onChange : zt;
889
+ const o = this.bindID, d = t.onChange !== void 0 ? t.onChange : $t;
890
890
  this.bindCBs.set(o, d), this.app.editor ? (this.pane === void 0 && this.createGUI(), (i !== void 0 ? i : this.pane).addBinding(n, a, t).on("change", (h) => {
891
891
  this.app.send({
892
892
  event: "updateBind",
@@ -967,7 +967,7 @@ class Bi extends Rt {
967
967
  }
968
968
  }
969
969
  }
970
- var Ft = { exports: {} }, lt = {};
970
+ var Bt = { exports: {} }, dt = {};
971
971
  /**
972
972
  * @license React
973
973
  * react-jsx-runtime.production.min.js
@@ -977,25 +977,25 @@ var Ft = { exports: {} }, lt = {};
977
977
  * This source code is licensed under the MIT license found in the
978
978
  * LICENSE file in the root directory of this source tree.
979
979
  */
980
- var sn;
980
+ var rn;
981
981
  function Ba() {
982
- if (sn)
983
- return lt;
984
- sn = 1;
982
+ if (rn)
983
+ return dt;
984
+ rn = 1;
985
985
  var e = Nn, n = Symbol.for("react.element"), a = Symbol.for("react.fragment"), t = Object.prototype.hasOwnProperty, i = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, o = { key: !0, ref: !0, __self: !0, __source: !0 };
986
986
  function d(r, h, u) {
987
- var f, m = {}, v = null, S = null;
988
- u !== void 0 && (v = "" + u), h.key !== void 0 && (v = "" + h.key), h.ref !== void 0 && (S = h.ref);
987
+ var f, m = {}, b = null, E = null;
988
+ u !== void 0 && (b = "" + u), h.key !== void 0 && (b = "" + h.key), h.ref !== void 0 && (E = h.ref);
989
989
  for (f in h)
990
990
  t.call(h, f) && !o.hasOwnProperty(f) && (m[f] = h[f]);
991
991
  if (r && r.defaultProps)
992
992
  for (f in h = r.defaultProps, h)
993
993
  m[f] === void 0 && (m[f] = h[f]);
994
- return { $$typeof: n, type: r, key: v, ref: S, props: m, _owner: i.current };
994
+ return { $$typeof: n, type: r, key: b, ref: E, props: m, _owner: i.current };
995
995
  }
996
- return lt.Fragment = a, lt.jsx = d, lt.jsxs = d, lt;
996
+ return dt.Fragment = a, dt.jsx = d, dt.jsxs = d, dt;
997
997
  }
998
- var ut = {};
998
+ var ht = {};
999
999
  /**
1000
1000
  * @license React
1001
1001
  * react-jsx-runtime.development.js
@@ -1005,18 +1005,18 @@ var ut = {};
1005
1005
  * This source code is licensed under the MIT license found in the
1006
1006
  * LICENSE file in the root directory of this source tree.
1007
1007
  */
1008
- var on;
1008
+ var sn;
1009
1009
  function Fa() {
1010
- return on || (on = 1, process.env.NODE_ENV !== "production" && function() {
1011
- var e = Nn, n = Symbol.for("react.element"), a = Symbol.for("react.portal"), t = Symbol.for("react.fragment"), i = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), d = Symbol.for("react.provider"), r = Symbol.for("react.context"), h = Symbol.for("react.forward_ref"), u = Symbol.for("react.suspense"), f = Symbol.for("react.suspense_list"), m = Symbol.for("react.memo"), v = Symbol.for("react.lazy"), S = Symbol.for("react.offscreen"), A = Symbol.iterator, F = "@@iterator";
1012
- function V(s) {
1010
+ return sn || (sn = 1, process.env.NODE_ENV !== "production" && function() {
1011
+ var e = Nn, n = Symbol.for("react.element"), a = Symbol.for("react.portal"), t = Symbol.for("react.fragment"), i = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), d = Symbol.for("react.provider"), r = Symbol.for("react.context"), h = Symbol.for("react.forward_ref"), u = Symbol.for("react.suspense"), f = Symbol.for("react.suspense_list"), m = Symbol.for("react.memo"), b = Symbol.for("react.lazy"), E = Symbol.for("react.offscreen"), D = Symbol.iterator, $ = "@@iterator";
1012
+ function z(s) {
1013
1013
  if (s === null || typeof s != "object")
1014
1014
  return null;
1015
- var p = A && s[A] || s[F];
1015
+ var p = D && s[D] || s[$];
1016
1016
  return typeof p == "function" ? p : null;
1017
1017
  }
1018
- var R = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
1019
- function I(s) {
1018
+ var B = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
1019
+ function C(s) {
1020
1020
  {
1021
1021
  for (var p = arguments.length, y = new Array(p > 1 ? p - 1 : 0), w = 1; w < p; w++)
1022
1022
  y[w - 1] = arguments[w];
@@ -1025,37 +1025,37 @@ function Fa() {
1025
1025
  }
1026
1026
  function T(s, p, y) {
1027
1027
  {
1028
- var w = R.ReactDebugCurrentFrame, $ = w.getStackAddendum();
1029
- $ !== "" && (p += "%s", y = y.concat([$]));
1030
- var W = y.map(function(L) {
1031
- return String(L);
1028
+ var w = B.ReactDebugCurrentFrame, U = w.getStackAddendum();
1029
+ U !== "" && (p += "%s", y = y.concat([U]));
1030
+ var H = y.map(function(N) {
1031
+ return String(N);
1032
1032
  });
1033
- W.unshift("Warning: " + p), Function.prototype.apply.call(console[s], console, W);
1033
+ H.unshift("Warning: " + p), Function.prototype.apply.call(console[s], console, H);
1034
1034
  }
1035
1035
  }
1036
- var Z = !1, te = !1, pe = !1, q = !1, ge = !1, ce;
1037
- ce = Symbol.for("react.module.reference");
1036
+ var X = !1, ne = !1, ge = !1, q = !1, ve = !1, le;
1037
+ le = Symbol.for("react.module.reference");
1038
1038
  function _e(s) {
1039
- return !!(typeof s == "string" || typeof s == "function" || s === t || s === o || ge || s === i || s === u || s === f || q || s === S || Z || te || pe || typeof s == "object" && s !== null && (s.$$typeof === v || s.$$typeof === m || s.$$typeof === d || s.$$typeof === r || s.$$typeof === h || // This needs to include all possible module reference object
1039
+ return !!(typeof s == "string" || typeof s == "function" || s === t || s === o || ve || s === i || s === u || s === f || q || s === E || X || ne || ge || typeof s == "object" && s !== null && (s.$$typeof === b || s.$$typeof === m || s.$$typeof === d || s.$$typeof === r || s.$$typeof === h || // This needs to include all possible module reference object
1040
1040
  // types supported by any Flight configuration anywhere since
1041
1041
  // we don't know which Flight build this will end up being used
1042
1042
  // with.
1043
- s.$$typeof === ce || s.getModuleId !== void 0));
1043
+ s.$$typeof === le || s.getModuleId !== void 0));
1044
1044
  }
1045
1045
  function ke(s, p, y) {
1046
1046
  var w = s.displayName;
1047
1047
  if (w)
1048
1048
  return w;
1049
- var $ = p.displayName || p.name || "";
1050
- return $ !== "" ? y + "(" + $ + ")" : y;
1049
+ var U = p.displayName || p.name || "";
1050
+ return U !== "" ? y + "(" + U + ")" : y;
1051
1051
  }
1052
- function be(s) {
1052
+ function ye(s) {
1053
1053
  return s.displayName || "Context";
1054
1054
  }
1055
- function U(s) {
1055
+ function F(s) {
1056
1056
  if (s == null)
1057
1057
  return null;
1058
- if (typeof s.tag == "number" && I("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof s == "function")
1058
+ if (typeof s.tag == "number" && C("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof s == "function")
1059
1059
  return s.displayName || s.name || null;
1060
1060
  if (typeof s == "string")
1061
1061
  return s;
@@ -1077,19 +1077,19 @@ function Fa() {
1077
1077
  switch (s.$$typeof) {
1078
1078
  case r:
1079
1079
  var p = s;
1080
- return be(p) + ".Consumer";
1080
+ return ye(p) + ".Consumer";
1081
1081
  case d:
1082
1082
  var y = s;
1083
- return be(y._context) + ".Provider";
1083
+ return ye(y._context) + ".Provider";
1084
1084
  case h:
1085
1085
  return ke(s, s.render, "ForwardRef");
1086
1086
  case m:
1087
1087
  var w = s.displayName || null;
1088
- return w !== null ? w : U(s.type) || "Memo";
1089
- case v: {
1090
- var $ = s, W = $._payload, L = $._init;
1088
+ return w !== null ? w : F(s.type) || "Memo";
1089
+ case b: {
1090
+ var U = s, H = U._payload, N = U._init;
1091
1091
  try {
1092
- return U(L(W));
1092
+ return F(N(H));
1093
1093
  } catch {
1094
1094
  return null;
1095
1095
  }
@@ -1097,18 +1097,18 @@ function Fa() {
1097
1097
  }
1098
1098
  return null;
1099
1099
  }
1100
- var ye = Object.assign, O = 0, we, De, je, Pe, Ae, Ie, Be;
1101
- function Fe() {
1100
+ var Ee = Object.assign, R = 0, Me, De, Ie, Pe, Ae, je, qe;
1101
+ function Ne() {
1102
1102
  }
1103
- Fe.__reactDisabledLog = !0;
1104
- function re() {
1103
+ Ne.__reactDisabledLog = !0;
1104
+ function Ke() {
1105
1105
  {
1106
- if (O === 0) {
1107
- we = console.log, De = console.info, je = console.warn, Pe = console.error, Ae = console.group, Ie = console.groupCollapsed, Be = console.groupEnd;
1106
+ if (R === 0) {
1107
+ Me = console.log, De = console.info, Ie = console.warn, Pe = console.error, Ae = console.group, je = console.groupCollapsed, qe = console.groupEnd;
1108
1108
  var s = {
1109
1109
  configurable: !0,
1110
1110
  enumerable: !0,
1111
- value: Fe,
1111
+ value: Ne,
1112
1112
  writable: !0
1113
1113
  };
1114
1114
  Object.defineProperties(console, {
@@ -1121,254 +1121,254 @@ function Fa() {
1121
1121
  groupEnd: s
1122
1122
  });
1123
1123
  }
1124
- O++;
1124
+ R++;
1125
1125
  }
1126
1126
  }
1127
- function Me() {
1127
+ function ct() {
1128
1128
  {
1129
- if (O--, O === 0) {
1129
+ if (R--, R === 0) {
1130
1130
  var s = {
1131
1131
  configurable: !0,
1132
1132
  enumerable: !0,
1133
1133
  writable: !0
1134
1134
  };
1135
1135
  Object.defineProperties(console, {
1136
- log: ye({}, s, {
1137
- value: we
1136
+ log: Ee({}, s, {
1137
+ value: Me
1138
1138
  }),
1139
- info: ye({}, s, {
1139
+ info: Ee({}, s, {
1140
1140
  value: De
1141
1141
  }),
1142
- warn: ye({}, s, {
1143
- value: je
1142
+ warn: Ee({}, s, {
1143
+ value: Ie
1144
1144
  }),
1145
- error: ye({}, s, {
1145
+ error: Ee({}, s, {
1146
1146
  value: Pe
1147
1147
  }),
1148
- group: ye({}, s, {
1148
+ group: Ee({}, s, {
1149
1149
  value: Ae
1150
1150
  }),
1151
- groupCollapsed: ye({}, s, {
1152
- value: Ie
1151
+ groupCollapsed: Ee({}, s, {
1152
+ value: je
1153
1153
  }),
1154
- groupEnd: ye({}, s, {
1155
- value: Be
1154
+ groupEnd: Ee({}, s, {
1155
+ value: qe
1156
1156
  })
1157
1157
  });
1158
1158
  }
1159
- O < 0 && I("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
1159
+ R < 0 && C("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
1160
1160
  }
1161
1161
  }
1162
- var He = R.ReactCurrentDispatcher, Ye;
1163
- function ue(s, p, y) {
1162
+ var Le = B.ReactCurrentDispatcher, ae;
1163
+ function fe(s, p, y) {
1164
1164
  {
1165
- if (Ye === void 0)
1165
+ if (ae === void 0)
1166
1166
  try {
1167
1167
  throw Error();
1168
- } catch ($) {
1169
- var w = $.stack.trim().match(/\n( *(at )?)/);
1170
- Ye = w && w[1] || "";
1168
+ } catch (U) {
1169
+ var w = U.stack.trim().match(/\n( *(at )?)/);
1170
+ ae = w && w[1] || "";
1171
1171
  }
1172
1172
  return `
1173
- ` + Ye + s;
1173
+ ` + ae + s;
1174
1174
  }
1175
1175
  }
1176
- var g = !1, b;
1176
+ var Ue = !1, Be;
1177
1177
  {
1178
- var M = typeof WeakMap == "function" ? WeakMap : Map;
1179
- b = new M();
1178
+ var be = typeof WeakMap == "function" ? WeakMap : Map;
1179
+ Be = new be();
1180
1180
  }
1181
- function N(s, p) {
1182
- if (!s || g)
1181
+ function g(s, p) {
1182
+ if (!s || Ue)
1183
1183
  return "";
1184
1184
  {
1185
- var y = b.get(s);
1185
+ var y = Be.get(s);
1186
1186
  if (y !== void 0)
1187
1187
  return y;
1188
1188
  }
1189
1189
  var w;
1190
- g = !0;
1191
- var $ = Error.prepareStackTrace;
1190
+ Ue = !0;
1191
+ var U = Error.prepareStackTrace;
1192
1192
  Error.prepareStackTrace = void 0;
1193
- var W;
1194
- W = He.current, He.current = null, re();
1193
+ var H;
1194
+ H = Le.current, Le.current = null, Ke();
1195
1195
  try {
1196
1196
  if (p) {
1197
- var L = function() {
1197
+ var N = function() {
1198
1198
  throw Error();
1199
1199
  };
1200
- if (Object.defineProperty(L.prototype, "props", {
1200
+ if (Object.defineProperty(N.prototype, "props", {
1201
1201
  set: function() {
1202
1202
  throw Error();
1203
1203
  }
1204
1204
  }), typeof Reflect == "object" && Reflect.construct) {
1205
1205
  try {
1206
- Reflect.construct(L, []);
1207
- } catch (Le) {
1208
- w = Le;
1206
+ Reflect.construct(N, []);
1207
+ } catch (Fe) {
1208
+ w = Fe;
1209
1209
  }
1210
- Reflect.construct(s, [], L);
1210
+ Reflect.construct(s, [], N);
1211
1211
  } else {
1212
1212
  try {
1213
- L.call();
1214
- } catch (Le) {
1215
- w = Le;
1213
+ N.call();
1214
+ } catch (Fe) {
1215
+ w = Fe;
1216
1216
  }
1217
- s.call(L.prototype);
1217
+ s.call(N.prototype);
1218
1218
  }
1219
1219
  } else {
1220
1220
  try {
1221
1221
  throw Error();
1222
- } catch (Le) {
1223
- w = Le;
1222
+ } catch (Fe) {
1223
+ w = Fe;
1224
1224
  }
1225
1225
  s();
1226
1226
  }
1227
- } catch (Le) {
1228
- if (Le && w && typeof Le.stack == "string") {
1229
- for (var j = Le.stack.split(`
1227
+ } catch (Fe) {
1228
+ if (Fe && w && typeof Fe.stack == "string") {
1229
+ for (var I = Fe.stack.split(`
1230
1230
  `), he = w.stack.split(`
1231
- `), Q = j.length - 1, ae = he.length - 1; Q >= 1 && ae >= 0 && j[Q] !== he[ae]; )
1232
- ae--;
1233
- for (; Q >= 1 && ae >= 0; Q--, ae--)
1234
- if (j[Q] !== he[ae]) {
1235
- if (Q !== 1 || ae !== 1)
1231
+ `), ee = I.length - 1, ie = he.length - 1; ee >= 1 && ie >= 0 && I[ee] !== he[ie]; )
1232
+ ie--;
1233
+ for (; ee >= 1 && ie >= 0; ee--, ie--)
1234
+ if (I[ee] !== he[ie]) {
1235
+ if (ee !== 1 || ie !== 1)
1236
1236
  do
1237
- if (Q--, ae--, ae < 0 || j[Q] !== he[ae]) {
1238
- var Ce = `
1239
- ` + j[Q].replace(" at new ", " at ");
1240
- return s.displayName && Ce.includes("<anonymous>") && (Ce = Ce.replace("<anonymous>", s.displayName)), typeof s == "function" && b.set(s, Ce), Ce;
1237
+ if (ee--, ie--, ie < 0 || I[ee] !== he[ie]) {
1238
+ var we = `
1239
+ ` + I[ee].replace(" at new ", " at ");
1240
+ return s.displayName && we.includes("<anonymous>") && (we = we.replace("<anonymous>", s.displayName)), typeof s == "function" && Be.set(s, we), we;
1241
1241
  }
1242
- while (Q >= 1 && ae >= 0);
1242
+ while (ee >= 1 && ie >= 0);
1243
1243
  break;
1244
1244
  }
1245
1245
  }
1246
1246
  } finally {
1247
- g = !1, He.current = W, Me(), Error.prepareStackTrace = $;
1247
+ Ue = !1, Le.current = H, ct(), Error.prepareStackTrace = U;
1248
1248
  }
1249
- var tt = s ? s.displayName || s.name : "", Vt = tt ? ue(tt) : "";
1250
- return typeof s == "function" && b.set(s, Vt), Vt;
1249
+ var at = s ? s.displayName || s.name : "", Yt = at ? fe(at) : "";
1250
+ return typeof s == "function" && Be.set(s, Yt), Yt;
1251
1251
  }
1252
- function ve(s, p, y) {
1253
- return N(s, !1);
1252
+ function v(s, p, y) {
1253
+ return g(s, !1);
1254
1254
  }
1255
- function le(s) {
1255
+ function M(s) {
1256
1256
  var p = s.prototype;
1257
1257
  return !!(p && p.isReactComponent);
1258
1258
  }
1259
- function C(s, p, y) {
1259
+ function j(s, p, y) {
1260
1260
  if (s == null)
1261
1261
  return "";
1262
1262
  if (typeof s == "function")
1263
- return N(s, le(s));
1263
+ return g(s, M(s));
1264
1264
  if (typeof s == "string")
1265
- return ue(s);
1265
+ return fe(s);
1266
1266
  switch (s) {
1267
1267
  case u:
1268
- return ue("Suspense");
1268
+ return fe("Suspense");
1269
1269
  case f:
1270
- return ue("SuspenseList");
1270
+ return fe("SuspenseList");
1271
1271
  }
1272
1272
  if (typeof s == "object")
1273
1273
  switch (s.$$typeof) {
1274
1274
  case h:
1275
- return ve(s.render);
1275
+ return v(s.render);
1276
1276
  case m:
1277
- return C(s.type, p, y);
1278
- case v: {
1279
- var w = s, $ = w._payload, W = w._init;
1277
+ return j(s.type, p, y);
1278
+ case b: {
1279
+ var w = s, U = w._payload, H = w._init;
1280
1280
  try {
1281
- return C(W($), p, y);
1281
+ return j(H(U), p, y);
1282
1282
  } catch {
1283
1283
  }
1284
1284
  }
1285
1285
  }
1286
1286
  return "";
1287
1287
  }
1288
- var x = Object.prototype.hasOwnProperty, G = {}, ne = R.ReactDebugCurrentFrame;
1289
- function _(s) {
1288
+ var oe = Object.prototype.hasOwnProperty, ue = {}, O = B.ReactDebugCurrentFrame;
1289
+ function S(s) {
1290
1290
  if (s) {
1291
- var p = s._owner, y = C(s.type, s._source, p ? p.type : null);
1292
- ne.setExtraStackFrame(y);
1291
+ var p = s._owner, y = j(s.type, s._source, p ? p.type : null);
1292
+ O.setExtraStackFrame(y);
1293
1293
  } else
1294
- ne.setExtraStackFrame(null);
1294
+ O.setExtraStackFrame(null);
1295
1295
  }
1296
- function z(s, p, y, w, $) {
1296
+ function G(s, p, y, w, U) {
1297
1297
  {
1298
- var W = Function.call.bind(x);
1299
- for (var L in s)
1300
- if (W(s, L)) {
1301
- var j = void 0;
1298
+ var H = Function.call.bind(oe);
1299
+ for (var N in s)
1300
+ if (H(s, N)) {
1301
+ var I = void 0;
1302
1302
  try {
1303
- if (typeof s[L] != "function") {
1304
- var he = Error((w || "React class") + ": " + y + " type `" + L + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof s[L] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
1303
+ if (typeof s[N] != "function") {
1304
+ var he = Error((w || "React class") + ": " + y + " type `" + N + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof s[N] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
1305
1305
  throw he.name = "Invariant Violation", he;
1306
1306
  }
1307
- j = s[L](p, L, w, y, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
1308
- } catch (Q) {
1309
- j = Q;
1307
+ I = s[N](p, N, w, y, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
1308
+ } catch (ee) {
1309
+ I = ee;
1310
1310
  }
1311
- j && !(j instanceof Error) && (_($), I("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", w || "React class", y, L, typeof j), _(null)), j instanceof Error && !(j.message in G) && (G[j.message] = !0, _($), I("Failed %s type: %s", y, j.message), _(null));
1311
+ I && !(I instanceof Error) && (S(U), C("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", w || "React class", y, N, typeof I), S(null)), I instanceof Error && !(I.message in ue) && (ue[I.message] = !0, S(U), C("Failed %s type: %s", y, I.message), S(null));
1312
1312
  }
1313
1313
  }
1314
1314
  }
1315
- var K = Array.isArray;
1316
- function Ne(s) {
1317
- return K(s);
1315
+ var Z = Array.isArray;
1316
+ function _(s) {
1317
+ return Z(s);
1318
1318
  }
1319
- function Je(s) {
1319
+ function Y(s) {
1320
1320
  {
1321
1321
  var p = typeof Symbol == "function" && Symbol.toStringTag, y = p && s[Symbol.toStringTag] || s.constructor.name || "Object";
1322
1322
  return y;
1323
1323
  }
1324
1324
  }
1325
- function ft(s) {
1325
+ function Q(s) {
1326
1326
  try {
1327
- return mt(s), !1;
1327
+ return $e(s), !1;
1328
1328
  } catch {
1329
1329
  return !0;
1330
1330
  }
1331
1331
  }
1332
- function mt(s) {
1332
+ function $e(s) {
1333
1333
  return "" + s;
1334
1334
  }
1335
- function st(s) {
1336
- if (ft(s))
1337
- return I("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Je(s)), mt(s);
1335
+ function ze(s) {
1336
+ if (Q(s))
1337
+ return C("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Y(s)), $e(s);
1338
1338
  }
1339
- var Ue = R.ReactCurrentOwner, ot = {
1339
+ var Ge = B.ReactCurrentOwner, lt = {
1340
1340
  key: !0,
1341
1341
  ref: !0,
1342
1342
  __self: !0,
1343
1343
  __source: !0
1344
- }, ct, pt, Qe;
1345
- Qe = {};
1346
- function kt(s) {
1347
- if (x.call(s, "ref")) {
1344
+ }, ut, pt, tt;
1345
+ tt = {};
1346
+ function _t(s) {
1347
+ if (oe.call(s, "ref")) {
1348
1348
  var p = Object.getOwnPropertyDescriptor(s, "ref").get;
1349
1349
  if (p && p.isReactWarning)
1350
1350
  return !1;
1351
1351
  }
1352
1352
  return s.ref !== void 0;
1353
1353
  }
1354
- function Dt(s) {
1355
- if (x.call(s, "key")) {
1354
+ function kt(s) {
1355
+ if (oe.call(s, "key")) {
1356
1356
  var p = Object.getOwnPropertyDescriptor(s, "key").get;
1357
1357
  if (p && p.isReactWarning)
1358
1358
  return !1;
1359
1359
  }
1360
1360
  return s.key !== void 0;
1361
1361
  }
1362
- function Pt(s, p) {
1363
- if (typeof s.ref == "string" && Ue.current && p && Ue.current.stateNode !== p) {
1364
- var y = U(Ue.current.type);
1365
- Qe[y] || (I('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', U(Ue.current.type), s.ref), Qe[y] = !0);
1362
+ function Dt(s, p) {
1363
+ if (typeof s.ref == "string" && Ge.current && p && Ge.current.stateNode !== p) {
1364
+ var y = F(Ge.current.type);
1365
+ tt[y] || (C('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', F(Ge.current.type), s.ref), tt[y] = !0);
1366
1366
  }
1367
1367
  }
1368
1368
  function gt(s, p) {
1369
1369
  {
1370
1370
  var y = function() {
1371
- ct || (ct = !0, I("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", p));
1371
+ ut || (ut = !0, C("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", p));
1372
1372
  };
1373
1373
  y.isReactWarning = !0, Object.defineProperty(s, "key", {
1374
1374
  get: y,
@@ -1376,10 +1376,10 @@ function Fa() {
1376
1376
  });
1377
1377
  }
1378
1378
  }
1379
- function $e(s, p) {
1379
+ function We(s, p) {
1380
1380
  {
1381
1381
  var y = function() {
1382
- pt || (pt = !0, I("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", p));
1382
+ pt || (pt = !0, C("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", p));
1383
1383
  };
1384
1384
  y.isReactWarning = !0, Object.defineProperty(s, "ref", {
1385
1385
  get: y,
@@ -1387,70 +1387,70 @@ function Fa() {
1387
1387
  });
1388
1388
  }
1389
1389
  }
1390
- var Ht = function(s, p, y, w, $, W, L) {
1391
- var j = {
1390
+ var Wt = function(s, p, y, w, U, H, N) {
1391
+ var I = {
1392
1392
  // This tag allows us to uniquely identify this as a React Element
1393
1393
  $$typeof: n,
1394
1394
  // Built-in properties that belong on the element
1395
1395
  type: s,
1396
1396
  key: p,
1397
1397
  ref: y,
1398
- props: L,
1398
+ props: N,
1399
1399
  // Record the component responsible for creating this element.
1400
- _owner: W
1400
+ _owner: H
1401
1401
  };
1402
- return j._store = {}, Object.defineProperty(j._store, "validated", {
1402
+ return I._store = {}, Object.defineProperty(I._store, "validated", {
1403
1403
  configurable: !1,
1404
1404
  enumerable: !1,
1405
1405
  writable: !0,
1406
1406
  value: !1
1407
- }), Object.defineProperty(j, "_self", {
1407
+ }), Object.defineProperty(I, "_self", {
1408
1408
  configurable: !1,
1409
1409
  enumerable: !1,
1410
1410
  writable: !1,
1411
1411
  value: w
1412
- }), Object.defineProperty(j, "_source", {
1412
+ }), Object.defineProperty(I, "_source", {
1413
1413
  configurable: !1,
1414
1414
  enumerable: !1,
1415
1415
  writable: !1,
1416
- value: $
1417
- }), Object.freeze && (Object.freeze(j.props), Object.freeze(j)), j;
1416
+ value: U
1417
+ }), Object.freeze && (Object.freeze(I.props), Object.freeze(I)), I;
1418
1418
  };
1419
- function c(s, p, y, w, $) {
1419
+ function c(s, p, y, w, U) {
1420
1420
  {
1421
- var W, L = {}, j = null, he = null;
1422
- y !== void 0 && (st(y), j = "" + y), Dt(p) && (st(p.key), j = "" + p.key), kt(p) && (he = p.ref, Pt(p, $));
1423
- for (W in p)
1424
- x.call(p, W) && !ot.hasOwnProperty(W) && (L[W] = p[W]);
1421
+ var H, N = {}, I = null, he = null;
1422
+ y !== void 0 && (ze(y), I = "" + y), kt(p) && (ze(p.key), I = "" + p.key), _t(p) && (he = p.ref, Dt(p, U));
1423
+ for (H in p)
1424
+ oe.call(p, H) && !lt.hasOwnProperty(H) && (N[H] = p[H]);
1425
1425
  if (s && s.defaultProps) {
1426
- var Q = s.defaultProps;
1427
- for (W in Q)
1428
- L[W] === void 0 && (L[W] = Q[W]);
1426
+ var ee = s.defaultProps;
1427
+ for (H in ee)
1428
+ N[H] === void 0 && (N[H] = ee[H]);
1429
1429
  }
1430
- if (j || he) {
1431
- var ae = typeof s == "function" ? s.displayName || s.name || "Unknown" : s;
1432
- j && gt(L, ae), he && $e(L, ae);
1430
+ if (I || he) {
1431
+ var ie = typeof s == "function" ? s.displayName || s.name || "Unknown" : s;
1432
+ I && gt(N, ie), he && We(N, ie);
1433
1433
  }
1434
- return Ht(s, j, he, $, w, Ue.current, L);
1434
+ return Wt(s, I, he, U, w, Ge.current, N);
1435
1435
  }
1436
1436
  }
1437
- var E = R.ReactCurrentOwner, k = R.ReactDebugCurrentFrame;
1438
- function B(s) {
1437
+ var x = B.ReactCurrentOwner, k = B.ReactDebugCurrentFrame;
1438
+ function L(s) {
1439
1439
  if (s) {
1440
- var p = s._owner, y = C(s.type, s._source, p ? p.type : null);
1440
+ var p = s._owner, y = j(s.type, s._source, p ? p.type : null);
1441
1441
  k.setExtraStackFrame(y);
1442
1442
  } else
1443
1443
  k.setExtraStackFrame(null);
1444
1444
  }
1445
- var ie;
1446
- ie = !1;
1447
- function Ee(s) {
1445
+ var re;
1446
+ re = !1;
1447
+ function xe(s) {
1448
1448
  return typeof s == "object" && s !== null && s.$$typeof === n;
1449
1449
  }
1450
1450
  function de() {
1451
1451
  {
1452
- if (E.current) {
1453
- var s = U(E.current.type);
1452
+ if (x.current) {
1453
+ var s = F(x.current.type);
1454
1454
  if (s)
1455
1455
  return `
1456
1456
 
@@ -1459,7 +1459,7 @@ Check the render method of \`` + s + "`.";
1459
1459
  return "";
1460
1460
  }
1461
1461
  }
1462
- function Yt(s) {
1462
+ function Ht(s) {
1463
1463
  {
1464
1464
  if (s !== void 0) {
1465
1465
  var p = s.fileName.replace(/^.*[\\\/]/, ""), y = s.lineNumber;
@@ -1483,7 +1483,7 @@ Check the top-level render call using <` + y + ">.");
1483
1483
  return p;
1484
1484
  }
1485
1485
  }
1486
- function xe(s, p) {
1486
+ function Se(s, p) {
1487
1487
  {
1488
1488
  if (!s._store || s._store.validated || s.key != null)
1489
1489
  return;
@@ -1493,29 +1493,29 @@ Check the top-level render call using <` + y + ">.");
1493
1493
  return;
1494
1494
  vt[y] = !0;
1495
1495
  var w = "";
1496
- s && s._owner && s._owner !== E.current && (w = " It was passed a child from " + U(s._owner.type) + "."), B(s), I('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', y, w), B(null);
1496
+ s && s._owner && s._owner !== x.current && (w = " It was passed a child from " + F(s._owner.type) + "."), L(s), C('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', y, w), L(null);
1497
1497
  }
1498
1498
  }
1499
- function Se(s, p) {
1499
+ function Ce(s, p) {
1500
1500
  {
1501
1501
  if (typeof s != "object")
1502
1502
  return;
1503
- if (Ne(s))
1503
+ if (_(s))
1504
1504
  for (var y = 0; y < s.length; y++) {
1505
1505
  var w = s[y];
1506
- Ee(w) && xe(w, p);
1506
+ xe(w) && Se(w, p);
1507
1507
  }
1508
- else if (Ee(s))
1508
+ else if (xe(s))
1509
1509
  s._store && (s._store.validated = !0);
1510
1510
  else if (s) {
1511
- var $ = V(s);
1512
- if (typeof $ == "function" && $ !== s.entries)
1513
- for (var W = $.call(s), L; !(L = W.next()).done; )
1514
- Ee(L.value) && xe(L.value, p);
1511
+ var U = z(s);
1512
+ if (typeof U == "function" && U !== s.entries)
1513
+ for (var H = U.call(s), N; !(N = H.next()).done; )
1514
+ xe(N.value) && Se(N.value, p);
1515
1515
  }
1516
1516
  }
1517
1517
  }
1518
- function Ve(s) {
1518
+ function Xe(s) {
1519
1519
  {
1520
1520
  var p = s.type;
1521
1521
  if (p == null || typeof p == "string")
@@ -1530,14 +1530,14 @@ Check the top-level render call using <` + y + ">.");
1530
1530
  else
1531
1531
  return;
1532
1532
  if (y) {
1533
- var w = U(p);
1534
- z(y, s.props, "prop", w, s);
1535
- } else if (p.PropTypes !== void 0 && !ie) {
1536
- ie = !0;
1537
- var $ = U(p);
1538
- I("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", $ || "Unknown");
1533
+ var w = F(p);
1534
+ G(y, s.props, "prop", w, s);
1535
+ } else if (p.PropTypes !== void 0 && !re) {
1536
+ re = !0;
1537
+ var U = F(p);
1538
+ C("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", U || "Unknown");
1539
1539
  }
1540
- typeof p.getDefaultProps == "function" && !p.getDefaultProps.isReactClassApproved && I("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
1540
+ typeof p.getDefaultProps == "function" && !p.getDefaultProps.isReactClassApproved && C("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
1541
1541
  }
1542
1542
  }
1543
1543
  function Oe(s) {
@@ -1545,55 +1545,55 @@ Check the top-level render call using <` + y + ">.");
1545
1545
  for (var p = Object.keys(s.props), y = 0; y < p.length; y++) {
1546
1546
  var w = p[y];
1547
1547
  if (w !== "children" && w !== "key") {
1548
- B(s), I("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", w), B(null);
1548
+ L(s), C("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", w), L(null);
1549
1549
  break;
1550
1550
  }
1551
1551
  }
1552
- s.ref !== null && (B(s), I("Invalid attribute `ref` supplied to `React.Fragment`."), B(null));
1552
+ s.ref !== null && (L(s), C("Invalid attribute `ref` supplied to `React.Fragment`."), L(null));
1553
1553
  }
1554
1554
  }
1555
- function ze(s, p, y, w, $, W) {
1555
+ function He(s, p, y, w, U, H) {
1556
1556
  {
1557
- var L = _e(s);
1558
- if (!L) {
1559
- var j = "";
1560
- (s === void 0 || typeof s == "object" && s !== null && Object.keys(s).length === 0) && (j += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
1561
- var he = Yt($);
1562
- he ? j += he : j += de();
1563
- var Q;
1564
- s === null ? Q = "null" : Ne(s) ? Q = "array" : s !== void 0 && s.$$typeof === n ? (Q = "<" + (U(s.type) || "Unknown") + " />", j = " Did you accidentally export a JSX literal instead of a component?") : Q = typeof s, I("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", Q, j);
1557
+ var N = _e(s);
1558
+ if (!N) {
1559
+ var I = "";
1560
+ (s === void 0 || typeof s == "object" && s !== null && Object.keys(s).length === 0) && (I += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
1561
+ var he = Ht(U);
1562
+ he ? I += he : I += de();
1563
+ var ee;
1564
+ s === null ? ee = "null" : _(s) ? ee = "array" : s !== void 0 && s.$$typeof === n ? (ee = "<" + (F(s.type) || "Unknown") + " />", I = " Did you accidentally export a JSX literal instead of a component?") : ee = typeof s, C("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", ee, I);
1565
1565
  }
1566
- var ae = c(s, p, y, $, W);
1567
- if (ae == null)
1568
- return ae;
1569
- if (L) {
1570
- var Ce = p.children;
1571
- if (Ce !== void 0)
1566
+ var ie = c(s, p, y, U, H);
1567
+ if (ie == null)
1568
+ return ie;
1569
+ if (N) {
1570
+ var we = p.children;
1571
+ if (we !== void 0)
1572
1572
  if (w)
1573
- if (Ne(Ce)) {
1574
- for (var tt = 0; tt < Ce.length; tt++)
1575
- Se(Ce[tt], s);
1576
- Object.freeze && Object.freeze(Ce);
1573
+ if (_(we)) {
1574
+ for (var at = 0; at < we.length; at++)
1575
+ Ce(we[at], s);
1576
+ Object.freeze && Object.freeze(we);
1577
1577
  } else
1578
- I("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
1578
+ C("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
1579
1579
  else
1580
- Se(Ce, s);
1580
+ Ce(we, s);
1581
1581
  }
1582
- return s === t ? Oe(ae) : Ve(ae), ae;
1582
+ return s === t ? Oe(ie) : Xe(ie), ie;
1583
1583
  }
1584
1584
  }
1585
- function et(s, p, y) {
1586
- return ze(s, p, y, !0);
1585
+ function nt(s, p, y) {
1586
+ return He(s, p, y, !0);
1587
1587
  }
1588
1588
  function yt(s, p, y) {
1589
- return ze(s, p, y, !1);
1589
+ return He(s, p, y, !1);
1590
1590
  }
1591
- var Gn = yt, Wn = et;
1592
- ut.Fragment = t, ut.jsx = Gn, ut.jsxs = Wn;
1593
- }()), ut;
1591
+ var Gn = yt, Wn = nt;
1592
+ ht.Fragment = t, ht.jsx = Gn, ht.jsxs = Wn;
1593
+ }()), ht;
1594
1594
  }
1595
- process.env.NODE_ENV === "production" ? Ft.exports = Ba() : Ft.exports = Fa();
1596
- var l = Ft.exports;
1595
+ process.env.NODE_ENV === "production" ? Bt.exports = Ba() : Bt.exports = Fa();
1596
+ var l = Bt.exports;
1597
1597
  function Fn(e) {
1598
1598
  return e.title.search("<") > -1 ? /* @__PURE__ */ l.jsx("button", { className: "svg", dangerouslySetInnerHTML: { __html: e.title } }) : /* @__PURE__ */ l.jsx("button", { children: e.title });
1599
1599
  }
@@ -1619,7 +1619,7 @@ function za(e) {
1619
1619
  ] }) }, e.title);
1620
1620
  }
1621
1621
  function Ga(e) {
1622
- const [n, a] = H(!1), [t, i] = H(e.options), o = (u) => {
1622
+ const [n, a] = W(!1), [t, i] = W(e.options), o = (u) => {
1623
1623
  e.onDragComplete(u), i(u);
1624
1624
  }, d = (u) => {
1625
1625
  const f = [...t];
@@ -1635,7 +1635,7 @@ function Ga(e) {
1635
1635
  ] });
1636
1636
  }
1637
1637
  function Wa(e) {
1638
- const [n, a] = H(!1), t = [];
1638
+ const [n, a] = W(!1), t = [];
1639
1639
  e.options.map((o, d) => {
1640
1640
  e.onSelect !== void 0 && (o.onSelect = e.onSelect), t.push(/* @__PURE__ */ l.jsx(Ha, { option: o }, d));
1641
1641
  });
@@ -1660,7 +1660,7 @@ function Wa(e) {
1660
1660
  );
1661
1661
  }
1662
1662
  function Ha(e) {
1663
- const { option: n } = e, [a, t] = H("");
1663
+ const { option: n } = e, [a, t] = W("");
1664
1664
  let i;
1665
1665
  switch (n.type) {
1666
1666
  case "draggable":
@@ -1701,13 +1701,13 @@ function Ha(e) {
1701
1701
  }
1702
1702
  return /* @__PURE__ */ l.jsx("li", { className: a === n.title ? "selected" : "", children: i }, _a());
1703
1703
  }
1704
- function Fi(e, n, a) {
1704
+ function Bi(e, n, a) {
1705
1705
  function t(o) {
1706
1706
  switch (n.forEach((d) => {
1707
1707
  d.callback(e, d.remote, o);
1708
1708
  }), o.event) {
1709
1709
  case "custom":
1710
- D.dispatchEvent({ type: P.CUSTOM, value: o.data });
1710
+ P.dispatchEvent({ type: A.CUSTOM, value: o.data });
1711
1711
  break;
1712
1712
  }
1713
1713
  }
@@ -1716,7 +1716,7 @@ function Fi(e, n, a) {
1716
1716
  d.callback(e, d.remote, o);
1717
1717
  }), o.event) {
1718
1718
  case "custom":
1719
- D.dispatchEvent({ type: P.CUSTOM, value: o.data });
1719
+ P.dispatchEvent({ type: A.CUSTOM, value: o.data });
1720
1720
  break;
1721
1721
  }
1722
1722
  }
@@ -1724,8 +1724,8 @@ function Fi(e, n, a) {
1724
1724
  o.target === "editor" ? i(o) : t(o);
1725
1725
  };
1726
1726
  }
1727
- function Wt(e) {
1728
- const [n, a] = H(e.open !== void 0 ? e.open : !0), t = !n || e.children === void 0;
1727
+ function Gt(e) {
1728
+ const [n, a] = W(e.open !== void 0 ? e.open : !0), t = !n || e.children === void 0;
1729
1729
  return /* @__PURE__ */ l.jsxs("div", { className: `accordion ${t ? "hide" : ""}`, children: [
1730
1730
  /* @__PURE__ */ l.jsxs(
1731
1731
  "button",
@@ -1743,7 +1743,7 @@ function Wt(e) {
1743
1743
  children: "Toggle"
1744
1744
  }
1745
1745
  ),
1746
- /* @__PURE__ */ l.jsx("p", { className: "label", children: Ot(e.label) })
1746
+ /* @__PURE__ */ l.jsx("p", { className: "label", children: Mt(e.label) })
1747
1747
  ]
1748
1748
  }
1749
1749
  ),
@@ -1752,7 +1752,7 @@ function Wt(e) {
1752
1752
  ] });
1753
1753
  }
1754
1754
  function Un(e) {
1755
- const n = Y(null), [a, t] = H(!1), i = e.child !== void 0 && e.child.children.length > 0, o = [];
1755
+ const n = V(null), [a, t] = W(!1), i = e.child !== void 0 && e.child.children.length > 0, o = [];
1756
1756
  return e.child !== void 0 && e.child.children.length > 0 && e.child.children.map((d, r) => {
1757
1757
  o.push(/* @__PURE__ */ l.jsx(Un, { child: d, three: e.three }, r));
1758
1758
  }), Re(() => {
@@ -1800,7 +1800,7 @@ function Un(e) {
1800
1800
  const r = d.getObjectByProperty("uuid", e.child.uuid);
1801
1801
  if (r !== void 0) {
1802
1802
  const h = "visible", u = !r.visible;
1803
- n.current.style.opacity = u ? "1" : "0.25", e.three.updateObject(e.child.uuid, h, u), ee(r, h, u);
1803
+ n.current.style.opacity = u ? "1" : "0.25", e.three.updateObject(e.child.uuid, h, u), te(r, h, u);
1804
1804
  } else
1805
1805
  console.log(`Hermes - Couldn't find object: ${e.child.uuid}`, d);
1806
1806
  } else
@@ -1821,32 +1821,32 @@ function Ya(e) {
1821
1821
  }), /* @__PURE__ */ l.jsx("div", { className: `scene ${e.class !== void 0 ? e.class : ""}`, children: n });
1822
1822
  }
1823
1823
  function Va(e) {
1824
- const [n, a] = H(e.defaultValue);
1824
+ const [n, a] = W(e.defaultValue);
1825
1825
  return Re(() => {
1826
1826
  let t = !1, i = -1, o = 0, d = e.defaultValue;
1827
- const r = (v) => {
1828
- t = !0, o = Number(e.input.current?.value), i = v.clientX, document.addEventListener("mouseup", u, !1), document.addEventListener("mousemove", h, !1), document.addEventListener("contextmenu", u, !1);
1829
- }, h = (v) => {
1827
+ const r = (b) => {
1828
+ t = !0, o = Number(e.input.current?.value), i = b.clientX, document.addEventListener("mouseup", u, !1), document.addEventListener("mousemove", h, !1), document.addEventListener("contextmenu", u, !1);
1829
+ }, h = (b) => {
1830
1830
  if (!t)
1831
1831
  return;
1832
- const S = e.step !== void 0 ? e.step : 1, A = (v.clientX - i) * S;
1833
- d = Number((o + A).toFixed(4)), e.min !== void 0 && (d = Math.max(d, e.min)), e.max !== void 0 && (d = Math.min(d, e.max)), e.onChange !== void 0 && e.onChange(d), a(d);
1832
+ const E = e.step !== void 0 ? e.step : 1, D = (b.clientX - i) * E;
1833
+ d = Number((o + D).toFixed(4)), e.min !== void 0 && (d = Math.max(d, e.min)), e.max !== void 0 && (d = Math.min(d, e.max)), e.onChange !== void 0 && e.onChange(d), a(d);
1834
1834
  }, u = () => {
1835
1835
  t = !1, document.removeEventListener("mouseup", u), document.removeEventListener("mousemove", h), document.removeEventListener("contextmenu", u);
1836
- }, f = (v) => {
1837
- const S = Number(v.target.value);
1838
- a(S);
1839
- }, m = (v) => {
1840
- const S = Number(v.target.value);
1841
- e.onChange !== void 0 && e.onChange(S), a(S);
1836
+ }, f = (b) => {
1837
+ const E = Number(b.target.value);
1838
+ a(E);
1839
+ }, m = (b) => {
1840
+ const E = Number(b.target.value);
1841
+ e.onChange !== void 0 && e.onChange(E), a(E);
1842
1842
  };
1843
1843
  return e.input.current?.addEventListener("input", f), e.label.current?.addEventListener("mousedown", r, !1), e.sliderRef !== void 0 && e.sliderRef.current?.addEventListener("input", m), () => {
1844
1844
  e.input.current?.removeEventListener("input", f), e.label.current?.removeEventListener("mousedown", r), e.sliderRef !== void 0 && e.sliderRef.current?.removeEventListener("input", m), document.removeEventListener("mouseup", u), document.removeEventListener("mousemove", h), document.removeEventListener("contextmenu", u);
1845
1845
  };
1846
1846
  }, []), n;
1847
1847
  }
1848
- function Xe(e) {
1849
- const n = Y(null), a = Y(null), t = Va({
1848
+ function Qe(e) {
1849
+ const n = V(null), a = V(null), t = Va({
1850
1850
  label: e.labelRef,
1851
1851
  input: n,
1852
1852
  sliderRef: a,
@@ -1902,42 +1902,42 @@ function Xe(e) {
1902
1902
  max: e.max,
1903
1903
  step: e.step,
1904
1904
  ref: a,
1905
- onChange: zt
1905
+ onChange: $t
1906
1906
  }
1907
1907
  )
1908
1908
  ] })
1909
1909
  ] });
1910
1910
  }
1911
1911
  function qa(e) {
1912
- const n = Y(null), a = Y(null), t = Y(null), i = Y(null), o = Y(null), d = Y(null), [r, h] = H(e.value), [u, f] = H({
1912
+ const n = V(null), a = V(null), t = V(null), i = V(null), o = V(null), d = V(null), [r, h] = W(e.value), [u, f] = W({
1913
1913
  min: Math.min(e.min, Math.min(e.value.x, e.value.y)),
1914
1914
  max: Math.max(e.max, Math.max(e.value.x, e.value.y))
1915
- }), [m, v] = H(!1);
1916
- function S() {
1917
- m || (window.addEventListener("mousemove", F), window.addEventListener("mouseup", A), window.addEventListener("mouseup", A), v(!0));
1915
+ }), [m, b] = W(!1);
1916
+ function E() {
1917
+ m || (window.addEventListener("mousemove", $), window.addEventListener("mouseup", D), window.addEventListener("mouseup", D), b(!0));
1918
1918
  }
1919
- function A() {
1920
- window.removeEventListener("mousemove", F), window.removeEventListener("mouseup", A), v(!1);
1919
+ function D() {
1920
+ window.removeEventListener("mousemove", $), window.removeEventListener("mouseup", D), b(!1);
1921
1921
  }
1922
- function F(T) {
1923
- const Z = o.current.getBoundingClientRect(), te = Ke(0, 99, T.clientX - Z.left) / 99, pe = Ke(0, 99, T.clientY - Z.top) / 99, q = an(nn(u.min, u.max, te), 3), ge = an(nn(u.min, u.max, pe), 3);
1924
- e.onChange({ target: { value: { x: q, y: ge } } }), h({ x: q, y: ge });
1922
+ function $(T) {
1923
+ const X = o.current.getBoundingClientRect(), ne = Je(0, 99, T.clientX - X.left) / 99, ge = Je(0, 99, T.clientY - X.top) / 99, q = nn(tn(u.min, u.max, ne), 3), ve = nn(tn(u.min, u.max, ge), 3);
1924
+ e.onChange({ target: { value: { x: q, y: ve } } }), h({ x: q, y: ve });
1925
1925
  }
1926
- function V(T) {
1927
- let Z = r.x, te = r.y;
1928
- T.target === n.current ? Z = Number(T.target.value) : te = Number(T.target.value), h({ x: Z, y: te });
1926
+ function z(T) {
1927
+ let X = r.x, ne = r.y;
1928
+ T.target === n.current ? X = Number(T.target.value) : ne = Number(T.target.value), h({ x: X, y: ne });
1929
1929
  }
1930
- function R() {
1930
+ function B() {
1931
1931
  const T = Number(t.current.value);
1932
- f({ min: T, max: u.max }), (r.x < T || r.y < T) && h({ x: Ke(T, u.max, r.x), y: Ke(T, u.max, r.y) });
1932
+ f({ min: T, max: u.max }), (r.x < T || r.y < T) && h({ x: Je(T, u.max, r.x), y: Je(T, u.max, r.y) });
1933
1933
  }
1934
- function I() {
1934
+ function C() {
1935
1935
  const T = Number(i.current.value);
1936
- f({ min: u.min, max: T }), (r.x > T || r.y > T) && h({ x: Ke(u.min, T, r.x), y: Ke(u.min, T, r.y) });
1936
+ f({ min: u.min, max: T }), (r.x > T || r.y > T) && h({ x: Je(u.min, T, r.x), y: Je(u.min, T, r.y) });
1937
1937
  }
1938
1938
  return Re(() => {
1939
- const T = tn(u.min, u.max, r.x), Z = tn(u.min, u.max, r.y);
1940
- d.current.style.left = `${T * 100}%`, d.current.style.top = `${Z * 100}%`;
1939
+ const T = en(u.min, u.max, r.x), X = en(u.min, u.max, r.y);
1940
+ d.current.style.left = `${T * 100}%`, d.current.style.top = `${X * 100}%`;
1941
1941
  }, [u, r]), /* @__PURE__ */ l.jsxs("div", { className: "vector2", children: [
1942
1942
  /* @__PURE__ */ l.jsxs("div", { className: "fields", children: [
1943
1943
  /* @__PURE__ */ l.jsxs("div", { children: [
@@ -1951,7 +1951,7 @@ function qa(e) {
1951
1951
  min: u.min,
1952
1952
  max: u.max,
1953
1953
  step: 0.01,
1954
- onChange: V
1954
+ onChange: z
1955
1955
  }
1956
1956
  )
1957
1957
  ] }),
@@ -1966,7 +1966,7 @@ function qa(e) {
1966
1966
  min: u.min,
1967
1967
  max: u.max,
1968
1968
  step: 0.01,
1969
- onChange: V
1969
+ onChange: z
1970
1970
  }
1971
1971
  )
1972
1972
  ] }),
@@ -1979,7 +1979,7 @@ function qa(e) {
1979
1979
  type: "number",
1980
1980
  value: u.min,
1981
1981
  step: 0.01,
1982
- onChange: R
1982
+ onChange: B
1983
1983
  }
1984
1984
  )
1985
1985
  ] }),
@@ -1992,31 +1992,31 @@ function qa(e) {
1992
1992
  type: "number",
1993
1993
  value: u.max,
1994
1994
  step: 0.01,
1995
- onChange: I
1995
+ onChange: C
1996
1996
  }
1997
1997
  )
1998
1998
  ] })
1999
1999
  ] }),
2000
- /* @__PURE__ */ l.jsxs("div", { className: "input", ref: o, onMouseDown: S, onMouseUp: A, children: [
2000
+ /* @__PURE__ */ l.jsxs("div", { className: "input", ref: o, onMouseDown: E, onMouseUp: D, children: [
2001
2001
  /* @__PURE__ */ l.jsx("div", { className: "x" }),
2002
2002
  /* @__PURE__ */ l.jsx("div", { className: "y" }),
2003
2003
  /* @__PURE__ */ l.jsx("div", { className: "pt", ref: d })
2004
2004
  ] })
2005
2005
  ] });
2006
2006
  }
2007
- function cn(e) {
2007
+ function on(e) {
2008
2008
  const n = e.value.isVector3 !== void 0, a = e.value.isEuler !== void 0, t = e.value.elements !== void 0, i = [];
2009
2009
  if (n) {
2010
2010
  const o = se(() => e.value, []), d = (h, u) => {
2011
2011
  o[h] = u, e.onChange({ target: { value: o } });
2012
2012
  };
2013
2013
  ["x", "y", "z"].forEach((h) => {
2014
- const u = Y(null);
2014
+ const u = V(null);
2015
2015
  i.push(
2016
2016
  /* @__PURE__ */ l.jsxs("div", { children: [
2017
2017
  /* @__PURE__ */ l.jsx("label", { ref: u, children: h.toUpperCase() }),
2018
2018
  /* @__PURE__ */ l.jsx(
2019
- Xe,
2019
+ Qe,
2020
2020
  {
2021
2021
  value: o[h],
2022
2022
  type: "number",
@@ -2034,12 +2034,12 @@ function cn(e) {
2034
2034
  o[h] = u, e.onChange({ target: { value: o } });
2035
2035
  };
2036
2036
  ["_x", "_y", "_z"].forEach((h) => {
2037
- const u = Y(null);
2037
+ const u = V(null);
2038
2038
  i.push(
2039
2039
  /* @__PURE__ */ l.jsxs("div", { children: [
2040
2040
  /* @__PURE__ */ l.jsx("label", { ref: u, children: h.substring(1).toUpperCase() }),
2041
2041
  /* @__PURE__ */ l.jsx(
2042
- Xe,
2042
+ Qe,
2043
2043
  {
2044
2044
  value: o[h],
2045
2045
  type: "number",
@@ -2058,12 +2058,12 @@ function cn(e) {
2058
2058
  o.elements[u] = h, e.onChange({ target: { value: o } });
2059
2059
  };
2060
2060
  for (let r = 0; r < 9; r++) {
2061
- const h = Y(null);
2061
+ const h = V(null);
2062
2062
  i.push(
2063
2063
  /* @__PURE__ */ l.jsxs("div", { children: [
2064
2064
  /* @__PURE__ */ l.jsx("label", { ref: h, children: r + 1 }),
2065
2065
  /* @__PURE__ */ l.jsx(
2066
- Xe,
2066
+ Qe,
2067
2067
  {
2068
2068
  value: o.elements[r],
2069
2069
  type: "number",
@@ -2086,12 +2086,12 @@ function Ka(e) {
2086
2086
  t[d] = r, e.onChange({ target: { value: t } });
2087
2087
  };
2088
2088
  ["x", "y", "z", "w"].forEach((d) => {
2089
- const r = Y(null);
2089
+ const r = V(null);
2090
2090
  a.push(
2091
2091
  /* @__PURE__ */ l.jsxs("div", { children: [
2092
2092
  /* @__PURE__ */ l.jsx("label", { ref: r, children: d.toUpperCase() }),
2093
2093
  /* @__PURE__ */ l.jsx(
2094
- Xe,
2094
+ Qe,
2095
2095
  {
2096
2096
  value: t.x,
2097
2097
  type: "number",
@@ -2110,12 +2110,12 @@ function Ka(e) {
2110
2110
  t.elements[r] = d, e.onChange({ target: { value: t } });
2111
2111
  };
2112
2112
  for (let o = 0; o < 16; o++) {
2113
- const d = Y(null);
2113
+ const d = V(null);
2114
2114
  a.push(
2115
2115
  /* @__PURE__ */ l.jsxs("div", { children: [
2116
2116
  /* @__PURE__ */ l.jsx("label", { ref: d, children: o + 1 }),
2117
2117
  /* @__PURE__ */ l.jsx(
2118
- Xe,
2118
+ Qe,
2119
2119
  {
2120
2120
  value: t.elements[o],
2121
2121
  type: "number",
@@ -2134,14 +2134,14 @@ function Ka(e) {
2134
2134
  function Xa(e) {
2135
2135
  return "items" in e;
2136
2136
  }
2137
- function Ze(e) {
2137
+ function et(e) {
2138
2138
  const n = [];
2139
2139
  return e.items.forEach((a) => {
2140
2140
  Xa(a) ? n.push(
2141
- /* @__PURE__ */ l.jsx(Ze, { title: Ot(a.title), items: a.items }, Math.random())
2141
+ /* @__PURE__ */ l.jsx(et, { title: Mt(a.title), items: a.items }, Math.random())
2142
2142
  ) : n.push(
2143
2143
  /* @__PURE__ */ l.jsx(
2144
- wt,
2144
+ Ct,
2145
2145
  {
2146
2146
  title: a.title,
2147
2147
  prop: a.prop,
@@ -2162,7 +2162,7 @@ function Ze(e) {
2162
2162
  Math.random()
2163
2163
  )
2164
2164
  );
2165
- }), /* @__PURE__ */ l.jsx(Wt, { label: e.title, open: e.expanded === !0, children: n });
2165
+ }), /* @__PURE__ */ l.jsx(Gt, { label: e.title, open: e.expanded === !0, children: n });
2166
2166
  }
2167
2167
  function Za(e) {
2168
2168
  return !(e === "alphaHash" || e === "alphaToCoverage" || e === "attenuationDistance" || e === "blendAlpha" || e === "blendColor" || e === "blendDstAlpha" || e === "colorWrite" || e === "combine" || e === "defaultAttributeValues" || e === "depthFunc" || e === "forceSinglePass" || e === "glslVersion" || e === "linecap" || e === "linejoin" || e === "linewidth" || e === "normalMapType" || e === "precision" || e === "premultipliedAlpha" || e === "shadowSide" || e === "toneMapped" || e === "uniformsGroups" || e === "uniformsNeedUpdate" || e === "userData" || e === "vertexColors" || e === "version" || e === "wireframeLinecap" || e === "wireframeLinejoin" || e === "wireframeLinewidth" || e.slice(0, 4) === "clip" || e.slice(0, 7) === "polygon" || e.slice(0, 7) === "stencil" || e.slice(0, 2) === "is");
@@ -2214,7 +2214,7 @@ function Ja(e) {
2214
2214
  }
2215
2215
  return e;
2216
2216
  }
2217
- function _t(e) {
2217
+ function Rt(e) {
2218
2218
  switch (e) {
2219
2219
  case "alphaMap":
2220
2220
  return "Alpha Map";
@@ -2584,13 +2584,13 @@ const ei = [
2584
2584
  valye: Pn
2585
2585
  }
2586
2586
  ];
2587
- function dt(e, n) {
2587
+ function ft(e, n) {
2588
2588
  e.needsUpdate = !0, e.type = "option", e.options = n;
2589
2589
  }
2590
2590
  function ri(e, n, a, t) {
2591
2591
  return {
2592
2592
  type: "boolean",
2593
- title: _t(e),
2593
+ title: Rt(e),
2594
2594
  prop: e,
2595
2595
  value: n,
2596
2596
  needsUpdate: !0,
@@ -2599,7 +2599,7 @@ function ri(e, n, a, t) {
2599
2599
  const d = t.getScene(a.uuid);
2600
2600
  if (d !== null) {
2601
2601
  const r = d.getObjectByProperty("uuid", a.uuid);
2602
- ee(r, `material.${e}`, o);
2602
+ te(r, `material.${e}`, o);
2603
2603
  }
2604
2604
  }
2605
2605
  };
@@ -2607,7 +2607,7 @@ function ri(e, n, a, t) {
2607
2607
  function si(e, n, a, t) {
2608
2608
  const i = {
2609
2609
  type: "number",
2610
- title: _t(e),
2610
+ title: Rt(e),
2611
2611
  prop: e,
2612
2612
  value: n,
2613
2613
  min: void 0,
@@ -2619,25 +2619,25 @@ function si(e, n, a, t) {
2619
2619
  const r = t.getScene(a.uuid);
2620
2620
  if (r !== null) {
2621
2621
  const h = r.getObjectByProperty("uuid", a.uuid);
2622
- ee(h, `material.${e}`, d);
2622
+ te(h, `material.${e}`, d);
2623
2623
  }
2624
2624
  }
2625
2625
  };
2626
2626
  switch (e) {
2627
2627
  case "blending":
2628
- dt(i, ti);
2628
+ ft(i, ti);
2629
2629
  break;
2630
2630
  case "blendDst":
2631
- dt(i, ii);
2631
+ ft(i, ii);
2632
2632
  break;
2633
2633
  case "blendEquation":
2634
- dt(i, ni);
2634
+ ft(i, ni);
2635
2635
  break;
2636
2636
  case "blendSrc":
2637
- dt(i, ai);
2637
+ ft(i, ai);
2638
2638
  break;
2639
2639
  case "side":
2640
- dt(i, ei);
2640
+ ft(i, ei);
2641
2641
  break;
2642
2642
  }
2643
2643
  return $n(e) && (i.value = Number(n), i.type = "range", i.min = Math.min(0, i.value), i.max = Math.max(1, i.value), i.step = 0.01), i;
@@ -2645,7 +2645,7 @@ function si(e, n, a, t) {
2645
2645
  function oi(e, n, a, t) {
2646
2646
  const i = {
2647
2647
  type: "string",
2648
- title: _t(e),
2648
+ title: Rt(e),
2649
2649
  prop: e,
2650
2650
  value: n,
2651
2651
  needsUpdate: !0,
@@ -2654,7 +2654,7 @@ function oi(e, n, a, t) {
2654
2654
  const h = t.getScene(a.uuid);
2655
2655
  if (h !== null) {
2656
2656
  const u = h.getObjectByProperty("uuid", a.uuid);
2657
- ee(u, `material.${e}`, r);
2657
+ te(u, `material.${e}`, r);
2658
2658
  }
2659
2659
  },
2660
2660
  onKeyDown: (d) => {
@@ -2665,7 +2665,7 @@ function oi(e, n, a, t) {
2665
2665
  const h = t.getScene(a.uuid);
2666
2666
  if (h !== null) {
2667
2667
  const u = h.getObjectByProperty("uuid", a.uuid);
2668
- ee(u, `material.${e}`, r);
2668
+ te(u, `material.${e}`, r);
2669
2669
  }
2670
2670
  }, i.onKeyDown = (d) => {
2671
2671
  if (d.key === "Enter" && (d.altKey || d.metaKey)) {
@@ -2673,7 +2673,7 @@ function oi(e, n, a, t) {
2673
2673
  const r = t.getScene(a.uuid);
2674
2674
  if (r !== null) {
2675
2675
  const h = r.getObjectByProperty("uuid", a.uuid);
2676
- ee(h, "material.needsUpdate", !0);
2676
+ te(h, "material.needsUpdate", !0);
2677
2677
  }
2678
2678
  }
2679
2679
  }), i;
@@ -2687,11 +2687,11 @@ function li(e) {
2687
2687
  function ui(e) {
2688
2688
  return e.x !== void 0 && e.y !== void 0 && e.z !== void 0 && e.w !== void 0;
2689
2689
  }
2690
- function Ut(e) {
2690
+ function Ft(e) {
2691
2691
  e.sort((n, a) => n.title < a.title ? -1 : n.title > a.title ? 1 : 0);
2692
2692
  }
2693
- function ht(e, n, a, t, i = "", o = !1) {
2694
- const d = _t(e).split(".")[0].replaceAll("[", "").replaceAll("]", ""), r = i.length > 0 ? `${i}.${e}` : e, h = typeof n;
2693
+ function mt(e, n, a, t, i = "", o = !1) {
2694
+ const d = Rt(e).split(".")[0].replaceAll("[", "").replaceAll("]", ""), r = i.length > 0 ? `${i}.${e}` : e, h = typeof n;
2695
2695
  if (h === "boolean" || h === "string")
2696
2696
  return {
2697
2697
  title: d,
@@ -2703,8 +2703,8 @@ function ht(e, n, a, t, i = "", o = !1) {
2703
2703
  t.updateObject(a.uuid, `material.${r}`, f);
2704
2704
  const m = t.getScene(a.uuid);
2705
2705
  if (m !== null) {
2706
- const v = m.getObjectByProperty("uuid", a.uuid);
2707
- ee(v, `material.${r}`, f);
2706
+ const b = m.getObjectByProperty("uuid", a.uuid);
2707
+ te(b, `material.${r}`, f);
2708
2708
  }
2709
2709
  }
2710
2710
  };
@@ -2718,10 +2718,10 @@ function ht(e, n, a, t, i = "", o = !1) {
2718
2718
  disabled: o,
2719
2719
  onChange: (f, m) => {
2720
2720
  t.updateObject(a.uuid, `material.${r}`, m);
2721
- const v = t.getScene(a.uuid);
2722
- if (v !== null) {
2723
- const S = v.getObjectByProperty("uuid", a.uuid);
2724
- ee(S, `material.${r}`, m);
2721
+ const b = t.getScene(a.uuid);
2722
+ if (b !== null) {
2723
+ const E = b.getObjectByProperty("uuid", a.uuid);
2724
+ te(E, `material.${r}`, m);
2725
2725
  }
2726
2726
  }
2727
2727
  };
@@ -2735,29 +2735,29 @@ function ht(e, n, a, t, i = "", o = !1) {
2735
2735
  value: n,
2736
2736
  disabled: o,
2737
2737
  onChange: (u, f) => {
2738
- const m = new $t(f);
2738
+ const m = new Ut(f);
2739
2739
  t.updateObject(a.uuid, `material.${r}`, m);
2740
- const v = t.getScene(a.uuid);
2741
- if (v !== null) {
2742
- const S = v.getObjectByProperty("uuid", a.uuid);
2743
- ee(S, `material.${r}`, m);
2740
+ const b = t.getScene(a.uuid);
2741
+ if (b !== null) {
2742
+ const E = b.getObjectByProperty("uuid", a.uuid);
2743
+ te(E, `material.${r}`, m);
2744
2744
  }
2745
2745
  }
2746
2746
  };
2747
2747
  if (Array.isArray(n)) {
2748
2748
  const u = [];
2749
2749
  for (const f in n) {
2750
- const m = n[f], v = `[${f.toString()}]`;
2750
+ const m = n[f], b = `[${f.toString()}]`;
2751
2751
  if (m.value !== void 0) {
2752
- const S = ht(`${v}.value`, m.value, a, t, r, o);
2753
- S !== void 0 && u.push(S);
2752
+ const E = mt(`${b}.value`, m.value, a, t, r, o);
2753
+ E !== void 0 && u.push(E);
2754
2754
  } else {
2755
- const S = ht(v, m, a, t, r, o);
2756
- S !== void 0 && u.push(S);
2755
+ const E = mt(b, m, a, t, r, o);
2756
+ E !== void 0 && u.push(E);
2757
2757
  }
2758
2758
  }
2759
2759
  if (u.length > 0)
2760
- return Ut(u), {
2760
+ return Ft(u), {
2761
2761
  title: d,
2762
2762
  items: u
2763
2763
  };
@@ -2773,8 +2773,8 @@ function ht(e, n, a, t, i = "", o = !1) {
2773
2773
  t.updateObject(a.uuid, `material.${r}`, f);
2774
2774
  const m = t.getScene(a.uuid);
2775
2775
  if (m !== null) {
2776
- const v = m.getObjectByProperty("uuid", a.uuid);
2777
- ee(v, `material.${r}`, f);
2776
+ const b = m.getObjectByProperty("uuid", a.uuid);
2777
+ te(b, `material.${r}`, f);
2778
2778
  }
2779
2779
  }
2780
2780
  };
@@ -2789,8 +2789,8 @@ function ht(e, n, a, t, i = "", o = !1) {
2789
2789
  t.updateObject(a.uuid, `material.${r}`, f);
2790
2790
  const m = t.getScene(a.uuid);
2791
2791
  if (m !== null) {
2792
- const v = m.getObjectByProperty("uuid", a.uuid);
2793
- ee(v, `material.${r}`, f);
2792
+ const b = m.getObjectByProperty("uuid", a.uuid);
2793
+ te(b, `material.${r}`, f);
2794
2794
  }
2795
2795
  }
2796
2796
  };
@@ -2805,8 +2805,8 @@ function ht(e, n, a, t, i = "", o = !1) {
2805
2805
  t.updateObject(a.uuid, `material.${r}`, f);
2806
2806
  const m = t.getScene(a.uuid);
2807
2807
  if (m !== null) {
2808
- const v = m.getObjectByProperty("uuid", a.uuid);
2809
- ee(v, `material.${r}`, f);
2808
+ const b = m.getObjectByProperty("uuid", a.uuid);
2809
+ te(b, `material.${r}`, f);
2810
2810
  }
2811
2811
  }
2812
2812
  };
@@ -2821,8 +2821,8 @@ function ht(e, n, a, t, i = "", o = !1) {
2821
2821
  t.updateObject(a.uuid, `material.${r}`, f);
2822
2822
  const m = t.getScene(a.uuid);
2823
2823
  if (m !== null) {
2824
- const v = m.getObjectByProperty("uuid", a.uuid);
2825
- ee(v, `material.${r}`, f);
2824
+ const b = m.getObjectByProperty("uuid", a.uuid);
2825
+ te(b, `material.${r}`, f);
2826
2826
  }
2827
2827
  }
2828
2828
  };
@@ -2833,33 +2833,37 @@ function ht(e, n, a, t, i = "", o = !1) {
2833
2833
  value: n,
2834
2834
  disabled: o,
2835
2835
  onChange: (u, f) => {
2836
- const m = Ja(e), v = i.length > 0 ? `${i}.${m}` : m;
2837
- t.createTexture(a.uuid, `material.${v}`, f);
2838
- const S = t.getScene(a.uuid);
2839
- if (S !== null) {
2840
- const A = S.getObjectByProperty("uuid", a.uuid);
2841
- A !== void 0 && Bn(f.src).then((F) => {
2842
- F.offset.set(f.offset[0], f.offset[1]), F.repeat.set(f.repeat[0], f.repeat[1]);
2843
- const V = A.material, R = v.split(".");
2844
- switch (R.length) {
2845
- case 1:
2846
- V[R[0]] = F;
2847
- break;
2848
- case 2:
2849
- V[R[0]][R[1]] = F;
2850
- break;
2851
- case 3:
2852
- V[R[0]][R[1]][R[2]] = F;
2853
- break;
2854
- case 4:
2855
- V[R[0]][R[1]][R[2]][R[3]] = F;
2856
- break;
2857
- case 5:
2858
- V[R[0]][R[1]][R[2]][R[3]][R[4]] = F;
2859
- break;
2860
- }
2861
- V.needsUpdate = !0;
2862
- });
2836
+ const m = Ja(e), b = i.length > 0 ? `${i}.${m}` : m;
2837
+ t.createTexture(a.uuid, `material.${b}`, f);
2838
+ const E = t.getScene(a.uuid);
2839
+ if (E !== null) {
2840
+ const D = E.getObjectByProperty("uuid", a.uuid);
2841
+ if (D !== void 0) {
2842
+ const $ = (z) => {
2843
+ const B = D.material, C = b.split(".");
2844
+ switch (C.length) {
2845
+ case 1:
2846
+ B[C[0]] = z;
2847
+ break;
2848
+ case 2:
2849
+ B[C[0]][C[1]] = z;
2850
+ break;
2851
+ case 3:
2852
+ B[C[0]][C[1]][C[2]] = z;
2853
+ break;
2854
+ case 4:
2855
+ B[C[0]][C[1]][C[2]][C[3]] = z;
2856
+ break;
2857
+ case 5:
2858
+ B[C[0]][C[1]][C[2]][C[3]][C[4]] = z;
2859
+ break;
2860
+ }
2861
+ B.needsUpdate = !0;
2862
+ };
2863
+ f.src.length > 0 ? Bn(f.src).then((z) => {
2864
+ z.offset.set(f.offset[0], f.offset[1]), z.repeat.set(f.repeat[0], f.repeat[1]), $(z);
2865
+ }) : $(null);
2866
+ }
2863
2867
  }
2864
2868
  }
2865
2869
  };
@@ -2874,8 +2878,8 @@ function ht(e, n, a, t, i = "", o = !1) {
2874
2878
  t.updateObject(a.uuid, `material.${r}`, f);
2875
2879
  const m = t.getScene(a.uuid);
2876
2880
  if (m !== null) {
2877
- const v = m.getObjectByProperty("uuid", a.uuid);
2878
- ee(v, `material.${r}`, f);
2881
+ const b = m.getObjectByProperty("uuid", a.uuid);
2882
+ te(b, `material.${r}`, f);
2879
2883
  }
2880
2884
  }
2881
2885
  };
@@ -2883,21 +2887,21 @@ function ht(e, n, a, t, i = "", o = !1) {
2883
2887
  const u = [], f = e === "defines" || e === "extensions";
2884
2888
  try {
2885
2889
  for (const m in n) {
2886
- const v = n[m];
2887
- if (v !== void 0)
2888
- if (v.value !== void 0) {
2889
- const S = ht(`${m}.value`, v.value, a, t, r, f);
2890
- S !== void 0 && u.push(S);
2890
+ const b = n[m];
2891
+ if (b !== void 0)
2892
+ if (b.value !== void 0) {
2893
+ const E = mt(`${m}.value`, b.value, a, t, r, f);
2894
+ E !== void 0 && u.push(E);
2891
2895
  } else {
2892
- const S = ht(m, v, a, t, r, f);
2893
- S !== void 0 && u.push(S);
2896
+ const E = mt(m, b, a, t, r, f);
2897
+ E !== void 0 && u.push(E);
2894
2898
  }
2895
2899
  }
2896
2900
  } catch {
2897
2901
  console.log("Issue cycling through material object:", e, n);
2898
2902
  }
2899
2903
  if (u.length > 0)
2900
- return Ut(u), {
2904
+ return Ft(u), {
2901
2905
  title: d,
2902
2906
  items: u
2903
2907
  };
@@ -2905,7 +2909,7 @@ function ht(e, n, a, t, i = "", o = !1) {
2905
2909
  }
2906
2910
  }
2907
2911
  }
2908
- function ln(e, n, a) {
2912
+ function cn(e, n, a) {
2909
2913
  const t = [];
2910
2914
  for (const i in e) {
2911
2915
  if (!Za(i))
@@ -2918,12 +2922,12 @@ function ln(e, n, a) {
2918
2922
  else if (o === "string")
2919
2923
  t.push(oi(i, d, n, a));
2920
2924
  else if (o === "object") {
2921
- const r = ht(i, d, n, a);
2925
+ const r = mt(i, d, n, a);
2922
2926
  r !== void 0 && t.push(r);
2923
2927
  } else
2924
2928
  d !== void 0 && console.log("other:", i, o, d);
2925
2929
  }
2926
- return Ut(t), t.push({
2930
+ return Ft(t), t.push({
2927
2931
  title: "Update Material",
2928
2932
  type: "button",
2929
2933
  onChange: () => {
@@ -2931,7 +2935,7 @@ function ln(e, n, a) {
2931
2935
  const i = a.getScene(n.uuid);
2932
2936
  if (i !== null) {
2933
2937
  const o = i.getObjectByProperty("uuid", n.uuid);
2934
- ee(o, "material.needsUpdate", !0);
2938
+ te(o, "material.needsUpdate", !0);
2935
2939
  }
2936
2940
  }
2937
2941
  }), t;
@@ -2943,10 +2947,10 @@ function di(e, n) {
2943
2947
  for (let o = 0; o < i; o++)
2944
2948
  t.push(
2945
2949
  /* @__PURE__ */ l.jsx(
2946
- Ze,
2950
+ et,
2947
2951
  {
2948
2952
  title: `Material ${o}`,
2949
- items: ln(a[o], e, n)
2953
+ items: cn(a[o], e, n)
2950
2954
  },
2951
2955
  `Material ${o}`
2952
2956
  )
@@ -2954,49 +2958,49 @@ function di(e, n) {
2954
2958
  return /* @__PURE__ */ l.jsx(l.Fragment, { children: t });
2955
2959
  } else
2956
2960
  return /* @__PURE__ */ l.jsx(
2957
- Ze,
2961
+ et,
2958
2962
  {
2959
2963
  title: "Material",
2960
- items: ln(a, e, n)
2964
+ items: cn(a, e, n)
2961
2965
  }
2962
2966
  );
2963
2967
  }
2964
- const hi = "data:image/gif;base64,R0lGODlhDgFkAIAAAP///wAAACH/C1hNUCBEYXRhWE1QPD94cGFja2V0IGJlZ2luPSLvu78iIGlkPSJXNU0wTXBDZWhpSHpyZVN6TlRjemtjOWQiPz4gPHg6eG1wbWV0YSB4bWxuczp4PSJhZG9iZTpuczptZXRhLyIgeDp4bXB0az0iQWRvYmUgWE1QIENvcmUgOS4xLWMwMDIgNzkuZGJhM2RhM2I1LCAyMDIzLzEyLzE1LTEwOjQyOjM3ICAgICAgICAiPiA8cmRmOlJERiB4bWxuczpyZGY9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkvMDIvMjItcmRmLXN5bnRheC1ucyMiPiA8cmRmOkRlc2NyaXB0aW9uIHJkZjphYm91dD0iIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtbG5zOnhtcE1NPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvbW0vIiB4bWxuczpzdFJlZj0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL3NUeXBlL1Jlc291cmNlUmVmIyIgeG1wOkNyZWF0b3JUb29sPSJBZG9iZSBQaG90b3Nob3AgMjUuNiAoTWFjaW50b3NoKSIgeG1wTU06SW5zdGFuY2VJRD0ieG1wLmlpZDoyMDk3M0NEODAxQjQxMUVGODVGNENDMkUyMUExNDk1NSIgeG1wTU06RG9jdW1lbnRJRD0ieG1wLmRpZDoyMDk3M0NEOTAxQjQxMUVGODVGNENDMkUyMUExNDk1NSI+IDx4bXBNTTpEZXJpdmVkRnJvbSBzdFJlZjppbnN0YW5jZUlEPSJ4bXAuaWlkOkE4ODc3Qzg5MDFCMzExRUY4NUY0Q0MyRTIxQTE0OTU1IiBzdFJlZjpkb2N1bWVudElEPSJ4bXAuZGlkOkE4ODc3QzhBMDFCMzExRUY4NUY0Q0MyRTIxQTE0OTU1Ii8+IDwvcmRmOkRlc2NyaXB0aW9uPiA8L3JkZjpSREY+IDwveDp4bXBtZXRhPiA8P3hwYWNrZXQgZW5kPSJyIj8+Af/+/fz7+vn49/b19PPy8fDv7u3s6+rp6Ofm5eTj4uHg397d3Nva2djX1tXU09LR0M/OzczLysnIx8bFxMPCwcC/vr28u7q5uLe2tbSzsrGwr66trKuqqainpqWko6KhoJ+enZybmpmYl5aVlJOSkZCPjo2Mi4qJiIeGhYSDgoGAf359fHt6eXh3dnV0c3JxcG9ubWxramloZ2ZlZGNiYWBfXl1cW1pZWFdWVVRTUlFQT05NTEtKSUhHRkVEQ0JBQD8+PTw7Ojk4NzY1NDMyMTAvLi0sKyopKCcmJSQjIiEgHx4dHBsaGRgXFhUUExIREA8ODQwLCgkIBwYFBAMCAQAAIfkEAAAAAAAsAAAAAA4BZAAAAv+Mj6nL7Q+jnLTai7PevPsPhuJIluaJpurKtu4Lx/JM1/aN5/rO9/4PDAqHxKLxiEwql8ym8wmNSqfUqvWKzWq33K73Cw6Lx+Sy+YxOq9fstvsNj8vn9Lr9js/r9/y+/w8YKDhIWGh4iJiouMjY6PgIGSk5SVlpeYmZqTkJAGDQ+dnpuekmGgAKejpKuiZqmprKqoZKGyrbOlqrejub6xvLGyw8TFzcprurGuvqybxq7ETbrItsCz0l7Zpc+6p9/cS967w9/S2FTF0u/mzehK4Oqz3eTl9vf4+fr7/P3+//DzCgwIEECxo8iDChwoUMGzp8CDGixIkUK1q8iDGjxo0XHDt6/AgypMiRJEuaPIkypcqVLFt+KwAAOw==";
2965
- function fi(e) {
2966
- const n = Y(null), a = Y(null), t = Y(null), i = Y(null), o = Y(null), [d] = H(e.value), [r, h] = H(e.value.offset[0]), [u, f] = H(e.value.offset[1]), [m, v] = H(e.value.repeat[0]), [S, A] = H(e.value.repeat[1]);
2967
- function F(R, I, T, Z, te) {
2968
+ const ln = "data:image/gif;base64,R0lGODlhDgFkAIAAAP///wAAACH/C1hNUCBEYXRhWE1QPD94cGFja2V0IGJlZ2luPSLvu78iIGlkPSJXNU0wTXBDZWhpSHpyZVN6TlRjemtjOWQiPz4gPHg6eG1wbWV0YSB4bWxuczp4PSJhZG9iZTpuczptZXRhLyIgeDp4bXB0az0iQWRvYmUgWE1QIENvcmUgOS4xLWMwMDIgNzkuZGJhM2RhM2I1LCAyMDIzLzEyLzE1LTEwOjQyOjM3ICAgICAgICAiPiA8cmRmOlJERiB4bWxuczpyZGY9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkvMDIvMjItcmRmLXN5bnRheC1ucyMiPiA8cmRmOkRlc2NyaXB0aW9uIHJkZjphYm91dD0iIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtbG5zOnhtcE1NPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvbW0vIiB4bWxuczpzdFJlZj0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL3NUeXBlL1Jlc291cmNlUmVmIyIgeG1wOkNyZWF0b3JUb29sPSJBZG9iZSBQaG90b3Nob3AgMjUuNiAoTWFjaW50b3NoKSIgeG1wTU06SW5zdGFuY2VJRD0ieG1wLmlpZDoyMDk3M0NEODAxQjQxMUVGODVGNENDMkUyMUExNDk1NSIgeG1wTU06RG9jdW1lbnRJRD0ieG1wLmRpZDoyMDk3M0NEOTAxQjQxMUVGODVGNENDMkUyMUExNDk1NSI+IDx4bXBNTTpEZXJpdmVkRnJvbSBzdFJlZjppbnN0YW5jZUlEPSJ4bXAuaWlkOkE4ODc3Qzg5MDFCMzExRUY4NUY0Q0MyRTIxQTE0OTU1IiBzdFJlZjpkb2N1bWVudElEPSJ4bXAuZGlkOkE4ODc3QzhBMDFCMzExRUY4NUY0Q0MyRTIxQTE0OTU1Ii8+IDwvcmRmOkRlc2NyaXB0aW9uPiA8L3JkZjpSREY+IDwveDp4bXBtZXRhPiA8P3hwYWNrZXQgZW5kPSJyIj8+Af/+/fz7+vn49/b19PPy8fDv7u3s6+rp6Ofm5eTj4uHg397d3Nva2djX1tXU09LR0M/OzczLysnIx8bFxMPCwcC/vr28u7q5uLe2tbSzsrGwr66trKuqqainpqWko6KhoJ+enZybmpmYl5aVlJOSkZCPjo2Mi4qJiIeGhYSDgoGAf359fHt6eXh3dnV0c3JxcG9ubWxramloZ2ZlZGNiYWBfXl1cW1pZWFdWVVRTUlFQT05NTEtKSUhHRkVEQ0JBQD8+PTw7Ojk4NzY1NDMyMTAvLi0sKyopKCcmJSQjIiEgHx4dHBsaGRgXFhUUExIREA8ODQwLCgkIBwYFBAMCAQAAIfkEAAAAAAAsAAAAAA4BZAAAAv+Mj6nL7Q+jnLTai7PevPsPhuJIluaJpurKtu4Lx/JM1/aN5/rO9/4PDAqHxKLxiEwql8ym8wmNSqfUqvWKzWq33K73Cw6Lx+Sy+YxOq9fstvsNj8vn9Lr9js/r9/y+/w8YKDhIWGh4iJiouMjY6PgIGSk5SVlpeYmZqTkJAGDQ+dnpuekmGgAKejpKuiZqmprKqoZKGyrbOlqrejub6xvLGyw8TFzcprurGuvqybxq7ETbrItsCz0l7Zpc+6p9/cS967w9/S2FTF0u/mzehK4Oqz3eTl9vf4+fr7/P3+//DzCgwIEECxo8iDChwoUMGzp8CDGixIkUK1q8iDGjxo0XHDt6/AgypMiRJEuaPIkypcqVLFt+KwAAOw==";
2969
+ function hi(e) {
2970
+ const n = V(null), a = V(null), t = V(null), i = V(null), o = V(null), [d] = W(e.value), [r, h] = W(e.value.offset[0]), [u, f] = W(e.value.offset[1]), [m, b] = W(e.value.repeat[0]), [E, D] = W(e.value.repeat[1]);
2971
+ function $(B, C, T, X, ne) {
2968
2972
  if (e.onChange !== void 0) {
2969
- const pe = e.prop !== void 0 ? e.prop : e.title;
2970
- e.onChange(pe, {
2971
- src: R,
2972
- offset: [I, T],
2973
- repeat: [Z, te]
2973
+ const ge = e.prop !== void 0 ? e.prop : e.title;
2974
+ e.onChange(ge, {
2975
+ src: B,
2976
+ offset: [C, T],
2977
+ repeat: [X, ne]
2974
2978
  });
2975
2979
  }
2976
2980
  }
2977
- function V(R) {
2978
- const I = n.current.src, T = R.target.value;
2979
- switch (R.target) {
2981
+ function z(B) {
2982
+ const C = n.current.src, T = B.target.value;
2983
+ switch (B.target) {
2980
2984
  case a.current:
2981
- h(T), F(I, T, u, m, S);
2985
+ h(T), $(C, T, u, m, E);
2982
2986
  break;
2983
2987
  case t.current:
2984
- f(T), F(I, r, T, m, S);
2988
+ f(T), $(C, r, T, m, E);
2985
2989
  break;
2986
2990
  case i.current:
2987
- v(T), F(I, r, u, T, S);
2991
+ b(T), $(C, r, u, T, E);
2988
2992
  break;
2989
2993
  case o.current:
2990
- A(T), F(I, r, u, m, T);
2994
+ D(T), $(C, r, u, m, T);
2991
2995
  break;
2992
2996
  }
2993
2997
  }
2994
2998
  return /* @__PURE__ */ l.jsxs("div", { className: "imageField", children: [
2995
2999
  /* @__PURE__ */ l.jsx("img", { alt: e.title, ref: n, onClick: () => {
2996
- Qa().then((R) => {
2997
- n.current.src = R, F(R, r, u, m, S);
3000
+ Qa().then((B) => {
3001
+ n.current.src = B, $(B, r, u, m, E);
2998
3002
  });
2999
- }, src: d.src.length > 0 ? d.src : hi }),
3003
+ }, src: d.src.length > 0 ? d.src : ln }),
3000
3004
  /* @__PURE__ */ l.jsxs("div", { className: "fields", children: [
3001
3005
  /* @__PURE__ */ l.jsxs("div", { children: [
3002
3006
  /* @__PURE__ */ l.jsx("label", { children: "Offset:" }),
@@ -3007,7 +3011,7 @@ function fi(e) {
3007
3011
  type: "number",
3008
3012
  value: r,
3009
3013
  step: 0.01,
3010
- onChange: V
3014
+ onChange: z
3011
3015
  }
3012
3016
  ),
3013
3017
  /* @__PURE__ */ l.jsx(
@@ -3017,7 +3021,7 @@ function fi(e) {
3017
3021
  type: "number",
3018
3022
  value: u,
3019
3023
  step: 0.01,
3020
- onChange: V
3024
+ onChange: z
3021
3025
  }
3022
3026
  )
3023
3027
  ] }),
@@ -3030,7 +3034,7 @@ function fi(e) {
3030
3034
  type: "number",
3031
3035
  value: m,
3032
3036
  step: 0.01,
3033
- onChange: V
3037
+ onChange: z
3034
3038
  }
3035
3039
  ),
3036
3040
  /* @__PURE__ */ l.jsx(
@@ -3038,19 +3042,22 @@ function fi(e) {
3038
3042
  {
3039
3043
  ref: o,
3040
3044
  type: "number",
3041
- value: S,
3045
+ value: E,
3042
3046
  step: 0.01,
3043
- onChange: V
3047
+ onChange: z
3044
3048
  }
3045
3049
  )
3046
- ] })
3050
+ ] }),
3051
+ /* @__PURE__ */ l.jsx("button", { onClick: () => {
3052
+ $("", r, u, m, E), n.current.src = ln;
3053
+ }, children: "Clear" })
3047
3054
  ] })
3048
3055
  ] });
3049
3056
  }
3050
- function wt(e) {
3057
+ function Ct(e) {
3051
3058
  let n = e.value;
3052
3059
  n !== void 0 && n.isColor !== void 0 && (n = Da(e.value));
3053
- const [a, t] = H(n), i = Y(null), o = (u) => {
3060
+ const [a, t] = W(n), i = V(null), o = (u) => {
3054
3061
  let f = u.target.value;
3055
3062
  e.type === "boolean" ? f = u.target.checked : e.type === "option" && (f = e.options[f].value), t(f), e.onChange !== void 0 && e.onChange(e.prop !== void 0 ? e.prop : e.title, f);
3056
3063
  }, d = {};
@@ -3058,7 +3065,7 @@ function wt(e) {
3058
3065
  const r = e.type === "string" && (a.length > 100 || a.search(`
3059
3066
  `) > -1), h = r || e.type === "image" || e.type === "vector2";
3060
3067
  return /* @__PURE__ */ l.jsxs("div", { className: `field ${h ? "block" : ""}`, style: d, children: [
3061
- e.type !== "button" && /* @__PURE__ */ l.jsx("label", { ref: i, children: Ot(e.title) }, "fieldLabel"),
3068
+ e.type !== "button" && /* @__PURE__ */ l.jsx("label", { ref: i, children: Mt(e.title) }, "fieldLabel"),
3062
3069
  e.type === "string" && !r && /* @__PURE__ */ l.jsx(
3063
3070
  "input",
3064
3071
  {
@@ -3091,7 +3098,7 @@ function wt(e) {
3091
3098
  }
3092
3099
  ),
3093
3100
  e.type === "number" && /* @__PURE__ */ l.jsx(
3094
- Xe,
3101
+ Qe,
3095
3102
  {
3096
3103
  value: a,
3097
3104
  type: e.type,
@@ -3105,7 +3112,7 @@ function wt(e) {
3105
3112
  }
3106
3113
  ),
3107
3114
  e.type === "range" && /* @__PURE__ */ l.jsx(
3108
- Xe,
3115
+ Qe,
3109
3116
  {
3110
3117
  value: a,
3111
3118
  type: e.type,
@@ -3132,12 +3139,12 @@ function wt(e) {
3132
3139
  children: e.title
3133
3140
  }
3134
3141
  ),
3135
- e.type === "image" && /* @__PURE__ */ l.jsx(fi, { title: e.title, prop: e.prop, value: e.value, onChange: e.onChange }),
3136
- e.type === "option" && /* @__PURE__ */ l.jsx(l.Fragment, { children: /* @__PURE__ */ l.jsx("select", { onChange: o, disabled: e.disabled, defaultValue: e.value, children: e.options?.map((u, f) => /* @__PURE__ */ l.jsx("option", { value: u.value, children: Ot(u.title) }, f)) }) }),
3142
+ e.type === "image" && /* @__PURE__ */ l.jsx(hi, { title: e.title, prop: e.prop, value: e.value, onChange: e.onChange }),
3143
+ e.type === "option" && /* @__PURE__ */ l.jsx(l.Fragment, { children: /* @__PURE__ */ l.jsx("select", { onChange: o, disabled: e.disabled, defaultValue: e.value, children: e.options?.map((u, f) => /* @__PURE__ */ l.jsx("option", { value: u.value, children: Mt(u.title) }, f)) }) }),
3137
3144
  e.type === "vector2" && /* @__PURE__ */ l.jsx(qa, { value: a, min: 0, max: 1, onChange: o }),
3138
- e.type === "grid3" && /* @__PURE__ */ l.jsx(cn, { value: a, onChange: o }),
3145
+ e.type === "grid3" && /* @__PURE__ */ l.jsx(on, { value: a, onChange: o }),
3139
3146
  e.type === "grid4" && /* @__PURE__ */ l.jsx(Ka, { value: a, onChange: o }),
3140
- e.type === "euler" && /* @__PURE__ */ l.jsx(cn, { value: a, onChange: o })
3147
+ e.type === "euler" && /* @__PURE__ */ l.jsx(on, { value: a, onChange: o })
3141
3148
  ] });
3142
3149
  }
3143
3150
  function un(e) {
@@ -3169,7 +3176,7 @@ function un(e) {
3169
3176
  }
3170
3177
  return e;
3171
3178
  }
3172
- function mi(e, n) {
3179
+ function fi(e, n) {
3173
3180
  const a = [];
3174
3181
  if (e.perspectiveCameraInfo !== void 0)
3175
3182
  for (const t in e.perspectiveCameraInfo)
@@ -3184,7 +3191,7 @@ function mi(e, n) {
3184
3191
  const d = n.getScene(e.uuid);
3185
3192
  if (d !== null) {
3186
3193
  const r = d.getObjectByProperty("uuid", e.uuid);
3187
- r !== void 0 && (ee(r, i, o), r.updateProjectionMatrix());
3194
+ r !== void 0 && (te(r, i, o), r.updateProjectionMatrix());
3188
3195
  }
3189
3196
  }
3190
3197
  });
@@ -3201,19 +3208,19 @@ function mi(e, n) {
3201
3208
  const d = n.getScene(e.uuid);
3202
3209
  if (d !== null) {
3203
3210
  const r = d.getObjectByProperty("uuid", e.uuid);
3204
- r !== void 0 && (ee(r, i, o), r.updateProjectionMatrix());
3211
+ r !== void 0 && (te(r, i, o), r.updateProjectionMatrix());
3205
3212
  }
3206
3213
  }
3207
3214
  });
3208
3215
  return /* @__PURE__ */ l.jsx(
3209
- Ze,
3216
+ et,
3210
3217
  {
3211
3218
  title: "Camera",
3212
3219
  items: a
3213
3220
  }
3214
3221
  );
3215
3222
  }
3216
- function pi(e, n) {
3223
+ function mi(e, n) {
3217
3224
  const a = new sa();
3218
3225
  a.elements = e.matrix;
3219
3226
  const t = new J(), i = new oa(), o = new J();
@@ -3224,11 +3231,11 @@ function pi(e, n) {
3224
3231
  const f = n.getScene(e.uuid);
3225
3232
  if (f !== null) {
3226
3233
  const m = f.getObjectByProperty("uuid", e.uuid);
3227
- ee(m, r, u);
3234
+ te(m, r, u);
3228
3235
  }
3229
3236
  };
3230
3237
  return /* @__PURE__ */ l.jsx(
3231
- Ze,
3238
+ et,
3232
3239
  {
3233
3240
  title: "Transform",
3234
3241
  items: [
@@ -3280,7 +3287,7 @@ function dn(e) {
3280
3287
  }
3281
3288
  return e;
3282
3289
  }
3283
- function gi(e, n) {
3290
+ function pi(e, n) {
3284
3291
  const a = [];
3285
3292
  if (e.lightInfo !== void 0)
3286
3293
  for (const t in e.lightInfo) {
@@ -3291,12 +3298,12 @@ function gi(e, n) {
3291
3298
  type: "color",
3292
3299
  value: i,
3293
3300
  onChange: (o, d) => {
3294
- const r = new $t(d);
3301
+ const r = new Ut(d);
3295
3302
  n.updateObject(e.uuid, o, r);
3296
3303
  const h = n.getScene(e.uuid);
3297
3304
  if (h !== null) {
3298
3305
  const u = h.getObjectByProperty("uuid", e.uuid);
3299
- ee(u, o, r);
3306
+ te(u, o, r);
3300
3307
  }
3301
3308
  }
3302
3309
  }) : a.push({
@@ -3310,20 +3317,20 @@ function gi(e, n) {
3310
3317
  const r = n.getScene(e.uuid);
3311
3318
  if (r !== null) {
3312
3319
  const h = r.getObjectByProperty("uuid", e.uuid);
3313
- ee(h, o, d);
3320
+ te(h, o, d);
3314
3321
  }
3315
3322
  }
3316
3323
  }));
3317
3324
  }
3318
3325
  return /* @__PURE__ */ l.jsx(
3319
- Ze,
3326
+ et,
3320
3327
  {
3321
3328
  title: "Light",
3322
3329
  items: a
3323
3330
  }
3324
3331
  );
3325
3332
  }
3326
- function vi(e, n) {
3333
+ function gi(e, n) {
3327
3334
  const a = [], t = [];
3328
3335
  let i = 0;
3329
3336
  e.animations.forEach((d) => {
@@ -3390,7 +3397,7 @@ function vi(e, n) {
3390
3397
  }
3391
3398
  }
3392
3399
  }
3393
- return /* @__PURE__ */ l.jsx(Ze, { title: "Animation", items: a });
3400
+ return /* @__PURE__ */ l.jsx(et, { title: "Animation", items: a });
3394
3401
  }
3395
3402
  const zn = {
3396
3403
  name: "",
@@ -3405,65 +3412,65 @@ const zn = {
3405
3412
  lightInfo: void 0,
3406
3413
  children: []
3407
3414
  };
3408
- let fe = { ...zn };
3409
- function bi(e) {
3410
- const [n, a] = H(-1);
3415
+ let me = { ...zn };
3416
+ function vi(e) {
3417
+ const [n, a] = W(-1);
3411
3418
  Re(() => {
3412
3419
  function d(h) {
3413
- fe = { ...h.value }, a(Date.now());
3420
+ me = { ...h.value }, a(Date.now());
3414
3421
  }
3415
3422
  function r() {
3416
- fe = { ...zn }, a(Date.now());
3423
+ me = { ...zn }, a(Date.now());
3417
3424
  }
3418
- return D.addEventListener(P.SET_SCENE, r), D.addEventListener(P.SET_OBJECT, d), () => {
3419
- D.removeEventListener(P.SET_SCENE, r), D.removeEventListener(P.SET_OBJECT, d);
3425
+ return P.addEventListener(A.SET_SCENE, r), P.addEventListener(A.SET_OBJECT, d), () => {
3426
+ P.removeEventListener(A.SET_SCENE, r), P.removeEventListener(A.SET_OBJECT, d);
3420
3427
  };
3421
3428
  }, []);
3422
- const t = fe.type.toLowerCase(), i = fe.animations.length > 0 || fe.mixer !== void 0, o = t.search("mesh") > -1 || t.search("line") > -1 || t.search("points") > -1;
3423
- return /* @__PURE__ */ l.jsx(Wt, { label: "Inspector", children: /* @__PURE__ */ l.jsx("div", { id: "Inspector", className: e.class, children: fe.uuid.length > 0 && /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
3429
+ const t = me.type.toLowerCase(), i = me.animations.length > 0 || me.mixer !== void 0, o = t.search("mesh") > -1 || t.search("line") > -1 || t.search("points") > -1;
3430
+ return /* @__PURE__ */ l.jsx(Gt, { label: "Inspector", children: /* @__PURE__ */ l.jsx("div", { id: "Inspector", className: e.class, children: me.uuid.length > 0 && /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
3424
3431
  /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
3425
3432
  /* @__PURE__ */ l.jsx(
3426
- wt,
3433
+ Ct,
3427
3434
  {
3428
3435
  type: "string",
3429
3436
  title: "Name",
3430
3437
  prop: "name",
3431
- value: fe.name,
3438
+ value: me.name,
3432
3439
  disabled: !0
3433
3440
  }
3434
3441
  ),
3435
3442
  /* @__PURE__ */ l.jsx(
3436
- wt,
3443
+ Ct,
3437
3444
  {
3438
3445
  type: "string",
3439
3446
  title: "Type",
3440
3447
  prop: "type",
3441
- value: fe.type,
3448
+ value: me.type,
3442
3449
  disabled: !0
3443
3450
  }
3444
3451
  ),
3445
3452
  /* @__PURE__ */ l.jsx(
3446
- wt,
3453
+ Ct,
3447
3454
  {
3448
3455
  type: "string",
3449
3456
  title: "UUID",
3450
3457
  prop: "uuid",
3451
- value: fe.uuid,
3458
+ value: me.uuid,
3452
3459
  disabled: !0
3453
3460
  }
3454
3461
  )
3455
3462
  ] }),
3456
3463
  /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
3457
- pi(fe, e.three),
3458
- i ? vi(fe, e.three) : null,
3459
- t.search("camera") > -1 ? mi(fe, e.three) : null,
3460
- t.search("light") > -1 ? gi(fe, e.three) : null,
3461
- o ? di(fe, e.three) : null
3464
+ mi(me, e.three),
3465
+ i ? gi(me, e.three) : null,
3466
+ t.search("camera") > -1 ? fi(me, e.three) : null,
3467
+ t.search("light") > -1 ? pi(me, e.three) : null,
3468
+ o ? di(me, e.three) : null
3462
3469
  ] })
3463
3470
  ] }) }, n) }, "Inspector");
3464
3471
  }
3465
- function Ui(e) {
3466
- const [n] = H([]), [a, t] = H(0), i = (r) => {
3472
+ function Fi(e) {
3473
+ const [n] = W([]), [a, t] = W(0), i = (r) => {
3467
3474
  n.push(r.value), t(Date.now());
3468
3475
  }, o = (r) => {
3469
3476
  const h = r.value;
@@ -3473,20 +3480,20 @@ function Ui(e) {
3473
3480
  return;
3474
3481
  }
3475
3482
  };
3476
- Re(() => (D.addEventListener(P.ADD_SCENE, i), D.addEventListener(P.REMOVE_SCENE, o), () => {
3477
- D.removeEventListener(P.ADD_SCENE, i), D.removeEventListener(P.REMOVE_SCENE, o);
3483
+ Re(() => (P.addEventListener(A.ADD_SCENE, i), P.addEventListener(A.REMOVE_SCENE, o), () => {
3484
+ P.removeEventListener(A.ADD_SCENE, i), P.removeEventListener(A.REMOVE_SCENE, o);
3478
3485
  }), []);
3479
3486
  const d = [];
3480
3487
  return n.forEach((r, h) => {
3481
3488
  d.push(
3482
- /* @__PURE__ */ l.jsx(Wt, { label: `Scene: ${r.name}`, open: !0, children: /* @__PURE__ */ l.jsx(Ya, { child: r, scene: r, three: e.three }) }, `scene_${h}`)
3489
+ /* @__PURE__ */ l.jsx(Gt, { label: `Scene: ${r.name}`, open: !0, children: /* @__PURE__ */ l.jsx(Ya, { child: r, scene: r, three: e.three }) }, `scene_${h}`)
3483
3490
  );
3484
3491
  }), /* @__PURE__ */ l.jsxs("div", { id: "SidePanel", children: [
3485
3492
  d,
3486
- /* @__PURE__ */ l.jsx(bi, { three: e.three })
3493
+ /* @__PURE__ */ l.jsx(vi, { three: e.three })
3487
3494
  ] }, `SidePanel ${a}`);
3488
3495
  }
3489
- function $i(e) {
3496
+ function Ui(e) {
3490
3497
  return Re(() => {
3491
3498
  function n(r) {
3492
3499
  let h = null;
@@ -3499,56 +3506,60 @@ function $i(e) {
3499
3506
  f !== void 0 ? e.three.setObject(f) : console.log(`Hermes - can't find object: ${h}`, u);
3500
3507
  }, t = (r, h, u) => {
3501
3508
  const f = n(r), m = f?.getObjectByProperty("uuid", r);
3502
- m !== void 0 ? ee(m, h, u) : console.log(`Hermes - can't set object: ${r}`, f);
3509
+ m !== void 0 ? te(m, h, u) : console.log(`Hermes - can't set object: ${r}`, f);
3503
3510
  }, i = (r) => {
3504
3511
  const h = r.value, { key: u, value: f, uuid: m } = h;
3505
3512
  t(m, u, f);
3506
3513
  }, o = (r) => {
3507
3514
  const h = r.value, f = n(h.uuid)?.getObjectByProperty("uuid", h.uuid);
3508
- f !== void 0 && Bn(h.value.src).then((m) => {
3509
- m.offset.set(h.value.offset[0], h.value.offset[1]), m.repeat.set(h.value.repeat[0], h.value.repeat[1]);
3510
- const v = h.key.split(".");
3511
- switch (v.length) {
3512
- case 1:
3513
- f[v[0]] = m;
3514
- break;
3515
- case 2:
3516
- f[v[0]][v[1]] = m;
3517
- break;
3518
- case 3:
3519
- f[v[0]][v[1]][v[2]] = m;
3520
- break;
3521
- case 4:
3522
- f[v[0]][v[1]][v[2]][v[3]] = m;
3523
- break;
3524
- case 5:
3525
- f[v[0]][v[1]][v[2]][v[3]][v[4]] = m;
3526
- break;
3527
- }
3528
- f.material.needsUpdate = !0;
3529
- });
3515
+ if (f !== void 0) {
3516
+ const m = (b) => {
3517
+ const E = h.key.split(".");
3518
+ switch (E.length) {
3519
+ case 1:
3520
+ f[E[0]] = b;
3521
+ break;
3522
+ case 2:
3523
+ f[E[0]][E[1]] = b;
3524
+ break;
3525
+ case 3:
3526
+ f[E[0]][E[1]][E[2]] = b;
3527
+ break;
3528
+ case 4:
3529
+ f[E[0]][E[1]][E[2]][E[3]] = b;
3530
+ break;
3531
+ case 5:
3532
+ f[E[0]][E[1]][E[2]][E[3]][E[4]] = b;
3533
+ break;
3534
+ }
3535
+ f.material.needsUpdate = !0;
3536
+ };
3537
+ h.value.src.length > 0 ? Bn(h.value.src).then((b) => {
3538
+ b.offset.set(h.value.offset[0], h.value.offset[1]), b.repeat.set(h.value.repeat[0], h.value.repeat[1]), m(b);
3539
+ }) : m(null);
3540
+ }
3530
3541
  }, d = (r) => {
3531
- const { key: h, uuid: u, value: f, subitem: m } = r.value, S = n(u)?.getObjectByProperty("uuid", u);
3532
- if (S !== void 0)
3542
+ const { key: h, uuid: u, value: f, subitem: m } = r.value, E = n(u)?.getObjectByProperty("uuid", u);
3543
+ if (E !== void 0)
3533
3544
  try {
3534
- m !== void 0 ? Na(S, m)[h](f) : S[h](f);
3535
- } catch (A) {
3536
- console.log("Error requesting method:"), console.log(A), console.log(h), console.log(f);
3545
+ m !== void 0 ? Na(E, m)[h](f) : E[h](f);
3546
+ } catch (D) {
3547
+ console.log("Error requesting method:"), console.log(D), console.log(h), console.log(f);
3537
3548
  }
3538
3549
  };
3539
- return D.addEventListener(P.GET_OBJECT, a), D.addEventListener(P.UPDATE_OBJECT, i), D.addEventListener(P.CREATE_TEXTURE, o), D.addEventListener(P.REQUEST_METHOD, d), () => {
3540
- D.removeEventListener(P.GET_OBJECT, a), D.removeEventListener(P.UPDATE_OBJECT, i), D.removeEventListener(P.CREATE_TEXTURE, o), D.removeEventListener(P.REQUEST_METHOD, d);
3550
+ return P.addEventListener(A.GET_OBJECT, a), P.addEventListener(A.UPDATE_OBJECT, i), P.addEventListener(A.CREATE_TEXTURE, o), P.addEventListener(A.REQUEST_METHOD, d), () => {
3551
+ P.removeEventListener(A.GET_OBJECT, a), P.removeEventListener(A.UPDATE_OBJECT, i), P.removeEventListener(A.CREATE_TEXTURE, o), P.removeEventListener(A.REQUEST_METHOD, d);
3541
3552
  };
3542
3553
  }, []), null;
3543
3554
  }
3544
- class yi extends ca {
3555
+ class bi extends ca {
3545
3556
  constructor(n, a) {
3546
- const t = [1, 1, 0, -1, 1, 0, -1, -1, 0, 1, -1, 0, 1, 1, 0], i = new Kt();
3547
- i.setAttribute("position", new Xt(t, 3)), i.computeBoundingSphere();
3557
+ const t = [1, 1, 0, -1, 1, 0, -1, -1, 0, 1, -1, 0, 1, 1, 0], i = new qt();
3558
+ i.setAttribute("position", new Kt(t, 3)), i.computeBoundingSphere();
3548
3559
  const o = new la({ fog: !1 });
3549
3560
  super(i, o), this.light = n, this.color = a, this.type = "RectAreaLightHelper";
3550
- const d = [1, 1, 0, -1, 1, 0, -1, -1, 0, 1, 1, 0, -1, -1, 0, 1, -1, 0], r = new Kt();
3551
- r.setAttribute("position", new Xt(d, 3)), r.computeBoundingSphere(), this.add(new An(r, new jn({ side: vn, fog: !1 })));
3561
+ const d = [1, 1, 0, -1, 1, 0, -1, -1, 0, 1, 1, 0, -1, -1, 0, 1, -1, 0], r = new qt();
3562
+ r.setAttribute("position", new Kt(d, 3)), r.computeBoundingSphere(), this.add(new An(r, new jn({ side: vn, fog: !1 })));
3552
3563
  }
3553
3564
  updateMatrixWorld() {
3554
3565
  if (this.scale.set(0.5 * this.light.width, 0.5 * this.light.height, 1), this.color !== void 0)
@@ -3564,62 +3575,62 @@ class yi extends ca {
3564
3575
  this.geometry.dispose(), this.material.dispose(), this.children[0].geometry.dispose(), this.children[0].material.dispose();
3565
3576
  }
3566
3577
  }
3567
- const hn = { type: "change" }, It = { type: "start" }, fn = { type: "end" }, Et = new ua(), mn = new da(), Ei = Math.cos(70 * ha.DEG2RAD);
3568
- class xi extends pn {
3578
+ const hn = { type: "change" }, jt = { type: "start" }, fn = { type: "end" }, Et = new ua(), mn = new da(), yi = Math.cos(70 * ha.DEG2RAD);
3579
+ class Ei extends pn {
3569
3580
  constructor(n, a) {
3570
- super(), this.object = n, this.domElement = a, this.domElement.style.touchAction = "none", this.enabled = !0, this.target = new J(), this.cursor = new J(), this.minDistance = 0, this.maxDistance = 1 / 0, this.minZoom = 0, this.maxZoom = 1 / 0, this.minTargetRadius = 0, this.maxTargetRadius = 1 / 0, this.minPolarAngle = 0, this.maxPolarAngle = Math.PI, this.minAzimuthAngle = -1 / 0, this.maxAzimuthAngle = 1 / 0, this.enableDamping = !1, this.dampingFactor = 0.05, this.enableZoom = !0, this.zoomSpeed = 1, this.enableRotate = !0, this.rotateSpeed = 1, this.enablePan = !0, this.panSpeed = 1, this.screenSpacePanning = !0, this.keyPanSpeed = 7, this.zoomToCursor = !1, this.autoRotate = !1, this.autoRotateSpeed = 2, this.keys = { LEFT: "ArrowLeft", UP: "ArrowUp", RIGHT: "ArrowRight", BOTTOM: "ArrowDown" }, this.mouseButtons = { LEFT: nt.ROTATE, MIDDLE: nt.DOLLY, RIGHT: nt.PAN }, this.touches = { ONE: at.ROTATE, TWO: at.DOLLY_PAN }, this.target0 = this.target.clone(), this.position0 = this.object.position.clone(), this.zoom0 = this.object.zoom, this._domElementKeyEvents = null, this.getPolarAngle = function() {
3581
+ super(), this.object = n, this.domElement = a, this.domElement.style.touchAction = "none", this.enabled = !0, this.target = new J(), this.cursor = new J(), this.minDistance = 0, this.maxDistance = 1 / 0, this.minZoom = 0, this.maxZoom = 1 / 0, this.minTargetRadius = 0, this.maxTargetRadius = 1 / 0, this.minPolarAngle = 0, this.maxPolarAngle = Math.PI, this.minAzimuthAngle = -1 / 0, this.maxAzimuthAngle = 1 / 0, this.enableDamping = !1, this.dampingFactor = 0.05, this.enableZoom = !0, this.zoomSpeed = 1, this.enableRotate = !0, this.rotateSpeed = 1, this.enablePan = !0, this.panSpeed = 1, this.screenSpacePanning = !0, this.keyPanSpeed = 7, this.zoomToCursor = !1, this.autoRotate = !1, this.autoRotateSpeed = 2, this.keys = { LEFT: "ArrowLeft", UP: "ArrowUp", RIGHT: "ArrowRight", BOTTOM: "ArrowDown" }, this.mouseButtons = { LEFT: it.ROTATE, MIDDLE: it.DOLLY, RIGHT: it.PAN }, this.touches = { ONE: rt.ROTATE, TWO: rt.DOLLY_PAN }, this.target0 = this.target.clone(), this.position0 = this.object.position.clone(), this.zoom0 = this.object.zoom, this._domElementKeyEvents = null, this.getPolarAngle = function() {
3571
3582
  return r.phi;
3572
3583
  }, this.getAzimuthalAngle = function() {
3573
3584
  return r.theta;
3574
3585
  }, this.getDistance = function() {
3575
3586
  return this.object.position.distanceTo(this.target);
3576
3587
  }, this.listenToKeyEvents = function(c) {
3577
- c.addEventListener("keydown", ot), this._domElementKeyEvents = c;
3588
+ c.addEventListener("keydown", lt), this._domElementKeyEvents = c;
3578
3589
  }, this.stopListenToKeyEvents = function() {
3579
- this._domElementKeyEvents.removeEventListener("keydown", ot), this._domElementKeyEvents = null;
3590
+ this._domElementKeyEvents.removeEventListener("keydown", lt), this._domElementKeyEvents = null;
3580
3591
  }, this.saveState = function() {
3581
3592
  t.target0.copy(t.target), t.position0.copy(t.object.position), t.zoom0 = t.object.zoom;
3582
3593
  }, this.reset = function() {
3583
3594
  t.target.copy(t.target0), t.object.position.copy(t.position0), t.object.zoom = t.zoom0, t.object.updateProjectionMatrix(), t.dispatchEvent(hn), t.update(), o = i.NONE;
3584
3595
  }, this.update = function() {
3585
- const c = new J(), E = new Zt().setFromUnitVectors(n.up, new J(0, 1, 0)), k = E.clone().invert(), B = new J(), ie = new Zt(), Ee = new J(), de = 2 * Math.PI;
3596
+ const c = new J(), x = new Xt().setFromUnitVectors(n.up, new J(0, 1, 0)), k = x.clone().invert(), L = new J(), re = new Xt(), xe = new J(), de = 2 * Math.PI;
3586
3597
  return function(vt = null) {
3587
3598
  const bt = t.object.position;
3588
- c.copy(bt).sub(t.target), c.applyQuaternion(E), r.setFromVector3(c), t.autoRotate && o === i.NONE && be(_e(vt)), t.enableDamping ? (r.theta += h.theta * t.dampingFactor, r.phi += h.phi * t.dampingFactor) : (r.theta += h.theta, r.phi += h.phi);
3589
- let xe = t.minAzimuthAngle, Se = t.maxAzimuthAngle;
3590
- isFinite(xe) && isFinite(Se) && (xe < -Math.PI ? xe += de : xe > Math.PI && (xe -= de), Se < -Math.PI ? Se += de : Se > Math.PI && (Se -= de), xe <= Se ? r.theta = Math.max(xe, Math.min(Se, r.theta)) : r.theta = r.theta > (xe + Se) / 2 ? Math.max(xe, r.theta) : Math.min(Se, r.theta)), r.phi = Math.max(t.minPolarAngle, Math.min(t.maxPolarAngle, r.phi)), r.makeSafe(), t.enableDamping === !0 ? t.target.addScaledVector(f, t.dampingFactor) : t.target.add(f), t.target.sub(t.cursor), t.target.clampLength(t.minTargetRadius, t.maxTargetRadius), t.target.add(t.cursor);
3591
- let Ve = !1;
3592
- if (t.zoomToCursor && pe || t.object.isOrthographicCamera)
3599
+ c.copy(bt).sub(t.target), c.applyQuaternion(x), r.setFromVector3(c), t.autoRotate && o === i.NONE && ye(_e(vt)), t.enableDamping ? (r.theta += h.theta * t.dampingFactor, r.phi += h.phi * t.dampingFactor) : (r.theta += h.theta, r.phi += h.phi);
3600
+ let Se = t.minAzimuthAngle, Ce = t.maxAzimuthAngle;
3601
+ isFinite(Se) && isFinite(Ce) && (Se < -Math.PI ? Se += de : Se > Math.PI && (Se -= de), Ce < -Math.PI ? Ce += de : Ce > Math.PI && (Ce -= de), Se <= Ce ? r.theta = Math.max(Se, Math.min(Ce, r.theta)) : r.theta = r.theta > (Se + Ce) / 2 ? Math.max(Se, r.theta) : Math.min(Ce, r.theta)), r.phi = Math.max(t.minPolarAngle, Math.min(t.maxPolarAngle, r.phi)), r.makeSafe(), t.enableDamping === !0 ? t.target.addScaledVector(f, t.dampingFactor) : t.target.add(f), t.target.sub(t.cursor), t.target.clampLength(t.minTargetRadius, t.maxTargetRadius), t.target.add(t.cursor);
3602
+ let Xe = !1;
3603
+ if (t.zoomToCursor && ge || t.object.isOrthographicCamera)
3593
3604
  r.radius = Ae(r.radius);
3594
3605
  else {
3595
3606
  const Oe = r.radius;
3596
- r.radius = Ae(r.radius * u), Ve = Oe != r.radius;
3607
+ r.radius = Ae(r.radius * u), Xe = Oe != r.radius;
3597
3608
  }
3598
- if (c.setFromSpherical(r), c.applyQuaternion(k), bt.copy(t.target).add(c), t.object.lookAt(t.target), t.enableDamping === !0 ? (h.theta *= 1 - t.dampingFactor, h.phi *= 1 - t.dampingFactor, f.multiplyScalar(1 - t.dampingFactor)) : (h.set(0, 0, 0), f.set(0, 0, 0)), t.zoomToCursor && pe) {
3609
+ if (c.setFromSpherical(r), c.applyQuaternion(k), bt.copy(t.target).add(c), t.object.lookAt(t.target), t.enableDamping === !0 ? (h.theta *= 1 - t.dampingFactor, h.phi *= 1 - t.dampingFactor, f.multiplyScalar(1 - t.dampingFactor)) : (h.set(0, 0, 0), f.set(0, 0, 0)), t.zoomToCursor && ge) {
3599
3610
  let Oe = null;
3600
3611
  if (t.object.isPerspectiveCamera) {
3601
- const ze = c.length();
3602
- Oe = Ae(ze * u);
3603
- const et = ze - Oe;
3604
- t.object.position.addScaledVector(Z, et), t.object.updateMatrixWorld(), Ve = !!et;
3612
+ const He = c.length();
3613
+ Oe = Ae(He * u);
3614
+ const nt = He - Oe;
3615
+ t.object.position.addScaledVector(X, nt), t.object.updateMatrixWorld(), Xe = !!nt;
3605
3616
  } else if (t.object.isOrthographicCamera) {
3606
- const ze = new J(te.x, te.y, 0);
3607
- ze.unproject(t.object);
3608
- const et = t.object.zoom;
3609
- t.object.zoom = Math.max(t.minZoom, Math.min(t.maxZoom, t.object.zoom / u)), t.object.updateProjectionMatrix(), Ve = et !== t.object.zoom;
3610
- const yt = new J(te.x, te.y, 0);
3611
- yt.unproject(t.object), t.object.position.sub(yt).add(ze), t.object.updateMatrixWorld(), Oe = c.length();
3617
+ const He = new J(ne.x, ne.y, 0);
3618
+ He.unproject(t.object);
3619
+ const nt = t.object.zoom;
3620
+ t.object.zoom = Math.max(t.minZoom, Math.min(t.maxZoom, t.object.zoom / u)), t.object.updateProjectionMatrix(), Xe = nt !== t.object.zoom;
3621
+ const yt = new J(ne.x, ne.y, 0);
3622
+ yt.unproject(t.object), t.object.position.sub(yt).add(He), t.object.updateMatrixWorld(), Oe = c.length();
3612
3623
  } else
3613
3624
  console.warn("WARNING: OrbitControls.js encountered an unknown camera type - zoom to cursor disabled."), t.zoomToCursor = !1;
3614
- Oe !== null && (this.screenSpacePanning ? t.target.set(0, 0, -1).transformDirection(t.object.matrix).multiplyScalar(Oe).add(t.object.position) : (Et.origin.copy(t.object.position), Et.direction.set(0, 0, -1).transformDirection(t.object.matrix), Math.abs(t.object.up.dot(Et.direction)) < Ei ? n.lookAt(t.target) : (mn.setFromNormalAndCoplanarPoint(t.object.up, t.target), Et.intersectPlane(mn, t.target))));
3625
+ Oe !== null && (this.screenSpacePanning ? t.target.set(0, 0, -1).transformDirection(t.object.matrix).multiplyScalar(Oe).add(t.object.position) : (Et.origin.copy(t.object.position), Et.direction.set(0, 0, -1).transformDirection(t.object.matrix), Math.abs(t.object.up.dot(Et.direction)) < yi ? n.lookAt(t.target) : (mn.setFromNormalAndCoplanarPoint(t.object.up, t.target), Et.intersectPlane(mn, t.target))));
3615
3626
  } else if (t.object.isOrthographicCamera) {
3616
3627
  const Oe = t.object.zoom;
3617
- t.object.zoom = Math.max(t.minZoom, Math.min(t.maxZoom, t.object.zoom / u)), Oe !== t.object.zoom && (t.object.updateProjectionMatrix(), Ve = !0);
3628
+ t.object.zoom = Math.max(t.minZoom, Math.min(t.maxZoom, t.object.zoom / u)), Oe !== t.object.zoom && (t.object.updateProjectionMatrix(), Xe = !0);
3618
3629
  }
3619
- return u = 1, pe = !1, Ve || B.distanceToSquared(t.object.position) > d || 8 * (1 - ie.dot(t.object.quaternion)) > d || Ee.distanceToSquared(t.target) > d ? (t.dispatchEvent(hn), B.copy(t.object.position), ie.copy(t.object.quaternion), Ee.copy(t.target), !0) : !1;
3630
+ return u = 1, ge = !1, Xe || L.distanceToSquared(t.object.position) > d || 8 * (1 - re.dot(t.object.quaternion)) > d || xe.distanceToSquared(t.target) > d ? (t.dispatchEvent(hn), L.copy(t.object.position), re.copy(t.object.quaternion), xe.copy(t.target), !0) : !1;
3620
3631
  };
3621
3632
  }(), this.dispose = function() {
3622
- t.domElement.removeEventListener("contextmenu", Qe), t.domElement.removeEventListener("pointerdown", _), t.domElement.removeEventListener("pointercancel", K), t.domElement.removeEventListener("wheel", ft), t.domElement.removeEventListener("pointermove", z), t.domElement.removeEventListener("pointerup", K), t.domElement.getRootNode().removeEventListener("keydown", st, { capture: !0 }), t._domElementKeyEvents !== null && (t._domElementKeyEvents.removeEventListener("keydown", ot), t._domElementKeyEvents = null);
3633
+ t.domElement.removeEventListener("contextmenu", tt), t.domElement.removeEventListener("pointerdown", S), t.domElement.removeEventListener("pointercancel", Z), t.domElement.removeEventListener("wheel", Q), t.domElement.removeEventListener("pointermove", G), t.domElement.removeEventListener("pointerup", Z), t.domElement.getRootNode().removeEventListener("keydown", ze, { capture: !0 }), t._domElementKeyEvents !== null && (t._domElementKeyEvents.removeEventListener("keydown", lt), t._domElementKeyEvents = null);
3623
3634
  };
3624
3635
  const t = this, i = {
3625
3636
  NONE: -1,
@@ -3632,257 +3643,257 @@ class xi extends pn {
3632
3643
  TOUCH_DOLLY_ROTATE: 6
3633
3644
  };
3634
3645
  let o = i.NONE;
3635
- const d = 1e-6, r = new Jt(), h = new Jt();
3646
+ const d = 1e-6, r = new Zt(), h = new Zt();
3636
3647
  let u = 1;
3637
- const f = new J(), m = new me(), v = new me(), S = new me(), A = new me(), F = new me(), V = new me(), R = new me(), I = new me(), T = new me(), Z = new J(), te = new me();
3638
- let pe = !1;
3639
- const q = [], ge = {};
3640
- let ce = !1;
3648
+ const f = new J(), m = new pe(), b = new pe(), E = new pe(), D = new pe(), $ = new pe(), z = new pe(), B = new pe(), C = new pe(), T = new pe(), X = new J(), ne = new pe();
3649
+ let ge = !1;
3650
+ const q = [], ve = {};
3651
+ let le = !1;
3641
3652
  function _e(c) {
3642
3653
  return c !== null ? 2 * Math.PI / 60 * t.autoRotateSpeed * c : 2 * Math.PI / 60 / 60 * t.autoRotateSpeed;
3643
3654
  }
3644
3655
  function ke(c) {
3645
- const E = Math.abs(c * 0.01);
3646
- return Math.pow(0.95, t.zoomSpeed * E);
3656
+ const x = Math.abs(c * 0.01);
3657
+ return Math.pow(0.95, t.zoomSpeed * x);
3647
3658
  }
3648
- function be(c) {
3659
+ function ye(c) {
3649
3660
  h.theta -= c;
3650
3661
  }
3651
- function U(c) {
3662
+ function F(c) {
3652
3663
  h.phi -= c;
3653
3664
  }
3654
- const ye = function() {
3665
+ const Ee = function() {
3655
3666
  const c = new J();
3656
- return function(k, B) {
3657
- c.setFromMatrixColumn(B, 0), c.multiplyScalar(-k), f.add(c);
3667
+ return function(k, L) {
3668
+ c.setFromMatrixColumn(L, 0), c.multiplyScalar(-k), f.add(c);
3658
3669
  };
3659
- }(), O = function() {
3670
+ }(), R = function() {
3660
3671
  const c = new J();
3661
- return function(k, B) {
3662
- t.screenSpacePanning === !0 ? c.setFromMatrixColumn(B, 1) : (c.setFromMatrixColumn(B, 0), c.crossVectors(t.object.up, c)), c.multiplyScalar(k), f.add(c);
3672
+ return function(k, L) {
3673
+ t.screenSpacePanning === !0 ? c.setFromMatrixColumn(L, 1) : (c.setFromMatrixColumn(L, 0), c.crossVectors(t.object.up, c)), c.multiplyScalar(k), f.add(c);
3663
3674
  };
3664
- }(), we = function() {
3675
+ }(), Me = function() {
3665
3676
  const c = new J();
3666
- return function(k, B) {
3667
- const ie = t.domElement;
3677
+ return function(k, L) {
3678
+ const re = t.domElement;
3668
3679
  if (t.object.isPerspectiveCamera) {
3669
- const Ee = t.object.position;
3670
- c.copy(Ee).sub(t.target);
3680
+ const xe = t.object.position;
3681
+ c.copy(xe).sub(t.target);
3671
3682
  let de = c.length();
3672
- de *= Math.tan(t.object.fov / 2 * Math.PI / 180), ye(2 * k * de / ie.clientHeight, t.object.matrix), O(2 * B * de / ie.clientHeight, t.object.matrix);
3683
+ de *= Math.tan(t.object.fov / 2 * Math.PI / 180), Ee(2 * k * de / re.clientHeight, t.object.matrix), R(2 * L * de / re.clientHeight, t.object.matrix);
3673
3684
  } else
3674
- t.object.isOrthographicCamera ? (ye(k * (t.object.right - t.object.left) / t.object.zoom / ie.clientWidth, t.object.matrix), O(B * (t.object.top - t.object.bottom) / t.object.zoom / ie.clientHeight, t.object.matrix)) : (console.warn("WARNING: OrbitControls.js encountered an unknown camera type - pan disabled."), t.enablePan = !1);
3685
+ t.object.isOrthographicCamera ? (Ee(k * (t.object.right - t.object.left) / t.object.zoom / re.clientWidth, t.object.matrix), R(L * (t.object.top - t.object.bottom) / t.object.zoom / re.clientHeight, t.object.matrix)) : (console.warn("WARNING: OrbitControls.js encountered an unknown camera type - pan disabled."), t.enablePan = !1);
3675
3686
  };
3676
3687
  }();
3677
3688
  function De(c) {
3678
3689
  t.object.isPerspectiveCamera || t.object.isOrthographicCamera ? u /= c : (console.warn("WARNING: OrbitControls.js encountered an unknown camera type - dolly/zoom disabled."), t.enableZoom = !1);
3679
3690
  }
3680
- function je(c) {
3691
+ function Ie(c) {
3681
3692
  t.object.isPerspectiveCamera || t.object.isOrthographicCamera ? u *= c : (console.warn("WARNING: OrbitControls.js encountered an unknown camera type - dolly/zoom disabled."), t.enableZoom = !1);
3682
3693
  }
3683
- function Pe(c, E) {
3694
+ function Pe(c, x) {
3684
3695
  if (!t.zoomToCursor)
3685
3696
  return;
3686
- pe = !0;
3687
- const k = t.domElement.getBoundingClientRect(), B = c - k.left, ie = E - k.top, Ee = k.width, de = k.height;
3688
- te.x = B / Ee * 2 - 1, te.y = -(ie / de) * 2 + 1, Z.set(te.x, te.y, 1).unproject(t.object).sub(t.object.position).normalize();
3697
+ ge = !0;
3698
+ const k = t.domElement.getBoundingClientRect(), L = c - k.left, re = x - k.top, xe = k.width, de = k.height;
3699
+ ne.x = L / xe * 2 - 1, ne.y = -(re / de) * 2 + 1, X.set(ne.x, ne.y, 1).unproject(t.object).sub(t.object.position).normalize();
3689
3700
  }
3690
3701
  function Ae(c) {
3691
3702
  return Math.max(t.minDistance, Math.min(t.maxDistance, c));
3692
3703
  }
3693
- function Ie(c) {
3704
+ function je(c) {
3694
3705
  m.set(c.clientX, c.clientY);
3695
3706
  }
3696
- function Be(c) {
3697
- Pe(c.clientX, c.clientX), R.set(c.clientX, c.clientY);
3707
+ function qe(c) {
3708
+ Pe(c.clientX, c.clientX), B.set(c.clientX, c.clientY);
3698
3709
  }
3699
- function Fe(c) {
3700
- A.set(c.clientX, c.clientY);
3710
+ function Ne(c) {
3711
+ D.set(c.clientX, c.clientY);
3701
3712
  }
3702
- function re(c) {
3703
- v.set(c.clientX, c.clientY), S.subVectors(v, m).multiplyScalar(t.rotateSpeed);
3704
- const E = t.domElement;
3705
- be(2 * Math.PI * S.x / E.clientHeight), U(2 * Math.PI * S.y / E.clientHeight), m.copy(v), t.update();
3713
+ function Ke(c) {
3714
+ b.set(c.clientX, c.clientY), E.subVectors(b, m).multiplyScalar(t.rotateSpeed);
3715
+ const x = t.domElement;
3716
+ ye(2 * Math.PI * E.x / x.clientHeight), F(2 * Math.PI * E.y / x.clientHeight), m.copy(b), t.update();
3706
3717
  }
3707
- function Me(c) {
3708
- I.set(c.clientX, c.clientY), T.subVectors(I, R), T.y > 0 ? De(ke(T.y)) : T.y < 0 && je(ke(T.y)), R.copy(I), t.update();
3718
+ function ct(c) {
3719
+ C.set(c.clientX, c.clientY), T.subVectors(C, B), T.y > 0 ? De(ke(T.y)) : T.y < 0 && Ie(ke(T.y)), B.copy(C), t.update();
3709
3720
  }
3710
- function He(c) {
3711
- F.set(c.clientX, c.clientY), V.subVectors(F, A).multiplyScalar(t.panSpeed), we(V.x, V.y), A.copy(F), t.update();
3721
+ function Le(c) {
3722
+ $.set(c.clientX, c.clientY), z.subVectors($, D).multiplyScalar(t.panSpeed), Me(z.x, z.y), D.copy($), t.update();
3712
3723
  }
3713
- function Ye(c) {
3714
- Pe(c.clientX, c.clientY), c.deltaY < 0 ? je(ke(c.deltaY)) : c.deltaY > 0 && De(ke(c.deltaY)), t.update();
3724
+ function ae(c) {
3725
+ Pe(c.clientX, c.clientY), c.deltaY < 0 ? Ie(ke(c.deltaY)) : c.deltaY > 0 && De(ke(c.deltaY)), t.update();
3715
3726
  }
3716
- function ue(c) {
3717
- let E = !1;
3727
+ function fe(c) {
3728
+ let x = !1;
3718
3729
  switch (c.code) {
3719
3730
  case t.keys.UP:
3720
- c.ctrlKey || c.metaKey || c.shiftKey ? U(2 * Math.PI * t.rotateSpeed / t.domElement.clientHeight) : we(0, t.keyPanSpeed), E = !0;
3731
+ c.ctrlKey || c.metaKey || c.shiftKey ? F(2 * Math.PI * t.rotateSpeed / t.domElement.clientHeight) : Me(0, t.keyPanSpeed), x = !0;
3721
3732
  break;
3722
3733
  case t.keys.BOTTOM:
3723
- c.ctrlKey || c.metaKey || c.shiftKey ? U(-2 * Math.PI * t.rotateSpeed / t.domElement.clientHeight) : we(0, -t.keyPanSpeed), E = !0;
3734
+ c.ctrlKey || c.metaKey || c.shiftKey ? F(-2 * Math.PI * t.rotateSpeed / t.domElement.clientHeight) : Me(0, -t.keyPanSpeed), x = !0;
3724
3735
  break;
3725
3736
  case t.keys.LEFT:
3726
- c.ctrlKey || c.metaKey || c.shiftKey ? be(2 * Math.PI * t.rotateSpeed / t.domElement.clientHeight) : we(t.keyPanSpeed, 0), E = !0;
3737
+ c.ctrlKey || c.metaKey || c.shiftKey ? ye(2 * Math.PI * t.rotateSpeed / t.domElement.clientHeight) : Me(t.keyPanSpeed, 0), x = !0;
3727
3738
  break;
3728
3739
  case t.keys.RIGHT:
3729
- c.ctrlKey || c.metaKey || c.shiftKey ? be(-2 * Math.PI * t.rotateSpeed / t.domElement.clientHeight) : we(-t.keyPanSpeed, 0), E = !0;
3740
+ c.ctrlKey || c.metaKey || c.shiftKey ? ye(-2 * Math.PI * t.rotateSpeed / t.domElement.clientHeight) : Me(-t.keyPanSpeed, 0), x = !0;
3730
3741
  break;
3731
3742
  }
3732
- E && (c.preventDefault(), t.update());
3743
+ x && (c.preventDefault(), t.update());
3733
3744
  }
3734
- function g(c) {
3745
+ function Ue(c) {
3735
3746
  if (q.length === 1)
3736
3747
  m.set(c.pageX, c.pageY);
3737
3748
  else {
3738
- const E = $e(c), k = 0.5 * (c.pageX + E.x), B = 0.5 * (c.pageY + E.y);
3739
- m.set(k, B);
3749
+ const x = We(c), k = 0.5 * (c.pageX + x.x), L = 0.5 * (c.pageY + x.y);
3750
+ m.set(k, L);
3740
3751
  }
3741
3752
  }
3742
- function b(c) {
3753
+ function Be(c) {
3743
3754
  if (q.length === 1)
3744
- A.set(c.pageX, c.pageY);
3755
+ D.set(c.pageX, c.pageY);
3745
3756
  else {
3746
- const E = $e(c), k = 0.5 * (c.pageX + E.x), B = 0.5 * (c.pageY + E.y);
3747
- A.set(k, B);
3757
+ const x = We(c), k = 0.5 * (c.pageX + x.x), L = 0.5 * (c.pageY + x.y);
3758
+ D.set(k, L);
3748
3759
  }
3749
3760
  }
3750
- function M(c) {
3751
- const E = $e(c), k = c.pageX - E.x, B = c.pageY - E.y, ie = Math.sqrt(k * k + B * B);
3752
- R.set(0, ie);
3761
+ function be(c) {
3762
+ const x = We(c), k = c.pageX - x.x, L = c.pageY - x.y, re = Math.sqrt(k * k + L * L);
3763
+ B.set(0, re);
3753
3764
  }
3754
- function N(c) {
3755
- t.enableZoom && M(c), t.enablePan && b(c);
3765
+ function g(c) {
3766
+ t.enableZoom && be(c), t.enablePan && Be(c);
3756
3767
  }
3757
- function ve(c) {
3758
- t.enableZoom && M(c), t.enableRotate && g(c);
3768
+ function v(c) {
3769
+ t.enableZoom && be(c), t.enableRotate && Ue(c);
3759
3770
  }
3760
- function le(c) {
3771
+ function M(c) {
3761
3772
  if (q.length == 1)
3762
- v.set(c.pageX, c.pageY);
3773
+ b.set(c.pageX, c.pageY);
3763
3774
  else {
3764
- const k = $e(c), B = 0.5 * (c.pageX + k.x), ie = 0.5 * (c.pageY + k.y);
3765
- v.set(B, ie);
3775
+ const k = We(c), L = 0.5 * (c.pageX + k.x), re = 0.5 * (c.pageY + k.y);
3776
+ b.set(L, re);
3766
3777
  }
3767
- S.subVectors(v, m).multiplyScalar(t.rotateSpeed);
3768
- const E = t.domElement;
3769
- be(2 * Math.PI * S.x / E.clientHeight), U(2 * Math.PI * S.y / E.clientHeight), m.copy(v);
3778
+ E.subVectors(b, m).multiplyScalar(t.rotateSpeed);
3779
+ const x = t.domElement;
3780
+ ye(2 * Math.PI * E.x / x.clientHeight), F(2 * Math.PI * E.y / x.clientHeight), m.copy(b);
3770
3781
  }
3771
- function C(c) {
3782
+ function j(c) {
3772
3783
  if (q.length === 1)
3773
- F.set(c.pageX, c.pageY);
3784
+ $.set(c.pageX, c.pageY);
3774
3785
  else {
3775
- const E = $e(c), k = 0.5 * (c.pageX + E.x), B = 0.5 * (c.pageY + E.y);
3776
- F.set(k, B);
3786
+ const x = We(c), k = 0.5 * (c.pageX + x.x), L = 0.5 * (c.pageY + x.y);
3787
+ $.set(k, L);
3777
3788
  }
3778
- V.subVectors(F, A).multiplyScalar(t.panSpeed), we(V.x, V.y), A.copy(F);
3789
+ z.subVectors($, D).multiplyScalar(t.panSpeed), Me(z.x, z.y), D.copy($);
3779
3790
  }
3780
- function x(c) {
3781
- const E = $e(c), k = c.pageX - E.x, B = c.pageY - E.y, ie = Math.sqrt(k * k + B * B);
3782
- I.set(0, ie), T.set(0, Math.pow(I.y / R.y, t.zoomSpeed)), De(T.y), R.copy(I);
3783
- const Ee = (c.pageX + E.x) * 0.5, de = (c.pageY + E.y) * 0.5;
3784
- Pe(Ee, de);
3791
+ function oe(c) {
3792
+ const x = We(c), k = c.pageX - x.x, L = c.pageY - x.y, re = Math.sqrt(k * k + L * L);
3793
+ C.set(0, re), T.set(0, Math.pow(C.y / B.y, t.zoomSpeed)), De(T.y), B.copy(C);
3794
+ const xe = (c.pageX + x.x) * 0.5, de = (c.pageY + x.y) * 0.5;
3795
+ Pe(xe, de);
3785
3796
  }
3786
- function G(c) {
3787
- t.enableZoom && x(c), t.enablePan && C(c);
3797
+ function ue(c) {
3798
+ t.enableZoom && oe(c), t.enablePan && j(c);
3788
3799
  }
3789
- function ne(c) {
3790
- t.enableZoom && x(c), t.enableRotate && le(c);
3800
+ function O(c) {
3801
+ t.enableZoom && oe(c), t.enableRotate && M(c);
3791
3802
  }
3792
- function _(c) {
3793
- t.enabled !== !1 && (q.length === 0 && (t.domElement.setPointerCapture(c.pointerId), t.domElement.addEventListener("pointermove", z), t.domElement.addEventListener("pointerup", K)), !Pt(c) && (kt(c), c.pointerType === "touch" ? ct(c) : Ne(c)));
3803
+ function S(c) {
3804
+ t.enabled !== !1 && (q.length === 0 && (t.domElement.setPointerCapture(c.pointerId), t.domElement.addEventListener("pointermove", G), t.domElement.addEventListener("pointerup", Z)), !Dt(c) && (_t(c), c.pointerType === "touch" ? ut(c) : _(c)));
3794
3805
  }
3795
- function z(c) {
3796
- t.enabled !== !1 && (c.pointerType === "touch" ? pt(c) : Je(c));
3806
+ function G(c) {
3807
+ t.enabled !== !1 && (c.pointerType === "touch" ? pt(c) : Y(c));
3797
3808
  }
3798
- function K(c) {
3799
- switch (Dt(c), q.length) {
3809
+ function Z(c) {
3810
+ switch (kt(c), q.length) {
3800
3811
  case 0:
3801
- t.domElement.releasePointerCapture(c.pointerId), t.domElement.removeEventListener("pointermove", z), t.domElement.removeEventListener("pointerup", K), t.dispatchEvent(fn), o = i.NONE;
3812
+ t.domElement.releasePointerCapture(c.pointerId), t.domElement.removeEventListener("pointermove", G), t.domElement.removeEventListener("pointerup", Z), t.dispatchEvent(fn), o = i.NONE;
3802
3813
  break;
3803
3814
  case 1:
3804
- const E = q[0], k = ge[E];
3805
- ct({ pointerId: E, pageX: k.x, pageY: k.y });
3815
+ const x = q[0], k = ve[x];
3816
+ ut({ pointerId: x, pageX: k.x, pageY: k.y });
3806
3817
  break;
3807
3818
  }
3808
3819
  }
3809
- function Ne(c) {
3810
- let E;
3820
+ function _(c) {
3821
+ let x;
3811
3822
  switch (c.button) {
3812
3823
  case 0:
3813
- E = t.mouseButtons.LEFT;
3824
+ x = t.mouseButtons.LEFT;
3814
3825
  break;
3815
3826
  case 1:
3816
- E = t.mouseButtons.MIDDLE;
3827
+ x = t.mouseButtons.MIDDLE;
3817
3828
  break;
3818
3829
  case 2:
3819
- E = t.mouseButtons.RIGHT;
3830
+ x = t.mouseButtons.RIGHT;
3820
3831
  break;
3821
3832
  default:
3822
- E = -1;
3833
+ x = -1;
3823
3834
  }
3824
- switch (E) {
3825
- case nt.DOLLY:
3835
+ switch (x) {
3836
+ case it.DOLLY:
3826
3837
  if (t.enableZoom === !1)
3827
3838
  return;
3828
- Be(c), o = i.DOLLY;
3839
+ qe(c), o = i.DOLLY;
3829
3840
  break;
3830
- case nt.ROTATE:
3841
+ case it.ROTATE:
3831
3842
  if (c.ctrlKey || c.metaKey || c.shiftKey) {
3832
3843
  if (t.enablePan === !1)
3833
3844
  return;
3834
- Fe(c), o = i.PAN;
3845
+ Ne(c), o = i.PAN;
3835
3846
  } else {
3836
3847
  if (t.enableRotate === !1)
3837
3848
  return;
3838
- Ie(c), o = i.ROTATE;
3849
+ je(c), o = i.ROTATE;
3839
3850
  }
3840
3851
  break;
3841
- case nt.PAN:
3852
+ case it.PAN:
3842
3853
  if (c.ctrlKey || c.metaKey || c.shiftKey) {
3843
3854
  if (t.enableRotate === !1)
3844
3855
  return;
3845
- Ie(c), o = i.ROTATE;
3856
+ je(c), o = i.ROTATE;
3846
3857
  } else {
3847
3858
  if (t.enablePan === !1)
3848
3859
  return;
3849
- Fe(c), o = i.PAN;
3860
+ Ne(c), o = i.PAN;
3850
3861
  }
3851
3862
  break;
3852
3863
  default:
3853
3864
  o = i.NONE;
3854
3865
  }
3855
- o !== i.NONE && t.dispatchEvent(It);
3866
+ o !== i.NONE && t.dispatchEvent(jt);
3856
3867
  }
3857
- function Je(c) {
3868
+ function Y(c) {
3858
3869
  switch (o) {
3859
3870
  case i.ROTATE:
3860
3871
  if (t.enableRotate === !1)
3861
3872
  return;
3862
- re(c);
3873
+ Ke(c);
3863
3874
  break;
3864
3875
  case i.DOLLY:
3865
3876
  if (t.enableZoom === !1)
3866
3877
  return;
3867
- Me(c);
3878
+ ct(c);
3868
3879
  break;
3869
3880
  case i.PAN:
3870
3881
  if (t.enablePan === !1)
3871
3882
  return;
3872
- He(c);
3883
+ Le(c);
3873
3884
  break;
3874
3885
  }
3875
3886
  }
3876
- function ft(c) {
3877
- t.enabled === !1 || t.enableZoom === !1 || o !== i.NONE || (c.preventDefault(), t.dispatchEvent(It), Ye(mt(c)), t.dispatchEvent(fn));
3887
+ function Q(c) {
3888
+ t.enabled === !1 || t.enableZoom === !1 || o !== i.NONE || (c.preventDefault(), t.dispatchEvent(jt), ae($e(c)), t.dispatchEvent(fn));
3878
3889
  }
3879
- function mt(c) {
3880
- const E = c.deltaMode, k = {
3890
+ function $e(c) {
3891
+ const x = c.deltaMode, k = {
3881
3892
  clientX: c.clientX,
3882
3893
  clientY: c.clientY,
3883
3894
  deltaY: c.deltaY
3884
3895
  };
3885
- switch (E) {
3896
+ switch (x) {
3886
3897
  case 1:
3887
3898
  k.deltaY *= 16;
3888
3899
  break;
@@ -3890,30 +3901,30 @@ class xi extends pn {
3890
3901
  k.deltaY *= 100;
3891
3902
  break;
3892
3903
  }
3893
- return c.ctrlKey && !ce && (k.deltaY *= 10), k;
3904
+ return c.ctrlKey && !le && (k.deltaY *= 10), k;
3894
3905
  }
3895
- function st(c) {
3896
- c.key === "Control" && (ce = !0, t.domElement.getRootNode().addEventListener("keyup", Ue, { passive: !0, capture: !0 }));
3906
+ function ze(c) {
3907
+ c.key === "Control" && (le = !0, t.domElement.getRootNode().addEventListener("keyup", Ge, { passive: !0, capture: !0 }));
3897
3908
  }
3898
- function Ue(c) {
3899
- c.key === "Control" && (ce = !1, t.domElement.getRootNode().removeEventListener("keyup", Ue, { passive: !0, capture: !0 }));
3909
+ function Ge(c) {
3910
+ c.key === "Control" && (le = !1, t.domElement.getRootNode().removeEventListener("keyup", Ge, { passive: !0, capture: !0 }));
3900
3911
  }
3901
- function ot(c) {
3902
- t.enabled === !1 || t.enablePan === !1 || ue(c);
3912
+ function lt(c) {
3913
+ t.enabled === !1 || t.enablePan === !1 || fe(c);
3903
3914
  }
3904
- function ct(c) {
3915
+ function ut(c) {
3905
3916
  switch (gt(c), q.length) {
3906
3917
  case 1:
3907
3918
  switch (t.touches.ONE) {
3908
- case at.ROTATE:
3919
+ case rt.ROTATE:
3909
3920
  if (t.enableRotate === !1)
3910
3921
  return;
3911
- g(c), o = i.TOUCH_ROTATE;
3922
+ Ue(c), o = i.TOUCH_ROTATE;
3912
3923
  break;
3913
- case at.PAN:
3924
+ case rt.PAN:
3914
3925
  if (t.enablePan === !1)
3915
3926
  return;
3916
- b(c), o = i.TOUCH_PAN;
3927
+ Be(c), o = i.TOUCH_PAN;
3917
3928
  break;
3918
3929
  default:
3919
3930
  o = i.NONE;
@@ -3921,15 +3932,15 @@ class xi extends pn {
3921
3932
  break;
3922
3933
  case 2:
3923
3934
  switch (t.touches.TWO) {
3924
- case at.DOLLY_PAN:
3935
+ case rt.DOLLY_PAN:
3925
3936
  if (t.enableZoom === !1 && t.enablePan === !1)
3926
3937
  return;
3927
- N(c), o = i.TOUCH_DOLLY_PAN;
3938
+ g(c), o = i.TOUCH_DOLLY_PAN;
3928
3939
  break;
3929
- case at.DOLLY_ROTATE:
3940
+ case rt.DOLLY_ROTATE:
3930
3941
  if (t.enableZoom === !1 && t.enableRotate === !1)
3931
3942
  return;
3932
- ve(c), o = i.TOUCH_DOLLY_ROTATE;
3943
+ v(c), o = i.TOUCH_DOLLY_ROTATE;
3933
3944
  break;
3934
3945
  default:
3935
3946
  o = i.NONE;
@@ -3938,70 +3949,70 @@ class xi extends pn {
3938
3949
  default:
3939
3950
  o = i.NONE;
3940
3951
  }
3941
- o !== i.NONE && t.dispatchEvent(It);
3952
+ o !== i.NONE && t.dispatchEvent(jt);
3942
3953
  }
3943
3954
  function pt(c) {
3944
3955
  switch (gt(c), o) {
3945
3956
  case i.TOUCH_ROTATE:
3946
3957
  if (t.enableRotate === !1)
3947
3958
  return;
3948
- le(c), t.update();
3959
+ M(c), t.update();
3949
3960
  break;
3950
3961
  case i.TOUCH_PAN:
3951
3962
  if (t.enablePan === !1)
3952
3963
  return;
3953
- C(c), t.update();
3964
+ j(c), t.update();
3954
3965
  break;
3955
3966
  case i.TOUCH_DOLLY_PAN:
3956
3967
  if (t.enableZoom === !1 && t.enablePan === !1)
3957
3968
  return;
3958
- G(c), t.update();
3969
+ ue(c), t.update();
3959
3970
  break;
3960
3971
  case i.TOUCH_DOLLY_ROTATE:
3961
3972
  if (t.enableZoom === !1 && t.enableRotate === !1)
3962
3973
  return;
3963
- ne(c), t.update();
3974
+ O(c), t.update();
3964
3975
  break;
3965
3976
  default:
3966
3977
  o = i.NONE;
3967
3978
  }
3968
3979
  }
3969
- function Qe(c) {
3980
+ function tt(c) {
3970
3981
  t.enabled !== !1 && c.preventDefault();
3971
3982
  }
3972
- function kt(c) {
3983
+ function _t(c) {
3973
3984
  q.push(c.pointerId);
3974
3985
  }
3975
- function Dt(c) {
3976
- delete ge[c.pointerId];
3977
- for (let E = 0; E < q.length; E++)
3978
- if (q[E] == c.pointerId) {
3979
- q.splice(E, 1);
3986
+ function kt(c) {
3987
+ delete ve[c.pointerId];
3988
+ for (let x = 0; x < q.length; x++)
3989
+ if (q[x] == c.pointerId) {
3990
+ q.splice(x, 1);
3980
3991
  return;
3981
3992
  }
3982
3993
  }
3983
- function Pt(c) {
3984
- for (let E = 0; E < q.length; E++)
3985
- if (q[E] == c.pointerId)
3994
+ function Dt(c) {
3995
+ for (let x = 0; x < q.length; x++)
3996
+ if (q[x] == c.pointerId)
3986
3997
  return !0;
3987
3998
  return !1;
3988
3999
  }
3989
4000
  function gt(c) {
3990
- let E = ge[c.pointerId];
3991
- E === void 0 && (E = new me(), ge[c.pointerId] = E), E.set(c.pageX, c.pageY);
4001
+ let x = ve[c.pointerId];
4002
+ x === void 0 && (x = new pe(), ve[c.pointerId] = x), x.set(c.pageX, c.pageY);
3992
4003
  }
3993
- function $e(c) {
3994
- const E = c.pointerId === q[0] ? q[1] : q[0];
3995
- return ge[E];
4004
+ function We(c) {
4005
+ const x = c.pointerId === q[0] ? q[1] : q[0];
4006
+ return ve[x];
3996
4007
  }
3997
- t.domElement.addEventListener("contextmenu", Qe), t.domElement.addEventListener("pointerdown", _), t.domElement.addEventListener("pointercancel", K), t.domElement.addEventListener("wheel", ft, { passive: !1 }), t.domElement.getRootNode().addEventListener("keydown", st, { passive: !0, capture: !0 }), this.update();
4008
+ t.domElement.addEventListener("contextmenu", tt), t.domElement.addEventListener("pointerdown", S), t.domElement.addEventListener("pointercancel", Z), t.domElement.addEventListener("wheel", Q, { passive: !1 }), t.domElement.getRootNode().addEventListener("keydown", ze, { passive: !0, capture: !0 }), this.update();
3998
4009
  }
3999
4010
  }
4000
- function rt(e, n, a, t, i) {
4011
+ function ot(e, n, a, t, i) {
4001
4012
  return t + (e - n) * (i - t) / (a - n);
4002
4013
  }
4003
- const Mt = (e) => {
4004
- const [n, a] = H(e.options[e.index]), t = () => {
4014
+ const wt = (e) => {
4015
+ const [n, a] = W(e.options[e.index]), t = () => {
4005
4016
  e.onToggle(!e.open);
4006
4017
  }, i = (o) => {
4007
4018
  o !== n && (e.onSelect(o), a(o)), e.onToggle(!1);
@@ -4010,14 +4021,14 @@ const Mt = (e) => {
4010
4021
  /* @__PURE__ */ l.jsx("div", { className: "dropdown-toggle", onClick: t, children: n }),
4011
4022
  e.open && /* @__PURE__ */ l.jsx("ul", { className: "dropdown-menu", children: e.options.map((o) => /* @__PURE__ */ l.jsx("li", { onClick: () => i(o), children: o }, o)) })
4012
4023
  ] });
4013
- }, qe = Ra(function(n, a) {
4014
- const [t, i] = H(!1), o = n.options.indexOf(n.camera.name);
4024
+ }, Ze = Ra(function(n, a) {
4025
+ const [t, i] = W(!1), o = n.options.indexOf(n.camera.name);
4015
4026
  return /* @__PURE__ */ l.jsxs("div", { className: "CameraWindow", children: [
4016
4027
  /* @__PURE__ */ l.jsx("div", { ref: a, className: "clickable", onClick: () => {
4017
4028
  t && i(!1);
4018
4029
  } }),
4019
4030
  /* @__PURE__ */ l.jsx(
4020
- Mt,
4031
+ wt,
4021
4032
  {
4022
4033
  index: o,
4023
4034
  open: t,
@@ -4031,7 +4042,7 @@ const Mt = (e) => {
4031
4042
  )
4032
4043
  ] });
4033
4044
  });
4034
- class Si extends In {
4045
+ class xi extends In {
4035
4046
  constructor(n) {
4036
4047
  super({
4037
4048
  extensions: {
@@ -4049,7 +4060,7 @@ class Si extends In {
4049
4060
  value: n?.divisions !== void 0 ? n?.divisions : 10
4050
4061
  },
4051
4062
  uColor: {
4052
- value: n?.color !== void 0 ? n?.color : new $t(16777215)
4063
+ value: n?.color !== void 0 ? n?.color : new Ut(16777215)
4053
4064
  },
4054
4065
  uDistance: {
4055
4066
  value: n?.distance !== void 0 ? n?.distance : 1e4
@@ -4144,17 +4155,17 @@ class Si extends In {
4144
4155
  });
4145
4156
  }
4146
4157
  }
4147
- class Ci extends An {
4158
+ class Si extends An {
4148
4159
  gridMaterial;
4149
4160
  constructor() {
4150
- const n = new Si();
4161
+ const n = new xi();
4151
4162
  super(new ma(2, 2), n), this.gridMaterial = n, this.frustumCulled = !1, this.name = "InfiniteGridHelper", this.position.y = 0.1;
4152
4163
  }
4153
4164
  update() {
4154
4165
  this.gridMaterial.needsUpdate = !0;
4155
4166
  }
4156
4167
  }
4157
- const wi = `#include <common>
4168
+ const Ci = `#include <common>
4158
4169
  #include <batching_pars_vertex>
4159
4170
  #include <uv_pars_vertex>
4160
4171
  #include <color_pars_vertex>
@@ -4184,7 +4195,7 @@ void main() {
4184
4195
  #include <logdepthbuf_vertex>
4185
4196
  #include <clipping_planes_vertex>
4186
4197
  #include <worldpos_vertex>
4187
- }`, Mi = `
4198
+ }`, wi = `
4188
4199
  #include <common>
4189
4200
  #include <uv_pars_fragment>
4190
4201
  #include <clipping_planes_pars_fragment>
@@ -4193,79 +4204,79 @@ void main() {
4193
4204
  #include <clipping_planes_fragment>
4194
4205
  gl_FragColor = vec4(vec3(vUv, 0.0), 1.0);
4195
4206
  }`;
4196
- class Oi extends In {
4207
+ class Mi extends In {
4197
4208
  constructor() {
4198
4209
  super({
4199
4210
  defines: {
4200
4211
  USE_UV: ""
4201
4212
  },
4202
- vertexShader: wi,
4203
- fragmentShader: Mi
4213
+ vertexShader: Ci,
4214
+ fragmentShader: wi
4204
4215
  });
4205
4216
  }
4206
4217
  }
4207
- let xt = "Renderer", Te, St = !1, Nt = !1, X = null, oe = null, Ge = null, We = null;
4208
- function zi(e) {
4209
- const n = e.three.app.appID, a = localStorage.getItem(`${n}_mode`), t = localStorage.getItem(`${n}_tlCam`) !== null ? localStorage.getItem(`${n}_tlCam`) : "Debug", i = localStorage.getItem(`${n}_trCam`) !== null ? localStorage.getItem(`${n}_trCam`) : "Orthographic", o = localStorage.getItem(`${n}_blCam`) !== null ? localStorage.getItem(`${n}_blCam`) : "Front", d = localStorage.getItem(`${n}_brCam`) !== null ? localStorage.getItem(`${n}_brCam`) : "Top", r = se(() => /* @__PURE__ */ new Map(), []), h = se(() => /* @__PURE__ */ new Map(), []), u = se(() => /* @__PURE__ */ new Map(), []), f = se(() => /* @__PURE__ */ new Map(), []), m = se(() => new pa(), []), v = se(() => new ga(), []), S = se(() => new Ci(), []), A = se(() => new Qt(500), []), F = se(() => new Qt(100), []), V = se(() => new va(), []), R = se(() => new ba(), []), I = se(() => new Oi(), []), T = se(() => new jn({
4218
+ let xt = "Renderer", Te, It = !1, K = null, ce = null, Ye = null, Ve = null;
4219
+ function $i(e) {
4220
+ const n = e.three.app.appID, a = localStorage.getItem(`${n}_mode`), t = localStorage.getItem(`${n}_tlCam`) !== null ? localStorage.getItem(`${n}_tlCam`) : "Debug", i = localStorage.getItem(`${n}_trCam`) !== null ? localStorage.getItem(`${n}_trCam`) : "Orthographic", o = localStorage.getItem(`${n}_blCam`) !== null ? localStorage.getItem(`${n}_blCam`) : "Front", d = localStorage.getItem(`${n}_brCam`) !== null ? localStorage.getItem(`${n}_brCam`) : "Top", r = se(() => /* @__PURE__ */ new Map(), []), h = se(() => /* @__PURE__ */ new Map(), []), u = se(() => /* @__PURE__ */ new Map(), []), f = se(() => /* @__PURE__ */ new Map(), []), m = se(() => new pa(), []), b = se(() => new ga(), []), E = se(() => new Si(), []), D = se(() => new Jt(500), []), $ = se(() => new Jt(100), []), z = se(() => new va(), []), B = se(() => new ba(), []), C = se(() => new Mi(), []), T = se(() => new jn({
4210
4221
  opacity: 0.33,
4211
4222
  transparent: !0,
4212
4223
  wireframe: !0
4213
4224
  }), []);
4214
- function Z(g, b) {
4215
- const M = new en(-100, 100, 100, -100, 50, 5e3);
4216
- return M.name = g, M.position.copy(b), M.lookAt(0, 0, 0), r.set(g, M), M;
4225
+ function X(g, v) {
4226
+ const M = new Qt(-100, 100, 100, -100, 50, 5e3);
4227
+ return M.name = g, M.position.copy(v), M.lookAt(0, 0, 0), r.set(g, M), M;
4217
4228
  }
4218
- const te = [
4229
+ const ne = [
4219
4230
  "Renderer",
4220
4231
  "Depth",
4221
4232
  "Normals",
4222
4233
  "UVs",
4223
4234
  "Wireframe"
4224
- ], pe = [
4235
+ ], ge = [
4225
4236
  "Single",
4226
4237
  "Side by Side",
4227
4238
  "Stacked",
4228
4239
  "Quad"
4229
- ], q = Y(null), ge = Y(null), ce = Y(null), _e = Y(null), ke = Y(null), be = Y(null), [U, ye] = H(a !== null ? a : "Single"), [O, we] = H(null), [De, je] = H(!1), [Pe, Ae] = H(!1), [Ie, Be] = H(!1), [, Fe] = H(Date.now());
4230
- localStorage.setItem(`${n}_mode`, U), localStorage.setItem(`${n}_tlCam`, t), localStorage.setItem(`${n}_trCam`, i), localStorage.setItem(`${n}_blCam`, o), localStorage.setItem(`${n}_brCam`, d);
4231
- const re = (g, b) => {
4240
+ ], q = V(null), ve = V(null), le = V(null), _e = V(null), ke = V(null), ye = V(null), [F, Ee] = W(a !== null ? a : "Single"), [R, Me] = W(null), [De, Ie] = W(!1), [Pe, Ae] = W(!1), [je, qe] = W("Orbit"), [Ne, Ke] = W(!1), [ct, Le] = W(Date.now());
4241
+ localStorage.setItem(`${n}_mode`, F), localStorage.setItem(`${n}_tlCam`, t), localStorage.setItem(`${n}_trCam`, i), localStorage.setItem(`${n}_blCam`, o), localStorage.setItem(`${n}_brCam`, d);
4242
+ const ae = (g, v) => {
4232
4243
  const M = h.get(g.name);
4233
4244
  if (M !== void 0 && M.dispose(), h.delete(g.name), g.name === "UI")
4234
4245
  return;
4235
- const N = new xi(g, b);
4236
- switch (N.enableDamping = !0, N.dampingFactor = 0.05, g.name) {
4246
+ const j = new Ei(g, v);
4247
+ switch (j.enableDamping = !0, j.dampingFactor = 0.05, g.name) {
4237
4248
  case "Top":
4238
4249
  case "Bottom":
4239
4250
  case "Left":
4240
4251
  case "Right":
4241
4252
  case "Front":
4242
4253
  case "Back":
4243
- N.enableRotate = !1;
4254
+ j.enableRotate = !1;
4244
4255
  break;
4245
4256
  }
4246
- h.set(g.name, N);
4247
- }, Me = (g) => {
4248
- const b = u.get(g.name);
4249
- b !== void 0 && (m.remove(b), b.dispose(), u.delete(g.name));
4257
+ h.set(g.name, j);
4258
+ }, fe = (g) => {
4259
+ const v = u.get(g.name);
4260
+ v !== void 0 && (m.remove(v), v.dispose(), u.delete(g.name));
4250
4261
  const M = h.get(g.name);
4251
4262
  M !== void 0 && (M.dispose(), h.delete(g.name));
4252
- }, He = () => {
4253
- h.forEach((g, b) => {
4263
+ }, Ue = () => {
4264
+ h.forEach((g, v) => {
4254
4265
  g.dispose();
4255
- const M = u.get(b);
4256
- M !== void 0 && (m.remove(M), M.dispose()), u.delete(b), h.delete(b);
4266
+ const M = u.get(v);
4267
+ M !== void 0 && (m.remove(M), M.dispose()), u.delete(v), h.delete(v);
4257
4268
  }), h.clear(), u.clear();
4258
- }, Ye = () => {
4259
- switch (U) {
4269
+ }, Be = () => {
4270
+ switch (F) {
4260
4271
  case "Single":
4261
- re(X, ce.current);
4272
+ ae(K, le.current);
4262
4273
  break;
4263
4274
  case "Side by Side":
4264
4275
  case "Stacked":
4265
- re(X, ce.current), re(oe, _e.current);
4276
+ ae(K, le.current), ae(ce, _e.current);
4266
4277
  break;
4267
4278
  case "Quad":
4268
- re(X, ce.current), re(oe, _e.current), re(Ge, ke.current), re(We, be.current);
4279
+ ae(K, le.current), ae(ce, _e.current), ae(Ye, ke.current), ae(Ve, ye.current);
4269
4280
  break;
4270
4281
  }
4271
4282
  };
@@ -4274,253 +4285,253 @@ function zi(e) {
4274
4285
  canvas: q.current,
4275
4286
  stencil: !1
4276
4287
  });
4277
- g.autoClear = !1, g.shadowMap.enabled = !0, g.setPixelRatio(devicePixelRatio), g.setClearColor(0), e.three.renderer = g, we(g);
4288
+ g.autoClear = !1, g.shadowMap.enabled = !0, g.setPixelRatio(devicePixelRatio), g.setClearColor(0), e.three.renderer = g, Me(g);
4278
4289
  }, []), Re(() => {
4279
- m.name = "Debug Scene", m.uuid = "", v.name = "helpers", m.add(v), v.add(S), A.name = "axisHelper", v.add(A), F.name = "interactionHelper", v.add(F), F.visible = !1, Z("Top", new J(0, 1e3, 0)), Z("Bottom", new J(0, -1e3, 0)), Z("Left", new J(-1e3, 0, 0)), Z("Right", new J(1e3, 0, 0)), Z("Front", new J(0, 0, 1e3)), Z("Back", new J(0, 0, -1e3)), Z("Orthographic", new J(1e3, 1e3, 1e3)), Z("UI", new J());
4280
- const g = new At(60, 1, 50, 5e3);
4281
- g.name = "Debug", g.position.set(500, 500, 500), g.lookAt(0, 0, 0), r.set("Debug", g), X = r.get(localStorage.getItem(`${n}_tlCam`)), oe = r.get(localStorage.getItem(`${n}_trCam`)), Ge = r.get(localStorage.getItem(`${n}_blCam`)), We = r.get(localStorage.getItem(`${n}_brCam`));
4290
+ m.name = "Debug Scene", m.uuid = "", b.name = "helpers", m.add(b), b.add(E), D.name = "axisHelper", b.add(D), $.name = "interactionHelper", b.add($), $.visible = !1, X("Top", new J(0, 1e3, 0)), X("Bottom", new J(0, -1e3, 0)), X("Left", new J(-1e3, 0, 0)), X("Right", new J(1e3, 0, 0)), X("Front", new J(0, 0, 1e3)), X("Back", new J(0, 0, -1e3)), X("Orthographic", new J(1e3, 1e3, 1e3)), X("UI", new J());
4291
+ const g = new Pt(60, 1, 50, 5e3);
4292
+ g.name = "Debug", g.position.set(500, 500, 500), g.lookAt(0, 0, 0), r.set("Debug", g), K = r.get(localStorage.getItem(`${n}_tlCam`)), ce = r.get(localStorage.getItem(`${n}_trCam`)), Ye = r.get(localStorage.getItem(`${n}_blCam`)), Ve = r.get(localStorage.getItem(`${n}_brCam`));
4282
4293
  }, []), Re(() => {
4283
4294
  const g = () => {
4284
- f.forEach((C) => {
4285
- v.remove(C), C.dispose();
4295
+ f.forEach((O) => {
4296
+ b.remove(O), O.dispose();
4286
4297
  }), f.clear();
4287
- }, b = () => {
4288
- Te.traverse((C) => {
4289
- if (C.type.search("Light") > -1) {
4290
- let x;
4291
- switch (C.type) {
4298
+ }, v = () => {
4299
+ Te.traverse((O) => {
4300
+ if (O.type.search("Light") > -1) {
4301
+ let S;
4302
+ switch (O.type) {
4292
4303
  case "DirectionalLight":
4293
- x = new Ma(C, 100), x.name = `${C.name}Helper`, f.set(C.name, x), v.add(x);
4304
+ S = new Ma(O, 100), S.name = `${O.name}Helper`, f.set(O.name, S), b.add(S);
4294
4305
  break;
4295
4306
  case "HemisphereLight":
4296
- x = new wa(C, 250), x.name = `${C.name}Helper`, f.set(C.name, x), v.add(x);
4307
+ S = new wa(O, 250), S.name = `${O.name}Helper`, f.set(O.name, S), b.add(S);
4297
4308
  break;
4298
4309
  case "RectAreaLight":
4299
- x = new yi(C), x.name = `${C.name}Helper`, f.set(C.name, x), v.add(x);
4310
+ S = new bi(O), S.name = `${O.name}Helper`, f.set(O.name, S), b.add(S);
4300
4311
  break;
4301
4312
  case "PointLight":
4302
- x = new Ca(C, 100), x.name = `${C.name}Helper`, f.set(C.name, x), v.add(x);
4313
+ S = new Ca(O, 100), S.name = `${O.name}Helper`, f.set(O.name, S), b.add(S);
4303
4314
  break;
4304
4315
  case "SpotLight":
4305
- x = new Sa(C), x.name = `${C.name}Helper`, f.set(C.name, x), v.add(x);
4316
+ S = new Sa(O), S.name = `${O.name}Helper`, f.set(O.name, S), b.add(S);
4306
4317
  break;
4307
4318
  }
4308
4319
  }
4309
4320
  });
4310
- }, M = (C) => {
4311
- v.add(A), g(), Tt(Te), m.remove(Te);
4312
- const x = e.scenes.get(C.value.name);
4313
- if (x !== void 0) {
4314
- const G = new x();
4315
- e.onSceneSet !== void 0 && e.onSceneSet(G), Te = G, e.three.scene = Te, m.add(Te), Nt = !0, b();
4321
+ }, M = (O) => {
4322
+ b.add(D), g(), Ot(Te), m.remove(Te);
4323
+ const S = e.scenes.get(O.value.name);
4324
+ if (S !== void 0) {
4325
+ const G = new S();
4326
+ e.onSceneSet !== void 0 && e.onSceneSet(G), Te = G, e.three.scene = Te, m.add(Te), It = !0, v();
4316
4327
  }
4317
- }, N = (C) => {
4318
- const x = C.value, G = e.three.scene?.getObjectByProperty("uuid", x.uuid);
4319
- if (G !== void 0 && r.set(x.name, G), G instanceof At) {
4320
- const ne = new xa(G);
4321
- u.set(G.name, ne), m.add(ne);
4328
+ }, j = (O) => {
4329
+ const S = O.value, G = e.three.scene?.getObjectByProperty("uuid", S.uuid);
4330
+ if (G !== void 0 && r.set(S.name, G), G instanceof Pt) {
4331
+ const Z = new xa(G);
4332
+ u.set(G.name, Z), m.add(Z);
4322
4333
  }
4323
- Fe(Date.now());
4324
- }, ve = (C) => {
4325
- const x = u.get(C.value.name);
4326
- x !== void 0 && (m.remove(x), x.dispose()), r.delete(C.value.name), Fe(Date.now());
4327
- }, le = (C) => {
4328
- const x = Te.getObjectByProperty("uuid", C.value.uuid);
4329
- x && x.add(A);
4334
+ Le(Date.now());
4335
+ }, oe = (O) => {
4336
+ const S = u.get(O.value.name);
4337
+ S !== void 0 && (m.remove(S), S.dispose()), r.delete(O.value.name), Le(Date.now());
4338
+ }, ue = (O) => {
4339
+ const S = Te.getObjectByProperty("uuid", O.value.uuid);
4340
+ S && S.add(D);
4330
4341
  };
4331
- return D.addEventListener(P.SET_SCENE, M), D.addEventListener(P.ADD_CAMERA, N), D.addEventListener(P.REMOVE_CAMERA, ve), D.addEventListener(P.SET_OBJECT, le), () => {
4332
- D.removeEventListener(P.SET_SCENE, M), D.removeEventListener(P.ADD_CAMERA, N), D.removeEventListener(P.REMOVE_CAMERA, ve), D.removeEventListener(P.SET_OBJECT, le);
4342
+ return P.addEventListener(A.SET_SCENE, M), P.addEventListener(A.ADD_CAMERA, j), P.addEventListener(A.REMOVE_CAMERA, oe), P.addEventListener(A.SET_OBJECT, ue), () => {
4343
+ P.removeEventListener(A.SET_SCENE, M), P.removeEventListener(A.ADD_CAMERA, j), P.removeEventListener(A.REMOVE_CAMERA, oe), P.removeEventListener(A.SET_OBJECT, ue);
4333
4344
  };
4334
4345
  }, []), Re(() => {
4335
- if (O === null)
4346
+ if (R === null)
4336
4347
  return;
4337
- let g = window.innerWidth, b = window.innerHeight, M = Math.floor(g / 2), N = Math.floor(b / 2), ve = -1;
4338
- const le = () => {
4339
- g = window.innerWidth - 300, b = window.innerHeight, M = Math.floor(g / 2), N = Math.floor(b / 2), e.three.resize(g, b), e.onSceneResize !== void 0 && Nt && e.onSceneResize(Te, g, b);
4340
- let _ = g, z = b;
4341
- switch (U) {
4348
+ let g = window.innerWidth, v = window.innerHeight, M = Math.floor(g / 2), j = Math.floor(v / 2), oe = -1;
4349
+ const ue = () => {
4350
+ g = window.innerWidth - 300, v = window.innerHeight, M = Math.floor(g / 2), j = Math.floor(v / 2), e.three.resize(g, v), e.onSceneResize !== void 0 && It && e.onSceneResize(Te, g, v);
4351
+ let _ = g, Y = v;
4352
+ switch (F) {
4342
4353
  case "Side by Side":
4343
- _ = M, z = b;
4354
+ _ = M, Y = v;
4344
4355
  break;
4345
4356
  case "Stacked":
4346
- _ = g, z = N;
4357
+ _ = g, Y = j;
4347
4358
  break;
4348
4359
  case "Quad":
4349
- _ = M, z = N;
4360
+ _ = M, Y = j;
4350
4361
  break;
4351
4362
  }
4352
- r.forEach((K) => {
4353
- K instanceof en ? (K.left = _ / -2, K.right = _ / 2, K.top = z / 2, K.bottom = z / -2, K.name === "UI" && (K.position.x = g / 2, K.position.y = b / -2, K.position.z = 100), K.updateProjectionMatrix()) : K instanceof At && (K.aspect = _ / z, K.updateProjectionMatrix(), u.get(K.name)?.update());
4363
+ r.forEach((Q) => {
4364
+ Q instanceof Qt ? (Q.left = _ / -2, Q.right = _ / 2, Q.top = Y / 2, Q.bottom = Y / -2, Q.name === "UI" && (Q.position.x = g / 2, Q.position.y = v / -2, Q.position.z = 100), Q.updateProjectionMatrix()) : Q instanceof Pt && (Q.aspect = _ / Y, Q.updateProjectionMatrix(), u.get(Q.name)?.update());
4354
4365
  });
4355
- }, C = () => {
4356
- O.setViewport(0, 0, g, b), O.setScissor(0, 0, g, b), O.render(m, X);
4357
- }, x = () => {
4358
- if (U === "Side by Side")
4359
- O.setViewport(0, 0, M, b), O.setScissor(0, 0, M, b), O.render(m, X), O.setViewport(M, 0, M, b), O.setScissor(M, 0, M, b), O.render(m, oe);
4366
+ }, O = () => {
4367
+ R.setViewport(0, 0, g, v), R.setScissor(0, 0, g, v), R.render(m, K);
4368
+ }, S = () => {
4369
+ if (F === "Side by Side")
4370
+ R.setViewport(0, 0, M, v), R.setScissor(0, 0, M, v), R.render(m, K), R.setViewport(M, 0, M, v), R.setScissor(M, 0, M, v), R.render(m, ce);
4360
4371
  else {
4361
- const _ = b - N;
4362
- O.setViewport(0, _, g, N), O.setScissor(0, _, g, N), O.render(m, X), O.setViewport(0, 0, g, N), O.setScissor(0, 0, g, N), O.render(m, oe);
4372
+ const _ = v - j;
4373
+ R.setViewport(0, _, g, j), R.setScissor(0, _, g, j), R.render(m, K), R.setViewport(0, 0, g, j), R.setScissor(0, 0, g, j), R.render(m, ce);
4363
4374
  }
4364
4375
  }, G = () => {
4365
- let _ = 0, z = 0;
4366
- z = b - N, _ = 0, O.setViewport(_, z, M, N), O.setScissor(_, z, M, N), O.render(m, X), _ = M, O.setViewport(_, z, M, N), O.setScissor(_, z, M, N), O.render(m, oe), z = 0, _ = 0, O.setViewport(_, z, M, N), O.setScissor(_, z, M, N), O.render(m, Ge), _ = M, O.setViewport(_, z, M, N), O.setScissor(_, z, M, N), O.render(m, We);
4367
- }, ne = () => {
4376
+ let _ = 0, Y = 0;
4377
+ Y = v - j, _ = 0, R.setViewport(_, Y, M, j), R.setScissor(_, Y, M, j), R.render(m, K), _ = M, R.setViewport(_, Y, M, j), R.setScissor(_, Y, M, j), R.render(m, ce), Y = 0, _ = 0, R.setViewport(_, Y, M, j), R.setScissor(_, Y, M, j), R.render(m, Ye), _ = M, R.setViewport(_, Y, M, j), R.setScissor(_, Y, M, j), R.render(m, Ve);
4378
+ }, Z = () => {
4368
4379
  switch (h.forEach((_) => {
4369
4380
  _.update();
4370
4381
  }), u.forEach((_) => {
4371
4382
  _.update();
4372
4383
  }), f.forEach((_) => {
4373
4384
  _.update !== void 0 && _.update();
4374
- }), e.onSceneUpdate !== void 0 && Nt && e.onSceneUpdate(Te), O.clear(), U) {
4385
+ }), e.onSceneUpdate !== void 0 && It && e.onSceneUpdate(Te), R.clear(), F) {
4375
4386
  case "Single":
4376
- C();
4387
+ O();
4377
4388
  break;
4378
4389
  case "Side by Side":
4379
4390
  case "Stacked":
4380
- x();
4391
+ S();
4381
4392
  break;
4382
4393
  case "Quad":
4383
4394
  G();
4384
4395
  break;
4385
4396
  }
4386
- ve = requestAnimationFrame(ne);
4397
+ oe = requestAnimationFrame(Z);
4387
4398
  };
4388
- return Ye(), window.addEventListener("resize", le), le(), ne(), () => {
4389
- window.removeEventListener("resize", le), cancelAnimationFrame(ve), ve = -1;
4399
+ return Be(), window.addEventListener("resize", ue), ue(), Z(), () => {
4400
+ window.removeEventListener("resize", ue), cancelAnimationFrame(oe), oe = -1;
4390
4401
  };
4391
- }, [U, O]), Re(() => {
4392
- if (O !== null) {
4393
- const g = new Ea(), b = new me(), M = (C, x, G, ne) => {
4394
- switch (U) {
4402
+ }, [F, R]), Re(() => {
4403
+ if (R !== null) {
4404
+ const g = new Ea(), v = new pe(), M = (O, S, G, Z) => {
4405
+ switch (F) {
4395
4406
  case "Quad":
4396
- C < G ? x < ne ? g.setFromCamera(b, X) : g.setFromCamera(b, Ge) : x < ne ? g.setFromCamera(b, oe) : g.setFromCamera(b, We);
4407
+ O < G ? S < Z ? g.setFromCamera(v, K) : g.setFromCamera(v, Ye) : S < Z ? g.setFromCamera(v, ce) : g.setFromCamera(v, Ve);
4397
4408
  break;
4398
4409
  case "Side by Side":
4399
- C < G ? g.setFromCamera(b, X) : g.setFromCamera(b, oe);
4410
+ O < G ? g.setFromCamera(v, K) : g.setFromCamera(v, ce);
4400
4411
  break;
4401
4412
  case "Single":
4402
- g.setFromCamera(b, X);
4413
+ g.setFromCamera(v, K);
4403
4414
  break;
4404
4415
  case "Stacked":
4405
- x < ne ? g.setFromCamera(b, X) : g.setFromCamera(b, oe);
4416
+ S < Z ? g.setFromCamera(v, K) : g.setFromCamera(v, ce);
4406
4417
  break;
4407
4418
  }
4408
- }, N = (C) => {
4409
- if (!St)
4419
+ }, j = (O) => {
4420
+ if (je === "Orbit")
4410
4421
  return;
4411
- const x = new me();
4412
- O.getSize(x);
4413
- const G = Math.min(C.clientX, x.x), ne = Math.min(C.clientY, x.y);
4414
- b.x = rt(G, 0, x.x, -1, 1), b.y = rt(ne, 0, x.y, 1, -1);
4415
- const _ = x.x / 2, z = x.y / 2, K = () => {
4416
- G < _ ? b.x = rt(G, 0, _, -1, 1) : b.x = rt(G, _, x.x, -1, 1);
4417
- }, Ne = () => {
4418
- ne < z ? b.y = rt(ne, 0, z, 1, -1) : b.y = rt(ne, z, x.y, 1, -1);
4422
+ const S = new pe();
4423
+ R.getSize(S);
4424
+ const G = Math.min(O.clientX, S.x), Z = Math.min(O.clientY, S.y);
4425
+ v.x = ot(G, 0, S.x, -1, 1), v.y = ot(Z, 0, S.y, 1, -1);
4426
+ const _ = S.x / 2, Y = S.y / 2, Q = () => {
4427
+ G < _ ? v.x = ot(G, 0, _, -1, 1) : v.x = ot(G, _, S.x, -1, 1);
4428
+ }, $e = () => {
4429
+ Z < Y ? v.y = ot(Z, 0, Y, 1, -1) : v.y = ot(Z, Y, S.y, 1, -1);
4419
4430
  };
4420
- switch (U) {
4431
+ switch (F) {
4421
4432
  case "Quad":
4422
- K(), Ne();
4433
+ Q(), $e();
4423
4434
  break;
4424
4435
  case "Side by Side":
4425
- K();
4436
+ Q();
4426
4437
  break;
4427
4438
  case "Stacked":
4428
- Ne(), Ne();
4439
+ $e(), $e();
4429
4440
  break;
4430
4441
  }
4431
- M(G, ne, _, z);
4432
- const Je = g.intersectObjects(Te.children);
4433
- Je.length > 0 && F.position.copy(Je[0].point);
4434
- }, ve = (C) => {
4435
- if (!St)
4442
+ M(G, Z, _, Y);
4443
+ const ze = g.intersectObjects(Te.children);
4444
+ ze.length > 0 && $.position.copy(ze[0].point);
4445
+ }, oe = (O) => {
4446
+ if (je === "Orbit")
4436
4447
  return;
4437
- const x = new me();
4438
- if (O.getSize(x), C.clientX >= x.x)
4448
+ const S = new pe();
4449
+ if (R.getSize(S), O.clientX >= S.x)
4439
4450
  return;
4440
- N(C);
4451
+ j(O);
4441
4452
  const G = g.intersectObjects(Te.children);
4442
- G.length > 0 && e.three.getObject(G[0].object.uuid);
4443
- }, le = ge.current;
4444
- return le.addEventListener("mousemove", N, !1), le.addEventListener("click", ve, !1), () => {
4445
- le.removeEventListener("mousemove", N), le.removeEventListener("click", ve);
4453
+ G.length > 0 && (e.three.getObject(G[0].object.uuid), $.visible = !1, qe("Orbit"), Le(Date.now()));
4454
+ }, ue = ve.current;
4455
+ return ue.addEventListener("mousemove", j, !1), ue.addEventListener("click", oe, !1), () => {
4456
+ ue.removeEventListener("mousemove", j), ue.removeEventListener("click", oe);
4446
4457
  };
4447
4458
  }
4448
- }, [U, O]);
4449
- const ue = [];
4450
- return r.forEach((g, b) => {
4451
- ue.push(b);
4459
+ }, [F, R, je]);
4460
+ const be = [];
4461
+ return r.forEach((g, v) => {
4462
+ be.push(v);
4452
4463
  }), /* @__PURE__ */ l.jsxs("div", { className: "multiview", children: [
4453
4464
  /* @__PURE__ */ l.jsx("canvas", { ref: q }),
4454
- O !== null && /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
4455
- /* @__PURE__ */ l.jsxs("div", { className: `cameras ${U === "Single" || U === "Stacked" ? "single" : ""}`, ref: ge, children: [
4456
- U === "Single" && /* @__PURE__ */ l.jsx(l.Fragment, { children: /* @__PURE__ */ l.jsx(qe, { camera: X, options: ue, ref: ce, onSelect: (g) => {
4457
- h.get(X.name)?.dispose();
4458
- const b = r.get(g);
4459
- b !== void 0 && (Me(X), X = b, localStorage.setItem(`${n}_tlCam`, b.name), re(b, ce.current));
4465
+ R !== null && /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
4466
+ /* @__PURE__ */ l.jsxs("div", { className: `cameras ${F === "Single" || F === "Stacked" ? "single" : ""}`, ref: ve, children: [
4467
+ F === "Single" && /* @__PURE__ */ l.jsx(l.Fragment, { children: /* @__PURE__ */ l.jsx(Ze, { camera: K, options: be, ref: le, onSelect: (g) => {
4468
+ h.get(K.name)?.dispose();
4469
+ const v = r.get(g);
4470
+ v !== void 0 && (fe(K), K = v, localStorage.setItem(`${n}_tlCam`, v.name), ae(v, le.current));
4460
4471
  } }) }),
4461
- (U === "Side by Side" || U === "Stacked") && /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
4462
- /* @__PURE__ */ l.jsx(qe, { camera: X, options: ue, ref: ce, onSelect: (g) => {
4463
- h.get(X.name)?.dispose();
4464
- const b = r.get(g);
4465
- b !== void 0 && (Me(X), X = b, localStorage.setItem(`${n}_tlCam`, b.name), re(b, ce.current));
4472
+ (F === "Side by Side" || F === "Stacked") && /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
4473
+ /* @__PURE__ */ l.jsx(Ze, { camera: K, options: be, ref: le, onSelect: (g) => {
4474
+ h.get(K.name)?.dispose();
4475
+ const v = r.get(g);
4476
+ v !== void 0 && (fe(K), K = v, localStorage.setItem(`${n}_tlCam`, v.name), ae(v, le.current));
4466
4477
  } }),
4467
- /* @__PURE__ */ l.jsx(qe, { camera: oe, options: ue, ref: _e, onSelect: (g) => {
4468
- h.get(oe.name)?.dispose();
4469
- const b = r.get(g);
4470
- b !== void 0 && (Me(oe), oe = b, localStorage.setItem(`${n}_trCam`, b.name), re(b, _e.current));
4478
+ /* @__PURE__ */ l.jsx(Ze, { camera: ce, options: be, ref: _e, onSelect: (g) => {
4479
+ h.get(ce.name)?.dispose();
4480
+ const v = r.get(g);
4481
+ v !== void 0 && (fe(ce), ce = v, localStorage.setItem(`${n}_trCam`, v.name), ae(v, _e.current));
4471
4482
  } })
4472
4483
  ] }),
4473
- U === "Quad" && /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
4474
- /* @__PURE__ */ l.jsx(qe, { camera: X, options: ue, ref: ce, onSelect: (g) => {
4475
- h.get(X.name)?.dispose();
4476
- const b = r.get(g);
4477
- b !== void 0 && (Me(X), X = b, localStorage.setItem(`${n}_tlCam`, b.name), re(b, ce.current));
4484
+ F === "Quad" && /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
4485
+ /* @__PURE__ */ l.jsx(Ze, { camera: K, options: be, ref: le, onSelect: (g) => {
4486
+ h.get(K.name)?.dispose();
4487
+ const v = r.get(g);
4488
+ v !== void 0 && (fe(K), K = v, localStorage.setItem(`${n}_tlCam`, v.name), ae(v, le.current));
4478
4489
  } }),
4479
- /* @__PURE__ */ l.jsx(qe, { camera: oe, options: ue, ref: _e, onSelect: (g) => {
4480
- h.get(oe.name)?.dispose();
4481
- const b = r.get(g);
4482
- b !== void 0 && (Me(oe), oe = b, localStorage.setItem(`${n}_trCam`, b.name), re(b, _e.current));
4490
+ /* @__PURE__ */ l.jsx(Ze, { camera: ce, options: be, ref: _e, onSelect: (g) => {
4491
+ h.get(ce.name)?.dispose();
4492
+ const v = r.get(g);
4493
+ v !== void 0 && (fe(ce), ce = v, localStorage.setItem(`${n}_trCam`, v.name), ae(v, _e.current));
4483
4494
  } }),
4484
- /* @__PURE__ */ l.jsx(qe, { camera: Ge, options: ue, ref: ke, onSelect: (g) => {
4485
- h.get(Ge.name)?.dispose();
4486
- const b = r.get(g);
4487
- b !== void 0 && (Me(Ge), Ge = b, localStorage.setItem(`${n}_blCam`, b.name), re(b, ke.current));
4495
+ /* @__PURE__ */ l.jsx(Ze, { camera: Ye, options: be, ref: ke, onSelect: (g) => {
4496
+ h.get(Ye.name)?.dispose();
4497
+ const v = r.get(g);
4498
+ v !== void 0 && (fe(Ye), Ye = v, localStorage.setItem(`${n}_blCam`, v.name), ae(v, ke.current));
4488
4499
  } }),
4489
- /* @__PURE__ */ l.jsx(qe, { camera: We, options: ue, ref: be, onSelect: (g) => {
4490
- h.get(We.name)?.dispose();
4491
- const b = r.get(g);
4492
- b !== void 0 && (Me(We), We = b, localStorage.setItem(`${n}_brCam`, b.name), re(b, be.current));
4500
+ /* @__PURE__ */ l.jsx(Ze, { camera: Ve, options: be, ref: ye, onSelect: (g) => {
4501
+ h.get(Ve.name)?.dispose();
4502
+ const v = r.get(g);
4503
+ v !== void 0 && (fe(Ve), Ve = v, localStorage.setItem(`${n}_brCam`, v.name), ae(v, ye.current));
4493
4504
  } })
4494
4505
  ] })
4495
4506
  ] }),
4496
4507
  /* @__PURE__ */ l.jsxs("div", { className: "settings", children: [
4497
4508
  /* @__PURE__ */ l.jsx(
4498
- Mt,
4509
+ wt,
4499
4510
  {
4500
- index: pe.indexOf(U),
4501
- options: pe,
4511
+ index: ge.indexOf(F),
4512
+ options: ge,
4502
4513
  onSelect: (g) => {
4503
- g !== U && (He(), ye(g));
4514
+ g !== F && (Ue(), Ee(g));
4504
4515
  },
4505
4516
  open: De,
4506
4517
  onToggle: (g) => {
4507
- je(g), Pe && Ae(!1), Ie && Be(!1);
4518
+ Ie(g), Pe && Ae(!1), Ne && Ke(!1);
4508
4519
  }
4509
4520
  }
4510
4521
  ),
4511
4522
  /* @__PURE__ */ l.jsx(
4512
- Mt,
4523
+ wt,
4513
4524
  {
4514
- index: te.indexOf(xt),
4515
- options: te,
4525
+ index: ne.indexOf(xt),
4526
+ options: ne,
4516
4527
  onSelect: (g) => {
4517
4528
  if (g !== xt)
4518
4529
  switch (xt = g, xt) {
4519
4530
  case "Depth":
4520
- m.overrideMaterial = V;
4531
+ m.overrideMaterial = z;
4521
4532
  break;
4522
4533
  case "Normals":
4523
- m.overrideMaterial = R;
4534
+ m.overrideMaterial = B;
4524
4535
  break;
4525
4536
  default:
4526
4537
  case "Renderer":
@@ -4530,38 +4541,38 @@ function zi(e) {
4530
4541
  m.overrideMaterial = T;
4531
4542
  break;
4532
4543
  case "UVs":
4533
- m.overrideMaterial = I;
4544
+ m.overrideMaterial = C;
4534
4545
  break;
4535
4546
  }
4536
4547
  },
4537
4548
  open: Pe,
4538
4549
  onToggle: (g) => {
4539
- De && je(!1), Ae(g), Ie && Be(!1);
4550
+ De && Ie(!1), Ae(g), Ne && Ke(!1);
4540
4551
  }
4541
4552
  }
4542
4553
  ),
4543
4554
  /* @__PURE__ */ l.jsx(
4544
- Mt,
4555
+ wt,
4545
4556
  {
4546
- index: 0,
4557
+ index: je === "Orbit" ? 0 : 1,
4547
4558
  options: [
4548
4559
  "Orbit Mode",
4549
4560
  "Selection Mode"
4550
4561
  ],
4551
4562
  onSelect: (g) => {
4552
- St = g === "Selection Mode", F.visible = St;
4563
+ $.visible = g === "Selection Mode", qe($.visible ? "Selection" : "Orbit");
4553
4564
  },
4554
- open: Ie,
4565
+ open: Ne,
4555
4566
  onToggle: (g) => {
4556
- De && je(!1), Pe && Ae(!1), Be(g);
4567
+ De && Ie(!1), Pe && Ae(!1), Ke(g);
4557
4568
  }
4558
4569
  }
4559
4570
  )
4560
- ] })
4571
+ ] }, ct)
4561
4572
  ] })
4562
4573
  ] });
4563
4574
  }
4564
- function Gi(e) {
4575
+ function zi(e) {
4565
4576
  return /* @__PURE__ */ l.jsxs("div", { className: "editor", ref: e.ref, style: e.style, children: [
4566
4577
  /* @__PURE__ */ l.jsx("div", { className: "header", children: e.header }),
4567
4578
  e.children,
@@ -4569,44 +4580,44 @@ function Gi(e) {
4569
4580
  ] });
4570
4581
  }
4571
4582
  export {
4572
- Wt as Accordion,
4573
- ji as Application,
4574
- Rt as BaseRemote,
4583
+ Gt as Accordion,
4584
+ Ai as Application,
4585
+ Tt as BaseRemote,
4575
4586
  Un as ChildObject,
4576
4587
  Ya as ContainerObject,
4577
4588
  Ga as Draggable,
4578
4589
  za as DraggableItem,
4579
4590
  Wa as Dropdown,
4580
4591
  Ha as DropdownItem,
4581
- Gi as Editor,
4582
- bi as Inspector,
4583
- zi as MultiView,
4592
+ zi as Editor,
4593
+ vi as Inspector,
4594
+ $i as MultiView,
4584
4595
  Fn as NavButton,
4585
- Ii as RemoteComponents,
4586
- Fi as RemoteController,
4587
- Gt as RemoteTheatre,
4588
- Li as RemoteThree,
4589
- Bi as RemoteTweakpane,
4590
- $i as SceneInspector,
4591
- Ui as SidePanel,
4592
- P as ToolEvents,
4593
- Ot as capitalize,
4594
- Ke as clamp,
4596
+ ji as RemoteComponents,
4597
+ Bi as RemoteController,
4598
+ zt as RemoteTheatre,
4599
+ Ni as RemoteThree,
4600
+ Li as RemoteTweakpane,
4601
+ Ui as SceneInspector,
4602
+ Fi as SidePanel,
4603
+ A as ToolEvents,
4604
+ Mt as capitalize,
4605
+ Je as clamp,
4595
4606
  Da as colorToHex,
4596
- D as debugDispatcher,
4597
- Di as defaultTheatreCallback,
4598
- Tt as dispose,
4607
+ P as debugDispatcher,
4608
+ ki as defaultTheatreCallback,
4609
+ Ot as dispose,
4599
4610
  Pa as disposeMaterial,
4600
- Ai as disposeTexture,
4601
- Pi as distance,
4602
- Bt as hierarchyUUID,
4611
+ Pi as disposeTexture,
4612
+ Di as distance,
4613
+ Lt as hierarchyUUID,
4603
4614
  ka as isColor,
4604
- nn as mix,
4605
- zt as noop,
4606
- tn as normalize,
4615
+ tn as mix,
4616
+ $t as noop,
4617
+ en as normalize,
4607
4618
  _a as randomID,
4608
- rn as resetThreeObjects,
4609
- an as round,
4610
- Ni as theatreEditorApp,
4611
- Lt as totalThreeObjects
4619
+ an as resetThreeObjects,
4620
+ nn as round,
4621
+ Ii as theatreEditorApp,
4622
+ Nt as totalThreeObjects
4612
4623
  };