vis-core 0.24.5 → 0.24.7

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.
@@ -2,9 +2,9 @@
2
2
  var J1 = Object.defineProperty, k1 = Object.defineProperties;
3
3
  var K1 = Object.getOwnPropertyDescriptors;
4
4
  var M1 = Object.getOwnPropertySymbols, z1 = Object.getPrototypeOf, U1 = Object.prototype.hasOwnProperty, P1 = Object.prototype.propertyIsEnumerable, B1 = Reflect.get;
5
- var b1 = (c, e) => (e = Symbol[c]) ? e : Symbol.for("Symbol." + c), E1 = (c) => {
5
+ var G1 = (c, e) => (e = Symbol[c]) ? e : Symbol.for("Symbol." + c), E1 = (c) => {
6
6
  throw TypeError(c);
7
- }, a1 = Math.pow, T1 = (c, e, s) => e in c ? J1(c, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : c[e] = s, ai = (c, e) => {
7
+ }, l1 = Math.pow, T1 = (c, e, s) => e in c ? J1(c, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : c[e] = s, ai = (c, e) => {
8
8
  for (var s in e || (e = {}))
9
9
  U1.call(e, s) && T1(c, s, e[s]);
10
10
  if (M1)
@@ -13,7 +13,7 @@ var b1 = (c, e) => (e = Symbol[c]) ? e : Symbol.for("Symbol." + c), E1 = (c) =>
13
13
  return c;
14
14
  }, zi = (c, e) => k1(c, K1(e));
15
15
  var F0 = (c, e, s) => T1(c, typeof e != "symbol" ? e + "" : e, s);
16
- var l1 = (c, e, s) => B1(z1(c), s, e);
16
+ var n1 = (c, e, s) => B1(z1(c), s, e);
17
17
  var q0 = (c, e, s) => new Promise((r, T) => {
18
18
  var de = (Ke) => {
19
19
  try {
@@ -33,8 +33,8 @@ var q0 = (c, e, s) => new Promise((r, T) => {
33
33
  this[0] = c, this[1] = e;
34
34
  };
35
35
  var N1 = (c) => {
36
- var e = c[b1("asyncIterator")], s = !1, r, T = {};
37
- return e == null ? (e = c[b1("iterator")](), r = (de) => T[de] = (Xe) => e[de](Xe)) : (e = e.call(c), r = (de) => T[de] = (Xe) => {
36
+ var e = c[G1("asyncIterator")], s = !1, r, T = {};
37
+ return e == null ? (e = c[G1("iterator")](), r = (de) => T[de] = (Xe) => e[de](Xe)) : (e = e.call(c), r = (de) => T[de] = (Xe) => {
38
38
  if (s) {
39
39
  if (s = !1, de === "throw") throw Xe;
40
40
  return Xe;
@@ -46,10 +46,10 @@ var N1 = (c) => {
46
46
  Ke instanceof Object || E1("Object expected"), Je(Ke);
47
47
  }), 1)
48
48
  };
49
- }), T[b1("iterator")] = () => T, r("next"), "throw" in e ? r("throw") : T.throw = (de) => {
49
+ }), T[G1("iterator")] = () => T, r("next"), "throw" in e ? r("throw") : T.throw = (de) => {
50
50
  throw de;
51
51
  }, "return" in e && r("return"), T;
52
- }, F1 = (c, e, s) => (e = c[b1("asyncIterator")]) ? e.call(c) : (c = c[b1("iterator")](), e = {}, s = (r, T) => (T = c[r]) && (e[r] = (de) => new Promise((Xe, Je, Ke) => (de = T.call(c, de), Ke = de.done, Promise.resolve(de.value).then((Qe) => Xe({ value: Qe, done: Ke }), Je)))), s("next"), s("return"), e);
52
+ }, F1 = (c, e, s) => (e = c[G1("asyncIterator")]) ? e.call(c) : (c = c[G1("iterator")](), e = {}, s = (r, T) => (T = c[r]) && (e[r] = (de) => new Promise((Xe, Je, Ke) => (de = T.call(c, de), Ke = de.done, Promise.resolve(de.value).then((Qe) => Xe({ value: Qe, done: Ke }), Je)))), s("next"), s("return"), e);
53
53
  import { KEYUTIL, KJUR, b64tohex } from "jsrsasign";
54
54
  import CryptoJS from "crypto-js";
55
55
  import { makePromiseCreator, WorkerPool, generateUUID as generateUUID$1 } from "esus-lite";
@@ -90,7 +90,7 @@ const publicKeyPEM = "LS0tLS1CRUdJTiBQVUJMSUMgS0VZLS0tLS0KTUlJQklqQU5CZ2txaGtpRz
90
90
  ).toString(CryptoJS.enc.Utf8), qe = JSON.parse($e), rt = Date.now();
91
91
  return !qe.s || qe.s > rt ? (this.token = void 0, "") : qe.e && qe.e < rt ? (this.token = void 0, "") : (qe.isValid = Qe, qe);
92
92
  }
93
- }, version = "0.24.5";
93
+ }, version = "0.24.7";
94
94
  /**
95
95
  * @license
96
96
  * Copyright 2010-2025 Three.js Authors
@@ -4118,7 +4118,7 @@ class Mesh extends Object3D {
4118
4118
  }
4119
4119
  raycast(e, s) {
4120
4120
  const r = this.geometry, T = this.material, de = this.matrixWorld;
4121
- T !== void 0 && (r.boundingSphere === null && r.computeBoundingSphere(), _sphere$6.copy(r.boundingSphere), _sphere$6.applyMatrix4(de), _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) > a1(e.far - e.near, 2))) && (_inverseMatrix$3.copy(de).invert(), _ray$3.copy(e.ray).applyMatrix4(_inverseMatrix$3), !(r.boundingBox !== null && _ray$3.intersectsBox(r.boundingBox) === !1) && this._computeIntersections(e, s, _ray$3)));
4121
+ T !== void 0 && (r.boundingSphere === null && r.computeBoundingSphere(), _sphere$6.copy(r.boundingSphere), _sphere$6.applyMatrix4(de), _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) > l1(e.far - e.near, 2))) && (_inverseMatrix$3.copy(de).invert(), _ray$3.copy(e.ray).applyMatrix4(_inverseMatrix$3), !(r.boundingBox !== null && _ray$3.intersectsBox(r.boundingBox) === !1) && this._computeIntersections(e, s, _ray$3)));
4122
4122
  }
4123
4123
  _computeIntersections(e, s, r) {
4124
4124
  let T;
@@ -21454,7 +21454,7 @@ class WebGLRenderer {
21454
21454
  }, this.clearStencil = function() {
21455
21455
  this.clear(!1, !1, !0);
21456
21456
  }, this.dispose = function() {
21457
- s.removeEventListener("webglcontextlost", ri, !1), s.removeEventListener("webglcontextrestored", gi, !1), s.removeEventListener("webglcontextcreationerror", Wi, !1), Ci.dispose(), Zi.dispose(), Ji.dispose(), ei.dispose(), b0.dispose(), N0.dispose(), Q0.dispose(), wi.dispose(), H0.dispose(), Vi.dispose(), D0.dispose(), D0.removeEventListener("sessionstart", G1), D0.removeEventListener("sessionend", V1), t1.stop();
21457
+ s.removeEventListener("webglcontextlost", ri, !1), s.removeEventListener("webglcontextrestored", gi, !1), s.removeEventListener("webglcontextcreationerror", Wi, !1), Ci.dispose(), Zi.dispose(), Ji.dispose(), ei.dispose(), b0.dispose(), N0.dispose(), Q0.dispose(), wi.dispose(), H0.dispose(), Vi.dispose(), D0.dispose(), D0.removeEventListener("sessionstart", V1), D0.removeEventListener("sessionend", f1), t1.stop();
21458
21458
  };
21459
21459
  function ri(r0) {
21460
21460
  r0.preventDefault(), console.log("THREE.WebGLRenderer: Context Lost."), Jt = !0;
@@ -21562,16 +21562,16 @@ class WebGLRenderer {
21562
21562
  function e1(r0) {
21563
21563
  qi && qi(r0);
21564
21564
  }
21565
- function G1() {
21565
+ function V1() {
21566
21566
  t1.stop();
21567
21567
  }
21568
- function V1() {
21568
+ function f1() {
21569
21569
  t1.start();
21570
21570
  }
21571
21571
  const t1 = new WebGLAnimation();
21572
21572
  t1.setAnimationLoop(e1), typeof self != "undefined" && t1.setContext(self), this.setAnimationLoop = function(r0) {
21573
21573
  qi = r0, D0.setAnimationLoop(r0), r0 === null ? t1.stop() : t1.start();
21574
- }, D0.addEventListener("sessionstart", G1), D0.addEventListener("sessionend", V1), this.render = function(r0, R0) {
21574
+ }, D0.addEventListener("sessionstart", V1), D0.addEventListener("sessionend", f1), this.render = function(r0, R0) {
21575
21575
  if (R0 !== void 0 && R0.isCamera !== !0) {
21576
21576
  console.error("THREE.WebGLRenderer.render: camera is not an instance of THREE.Camera.");
21577
21577
  return;
@@ -21579,9 +21579,9 @@ class WebGLRenderer {
21579
21579
  if (Jt === !0) return;
21580
21580
  if (r0.matrixWorldAutoUpdate === !0 && r0.updateMatrixWorld(), R0.parent === null && R0.matrixWorldAutoUpdate === !0 && R0.updateMatrixWorld(), D0.enabled === !0 && D0.isPresenting === !0 && (D0.cameraAutoUpdate === !0 && D0.updateCamera(R0), R0 = D0.getCamera()), r0.isScene === !0 && r0.onBeforeRender(Tt, r0, R0, t0), st = Ji.get(r0, vt.length), st.init(R0), vt.push(st), bi.multiplyMatrices(R0.projectionMatrix, R0.matrixWorldInverse), M0.setFromProjectionMatrix(bi), j0 = this.localClippingEnabled, A0 = mi.init(this.clippingPlanes, j0), Yt = Zi.get(r0, Zt.length), Yt.init(), Zt.push(Yt), D0.enabled === !0 && D0.isPresenting === !0) {
21581
21581
  const w0 = Tt.xr.getDepthSensingMesh();
21582
- w0 !== null && h1(w0, R0, -1 / 0, Tt.sortObjects);
21582
+ w0 !== null && u1(w0, R0, -1 / 0, Tt.sortObjects);
21583
21583
  }
21584
- h1(r0, R0, 0, Tt.sortObjects), Yt.finish(), Tt.sortObjects === !0 && Yt.sort(m0, I0), ti = D0.enabled === !1 || D0.isPresenting === !1 || D0.hasDepthSensing() === !1, ti && Ci.addToRenderList(Yt, r0), this.info.render.frame++, A0 === !0 && mi.beginShadows();
21584
+ u1(r0, R0, 0, Tt.sortObjects), Yt.finish(), Tt.sortObjects === !0 && Yt.sort(m0, I0), ti = D0.enabled === !1 || D0.isPresenting === !1 || D0.hasDepthSensing() === !1, ti && Ci.addToRenderList(Yt, r0), this.info.render.frame++, A0 === !0 && mi.beginShadows();
21585
21585
  const S0 = st.state.shadowsArray;
21586
21586
  Ri.render(S0, r0, R0), A0 === !0 && mi.endShadows(), this.info.autoReset === !0 && this.info.reset();
21587
21587
  const T0 = Yt.opaque, L0 = Yt.transmissive;
@@ -21590,18 +21590,18 @@ class WebGLRenderer {
21590
21590
  if (L0.length > 0)
21591
21591
  for (let k0 = 0, K0 = w0.length; k0 < K0; k0++) {
21592
21592
  const O0 = w0[k0];
21593
- f1(T0, L0, r0, O0);
21593
+ g1(T0, L0, r0, O0);
21594
21594
  }
21595
21595
  ti && Ci.render(r0);
21596
21596
  for (let k0 = 0, K0 = w0.length; k0 < K0; k0++) {
21597
21597
  const O0 = w0[k0];
21598
- u1(Yt, r0, O0, O0.viewport);
21598
+ m1(Yt, r0, O0, O0.viewport);
21599
21599
  }
21600
21600
  } else
21601
- L0.length > 0 && f1(T0, L0, r0, R0), ti && Ci.render(r0), u1(Yt, r0, R0);
21601
+ L0.length > 0 && g1(T0, L0, r0, R0), ti && Ci.render(r0), m1(Yt, r0, R0);
21602
21602
  t0 !== null && e0 === 0 && (V0.updateMultisampleRenderTarget(t0), V0.updateRenderTargetMipmap(t0)), r0.isScene === !0 && r0.onAfterRender(Tt, r0, R0), wi.resetDefaultState(), i0 = -1, n0 = null, vt.pop(), vt.length > 0 ? (st = vt[vt.length - 1], A0 === !0 && mi.setGlobalState(Tt.clippingPlanes, st.state.camera)) : st = null, Zt.pop(), Zt.length > 0 ? Yt = Zt[Zt.length - 1] : Yt = null;
21603
21603
  };
21604
- function h1(r0, R0, S0, T0) {
21604
+ function u1(r0, R0, S0, T0) {
21605
21605
  if (r0.visible === !1) return;
21606
21606
  if (r0.layers.test(R0.layers)) {
21607
21607
  if (r0.isGroup)
@@ -21629,13 +21629,13 @@ class WebGLRenderer {
21629
21629
  }
21630
21630
  const w0 = r0.children;
21631
21631
  for (let k0 = 0, K0 = w0.length; k0 < K0; k0++)
21632
- h1(w0[k0], R0, S0, T0);
21632
+ u1(w0[k0], R0, S0, T0);
21633
21633
  }
21634
- function u1(r0, R0, S0, T0) {
21634
+ function m1(r0, R0, S0, T0) {
21635
21635
  const L0 = r0.opaque, w0 = r0.transmissive, k0 = r0.transparent;
21636
21636
  st.setupLightsView(S0), A0 === !0 && mi.setGlobalState(Tt.clippingPlanes, S0), T0 && U0.viewport(s0.copy(T0)), L0.length > 0 && o1(L0, R0, S0), w0.length > 0 && o1(w0, R0, S0), k0.length > 0 && o1(k0, R0, S0), U0.buffers.depth.setTest(!0), U0.buffers.depth.setMask(!0), U0.buffers.color.setMask(!0), U0.setPolygonOffset(!1);
21637
21637
  }
21638
- function f1(r0, R0, S0, T0) {
21638
+ function g1(r0, R0, S0, T0) {
21639
21639
  if ((S0.isScene === !0 ? S0.overrideMaterial : null) !== null)
21640
21640
  return;
21641
21641
  st.state.transmissionRenderTarget[T0.id] === void 0 && (st.state.transmissionRenderTarget[T0.id] = new WebGLRenderTarget(1, 1, {
@@ -21661,7 +21661,7 @@ class WebGLRenderer {
21661
21661
  const yi = R0[di], Yi = yi.object, Ni = yi.geometry, Mi = yi.material, Li = yi.group;
21662
21662
  if (Mi.side === DoubleSide && Yi.layers.test(T0.layers)) {
21663
21663
  const Ki = Mi.side;
21664
- Mi.side = BackSide, Mi.needsUpdate = !0, g1(Yi, S0, T0, Ni, Mi, Li), Mi.side = Ki, Mi.needsUpdate = !0, oi = !0;
21664
+ Mi.side = BackSide, Mi.needsUpdate = !0, R1(Yi, S0, T0, Ni, Mi, Li), Mi.side = Ki, Mi.needsUpdate = !0, oi = !0;
21665
21665
  }
21666
21666
  }
21667
21667
  oi === !0 && (V0.updateMultisampleRenderTarget(w0), V0.updateRenderTargetMipmap(w0));
@@ -21672,10 +21672,10 @@ class WebGLRenderer {
21672
21672
  const T0 = R0.isScene === !0 ? R0.overrideMaterial : null;
21673
21673
  for (let L0 = 0, w0 = r0.length; L0 < w0; L0++) {
21674
21674
  const k0 = r0[L0], K0 = k0.object, O0 = k0.geometry, li = T0 === null ? k0.material : T0, oi = k0.group;
21675
- K0.layers.test(S0.layers) && g1(K0, R0, S0, O0, li, oi);
21675
+ K0.layers.test(S0.layers) && R1(K0, R0, S0, O0, li, oi);
21676
21676
  }
21677
21677
  }
21678
- function g1(r0, R0, S0, T0, L0, w0) {
21678
+ function R1(r0, R0, S0, T0, L0, w0) {
21679
21679
  r0.onBeforeRender(Tt, R0, S0, T0, L0, w0), r0.modelViewMatrix.multiplyMatrices(S0.matrixWorldInverse, r0.matrixWorld), r0.normalMatrix.getNormalMatrix(r0.modelViewMatrix), L0.onBeforeRender(Tt, R0, S0, T0, r0, w0), L0.transparent === !0 && L0.side === DoubleSide && L0.forceSinglePass === !1 ? (L0.side = BackSide, L0.needsUpdate = !0, Tt.renderBufferDirect(S0, R0, T0, L0, r0, w0), L0.side = FrontSide, L0.needsUpdate = !0, Tt.renderBufferDirect(S0, R0, T0, L0, r0, w0), L0.side = DoubleSide) : Tt.renderBufferDirect(S0, R0, T0, L0, r0, w0), r0.onAfterRender(Tt, R0, S0, T0, L0, w0);
21680
21680
  }
21681
21681
  function r1(r0, R0, S0) {
@@ -21686,20 +21686,20 @@ class WebGLRenderer {
21686
21686
  let oi = li.get(O0);
21687
21687
  if (oi !== void 0) {
21688
21688
  if (T0.currentProgram === oi && T0.lightsStateVersion === k0)
21689
- return p1(r0, K0), oi;
21689
+ return b1(r0, K0), oi;
21690
21690
  } else
21691
21691
  K0.uniforms = Vi.getUniforms(r0), r0.onBeforeCompile(K0, Tt), oi = Vi.acquireProgram(K0, O0), li.set(O0, oi), T0.uniforms = K0.uniforms;
21692
21692
  const di = T0.uniforms;
21693
- return (!r0.isShaderMaterial && !r0.isRawShaderMaterial || r0.clipping === !0) && (di.clippingPlanes = mi.uniform), p1(r0, K0), T0.needsLights = n1(r0), T0.lightsStateVersion = k0, T0.needsLights && (di.ambientLightColor.value = L0.state.ambient, di.lightProbe.value = L0.state.probe, di.directionalLights.value = L0.state.directional, di.directionalLightShadows.value = L0.state.directionalShadow, di.spotLights.value = L0.state.spot, di.spotLightShadows.value = L0.state.spotShadow, di.rectAreaLights.value = L0.state.rectArea, di.ltc_1.value = L0.state.rectAreaLTC1, di.ltc_2.value = L0.state.rectAreaLTC2, di.pointLights.value = L0.state.point, di.pointLightShadows.value = L0.state.pointShadow, di.hemisphereLights.value = L0.state.hemi, di.directionalShadowMap.value = L0.state.directionalShadowMap, di.directionalShadowMatrix.value = L0.state.directionalShadowMatrix, di.spotShadowMap.value = L0.state.spotShadowMap, di.spotLightMatrix.value = L0.state.spotLightMatrix, di.spotLightMap.value = L0.state.spotLightMap, di.pointShadowMap.value = L0.state.pointShadowMap, di.pointShadowMatrix.value = L0.state.pointShadowMatrix), T0.currentProgram = oi, T0.uniformsList = null, oi;
21693
+ return (!r0.isShaderMaterial && !r0.isRawShaderMaterial || r0.clipping === !0) && (di.clippingPlanes = mi.uniform), b1(r0, K0), T0.needsLights = s1(r0), T0.lightsStateVersion = k0, T0.needsLights && (di.ambientLightColor.value = L0.state.ambient, di.lightProbe.value = L0.state.probe, di.directionalLights.value = L0.state.directional, di.directionalLightShadows.value = L0.state.directionalShadow, di.spotLights.value = L0.state.spot, di.spotLightShadows.value = L0.state.spotShadow, di.rectAreaLights.value = L0.state.rectArea, di.ltc_1.value = L0.state.rectAreaLTC1, di.ltc_2.value = L0.state.rectAreaLTC2, di.pointLights.value = L0.state.point, di.pointLightShadows.value = L0.state.pointShadow, di.hemisphereLights.value = L0.state.hemi, di.directionalShadowMap.value = L0.state.directionalShadowMap, di.directionalShadowMatrix.value = L0.state.directionalShadowMatrix, di.spotShadowMap.value = L0.state.spotShadowMap, di.spotLightMatrix.value = L0.state.spotLightMatrix, di.spotLightMap.value = L0.state.spotLightMap, di.pointShadowMap.value = L0.state.pointShadowMap, di.pointShadowMatrix.value = L0.state.pointShadowMatrix), T0.currentProgram = oi, T0.uniformsList = null, oi;
21694
21694
  }
21695
- function m1(r0) {
21695
+ function p1(r0) {
21696
21696
  if (r0.uniformsList === null) {
21697
21697
  const R0 = r0.currentProgram.getUniforms();
21698
21698
  r0.uniformsList = WebGLUniforms.seqWithValue(R0.seq, r0.uniforms);
21699
21699
  }
21700
21700
  return r0.uniformsList;
21701
21701
  }
21702
- function p1(r0, R0) {
21702
+ function b1(r0, R0) {
21703
21703
  const S0 = ei.get(r0);
21704
21704
  S0.outputColorSpace = R0.outputColorSpace, S0.batching = R0.batching, S0.batchingColor = R0.batchingColor, S0.instancing = R0.instancing, S0.instancingColor = R0.instancingColor, S0.instancingMorph = R0.instancingMorph, S0.skinning = R0.skinning, S0.morphTargets = R0.morphTargets, S0.morphNormals = R0.morphNormals, S0.morphColors = R0.morphColors, S0.morphTargetsCount = R0.morphTargetsCount, S0.numClippingPlanes = R0.numClippingPlanes, S0.numIntersection = R0.numClipIntersection, S0.vertexAlphas = R0.vertexAlphas, S0.vertexTangents = R0.vertexTangents, S0.toneMapping = R0.toneMapping;
21705
21705
  }
@@ -21735,11 +21735,11 @@ class WebGLRenderer {
21735
21735
  }
21736
21736
  L0.isBatchedMesh && (Fi.setOptional(g0, L0, "batchingTexture"), Fi.setValue(g0, "batchingTexture", L0._matricesTexture, V0), Fi.setOptional(g0, L0, "batchingIdTexture"), Fi.setValue(g0, "batchingIdTexture", L0._indirectTexture, V0), Fi.setOptional(g0, L0, "batchingColorTexture"), L0._colorsTexture !== null && Fi.setValue(g0, "batchingColorTexture", L0._colorsTexture, V0));
21737
21737
  const $i = S0.morphAttributes;
21738
- if (($i.position !== void 0 || $i.normal !== void 0 || $i.color !== void 0) && vi.update(L0, S0, Ei), (Pi || Li.receiveShadow !== L0.receiveShadow) && (Li.receiveShadow = L0.receiveShadow, Fi.setValue(g0, "receiveShadow", L0.receiveShadow)), T0.isMeshGouraudMaterial && T0.envMap !== null && (ji.envMap.value = O0, ji.flipEnvMap.value = O0.isCubeTexture && O0.isRenderTargetTexture === !1 ? -1 : 1), T0.isMeshStandardMaterial && T0.envMap === null && R0.environment !== null && (ji.envMapIntensity.value = R0.environmentIntensity), Pi && (Fi.setValue(g0, "toneMappingExposure", Tt.toneMappingExposure), Li.needsLights && i1(ji, Ui), w0 && T0.fog === !0 && Gi.refreshFogUniforms(ji, w0), Gi.refreshMaterialUniforms(ji, T0, a0, c0, st.state.transmissionRenderTarget[r0.id]), WebGLUniforms.upload(g0, m1(Li), ji, V0)), T0.isShaderMaterial && T0.uniformsNeedUpdate === !0 && (WebGLUniforms.upload(g0, m1(Li), ji, V0), T0.uniformsNeedUpdate = !1), T0.isSpriteMaterial && Fi.setValue(g0, "center", L0.center), Fi.setValue(g0, "modelViewMatrix", L0.modelViewMatrix), Fi.setValue(g0, "normalMatrix", L0.normalMatrix), Fi.setValue(g0, "modelMatrix", L0.matrixWorld), T0.isShaderMaterial || T0.isRawShaderMaterial) {
21738
+ if (($i.position !== void 0 || $i.normal !== void 0 || $i.color !== void 0) && vi.update(L0, S0, Ei), (Pi || Li.receiveShadow !== L0.receiveShadow) && (Li.receiveShadow = L0.receiveShadow, Fi.setValue(g0, "receiveShadow", L0.receiveShadow)), T0.isMeshGouraudMaterial && T0.envMap !== null && (ji.envMap.value = O0, ji.flipEnvMap.value = O0.isCubeTexture && O0.isRenderTargetTexture === !1 ? -1 : 1), T0.isMeshStandardMaterial && T0.envMap === null && R0.environment !== null && (ji.envMapIntensity.value = R0.environmentIntensity), Pi && (Fi.setValue(g0, "toneMappingExposure", Tt.toneMappingExposure), Li.needsLights && i1(ji, Ui), w0 && T0.fog === !0 && Gi.refreshFogUniforms(ji, w0), Gi.refreshMaterialUniforms(ji, T0, a0, c0, st.state.transmissionRenderTarget[r0.id]), WebGLUniforms.upload(g0, p1(Li), ji, V0)), T0.isShaderMaterial && T0.uniformsNeedUpdate === !0 && (WebGLUniforms.upload(g0, p1(Li), ji, V0), T0.uniformsNeedUpdate = !1), T0.isSpriteMaterial && Fi.setValue(g0, "center", L0.center), Fi.setValue(g0, "modelViewMatrix", L0.modelViewMatrix), Fi.setValue(g0, "normalMatrix", L0.normalMatrix), Fi.setValue(g0, "modelMatrix", L0.matrixWorld), T0.isShaderMaterial || T0.isRawShaderMaterial) {
21739
21739
  const Qi = T0.uniformsGroups;
21740
21740
  for (let Di = 0, v1 = Qi.length; Di < v1; Di++) {
21741
- const s1 = Qi[Di];
21742
- H0.update(s1, Ei), H0.bind(s1, Ei);
21741
+ const a1 = Qi[Di];
21742
+ H0.update(a1, Ei), H0.bind(a1, Ei);
21743
21743
  }
21744
21744
  }
21745
21745
  return Ei;
@@ -21747,7 +21747,7 @@ class WebGLRenderer {
21747
21747
  function i1(r0, R0) {
21748
21748
  r0.ambientLightColor.needsUpdate = R0, r0.lightProbe.needsUpdate = R0, r0.directionalLights.needsUpdate = R0, r0.directionalLightShadows.needsUpdate = R0, r0.pointLights.needsUpdate = R0, r0.pointLightShadows.needsUpdate = R0, r0.spotLights.needsUpdate = R0, r0.spotLightShadows.needsUpdate = R0, r0.rectAreaLights.needsUpdate = R0, r0.hemisphereLights.needsUpdate = R0;
21749
21749
  }
21750
- function n1(r0) {
21750
+ function s1(r0) {
21751
21751
  return r0.isMeshLambertMaterial || r0.isMeshToonMaterial || r0.isMeshPhongMaterial || r0.isMeshStandardMaterial || r0.isShadowMaterial || r0.isShaderMaterial && r0.lights === !0;
21752
21752
  }
21753
21753
  this.getActiveCubeFace = function() {
@@ -21874,8 +21874,8 @@ class WebGLRenderer {
21874
21874
  if (r0.isDepthTexture) {
21875
21875
  const $i = ei.get(r0), Qi = ei.get(R0), Di = ei.get($i.__renderTarget), v1 = ei.get(Qi.__renderTarget);
21876
21876
  U0.bindFramebuffer(g0.READ_FRAMEBUFFER, Di.__webglFramebuffer), U0.bindFramebuffer(g0.DRAW_FRAMEBUFFER, v1.__webglFramebuffer);
21877
- for (let s1 = 0; s1 < O0; s1++)
21878
- Fi && (g0.framebufferTextureLayer(g0.READ_FRAMEBUFFER, g0.COLOR_ATTACHMENT0, ei.get(r0).__webglTexture, L0, di + s1), g0.framebufferTextureLayer(g0.DRAW_FRAMEBUFFER, g0.COLOR_ATTACHMENT0, ei.get(R0).__webglTexture, w0, Yi + s1)), g0.blitFramebuffer(li, oi, k0, K0, hi, yi, k0, K0, g0.DEPTH_BUFFER_BIT, g0.NEAREST);
21877
+ for (let a1 = 0; a1 < O0; a1++)
21878
+ Fi && (g0.framebufferTextureLayer(g0.READ_FRAMEBUFFER, g0.COLOR_ATTACHMENT0, ei.get(r0).__webglTexture, L0, di + a1), g0.framebufferTextureLayer(g0.DRAW_FRAMEBUFFER, g0.COLOR_ATTACHMENT0, ei.get(R0).__webglTexture, w0, Yi + a1)), g0.blitFramebuffer(li, oi, k0, K0, hi, yi, k0, K0, g0.DEPTH_BUFFER_BIT, g0.NEAREST);
21879
21879
  U0.bindFramebuffer(g0.READ_FRAMEBUFFER, null), U0.bindFramebuffer(g0.DRAW_FRAMEBUFFER, null);
21880
21880
  } else if (L0 !== 0 || r0.isRenderTargetTexture || ei.has(r0)) {
21881
21881
  const $i = ei.get(r0), Qi = ei.get(R0);
@@ -29253,7 +29253,7 @@ function geo_delaunay_from(c) {
29253
29253
  const T = [];
29254
29254
  let de = 1;
29255
29255
  for (let $e = 0, qe = c.length; $e < qe; $e++) {
29256
- let rt = a1(c[$e][0], 2) + a1(c[$e][1], 2);
29256
+ let rt = l1(c[$e][0], 2) + l1(c[$e][1], 2);
29257
29257
  !isFinite(rt) || rt > 1e32 ? T.push($e) : rt > de && (de = rt);
29258
29258
  }
29259
29259
  const Xe = 1e6 * sqrt(de);
@@ -31346,7 +31346,7 @@ function _populateBuffer(c, e) {
31346
31346
  }
31347
31347
  }
31348
31348
  function generateIndirectBuffer(c, e) {
31349
- const s = (c.index ? c.index.count : c.attributes.position.count) / 3, r = s > a1(2, 16), T = r ? 4 : 2, de = e ? new SharedArrayBuffer(s * T) : new ArrayBuffer(s * T), Xe = r ? new Uint32Array(de) : new Uint16Array(de);
31349
+ const s = (c.index ? c.index.count : c.attributes.position.count) / 3, r = s > l1(2, 16), T = r ? 4 : 2, de = e ? new SharedArrayBuffer(s * T) : new ArrayBuffer(s * T), Xe = r ? new Uint32Array(de) : new Uint16Array(de);
31350
31350
  for (let Je = 0, Ke = Xe.length; Je < Ke; Je++)
31351
31351
  Xe[Je] = Je;
31352
31352
  return Xe;
@@ -38056,7 +38056,7 @@ const V = {
38056
38056
  let T = c.clone().add(e);
38057
38057
  T = T.normalize().multiplyScalar(s);
38058
38058
  let de;
38059
- r <= 1 ? de = s / 5 * r : r > 1 && r < 2 ? de = s / 5 * a1(r, 2) : de = s / 5 * a1(r, 1.5);
38059
+ r <= 1 ? de = s / 5 * r : r > 1 && r < 2 ? de = s / 5 * l1(r, 2) : de = s / 5 * l1(r, 1.5);
38060
38060
  const Xe = c.clone().add(T).normalize().multiplyScalar(s + de), Je = e.clone().add(T).normalize().multiplyScalar(s + de);
38061
38061
  return new CubicBezierCurve3(c, Xe, Je, e);
38062
38062
  }, createFlyPath2 = (c, e, s = 40) => {
@@ -41391,11 +41391,11 @@ class EXRLoader extends DataTextureLoader {
41391
41391
  const v0 = wi(o0, f0), r0 = wi(o0, f0);
41392
41392
  return [v0, r0];
41393
41393
  }
41394
- function G1(o0, f0) {
41394
+ function V1(o0, f0) {
41395
41395
  const v0 = wi(o0, f0), r0 = wi(o0, f0), R0 = wi(o0, f0);
41396
41396
  return [v0, r0, R0];
41397
41397
  }
41398
- function V1(o0, f0, v0, r0, R0) {
41398
+ function f1(o0, f0, v0, r0, R0) {
41399
41399
  if (r0 === "string" || r0 === "stringvector" || r0 === "iccProfile")
41400
41400
  return Ji(f0, v0, R0);
41401
41401
  if (r0 === "chlist")
@@ -41417,7 +41417,7 @@ class EXRLoader extends DataTextureLoader {
41417
41417
  if (r0 === "v2f")
41418
41418
  return e1(o0, v0);
41419
41419
  if (r0 === "v3f")
41420
- return G1(o0, v0);
41420
+ return V1(o0, v0);
41421
41421
  if (r0 === "int")
41422
41422
  return Ci(o0, v0);
41423
41423
  if (r0 === "rational")
@@ -41432,7 +41432,7 @@ class EXRLoader extends DataTextureLoader {
41432
41432
  const v0 = Math.log2(o0);
41433
41433
  return f0 == "ROUND_DOWN" ? Math.floor(v0) : Math.ceil(v0);
41434
41434
  }
41435
- function h1(o0, f0, v0) {
41435
+ function u1(o0, f0, v0) {
41436
41436
  let r0 = 0;
41437
41437
  switch (o0.levelMode) {
41438
41438
  case "ONE_LEVEL":
@@ -41446,7 +41446,7 @@ class EXRLoader extends DataTextureLoader {
41446
41446
  }
41447
41447
  return r0;
41448
41448
  }
41449
- function u1(o0, f0, v0, r0) {
41449
+ function m1(o0, f0, v0, r0) {
41450
41450
  const R0 = new Array(o0);
41451
41451
  for (let S0 = 0; S0 < o0; S0++) {
41452
41452
  const T0 = 1 << S0;
@@ -41457,7 +41457,7 @@ class EXRLoader extends DataTextureLoader {
41457
41457
  }
41458
41458
  return R0;
41459
41459
  }
41460
- function f1() {
41460
+ function g1() {
41461
41461
  const o0 = this, f0 = o0.offset, v0 = { value: 0 };
41462
41462
  for (let r0 = 0; r0 < o0.tileCount; r0++) {
41463
41463
  const R0 = Ci(o0.viewer, f0), S0 = Ci(o0.viewer, f0);
@@ -41505,7 +41505,7 @@ class EXRLoader extends DataTextureLoader {
41505
41505
  }
41506
41506
  }
41507
41507
  }
41508
- function g1(o0, f0, v0) {
41508
+ function R1(o0, f0, v0) {
41509
41509
  const r0 = {};
41510
41510
  if (o0.getUint32(0, !0) != 20000630)
41511
41511
  throw new Error("THREE.EXRLoader: Provided file doesn't appear to be in OpenEXR format.");
@@ -41523,7 +41523,7 @@ class EXRLoader extends DataTextureLoader {
41523
41523
  if (T0 == 0)
41524
41524
  S0 = !1;
41525
41525
  else {
41526
- const L0 = Zi(f0, v0), w0 = vi(o0, v0), k0 = V1(o0, f0, v0, L0, w0);
41526
+ const L0 = Zi(f0, v0), w0 = vi(o0, v0), k0 = f1(o0, f0, v0, L0, w0);
41527
41527
  k0 === void 0 ? console.warn(`THREE.EXRLoader: Skipped unknown header attribute type '${L0}'.`) : r0[T0] = k0;
41528
41528
  }
41529
41529
  }
@@ -41633,13 +41633,13 @@ class EXRLoader extends DataTextureLoader {
41633
41633
  S0.decodeChannels[K0.name] !== void 0 && (S0.channelByteOffsets[K0.name] = k0), k0 += K0.pixelType * 2;
41634
41634
  if (S0.totalBytes = k0, S0.outLineWidth = S0.width * S0.outputChannels, o0.lineOrder === "INCREASING_Y" ? S0.scanOrder = (K0) => K0 : S0.scanOrder = (K0) => S0.height - 1 - K0, S0.outputChannels == 4 ? (S0.format = RGBAFormat, S0.colorSpace = LinearSRGBColorSpace) : (S0.format = RedFormat, S0.colorSpace = NoColorSpace), o0.spec.singleTile) {
41635
41635
  S0.blockHeight = o0.tiles.ySize, S0.blockWidth = o0.tiles.xSize;
41636
- const K0 = h1(o0.tiles, S0.width, S0.height), O0 = u1(K0, S0.width, o0.tiles.xSize, o0.tiles.roundingMode), li = u1(K0, S0.height, o0.tiles.ySize, o0.tiles.roundingMode);
41636
+ const K0 = u1(o0.tiles, S0.width, S0.height), O0 = m1(K0, S0.width, o0.tiles.xSize, o0.tiles.roundingMode), li = m1(K0, S0.height, o0.tiles.ySize, o0.tiles.roundingMode);
41637
41637
  S0.tileCount = O0[0] * li[0];
41638
41638
  for (let oi = 0; oi < K0; oi++)
41639
41639
  for (let di = 0; di < li[oi]; di++)
41640
41640
  for (let hi = 0; hi < O0[oi]; hi++)
41641
41641
  Ti(f0, r0);
41642
- S0.decode = f1.bind(S0);
41642
+ S0.decode = g1.bind(S0);
41643
41643
  } else {
41644
41644
  S0.blockWidth = S0.width;
41645
41645
  const K0 = Math.ceil(S0.height / S0.blockHeight);
@@ -41649,14 +41649,14 @@ class EXRLoader extends DataTextureLoader {
41649
41649
  }
41650
41650
  return S0;
41651
41651
  }
41652
- const m1 = { value: 0 }, p1 = new DataView(e), I1 = new Uint8Array(e), i1 = g1(p1, e, m1), n1 = r1(i1, p1, I1, m1, this.type);
41653
- return n1.decode(), {
41652
+ const p1 = { value: 0 }, b1 = new DataView(e), I1 = new Uint8Array(e), i1 = R1(b1, e, p1), s1 = r1(i1, b1, I1, p1, this.type);
41653
+ return s1.decode(), {
41654
41654
  header: i1,
41655
- width: n1.width,
41656
- height: n1.height,
41657
- data: n1.byteArray,
41658
- format: n1.format,
41659
- colorSpace: n1.colorSpace,
41655
+ width: s1.width,
41656
+ height: s1.height,
41657
+ data: s1.byteArray,
41658
+ format: s1.format,
41659
+ colorSpace: s1.colorSpace,
41660
41660
  type: this.type
41661
41661
  };
41662
41662
  }
@@ -49495,7 +49495,7 @@ class Viewport {
49495
49495
  }
49496
49496
  setVis(r) {
49497
49497
  return q0(this, arguments, function* (e, s = {}) {
49498
- var Je;
49498
+ var Xe;
49499
49499
  if (!this.options.visFactories && (this.editor.setViewportVis(e), !this.options.visFactories)) {
49500
49500
  console.error("visFactories is not defined");
49501
49501
  return;
@@ -49503,20 +49503,18 @@ class Viewport {
49503
49503
  if (this.vis = this.options.visFactories, this.vis.visName !== e)
49504
49504
  throw new Error(`visName is not match, import {${e}}`);
49505
49505
  const T = this.editor.hooks.events.beforeSetVisOptions.length ? this.editor.hooks.dispatch("beforeSetVisOptions", s) : s;
49506
- this.vis.setOptions(ai(ai({}, T), this.extendsOptions)), this.vis.cameraState = ai({}, this.cameraState);
49507
- const de = this.editor.dev;
49508
- de && (this.vis.publicDir = de.publicDir), this.delLoadObj && (this.vis.delLoadArr = this.delLoadObj), this.vis.playing = this.editor.playing, this.vis._baseObjectByUuid = this.editor.baseObjectByUuid.bind(this.editor), this.vis._objectByUuid = this.editor.objectByUuid.bind(this.editor), this.vis.on("loaderProgress", (Ke, Qe) => {
49506
+ this.vis.setOptions(ai(ai({}, T), this.extendsOptions)), this.vis.cameraState = ai({}, this.cameraState), this.delLoadObj && (this.vis.delLoadArr = this.delLoadObj), this.vis.playing = this.editor.playing, this.vis._baseObjectByUuid = this.editor.baseObjectByUuid.bind(this.editor), this.vis._objectByUuid = this.editor.objectByUuid.bind(this.editor), this.vis.on("loaderProgress", (Je, Ke) => {
49509
49507
  this.editor.emit("progress", {
49510
49508
  type: "下载资源",
49511
- value: Ke / Qe * 100 | 0
49509
+ value: Je / Ke * 100 | 0
49512
49510
  });
49513
49511
  }), this.vis.on("settingsChanged", () => {
49514
49512
  this.editor.emit("settingsChanged");
49515
49513
  }), this.vis.on("show", () => {
49516
49514
  this.editor.emit("visShow");
49517
49515
  }), yield this.vis.init();
49518
- const { pencil: Xe } = this.vis;
49519
- Xe.userData.EditorEnv = !this.editor.playing, this.editor.pencil = Xe, this.editor.changeSelectOption(), this.editor.playing || (this.initEvent(), this.editor.emit("visChanged", this.vis)), (Je = this.vis) == null || Je.pencil.event.on("object3dListChange", () => {
49516
+ const { pencil: de } = this.vis;
49517
+ de.userData.EditorEnv = !this.editor.playing, this.editor.pencil = de, this.editor.changeSelectOption(), this.editor.playing || (this.initEvent(), this.editor.emit("visChanged", this.vis)), (Xe = this.vis) == null || Xe.pencil.event.on("object3dListChange", () => {
49520
49518
  this.editor.changeSelectOption();
49521
49519
  });
49522
49520
  });
@@ -49723,9 +49721,10 @@ class Hooks {
49723
49721
  });
49724
49722
  }
49725
49723
  addEvents(e) {
49726
- for (const s in e) {
49727
- const r = s;
49728
- this.events[r] && this.events[r].push(e[r].bind(e));
49724
+ var s;
49725
+ for (const r in e) {
49726
+ const T = r;
49727
+ this.events[T] && this.events[T].push(e[T].bind(e)), T === "afterShow" && ((s = this.editor.viewport.vis) == null ? void 0 : s.showState) === !0 && e[T](this.editor.viewport.vis);
49729
49728
  }
49730
49729
  }
49731
49730
  addStaticEvents(e) {
@@ -49734,16 +49733,16 @@ class Hooks {
49734
49733
  this.source !== s && (this.source = s, this.editor.emit("scriptsChanged"));
49735
49734
  }
49736
49735
  fromJSON(e) {
49737
- if (!e) {
49736
+ if (!e)
49738
49737
  this.source = "";
49739
- return;
49740
- }
49741
- try {
49742
- const s = new Function(`return ${e}()`)();
49743
- this.addEvents(s), this.source = e;
49744
- } catch (s) {
49745
- console.error(s);
49746
- }
49738
+ else
49739
+ try {
49740
+ const s = new Function(`return ${e}()`)();
49741
+ this.addEvents(s), this.source = e;
49742
+ } catch (s) {
49743
+ console.error(s);
49744
+ }
49745
+ this.editor.emit("scriptsChanged");
49747
49746
  }
49748
49747
  toJSON() {
49749
49748
  return this.source;
@@ -50068,7 +50067,6 @@ const BLOCKLISTED_GPUS = [
50068
50067
  "3",
50069
50068
  "4",
50070
50069
  "6",
50071
- "11",
50072
50070
  "12",
50073
50071
  "15",
50074
50072
  "25",
@@ -50185,7 +50183,6 @@ const BLOCKLISTED_GPUS = [
50185
50183
  "3",
50186
50184
  "4",
50187
50185
  "6",
50188
- "11",
50189
50186
  "25",
50190
50187
  "48",
50191
50188
  "455",
@@ -50284,6 +50281,7 @@ const BLOCKLISTED_GPUS = [
50284
50281
  "15",
50285
50282
  "51",
50286
50283
  "120",
50284
+ "130",
50287
50285
  "140",
50288
50286
  "160",
50289
50287
  "180",
@@ -50346,6 +50344,7 @@ const BLOCKLISTED_GPUS = [
50346
50344
  ], geforce = [
50347
50345
  "10",
50348
50346
  "120",
50347
+ "130",
50349
50348
  "210",
50350
50349
  "240",
50351
50350
  "280",
@@ -50743,7 +50742,7 @@ class Base extends Event {
50743
50742
  dbName: this.visName,
50744
50743
  cacheVersion: version
50745
50744
  }), this.delLoadArr && (this.loader.delLoadArr = this.delLoadArr), this.loader.on("progress", (...s) => {
50746
- this.emit("loaderProgress", ...s);
50745
+ this.showState !== !0 && this.emit("loaderProgress", ...s);
50747
50746
  });
50748
50747
  }
50749
50748
  addCSS3DRenderer() {
@@ -130711,7 +130710,7 @@ const objs$4 = zi(ai({}, objs$5), {
130711
130710
  }
130712
130711
  handleSetting(s, r) {
130713
130712
  return q0(this, null, function* () {
130714
- if (yield l1(d1.prototype, this, "handleSetting").call(this, s, r), s === "label")
130713
+ if (yield n1(d1.prototype, this, "handleSetting").call(this, s, r), s === "label")
130715
130714
  r === !1 ? (this.eraseLabels(), this.options.showLabel = !1) : (this.settings.labelLite = !1, yield this.settings.labelLite, this.options.showLabel = !0, yield this.drawLabels());
130716
130715
  else if (s === "labelLite")
130717
130716
  r === !1 ? (this.eraseLabels(), this.options.showLabel = !1) : (this.settings.label = !1, yield this.settings.label, this.options.showLabel = "lite", yield this.drawLabels());
@@ -130754,7 +130753,7 @@ const objs$4 = zi(ai({}, objs$5), {
130754
130753
  projectionType: this.options.projectionType,
130755
130754
  rotate: this.options.worldPacificCentre ? [-160, 0] : void 0
130756
130755
  }), this.meters = this.projection([1 * 1141e-8 + this.pcenter[0], 0])[0], yield this.initPencil(), console.time(`vis-core:time.${this.visName}-loader`), this.loaderAdd(), console.timeEnd(`vis-core:time.${this.visName}-loader`), yield this.loader.loadAll(), this.group = yield this.drawController.draw("Group"), yield this.initMaterial(), yield this.initVis(s), this.options.clickHandleDrillDown && this.addListener(this.container, "click", (r) => {
130757
- this.handleClick(r);
130756
+ (this.playing || r.metaKey || r.ctrlKey) && this.handleClick(r);
130758
130757
  }), yield Promise.all(this.drawController.objectsPromise);
130759
130758
  });
130760
130759
  }
@@ -131086,7 +131085,7 @@ const objs$4 = zi(ai({}, objs$5), {
131086
131085
  show() {
131087
131086
  return q0(this, null, function* () {
131088
131087
  if (this.showState || this.options.disableInitShow) return;
131089
- this.useSaveCamera(`map-${this.options.adcode}`), l1(d1.prototype, this, "show").call(this);
131088
+ this.useSaveCamera(`map-${this.options.adcode}`), n1(d1.prototype, this, "show").call(this);
131090
131089
  const s = this.drawController.group;
131091
131090
  this.mapHistory[0] && (yield sinusoidalInOut({
131092
131091
  onUpdate: (r) => {
@@ -131119,7 +131118,7 @@ const objs$4 = zi(ai({}, objs$5), {
131119
131118
  s.position.z = -this.mapHistory[0].depth * r;
131120
131119
  }
131121
131120
  }).start(), setTimeout(() => {
131122
- l1(d1.prototype, this, "hide").call(this);
131121
+ n1(d1.prototype, this, "hide").call(this);
131123
131122
  });
131124
131123
  });
131125
131124
  }
@@ -131186,29 +131185,33 @@ const objs$4 = zi(ai({}, objs$5), {
131186
131185
  const { drillDownRestrictions: r } = this.options;
131187
131186
  if (this.isAnimating) return;
131188
131187
  const T = (de = this.map) == null ? void 0 : de.pickArea(s);
131189
- if (T && T.userData.adcode && this.getAdcodeShowLevel(T.userData.adcode) !== r)
131190
- this.clickArea({
131191
- adcodes: [...this.adcodes, T.userData.adcode]
131192
- });
131193
- else if (this.options.clickOusideBack && !T && this.mapHistory.length > 1) {
131194
- const Xe = [...this.adcodes];
131195
- Xe.pop(), this.clickArea({
131196
- adcodes: Xe
131197
- });
131198
- }
131188
+ T && T.userData.adcode && this.getAdcodeShowLevel(T.userData.adcode) !== r ? this.showMap({
131189
+ adcode: T.userData.adcode
131190
+ }) : this.options.clickOusideBack && !T && this.mapHistory.length > 1 && this.showMap({
131191
+ adcode: this.adcodes.at(-2)
131192
+ });
131199
131193
  }
131200
- beforeClickArea(s) {
131194
+ beforeShowMap(s) {
131201
131195
  return !0;
131202
131196
  }
131203
- clickArea(T) {
131197
+ getAdcodes(s) {
131198
+ const r = [];
131199
+ let T = s;
131200
+ for (; T; )
131201
+ r.unshift(T), T = adcodeMap[T].parent;
131202
+ return r;
131203
+ }
131204
+ showMap(de) {
131204
131205
  return q0(this, arguments, function* ({
131205
- adcodes: s,
131206
- duration: r = 1e3
131206
+ adcode: s,
131207
+ adcodes: r,
131208
+ duration: T = 1e3
131207
131209
  }) {
131208
- (yield this.beforeClickArea(s)) !== !1 && (this.emit("beforeDrillDown", s), yield this.setAdcode({
131209
- adcodes: s,
131210
- duration: r
131211
- }), this.emit("afterDrillDown", s));
131210
+ const Xe = r || this.getAdcodes(s);
131211
+ (yield this.beforeShowMap(Xe)) !== !1 && (this.emit("beforeDrillDown", [...Xe]), yield this.setAdcode({
131212
+ adcodes: Xe,
131213
+ duration: T
131214
+ }), this.emit("afterDrillDown", [...Xe]));
131212
131215
  });
131213
131216
  }
131214
131217
  drawLabels() {
@@ -133223,7 +133226,7 @@ class City extends City$1 {
133223
133226
  this.pencil.camera.near = r, this.pencil.camera.updateProjectionMatrix();
133224
133227
  }
133225
133228
  }
133226
- const R1 = class R1 extends Map$1 {
133229
+ const h1 = class h1 extends Map$1 {
133227
133230
  constructor() {
133228
133231
  super(...arguments);
133229
133232
  F0(this, "workerOnce", !1);
@@ -133264,7 +133267,7 @@ const R1 = class R1 extends Map$1 {
133264
133267
  init() {
133265
133268
  return q0(this, null, function* () {
133266
133269
  var s;
133267
- if (yield l1(R1.prototype, this, "init").call(this), this.showGroup = "map", this.options.adcode == 1e5 && (this.pencil.camera.far = 500, this.pencil.camera.updateProjectionMatrix()), this.on("handleDrillDown", (T) => q0(this, [T], function* ({ adcode: r }) {
133270
+ if (yield n1(h1.prototype, this, "init").call(this), this.showGroup = "map", this.options.adcode == 1e5 && (this.pencil.camera.far = 500, this.pencil.camera.updateProjectionMatrix()), this.on("handleDrillDown", (T) => q0(this, [T], function* ({ adcode: r }) {
133268
133271
  const de = this.getAdcodeShowLevel(r) === "city";
133269
133272
  this.options.initCity && de && this.initCityVis(r, {
133270
133273
  clip: !!this.options.cityOnMap,
@@ -133380,8 +133383,8 @@ const R1 = class R1 extends Map$1 {
133380
133383
  return;
133381
133384
  }
133382
133385
  if (Xe !== this.mapInfo.adcode) {
133383
- yield this.clickArea({
133384
- adcodes: [...this.adcodes, Xe],
133386
+ yield n1(h1.prototype, this, "showMap").call(this, {
133387
+ adcode: Xe,
133385
133388
  duration: 0
133386
133389
  }), yield this.showCity({
133387
133390
  adcode: Xe,
@@ -133392,12 +133395,13 @@ const R1 = class R1 extends Map$1 {
133392
133395
  (_e = this.options.fixCity) != null && _e[Xe] && (Xe = this.options.fixCity[Xe]), yield this.cityVisObj[Xe].state.promise, this.emit("beforeDrillDown", "city"), this.showGroup = "city", this.cityVis.fixNearFar(), this.cityVis.group.position.z = this.mapObj.z + this.mapObj.depth, this.cityVis.group.show(), this.group.hide(), this.verticalDragToForward = !0, yield this.cityVis.fitToTarget(Xe, T), this.emit("afterDrillDown", "city");
133393
133396
  });
133394
133397
  }
133395
- showMap(s) {
133396
- return q0(this, null, function* () {
133398
+ showMap(r) {
133399
+ return q0(this, arguments, function* ({ adcode: s }) {
133397
133400
  if (this.isAnimating)
133398
133401
  return;
133399
- s || (s = this.adcodes), this.showGroup === "city" && !this.options.cityOnMap && (this.fixNear(this.mapInfo.adcode), this.cityVis.group.hide(), this.group.show(), this.verticalDragToForward = !1), this.showGroup = "map", JSON.stringify(s) === JSON.stringify(this.adcodes) ? (this.emit("beforeDrillDown", [...this.adcodes]), this.options.cityOnMap ? yield this.handleLookBack() : yield this.fitTo(this.map), this.emit("afterDrillDown", [...this.adcodes])) : yield this.clickArea({
133400
- adcodes: s
133402
+ const T = s ? this.getAdcodes(s) : this.adcodes;
133403
+ this.showGroup === "city" && !this.options.cityOnMap && (this.fixNear(this.mapInfo.adcode), this.cityVis.group.hide(), this.group.show(), this.verticalDragToForward = !1), this.showGroup = "map", JSON.stringify(T) === JSON.stringify(this.adcodes) ? (this.emit("beforeDrillDown", [...T]), this.options.cityOnMap ? yield this.handleLookBack() : yield this.fitTo(this.map), this.emit("afterDrillDown", [...T])) : yield n1(h1.prototype, this, "showMap").call(this, {
133404
+ adcodes: [...T]
133401
133405
  });
133402
133406
  });
133403
133407
  }
@@ -133408,8 +133412,8 @@ const R1 = class R1 extends Map$1 {
133408
133412
  }), super.dispose();
133409
133413
  }
133410
133414
  };
133411
- F0(R1, "VisName", "map2");
133412
- let index$2 = R1;
133415
+ F0(h1, "VisName", "map2");
133416
+ let index$2 = h1;
133413
133417
  class Earth$1 extends Sphere {
133414
133418
  constructor(s) {
133415
133419
  super();
@@ -133793,7 +133797,7 @@ const objs$1 = zi(ai({}, objs$5), {
133793
133797
  }
133794
133798
  handleSetting(s, r) {
133795
133799
  return q0(this, null, function* () {
133796
- return yield l1(S1.prototype, this, "handleSetting").call(this, s, r), s === "测试板块颜色.color" ? this.setAreaEmissiveByProperty("ISO_A2", "CN", r) : s === "测试边框颜色.color" ? this.setLineColorByProperty("ISO_A2", "CN", r) : s === "测试立柱" ? (typeof r == "boolean" && (r = ""), r ? this.addBar(r) : this.removeBar()) : s === "autoRotate" && this.playing && (r ? this.autoRotateSpeed = -20 : this.autoRotateSpeed = 0, this.pencil.autoRotate(this.autoRotateSpeed)), r;
133800
+ return yield n1(S1.prototype, this, "handleSetting").call(this, s, r), s === "测试板块颜色.color" ? this.setAreaEmissiveByProperty("ISO_A2", "CN", r) : s === "测试边框颜色.color" ? this.setLineColorByProperty("ISO_A2", "CN", r) : s === "测试立柱" ? (typeof r == "boolean" && (r = ""), r ? this.addBar(r) : this.removeBar()) : s === "autoRotate" && this.playing && (r ? this.autoRotateSpeed = -20 : this.autoRotateSpeed = 0, this.pencil.autoRotate(this.autoRotateSpeed)), r;
133797
133801
  });
133798
133802
  }
133799
133803
  show() {
@@ -134052,7 +134056,7 @@ const objs = zi(ai({}, objs$5), {
134052
134056
  }
134053
134057
  handleSetting(s, r) {
134054
134058
  return q0(this, null, function* () {
134055
- return yield l1(L1.prototype, this, "handleSetting").call(this, s, r), s === "autoRotate" && this.playing && (r ? this.autoRotateSpeed = -20 : this.autoRotateSpeed = 0, this.pencil.autoRotate(this.autoRotateSpeed)), r;
134059
+ return yield n1(L1.prototype, this, "handleSetting").call(this, s, r), s === "autoRotate" && this.playing && (r ? this.autoRotateSpeed = -20 : this.autoRotateSpeed = 0, this.pencil.autoRotate(this.autoRotateSpeed)), r;
134056
134060
  });
134057
134061
  }
134058
134062
  animationIn() {
package/dist/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- declare const _default: "0.24.5";
1
+ declare const _default: "0.24.7";
2
2
  export default _default;