@realsee/dnalogel 3.33.1-dev.0 → 3.33.1-dev.1

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.
@@ -1,25 +1,25 @@
1
1
  var F = Object.defineProperty, C = Object.defineProperties;
2
- var E = Object.getOwnPropertyDescriptors;
3
- var u = Object.getOwnPropertySymbols;
4
- var R = Object.prototype.hasOwnProperty, D = Object.prototype.propertyIsEnumerable;
5
- var a = (r, i, e) => i in r ? F(r, i, { enumerable: !0, configurable: !0, writable: !0, value: e }) : r[i] = e, p = (r, i) => {
2
+ var D = Object.getOwnPropertyDescriptors;
3
+ var f = Object.getOwnPropertySymbols;
4
+ var R = Object.prototype.hasOwnProperty, O = Object.prototype.propertyIsEnumerable;
5
+ var m = (r, i, e) => i in r ? F(r, i, { enumerable: !0, configurable: !0, writable: !0, value: e }) : r[i] = e, p = (r, i) => {
6
6
  for (var e in i || (i = {}))
7
- R.call(i, e) && a(r, e, i[e]);
8
- if (u)
9
- for (var e of u(i))
10
- D.call(i, e) && a(r, e, i[e]);
7
+ R.call(i, e) && m(r, e, i[e]);
8
+ if (f)
9
+ for (var e of f(i))
10
+ O.call(i, e) && m(r, e, i[e]);
11
11
  return r;
12
- }, m = (r, i) => C(r, E(i));
13
- var o = (r, i, e) => (a(r, typeof i != "symbol" ? i + "" : i, e), e);
12
+ }, h = (r, i) => C(r, D(i));
13
+ var o = (r, i, e) => (m(r, typeof i != "symbol" ? i + "" : i, e), e);
14
14
  import { CSS3DRender as S } from "./utils/three/CSS3DRender.js";
15
- import O from "./utils/generateBehindFiveElement.js";
15
+ import j from "./utils/generateBehindFiveElement.js";
16
16
  import "hammerjs";
17
17
  import "three";
18
18
  import "@realsee/five";
19
19
  import "../vendor/@tweenjs/tween/dist/tween.esm.js.js";
20
20
  import "animejs";
21
- import { absoluteUrl as j } from "../shared-utils/url/absoluteUrl.js";
22
- import { waitFiveModelLoaded as x } from "../shared-utils/five/fiveModelLoad.js";
21
+ import { absoluteUrl as x } from "../shared-utils/url/absoluteUrl.js";
22
+ import { waitFiveModelLoaded as P } from "../shared-utils/five/fiveModelLoad.js";
23
23
  import "../shared-utils/positionToVector3.js";
24
24
  import "./utils/three/CSS3DRenderer.js";
25
25
  import "three/examples/jsm/renderers/CSS3DRenderer";
@@ -34,14 +34,14 @@ import "../shared-utils/three/centerPoint.js";
34
34
  import "../shared-utils/three/getObjectVisible.js";
35
35
  import "./utils/three/CSS3DScene.js";
36
36
  import "./utils/three/CSS3DGroup.js";
37
- const b = "v2.0.1", f = `CSS3DRenderPlugin@${b}`;
38
- class Y extends S {
37
+ const E = "v2.0.1", b = `CSS3DRenderPlugin@${E}`;
38
+ class Z extends S {
39
39
  constructor(e) {
40
40
  super();
41
41
  o(this, "five");
42
42
  o(this, "behindFiveContainer");
43
43
  o(this, "frontFiveContainer");
44
- o(this, "VERSION", b);
44
+ o(this, "VERSION", E);
45
45
  o(this, "staticPrefix", "//vr-image-4.realsee-cdn.cn");
46
46
  o(this, "created3DElementResults", []);
47
47
  /**
@@ -82,31 +82,32 @@ class Y extends S {
82
82
  o(this, "create3DDomContainer", (e, t) => {
83
83
  if (this.state.disposed)
84
84
  return;
85
- const s = (() => {
86
- var c;
87
- (t == null ? void 0 : t.dpr) !== void 0 && console.warn(`${f}: please use "config.devicePixelRatio" replace "config.dpr"`);
88
- const d = {
85
+ const d = (() => {
86
+ var a;
87
+ (t == null ? void 0 : t.dpr) !== void 0 && console.warn(`${b}: please use "config.devicePixelRatio" replace "config.dpr"`);
88
+ const s = {
89
89
  ratio: 216e-5,
90
- devicePixelRatio: (c = t == null ? void 0 : t.dpr) != null ? c : 1,
90
+ devicePixelRatio: (a = t == null ? void 0 : t.dpr) != null ? a : 1,
91
91
  mode: "front",
92
92
  autoRender: !0,
93
93
  wrapperStyle: {}
94
94
  };
95
- return Object.assign(d, t, (t == null ? void 0 : t.mode) === "behind" ? { scene: this.five.scene } : void 0);
96
- })(), { autoRender: h } = s;
97
- s.mode === "behind" && s.behindFiveContainer && (this.behindFiveContainer = s.behindFiveContainer);
98
- const n = this.create3DElement(this.five.camera, e, m(p({}, s), { autoRender: !1 }));
95
+ return Object.assign(s, t, (t == null ? void 0 : t.mode) === "behind" ? { scene: this.five.scene } : void 0);
96
+ })(), { autoRender: l } = d;
97
+ d.mode === "behind" && d.behindFiveContainer && (this.behindFiveContainer = d.behindFiveContainer);
98
+ const n = this.create3DElement(this.five.camera, e, h(p({}, d), { autoRender: !1 }));
99
99
  if (!n)
100
100
  return;
101
- const l = () => {
102
- const d = n.css3DObject.mode === "front" ? this.frontFiveContainer : this.getBehindFiveElement();
103
- if (!d)
104
- return console.error(`${f}: wrapper is ${d}`);
105
- n.appendToElement(d), n.render(), this.created3DElementResults.push(n);
106
- }, v = () => {
107
- n.css3DObject.mode === "front" && l(), n.css3DObject.mode === "behind" && x(this.five).then(() => l());
101
+ const v = () => {
102
+ var a, u;
103
+ const s = n.css3DObject.mode === "front" ? (u = this.frontFiveContainer) != null ? u : (a = this.five.getElement()) == null ? void 0 : a.parentElement : this.getBehindFiveElement();
104
+ if (console.log({ wrapper: s }), !s)
105
+ return console.error(`${b}: wrapper is ${s}; mode is ${n.css3DObject.mode}`);
106
+ n.appendToElement(s), n.render(), this.created3DElementResults.push(n);
107
+ }, c = () => {
108
+ n.css3DObject.mode === "front" && v(), n.css3DObject.mode === "behind" && P(this.five).then(() => v());
108
109
  };
109
- return h && v(), m(p({}, n), { render: h ? void 0 : v });
110
+ return l && c(), h(p({}, n), { render: l ? void 0 : c });
110
111
  });
111
112
  this.five = e;
112
113
  }
@@ -129,16 +130,16 @@ class Y extends S {
129
130
  });
130
131
  }
131
132
  getBehindFiveElement() {
132
- return this.behindFiveContainer ? this.behindFiveContainer : (this.behindFiveContainer = O(this.five), this.behindFiveContainer);
133
+ return this.behindFiveContainer ? this.behindFiveContainer : (this.behindFiveContainer = j(this.five), this.behindFiveContainer);
133
134
  }
134
135
  /**
135
136
  * @description: 获取静态资源的url
136
137
  */
137
138
  absoluteUrl(e) {
138
- return j(this.staticPrefix, e);
139
+ return x(this.staticPrefix, e);
139
140
  }
140
141
  }
141
142
  export {
142
- f as PLUGIN_NAME,
143
- Y as default
143
+ b as PLUGIN_NAME,
144
+ Z as default
144
145
  };
@@ -16,7 +16,7 @@ class v extends d {
16
16
  this.domElementWrapper.classList.add("ICSS3DRendererWrapper"), this.domElementWrapper.style.position = "absolute", this.domElementWrapper.style.top = "0", this.domElementWrapper.style.left = "0", this.domElementWrapper.style.width = "100%", this.domElementWrapper.style.height = "100%", this.domElementWrapper.style.userSelect = "none", this.domElementWrapper.style.pointerEvents = "none", this.domElement.classList.add("ICSS3DRenderer"), this.domElement.style.position = "absolute", this.domElement.style.top = "0", this.domElement.style.left = "0", this.domElement.style.userSelect = "none", this.domElement.style.pointerEvents = "none", this.domElementWrapper.appendChild(this.domElement);
17
17
  }
18
18
  setWrapper(e) {
19
- if (!e)
19
+ if (console.log("setWrapper", e, this.wrapper), !e)
20
20
  throw new Error("CSS3DRenderer: wrapper is required");
21
21
  if ((() => {
22
22
  for (let s = 0; s < e.children.length; s++)
@@ -283,9 +283,9 @@ class Gi extends j {
283
283
  }
284
284
  appendTo(e) {
285
285
  var i, s, o, n;
286
- this.container = e;
287
- const t = (s = (i = this.TagContainerSvelte) == null ? void 0 : i.$$) == null ? void 0 : s.root;
288
- t && t !== this.container && ((o = this.css3DRenderPlugin) == null || o.appendToFrontFiveContainer(this.container), (n = this.TagContainerSvelte) == null || n.$destroy(), this.TagContainerSvelte = void 0, this.updateDomView());
286
+ this.container = e, (i = this.css3DRenderPlugin) == null || i.appendToFrontFiveContainer(this.container);
287
+ const t = (o = (s = this.TagContainerSvelte) == null ? void 0 : s.$$) == null ? void 0 : o.root;
288
+ t && t !== this.container && ((n = this.TagContainerSvelte) == null || n.$destroy(), this.TagContainerSvelte = void 0, this.updateDomView());
289
289
  }
290
290
  /**
291
291
  * @description 加载数据
@@ -15,7 +15,7 @@ let v = class {
15
15
  /**
16
16
  * @realsee/dnalogel 版本号
17
17
  */
18
- i(this, "VERSION", "3.33.1-dev.0");
18
+ i(this, "VERSION", "3.33.1-dev.1");
19
19
  i(this, "five");
20
20
  /**
21
21
  * @description: 插件事件钩子
@@ -1,6 +1,6 @@
1
1
  function A() {
2
2
  console.debug(
3
- "%c %c@realsee/dnalogel %cv3.33.1-dev.0",
3
+ "%c %c@realsee/dnalogel %cv3.33.1-dev.1",
4
4
  [
5
5
  "background: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAkAAAAMCAMAAACHgmeRAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAABLFBMVEUAAAAapPoap/oaqvkbrfkbr/gZnfwZoPsaqfnD4v/E4/8Ylv0clPm93/+/4P/B4f8Yj/683/8Wif+33P8Uhv+x2f8ShP+s1v8Pgf+n0/8Nf/+h0f8Lff8Lff8Nf/9dl/+czv8KfP8KfP+Lxf+Uyv+Xy/+Hwv+Jw/+Mxf+Oxv+RyP8aovsapfoap/oZmfwZm/wZnvsYnPsYkf4YlP0NePsDYfgYcfi43f+63v8Xiv8Xjf4EWfwCV/sWZ/qz2v+02/8Vh/8WiP8EUf8CTf4WXv2u1/+v2P8Thf8Thv8ETf8CR/8VV/+o1f+q1f8Qgv8Rg/8DSv8BRf8UVP+j0v+k0v8OgP8Pgf8DR/8DQv9Nhf+dzv+fz/+Kv/+Vyv+Xy/+azf+Oxv+Qx/+SyP////8MUhLdAAAAK3RSTlMACEWQ2bd98uQECPXxqO7c+Pb49vj2+Pb49vj23Oul8fMHA+TwerXXjEIG2P+bHgAAAAFiS0dEY1y+LaoAAAB+SURBVAjXY2BgZGJmYWVgYGBgY9fW0eVg4ORi4NbTNzDk4eXjZxAwMjYxNTO3EGQQsrSytrG1sxdmEHFwdHJ2cXUTZRBz9/D08vbxFWeQ8PMPCAwKDpFkkAoNC4+IjIqWZpCRlZOPiY2LV2BQVGJQTkhMUlEFWaOmrqGpxQAAyg0S9Dq+VPYAAAAASUVORK5CYII=')",
6
6
  "background-repeat: no-repeat",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@realsee/dnalogel",
3
- "version": "3.33.1-dev.0",
3
+ "version": "3.33.1-dev.1",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./libs/index.js",
6
6
  "types": "./libs/index.d.ts",