vis-core 0.29.10 → 0.29.11

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.
@@ -63,7 +63,7 @@ import { continentsCountriesIso2 } from "geojson-cn";
63
63
  Array.prototype.at || (Array.prototype.at = function(v) {
64
64
  return v < 0 && (v = this.length + v), this[v];
65
65
  });
66
- const version = "0.29.10", publicKeyPEM = "LS0tLS1CRUdJTiBQVUJMSUMgS0VZLS0tLS0KTUlJQklqQU5CZ2txaGtpRzl3MEJBUUVGQUFPQ0FROEFNSUlCQ2dLQ0FRRUEyTG1aVVQzVG9LZEVRRUdrdUU1QQo3dnlYTzRMM1Z6NDA5RFF2a2xzRHZ2SytNM2M2OGl4ZEVhZDZFcnZGS2FKQ1QrNTZNdU1XSXhUTnlDZDVQSkFGCjVYdzI4cW1iVkVCR3FGdXVIZTltSm5GUmRXN1NpK1Z1cTZvRWxwQkRkeEFIQ0dsWVVpU1R3WmhBbjJaVXJLSUYKd1J2c1k1bi9uWWNhZnl5QW9tRjhmNVRsTkpwS1JtbDU3WlRSWjBMdzdQRDFSeHFIbmJ0YWFETkpiSDV5eFd6cQpaVTBwQWhxMFNkNHdlOW1DUTJWWXc5czhtUERLbW4rU083eGovSUsrR1ZEaEJNOUpaZ3VIcGFZUGt3bWd5UkdwCkx6V0tHMkZULzJRalZUT1dRT09mRFVtVitDSVlsN1hVVlh1Q0toYWFNQ0ZVa1JQOHg4aEZucmNFeklHQ1JpM3IKK3dJREFRQUIKLS0tLS1FTkQgUFVCTElDIEtFWS0tLS0t", accessToken = {
66
+ const version = "0.29.11", publicKeyPEM = "LS0tLS1CRUdJTiBQVUJMSUMgS0VZLS0tLS0KTUlJQklqQU5CZ2txaGtpRzl3MEJBUUVGQUFPQ0FROEFNSUlCQ2dLQ0FRRUEyTG1aVVQzVG9LZEVRRUdrdUU1QQo3dnlYTzRMM1Z6NDA5RFF2a2xzRHZ2SytNM2M2OGl4ZEVhZDZFcnZGS2FKQ1QrNTZNdU1XSXhUTnlDZDVQSkFGCjVYdzI4cW1iVkVCR3FGdXVIZTltSm5GUmRXN1NpK1Z1cTZvRWxwQkRkeEFIQ0dsWVVpU1R3WmhBbjJaVXJLSUYKd1J2c1k1bi9uWWNhZnl5QW9tRjhmNVRsTkpwS1JtbDU3WlRSWjBMdzdQRDFSeHFIbmJ0YWFETkpiSDV5eFd6cQpaVTBwQWhxMFNkNHdlOW1DUTJWWXc5czhtUERLbW4rU083eGovSUsrR1ZEaEJNOUpaZ3VIcGFZUGt3bWd5UkdwCkx6V0tHMkZULzJRalZUT1dRT09mRFVtVitDSVlsN1hVVlh1Q0toYWFNQ0ZVa1JQOHg4aEZucmNFeklHQ1JpM3IKK3dJREFRQUIKLS0tLS1FTkQgUFVCTElDIEtFWS0tLS0t", accessToken = {
67
67
  token: void 0,
68
68
  getInfo() {
69
69
  if (!this.token)
@@ -61496,7 +61496,6 @@ class Camera extends Event {
61496
61496
  const IS_DEV = !1;
61497
61497
  class Base extends Camera {
61498
61498
  constructor(n) {
61499
- var r;
61500
61499
  super();
61501
61500
  g0(this, "playing", !0);
61502
61501
  g0(this, "leftTruck", !0);
@@ -61528,45 +61527,23 @@ class Base extends Camera {
61528
61527
  logarithmicDepthBuffer: !0,
61529
61528
  observeParentScale: !0
61530
61529
  }, n), !this.options.assetsPrefix) {
61531
- let C = "/";
61532
- C === "/" && (C = ""), this.options.assetsPrefix = C;
61530
+ let r = "/";
61531
+ r === "/" && (r = ""), this.options.assetsPrefix = r;
61533
61532
  }
61534
61533
  this.options.workerOnce !== void 0 && (this.workerOnce = this.options.workerOnce);
61535
61534
  try {
61536
- const C = window.location.search.match(/v_ldb=(\d+)/);
61537
- if (C) {
61538
- const w = !!+C[1];
61539
- this.options.logarithmicDepthBuffer = w;
61535
+ const r = window.location.search.match(/v_ldb=(\d+)/);
61536
+ if (r) {
61537
+ const C = !!+r[1];
61538
+ this.options.logarithmicDepthBuffer = C;
61540
61539
  }
61541
- } catch (C) {
61542
- console.error(C);
61543
- }
61544
- if (this.options.editor) {
61545
- const C = detect();
61546
- let w = (r = this.options.tier) != null ? r : C.tier;
61547
- try {
61548
- const E = window.location.search.match(/v_tier=(\d+)/);
61549
- E && (w = +E[1]);
61550
- } catch (E) {
61551
- console.error(E);
61552
- }
61553
- this.tier0 = w !== 3, this.editor = new Editor({
61554
- assetsPrefix: this.options.assetsPrefix,
61555
- visFactories: this
61556
- }), console.info(
61557
- "vis-core:detect",
61558
- version,
61559
- JSON.stringify(
61560
- Ui(O0({}, C), {
61561
- ldb: this.options.logarithmicDepthBuffer,
61562
- tier0: this.tier0
61563
- }),
61564
- null,
61565
- 2
61566
- )
61567
- );
61540
+ } catch (r) {
61541
+ console.error(r);
61568
61542
  }
61569
- this.visName = this.constructor.VisName;
61543
+ this.options.editor && (this.editor = new Editor({
61544
+ assetsPrefix: this.options.assetsPrefix,
61545
+ visFactories: this
61546
+ }), this.showDetectRes()), this.visName = this.constructor.VisName;
61570
61547
  }
61571
61548
  get loader() {
61572
61549
  return this.pencil.loader;
@@ -61574,6 +61551,29 @@ class Base extends Camera {
61574
61551
  get worker() {
61575
61552
  return this.pencil.installPlugins.get("worker");
61576
61553
  }
61554
+ showDetectRes() {
61555
+ var C;
61556
+ const n = detect();
61557
+ let r = (C = this.options.tier) != null ? C : n.tier;
61558
+ try {
61559
+ const w = window.location.search.match(/v_tier=(\d+)/);
61560
+ w && (r = +w[1]);
61561
+ } catch (w) {
61562
+ console.error(w);
61563
+ }
61564
+ this.tier0 = r !== 3, console.info(
61565
+ "vis-core:detect",
61566
+ version,
61567
+ JSON.stringify(
61568
+ Ui(O0({}, n), {
61569
+ ldb: this.options.logarithmicDepthBuffer,
61570
+ tier0: this.tier0
61571
+ }),
61572
+ null,
61573
+ 2
61574
+ )
61575
+ );
61576
+ }
61577
61577
  setOptions(n) {
61578
61578
  this.options = O0(O0({}, this.options), n);
61579
61579
  }
@@ -61684,14 +61684,13 @@ class Base extends Camera {
61684
61684
  if (Ue.material) {
61685
61685
  const Gt = Ue.material;
61686
61686
  (Array.isArray(Gt) ? Gt : [Gt]).forEach((Xt) => {
61687
- !Lt.has(Xt) && Xt.name && (Lt.set(Xt, Xt.name), Xt.name = "");
61687
+ !Lt.has(Xt) && Xt.name && (Lt.set(Xt, Xt.name), Xt.name = ""), Xt.transparent && Xt.alphaTest === 0 && (Xt.alphaTest = 0.01, Xt.needsUpdate = !0);
61688
61688
  });
61689
61689
  }
61690
61690
  });
61691
61691
  }), ke.event.on("render", () => {
61692
61692
  [...Lt.keys()].forEach((bt) => {
61693
- const Ue = Lt.get(bt);
61694
- Ue && (bt.name = Ue);
61693
+ Lt.has(bt) && (bt.name = Lt.get(bt));
61695
61694
  }), Lt.clear();
61696
61695
  });
61697
61696
  }
package/dist/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- declare const _default: "0.29.10";
1
+ declare const _default: "0.29.11";
2
2
  export default _default;
@@ -75,6 +75,7 @@ export default class Base extends Camera {
75
75
  editor?: Editor;
76
76
  publicDir: Record<string, string>;
77
77
  constructor(options: BaseOptions);
78
+ private showDetectRes;
78
79
  setOptions(options: Record<string, any>): void;
79
80
  _baseObjectByUuid: Editor['baseObjectByUuid'];
80
81
  _objectByUuid: Editor['objectByUuid'];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vis-core",
3
- "version": "0.29.10",
3
+ "version": "0.29.11",
4
4
  "scripts": {
5
5
  "start": "npm run version && PORT=5173 bundler-dev",
6
6
  "build:site": "npm run version && PUBLIC_EXCLUDE=true bundler",