vis-core 0.24.11 → 0.24.12

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.
@@ -90,7 +90,7 @@ const publicKeyPEM = "LS0tLS1CRUdJTiBQVUJMSUMgS0VZLS0tLS0KTUlJQklqQU5CZ2txaGtpRz
90
90
  ).toString(CryptoJS.enc.Utf8), ct = JSON.parse(rt), Zt = Date.now();
91
91
  return !ct.s || ct.s > Zt ? (this.token = void 0, "") : ct.e && ct.e < Zt ? (this.token = void 0, "") : (ct.isValid = qe, ct);
92
92
  }
93
- }, version = "0.24.11";
93
+ }, version = "0.24.12";
94
94
  /**
95
95
  * @license
96
96
  * Copyright 2010-2025 Three.js Authors
@@ -50683,53 +50683,58 @@ class Base extends Event {
50683
50683
  }
50684
50684
  initPencil() {
50685
50685
  return ti(this, null, function* () {
50686
- var Je, Ke, Qe, _e, $e, qe, st, rt, ct, Zt, Wt, Yt;
50687
- if (this.options.pencil && (this.pencil = this.options.pencil, this.sceneActive = this.pencil.addPage({
50688
- cameraOptions: {
50689
- fov: (Ke = (Je = this.pencilConfig.camera) == null ? void 0 : Je.fov) != null ? Ke : 45,
50690
- near: (_e = (Qe = this.pencilConfig.camera) == null ? void 0 : Qe.near) != null ? _e : 0.1,
50691
- far: (qe = ($e = this.pencilConfig.camera) == null ? void 0 : $e.far) != null ? qe : 1e3,
50692
- up: (rt = (st = this.pencilConfig.camera) == null ? void 0 : st.up) != null ? rt : new Vector3(0, 1, 0)
50693
- }
50694
- }), this.setSceneActive(), this.drawController.install(this.pencil), this.mList.install(this.pencil), yield this.drawController.initGroup(), (ct = this.drawController.group) == null || ct.hide(), (Zt = this.drawController.prefabGroup) == null || Zt.hide()), this.pencil) return;
50695
- this.pencilConfig = li({}, this.pencilConfig), this.options.css2DContainer && (this.pencilConfig.css2DRendererParams = {
50686
+ var c, Je, Ke, Qe, _e, $e, qe, st, rt, ct;
50687
+ if (this.pencil) return;
50688
+ if (this.pencilConfig = li({}, this.pencilConfig), this.options.css2DContainer && (this.pencilConfig.css2DRendererParams = {
50696
50689
  container: this.options.css2DContainer
50697
- });
50698
- const r = new Vt$1(li(li(Pi(li({
50699
- container: this.container,
50700
- isdev: !this.playing && IS_DEV,
50701
- stats: !this.playing && IS_DEV,
50702
- gui: !this.playing && IS_DEV,
50703
- helper: !this.playing,
50704
- viewHelper: !this.playing,
50705
- transformControls: !this.playing,
50706
- css2DRenderer: !0
50707
- }, this.tier0 ? {
50708
- composer: {
50709
- multisampling: 0
50710
- }
50711
- } : {}), {
50712
- renderer: {
50713
- alpha: !0,
50714
- logarithmicDepthBuffer: this.options.logarithmicDepthBuffer
50715
- },
50716
- camera: {
50717
- near: 0.1,
50718
- far: 1e3,
50719
- fov: 45
50720
- },
50721
- bloom: !0,
50722
- ssao: !0,
50723
- ssaoParams: {
50724
- minDistance: 1e-3
50725
- },
50726
- scene: {
50727
- background: new Color$1(0)
50728
- }
50729
- }), this.pencilConfig), this.options.pencilConfig));
50730
- this.sceneActive = 0;
50731
- const c = r.composerController.ssaoPass;
50732
- c && (c.enabled = !1), this.leftTruck && (r.controls.mouseButtons.left = ws.TRUCK, r.controls.mouseButtons.right = ws.ROTATE), this.initPencilPlugin(r), yield this.drawController.initGroup(), (Wt = this.drawController.group) == null || Wt.hide(), (Yt = this.drawController.prefabGroup) == null || Yt.hide(), this.pencil = r, this.initSceneUserData(), this.playing || (window.vis = this, window.pencil = r), this.initSettings();
50690
+ }), this.options.pencil)
50691
+ this.pencil = this.options.pencil, this.sceneActive = this.pencil.addPage({
50692
+ cameraOptions: {
50693
+ fov: (Je = (c = this.pencilConfig.camera) == null ? void 0 : c.fov) != null ? Je : 45,
50694
+ near: (Qe = (Ke = this.pencilConfig.camera) == null ? void 0 : Ke.near) != null ? Qe : 0.1,
50695
+ far: ($e = (_e = this.pencilConfig.camera) == null ? void 0 : _e.far) != null ? $e : 1e3,
50696
+ up: (st = (qe = this.pencilConfig.camera) == null ? void 0 : qe.up) != null ? st : new Vector3(0, 1, 0)
50697
+ }
50698
+ }), this.setSceneActive(), this.drawController.install(this.pencil), this.mList.install(this.pencil);
50699
+ else {
50700
+ const Zt = new Vt$1(li(li(Pi(li({
50701
+ container: this.container,
50702
+ isdev: !this.playing && IS_DEV,
50703
+ stats: !this.playing && IS_DEV,
50704
+ gui: !this.playing && IS_DEV,
50705
+ helper: !this.playing,
50706
+ viewHelper: !this.playing,
50707
+ transformControls: !this.playing,
50708
+ css2DRenderer: !0
50709
+ }, this.tier0 ? {
50710
+ composer: {
50711
+ multisampling: 0
50712
+ }
50713
+ } : {}), {
50714
+ renderer: {
50715
+ alpha: !0,
50716
+ logarithmicDepthBuffer: this.options.logarithmicDepthBuffer
50717
+ },
50718
+ camera: {
50719
+ near: 0.1,
50720
+ far: 1e3,
50721
+ fov: 45
50722
+ },
50723
+ bloom: !0,
50724
+ ssao: !0,
50725
+ ssaoParams: {
50726
+ minDistance: 1e-3
50727
+ },
50728
+ scene: {
50729
+ background: new Color$1(0)
50730
+ }
50731
+ }), this.pencilConfig), this.options.pencilConfig));
50732
+ this.pencil = Zt, this.sceneActive = 0;
50733
+ const Wt = Zt.composerController.ssaoPass;
50734
+ Wt && (Wt.enabled = !1), this.initPencilPlugin(Zt), this.playing || (window.vis = this, window.pencil = Zt);
50735
+ }
50736
+ const r = this.pencil;
50737
+ this.leftTruck && (r.controls.mouseButtons.left = ws.TRUCK, r.controls.mouseButtons.right = ws.ROTATE), yield this.drawController.initGroup(), (rt = this.drawController.group) == null || rt.hide(), (ct = this.drawController.prefabGroup) == null || ct.hide(), this.initSceneUserData(), this.initSettings();
50733
50738
  });
50734
50739
  }
50735
50740
  setSceneActive() {
@@ -131682,8 +131687,10 @@ const objs$4 = Pi(li({}, objs$5), {
131682
131687
  }
131683
131688
  });
131684
131689
  }
131685
- setPadding(r, c = !1) {
131686
- this.options.mapPadding = r, c && this.fitTo(this.map);
131690
+ setPadding(r, c = !1, Je = !1) {
131691
+ this.options.mapPadding = r, c && this.fitTo(this.map, {
131692
+ enableTransition: Je
131693
+ });
131687
131694
  }
131688
131695
  dispose() {
131689
131696
  var r, c;
package/dist/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- declare const _default: "0.24.11";
1
+ declare const _default: "0.24.12";
2
2
  export default _default;
@@ -208,7 +208,7 @@ export default class extends Base {
208
208
  adcodes: number[];
209
209
  duration?: number;
210
210
  }): Promise<void>;
211
- setPadding(padding: number[], fitTo?: boolean): void;
211
+ setPadding(padding: number[], fitTo?: boolean, enableTransition?: boolean): void;
212
212
  dispose(): void;
213
213
  }
214
214
  export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vis-core",
3
- "version": "0.24.11",
3
+ "version": "0.24.12",
4
4
  "scripts": {
5
5
  "start": "npm run version && PORT=5173 bundler-dev",
6
6
  "build:site": "npm run version && bundler",