@realsee/dnalogel 3.47.9 → 3.47.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.
Files changed (104) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/dist/Sculpt/Meshes/Line.d.ts +1 -0
  3. package/dist/Sculpt/Meshes/Polyline.d.ts +1 -0
  4. package/dist/Sculpt/Meshes/RectangleWithEdge.d.ts +1 -0
  5. package/dist/index.cjs.js +57 -57
  6. package/dist/index.js +3236 -3222
  7. package/dist/index.umd.js +50 -50
  8. package/libs/AreaMakerPlugin/Controller.js +14 -13
  9. package/libs/AreaMakerPlugin/index.js +15 -14
  10. package/libs/AreaMakerPlugin/utils/Item.js +15 -14
  11. package/libs/CSS3DRenderPlugin/Controller.js +12 -11
  12. package/libs/CSS3DRenderPlugin/index.js +18 -17
  13. package/libs/CSS3DRenderPlugin/utils/three/CSS3DObject.js +12 -11
  14. package/libs/CSS3DRenderPlugin/utils/three/CSS3DRender.js +26 -25
  15. package/libs/CruisePlugin/BaseController.js +17 -16
  16. package/libs/CruisePlugin/Move.js +20 -19
  17. package/libs/CruisePlugin/Work.js +15 -14
  18. package/libs/CruisePlugin/index.js +19 -18
  19. package/libs/CurrentPanoImagePlugin/Controller.js +14 -13
  20. package/libs/CurrentPanoImagePlugin/index.js +16 -15
  21. package/libs/GuideLinePlugin/Controller.js +17 -16
  22. package/libs/GuideLinePlugin/GuideLineItem.js +15 -14
  23. package/libs/GuideLinePlugin/GuideLineModeItem/index.js +5 -3
  24. package/libs/GuideLinePlugin/GuideLineModeItem.js +15 -14
  25. package/libs/GuideLinePlugin/index.js +19 -18
  26. package/libs/ModelMakerPlugin/Controller.js +13 -12
  27. package/libs/ModelMakerPlugin/index.js +15 -14
  28. package/libs/ModelTVVideoPlugin/Plugin.js +37 -36
  29. package/libs/ModelTVVideoPlugin/index.js +13 -12
  30. package/libs/Object3DHelperPlugin/Controller.js +14 -13
  31. package/libs/Object3DHelperPlugin/index.js +18 -17
  32. package/libs/PanoCompassPlugin/Controller.js +15 -14
  33. package/libs/PanoCompassPlugin/index.js +16 -15
  34. package/libs/PanoDoorLabelPlugin/BaseController.js +15 -14
  35. package/libs/PanoDoorLabelPlugin/Controller.js +15 -14
  36. package/libs/PanoDoorLabelPlugin/index.js +16 -15
  37. package/libs/PanoMeasurePlugin/Components/Controller0.js +12 -11
  38. package/libs/PanoMeasurePlugin/Components/Controller1.js +12 -11
  39. package/libs/PanoMeasurePlugin/Controller/EditController.js +12 -11
  40. package/libs/PanoMeasurePlugin/Controller/WatchController.js +13 -12
  41. package/libs/PanoMeasurePlugin/Controller/index.js +10 -9
  42. package/libs/PanoMeasurePlugin/Model/area.js +12 -11
  43. package/libs/PanoMeasurePlugin/Modules/Magnifier.js +12 -11
  44. package/libs/PanoMeasurePlugin/Modules/UIController/index.js +12 -11
  45. package/libs/PanoMeasurePlugin/index.js +21 -20
  46. package/libs/PanoMeasurePlugin/utils/dom/areaDom.js +12 -11
  47. package/libs/PanoSpatialTagPlugin/Plugin.js +14 -13
  48. package/libs/PanoSpatialTagPlugin/index.js +11 -10
  49. package/libs/PanoTagPlugin/Components/Common/TagPoint.js +14 -13
  50. package/libs/PanoTagPlugin/Components/Tag/MarketingTag.js +13 -12
  51. package/libs/PanoTagPlugin/Components/Tag/index.js +13 -12
  52. package/libs/PanoTagPlugin/Components/TagContainer.js +13 -12
  53. package/libs/PanoTagPlugin/Components/TagItem.js +13 -12
  54. package/libs/PanoTagPlugin/controller/Tag/BaseTag.js +34 -33
  55. package/libs/PanoTagPlugin/controller/Tag/ModelTag.js +13 -12
  56. package/libs/PanoTagPlugin/controller/Tag/PlaneTag.js +13 -12
  57. package/libs/PanoTagPlugin/controller/Tag/PointTag.js +15 -14
  58. package/libs/PanoTagPlugin/controller/TagRender.js +12 -11
  59. package/libs/PanoTagPlugin/controller/TagUtil.js +13 -12
  60. package/libs/PanoTagPlugin/controller/index.js +22 -16
  61. package/libs/PanoTagPlugin/index.js +21 -20
  62. package/libs/PanoTagPlugin/utils/tag/calculateTagConfig.js +14 -13
  63. package/libs/PanoVideoPlugin/Controller.js +15 -14
  64. package/libs/PanoVideoPlugin/VideoMeshController.js +30 -29
  65. package/libs/PanoVideoPlugin/index.js +18 -17
  66. package/libs/PipelinePlugin/Controller.js +14 -13
  67. package/libs/PipelinePlugin/index.js +16 -15
  68. package/libs/PipelinePlugin/utils/Objects/FlowPipe.js +21 -20
  69. package/libs/PipelinePlugin/utils/Objects/HighlightPipe.js +15 -14
  70. package/libs/PipelinePlugin/utils/Objects/Pipe.js +13 -12
  71. package/libs/Sculpt/Meshes/Box.js +11 -9
  72. package/libs/Sculpt/Meshes/Cylinder.js +17 -15
  73. package/libs/Sculpt/Meshes/Line.d.ts +1 -0
  74. package/libs/Sculpt/Meshes/Line.js +84 -78
  75. package/libs/Sculpt/Meshes/Point.js +14 -12
  76. package/libs/Sculpt/Meshes/Polyline.d.ts +1 -0
  77. package/libs/Sculpt/Meshes/Polyline.js +69 -74
  78. package/libs/Sculpt/Meshes/Rectangle.js +6 -4
  79. package/libs/Sculpt/Meshes/RectangleWithEdge.d.ts +1 -0
  80. package/libs/Sculpt/Objects/Base/index.js +5 -5
  81. package/libs/Sculpt/Objects/Line/Editor.js +17 -15
  82. package/libs/Sculpt/Objects/Polygon/index.js +22 -22
  83. package/libs/Sculpt/Objects/Rectangle/Editor.js +2 -2
  84. package/libs/Sculpt/Objects/Rectangle/index.js +79 -69
  85. package/libs/Sculpt/index.js +15 -14
  86. package/libs/Sculpt/utils/three/ColoredMesh.js +6 -4
  87. package/libs/base/BasePlugin.js +16 -14
  88. package/libs/floorplan/MapviewFloorplanPlugin/Controller.js +13 -12
  89. package/libs/floorplan/MapviewFloorplanPlugin/index.js +16 -15
  90. package/libs/floorplan/ModelFloorplanPlugin/Controller.js +13 -12
  91. package/libs/floorplan/ModelFloorplanPlugin/index.js +16 -15
  92. package/libs/floorplan/PanoFloorplanRadarPlugin/Controller.js +15 -14
  93. package/libs/floorplan/PanoFloorplanRadarPlugin/index.js +16 -15
  94. package/libs/floorplan/TopviewFloorplanPlugin/Controller.js +13 -12
  95. package/libs/floorplan/TopviewFloorplanPlugin/index.js +16 -15
  96. package/libs/floorplan/index.js +3 -1
  97. package/libs/index.js +12 -12
  98. package/libs/shared-utils/five/index.js +5 -3
  99. package/libs/shared-utils/five/lookObject.js +20 -18
  100. package/libs/shared-utils/logger.js +1 -1
  101. package/libs/shared-utils/tag.js +4 -1
  102. package/libs/shared-utils/three/applyObjectMatrixWorld.js +4 -6
  103. package/libs/shared-utils/three/index.js +3 -1
  104. package/package.json +1 -1
@@ -1,27 +1,29 @@
1
1
  var g = Object.defineProperty;
2
2
  var d = (s, e, t) => e in s ? g(s, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : s[e] = t;
3
- var n = (s, e, t) => (d(s, typeof e != "symbol" ? e + "" : e, t), t);
3
+ var o = (s, e, t) => (d(s, typeof e != "symbol" ? e + "" : e, t), t);
4
4
  import { BaseEditor as p } from "../Base/Editor.js";
5
- import { Sculpt as o } from "../../index.js";
5
+ import { Sculpt as n } from "../../index.js";
6
6
  import { PointMesh as a } from "../../Meshes/Point.js";
7
7
  import { getIntersectByRaycaster as h } from "../../../shared-utils/five/getPosition.js";
8
8
  import "three";
9
9
  import "hammerjs";
10
10
  import "three/examples/jsm/renderers/CSS3DRenderer";
11
- import "../../Meshes/Line.js";
11
+ import "@realsee/five/line";
12
+ import "../../../shared-utils/tag.js";
13
+ import "../../utils/Modules/Global.js";
12
14
  import "../../../shared-utils/three/THREESphere.js";
13
15
  import "animejs";
14
- import { notNil as l } from "../../../shared-utils/isNil.js";
16
+ import { notNil as m } from "../../../shared-utils/isNil.js";
15
17
  import "../../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
16
- class m extends p {
18
+ class l extends p {
17
19
  constructor(t) {
18
20
  super(t);
19
- n(this, "draggingPoints", []);
20
- n(this, "onDragstart", (t) => {
21
+ o(this, "draggingPoints", []);
22
+ o(this, "onDragstart", (t) => {
21
23
  const i = t.target;
22
24
  this.draggingPoints = this.pointMeshes.filter((r) => r.position.equals(i.position));
23
25
  });
24
- n(this, "onDragend", (t) => {
26
+ o(this, "onDragend", (t) => {
25
27
  this.draggingPoints = [];
26
28
  });
27
29
  }
@@ -32,22 +34,22 @@ class m extends p {
32
34
  return this.children;
33
35
  }
34
36
  enable() {
35
- super.enable(), this.points.filter(l).forEach((t) => {
37
+ super.enable(), this.points.filter(m).forEach((t) => {
36
38
  const i = new a();
37
- i.visible = !1, i.position.copy(t), i.draggable = !0, o.modules.fiveDomEvents.addEventListener(i, "drag", this.onDrag), o.modules.fiveDomEvents.addEventListener(i, "dragstart", this.onDragstart), o.modules.fiveDomEvents.addEventListener(i, "dragend", this.onDragend), this.add(i);
39
+ i.visible = !1, i.position.copy(t), i.draggable = !0, n.modules.fiveDomEvents.addEventListener(i, "drag", this.onDrag), n.modules.fiveDomEvents.addEventListener(i, "dragstart", this.onDragstart), n.modules.fiveDomEvents.addEventListener(i, "dragend", this.onDragend), this.add(i);
38
40
  });
39
41
  }
40
42
  disable() {
41
43
  super.disable(), this.removeChildren();
42
44
  }
43
45
  }
44
- class B extends m {
46
+ class q extends l {
45
47
  constructor(t) {
46
48
  super(t);
47
- n(this, "onDrag", (t) => {
49
+ o(this, "onDrag", (t) => {
48
50
  if (!this.draggingPoints || this.draggingPoints.length === 0)
49
51
  return;
50
- const i = h(o.modules.five, t.raycaster);
52
+ const i = h(n.modules.five, t.raycaster);
51
53
  this.draggingPoints.forEach((r) => r.position.copy(i.point)), this.originObject.lineMesh.setPoints(this.pointMeshes.map((r) => r.position));
52
54
  });
53
55
  }
@@ -56,6 +58,6 @@ class B extends m {
56
58
  }
57
59
  }
58
60
  export {
59
- B as LineEditor,
60
- m as LineEditorAbstract
61
+ q as LineEditor,
62
+ l as LineEditorAbstract
61
63
  };
@@ -1,17 +1,17 @@
1
1
  var F = Object.defineProperty, L = Object.defineProperties;
2
2
  var N = Object.getOwnPropertyDescriptors;
3
- var T = Object.getOwnPropertySymbols;
3
+ var j = Object.getOwnPropertySymbols;
4
4
  var O = Object.prototype.hasOwnProperty, U = Object.prototype.propertyIsEnumerable;
5
- var u = (s, e, t) => e in s ? F(s, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : s[e] = t, c = (s, e) => {
5
+ var w = (s, e, t) => e in s ? F(s, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : s[e] = t, c = (s, e) => {
6
6
  for (var t in e || (e = {}))
7
- O.call(e, t) && u(s, t, e[t]);
8
- if (T)
9
- for (var t of T(e))
10
- U.call(e, t) && u(s, t, e[t]);
7
+ O.call(e, t) && w(s, t, e[t]);
8
+ if (j)
9
+ for (var t of j(e))
10
+ U.call(e, t) && w(s, t, e[t]);
11
11
  return s;
12
12
  }, y = (s, e) => L(s, N(e));
13
- var v = (s, e, t) => (u(s, typeof e != "symbol" ? e + "" : e, t), t);
14
- var W = (s, e, t) => new Promise((f, d) => {
13
+ var M = (s, e, t) => (w(s, typeof e != "symbol" ? e + "" : e, t), t);
14
+ var T = (s, e, t) => new Promise((f, d) => {
15
15
  var n = (l) => {
16
16
  try {
17
17
  a(t.next(l));
@@ -38,14 +38,14 @@ const D = new m.Vector3();
38
38
  class X extends z {
39
39
  constructor(t, f) {
40
40
  super(t, f);
41
- v(this, "type", "Polygon");
42
- v(this, "areaMesh");
41
+ M(this, "type", "Polygon");
42
+ M(this, "areaMesh");
43
43
  this.editor = new B(this), t && (this.areaMesh = new V(c(c({}, t.style), t)), this.add(this.areaMesh)), k("esc", () => {
44
44
  this.stopCreating();
45
45
  });
46
46
  }
47
47
  get data() {
48
- return y(c({}, this.baseData), {
48
+ return this.updateMatrixWorld(), y(c({}, this.baseData), {
49
49
  points: H(this.applyObjectMatrixWorld(this.areaMesh.points)),
50
50
  style: {
51
51
  color: this.areaMesh.color.getHex(),
@@ -63,7 +63,7 @@ class X extends z {
63
63
  (t = this.areaMesh) == null || t.unhighlight();
64
64
  }
65
65
  create(t) {
66
- return W(this, null, function* () {
66
+ return T(this, null, function* () {
67
67
  this.children.forEach((d) => {
68
68
  d.parent === this && this.remove(d);
69
69
  }), this.children.length = 0;
@@ -74,37 +74,37 @@ class X extends z {
74
74
  }
75
75
  function I(s, e, t) {
76
76
  return new Promise((f, d) => {
77
- var x;
77
+ var C;
78
78
  const n = s.parent;
79
79
  if (!n) {
80
80
  d(new Error("No container"));
81
81
  return;
82
82
  }
83
- const P = (x = t == null ? void 0 : t.limit) != null ? x : "none", a = new A(s.style);
83
+ const P = (C = t == null ? void 0 : t.limit) != null ? C : "none", a = new A(s.style);
84
84
  n == null || n.add(a);
85
85
  const l = new A(y(c({}, s.style), { dashed: !0, lengthEnable: !1 }));
86
86
  n == null || n.add(l), e.enable();
87
87
  const o = [];
88
- let i, r, w = !1;
89
- const M = (h) => {
88
+ let i, r, u = !1;
89
+ const v = (h) => {
90
90
  const p = o.length === 0 ? h.point : i.clone();
91
- o.push(p), s.setPoints(o, { closed: !1 }), w && (E(), f());
91
+ o.push(p), s.setPoints(o, { closed: !1 }), u && (E(), f());
92
92
  }, b = (h) => {
93
93
  if (!(o != null && o.length) || !h)
94
94
  return;
95
95
  const p = o.at(-1).clone();
96
96
  if (o.length < 3 && (P === "none" ? (i = h.point, a.setPoints([p, i])) : P === "xoz" ? (r = r != null ? r : new m.Plane().setFromNormalAndCoplanarPoint(new m.Vector3(0, 1, 0), o[0]), e.plane = r, i = r.projectPoint(h.point, D), a.setPoints([p, i]), l.setPoints([i, h.point])) : P === "y" && (o.length === 1 ? (i = h.point, a.setPoints([p, i])) : (r = r != null ? r : new m.Plane().setFromCoplanarPoints(o[0], o[1], new m.Vector3(0, 1, 0).add(o[0])), e.plane = r, i = r.projectPoint(h.point, D), a.setPoints([p, i]), l.setPoints([i, h.point])))), o.length >= 3) {
97
97
  i = s.projectPoint(h.point);
98
- const g = o[0], j = 0.2;
99
- g.distanceTo(i) < j || g.distanceTo(h.point) < j ? (i = g, h.point.copy(g), e.pointSelectorHelper.updateWithIntersect(h, { emitEvent: !1 }), w = !0) : w = !1, a.setPoints([p, i]), l.setPoints([i, h.point]);
98
+ const g = o[0], W = 0.2;
99
+ g.distanceTo(i) < W || g.distanceTo(h.point) < W ? (i = g, h.point.copy(g), e.pointSelectorHelper.updateWithIntersect(h, { emitEvent: !1 }), u = !0) : u = !1, a.setPoints([p, i]), l.setPoints([i, h.point]);
100
100
  }
101
101
  o.length >= 2 && s.setPoints([...o, i], { closed: !1 });
102
102
  }, E = () => {
103
- e.off("select", M), e.off("intersectionUpdate", b), e.off("disable", C), e.plane = null, e.disable(), n == null || n.remove(a, l);
104
- }, C = () => {
103
+ e.off("select", v), e.off("intersectionUpdate", b), e.off("disable", x), e.plane = null, e.disable(), n == null || n.remove(a, l);
104
+ }, x = () => {
105
105
  E(), n == null || n.remove(s, l, a), d(new Error("Cancelled"));
106
106
  };
107
- e.on("select", M), e.on("intersectionUpdate", b), e.on("disable", C);
107
+ e.on("select", v), e.on("intersectionUpdate", b), e.on("disable", x);
108
108
  });
109
109
  }
110
110
  export {
@@ -1,5 +1,5 @@
1
- import { BaseEditorWithObjectHelper as t } from "../Base/Editor.js";
2
- class o extends t {
1
+ import { BaseEditorWithObjectHelper as r } from "../Base/Editor.js";
2
+ class o extends r {
3
3
  constructor(e) {
4
4
  super(e, () => ({ yAxis: e.rectangleMesh.up }));
5
5
  }
@@ -1,45 +1,45 @@
1
- var O = Object.defineProperty, U = Object.defineProperties;
2
- var k = Object.getOwnPropertyDescriptors;
3
- var H = Object.getOwnPropertySymbols;
4
- var B = Object.prototype.hasOwnProperty, I = Object.prototype.propertyIsEnumerable;
5
- var b = (s, t, e) => t in s ? O(s, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[t] = e, d = (s, t) => {
1
+ var U = Object.defineProperty, k = Object.defineProperties;
2
+ var B = Object.getOwnPropertyDescriptors;
3
+ var A = Object.getOwnPropertySymbols;
4
+ var I = Object.prototype.hasOwnProperty, _ = Object.prototype.propertyIsEnumerable;
5
+ var E = (s, t, e) => t in s ? U(s, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[t] = e, d = (s, t) => {
6
6
  for (var e in t || (t = {}))
7
- B.call(t, e) && b(s, e, t[e]);
8
- if (H)
9
- for (var e of H(t))
10
- I.call(t, e) && b(s, e, t[e]);
7
+ I.call(t, e) && E(s, e, t[e]);
8
+ if (A)
9
+ for (var e of A(t))
10
+ _.call(t, e) && E(s, e, t[e]);
11
11
  return s;
12
- }, u = (s, t) => U(s, k(t));
13
- var M = (s, t, e) => (b(s, typeof t != "symbol" ? t + "" : t, e), e);
14
- var L = (s, t, e) => new Promise((h, f) => {
15
- var r = (o) => {
12
+ }, u = (s, t) => k(s, B(t));
13
+ var L = (s, t, e) => (E(s, typeof t != "symbol" ? t + "" : t, e), e);
14
+ var D = (s, t, e) => new Promise((c, w) => {
15
+ var a = (o) => {
16
16
  try {
17
- m(e.next(o));
18
- } catch (c) {
19
- f(c);
17
+ g(e.next(o));
18
+ } catch (h) {
19
+ w(h);
20
20
  }
21
- }, w = (o) => {
21
+ }, m = (o) => {
22
22
  try {
23
- m(e.throw(o));
24
- } catch (c) {
25
- f(c);
23
+ g(e.throw(o));
24
+ } catch (h) {
25
+ w(h);
26
26
  }
27
- }, m = (o) => o.done ? h(o.value) : Promise.resolve(o.value).then(r, w);
28
- m((e = e.apply(s, t)).next());
27
+ }, g = (o) => o.done ? c(o.value) : Promise.resolve(o.value).then(a, m);
28
+ g((e = e.apply(s, t)).next());
29
29
  });
30
- import { hotkeys as _ } from "../../../vendor/hotkeys-js/dist/hotkeys.esm.js";
31
- import { BaseObject as j } from "../Base/index.js";
32
- import * as l from "three";
33
- import { PolylineWithDotsMesh as E } from "../../Meshes/Polyline.js";
34
- import { RectangleEditor as q } from "./Editor.js";
35
- import { RectangleWithEdgeMesh as T } from "../../Meshes/RectangleWithEdge.js";
36
- const G = new l.Vector3();
37
- class S extends j {
38
- constructor(e, h) {
39
- super(e, h);
40
- M(this, "type", "Rectangle");
41
- M(this, "rectangleMesh");
42
- this.config.canEdit && (this.editor = new q(this)), e && (this.rectangleMesh = new T(d(d({}, e.style), e)), this.add(this.rectangleMesh)), _("esc", () => {
30
+ import { hotkeys as j } from "../../../vendor/hotkeys-js/dist/hotkeys.esm.js";
31
+ import { BaseObject as q } from "../Base/index.js";
32
+ import * as r from "three";
33
+ import { PolylineWithDotsMesh as M } from "../../Meshes/Polyline.js";
34
+ import { RectangleEditor as G } from "./Editor.js";
35
+ import { RectangleWithEdgeMesh as H } from "../../Meshes/RectangleWithEdge.js";
36
+ const P = new r.Vector3();
37
+ class S extends q {
38
+ constructor(e, c) {
39
+ super(e, c);
40
+ L(this, "type", "Rectangle");
41
+ L(this, "rectangleMesh");
42
+ this.config.canEdit && (this.editor = new G(this)), e && (this.rectangleMesh = new H(d(d({}, e.style), e)), this.add(this.rectangleMesh)), j("esc", () => {
43
43
  this.stopCreating();
44
44
  });
45
45
  }
@@ -62,51 +62,61 @@ class S extends j {
62
62
  (e = this.rectangleMesh) == null || e.unhighlight();
63
63
  }
64
64
  create(e) {
65
- return L(this, null, function* () {
65
+ return D(this, null, function* () {
66
66
  this.removeChildren();
67
- const h = new T(e);
68
- this.rectangleMesh = h, this.add(this.rectangleMesh), yield J(this.rectangleMesh, this.pointSelector), this.editor.enable();
67
+ const c = new H(e);
68
+ this.rectangleMesh = c, this.add(this.rectangleMesh), yield J(this.rectangleMesh, this.pointSelector, e);
69
69
  });
70
70
  }
71
71
  }
72
72
  function J(s, t, e) {
73
- return new Promise((h, f) => {
74
- var W, z;
75
- const r = s.parent;
76
- if (!r)
77
- return f(new Error("No container"));
78
- const w = (W = e == null ? void 0 : e.limit) != null ? W : "none", m = (z = e == null ? void 0 : e.drawMethod) != null ? z : "diagonal", o = new E(u(d({}, s.style), { dashed: !0, lengthEnable: !1 })), c = new E(u(d({}, s.style), { dashed: !0, lengthEnable: !1 })), y = new E(u(d({}, s.style), { dashed: !1, lengthEnable: !1 }));
79
- r.add(o, y, c), t.enable();
73
+ return new Promise((c, w) => {
74
+ var N, T;
75
+ const a = s.parent;
76
+ if (!a)
77
+ return w(new Error("No container"));
78
+ const m = (N = e == null ? void 0 : e.limit) != null ? N : "none", g = (T = e == null ? void 0 : e.drawMethod) != null ? T : "diagonal", o = new M(u(d({}, s.style), { dashed: !0, lengthEnable: !1 })), h = new M(u(d({}, s.style), { dashed: !0, lengthEnable: !1 })), y = new M(u(d({}, s.style), { dashed: !1, lengthEnable: !1 }));
79
+ a.add(o, y, h), t.enable();
80
80
  const n = [];
81
- let a = new l.Vector3(), v = new l.Vector3();
82
- const g = new l.Plane(), C = () => {
83
- n.push(a.clone()), n.length === 1 ? (w === "xoz" && g.setFromNormalAndCoplanarPoint(new l.Vector3(0, 1, 0), n[0]), w === "none" && g.setFromNormalAndCoplanarPoint(v, n[0])) : n.length === 2 ? (w === "y" && g.setFromCoplanarPoints(n[0], n[1], new l.Vector3(0, 1, 0).add(n[0])), y.setPoints([n[0], n[1]])) : n.length === 3 && (R(), h());
84
- }, x = (i) => {
85
- var A;
86
- if (!(i != null && i.raycaster))
81
+ let i = new r.Vector3(), v = new r.Vector3();
82
+ const f = new r.Plane(), C = () => {
83
+ n.push(i.clone()), n.length === 1 ? (m === "xoz" && f.setFromNormalAndCoplanarPoint(new r.Vector3(0, 1, 0), n[0]), m === "none" && f.setFromNormalAndCoplanarPoint(v, n[0])) : n.length === 2 ? m === "y" ? (b(), c()) : y.setPoints([n[0], n[1]]) : n.length === 3 && (b(), c());
84
+ }, x = (l) => {
85
+ var W;
86
+ if (!(l != null && l.raycaster))
87
87
  return;
88
- const D = (A = n.at(-1)) == null ? void 0 : A.clone();
89
- if (n.length === 0)
90
- a = i.point.clone(), v = i.face.normal;
91
- else if (n.length === 1)
92
- g ? (a = i.raycaster.ray.intersectPlane(g, G), c.setPoints([a, i.point])) : a = i.point.clone(), o.setPoints([D, a]);
93
- else if (n.length === 2) {
94
- const F = i.raycaster.ray.intersectPlane(g, new l.Vector3());
95
- if (m === "diagonal") {
96
- const P = n[0].distanceTo(n[1]) / 2, p = new l.Vector3().lerpVectors(n[0], n[1], 0.5), V = new l.Vector3().subVectors(F, p).normalize();
97
- a = new l.Vector3().addVectors(p, V.multiplyScalar(P));
98
- } else if (m === "vertex") {
99
- const P = n[0].distanceTo(n[1]), p = n[0], V = new l.Vector3().subVectors(F, p).normalize();
100
- a = new l.Vector3().addVectors(p, V.multiplyScalar(P));
88
+ const O = (W = n.at(-1)) == null ? void 0 : W.clone();
89
+ if (n.length === 0) {
90
+ i = l.point.clone(), v = l.face.normal;
91
+ return;
92
+ }
93
+ if (n.length === 1 && m === "y") {
94
+ const p = new r.Line3(new r.Vector3(0, 1, 0).add(n[0]), new r.Vector3(0, -1, 0).add(n[0])).closestPointToPoint(l.point, !1, P);
95
+ s.setPoints([n[0], p, l.point]);
96
+ return;
97
+ }
98
+ if (n.length === 1) {
99
+ f ? (i = l.raycaster.ray.intersectPlane(f, P), h.setPoints([i, l.point])) : i = l.point.clone(), o.setPoints([O, i]);
100
+ return;
101
+ }
102
+ if (n.length === 2) {
103
+ a.remove(o);
104
+ const z = l.raycaster.ray.intersectPlane(f, P);
105
+ if (g === "diagonal") {
106
+ const p = n[0].distanceTo(n[1]) / 2, V = new r.Vector3().lerpVectors(n[0], n[1], 0.5), F = new r.Vector3().subVectors(z, V).normalize();
107
+ i = new r.Vector3().addVectors(V, F.multiplyScalar(p)), s.setPoints([n[0], i, n[1]]);
108
+ } else if (g === "vertex") {
109
+ const p = P.crossVectors(n[0].clone().sub(n[1]), f.normal).normalize();
110
+ i = new r.Line3(n[1].clone().add(p), n[1].clone().sub(p)).closestPointToPoint(l.point, !1, P), s.setPoints([n[0], n[1], i]);
101
111
  }
102
- r.remove(o), s.setPoints([n[0], a, n[1]]);
112
+ return;
103
113
  }
114
+ }, b = () => {
115
+ t.off("select", C), t.off("intersectionUpdate", x), t.off("disable", R), t.disable(), a == null || a.remove(o, y, h);
104
116
  }, R = () => {
105
- t.off("select", C), t.off("intersectionUpdate", x), t.off("disable", N), t.disable(), r == null || r.remove(o, y, c);
106
- }, N = () => {
107
- R(), r == null || r.remove(s), f(new Error("Cancelled"));
117
+ b(), a == null || a.remove(s), w(new Error("Cancelled"));
108
118
  };
109
- t.on("select", C), t.on("intersectionUpdate", x), t.on("disable", N);
119
+ t.on("select", C), t.on("intersectionUpdate", x), t.on("disable", R);
110
120
  });
111
121
  }
112
122
  export {
@@ -10,7 +10,7 @@ var d = (m, i, e) => i in m ? _(m, i, { enumerable: !0, configurable: !0, writab
10
10
  O.call(i, e) && d(m, e, i[e]);
11
11
  return m;
12
12
  }, w = (m, i) => x(m, E(i));
13
- var h = (m, i, e) => (d(m, typeof i != "symbol" ? i + "" : i, e), e);
13
+ var a = (m, i, e) => (d(m, typeof i != "symbol" ? i + "" : i, e), e);
14
14
  var c = (m, i, e) => new Promise((t, o) => {
15
15
  var l = (u) => {
16
16
  try {
@@ -33,7 +33,8 @@ import { IObject3D as U } from "../shared-utils/three/IObject3D.js";
33
33
  import "three";
34
34
  import "hammerjs";
35
35
  import "three/examples/jsm/renderers/CSS3DRenderer";
36
- import "./Meshes/Line.js";
36
+ import "@realsee/five/line";
37
+ import "../shared-utils/tag.js";
37
38
  import "../shared-utils/three/THREESphere.js";
38
39
  import "animejs";
39
40
  import { notNil as H } from "../shared-utils/isNil.js";
@@ -49,17 +50,17 @@ import { Cylinder as D } from "./Objects/Cylinder/index.js";
49
50
  import { Box as j } from "./Objects/Box/index.js";
50
51
  import { forReverseEach as k } from "../shared-utils/forReverseEach.js";
51
52
  import { Line as B } from "./Objects/Line/index.js";
52
- const a = class extends S {
53
+ const p = class extends S {
53
54
  constructor(e, t) {
54
55
  super();
55
- h(this, "group");
56
- h(this, "five");
57
- h(this, "theme");
58
- this.five = e, this.theme = t, this.group = new U(), this.group.name = "Sculpt", e.scene.add(this.group), a.modules.init(e), a.modules.fiveDomEvents.addEventListener(this.group, "click", ({ intersects: o }) => {
56
+ a(this, "group");
57
+ a(this, "five");
58
+ a(this, "theme");
59
+ this.five = e, this.theme = t, this.group = new U(), this.group.name = "Sculpt", e.scene.add(this.group), p.modules.init(e), p.modules.fiveDomEvents.addEventListener(this.group, "click", ({ intersects: o }) => {
59
60
  var s;
60
61
  const l = M((s = o == null ? void 0 : o[0]) == null ? void 0 : s.object, (n) => n.isSculptObject);
61
62
  return l ? this.emit("click", l) : !1;
62
- }), window.__SCLUPT_DEBUG__ = this, window.__SCLUPT_MODULES_DEBUG__ = a.modules;
63
+ }), window.__SCLUPT_DEBUG__ = this, window.__SCLUPT_MODULES_DEBUG__ = p.modules;
63
64
  }
64
65
  get data() {
65
66
  return {
@@ -102,7 +103,7 @@ const a = class extends S {
102
103
  putObject(e) {
103
104
  var l;
104
105
  this.group.add(e);
105
- const t = a.modules.object3DHelper, o = t.addObject3DHelper(e);
106
+ const t = p.modules.object3DHelper, o = t.addObject3DHelper(e);
106
107
  return (l = o == null ? void 0 : o.moveController) == null || l.moveByMouse(), t;
107
108
  }
108
109
  /**
@@ -211,10 +212,10 @@ const a = class extends S {
211
212
  });
212
213
  }
213
214
  };
214
- let p = a;
215
- h(p, "modules", R);
216
- const me = (m) => new p(m);
215
+ let h = p;
216
+ a(h, "modules", R);
217
+ const le = (m) => new h(m);
217
218
  export {
218
- p as Sculpt,
219
- me as SculptPlugin
219
+ h as Sculpt,
220
+ le as SculptPlugin
220
221
  };
@@ -12,15 +12,17 @@ var u = (i, e, t) => e in i ? g(i, e, { enumerable: !0, configurable: !0, writab
12
12
  var n = (i, e, t) => (u(i, typeof e != "symbol" ? e + "" : e, t), t);
13
13
  import * as s from "three";
14
14
  import { DEFAULT_COLOR as F } from "../../typings/style.js";
15
- import { IObject3D as B } from "../../../shared-utils/three/IObject3D.js";
15
+ import { IObject3D as p } from "../../../shared-utils/three/IObject3D.js";
16
16
  import "hammerjs";
17
17
  import "three/examples/jsm/renderers/CSS3DRenderer";
18
- import "../../Meshes/Line.js";
18
+ import "@realsee/five/line";
19
+ import "../../../shared-utils/tag.js";
20
+ import "../Modules/Global.js";
19
21
  import "../../../shared-utils/three/THREESphere.js";
20
22
  import "animejs";
21
23
  import { notNil as y } from "../../../shared-utils/isNil.js";
22
24
  import "../../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
23
- class R extends B {
25
+ class x extends p {
24
26
  constructor(t) {
25
27
  var h, m;
26
28
  super();
@@ -82,5 +84,5 @@ class R extends B {
82
84
  }
83
85
  }
84
86
  export {
85
- R as ColoredMesh
87
+ x as ColoredMesh
86
88
  };
@@ -1,31 +1,33 @@
1
1
  var o = Object.defineProperty;
2
- var s = (i, t, r) => t in i ? o(i, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : i[t] = r;
3
- var e = (i, t, r) => (s(i, typeof t != "symbol" ? t + "" : t, r), r);
2
+ var s = (e, t, r) => t in e ? o(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r;
3
+ var i = (e, t, r) => (s(e, typeof t != "symbol" ? t + "" : t, r), r);
4
4
  import { Subscribe as l } from "../shared-utils/Subscribe.js";
5
5
  import "three";
6
6
  import "hammerjs";
7
7
  import "three/examples/jsm/renderers/CSS3DRenderer";
8
- import "../Sculpt/Meshes/Line.js";
8
+ import "@realsee/five/line";
9
+ import "../shared-utils/tag.js";
10
+ import "../Sculpt/utils/Modules/Global.js";
9
11
  import "../shared-utils/three/THREESphere.js";
10
12
  import "animejs";
11
13
  import { FiveUtil as a } from "../shared-utils/Utils/FiveUtil.js";
12
- import { absoluteUrl as h } from "../shared-utils/url/absoluteUrl.js";
14
+ import { absoluteUrl as m } from "../shared-utils/url/absoluteUrl.js";
13
15
  import "../vendor/@tweenjs/tween/dist/tween.esm.js.js";
14
- let c = class {
16
+ let P = class {
15
17
  constructor(t, r) {
16
18
  /**
17
19
  * @realsee/dnalogel 版本号
18
20
  */
19
- e(this, "VERSION", "3.47.9");
20
- e(this, "NAME");
21
- e(this, "five");
22
- e(this, "workUtil");
23
- e(this, "fiveUtil");
21
+ i(this, "VERSION", "3.47.11");
22
+ i(this, "NAME");
23
+ i(this, "five");
24
+ i(this, "workUtil");
25
+ i(this, "fiveUtil");
24
26
  /**
25
27
  * @description: 插件事件钩子
26
28
  */
27
- e(this, "hooks", new l());
28
- e(this, "staticPrefix", "//vr-image-4.realsee-cdn.cn");
29
+ i(this, "hooks", new l());
30
+ i(this, "staticPrefix", "//vr-image-4.realsee-cdn.cn");
29
31
  this.updateFive(t), r != null && r.staticPrefix && (this.staticPrefix = r.staticPrefix);
30
32
  }
31
33
  set workCode(t) {
@@ -47,11 +49,11 @@ let c = class {
47
49
  * @description: 获取静态资源的url
48
50
  */
49
51
  absoluteUrl(t) {
50
- return h(this.staticPrefix, t);
52
+ return m(this.staticPrefix, t);
51
53
  }
52
54
  onWorkCodeChange() {
53
55
  }
54
56
  };
55
57
  export {
56
- c as Controller
58
+ P as Controller
57
59
  };
@@ -42,7 +42,9 @@ import { changeModelCanvasOpacity as A } from "../../shared-utils/changeModelCan
42
42
  import { FloorplanErrorType as c, SHOW_ANIME_DURATION as H } from "../utils/constant.js";
43
43
  import "hammerjs";
44
44
  import "three/examples/jsm/renderers/CSS3DRenderer";
45
- import "../../Sculpt/Meshes/Line.js";
45
+ import "@realsee/five/line";
46
+ import "../../shared-utils/tag.js";
47
+ import "../../Sculpt/utils/Modules/Global.js";
46
48
  import "../../shared-utils/three/THREESphere.js";
47
49
  import "animejs";
48
50
  import { isNil as U } from "../../shared-utils/isNil.js";
@@ -87,21 +89,15 @@ import "../../shared-utils/five/getFiveModel.js";
87
89
  import "../../shared-utils/url/absoluteUrl.js";
88
90
  import "../../shared-utils/nearlyEqual.js";
89
91
  import "../../shared-utils/five/changeMode.js";
90
- import "../../Sculpt/typings/style.js";
91
- import "../../shared-utils/five/FiveLine.js";
92
- import "@realsee/five/line";
93
92
  import "../../shared-utils/positionToVector3.js";
94
- import "../../shared-utils/three/IObject3D.js";
95
- import "../../shared-utils/three/centerPoint.js";
96
- import "../../shared-utils/tag.js";
97
93
  import "../../shared-utils/five/vector3ToScreen.js";
98
94
  import "../../shared-utils/three/temp.js";
99
- import "../../Sculpt/utils/Modules/Global.js";
100
95
  import "../../Sculpt/utils/Modules/Cursor.js";
101
96
  import "../../Object3DHelperPlugin/Controller.js";
102
97
  import "../../shared-utils/Object3DHelper/Helper/MoveHelper.js";
103
98
  import "../../shared-utils/Object3DHelper/Base/BaseHelper.js";
104
99
  import "../../shared-utils/Object3DHelper/utils/setObjectQuaternion.js";
100
+ import "../../shared-utils/three/IObject3D.js";
105
101
  import "../../shared-utils/three/boundingBox.js";
106
102
  import "../../shared-utils/Object3DHelper/Helper/Objects/ArrowGroup.js";
107
103
  import "../../shared-utils/Object3DHelper/utils/direction.js";
@@ -114,6 +110,7 @@ import "../../CSS3DRenderPlugin/utils/createResizeObserver.js";
114
110
  import "../../CSS3DRenderPlugin/utils/even.js";
115
111
  import "../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
116
112
  import "../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
113
+ import "../../shared-utils/three/centerPoint.js";
117
114
  import "../../shared-utils/three/getObjectVisible.js";
118
115
  import "../../CSS3DRenderPlugin/utils/three/CSS3DScene.js";
119
116
  import "../../CSS3DRenderPlugin/utils/getAllCSS3DObject.js";
@@ -153,12 +150,16 @@ import "../../shared-utils/three/Assets/index.js";
153
150
  import "../../shared-utils/three/PointSelector/utils/html.js";
154
151
  import "../../shared-utils/five/initialCSS3DRender.js";
155
152
  import "../../shared-utils/three/PointSelector/utils/PointHelper2.js";
153
+ import "../../Sculpt/Meshes/Line.js";
154
+ import "../../Sculpt/typings/style.js";
155
+ import "../../shared-utils/five/FiveLine.js";
156
+ import "../../Sculpt/utils/removeAllTag.js";
157
+ import "../../Sculpt/utils/Meshes/getLengthHTML.js";
158
+ import "../../shared-utils/three/applyObjectMatrixWorld.js";
156
159
  import "../../CSS3DRenderPlugin/utils/three/CSS3DSprite.js";
157
160
  import "../../shared-utils/isTouchDevice.js";
158
161
  import "../../shared-utils/five/getPosition.js";
159
162
  import "../../shared-utils/five/getRaycasterByNdcPosition.js";
160
- import "../../Sculpt/utils/removeAllTag.js";
161
- import "../../Sculpt/utils/Meshes/getLengthHTML.js";
162
163
  function W(d) {
163
164
  const { latitude: n, longitude: t } = d, e = Math.abs(n - Math.PI / 2) > 5 * Math.PI / 180, i = t > 5 * (Math.PI / 180) && t < 355 * (Math.PI / 180);
164
165
  return e || i;
@@ -167,7 +168,7 @@ function G(d) {
167
168
  const { latitude: n, longitude: t } = d, e = Math.abs(n - Math.PI / 2) < 10 * Math.PI / 180, i = t < 30 * (Math.PI / 180) || t > 330 * (Math.PI / 180);
168
169
  return e && i;
169
170
  }
170
- class pi extends O {
171
+ class fi extends O {
171
172
  constructor(t, e) {
172
173
  var a, m;
173
174
  super(t);
@@ -502,5 +503,5 @@ class pi extends O {
502
503
  }
503
504
  }
504
505
  export {
505
- pi as Controller
506
+ fi as Controller
506
507
  };