@realsee/dnalogel 3.49.10 → 3.49.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.
- package/CHANGELOG.md +6 -0
- package/dist/Sculpt/Meshes/Line.d.ts +5 -7
- package/dist/Sculpt/Meshes/Point.d.ts +9 -2
- package/dist/Sculpt/Objects/Base/index.d.ts +1 -0
- package/dist/Sculpt/typings/style.d.ts +6 -0
- package/dist/index.cjs.js +58 -57
- package/dist/index.js +2682 -2642
- package/dist/index.umd.js +52 -51
- package/libs/Sculpt/Meshes/Line.d.ts +5 -7
- package/libs/Sculpt/Meshes/Line.js +75 -67
- package/libs/Sculpt/Meshes/LineWithDots.js +5 -5
- package/libs/Sculpt/Meshes/Point.d.ts +9 -2
- package/libs/Sculpt/Meshes/Point.js +77 -44
- package/libs/Sculpt/Objects/Base/index.d.ts +1 -0
- package/libs/Sculpt/Objects/Base/index.js +5 -2
- package/libs/Sculpt/Objects/Point/index.js +46 -43
- package/libs/Sculpt/index.js +1 -1
- package/libs/Sculpt/typings/style.d.ts +6 -0
- package/libs/Sculpt/utils/Meshes/getLengthHTML.js +1 -0
- package/libs/Sculpt/utils/removeAllTag.js +8 -5
- package/libs/base/BasePlugin.js +1 -1
- package/libs/shared-utils/logger.js +1 -1
- package/package.json +1 -1
|
@@ -1,46 +1,46 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
1
|
+
var g = Object.defineProperty, u = Object.defineProperties;
|
|
2
|
+
var y = Object.getOwnPropertyDescriptors;
|
|
3
3
|
var d = Object.getOwnPropertySymbols;
|
|
4
|
-
var
|
|
5
|
-
var
|
|
4
|
+
var P = Object.prototype.hasOwnProperty, w = Object.prototype.propertyIsEnumerable;
|
|
5
|
+
var p = (e, i, t) => i in e ? g(e, i, { enumerable: !0, configurable: !0, writable: !0, value: t }) : e[i] = t, a = (e, i) => {
|
|
6
6
|
for (var t in i || (i = {}))
|
|
7
|
-
|
|
7
|
+
P.call(i, t) && p(e, t, i[t]);
|
|
8
8
|
if (d)
|
|
9
9
|
for (var t of d(i))
|
|
10
|
-
|
|
10
|
+
w.call(i, t) && p(e, t, i[t]);
|
|
11
11
|
return e;
|
|
12
|
-
},
|
|
13
|
-
var
|
|
14
|
-
var
|
|
12
|
+
}, m = (e, i) => u(e, y(i));
|
|
13
|
+
var c = (e, i, t) => (p(e, typeof i != "symbol" ? i + "" : i, t), t);
|
|
14
|
+
var b = (e, i, t) => new Promise((h, n) => {
|
|
15
15
|
var r = (s) => {
|
|
16
16
|
try {
|
|
17
|
-
|
|
18
|
-
} catch (
|
|
19
|
-
|
|
17
|
+
o(t.next(s));
|
|
18
|
+
} catch (l) {
|
|
19
|
+
n(l);
|
|
20
20
|
}
|
|
21
|
-
},
|
|
21
|
+
}, f = (s) => {
|
|
22
22
|
try {
|
|
23
|
-
|
|
24
|
-
} catch (
|
|
25
|
-
|
|
23
|
+
o(t.throw(s));
|
|
24
|
+
} catch (l) {
|
|
25
|
+
n(l);
|
|
26
26
|
}
|
|
27
|
-
},
|
|
28
|
-
|
|
27
|
+
}, o = (s) => s.done ? h(s.value) : Promise.resolve(s.value).then(r, f);
|
|
28
|
+
o((t = t.apply(e, i)).next());
|
|
29
29
|
});
|
|
30
|
-
import { PointMesh as
|
|
31
|
-
import { BaseObject as
|
|
32
|
-
import { PointEditor as
|
|
33
|
-
import { vector3ToArray as
|
|
34
|
-
class
|
|
35
|
-
constructor(t,
|
|
36
|
-
super(t,
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
this.editor = new
|
|
30
|
+
import { PointMesh as M } from "../../Meshes/Point.js";
|
|
31
|
+
import { BaseObject as v } from "../Base/index.js";
|
|
32
|
+
import { PointEditor as x } from "./Editor.js";
|
|
33
|
+
import { vector3ToArray as E } from "../../../shared-utils/three/vector3ToArray.js";
|
|
34
|
+
class C extends v {
|
|
35
|
+
constructor(t, h) {
|
|
36
|
+
super(t, h);
|
|
37
|
+
c(this, "type", "Point");
|
|
38
|
+
c(this, "pointMesh");
|
|
39
|
+
this.editor = new x(this), t && (this.pointMesh = new M(a(a({}, t.style), t)), this.add(this.pointMesh));
|
|
40
40
|
}
|
|
41
41
|
get data() {
|
|
42
|
-
return
|
|
43
|
-
point:
|
|
42
|
+
return m(a({}, this.baseData), {
|
|
43
|
+
point: E(this.applyObjectMatrixWorld(this.pointMesh.position)),
|
|
44
44
|
style: {
|
|
45
45
|
color: this.pointMesh.color.getHex(),
|
|
46
46
|
size: this.pointMesh.size
|
|
@@ -67,24 +67,27 @@ class D extends x {
|
|
|
67
67
|
* @description: 创建点
|
|
68
68
|
*/
|
|
69
69
|
create(t) {
|
|
70
|
-
return
|
|
71
|
-
this.pointMesh && this.remove(this.pointMesh), this.add(this.pointMesh = new
|
|
70
|
+
return b(this, null, function* () {
|
|
71
|
+
this.pointMesh && this.remove(this.pointMesh), this.add(this.pointMesh = new M(t)), yield U(this.pointMesh, this.pointSelector), this.editor.enable();
|
|
72
72
|
});
|
|
73
73
|
}
|
|
74
74
|
}
|
|
75
|
-
function
|
|
76
|
-
return new Promise((t,
|
|
77
|
-
i.enable();
|
|
78
|
-
const
|
|
79
|
-
|
|
80
|
-
|
|
75
|
+
function U(e, i) {
|
|
76
|
+
return new Promise((t, h) => {
|
|
77
|
+
i.enable(), e.visible = !1;
|
|
78
|
+
const n = (s) => {
|
|
79
|
+
s && (e.visible = !0, e.position.copy(s.point));
|
|
80
|
+
}, r = (s) => {
|
|
81
|
+
s && (e.position.copy(s.point), f());
|
|
82
|
+
}, f = () => {
|
|
83
|
+
i.off("select", r), i.off("disable", o), i.off("intersectionUpdate", n), i.disable(), t();
|
|
84
|
+
}, o = () => {
|
|
85
|
+
i.off("select", r), i.off("disable", o), i.off("intersectionUpdate", n), e.removeFromParent(), h(new Error("Cancelled"));
|
|
81
86
|
};
|
|
82
|
-
i.on("disable",
|
|
83
|
-
i.off("select", h), o(new Error("Cancelled"));
|
|
84
|
-
}), i.once("select", h);
|
|
87
|
+
i.on("intersectionUpdate", n), i.on("disable", o), i.once("select", r);
|
|
85
88
|
});
|
|
86
89
|
}
|
|
87
90
|
export {
|
|
88
|
-
|
|
89
|
-
|
|
91
|
+
C as Point,
|
|
92
|
+
U as createPoint
|
|
90
93
|
};
|
package/libs/Sculpt/index.js
CHANGED
|
@@ -76,7 +76,7 @@ const h = class extends S {
|
|
|
76
76
|
this.five = e, this.theme = t, this.group = new k(), this.group.name = "Sculpt", e.scene.add(this.group), h.modules.init(e), B("ctrl+z", this.undo), B("ctrl+shift+z", this.redo), h.modules.fiveDomEvents.addEventListener(this.group, "click", ({ intersects: n, origDomEvent: l }) => {
|
|
77
77
|
var s;
|
|
78
78
|
const o = M((s = n == null ? void 0 : n[0]) == null ? void 0 : s.object, (c) => c.isSculptObject);
|
|
79
|
-
return o ? this.emit("click", l, o) : !1;
|
|
79
|
+
return o && !o.editing ? this.emit("click", l, o) : !1;
|
|
80
80
|
}), window.__SCULPT_DEBUG__ = this, window.__SCULPT_MODULES_DEBUG__ = h.modules;
|
|
81
81
|
}
|
|
82
82
|
get data() {
|
|
@@ -57,4 +57,10 @@ export type OcclusionStyle = {
|
|
|
57
57
|
*/
|
|
58
58
|
occlusionMode: 'translucence' | 'depthTest';
|
|
59
59
|
};
|
|
60
|
+
export type lengthConfig = {
|
|
61
|
+
lengthEnable: boolean;
|
|
62
|
+
};
|
|
63
|
+
export type DisplayInfoConfig = {
|
|
64
|
+
tip: string;
|
|
65
|
+
};
|
|
60
66
|
export type LineStyle = LineColorStyle & LineWidthStyle & OpacityStyle;
|
|
@@ -1,9 +1,12 @@
|
|
|
1
|
-
import { LightTag as
|
|
2
|
-
function s(
|
|
3
|
-
|
|
1
|
+
import { LightTag as a } from "../../shared-utils/tag.js";
|
|
2
|
+
function s(o) {
|
|
3
|
+
n(o), o.traverse((r) => n(r));
|
|
4
4
|
}
|
|
5
|
-
function
|
|
6
|
-
|
|
5
|
+
function n(o) {
|
|
6
|
+
const r = o;
|
|
7
|
+
Array.isArray(r.doms) && r.doms[0] instanceof a && r.doms.forEach((t) => t.destroy());
|
|
8
|
+
const e = o;
|
|
9
|
+
e.dom && e.dom instanceof a && e.dom.destroy(), o.areaDom instanceof a && o.areaDom.destroy();
|
|
7
10
|
}
|
|
8
11
|
export {
|
|
9
12
|
s as removeAllTag
|
package/libs/base/BasePlugin.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
function A() {
|
|
2
2
|
console.debug(
|
|
3
|
-
"%c %c@realsee/dnalogel %cv3.49.
|
|
3
|
+
"%c %c@realsee/dnalogel %cv3.49.12",
|
|
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",
|