vis-core 0.30.0-beta.51 → 0.30.0-beta.52

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.
@@ -13,7 +13,7 @@ var An = (_, e) => (e = Symbol[_]) ? e : Symbol.for("Symbol." + _), o1 = (_) =>
13
13
  return _;
14
14
  }, ln = (_, e) => t1(_, i1(e));
15
15
  var w0 = (_, e, n) => Dn(_, typeof e != "symbol" ? e + "" : e, n);
16
- var Wn = (_, e, n) => a1(n1(_), n, e);
16
+ var Vn = (_, e, n) => a1(n1(_), n, e);
17
17
  var J0 = (_, e, n) => new Promise((r, fe) => {
18
18
  var ze = (nt) => {
19
19
  try {
@@ -57,13 +57,13 @@ import { EventEmitter } from "events";
57
57
  import world$1 from "geojson-cn/json/0.json";
58
58
  import json100000Lite from "geojson-cn/json-lite/100000.json";
59
59
  import json100000 from "geojson-cn/json/100000.json";
60
- import adcodeAll from "geojson-cn/json-lite/all.json";
60
+ import adcodeAll$1 from "geojson-cn/json-lite/all.json";
61
61
  import { centroid as centroid$1, booleanPointInPolygon as booleanPointInPolygon$1, point, polygon, center } from "@turf/turf";
62
62
  import { continentsCountriesIso2 } from "geojson-cn";
63
63
  Array.prototype.at || (Array.prototype.at = function(_) {
64
64
  return _ < 0 && (_ = this.length + _), this[_];
65
65
  });
66
- const version = "0.30.0-beta.51", publicKeyPEM = "LS0tLS1CRUdJTiBQVUJMSUMgS0VZLS0tLS0KTUlJQklqQU5CZ2txaGtpRzl3MEJBUUVGQUFPQ0FROEFNSUlCQ2dLQ0FRRUEyTG1aVVQzVG9LZEVRRUdrdUU1QQo3dnlYTzRMM1Z6NDA5RFF2a2xzRHZ2SytNM2M2OGl4ZEVhZDZFcnZGS2FKQ1QrNTZNdU1XSXhUTnlDZDVQSkFGCjVYdzI4cW1iVkVCR3FGdXVIZTltSm5GUmRXN1NpK1Z1cTZvRWxwQkRkeEFIQ0dsWVVpU1R3WmhBbjJaVXJLSUYKd1J2c1k1bi9uWWNhZnl5QW9tRjhmNVRsTkpwS1JtbDU3WlRSWjBMdzdQRDFSeHFIbmJ0YWFETkpiSDV5eFd6cQpaVTBwQWhxMFNkNHdlOW1DUTJWWXc5czhtUERLbW4rU083eGovSUsrR1ZEaEJNOUpaZ3VIcGFZUGt3bWd5UkdwCkx6V0tHMkZULzJRalZUT1dRT09mRFVtVitDSVlsN1hVVlh1Q0toYWFNQ0ZVa1JQOHg4aEZucmNFeklHQ1JpM3IKK3dJREFRQUIKLS0tLS1FTkQgUFVCTElDIEtFWS0tLS0t", accessToken = {
66
+ const version = "0.30.0-beta.52", publicKeyPEM = "LS0tLS1CRUdJTiBQVUJMSUMgS0VZLS0tLS0KTUlJQklqQU5CZ2txaGtpRzl3MEJBUUVGQUFPQ0FROEFNSUlCQ2dLQ0FRRUEyTG1aVVQzVG9LZEVRRUdrdUU1QQo3dnlYTzRMM1Z6NDA5RFF2a2xzRHZ2SytNM2M2OGl4ZEVhZDZFcnZGS2FKQ1QrNTZNdU1XSXhUTnlDZDVQSkFGCjVYdzI4cW1iVkVCR3FGdXVIZTltSm5GUmRXN1NpK1Z1cTZvRWxwQkRkeEFIQ0dsWVVpU1R3WmhBbjJaVXJLSUYKd1J2c1k1bi9uWWNhZnl5QW9tRjhmNVRsTkpwS1JtbDU3WlRSWjBMdzdQRDFSeHFIbmJ0YWFETkpiSDV5eFd6cQpaVTBwQWhxMFNkNHdlOW1DUTJWWXc5czhtUERLbW4rU083eGovSUsrR1ZEaEJNOUpaZ3VIcGFZUGt3bWd5UkdwCkx6V0tHMkZULzJRalZUT1dRT09mRFVtVitDSVlsN1hVVlh1Q0toYWFNQ0ZVa1JQOHg4aEZucmNFeklHQ1JpM3IKK3dJREFRQUIKLS0tLS1FTkQgUFVCTElDIEtFWS0tLS0t", accessToken = {
67
67
  token: void 0,
68
68
  getInfo() {
69
69
  if (!this.token)
@@ -9066,7 +9066,7 @@ class BufferGeometry extends EventDispatcher {
9066
9066
  this.dispatchEvent({ type: "dispose" });
9067
9067
  }
9068
9068
  }
9069
- const _inverseMatrix$3 = /* @__PURE__ */ new Matrix4(), _ray$3$1 = /* @__PURE__ */ new Ray(), _sphere$6 = /* @__PURE__ */ new Sphere$1(), _sphereHitAt = /* @__PURE__ */ new Vector3(), _vA$1 = /* @__PURE__ */ new Vector3(), _vB$1 = /* @__PURE__ */ new Vector3(), _vC$1 = /* @__PURE__ */ new Vector3(), _tempA = /* @__PURE__ */ new Vector3(), _morphA = /* @__PURE__ */ new Vector3(), _intersectionPoint$1 = /* @__PURE__ */ new Vector3(), _intersectionPointWorld = /* @__PURE__ */ new Vector3();
9069
+ const _inverseMatrix$3 = /* @__PURE__ */ new Matrix4(), _ray$3 = /* @__PURE__ */ new Ray(), _sphere$6 = /* @__PURE__ */ new Sphere$1(), _sphereHitAt = /* @__PURE__ */ new Vector3(), _vA$1 = /* @__PURE__ */ new Vector3(), _vB$1 = /* @__PURE__ */ new Vector3(), _vC$1 = /* @__PURE__ */ new Vector3(), _tempA = /* @__PURE__ */ new Vector3(), _morphA = /* @__PURE__ */ new Vector3(), _intersectionPoint$1 = /* @__PURE__ */ new Vector3(), _intersectionPointWorld = /* @__PURE__ */ new Vector3();
9070
9070
  class Mesh extends Object3D {
9071
9071
  /**
9072
9072
  * Constructs a new mesh.
@@ -9127,7 +9127,7 @@ class Mesh extends Object3D {
9127
9127
  */
9128
9128
  raycast(e, n) {
9129
9129
  const r = this.geometry, fe = this.material, ze = this.matrixWorld;
9130
- fe !== void 0 && (r.boundingSphere === null && r.computeBoundingSphere(), _sphere$6.copy(r.boundingSphere), _sphere$6.applyMatrix4(ze), _ray$3$1.copy(e.ray).recast(e.near), !(_sphere$6.containsPoint(_ray$3$1.origin) === !1 && (_ray$3$1.intersectSphere(_sphere$6, _sphereHitAt) === null || _ray$3$1.origin.distanceToSquared(_sphereHitAt) > Rn(e.far - e.near, 2))) && (_inverseMatrix$3.copy(ze).invert(), _ray$3$1.copy(e.ray).applyMatrix4(_inverseMatrix$3), !(r.boundingBox !== null && _ray$3$1.intersectsBox(r.boundingBox) === !1) && this._computeIntersections(e, n, _ray$3$1)));
9130
+ fe !== void 0 && (r.boundingSphere === null && r.computeBoundingSphere(), _sphere$6.copy(r.boundingSphere), _sphere$6.applyMatrix4(ze), _ray$3.copy(e.ray).recast(e.near), !(_sphere$6.containsPoint(_ray$3.origin) === !1 && (_ray$3.intersectSphere(_sphere$6, _sphereHitAt) === null || _ray$3.origin.distanceToSquared(_sphereHitAt) > Rn(e.far - e.near, 2))) && (_inverseMatrix$3.copy(ze).invert(), _ray$3.copy(e.ray).applyMatrix4(_inverseMatrix$3), !(r.boundingBox !== null && _ray$3.intersectsBox(r.boundingBox) === !1) && this._computeIntersections(e, n, _ray$3)));
9131
9131
  }
9132
9132
  _computeIntersections(e, n, r) {
9133
9133
  let fe;
@@ -12119,7 +12119,7 @@ class LineBasicMaterial extends Material {
12119
12119
  return super.copy(e), this.color.copy(e.color), this.map = e.map, this.linewidth = e.linewidth, this.linecap = e.linecap, this.linejoin = e.linejoin, this.fog = e.fog, this;
12120
12120
  }
12121
12121
  }
12122
- const _vStart = /* @__PURE__ */ new Vector3(), _vEnd = /* @__PURE__ */ new Vector3(), _inverseMatrix$1 = /* @__PURE__ */ new Matrix4(), _ray$1$1 = /* @__PURE__ */ new Ray(), _sphere$1$1 = /* @__PURE__ */ new Sphere$1(), _intersectPointOnRay = /* @__PURE__ */ new Vector3(), _intersectPointOnSegment = /* @__PURE__ */ new Vector3();
12122
+ const _vStart = /* @__PURE__ */ new Vector3(), _vEnd = /* @__PURE__ */ new Vector3(), _inverseMatrix$1 = /* @__PURE__ */ new Matrix4(), _ray$1$1 = /* @__PURE__ */ new Ray(), _sphere$1 = /* @__PURE__ */ new Sphere$1(), _intersectPointOnRay = /* @__PURE__ */ new Vector3(), _intersectPointOnSegment = /* @__PURE__ */ new Vector3();
12123
12123
  class Line extends Object3D {
12124
12124
  /**
12125
12125
  * Constructs a new line.
@@ -12159,7 +12159,7 @@ class Line extends Object3D {
12159
12159
  */
12160
12160
  raycast(e, n) {
12161
12161
  const r = this.geometry, fe = this.matrixWorld, ze = e.params.Line.threshold, Fe = r.drawRange;
12162
- if (r.boundingSphere === null && r.computeBoundingSphere(), _sphere$1$1.copy(r.boundingSphere), _sphere$1$1.applyMatrix4(fe), _sphere$1$1.radius += ze, e.ray.intersectsSphere(_sphere$1$1) === !1) return;
12162
+ if (r.boundingSphere === null && r.computeBoundingSphere(), _sphere$1.copy(r.boundingSphere), _sphere$1.applyMatrix4(fe), _sphere$1.radius += ze, e.ray.intersectsSphere(_sphere$1) === !1) return;
12163
12163
  _inverseMatrix$1.copy(fe).invert(), _ray$1$1.copy(e.ray).applyMatrix4(_inverseMatrix$1);
12164
12164
  const Ue = ze / ((this.scale.x + this.scale.y + this.scale.z) / 3), nt = Ue * Ue, at = this.isLineSegments ? 2 : 1, ot = r.index, Lt = r.attributes.position;
12165
12165
  if (ot !== null) {
@@ -12271,7 +12271,7 @@ class PointsMaterial extends Material {
12271
12271
  return super.copy(e), this.color.copy(e.color), this.map = e.map, this.alphaMap = e.alphaMap, this.size = e.size, this.sizeAttenuation = e.sizeAttenuation, this.fog = e.fog, this;
12272
12272
  }
12273
12273
  }
12274
- const _inverseMatrix$4 = /* @__PURE__ */ new Matrix4(), _ray$4 = /* @__PURE__ */ new Ray(), _sphere$7 = /* @__PURE__ */ new Sphere$1(), _position$2$1 = /* @__PURE__ */ new Vector3();
12274
+ const _inverseMatrix = /* @__PURE__ */ new Matrix4(), _ray$4 = /* @__PURE__ */ new Ray(), _sphere$7 = /* @__PURE__ */ new Sphere$1(), _position$2 = /* @__PURE__ */ new Vector3();
12275
12275
  class Points extends Object3D {
12276
12276
  /**
12277
12277
  * Constructs a new point cloud.
@@ -12294,18 +12294,18 @@ class Points extends Object3D {
12294
12294
  raycast(e, n) {
12295
12295
  const r = this.geometry, fe = this.matrixWorld, ze = e.params.Points.threshold, Fe = r.drawRange;
12296
12296
  if (r.boundingSphere === null && r.computeBoundingSphere(), _sphere$7.copy(r.boundingSphere), _sphere$7.applyMatrix4(fe), _sphere$7.radius += ze, e.ray.intersectsSphere(_sphere$7) === !1) return;
12297
- _inverseMatrix$4.copy(fe).invert(), _ray$4.copy(e.ray).applyMatrix4(_inverseMatrix$4);
12297
+ _inverseMatrix.copy(fe).invert(), _ray$4.copy(e.ray).applyMatrix4(_inverseMatrix);
12298
12298
  const Ue = ze / ((this.scale.x + this.scale.y + this.scale.z) / 3), nt = Ue * Ue, at = r.index, Gt = r.attributes.position;
12299
12299
  if (at !== null) {
12300
12300
  const Lt = Math.max(0, Fe.start), Xt = Math.min(at.count, Fe.start + Fe.count);
12301
12301
  for (let Vt = Lt, Kt = Xt; Vt < Kt; Vt++) {
12302
12302
  const It = at.getX(Vt);
12303
- _position$2$1.fromBufferAttribute(Gt, It), testPoint$1(_position$2$1, It, nt, fe, e, n, this);
12303
+ _position$2.fromBufferAttribute(Gt, It), testPoint(_position$2, It, nt, fe, e, n, this);
12304
12304
  }
12305
12305
  } else {
12306
12306
  const Lt = Math.max(0, Fe.start), Xt = Math.min(Gt.count, Fe.start + Fe.count);
12307
12307
  for (let Vt = Lt, Kt = Xt; Vt < Kt; Vt++)
12308
- _position$2$1.fromBufferAttribute(Gt, Vt), testPoint$1(_position$2$1, Vt, nt, fe, e, n, this);
12308
+ _position$2.fromBufferAttribute(Gt, Vt), testPoint(_position$2, Vt, nt, fe, e, n, this);
12309
12309
  }
12310
12310
  }
12311
12311
  /**
@@ -12326,7 +12326,7 @@ class Points extends Object3D {
12326
12326
  }
12327
12327
  }
12328
12328
  }
12329
- function testPoint$1(_, e, n, r, fe, ze, Fe) {
12329
+ function testPoint(_, e, n, r, fe, ze, Fe) {
12330
12330
  const Ue = _ray$4.distanceSqToPoint(_);
12331
12331
  if (Ue < n) {
12332
12332
  const nt = new Vector3();
@@ -32713,7 +32713,7 @@ class WebGLRenderer {
32713
32713
  Bi.render(Ui, hn);
32714
32714
  };
32715
32715
  function Fn(a0, g0, L0) {
32716
- a0.transparent === !0 && a0.side === DoubleSide && a0.forceSinglePass === !1 ? (a0.side = BackSide, a0.needsUpdate = !0, Vn(a0, g0, L0), a0.side = FrontSide, a0.needsUpdate = !0, Vn(a0, g0, L0), a0.side = DoubleSide) : Vn(a0, g0, L0);
32716
+ a0.transparent === !0 && a0.side === DoubleSide && a0.forceSinglePass === !1 ? (a0.side = BackSide, a0.needsUpdate = !0, wn(a0, g0, L0), a0.side = FrontSide, a0.needsUpdate = !0, wn(a0, g0, L0), a0.side = DoubleSide) : wn(a0, g0, L0);
32717
32717
  }
32718
32718
  this.compile = function(a0, g0, L0 = null) {
32719
32719
  L0 === null && (L0 = a0), Ht = Wi.get(L0), Ht.init(g0), jt.push(Ht), L0.traverseVisible(function(v0) {
@@ -32827,7 +32827,7 @@ class WebGLRenderer {
32827
32827
  }
32828
32828
  function kn(a0, g0, L0, M0) {
32829
32829
  const { opaque: v0, transmissive: k0, transparent: H0 } = a0;
32830
- Ht.setupLightsView(L0), Ci === !0 && ki.setGlobalState($t.clippingPlanes, L0), M0 && K0.viewport(i0.copy(M0)), v0.length > 0 && Zn(v0, g0, L0), k0.length > 0 && Zn(k0, g0, L0), H0.length > 0 && Zn(H0, g0, L0), K0.buffers.depth.setTest(!0), K0.buffers.depth.setMask(!0), K0.buffers.color.setMask(!0), K0.setPolygonOffset(!1);
32830
+ Ht.setupLightsView(L0), Ci === !0 && ki.setGlobalState($t.clippingPlanes, L0), M0 && K0.viewport(i0.copy(M0)), v0.length > 0 && _n(v0, g0, L0), k0.length > 0 && _n(k0, g0, L0), H0.length > 0 && _n(H0, g0, L0), K0.buffers.depth.setTest(!0), K0.buffers.depth.setMask(!0), K0.buffers.color.setMask(!0), K0.setPolygonOffset(!1);
32831
32831
  }
32832
32832
  function Hn(a0, g0, L0, M0) {
32833
32833
  if ((L0.isScene === !0 ? L0.overrideMaterial : null) !== null)
@@ -32852,7 +32852,7 @@ class WebGLRenderer {
32852
32852
  const vi = $t.toneMapping;
32853
32853
  $t.toneMapping = NoToneMapping;
32854
32854
  const Ti = M0.viewport;
32855
- if (M0.viewport !== void 0 && (M0.viewport = void 0), Ht.setupLightsView(M0), Ci === !0 && ki.setGlobalState($t.clippingPlanes, M0), Zn(a0, L0, M0), T0.updateMultisampleRenderTarget(k0), T0.updateRenderTargetMipmap(k0), F0.has("WEBGL_multisampled_render_to_texture") === !1) {
32855
+ if (M0.viewport !== void 0 && (M0.viewport = void 0), Ht.setupLightsView(M0), Ci === !0 && ki.setGlobalState($t.clippingPlanes, M0), _n(a0, L0, M0), T0.updateMultisampleRenderTarget(k0), T0.updateRenderTargetMipmap(k0), F0.has("WEBGL_multisampled_render_to_texture") === !1) {
32856
32856
  let Ui = !1;
32857
32857
  for (let qi = 0, hn = g0.length; qi < hn; qi++) {
32858
32858
  const nn = g0[qi], { object: Bi, geometry: Hi, material: an, group: Qi } = nn;
@@ -32865,7 +32865,7 @@ class WebGLRenderer {
32865
32865
  }
32866
32866
  $t.setRenderTarget(D0, xi, Q0), $t.setClearColor(d0, G0), Ti !== void 0 && (M0.viewport = Ti), $t.toneMapping = vi;
32867
32867
  }
32868
- function Zn(a0, g0, L0) {
32868
+ function _n(a0, g0, L0) {
32869
32869
  const M0 = g0.isScene === !0 ? g0.overrideMaterial : null;
32870
32870
  for (let v0 = 0, k0 = a0.length; v0 < k0; v0++) {
32871
32871
  const H0 = a0[v0], { object: D0, geometry: xi, group: Q0 } = H0;
@@ -32876,7 +32876,7 @@ class WebGLRenderer {
32876
32876
  function zn(a0, g0, L0, M0, v0, k0) {
32877
32877
  a0.onBeforeRender($t, g0, L0, M0, v0, k0), a0.modelViewMatrix.multiplyMatrices(L0.matrixWorldInverse, a0.matrixWorld), a0.normalMatrix.getNormalMatrix(a0.modelViewMatrix), v0.onBeforeRender($t, g0, L0, M0, a0, k0), v0.transparent === !0 && v0.side === DoubleSide && v0.forceSinglePass === !1 ? (v0.side = BackSide, v0.needsUpdate = !0, $t.renderBufferDirect(L0, g0, M0, v0, a0, k0), v0.side = FrontSide, v0.needsUpdate = !0, $t.renderBufferDirect(L0, g0, M0, v0, a0, k0), v0.side = DoubleSide) : $t.renderBufferDirect(L0, g0, M0, v0, a0, k0), a0.onAfterRender($t, g0, L0, M0, v0, k0);
32878
32878
  }
32879
- function Vn(a0, g0, L0) {
32879
+ function wn(a0, g0, L0) {
32880
32880
  g0.isScene !== !0 && (g0 = Si);
32881
32881
  const M0 = c0.get(a0), v0 = Ht.state.lights, k0 = Ht.state.shadowsArray, H0 = v0.state.version, D0 = zi.getParameters(a0, v0.state, k0, g0, L0), xi = zi.getProgramCacheKey(D0);
32882
32882
  let Q0 = M0.programs;
@@ -32914,7 +32914,7 @@ class WebGLRenderer {
32914
32914
  let Qi = !1;
32915
32915
  M0.version === Hi.__version ? (Hi.needsLights && Hi.lightsStateVersion !== an.state.version || Hi.outputColorSpace !== D0 || v0.isBatchedMesh && Hi.batching === !1 || !v0.isBatchedMesh && Hi.batching === !0 || v0.isBatchedMesh && Hi.batchingColor === !0 && v0.colorTexture === null || v0.isBatchedMesh && Hi.batchingColor === !1 && v0.colorTexture !== null || v0.isInstancedMesh && Hi.instancing === !1 || !v0.isInstancedMesh && Hi.instancing === !0 || v0.isSkinnedMesh && Hi.skinning === !1 || !v0.isSkinnedMesh && Hi.skinning === !0 || v0.isInstancedMesh && Hi.instancingColor === !0 && v0.instanceColor === null || v0.isInstancedMesh && Hi.instancingColor === !1 && v0.instanceColor !== null || v0.isInstancedMesh && Hi.instancingMorph === !0 && v0.morphTexture === null || v0.isInstancedMesh && Hi.instancingMorph === !1 && v0.morphTexture !== null || Hi.envMap !== xi || M0.fog === !0 && Hi.fog !== k0 || Hi.numClippingPlanes !== void 0 && (Hi.numClippingPlanes !== ki.numPlanes || Hi.numIntersection !== ki.numIntersection) || Hi.vertexAlphas !== Q0 || Hi.vertexTangents !== vi || Hi.morphTargets !== Ti || Hi.morphNormals !== Ui || Hi.morphColors !== qi || Hi.toneMapping !== hn || Hi.morphTargetsCount !== Bi) && (Qi = !0) : (Qi = !0, Hi.__version = M0.version);
32916
32916
  let on = Hi.currentProgram;
32917
- Qi === !0 && (on = Vn(M0, g0, v0));
32917
+ Qi === !0 && (on = wn(M0, g0, v0));
32918
32918
  let un = !1, fn = !1, Cn = !1;
32919
32919
  const dn = on.getUniforms(), bn = Hi.uniforms;
32920
32920
  if (K0.useProgram(on.program) && (un = !0, fn = !0, Cn = !0), M0.id !== u0 && (u0 = M0.id, fn = !0), un || l0 !== a0) {
@@ -32936,8 +32936,8 @@ class WebGLRenderer {
32936
32936
  if ((Gn.position !== void 0 || Gn.normal !== void 0 || Gn.color !== void 0) && ji.update(v0, L0, on), (fn || Hi.receiveShadow !== v0.receiveShadow) && (Hi.receiveShadow = v0.receiveShadow, dn.setValue(b0, "receiveShadow", v0.receiveShadow)), M0.isMeshGouraudMaterial && M0.envMap !== null && (bn.envMap.value = xi, bn.flipEnvMap.value = xi.isCubeTexture && xi.isRenderTargetTexture === !1 ? -1 : 1), M0.isMeshStandardMaterial && M0.envMap === null && g0.environment !== null && (bn.envMapIntensity.value = g0.environmentIntensity), bn.dfgLUT !== void 0 && (bn.dfgLUT.value = getDFGLUT()), fn && (dn.setValue(b0, "toneMappingExposure", $t.toneMappingExposure), Hi.needsLights && f0(bn, Cn), k0 && M0.fog === !0 && $i.refreshFogUniforms(bn, k0), $i.refreshMaterialUniforms(bn, M0, yi, A0, Ht.state.transmissionRenderTarget[a0.id]), WebGLUniforms.upload(b0, Tn(Hi), bn, T0)), M0.isShaderMaterial && M0.uniformsNeedUpdate === !0 && (WebGLUniforms.upload(b0, Tn(Hi), bn, T0), M0.uniformsNeedUpdate = !1), M0.isSpriteMaterial && dn.setValue(b0, "center", v0.center), dn.setValue(b0, "modelViewMatrix", v0.modelViewMatrix), dn.setValue(b0, "normalMatrix", v0.normalMatrix), dn.setValue(b0, "modelMatrix", v0.matrixWorld), M0.isShaderMaterial || M0.isRawShaderMaterial) {
32937
32937
  const xn = M0.uniformsGroups;
32938
32938
  for (let Sn = 0, On = xn.length; Sn < On; Sn++) {
32939
- const wn = xn[Sn];
32940
- Pi.update(wn, on), Pi.bind(wn, on);
32939
+ const Zn = xn[Sn];
32940
+ Pi.update(Zn, on), Pi.bind(Zn, on);
32941
32941
  }
32942
32942
  }
32943
32943
  return on;
@@ -33073,8 +33073,8 @@ class WebGLRenderer {
33073
33073
  if (a0.isDepthTexture) {
33074
33074
  const Gn = c0.get(a0), xn = c0.get(g0), Sn = c0.get(Gn.__renderTarget), On = c0.get(xn.__renderTarget);
33075
33075
  K0.bindFramebuffer(b0.READ_FRAMEBUFFER, Sn.__webglFramebuffer), K0.bindFramebuffer(b0.DRAW_FRAMEBUFFER, On.__webglFramebuffer);
33076
- for (let wn = 0; wn < xi; wn++)
33077
- dn && (b0.framebufferTextureLayer(b0.READ_FRAMEBUFFER, b0.COLOR_ATTACHMENT0, c0.get(a0).__webglTexture, v0, Ti + wn), b0.framebufferTextureLayer(b0.DRAW_FRAMEBUFFER, b0.COLOR_ATTACHMENT0, c0.get(g0).__webglTexture, k0, hn + wn)), b0.blitFramebuffer(Q0, vi, H0, D0, Ui, qi, H0, D0, b0.DEPTH_BUFFER_BIT, b0.NEAREST);
33076
+ for (let Zn = 0; Zn < xi; Zn++)
33077
+ dn && (b0.framebufferTextureLayer(b0.READ_FRAMEBUFFER, b0.COLOR_ATTACHMENT0, c0.get(a0).__webglTexture, v0, Ti + Zn), b0.framebufferTextureLayer(b0.DRAW_FRAMEBUFFER, b0.COLOR_ATTACHMENT0, c0.get(g0).__webglTexture, k0, hn + Zn)), b0.blitFramebuffer(Q0, vi, H0, D0, Ui, qi, H0, D0, b0.DEPTH_BUFFER_BIT, b0.NEAREST);
33078
33078
  K0.bindFramebuffer(b0.READ_FRAMEBUFFER, null), K0.bindFramebuffer(b0.DRAW_FRAMEBUFFER, null);
33079
33079
  } else if (v0 !== 0 || a0.isRenderTargetTexture || c0.has(a0)) {
33080
33080
  const Gn = c0.get(a0), xn = c0.get(g0);
@@ -40715,21 +40715,21 @@ class RaySet {
40715
40715
  }
40716
40716
  }
40717
40717
  }
40718
- const _v0 = new Vector3(), _v1$1 = new Vector3(), _ray$3 = new Ray();
40718
+ const _v0 = new Vector3(), _v1$1 = new Vector3(), _ray$2 = new Ray();
40719
40719
  function computeDisjointEdges(_, e, n) {
40720
40720
  const r = _.attributes, fe = _.index, ze = r.position, Fe = /* @__PURE__ */ new Map(), Ue = /* @__PURE__ */ new Map(), nt = Array.from(e), at = new RaySet();
40721
40721
  for (let ot = 0, Gt = nt.length; ot < Gt; ot++) {
40722
40722
  const Lt = nt[ot], Xt = toTriIndex(Lt), Vt = toEdgeIndex(Lt);
40723
40723
  let Kt = 3 * Xt + Vt, It = 3 * Xt + (Vt + 1) % 3;
40724
- fe && (Kt = fe.getX(Kt), It = fe.getX(It)), _v0.fromBufferAttribute(ze, Kt), _v1$1.fromBufferAttribute(ze, It), toNormalizedRay(_v0, _v1$1, _ray$3);
40725
- let Zt, zt = at.findClosestRay(_ray$3);
40726
- zt === null && (zt = _ray$3.clone(), at.addRay(zt)), Ue.has(zt) || Ue.set(zt, {
40724
+ fe && (Kt = fe.getX(Kt), It = fe.getX(It)), _v0.fromBufferAttribute(ze, Kt), _v1$1.fromBufferAttribute(ze, It), toNormalizedRay(_v0, _v1$1, _ray$2);
40725
+ let Zt, zt = at.findClosestRay(_ray$2);
40726
+ zt === null && (zt = _ray$2.clone(), at.addRay(zt)), Ue.has(zt) || Ue.set(zt, {
40727
40727
  forward: [],
40728
40728
  reverse: [],
40729
40729
  ray: zt
40730
40730
  }), Zt = Ue.get(zt);
40731
40731
  let Ft = getProjectedDistance(zt, _v0), kt = getProjectedDistance(zt, _v1$1);
40732
- Ft > kt && ([Ft, kt] = [kt, Ft]), _ray$3.direction.dot(zt.direction) < 0 ? Zt.reverse.push({ start: Ft, end: kt, index: Lt }) : Zt.forward.push({ start: Ft, end: kt, index: Lt });
40732
+ Ft > kt && ([Ft, kt] = [kt, Ft]), _ray$2.direction.dot(zt.direction) < 0 ? Zt.reverse.push({ start: Ft, end: kt, index: Lt }) : Zt.forward.push({ start: Ft, end: kt, index: Lt });
40733
40733
  }
40734
40734
  return Ue.forEach(({ forward: ot, reverse: Gt }, Lt) => {
40735
40735
  matchEdges(ot, Gt, Fe, n), ot.length === 0 && Gt.length === 0 && Ue.delete(Lt);
@@ -41107,27 +41107,27 @@ class IntersectionMap {
41107
41107
  r[e] || (r[e] = [], fe.push(e)), r[e].push(n);
41108
41108
  }
41109
41109
  }
41110
- const ADDITION = 0, SUBTRACTION = 1, REVERSE_SUBTRACTION = 2, INTERSECTION = 3, DIFFERENCE = 4, HOLLOW_SUBTRACTION = 5, HOLLOW_INTERSECTION = 6, _ray$2 = new Ray(), _matrix$1 = new Matrix4(), _tri$1 = new Triangle(), _vec3 = new Vector3(), _vec4a = new Vector4(), _vec4b = new Vector4(), _vec4c = new Vector4(), _vec4_0 = new Vector4(), _vec4_1 = new Vector4(), _vec4_2 = new Vector4(), _edge = new Line3(), _normal = new Vector3(), JITTER_EPSILON = 1e-8, OFFSET_EPSILON = 1e-15, BACK_SIDE = -1, FRONT_SIDE = 1, COPLANAR_OPPOSITE = -2, COPLANAR_ALIGNED = 2, INVERT_TRI = 0, ADD_TRI = 1, SKIP_TRI = 2, FLOATING_COPLANAR_EPSILON = 1e-14;
41110
+ const ADDITION = 0, SUBTRACTION = 1, REVERSE_SUBTRACTION = 2, INTERSECTION = 3, DIFFERENCE = 4, HOLLOW_SUBTRACTION = 5, HOLLOW_INTERSECTION = 6, _ray$1 = new Ray(), _matrix$1 = new Matrix4(), _tri$1 = new Triangle(), _vec3 = new Vector3(), _vec4a = new Vector4(), _vec4b = new Vector4(), _vec4c = new Vector4(), _vec4_0 = new Vector4(), _vec4_1 = new Vector4(), _vec4_2 = new Vector4(), _edge = new Line3(), _normal = new Vector3(), JITTER_EPSILON = 1e-8, OFFSET_EPSILON = 1e-15, BACK_SIDE = -1, FRONT_SIDE = 1, COPLANAR_OPPOSITE = -2, COPLANAR_ALIGNED = 2, INVERT_TRI = 0, ADD_TRI = 1, SKIP_TRI = 2, FLOATING_COPLANAR_EPSILON = 1e-14;
41111
41111
  let _debugContext = null;
41112
41112
  function setDebugContext(_) {
41113
41113
  _debugContext = _;
41114
41114
  }
41115
41115
  function getHitSide(_, e) {
41116
- _.getMidpoint(_ray$2.origin), _.getNormal(_ray$2.direction);
41117
- const n = e.raycastFirst(_ray$2, DoubleSide);
41118
- return !!(n && _ray$2.direction.dot(n.face.normal) > 0) ? BACK_SIDE : FRONT_SIDE;
41116
+ _.getMidpoint(_ray$1.origin), _.getNormal(_ray$1.direction);
41117
+ const n = e.raycastFirst(_ray$1, DoubleSide);
41118
+ return !!(n && _ray$1.direction.dot(n.face.normal) > 0) ? BACK_SIDE : FRONT_SIDE;
41119
41119
  }
41120
41120
  function getHitSideWithCoplanarCheck(_, e) {
41121
41121
  function n() {
41122
41122
  return Math.random() - 0.5;
41123
41123
  }
41124
- _.getNormal(_normal), _ray$2.direction.copy(_normal), _.getMidpoint(_ray$2.origin);
41124
+ _.getNormal(_normal), _ray$1.direction.copy(_normal), _.getMidpoint(_ray$1.origin);
41125
41125
  const r = 3;
41126
41126
  let fe = 0, ze = 1 / 0;
41127
41127
  for (let Fe = 0; Fe < r; Fe++) {
41128
- _ray$2.direction.x += n() * JITTER_EPSILON, _ray$2.direction.y += n() * JITTER_EPSILON, _ray$2.direction.z += n() * JITTER_EPSILON, _ray$2.direction.multiplyScalar(-1);
41129
- const Ue = e.raycastFirst(_ray$2, DoubleSide);
41130
- if (!!(Ue && _ray$2.direction.dot(Ue.face.normal) > 0) && fe++, Ue !== null && (ze = Math.min(ze, Ue.distance)), ze <= OFFSET_EPSILON)
41128
+ _ray$1.direction.x += n() * JITTER_EPSILON, _ray$1.direction.y += n() * JITTER_EPSILON, _ray$1.direction.z += n() * JITTER_EPSILON, _ray$1.direction.multiplyScalar(-1);
41129
+ const Ue = e.raycastFirst(_ray$1, DoubleSide);
41130
+ if (!!(Ue && _ray$1.direction.dot(Ue.face.normal) > 0) && fe++, Ue !== null && (ze = Math.min(ze, Ue.distance)), ze <= OFFSET_EPSILON)
41131
41131
  return Ue.face.normal.dot(_normal) > 0 ? COPLANAR_ALIGNED : COPLANAR_OPPOSITE;
41132
41132
  if (fe / r > 0.5 || (Fe - fe + 1) / r > 0.5)
41133
41133
  break;
@@ -41560,8 +41560,8 @@ class RectAreaLightUniformsLib {
41560
41560
  UniformsLib.LTC_FLOAT_1 = e, UniformsLib.LTC_FLOAT_2 = n, UniformsLib.LTC_HALF_1 = r, UniformsLib.LTC_HALF_2 = fe;
41561
41561
  }
41562
41562
  }
41563
- const _viewport = new Vector4(), _start = new Vector3(), _end = new Vector3(), _start4 = new Vector4(), _end4 = new Vector4(), _ssOrigin = new Vector4(), _ssOrigin3 = new Vector3(), _mvMatrix = new Matrix4(), _line = new Line3(), _closestPoint = new Vector3(), _box = new Box3(), _sphere$1 = new Sphere$1(), _clipToWorldVector = new Vector4();
41564
- let _ray$1, _lineWidth;
41563
+ const _viewport = new Vector4(), _start = new Vector3(), _end = new Vector3(), _start4 = new Vector4(), _end4 = new Vector4(), _ssOrigin = new Vector4(), _ssOrigin3 = new Vector3(), _mvMatrix = new Matrix4(), _line = new Line3(), _closestPoint = new Vector3(), _box = new Box3(), _sphere = new Sphere$1(), _clipToWorldVector = new Vector4();
41564
+ let _ray, _lineWidth;
41565
41565
  function getWorldSpaceHalfWidth(_, e, n) {
41566
41566
  return _clipToWorldVector.set(0, 0, -e, 1).applyMatrix4(_.projectionMatrix), _clipToWorldVector.multiplyScalar(1 / _clipToWorldVector.w), _clipToWorldVector.x = _lineWidth / n.width, _clipToWorldVector.y = _lineWidth / n.height, _clipToWorldVector.applyMatrix4(_.projectionMatrixInverse), _clipToWorldVector.multiplyScalar(1 / _clipToWorldVector.w), Math.abs(Math.max(_clipToWorldVector.x, _clipToWorldVector.y));
41567
41567
  }
@@ -41570,10 +41570,10 @@ function raycastWorldUnits(_, e) {
41570
41570
  for (let Ue = 0, nt = Fe; Ue < nt; Ue++) {
41571
41571
  _line.start.fromBufferAttribute(fe, Ue), _line.end.fromBufferAttribute(ze, Ue), _line.applyMatrix4(n);
41572
41572
  const at = new Vector3(), ot = new Vector3();
41573
- _ray$1.distanceSqToSegment(_line.start, _line.end, ot, at), ot.distanceTo(at) < _lineWidth * 0.5 && e.push({
41573
+ _ray.distanceSqToSegment(_line.start, _line.end, ot, at), ot.distanceTo(at) < _lineWidth * 0.5 && e.push({
41574
41574
  point: ot,
41575
41575
  pointOnLine: at,
41576
- distance: _ray$1.origin.distanceTo(ot),
41576
+ distance: _ray.origin.distanceTo(ot),
41577
41577
  object: _,
41578
41578
  face: null,
41579
41579
  faceIndex: Ue,
@@ -41584,7 +41584,7 @@ function raycastWorldUnits(_, e) {
41584
41584
  }
41585
41585
  function raycastScreenSpace(_, e, n) {
41586
41586
  const r = e.projectionMatrix, ze = _.material.resolution, Fe = _.matrixWorld, Ue = _.geometry, nt = Ue.attributes.instanceStart, at = Ue.attributes.instanceEnd, ot = Math.min(Ue.instanceCount, nt.count), Gt = -e.near;
41587
- _ray$1.at(1, _ssOrigin), _ssOrigin.w = 1, _ssOrigin.applyMatrix4(e.matrixWorldInverse), _ssOrigin.applyMatrix4(r), _ssOrigin.multiplyScalar(1 / _ssOrigin.w), _ssOrigin.x *= ze.x / 2, _ssOrigin.y *= ze.y / 2, _ssOrigin.z = 0, _ssOrigin3.copy(_ssOrigin), _mvMatrix.multiplyMatrices(e.matrixWorldInverse, Fe);
41587
+ _ray.at(1, _ssOrigin), _ssOrigin.w = 1, _ssOrigin.applyMatrix4(e.matrixWorldInverse), _ssOrigin.applyMatrix4(r), _ssOrigin.multiplyScalar(1 / _ssOrigin.w), _ssOrigin.x *= ze.x / 2, _ssOrigin.y *= ze.y / 2, _ssOrigin.z = 0, _ssOrigin3.copy(_ssOrigin), _mvMatrix.multiplyMatrices(e.matrixWorldInverse, Fe);
41588
41588
  for (let Lt = 0, Xt = ot; Lt < Xt; Lt++) {
41589
41589
  if (_start4.fromBufferAttribute(nt, Lt), _end4.fromBufferAttribute(at, Lt), _start4.w = 1, _end4.w = 1, _start4.applyMatrix4(_mvMatrix), _end4.applyMatrix4(_mvMatrix), _start4.z > Gt && _end4.z > Gt)
41590
41590
  continue;
@@ -41602,10 +41602,10 @@ function raycastScreenSpace(_, e, n) {
41602
41602
  if (Zt && zt) {
41603
41603
  _line.start.fromBufferAttribute(nt, Lt), _line.end.fromBufferAttribute(at, Lt), _line.start.applyMatrix4(Fe), _line.end.applyMatrix4(Fe);
41604
41604
  const Ft = new Vector3(), kt = new Vector3();
41605
- _ray$1.distanceSqToSegment(_line.start, _line.end, kt, Ft), n.push({
41605
+ _ray.distanceSqToSegment(_line.start, _line.end, kt, Ft), n.push({
41606
41606
  point: kt,
41607
41607
  pointOnLine: Ft,
41608
- distance: _ray$1.origin.distanceTo(kt),
41608
+ distance: _ray.origin.distanceTo(kt),
41609
41609
  object: _,
41610
41610
  face: null,
41611
41611
  faceIndex: Lt,
@@ -41649,27 +41649,27 @@ class LineSegments2 extends Mesh {
41649
41649
  const r = this.material.worldUnits, fe = e.camera;
41650
41650
  fe === null && !r && console.error('LineSegments2: "Raycaster.camera" needs to be set in order to raycast against LineSegments2 while worldUnits is set to false.');
41651
41651
  const ze = e.params.Line2 !== void 0 && e.params.Line2.threshold || 0;
41652
- _ray$1 = e.ray;
41652
+ _ray = e.ray;
41653
41653
  const Fe = this.matrixWorld, Ue = this.geometry, nt = this.material;
41654
- _lineWidth = nt.linewidth + ze, Ue.boundingSphere === null && Ue.computeBoundingSphere(), _sphere$1.copy(Ue.boundingSphere).applyMatrix4(Fe);
41654
+ _lineWidth = nt.linewidth + ze, Ue.boundingSphere === null && Ue.computeBoundingSphere(), _sphere.copy(Ue.boundingSphere).applyMatrix4(Fe);
41655
41655
  let at;
41656
41656
  if (r)
41657
41657
  at = _lineWidth * 0.5;
41658
41658
  else {
41659
- const Gt = Math.max(fe.near, _sphere$1.distanceToPoint(_ray$1.origin));
41659
+ const Gt = Math.max(fe.near, _sphere.distanceToPoint(_ray.origin));
41660
41660
  at = getWorldSpaceHalfWidth(fe, Gt, nt.resolution);
41661
41661
  }
41662
- if (_sphere$1.radius += at, _ray$1.intersectsSphere(_sphere$1) === !1)
41662
+ if (_sphere.radius += at, _ray.intersectsSphere(_sphere) === !1)
41663
41663
  return;
41664
41664
  Ue.boundingBox === null && Ue.computeBoundingBox(), _box.copy(Ue.boundingBox).applyMatrix4(Fe);
41665
41665
  let ot;
41666
41666
  if (r)
41667
41667
  ot = _lineWidth * 0.5;
41668
41668
  else {
41669
- const Gt = Math.max(fe.near, _box.distanceToPoint(_ray$1.origin));
41669
+ const Gt = Math.max(fe.near, _box.distanceToPoint(_ray.origin));
41670
41670
  ot = getWorldSpaceHalfWidth(fe, Gt, nt.resolution);
41671
41671
  }
41672
- _box.expandByScalar(ot), _ray$1.intersectsBox(_box) !== !1 && (r ? raycastWorldUnits(this, n) : raycastScreenSpace(this, fe, n));
41672
+ _box.expandByScalar(ot), _ray.intersectsBox(_box) !== !1 && (r ? raycastWorldUnits(this, n) : raycastScreenSpace(this, fe, n));
41673
41673
  }
41674
41674
  onBeforeRender(e) {
41675
41675
  const n = this.material.uniforms;
@@ -42842,7 +42842,7 @@ class PanelVSync extends Panel {
42842
42842
  this.canvas.style.transform = `translate(${e}px, ${n}px)`;
42843
42843
  }
42844
42844
  }
42845
- const _Stats = class Pn {
42845
+ const _Stats = class Wn {
42846
42846
  constructor({
42847
42847
  trackGPU: e = !1,
42848
42848
  trackCPT: n = !1,
@@ -42870,7 +42870,7 @@ const _Stats = class Pn {
42870
42870
  this.resizePanel(this.fpsPanel), this.resizePanel(this.msPanel), this.gpuPanel && this.resizePanel(this.gpuPanel), this.gpuPanelCompute && this.resizePanel(this.gpuPanelCompute);
42871
42871
  }, this.mode = Gt, this.horizontal = ot, this.minimal = at, this.trackGPU = e, this.trackCPT = n, this.trackHz = r, this.samplesLog = Fe, this.samplesGraph = Ue, this.precision = nt, this.logsPerSecond = fe, this.graphsPerSecond = ze;
42872
42872
  const Lt = performance.now();
42873
- this.prevGraphTime = Lt, this.dom = document.createElement("div"), this.initializeDOM(), this.beginTime = performance.now(), this.prevTextTime = this.beginTime, this.prevCpuTime = this.beginTime, this._panelId = 0, this.fpsPanel = this.addPanel(new Pn.Panel("FPS", "#0ff", "#002")), this.msPanel = this.addPanel(new Pn.Panel("CPU", "#0f0", "#020")), this.trackHz === !0 && (this.vsyncPanel = new PanelVSync("", "#f0f", "#202"), this.dom.appendChild(this.vsyncPanel.canvas), this.vsyncPanel.setOffset(56, 35)), this.setupEventListeners();
42873
+ this.prevGraphTime = Lt, this.dom = document.createElement("div"), this.initializeDOM(), this.beginTime = performance.now(), this.prevTextTime = this.beginTime, this.prevCpuTime = this.beginTime, this._panelId = 0, this.fpsPanel = this.addPanel(new Wn.Panel("FPS", "#0ff", "#002")), this.msPanel = this.addPanel(new Wn.Panel("CPU", "#0f0", "#020")), this.trackHz === !0 && (this.vsyncPanel = new PanelVSync("", "#f0f", "#202"), this.dom.appendChild(this.vsyncPanel.canvas), this.vsyncPanel.setOffset(56, 35)), this.setupEventListeners();
42874
42874
  }
42875
42875
  initializeDOM() {
42876
42876
  this.dom.style.cssText = `
@@ -42908,7 +42908,7 @@ const _Stats = class Pn {
42908
42908
  });
42909
42909
  }
42910
42910
  initializeWebGPUPanels() {
42911
- this.trackGPU && (this.gpuPanel = this.addPanel(new Pn.Panel("GPU", "#ff0", "#220"))), this.trackCPT && (this.gpuPanelCompute = this.addPanel(new Pn.Panel("CPT", "#e1e1e1", "#212121")));
42911
+ this.trackGPU && (this.gpuPanel = this.addPanel(new Wn.Panel("GPU", "#ff0", "#220"))), this.trackCPT && (this.gpuPanelCompute = this.addPanel(new Wn.Panel("CPT", "#e1e1e1", "#212121")));
42912
42912
  }
42913
42913
  initializeWebGL(e) {
42914
42914
  if (e instanceof WebGL2RenderingContext)
@@ -42923,7 +42923,7 @@ const _Stats = class Pn {
42923
42923
  return !0;
42924
42924
  }
42925
42925
  initializeGPUTracking() {
42926
- this.gl && (this.ext = this.gl.getExtension("EXT_disjoint_timer_query_webgl2"), this.ext && (this.gpuPanel = this.addPanel(new Pn.Panel("GPU", "#ff0", "#220"))));
42926
+ this.gl && (this.ext = this.gl.getExtension("EXT_disjoint_timer_query_webgl2"), this.ext && (this.gpuPanel = this.addPanel(new Wn.Panel("GPU", "#ff0", "#220"))));
42927
42927
  }
42928
42928
  begin() {
42929
42929
  this.beginProfiling("cpu-started"), !(!this.gl || !this.ext) && (this.activeQuery && this.gl.endQuery(this.ext.TIME_ELAPSED_EXT), this.activeQuery = this.gl.createQuery(), this.activeQuery && this.gl.beginQuery(this.ext.TIME_ELAPSED_EXT, this.activeQuery));
@@ -46093,7 +46093,7 @@ class EXRLoader extends DataTextureLoader {
46093
46093
  }
46094
46094
  return a0;
46095
46095
  }
46096
- const Zn = { value: 0 }, zn = new DataView(e), Vn = new Uint8Array(e), Tn = kn(zn, e, Zn), Ln = Hn(Tn, zn, Vn, Zn, this.type, this.outputFormat);
46096
+ const _n = { value: 0 }, zn = new DataView(e), wn = new Uint8Array(e), Tn = kn(zn, e, _n), Ln = Hn(Tn, zn, wn, _n, this.type, this.outputFormat);
46097
46097
  if (Ln.decode(), Ln.shouldExpand) {
46098
46098
  const r0 = Ln.byteArray;
46099
46099
  if (this.outputFormat == RGBAFormat)
@@ -59053,7 +59053,7 @@ class Arc extends H$3 {
59053
59053
  this.update();
59054
59054
  const r = yield this.line.instantiate(ln(Gi({}, n), {
59055
59055
  recursive: !!this.pencil.userData.EditorEnv
59056
- })), fe = yield Wn(Arc.prototype, this, "instantiate").call(this, ln(Gi({}, n), {
59056
+ })), fe = yield Vn(Arc.prototype, this, "instantiate").call(this, ln(Gi({}, n), {
59057
59057
  recursive: !1,
59058
59058
  create: (ze) => {
59059
59059
  ze.line = r, ze.object3d = r.object3d, ze.children.length && (ze.children.forEach((Fe) => {
@@ -102255,7 +102255,7 @@ const type = "FeatureCollection", features = [
102255
102255
  ], worldExclATALite = {
102256
102256
  type,
102257
102257
  features
102258
- }, chinaJson = json100000, chinaLiteJson = json100000Lite, chinaBbox = adcodeAll[1e5].b, worldJson = ln(Gi({}, world$1), {
102258
+ }, chinaJson = json100000, chinaLiteJson = json100000Lite, chinaBbox = adcodeAll$1[1e5].b, worldJson = ln(Gi({}, world$1), {
102259
102259
  features: world$1.features.map((_) => {
102260
102260
  if (_.properties.name === "索马里兰" || _.properties.full_name.endsWith(")") || _.properties.full_name.includes("美属") || _.properties.full_name.includes("英属") || _.properties.full_name.includes("法属") || _.properties.full_name.includes("荷属") || _.properties.full_name.includes("本土外"))
102261
102261
  return null;
@@ -138430,7 +138430,9 @@ const continentsBbox = continentsBboxObj, continentsM49 = {
138430
138430
  ))
138431
138431
  }, _),
138432
138432
  {}
138433
- ), continentsLiteJson = continentsLite, findAdcodeInfo = (_) => _ === 0 ? {
138433
+ ), continentsLiteJson = continentsLite, adcodeAll = Gi({}, adcodeAll$1), extendsAdcodeAll = (_) => {
138434
+ Object.assign(adcodeAll, _);
138435
+ }, findAdcodeInfo = (_) => _ === 0 ? {
138434
138436
  name: "世界",
138435
138437
  adcode: 0,
138436
138438
  lng: 0,
@@ -138439,7 +138441,7 @@ const continentsBbox = continentsBboxObj, continentsM49 = {
138439
138441
  parent: 0,
138440
138442
  c: [],
138441
138443
  b: [...worldExclATABbox]
138442
- } : /^\d{6}$/.test(`${_}`) ? adcodeAll[_] : continentsType.find((e) => e.adcode === _), findNameInfo = (_) => {
138444
+ } : /^\d{6}$/.test(`${_}`) ? adcodeAll[_] : continentsType.find((e) => e.adcode === _), findAdcodeInfoByName = (_) => {
138443
138445
  if (_ === "世界")
138444
138446
  return findAdcodeInfo(0);
138445
138447
  {
@@ -143351,7 +143353,7 @@ const objs$1 = ln(Gi({}, objs$3), {
143351
143353
  }
143352
143354
  handleSetting(n, r) {
143353
143355
  return J0(this, null, function* () {
143354
- return yield Wn(Yn.prototype, this, "handleSetting").call(this, n, r), n === "autoRotateSpeed" ? this.pencil.autoRotate(r) : n === "autoRotate" && (r ? this.settings.autoRotateSpeed = -20 : this.settings.autoRotateSpeed = 0), r;
143356
+ return yield Vn(Yn.prototype, this, "handleSetting").call(this, n, r), n === "autoRotateSpeed" ? this.pencil.autoRotate(r) : n === "autoRotate" && (r ? this.settings.autoRotateSpeed = -20 : this.settings.autoRotateSpeed = 0), r;
143355
143357
  });
143356
143358
  }
143357
143359
  show() {
@@ -144319,7 +144321,7 @@ const getLabelElement = (_) => {
144319
144321
  return n === "district" && fe === "province" && e ? "city" : n;
144320
144322
  } else if (continentsType.find((n) => n.adcode === _))
144321
144323
  return "continent";
144322
- }, _n = class _n extends Base {
144324
+ }, Pn = class Pn extends Base {
144323
144325
  constructor() {
144324
144326
  super(...arguments);
144325
144327
  w0(this, "leadObjs", objs);
@@ -144444,7 +144446,7 @@ const getLabelElement = (_) => {
144444
144446
  }
144445
144447
  handleSetting(n, r) {
144446
144448
  return J0(this, null, function* () {
144447
- return yield Wn(_n.prototype, this, "handleSetting").call(this, n, r), n === "label" ? r === !1 ? (this.eraseLabels(), this.options.showLabel = !1) : (this.settings.labelLite = !1, yield this.settings.labelLite, this.options.showLabel = !0, yield this.drawLabels()) : n === "labelLite" ? r === !1 ? (this.eraseLabels(), this.options.showLabel = !1) : (this.settings.label = !1, yield this.settings.label, this.options.showLabel = "lite", yield this.drawLabels()) : n === "shadowMap" && (r === !1 ? this.shadowMapDisabled() : yield this.shadowMapEnabled()), r;
144449
+ return yield Vn(Pn.prototype, this, "handleSetting").call(this, n, r), n === "label" ? r === !1 ? (this.eraseLabels(), this.options.showLabel = !1) : (this.settings.labelLite = !1, yield this.settings.labelLite, this.options.showLabel = !0, yield this.drawLabels()) : n === "labelLite" ? r === !1 ? (this.eraseLabels(), this.options.showLabel = !1) : (this.settings.label = !1, yield this.settings.label, this.options.showLabel = "lite", yield this.drawLabels()) : n === "shadowMap" && (r === !1 ? this.shadowMapDisabled() : yield this.shadowMapEnabled()), r;
144448
144450
  });
144449
144451
  }
144450
144452
  init() {
@@ -144474,8 +144476,7 @@ const getLabelElement = (_) => {
144474
144476
  }
144475
144477
  initCityVis(n, r = !1) {
144476
144478
  return J0(this, null, function* () {
144477
- var Ue;
144478
- if ((Ue = this.options.fixCity) != null && Ue[n] && (n = this.options.fixCity[n]), n === 71e4)
144479
+ if (n === 71e4)
144479
144480
  return this.settings.mouseLeft = Xi.SCREEN_PAN, yield this.settings.mouseLeft, this.pencil.camera.userData.up = "0,0,1", null;
144480
144481
  const fe = new City({
144481
144482
  container: this.container,
@@ -144804,7 +144805,7 @@ const getLabelElement = (_) => {
144804
144805
  }
144805
144806
  showAction() {
144806
144807
  return J0(this, null, function* () {
144807
- Wn(_n.prototype, this, "showAction").call(this), this.useSaveCamera(`map-${this.options.adcode}`);
144808
+ Vn(Pn.prototype, this, "showAction").call(this), this.useSaveCamera(`map-${this.options.adcode}`);
144808
144809
  const n = this.lead.group;
144809
144810
  if (this.mapHistory[0]) {
144810
144811
  const { stop: r, start: fe } = sinusoidalInOut({
@@ -144829,7 +144830,7 @@ const getLabelElement = (_) => {
144829
144830
  n.position.z = -this.mapHistory[0].depth * r;
144830
144831
  }
144831
144832
  }).start(), setTimeout(() => {
144832
- Wn(_n.prototype, this, "hide").call(this);
144833
+ Vn(Pn.prototype, this, "hide").call(this);
144833
144834
  });
144834
144835
  });
144835
144836
  }
@@ -144879,8 +144880,7 @@ const getLabelElement = (_) => {
144879
144880
  return Math.max(fe, ze);
144880
144881
  }
144881
144882
  getAdcodeShowLevel(n, r = !0) {
144882
- var fe;
144883
- return (fe = this.options.fixCity) != null && fe[n] && (n = this.options.fixCity[n]), getAdcodeShowLevel(n, r);
144883
+ return getAdcodeShowLevel(n, r);
144884
144884
  }
144885
144885
  handleClick(n) {
144886
144886
  const { drillDownRestrictions: r } = this.options;
@@ -145383,8 +145383,8 @@ const getLabelElement = (_) => {
145383
145383
  }), this.parentBg.length = 0, (fe = this.continentsBg) == null || fe.dispose(), this.continentsBg = void 0, this.mapHistory.length = 0, super.dispose();
145384
145384
  }
145385
145385
  };
145386
- w0(_n, "VisName", "map"), w0(_n, "getAdcodeShowLevel", getAdcodeShowLevel), w0(_n, "findAdcodeInfo", findAdcodeInfo), w0(_n, "findNameInfo", findNameInfo);
145387
- let Map$1 = _n;
145386
+ w0(Pn, "VisName", "map");
145387
+ let Map$1 = Pn;
145388
145388
  class MapManager {
145389
145389
  constructor(e) {
145390
145390
  w0(this, "container");
@@ -145452,7 +145452,7 @@ class MapManager {
145452
145452
  createMapInstance(e, n = !1) {
145453
145453
  return J0(this, null, function* () {
145454
145454
  var ot, Gt;
145455
- const r = Object.values(this.mapInstances)[0], fe = (ot = Map$1.getAdcodeShowLevel(e)) != null ? ot : "country", ze = Map$1.findAdcodeInfo(e), Fe = r == null ? void 0 : r.pencil;
145455
+ const r = Object.values(this.mapInstances)[0], fe = (ot = getAdcodeShowLevel(e)) != null ? ot : "country", ze = findAdcodeInfo(e), Fe = r == null ? void 0 : r.pencil;
145456
145456
  this.container.style.cursor = "default";
145457
145457
  const Ue = this.mapInstances[fe];
145458
145458
  if (Ue)
@@ -145548,7 +145548,7 @@ class MapManager {
145548
145548
  setZoom(e) {
145549
145549
  var ze;
145550
145550
  if (!this.currentMap || this.currentZoom === e) return;
145551
- const n = (ze = Map$1.getAdcodeShowLevel(this.currentMap.options.adcode)) != null ? ze : "country", r = this.mapDistances[n];
145551
+ const n = (ze = getAdcodeShowLevel(this.currentMap.options.adcode)) != null ? ze : "country", r = this.mapDistances[n];
145552
145552
  if (!r) return;
145553
145553
  const fe = r / e;
145554
145554
  this.currentZoom = e, this.currentMap.pencil.controls.distance = fe;
@@ -145607,63 +145607,7 @@ class MapManager {
145607
145607
  }), this.mapInstances = {}, this.currentMap = null, Editor.clearUrlCache();
145608
145608
  }
145609
145609
  }
145610
- w0(MapManager, "findNameInfo", Map$1.findNameInfo), w0(MapManager, "getAdcodeShowLevel", Map$1.getAdcodeShowLevel), w0(MapManager, "findAdcodeInfo", Map$1.findAdcodeInfo);
145611
- const _inverseMatrix = /* @__PURE__ */ new Matrix4(), _ray = /* @__PURE__ */ new Ray(), _sphere = /* @__PURE__ */ new Sphere$1(), _position$2 = /* @__PURE__ */ new Vector3();
145612
- function proposedRaycast(_, e) {
145613
- const n = this.geometry, r = this.matrixWorld, fe = _.params.Points.threshold, ze = n.drawRange;
145614
- n.boundingSphere === null && n.computeBoundingSphere(), _sphere.copy(n.boundingSphere), _sphere.applyMatrix4(r), _sphere.radius += fe, _inverseMatrix.copy(r).invert(), _ray.copy(_.ray).applyMatrix4(_inverseMatrix);
145615
- const Fe = fe / ((this.scale.x + this.scale.y + this.scale.z) / 3), Ue = n.index, at = n.attributes.position;
145616
- if (Ue !== null) {
145617
- const ot = Math.max(0, ze.start), Gt = Math.min(Ue.count, ze.start + ze.count);
145618
- for (let Lt = ot, Xt = Gt; Lt < Xt; Lt++) {
145619
- const Vt = Ue.getX(Lt);
145620
- _position$2.fromBufferAttribute(at, Vt), testPoint(
145621
- _position$2,
145622
- Vt,
145623
- Fe,
145624
- r,
145625
- _,
145626
- e,
145627
- this
145628
- );
145629
- }
145630
- } else {
145631
- const ot = Math.max(0, ze.start), Gt = Math.min(
145632
- at.count,
145633
- ze.start + ze.count
145634
- );
145635
- for (let Lt = ot, Xt = Gt; Lt < Xt; Lt++)
145636
- _position$2.fromBufferAttribute(at, Lt), testPoint(
145637
- _position$2,
145638
- Lt,
145639
- Fe,
145640
- r,
145641
- _,
145642
- e,
145643
- this
145644
- );
145645
- }
145646
- }
145647
- function testPoint(_, e, n, r, fe, ze, Fe) {
145648
- const Ue = new Vector3();
145649
- _ray.closestPointToPoint(_, Ue), Ue.applyMatrix4(r);
145650
- const nt = fe.ray.origin.distanceTo(_), at = Ue.distanceTo(_), ot = Math.asin(
145651
- at / nt
145652
- );
145653
- if (ot < n) {
145654
- if (nt < fe.near || nt > fe.far)
145655
- return;
145656
- ze.push({
145657
- distance: nt,
145658
- distanceToRay: at,
145659
- angleToRay: ot,
145660
- point: Ue,
145661
- index: e,
145662
- face: null,
145663
- object: Fe
145664
- });
145665
- }
145666
- }
145610
+ w0(MapManager, "findAdcodeInfoByName", findAdcodeInfoByName), w0(MapManager, "getAdcodeShowLevel", getAdcodeShowLevel), w0(MapManager, "findAdcodeInfo", findAdcodeInfo), w0(MapManager, "extendsAdcodeAll", extendsAdcodeAll);
145667
145611
  const access = {
145668
145612
  set token(_) {
145669
145613
  accessToken.token = _;
@@ -145680,8 +145624,11 @@ export {
145680
145624
  VERSION,
145681
145625
  access,
145682
145626
  animation as animationUtils,
145627
+ extendsAdcodeAll,
145628
+ findAdcodeInfo,
145629
+ findAdcodeInfoByName,
145630
+ getAdcodeShowLevel,
145683
145631
  getCityConfig,
145684
145632
  getMapConfig,
145685
- proposedRaycast,
145686
145633
  removeCameraHistory
145687
145634
  };
package/dist/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- declare const _default: "0.30.0-beta.51";
1
+ declare const _default: "0.30.0-beta.52";
2
2
  export default _default;