@realsee/dnalogel 3.44.1 → 3.44.3
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.
- package/CHANGELOG.md +6 -0
- package/dist/PanoTagPlugin/controller/TagUtil.d.ts +4 -1
- package/dist/index.cjs.js +5 -5
- package/dist/index.js +22 -16
- package/dist/index.umd.js +5 -5
- package/libs/CurrentPanoImagePlugin/Controller.js +43 -39
- package/libs/PanoTagPlugin/Components/Common/TagPoint.js +37 -37
- package/libs/PanoTagPlugin/controller/TagUtil.d.ts +4 -1
- package/libs/PanoTagPlugin/controller/TagUtil.js +13 -9
- package/libs/PanoTagPlugin/controller/index.js +6 -8
- package/libs/base/BasePlugin.js +1 -1
- package/libs/shared-utils/logger.js +1 -1
- package/libs/shared-utils/three/PointSelector/utils/PointSelectorHelper.js +5 -5
- package/package.json +1 -1
|
@@ -1,32 +1,32 @@
|
|
|
1
1
|
var m = Object.defineProperty;
|
|
2
2
|
var p = Object.getOwnPropertySymbols;
|
|
3
3
|
var v = Object.prototype.hasOwnProperty, b = Object.prototype.propertyIsEnumerable;
|
|
4
|
-
var g = (
|
|
4
|
+
var g = (r, o, e) => o in r ? m(r, o, { enumerable: !0, configurable: !0, writable: !0, value: e }) : r[o] = e, a = (r, o) => {
|
|
5
5
|
for (var e in o || (o = {}))
|
|
6
|
-
v.call(o, e) && g(
|
|
6
|
+
v.call(o, e) && g(r, e, o[e]);
|
|
7
7
|
if (p)
|
|
8
8
|
for (var e of p(o))
|
|
9
|
-
b.call(o, e) && g(
|
|
10
|
-
return
|
|
9
|
+
b.call(o, e) && g(r, e, o[e]);
|
|
10
|
+
return r;
|
|
11
11
|
};
|
|
12
|
-
var n = (
|
|
13
|
-
var
|
|
12
|
+
var n = (r, o, e) => (g(r, typeof o != "symbol" ? o + "" : o, e), e);
|
|
13
|
+
var u = (r, o, e) => new Promise((i, t) => {
|
|
14
14
|
var s = (d) => {
|
|
15
15
|
try {
|
|
16
|
-
|
|
16
|
+
f(e.next(d));
|
|
17
17
|
} catch (c) {
|
|
18
18
|
t(c);
|
|
19
19
|
}
|
|
20
|
-
},
|
|
20
|
+
}, l = (d) => {
|
|
21
21
|
try {
|
|
22
|
-
|
|
22
|
+
f(e.throw(d));
|
|
23
23
|
} catch (c) {
|
|
24
24
|
t(c);
|
|
25
25
|
}
|
|
26
|
-
},
|
|
27
|
-
|
|
26
|
+
}, f = (d) => d.done ? i(d.value) : Promise.resolve(d.value).then(s, l);
|
|
27
|
+
f((e = e.apply(r, o)).next());
|
|
28
28
|
});
|
|
29
|
-
import * as
|
|
29
|
+
import * as h from "three";
|
|
30
30
|
import { Controller as M } from "../base/BasePlugin.js";
|
|
31
31
|
import { tweenProgress as A } from "../shared-utils/animationFrame/BetterTween.js";
|
|
32
32
|
import "hammerjs";
|
|
@@ -34,8 +34,8 @@ import "three/examples/jsm/renderers/CSS3DRenderer";
|
|
|
34
34
|
import "@realsee/five/line";
|
|
35
35
|
import "../shared-utils/three/THREESphere.js";
|
|
36
36
|
import "animejs";
|
|
37
|
-
import { equal as
|
|
38
|
-
import { loadTexture as
|
|
37
|
+
import { equal as P } from "../shared-utils/equal.js";
|
|
38
|
+
import { loadTexture as w } from "../shared-utils/three/loadTexture.js";
|
|
39
39
|
import "../shared-utils/Subscribe.js";
|
|
40
40
|
import "../shared-utils/Utils/FiveUtil.js";
|
|
41
41
|
import "../shared-utils/Utils/BaseUtil.js";
|
|
@@ -62,7 +62,7 @@ class E extends M {
|
|
|
62
62
|
pluginHidden: ""
|
|
63
63
|
});
|
|
64
64
|
// ==================== private properties ====================
|
|
65
|
-
n(this, "group", new
|
|
65
|
+
n(this, "group", new h.Group());
|
|
66
66
|
n(this, "mesh");
|
|
67
67
|
n(this, "textureLoadingPromise");
|
|
68
68
|
n(this, "opacityAnimeTween");
|
|
@@ -120,20 +120,20 @@ class E extends M {
|
|
|
120
120
|
visible: !0
|
|
121
121
|
};
|
|
122
122
|
this.state = Object.assign(t, i == null ? void 0 : i.initialState);
|
|
123
|
-
const s =
|
|
123
|
+
const s = a({
|
|
124
124
|
width: 1.4,
|
|
125
125
|
yOffset: 0.01,
|
|
126
126
|
yRotate: 0,
|
|
127
127
|
imageURL: this.absoluteUrl("/release/web/logo.7febb17f.png")
|
|
128
128
|
}, i == null ? void 0 : i.config);
|
|
129
|
-
this._config = s, this.group.name = "current-pano-image-plugin-group", this.mesh = new
|
|
130
|
-
new
|
|
131
|
-
new
|
|
129
|
+
this._config = s, this.group.name = "current-pano-image-plugin-group", this.mesh = new h.Mesh(
|
|
130
|
+
new h.PlaneBufferGeometry(this.config.width, this.config.width),
|
|
131
|
+
new h.MeshBasicMaterial({ transparent: !0, opacity: 0, depthTest: !1 })
|
|
132
132
|
), this.mesh.visible = !1, this.group.add(this.mesh), this.updateMeshQuaternion(this.config.yRotate), this.state.visible || (this.checkMsg.pluginHidden = "初始值设置为隐藏"), this.state.enabled || (this.checkMsg.pluginDisabled = "初始值设置为禁用"), this.state.enabled && this._enable({ userAction: !1 }), this.five.once("dispose", this.dispose);
|
|
133
133
|
}
|
|
134
134
|
/** 插件配置项 */
|
|
135
135
|
get config() {
|
|
136
|
-
return
|
|
136
|
+
return a({}, this._config);
|
|
137
137
|
}
|
|
138
138
|
/** 是否已经被销毁 */
|
|
139
139
|
get disposed() {
|
|
@@ -166,12 +166,12 @@ class E extends M {
|
|
|
166
166
|
* @param `options.userAction` `<boolean> | <undefined>` 是否是用户操作。默认是 true。
|
|
167
167
|
*/
|
|
168
168
|
show(e) {
|
|
169
|
-
return
|
|
169
|
+
return u(this, null, function* () {
|
|
170
170
|
if (this.state.visible)
|
|
171
171
|
return Promise.resolve();
|
|
172
172
|
if (this.disposed)
|
|
173
173
|
return Promise.reject(new Error("不能在已销毁的插件上调用 show"));
|
|
174
|
-
const i =
|
|
174
|
+
const i = a({ userAction: !0 }, e);
|
|
175
175
|
this.updateState({ visible: !0 }, i.userAction), this.checkMsg.pluginHidden = "", this._show(i);
|
|
176
176
|
});
|
|
177
177
|
}
|
|
@@ -180,10 +180,10 @@ class E extends M {
|
|
|
180
180
|
* @param `options.userAction` `<boolean> | <undefined>` 是否是用户操作。默认是 true。
|
|
181
181
|
*/
|
|
182
182
|
hide(e) {
|
|
183
|
-
return
|
|
183
|
+
return u(this, null, function* () {
|
|
184
184
|
if (this.state.visible === !1)
|
|
185
185
|
return;
|
|
186
|
-
const i =
|
|
186
|
+
const i = a({ userAction: !0 }, e);
|
|
187
187
|
this.updateState({ visible: !1 }, i.userAction), this.checkMsg.pluginDisabled = "调用 hide 隐藏", this._hide(i);
|
|
188
188
|
});
|
|
189
189
|
}
|
|
@@ -194,12 +194,12 @@ class E extends M {
|
|
|
194
194
|
*/
|
|
195
195
|
setState(e, i = {}) {
|
|
196
196
|
const t = this.state;
|
|
197
|
-
if (
|
|
197
|
+
if (P(e, t, { deep: !0 }))
|
|
198
198
|
return;
|
|
199
199
|
const s = i.userAction !== void 0 ? i.userAction : !0;
|
|
200
200
|
if (this.updateState(e, s), e.enabled !== void 0 && t.enabled !== e.enabled && (e.enabled ? this.checkMsg.pluginDisabled = "" : this.checkMsg.pluginDisabled = "调用 setState 禁用", e.enabled ? this._enable({ userAction: s }) : this._disable({ userAction: s })), e.visible !== void 0 && t.visible !== e.visible) {
|
|
201
|
-
const
|
|
202
|
-
e.visible ? this.checkMsg.pluginHidden = "" : this.checkMsg.pluginHidden = "调用 setState 隐藏", e.visible ? this._show(
|
|
201
|
+
const l = { userAction: s, anime: { duration: 500 } };
|
|
202
|
+
e.visible ? this.checkMsg.pluginHidden = "" : this.checkMsg.pluginHidden = "调用 setState 隐藏", e.visible ? this._show(l) : this._hide(l);
|
|
203
203
|
}
|
|
204
204
|
}
|
|
205
205
|
/** 更改插件 Config
|
|
@@ -207,9 +207,9 @@ class E extends M {
|
|
|
207
207
|
* @param `options` `<Option> | <undefined>`
|
|
208
208
|
*/
|
|
209
209
|
updateConfig(e, i = {}) {
|
|
210
|
-
var
|
|
211
|
-
const t = this.config, s =
|
|
212
|
-
this._config = s, t.imageURL !== s.imageURL && this.reloadTexture(s.imageURL), t.yOffset !== s.yOffset && this.updateMeshPosition(this.five.getCurrentState().panoIndex), t.yRotate !== s.yRotate && this.updateMeshQuaternion(s.yRotate), t.width !== s.width && (this.mesh.geometry = new
|
|
210
|
+
var l;
|
|
211
|
+
const t = this.config, s = a(a({}, t), e);
|
|
212
|
+
this._config = s, t.imageURL !== s.imageURL && this.reloadTexture(s.imageURL), t.yOffset !== s.yOffset && this.updateMeshPosition(this.five.getCurrentState().panoIndex), t.yRotate !== s.yRotate && this.updateMeshQuaternion(s.yRotate), t.width !== s.width && (this.mesh.geometry = new h.PlaneBufferGeometry(s.width, s.width)), this.hooks.emit("configChange", { prevConfig: t, config: s, userAction: (l = i.userAction) != null ? l : !0 });
|
|
213
213
|
}
|
|
214
214
|
/** 问什么看不到模型 */
|
|
215
215
|
__whyCantSeeMesh() {
|
|
@@ -224,7 +224,7 @@ class E extends M {
|
|
|
224
224
|
}
|
|
225
225
|
updateState(e, i) {
|
|
226
226
|
const t = this.state;
|
|
227
|
-
this.state =
|
|
227
|
+
this.state = a(a({}, this.state), e), this.hooks.emit("stateChange", { state: this.state, prevState: t, userAction: i });
|
|
228
228
|
}
|
|
229
229
|
/** 根据各种条件更新 Mesh 的可见性 */
|
|
230
230
|
updateMeshVisible() {
|
|
@@ -233,30 +233,34 @@ class E extends M {
|
|
|
233
233
|
}
|
|
234
234
|
/** 根据点位更新 Mesh 坐标 */
|
|
235
235
|
updateMeshPosition(e) {
|
|
236
|
-
|
|
237
|
-
|
|
236
|
+
const i = this.workUtil.getObserverStandingPosition(e);
|
|
237
|
+
if (!i) {
|
|
238
|
+
console.warn("CurrentPanoImagePlugin: 无法获取到当前点位的 standingPosition");
|
|
239
|
+
return;
|
|
240
|
+
}
|
|
241
|
+
const t = i.clone().setY(i.y + this.config.yOffset);
|
|
238
242
|
t && this.mesh.position.copy(t);
|
|
239
243
|
}
|
|
240
244
|
/** 重新加载贴图,调用时会先清除已有的贴图 */
|
|
241
245
|
reloadTexture(e) {
|
|
242
|
-
return
|
|
246
|
+
return u(this, null, function* () {
|
|
243
247
|
if (this.mesh.material.map = null, e !== "") {
|
|
244
|
-
const i =
|
|
248
|
+
const i = w(e);
|
|
245
249
|
this.textureLoadingPromise = i;
|
|
246
250
|
const t = yield i;
|
|
247
|
-
t.minFilter =
|
|
251
|
+
t.minFilter = h.LinearFilter, this.textureLoadingPromise === i && (this.onTextureLoaded(t), this.textureLoadingPromise = null);
|
|
248
252
|
}
|
|
249
253
|
this.updateMeshVisible();
|
|
250
254
|
});
|
|
251
255
|
}
|
|
252
256
|
/** north_rad 变化时,需要更新模型的旋转角度 */
|
|
253
257
|
updateMeshQuaternion(e) {
|
|
254
|
-
const i = new
|
|
258
|
+
const i = new h.Quaternion();
|
|
255
259
|
i.multiplyQuaternions(
|
|
256
260
|
// 沿着自身 X 轴旋转 -90 度
|
|
257
|
-
new
|
|
261
|
+
new h.Quaternion().setFromAxisAngle(new h.Vector3(1, 0, 0), -Math.PI / 2),
|
|
258
262
|
// 沿着自身 Z 轴旋转 rad 弧度
|
|
259
|
-
new
|
|
263
|
+
new h.Quaternion().setFromAxisAngle(new h.Vector3(0, 0, 1), e)
|
|
260
264
|
), this.mesh.quaternion.copy(i);
|
|
261
265
|
}
|
|
262
266
|
_enable(e) {
|
|
@@ -15,11 +15,11 @@ import "../../../vendor/svelte/easing/index.js";
|
|
|
15
15
|
import "../../utils/noTypecheck.js";
|
|
16
16
|
import "../../utils/getImageInfo.js";
|
|
17
17
|
import "../../utils/px2rem.js";
|
|
18
|
-
function Q(
|
|
19
|
-
U(
|
|
18
|
+
function Q(t) {
|
|
19
|
+
U(t, "svelte-7aiuwz", '@charset "UTF-8";.tag-point-click-helper.svelte-7aiuwz.svelte-7aiuwz{position:absolute;pointer-events:auto;cursor:pointer;width:calc(100% + 0.75rem);height:calc(100% + 0.75rem);left:50%;top:50%;transform:translate(-50%, -50%)}.tag-point-wrapper.svelte-7aiuwz.svelte-7aiuwz{pointer-events:none;position:absolute;left:50%;top:50%;transform:translate(-50%, -50%)}.tag-folded-point.svelte-7aiuwz.svelte-7aiuwz,.tag-unfolded-point.svelte-7aiuwz.svelte-7aiuwz{transition:all 0.5s}.tag-point-wrapper.svelte-7aiuwz .tag-unfolded-point.svelte-7aiuwz{display:flex;justify-content:center;align-items:center;position:absolute;width:100%;height:100%;border-radius:50%}.tag-point-wrapper.svelte-7aiuwz .tag-unfolded-point.svelte-7aiuwz:after{content:"";position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);width:0.3125rem;height:0.3125rem;border-radius:50%;background-color:white}.tag-point-wrapper.svelte-7aiuwz .tag-unfolded-point.svelte-7aiuwz:before{content:"";position:absolute;width:0.875rem;height:0.875rem;border-radius:50%;background-color:rgba(0, 0, 0, 0.2)}.tag-point-wrapper.folded.svelte-7aiuwz .tag-folded-point.svelte-7aiuwz{opacity:1;scale:1}.tag-point-wrapper.folded.svelte-7aiuwz .tag-unfolded-point.svelte-7aiuwz{opacity:0;scale:1}.tag-point-wrapper.unfolded.svelte-7aiuwz .tag-folded-point.svelte-7aiuwz{opacity:0;scale:0.2}.tag-point-wrapper.unfolded.svelte-7aiuwz .tag-unfolded-point.svelte-7aiuwz{opacity:1;scale:1}');
|
|
20
20
|
}
|
|
21
|
-
function V(
|
|
22
|
-
let o, r, u, d, c, p, w,
|
|
21
|
+
function V(t) {
|
|
22
|
+
let o, r, u, d, c, p, w, e, a, l, g, v;
|
|
23
23
|
return d = new H({
|
|
24
24
|
props: {
|
|
25
25
|
center: !0,
|
|
@@ -31,53 +31,53 @@ function V(e) {
|
|
|
31
31
|
props: {
|
|
32
32
|
icon: (
|
|
33
33
|
/*url*/
|
|
34
|
-
|
|
34
|
+
t[2]
|
|
35
35
|
),
|
|
36
36
|
width: (
|
|
37
37
|
/*width*/
|
|
38
|
-
|
|
38
|
+
t[1]
|
|
39
39
|
)
|
|
40
40
|
}
|
|
41
41
|
}), a.$on(
|
|
42
42
|
"iconLoaded",
|
|
43
43
|
/*iconLoaded_handler*/
|
|
44
|
-
|
|
44
|
+
t[7]
|
|
45
45
|
), {
|
|
46
46
|
c() {
|
|
47
|
-
o = h("div"), r = h("div"), u = _(), S(d.$$.fragment), c = _(), p = h("div"), w = _(),
|
|
47
|
+
o = h("div"), r = h("div"), u = _(), S(d.$$.fragment), c = _(), p = h("div"), w = _(), e = h("div"), S(a.$$.fragment), z(r, "class", "tag-point-click-helper svelte-7aiuwz"), z(p, "class", "tag-unfolded-point svelte-7aiuwz"), y(
|
|
48
48
|
p,
|
|
49
49
|
"transition-delay",
|
|
50
50
|
/*folded*/
|
|
51
|
-
(
|
|
51
|
+
(t[3] ? (
|
|
52
52
|
/*foldDelay*/
|
|
53
|
-
|
|
53
|
+
t[5]
|
|
54
54
|
) : 0) + "ms"
|
|
55
|
-
), z(
|
|
56
|
-
|
|
55
|
+
), z(e, "class", "tag-folded-point svelte-7aiuwz"), y(
|
|
56
|
+
e,
|
|
57
57
|
"transition-delay",
|
|
58
58
|
/*folded*/
|
|
59
|
-
(
|
|
59
|
+
(t[3] ? (
|
|
60
60
|
/*foldDelay*/
|
|
61
|
-
|
|
61
|
+
t[5]
|
|
62
62
|
) : 0) + "ms"
|
|
63
63
|
), z(o, "class", "tag-point-wrapper svelte-7aiuwz"), b(
|
|
64
64
|
o,
|
|
65
65
|
"unfolded",
|
|
66
66
|
/*unfolded*/
|
|
67
|
-
|
|
67
|
+
t[0]
|
|
68
68
|
), b(
|
|
69
69
|
o,
|
|
70
70
|
"folded",
|
|
71
71
|
/*folded*/
|
|
72
|
-
|
|
72
|
+
t[3]
|
|
73
73
|
);
|
|
74
74
|
},
|
|
75
75
|
m(i, s) {
|
|
76
|
-
W(i, o, s), m(o, r), m(o, u), A(d, o, null), m(o, c), m(o, p), m(o, w), m(o,
|
|
76
|
+
W(i, o, s), m(o, r), m(o, u), A(d, o, null), m(o, c), m(o, p), m(o, w), m(o, e), A(a, e, null), l = !0, g || (v = X(
|
|
77
77
|
r,
|
|
78
78
|
"click",
|
|
79
79
|
/*handlePointClick*/
|
|
80
|
-
|
|
80
|
+
t[4]
|
|
81
81
|
), g = !0);
|
|
82
82
|
},
|
|
83
83
|
p(i, [s]) {
|
|
@@ -98,7 +98,7 @@ function V(e) {
|
|
|
98
98
|
2 && (n.width = /*width*/
|
|
99
99
|
i[1]), a.$set(n), s & /*folded*/
|
|
100
100
|
8 && y(
|
|
101
|
-
|
|
101
|
+
e,
|
|
102
102
|
"transition-delay",
|
|
103
103
|
/*folded*/
|
|
104
104
|
(i[3] ? (
|
|
@@ -130,10 +130,10 @@ function V(e) {
|
|
|
130
130
|
}
|
|
131
131
|
};
|
|
132
132
|
}
|
|
133
|
-
function Y(
|
|
133
|
+
function Y(t, o, r) {
|
|
134
134
|
let u, d, c, p;
|
|
135
135
|
const w = E("hooks");
|
|
136
|
-
let { tag:
|
|
136
|
+
let { tag: e } = o, a, l = !1;
|
|
137
137
|
const g = () => {
|
|
138
138
|
a !== void 0 && clearTimeout(a), l = !0, a = setTimeout(
|
|
139
139
|
() => {
|
|
@@ -142,25 +142,25 @@ function Y(e, o, r) {
|
|
|
142
142
|
800
|
|
143
143
|
);
|
|
144
144
|
}, v = (n) => {
|
|
145
|
-
l || (
|
|
146
|
-
}, i = (() =>
|
|
145
|
+
l || (e.entryFromModel && N(e.five.state.mode) ? e.find({ targetMode: "Panorama" }).then(() => e.unfoldAndFoldOthers()) : w.emit("click", { event: n, target: "TagPoint", tag: e }));
|
|
146
|
+
}, i = (() => e.contentType === "Text" && e.data.appearance === "plane" ? 500 : 800)();
|
|
147
147
|
function s(n) {
|
|
148
|
-
G.call(this,
|
|
148
|
+
G.call(this, t, n);
|
|
149
149
|
}
|
|
150
|
-
return
|
|
151
|
-
"tag" in n && r(6,
|
|
152
|
-
},
|
|
150
|
+
return t.$$set = (n) => {
|
|
151
|
+
"tag" in n && r(6, e = n.tag);
|
|
152
|
+
}, t.$$.update = () => {
|
|
153
153
|
var n, k, T, L;
|
|
154
|
-
|
|
155
|
-
64 && r(0, u = (n =
|
|
156
|
-
1 && r(3, d = !u),
|
|
157
|
-
64 && r(2, c = (T = (k =
|
|
154
|
+
t.$$.dirty & /*tag*/
|
|
155
|
+
64 && r(0, u = (n = e.state) == null ? void 0 : n.unfolded), t.$$.dirty & /*unfolded*/
|
|
156
|
+
1 && r(3, d = !u), t.$$.dirty & /*tag*/
|
|
157
|
+
64 && r(2, c = (T = (k = e.style) == null ? void 0 : k.point) != null && T.url ? (L = e.style) == null ? void 0 : L.point : { url: K }), t.$$.dirty & /*tag*/
|
|
158
158
|
64 && r(1, p = (() => {
|
|
159
|
-
var
|
|
160
|
-
const
|
|
161
|
-
if (typeof
|
|
162
|
-
return
|
|
163
|
-
const f = (
|
|
159
|
+
var M, $, C, F;
|
|
160
|
+
const P = ($ = (M = e.style) == null ? void 0 : M.point) == null ? void 0 : $.width;
|
|
161
|
+
if (typeof P == "number")
|
|
162
|
+
return P;
|
|
163
|
+
const f = (F = (C = e.style) == null ? void 0 : C.point) == null ? void 0 : F.size;
|
|
164
164
|
if (typeof f == "number")
|
|
165
165
|
return f;
|
|
166
166
|
if (f === "S")
|
|
@@ -179,7 +179,7 @@ function Y(e, o, r) {
|
|
|
179
179
|
d,
|
|
180
180
|
v,
|
|
181
181
|
i,
|
|
182
|
-
|
|
182
|
+
e,
|
|
183
183
|
s
|
|
184
184
|
];
|
|
185
185
|
}
|
|
@@ -16,7 +16,10 @@ export declare abstract class TagUtil extends BasePlugin.Controller<State, Plugi
|
|
|
16
16
|
get container(): Element;
|
|
17
17
|
set container(container: Element);
|
|
18
18
|
config: Pick<Tags, 'globalConfig' | 'contentTypeConfig'>;
|
|
19
|
-
renderQueue: Map<string,
|
|
19
|
+
renderQueue: Map<string, {
|
|
20
|
+
keys: string[];
|
|
21
|
+
tags: BaseTag[];
|
|
22
|
+
}>;
|
|
20
23
|
set tagsLengthWillUpdate(value: boolean);
|
|
21
24
|
/** 插件参数 */
|
|
22
25
|
protected params: {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var d = Object.defineProperty;
|
|
2
|
-
var c = (
|
|
3
|
-
var r = (
|
|
2
|
+
var c = (a, n, e) => n in a ? d(a, n, { enumerable: !0, configurable: !0, writable: !0, value: e }) : a[n] = e;
|
|
3
|
+
var r = (a, n, e) => (c(a, typeof n != "symbol" ? n + "" : n, e), e);
|
|
4
4
|
import { DefaultConfig as l } from "../tag.config.js";
|
|
5
5
|
import "three";
|
|
6
6
|
import { anyPositionToVector3 as p } from "../../shared-utils/positionToVector3.js";
|
|
@@ -134,8 +134,12 @@ class Se extends E {
|
|
|
134
134
|
return (e = this._cache_css3DTag) != null ? e : [];
|
|
135
135
|
}
|
|
136
136
|
addRenderQueue(e) {
|
|
137
|
-
|
|
138
|
-
|
|
137
|
+
var m, s;
|
|
138
|
+
const { type: t, keys: i = [], tags: o = [] } = e;
|
|
139
|
+
this.renderQueue.has(t) ? this.renderQueue.set(t, {
|
|
140
|
+
keys: Array.from(/* @__PURE__ */ new Set([...(m = this.renderQueue.get(t).keys) != null ? m : [], ...i])),
|
|
141
|
+
tags: Array.from(/* @__PURE__ */ new Set([...(s = this.renderQueue.get(t).tags) != null ? s : [], ...o]))
|
|
142
|
+
}) : this.renderQueue.set(t, { keys: i, tags: o });
|
|
139
143
|
}
|
|
140
144
|
getTagById(e) {
|
|
141
145
|
const t = this.tags.find((i) => i.id === e);
|
|
@@ -161,14 +165,14 @@ class Se extends E {
|
|
|
161
165
|
if (!t || !this.domEvents)
|
|
162
166
|
return () => {
|
|
163
167
|
};
|
|
164
|
-
const o = () => !(!e.currentVisible || e.loading),
|
|
168
|
+
const o = () => !(!e.currentVisible || e.loading), m = (s) => {
|
|
165
169
|
if (!o())
|
|
166
170
|
return !1;
|
|
167
|
-
i(
|
|
171
|
+
i(s.origDomEvent);
|
|
168
172
|
};
|
|
169
|
-
return this.domEvents.addEventListener(t, "click",
|
|
170
|
-
var
|
|
171
|
-
(
|
|
173
|
+
return this.domEvents.addEventListener(t, "click", m), () => {
|
|
174
|
+
var s;
|
|
175
|
+
(s = this.domEvents) == null || s.removeEventListener(t, "click", m);
|
|
172
176
|
};
|
|
173
177
|
}
|
|
174
178
|
/**
|
|
@@ -235,10 +235,8 @@ class ji extends R {
|
|
|
235
235
|
});
|
|
236
236
|
p(this, "handleFivePanoArrived", () => l(this, null, function* () {
|
|
237
237
|
this.tags.forEach((e) => {
|
|
238
|
-
e.state.visible = !1, e.applyVisible(), e.updateVisible();
|
|
239
|
-
}), this.temporaryState.visible = !0, this.addRenderQueue({ type: "TagContainerSvelte", keys: ["temporaryState"] }), yield this.setUnfolded(), this.updateRender3DDomTag(), this.tags.
|
|
240
|
-
e.temporaryState = c(f({}, e.temporaryState), { visible: !0 });
|
|
241
|
-
}), this.tags.filter(w).filter((e) => {
|
|
238
|
+
e.state.visible = !1, e.temporaryState = c(f({}, e.temporaryState), { visible: !0 }), e.applyVisible(), e.updateVisible();
|
|
239
|
+
}), this.temporaryState.visible = !0, this.addRenderQueue({ type: "TagContainerSvelte", keys: ["temporaryState"] }), yield this.setUnfolded(), this.updateRender3DDomTag(), this.tags.filter(w).filter((e) => {
|
|
242
240
|
var t;
|
|
243
241
|
return (t = e.getConfig().modelConfig) == null ? void 0 : t.autoLookAtEnabled;
|
|
244
242
|
}).forEach((e) => {
|
|
@@ -264,8 +262,8 @@ class ji extends R {
|
|
|
264
262
|
});
|
|
265
263
|
p(this, "render", () => {
|
|
266
264
|
this.renderQueue.forEach((e, t) => {
|
|
267
|
-
const
|
|
268
|
-
if (
|
|
265
|
+
const { keys: i } = e;
|
|
266
|
+
if (t === "TagContainerSvelte") {
|
|
269
267
|
const s = this.filterPointTag.filter((r) => r.screenPosition), n = {
|
|
270
268
|
hooks: this.hooks,
|
|
271
269
|
tags: s,
|
|
@@ -278,10 +276,10 @@ class ji extends R {
|
|
|
278
276
|
};
|
|
279
277
|
if (this.TagContainerSvelte) {
|
|
280
278
|
let r = {};
|
|
281
|
-
if (
|
|
279
|
+
if (i.length === 0)
|
|
282
280
|
r = n;
|
|
283
281
|
else
|
|
284
|
-
for (const h of
|
|
282
|
+
for (const h of i)
|
|
285
283
|
r[h] = n[h];
|
|
286
284
|
this.TagContainerSvelte.$set(r);
|
|
287
285
|
} else {
|
package/libs/base/BasePlugin.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
function A() {
|
|
2
2
|
console.debug(
|
|
3
|
-
"%c %c@realsee/dnalogel %cv3.44.
|
|
3
|
+
"%c %c@realsee/dnalogel %cv3.44.3",
|
|
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",
|
|
@@ -4,14 +4,14 @@ var t = (a, i, e) => (f(a, typeof i != "symbol" ? i + "" : i, e), e);
|
|
|
4
4
|
import * as m from "three";
|
|
5
5
|
import { Magnifier as p } from "../../Magnifier.js";
|
|
6
6
|
import { PointHelper as u } from "./PointHelper.js";
|
|
7
|
-
import { Subscribe as
|
|
8
|
-
import { PointHelper2 as
|
|
7
|
+
import { Subscribe as b } from "../../../Subscribe.js";
|
|
8
|
+
import { PointHelper2 as g } from "./PointHelper2.js";
|
|
9
9
|
import "../../THREESphere.js";
|
|
10
10
|
import "animejs";
|
|
11
11
|
class M {
|
|
12
12
|
constructor(i, e) {
|
|
13
13
|
t(this, "five");
|
|
14
|
-
t(this, "hooks", new
|
|
14
|
+
t(this, "hooks", new b());
|
|
15
15
|
t(this, "position");
|
|
16
16
|
t(this, "magnifier", null);
|
|
17
17
|
t(this, "pointHelper", null);
|
|
@@ -39,9 +39,9 @@ class M {
|
|
|
39
39
|
t(this, "abortUpdateMagnifier", () => {
|
|
40
40
|
});
|
|
41
41
|
var s, n, h, l;
|
|
42
|
-
|
|
42
|
+
this.five = i, this.magnifier = (e == null ? void 0 : e.magnifier) !== void 0 ? e.magnifier : new p(i, (s = e == null ? void 0 : e.magnifierParams) != null ? s : { dragEnabled: !0 });
|
|
43
43
|
let r;
|
|
44
|
-
(e == null ? void 0 : e.pointHelper) === "default" || (e == null ? void 0 : e.pointHelper) === void 0 ? r = new u(i) : (e == null ? void 0 : e.pointHelper) === "highlight" ? r = new
|
|
44
|
+
(e == null ? void 0 : e.pointHelper) === "default" || (e == null ? void 0 : e.pointHelper) === void 0 ? r = new u(i) : (e == null ? void 0 : e.pointHelper) === "highlight" ? r = new g(i) : r = e.pointHelper, this.pointHelper = r, this.group.name = "five-point-selector", this.five.scene.add(this.group), (l = this.magnifier) == null || l.appendTo((h = (n = e.container) != null ? n : i.getElement().parentElement) != null ? h : document.body);
|
|
45
45
|
}
|
|
46
46
|
enable() {
|
|
47
47
|
var i;
|