@realsee/dnalogel 3.50.14 → 3.50.15-alpha.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.
Files changed (110) hide show
  1. package/README.md +116 -0
  2. package/dist/Sculpt/Objects/Base/index.d.ts +1 -1
  3. package/dist/Sculpt/index.d.ts +4 -4
  4. package/dist/index.cjs.js +262 -262
  5. package/dist/index.js +4235 -4231
  6. package/dist/index.umd.js +263 -263
  7. package/dist/shared-utils/five/index.d.ts +2 -0
  8. package/dist/shared-utils/tag.d.ts +1 -1
  9. package/dist/shared-utils/three/index.d.ts +1 -0
  10. package/libs/AreaMakerPlugin/Controller.js +104 -74
  11. package/libs/AreaMakerPlugin/index.js +33 -3
  12. package/libs/AreaMakerPlugin/utils/Item.js +66 -36
  13. package/libs/CSS3DRenderPlugin/Controller.js +39 -19
  14. package/libs/CSS3DRenderPlugin/index.js +34 -14
  15. package/libs/CSS3DRenderPlugin/utils/three/CSS3DObject.js +60 -35
  16. package/libs/CSS3DRenderPlugin/utils/three/CSS3DRender.js +98 -78
  17. package/libs/CruisePlugin/BaseController.js +59 -29
  18. package/libs/CruisePlugin/Move.js +33 -14
  19. package/libs/CruisePlugin/Work.js +66 -47
  20. package/libs/CruisePlugin/index.js +38 -19
  21. package/libs/CurrentPanoImagePlugin/Controller.js +68 -38
  22. package/libs/CurrentPanoImagePlugin/index.js +34 -4
  23. package/libs/GuideLinePlugin/Controller.js +69 -50
  24. package/libs/GuideLinePlugin/GuideLineItem.js +34 -15
  25. package/libs/GuideLinePlugin/GuideLineModeItem/index.js +3 -2
  26. package/libs/GuideLinePlugin/GuideLineModeItem.js +34 -15
  27. package/libs/GuideLinePlugin/index.js +38 -19
  28. package/libs/ModelMakerPlugin/Controller.js +60 -42
  29. package/libs/ModelMakerPlugin/index.js +34 -16
  30. package/libs/ModelTVVideoPlugin/Plugin.js +48 -28
  31. package/libs/ModelTVVideoPlugin/index.js +24 -4
  32. package/libs/Object3DHelperPlugin/Controller.js +49 -30
  33. package/libs/Object3DHelperPlugin/index.js +36 -17
  34. package/libs/PanoCompassPlugin/Controller.js +33 -13
  35. package/libs/PanoCompassPlugin/index.js +34 -14
  36. package/libs/PanoDoorLabelPlugin/BaseController.js +55 -25
  37. package/libs/PanoDoorLabelPlugin/Controller.js +99 -69
  38. package/libs/PanoDoorLabelPlugin/index.js +34 -4
  39. package/libs/PanoMeasurePlugin/Components/Controller0.js +8 -8
  40. package/libs/PanoMeasurePlugin/Components/Controller1.js +8 -8
  41. package/libs/PanoMeasurePlugin/Controller/WatchController.js +75 -49
  42. package/libs/PanoMeasurePlugin/Controller/index.js +16 -16
  43. package/libs/PanoMeasurePlugin/Model/area.js +41 -15
  44. package/libs/PanoMeasurePlugin/Modules/Magnifier.js +29 -0
  45. package/libs/PanoMeasurePlugin/Modules/UIController/index.js +8 -8
  46. package/libs/PanoMeasurePlugin/index.js +3 -3
  47. package/libs/PanoMeasurePlugin/utils/dom/areaDom.js +43 -15
  48. package/libs/PanoRulerProPlugin/Controller.js +60 -30
  49. package/libs/PanoRulerProPlugin/RulerItems.js +85 -55
  50. package/libs/PanoRulerProPlugin/index.js +33 -3
  51. package/libs/PanoSpatialTagPlugin/Plugin.js +54 -34
  52. package/libs/PanoSpatialTagPlugin/index.js +22 -2
  53. package/libs/PanoTagPlugin/Components/Common/TagPoint.js +79 -49
  54. package/libs/PanoTagPlugin/Components/Tag/MarketingTag.js +235 -206
  55. package/libs/PanoTagPlugin/Components/Tag/index.js +152 -125
  56. package/libs/PanoTagPlugin/Components/TagContainer.js +97 -70
  57. package/libs/PanoTagPlugin/Components/TagItem.js +31 -4
  58. package/libs/PanoTagPlugin/controller/Tag/BaseTag.js +29 -2
  59. package/libs/PanoTagPlugin/controller/Tag/ModelTag.js +55 -28
  60. package/libs/PanoTagPlugin/controller/Tag/PlaneTag.js +53 -26
  61. package/libs/PanoTagPlugin/controller/Tag/PointTag.js +54 -27
  62. package/libs/PanoTagPlugin/controller/TagRender.js +48 -29
  63. package/libs/PanoTagPlugin/controller/TagUtil.js +33 -14
  64. package/libs/PanoTagPlugin/controller/index.js +49 -30
  65. package/libs/PanoTagPlugin/index.js +41 -22
  66. package/libs/PanoTagPlugin/utils/tag/calculateTagConfig.js +59 -29
  67. package/libs/PanoVideoPlugin/Controller.js +91 -61
  68. package/libs/PanoVideoPlugin/VideoMeshController.js +56 -26
  69. package/libs/PanoVideoPlugin/index.js +36 -6
  70. package/libs/PipelinePlugin/Controller.js +80 -51
  71. package/libs/PipelinePlugin/index.js +34 -5
  72. package/libs/PipelinePlugin/utils/Objects/FlowPipe.js +44 -14
  73. package/libs/PipelinePlugin/utils/Objects/HighlightPipe.js +43 -13
  74. package/libs/PipelinePlugin/utils/Objects/Pipe.js +61 -31
  75. package/libs/Sculpt/Meshes/Box.js +3 -2
  76. package/libs/Sculpt/Meshes/Cylinder.js +3 -2
  77. package/libs/Sculpt/Meshes/Line.js +9 -8
  78. package/libs/Sculpt/Meshes/LineWithDots.js +8 -7
  79. package/libs/Sculpt/Meshes/Point.js +3 -2
  80. package/libs/Sculpt/Meshes/Polygon.js +3 -2
  81. package/libs/Sculpt/Meshes/Prism.js +9 -8
  82. package/libs/Sculpt/Meshes/Rectangle.js +3 -2
  83. package/libs/Sculpt/Objects/Base/index.d.ts +1 -1
  84. package/libs/Sculpt/Objects/Line/Editor.js +7 -6
  85. package/libs/Sculpt/index.d.ts +4 -4
  86. package/libs/Sculpt/index.js +3 -2
  87. package/libs/Sculpt/utils/three/ColoredMesh.js +6 -5
  88. package/libs/base/BasePlugin.js +4 -3
  89. package/libs/floorplan/MapviewFloorplanPlugin/Controller.js +89 -60
  90. package/libs/floorplan/MapviewFloorplanPlugin/index.js +34 -5
  91. package/libs/floorplan/ModelFloorplanPlugin/Controller.js +79 -50
  92. package/libs/floorplan/ModelFloorplanPlugin/index.js +34 -5
  93. package/libs/floorplan/PanoFloorplanRadarPlugin/Controller.js +68 -38
  94. package/libs/floorplan/PanoFloorplanRadarPlugin/index.js +34 -4
  95. package/libs/floorplan/TopviewFloorplanPlugin/Controller.js +104 -75
  96. package/libs/floorplan/TopviewFloorplanPlugin/index.js +34 -5
  97. package/libs/floorplan/index.js +1 -0
  98. package/libs/index.js +28 -28
  99. package/libs/shared-utils/five/fiveModelLoad.js +1 -0
  100. package/libs/shared-utils/five/index.d.ts +2 -0
  101. package/libs/shared-utils/five/index.js +3 -2
  102. package/libs/shared-utils/five/lookObject.js +3 -2
  103. package/libs/shared-utils/index.js +42 -35
  104. package/libs/shared-utils/logger.js +1 -1
  105. package/libs/shared-utils/tag.d.ts +1 -1
  106. package/libs/shared-utils/tag.js +41 -41
  107. package/libs/shared-utils/three/PointSelector/utils/PointSelectorHelper.js +3 -2
  108. package/libs/shared-utils/three/index.d.ts +1 -0
  109. package/libs/shared-utils/three/index.js +1 -0
  110. package/package.json +1 -1
@@ -1,6 +1,6 @@
1
1
  var I = Object.defineProperty;
2
2
  var R = (c, r, t) => r in c ? I(c, r, { enumerable: !0, configurable: !0, writable: !0, value: t }) : c[r] = t;
3
- var s = (c, r, t) => (R(c, typeof r != "symbol" ? r + "" : r, t), t);
3
+ var o = (c, r, t) => (R(c, typeof r != "symbol" ? r + "" : r, t), t);
4
4
  import G from "hammerjs";
5
5
  import T from "../Modules/DeleteDom/index.js";
6
6
  import w from "../utils/isNDCPointInScreen.js";
@@ -41,7 +41,16 @@ import "../../shared-utils/Utils/WorkUtil.js";
41
41
  import "../../shared-utils/five/transformPosition.js";
42
42
  import "../../shared-utils/three/temp.js";
43
43
  import "../../shared-utils/dom/resizeObserver.js";
44
+ import "../../shared-utils/three/PointSelector/index.js";
45
+ import "../../shared-utils/three/PointSelector/utils/PointSelectorHelper.js";
46
+ import "../../shared-utils/three/Magnifier.js";
47
+ import "../../shared-utils/three/PointSelector/utils/PointHelper.js";
48
+ import "../../shared-utils/three/Assets/index.js";
49
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
44
50
  import "three/examples/jsm/renderers/CSS3DRenderer";
51
+ import "../../CSS3DRenderPlugin/utils/even.js";
52
+ import "../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
53
+ import "../../shared-utils/three/getObjectVisible.js";
45
54
  import "../../vendor/three/examples/jsm/lines/LineGeometry.js";
46
55
  import "../../vendor/three/examples/jsm/lines/LineSegmentsGeometry.js";
47
56
  import "../../vendor/three/build/three.module.js";
@@ -49,47 +58,64 @@ import "../../shared-utils/three/core/Sphere.js";
49
58
  import "animejs";
50
59
  import "../../shared-utils/isNil.js";
51
60
  import "../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
61
+ import "../../shared-utils/three/PointSelector/utils/html.js";
62
+ import "../../shared-utils/five/initialCSS3DRender.js";
63
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
64
+ import "../../CSS3DRenderPlugin/utils/three/THREEJS_CSS3DRenderer.js";
65
+ import "../../CSS3DRenderPlugin/utils/createResizeObserver.js";
66
+ import "../../shared-utils/three/PointSelector/utils/PointHelper2.js";
67
+ import "../../Sculpt/Meshes/Line.js";
68
+ import "../../Sculpt/typings/style.js";
52
69
  import "../../shared-utils/three/IObject3D.js";
70
+ import "../../Sculpt/utils/removeAllTag.js";
71
+ import "../../Sculpt/utils/Meshes/getLengthHTML.js";
72
+ import "../../shared-utils/three/applyObjectMatrixWorld.js";
73
+ import "../../shared-utils/util.js";
74
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DSprite.js";
75
+ import "../../shared-utils/isTouchDevice.js";
76
+ import "../../shared-utils/five/getPosition.js";
77
+ import "../../shared-utils/five/getRaycasterByNdcPosition.js";
78
+ import "../../shared-utils/three/PointSelector/utils/contents.js";
53
79
  import "../../shared-utils/three/generatePolygonGeometry.js";
54
80
  import "../../shared-utils/three/earcut3D.js";
55
81
  import "earcut";
56
82
  import "../../shared-utils/three/getNormal.js";
57
83
  import "../utils/isIntersecting.js";
58
84
  const E = () => !1;
59
- class Vt extends U {
85
+ class de extends U {
60
86
  constructor(t) {
61
87
  super(t);
62
- s(this, "type", "watch");
63
- s(this, "deleteDom");
64
- s(this, "choose");
88
+ o(this, "type", "watch");
89
+ o(this, "deleteDom");
90
+ o(this, "choose");
65
91
  // tmd 真没时间改了,先这样吧,理解万岁
66
- s(this, "highlightedLines", []);
67
- s(this, "highlightedArea");
68
- s(this, "fiveElement");
69
- s(this, "editPointState");
70
- s(this, "hammer");
71
- s(this, "onPanStart", (t) => {
72
- var p;
92
+ o(this, "highlightedLines", []);
93
+ o(this, "highlightedArea");
94
+ o(this, "fiveElement");
95
+ o(this, "editPointState");
96
+ o(this, "hammer");
97
+ o(this, "onPanStart", (t) => {
98
+ var m;
73
99
  if (this.model.getAllLines().length === 0 || !this.fiveElement)
74
100
  return;
75
- const i = C(t).point, e = (p = j(this.five, this.model.getAllPoints(), i, 20)) == null ? void 0 : p.point;
101
+ const i = C(t).point, e = (m = j(this.five, this.model.getAllPoints(), i, 20)) == null ? void 0 : m.point;
76
102
  if (!e) {
77
103
  this.editPointState = void 0;
78
104
  return;
79
105
  }
80
- const n = this.model.polylines.find((a) => a.includes(e)), l = {
106
+ const n = this.model.polylines.find((a) => a.includes(e)), p = {
81
107
  point: e,
82
108
  associatedLines: n.lines
83
109
  };
84
110
  this.hook.emit("wantsDragLine", {
85
111
  point: e.id,
86
- lines: l.associatedLines.map(({ id: a }) => a)
87
- }) || (this.editPointState = l, this.magnifier.appendTo(this.container), this.magnifier.enable(), this.group.add(this.mouseGroup));
112
+ lines: p.associatedLines.map(({ id: a }) => a)
113
+ }) || (this.editPointState = p, this.magnifier.appendTo(this.container), this.magnifier.enable(), this.group.add(this.mouseGroup));
88
114
  });
89
- s(this, "onPanEnd", () => {
115
+ o(this, "onPanEnd", () => {
90
116
  this.editPointState && (this.editPointState.associatedLines.forEach((t) => t.mesh.setMaterial({ dashed: !1 })), this.highlightLines(this.editPointState.associatedLines), this.editPointState = void 0, this.magnifier.disable(), this.group.remove(this.mouseGroup));
91
117
  });
92
- s(this, "onPan", (t) => {
118
+ o(this, "onPan", (t) => {
93
119
  if (!this.editPointState || !this.fiveElement)
94
120
  return;
95
121
  const i = C(t).ndcPoint, e = new M();
@@ -97,15 +123,15 @@ class Vt extends U {
97
123
  const [n] = D(this.five).intersectRaycaster(e);
98
124
  n && this.onIntersectionUpdate(n);
99
125
  });
100
- s(this, "onIntersectionUpdate", (t, i) => {
126
+ o(this, "onIntersectionUpdate", (t, i) => {
101
127
  if (this.editPointState) {
102
128
  if (this.clearHighlightLines(), this.editPointState.point.position.copy(t.point), this.editPointState.associatedLines.forEach((e) => {
103
129
  e.mesh.setPoints(e.points[0].position.clone(), e.points[1].position.clone()), e.lightMesh.setPoints(e.points[0].position.clone(), e.points[1].position.clone()), e.mesh.setMaterial({ dashed: !0 });
104
130
  }), this.updateDistanceUI(), this.magnifier.renderWithPoint(t.point), this.mouseGroup.position.copy(t.point), i)
105
131
  this.mouseGroup.quaternion.copy(i.quaternion);
106
132
  else if (t.face) {
107
- const n = t.face.normal.clone().multiplyScalar(0.05), d = t.point.clone().add(n).clone().add(n);
108
- this.mouseGroup.lookAt(d);
133
+ const n = t.face.normal.clone().multiplyScalar(0.05), l = t.point.clone().add(n).clone().add(n);
134
+ this.mouseGroup.lookAt(l);
109
135
  }
110
136
  this.five.needsRender = !0, this.hook.emit(
111
137
  "selectedChange",
@@ -113,43 +139,43 @@ class Vt extends U {
113
139
  );
114
140
  }
115
141
  });
116
- s(this, "wantsPanGesture", () => {
142
+ o(this, "wantsPanGesture", () => {
117
143
  if (this.editPointState)
118
144
  return !1;
119
145
  });
120
- s(this, "wantsTapGesture", (t) => {
146
+ o(this, "wantsTapGesture", (t) => {
121
147
  var S;
122
- const i = this.model.areas.map((o) => t.intersectObject(o.polygon, !0)[0]).sort((o, h) => o.distance - h.distance), e = (S = i[0]) == null ? void 0 : S.object.parent;
148
+ const i = this.model.areas.map((s) => t.intersectObject(s.polygon, !0)[0]).sort((s, h) => s.distance - h.distance), e = (S = i[0]) == null ? void 0 : S.object.parent;
123
149
  if (e instanceof F) {
124
- const o = this.model.areas.find((h) => h.polygon === e);
125
- if (o) {
126
- const { x: h, y: u } = i[0].point.clone().project(this.five.camera), m = `${(h + 1) / 2 * 100}%`, g = `${(-u + 1) / 2 * 100}%`;
127
- return this.chooseArea(o, { left: m, top: g }), !1;
150
+ const s = this.model.areas.find((h) => h.polygon === e);
151
+ if (s) {
152
+ const { x: h, y: u } = i[0].point.clone().project(this.five.camera), d = `${(h + 1) / 2 * 100}%`, g = `${(-u + 1) / 2 * 100}%`;
153
+ return this.chooseArea(s, { left: d, top: g }), !1;
128
154
  }
129
155
  }
130
- const n = D(this.five), [l] = n.intersectRaycaster(t);
131
- if (!l)
156
+ const n = D(this.five), [p] = n.intersectRaycaster(t);
157
+ if (!p)
132
158
  return;
133
- const d = this.five.camera, p = l.point.clone().project(d), a = this.container.clientWidth, f = this.container.clientHeight, P = new L(p.x * a, p.y * f), v = this.model.getAllLines().map((o) => {
134
- const [h, u] = o.points, m = h.position.clone().project(d), g = u.position.clone().project(d);
135
- if (!w(m) && !w(g))
159
+ const l = this.five.camera, m = p.point.clone().project(l), a = this.container.clientWidth, f = this.container.clientHeight, P = new L(m.x * a, m.y * f), v = this.model.getAllLines().map((s) => {
160
+ const [h, u] = s.points, d = h.position.clone().project(l), g = u.position.clone().project(l);
161
+ if (!w(d) && !w(g))
136
162
  return null;
137
- const H = new L(m.x * a, m.y * f), k = new L(g.x * a, g.y * f);
138
- return { id: o.id, points: [H, k] };
139
- }).filter((o) => !!o);
163
+ const H = new L(d.x * a, d.y * f), k = new L(g.x * a, g.y * f);
164
+ return { id: s.id, points: [H, k] };
165
+ }).filter((s) => !!s);
140
166
  if (v.length === 0)
141
167
  return;
142
- const y = v.map((o) => {
143
- const h = b(P, o.points);
144
- return { id: o.id, distance: h.distanceTo(P) };
145
- }).sort((o, h) => o.distance - h.distance)[0];
168
+ const y = v.map((s) => {
169
+ const h = b(P, s.points);
170
+ return { id: s.id, distance: h.distanceTo(P) };
171
+ }).sort((s, h) => s.distance - h.distance)[0];
146
172
  if (y.distance > 20)
147
173
  return;
148
- const A = this.model.getAllLines().find(({ id: o }) => o === y.id);
174
+ const A = this.model.getAllLines().find(({ id: s }) => s === y.id);
149
175
  if (A)
150
176
  return this.chooseLine(A), !1;
151
177
  });
152
- s(this, "chooseLine", (t) => {
178
+ o(this, "chooseLine", (t) => {
153
179
  this.choose = "line";
154
180
  const i = t.getPolyline().lines;
155
181
  this.deleteDom.setLines(i).updatePosition().show(), this.highlightLines(i), this.five.needsRender = !0, this.hook.emit(
@@ -157,26 +183,26 @@ class Vt extends U {
157
183
  i.map((e) => e)
158
184
  );
159
185
  });
160
- s(this, "chooseArea", (t, i) => {
186
+ o(this, "chooseArea", (t, i) => {
161
187
  this.choose = t, this.deleteDom.updatePosition(i.left, `calc(${i.top} - 20px)`).show(), this.highlightArea(t);
162
188
  });
163
- s(this, "polylineRemoved", (t) => {
189
+ o(this, "polylineRemoved", (t) => {
164
190
  t.lines.forEach((i) => this.removeLine(i)), this.hook.emit(
165
191
  "selectedChange",
166
192
  this.model.getAllLines().filter((i) => i.selected).map((i) => i)
167
193
  );
168
194
  });
169
- s(this, "onCameraUpdate", () => {
195
+ o(this, "onCameraUpdate", () => {
170
196
  this.updateDistanceUI(), this.highlightedLines.length > 0 && this.deleteDom.updatePosition();
171
197
  });
172
- s(this, "deleteArea", (t) => {
198
+ o(this, "deleteArea", (t) => {
173
199
  this.unHighlightArea(t), t.dispose(), this.deleteDom.hide();
174
200
  });
175
- s(this, "deleteLine", () => {
201
+ o(this, "deleteLine", () => {
176
202
  const t = this.highlightedLines[0], i = this.model.getPolylineByLine(t);
177
203
  i && (this.model.removePolyline(i), this.highlightedLines = [], this.deleteDom.setLines([]).hide());
178
204
  });
179
- s(this, "cancelDeleteClickCallback", () => {
205
+ o(this, "cancelDeleteClickCallback", () => {
180
206
  this.deleteDom.hide(), this.clearHighlightLines(), this.unHighlightArea();
181
207
  });
182
208
  this.deleteDom = new T(this.five, {
@@ -229,5 +255,5 @@ class Vt extends U {
229
255
  }
230
256
  }
231
257
  export {
232
- Vt as default
258
+ de as default
233
259
  };
@@ -24,13 +24,14 @@ import { ShortcutKeyController as B } from "./ShortcutKeyController.js";
24
24
  import { safeObj as U } from "../../shared-utils/safeObj.js";
25
25
  import "../../shared-utils/tag.js";
26
26
  import { Magnifier as V } from "../../shared-utils/three/Magnifier.js";
27
+ import "../../shared-utils/three/PointSelector/index.js";
27
28
  import "three/examples/jsm/renderers/CSS3DRenderer";
28
29
  import "@realsee/five/line";
29
30
  import "../../vendor/three/examples/jsm/lines/LineGeometry.js";
30
31
  import "../../shared-utils/three/core/Sphere.js";
31
32
  import "animejs";
32
- import "../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
33
33
  import { isTouchDevice as K } from "../../shared-utils/isTouchDevice.js";
34
+ import "../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
34
35
  import { Controller as H } from "../../base/BasePlugin.js";
35
36
  import "../Model/line.js";
36
37
  import "../../shared-utils/uuid.js";
@@ -59,26 +60,30 @@ import "../utils/dom/areaDom.js";
59
60
  import "../../shared-utils/three/geometryUtil.js";
60
61
  import "hammerjs";
61
62
  import "../../shared-utils/isNil.js";
62
- import "../../shared-utils/three/PointSelector/index.js";
63
- import "../../shared-utils/three/PointSelector/utils/PointSelectorHelper.js";
64
- import "../../shared-utils/three/PointSelector/utils/PointHelper.js";
65
- import "../../shared-utils/three/Assets/index.js";
66
- import "../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
67
- import "../../CSS3DRenderPlugin/utils/even.js";
68
- import "../../shared-utils/Subscribe.js";
69
- import "../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
70
- import "../../shared-utils/three/getObjectVisible.js";
63
+ import "../Modules/DeleteDom/index.js";
64
+ import "../Modules/DeleteDom/_Assets/delete.svg.js";
65
+ import "../Modules/DeleteDom/_Assets/delete_bg.png.js";
66
+ import "../Modules/DeleteDom/_Assets/delete_hover_bg.png.js";
67
+ import "../utils/math.js";
68
+ import "../../shared-utils/five/getFiveModel.js";
71
69
  import "../../shared-utils/positionToVector3.js";
72
70
  import "../../shared-utils/five/vector3ToScreen.js";
73
- import "../../shared-utils/five/getFiveModel.js";
74
71
  import "../../shared-utils/Utils/FiveUtil.js";
75
72
  import "../../shared-utils/Utils/BaseUtil.js";
73
+ import "../../shared-utils/Subscribe.js";
76
74
  import "../../shared-utils/Utils/WorkUtil.js";
77
75
  import "../../shared-utils/five/transformPosition.js";
78
76
  import "../../shared-utils/three/temp.js";
79
77
  import "../../shared-utils/dom/resizeObserver.js";
80
78
  import "../../vendor/three/examples/jsm/lines/LineSegmentsGeometry.js";
81
79
  import "../../vendor/three/build/three.module.js";
80
+ import "../../shared-utils/three/PointSelector/utils/PointSelectorHelper.js";
81
+ import "../../shared-utils/three/PointSelector/utils/PointHelper.js";
82
+ import "../../shared-utils/three/Assets/index.js";
83
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
84
+ import "../../CSS3DRenderPlugin/utils/even.js";
85
+ import "../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
86
+ import "../../shared-utils/three/getObjectVisible.js";
82
87
  import "../../shared-utils/three/PointSelector/utils/html.js";
83
88
  import "../../shared-utils/five/initialCSS3DRender.js";
84
89
  import "../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
@@ -95,11 +100,6 @@ import "../../CSS3DRenderPlugin/utils/three/CSS3DSprite.js";
95
100
  import "../../shared-utils/five/getPosition.js";
96
101
  import "../../shared-utils/five/getRaycasterByNdcPosition.js";
97
102
  import "../../shared-utils/three/PointSelector/utils/contents.js";
98
- import "../Modules/DeleteDom/index.js";
99
- import "../Modules/DeleteDom/_Assets/delete.svg.js";
100
- import "../Modules/DeleteDom/_Assets/delete_bg.png.js";
101
- import "../Modules/DeleteDom/_Assets/delete_hover_bg.png.js";
102
- import "../utils/math.js";
103
103
  import "../utils/findClosestPoint.js";
104
104
  import "../utils/ndc2Screen.js";
105
105
  import "../../shared-utils/getPointFromHammerEvent.js";
@@ -1,13 +1,13 @@
1
1
  var l = Object.defineProperty;
2
2
  var d = (o, t, e) => t in o ? l(o, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : o[t] = e;
3
3
  var i = (o, t, e) => (d(o, typeof t != "symbol" ? t + "" : t, e), e);
4
- import * as r from "three";
4
+ import * as m from "three";
5
5
  import { uuid as f } from "../../shared-utils/uuid.js";
6
6
  import { Subscribe as c } from "@realsee/five";
7
7
  import u from "./line.js";
8
8
  import v from "./polygon.js";
9
9
  import { Polyline as y } from "./polyline.js";
10
- import a from "./point.js";
10
+ import n from "./point.js";
11
11
  import { AreaItem as C } from "../utils/dom/areaDom.js";
12
12
  import "../utils/line.js";
13
13
  import "../../shared-utils/five/FiveLine.js";
@@ -36,7 +36,16 @@ import "../../shared-utils/five/transformPosition.js";
36
36
  import "../../shared-utils/three/temp.js";
37
37
  import "../../shared-utils/dom/resizeObserver.js";
38
38
  import "hammerjs";
39
+ import "../../shared-utils/three/PointSelector/index.js";
40
+ import "../../shared-utils/three/PointSelector/utils/PointSelectorHelper.js";
41
+ import "../../shared-utils/three/Magnifier.js";
42
+ import "../../shared-utils/three/PointSelector/utils/PointHelper.js";
43
+ import "../../shared-utils/three/Assets/index.js";
44
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
39
45
  import "three/examples/jsm/renderers/CSS3DRenderer";
46
+ import "../../CSS3DRenderPlugin/utils/even.js";
47
+ import "../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
48
+ import "../../shared-utils/three/getObjectVisible.js";
40
49
  import "../../vendor/three/examples/jsm/lines/LineGeometry.js";
41
50
  import "../../vendor/three/examples/jsm/lines/LineSegmentsGeometry.js";
42
51
  import "../../vendor/three/build/three.module.js";
@@ -44,7 +53,24 @@ import "../../shared-utils/three/core/Sphere.js";
44
53
  import "animejs";
45
54
  import "../../shared-utils/isNil.js";
46
55
  import "../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
47
- class at {
56
+ import "../../shared-utils/three/PointSelector/utils/html.js";
57
+ import "../../shared-utils/five/initialCSS3DRender.js";
58
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
59
+ import "../../CSS3DRenderPlugin/utils/three/THREEJS_CSS3DRenderer.js";
60
+ import "../../CSS3DRenderPlugin/utils/createResizeObserver.js";
61
+ import "../../shared-utils/three/PointSelector/utils/PointHelper2.js";
62
+ import "../../Sculpt/Meshes/Line.js";
63
+ import "../../Sculpt/typings/style.js";
64
+ import "../../Sculpt/utils/removeAllTag.js";
65
+ import "../../Sculpt/utils/Meshes/getLengthHTML.js";
66
+ import "../../shared-utils/three/applyObjectMatrixWorld.js";
67
+ import "../../shared-utils/util.js";
68
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DSprite.js";
69
+ import "../../shared-utils/isTouchDevice.js";
70
+ import "../../shared-utils/five/getPosition.js";
71
+ import "../../shared-utils/five/getRaycasterByNdcPosition.js";
72
+ import "../../shared-utils/three/PointSelector/utils/contents.js";
73
+ class Ft {
48
74
  constructor(t, e) {
49
75
  i(this, "id", f());
50
76
  i(this, "selected", !1);
@@ -73,14 +99,14 @@ class at {
73
99
  i(this, "updateDom", () => {
74
100
  this.five && (this.polyline.lines.forEach((t) => t.distanceItem.update(this.five)), this.areaItem.updateDomPosition(this.five));
75
101
  });
76
- var n;
102
+ var p;
77
103
  t && (this.points = t), this.model = e.model, this.polygon = new v(t), this.polyline = new y({ model: e.model }), this.areaItem = new C({
78
104
  area: this,
79
- clickCallback: (p, s) => {
80
- const h = p.clientX + "px", m = p.clientY + "px";
81
- this.hook.emit("selected", this, { left: h, top: m });
105
+ clickCallback: (r, s) => {
106
+ const a = r.clientX + "px", h = r.clientY + "px";
107
+ this.hook.emit("selected", this, { left: a, top: h });
82
108
  }
83
- }), this.domContainer = e.domContainer || null, this.meshContainer = e.meshContainer || null, this.five = e.five || null, this.areaItem.appendTo(this.domContainer), (n = this.five) == null || n.on("cameraUpdate", this.updateDom);
109
+ }), this.domContainer = e.domContainer || null, this.meshContainer = e.meshContainer || null, this.five = e.five || null, this.areaItem.appendTo(this.domContainer), (p = this.five) == null || p.on("cameraUpdate", this.updateDom);
84
110
  }
85
111
  /**
86
112
  * @description: 多边形的端点是否闭合
@@ -90,14 +116,14 @@ class at {
90
116
  return this.points.length >= 4 && ((t = this.points.at(0)) == null ? void 0 : t.equals(this.points.at(-1)));
91
117
  }
92
118
  addPoints(t) {
93
- var p;
119
+ var r;
94
120
  this.points = this.points.concat(t);
95
- const e = this.points.at(-2), n = this.points.at(-1);
96
- if (e && n) {
97
- const s = new u(new a(e), new a(n), this.polyline.model);
121
+ const e = this.points.at(-2), p = this.points.at(-1);
122
+ if (e && p) {
123
+ const s = new u(new n(e), new n(p), this.polyline.model);
98
124
  this.polyline.addLine(s), this.meshContainer.add(s.mesh), this.five && (s.distanceItem.setCanSelect(!1), s.distanceItem.appendTo(this.domContainer), s.distanceItem.update(this.five));
99
125
  }
100
- (p = this.meshContainer) != null && p.children.includes(this.polygon) || this.meshContainer.add(this.polygon), this.polygon.updatePoints(this.points), this.areaItem.updateArea(this.five), this.points.length === 3 ? this.planeHelper = new r.Plane().setFromCoplanarPoints(this.points[0], this.points[1], this.points[2]) : this.points.length < 3 && (this.planeHelper = null);
126
+ (r = this.meshContainer) != null && r.children.includes(this.polygon) || this.meshContainer.add(this.polygon), this.polygon.updatePoints(this.points), this.areaItem.updateArea(this.five), this.points.length === 3 ? this.planeHelper = new m.Plane().setFromCoplanarPoints(this.points[0], this.points[1], this.points[2]) : this.points.length < 3 && (this.planeHelper = null);
101
127
  }
102
128
  /**
103
129
  * @description: 移除最后一个添加的点
@@ -123,7 +149,7 @@ class at {
123
149
  * @description: 获取一个点投影在当前平面上的点
124
150
  */
125
151
  projectPoint(t) {
126
- return t && (this.planeHelper ? this.planeHelper.projectPoint(t, new r.Vector3()) : t);
152
+ return t && (this.planeHelper ? this.planeHelper.projectPoint(t, new m.Vector3()) : t);
127
153
  }
128
154
  remove() {
129
155
  this.polygon.removeFromParent(), this.areaItem.remove(), this.polyline.lines.forEach((t) => t.remove());
@@ -143,5 +169,5 @@ class at {
143
169
  }
144
170
  }
145
171
  export {
146
- at as default
172
+ Ft as default
147
173
  };
@@ -1,6 +1,7 @@
1
1
  import "../../shared-utils/tag.js";
2
2
  import "three";
3
3
  import { Magnifier as t } from "../../shared-utils/three/Magnifier.js";
4
+ import "../../shared-utils/three/PointSelector/index.js";
4
5
  import "three/examples/jsm/renderers/CSS3DRenderer";
5
6
  import "@realsee/five/line";
6
7
  import "../../vendor/three/examples/jsm/lines/LineGeometry.js";
@@ -18,6 +19,34 @@ import "../../shared-utils/five/transformPosition.js";
18
19
  import "../../shared-utils/three/temp.js";
19
20
  import "../../shared-utils/dom/resizeObserver.js";
20
21
  import "hammerjs";
22
+ import "../../shared-utils/three/PointSelector/utils/PointSelectorHelper.js";
23
+ import "../../shared-utils/three/PointSelector/utils/PointHelper.js";
24
+ import "../../shared-utils/three/Assets/index.js";
25
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
26
+ import "../../CSS3DRenderPlugin/utils/even.js";
27
+ import "../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
28
+ import "../../shared-utils/three/centerPoint.js";
29
+ import "../../shared-utils/three/getObjectVisible.js";
30
+ import "../../shared-utils/isNil.js";
31
+ import "../../shared-utils/three/PointSelector/utils/html.js";
32
+ import "../../shared-utils/five/initialCSS3DRender.js";
33
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
34
+ import "../../CSS3DRenderPlugin/utils/three/THREEJS_CSS3DRenderer.js";
35
+ import "../../CSS3DRenderPlugin/utils/createResizeObserver.js";
36
+ import "../../shared-utils/three/PointSelector/utils/PointHelper2.js";
37
+ import "../../Sculpt/Meshes/Line.js";
38
+ import "../../Sculpt/typings/style.js";
39
+ import "../../shared-utils/five/FiveLine.js";
40
+ import "../../shared-utils/three/IObject3D.js";
41
+ import "../../Sculpt/utils/removeAllTag.js";
42
+ import "../../Sculpt/utils/Meshes/getLengthHTML.js";
43
+ import "../../shared-utils/three/applyObjectMatrixWorld.js";
44
+ import "../../shared-utils/util.js";
45
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DSprite.js";
46
+ import "../../shared-utils/isTouchDevice.js";
47
+ import "../../shared-utils/five/getPosition.js";
48
+ import "../../shared-utils/five/getRaycasterByNdcPosition.js";
49
+ import "../../shared-utils/three/PointSelector/utils/contents.js";
21
50
  import "../../vendor/three/examples/jsm/lines/LineSegmentsGeometry.js";
22
51
  import "../../vendor/three/build/three.module.js";
23
52
  export {
@@ -52,23 +52,23 @@ import "../../../shared-utils/five/transformPosition.js";
52
52
  import "../../../shared-utils/three/temp.js";
53
53
  import "../../../shared-utils/dom/resizeObserver.js";
54
54
  import "hammerjs";
55
- import "three/examples/jsm/renderers/CSS3DRenderer";
56
- import "../../../vendor/three/examples/jsm/lines/LineGeometry.js";
57
- import "../../../vendor/three/examples/jsm/lines/LineSegmentsGeometry.js";
58
- import "../../../vendor/three/build/three.module.js";
59
- import "../../../shared-utils/three/core/Sphere.js";
60
- import "animejs";
61
- import "../../../shared-utils/isNil.js";
62
- import "../../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
63
55
  import "../../../shared-utils/three/PointSelector/index.js";
64
56
  import "../../../shared-utils/three/PointSelector/utils/PointSelectorHelper.js";
65
57
  import "../../../shared-utils/three/Magnifier.js";
66
58
  import "../../../shared-utils/three/PointSelector/utils/PointHelper.js";
67
59
  import "../../../shared-utils/three/Assets/index.js";
68
60
  import "../../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
61
+ import "three/examples/jsm/renderers/CSS3DRenderer";
69
62
  import "../../../CSS3DRenderPlugin/utils/even.js";
70
63
  import "../../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
71
64
  import "../../../shared-utils/three/getObjectVisible.js";
65
+ import "../../../vendor/three/examples/jsm/lines/LineGeometry.js";
66
+ import "../../../vendor/three/examples/jsm/lines/LineSegmentsGeometry.js";
67
+ import "../../../vendor/three/build/three.module.js";
68
+ import "../../../shared-utils/three/core/Sphere.js";
69
+ import "animejs";
70
+ import "../../../shared-utils/isNil.js";
71
+ import "../../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
72
72
  import "../../../shared-utils/three/PointSelector/utils/html.js";
73
73
  import "../../../shared-utils/five/initialCSS3DRender.js";
74
74
  import "../../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
@@ -2,6 +2,7 @@ import t from "./Controller/index.js";
2
2
  import "../shared-utils/tag.js";
3
3
  import "three";
4
4
  import { Magnifier as fr } from "../shared-utils/three/Magnifier.js";
5
+ import "../shared-utils/three/PointSelector/index.js";
5
6
  import "three/examples/jsm/renderers/CSS3DRenderer";
6
7
  import "@realsee/five/line";
7
8
  import "../vendor/three/examples/jsm/lines/LineGeometry.js";
@@ -47,9 +48,6 @@ import "../shared-utils/Utils/WorkUtil.js";
47
48
  import "../shared-utils/five/transformPosition.js";
48
49
  import "../shared-utils/three/temp.js";
49
50
  import "../shared-utils/dom/resizeObserver.js";
50
- import "../vendor/three/examples/jsm/lines/LineSegmentsGeometry.js";
51
- import "../vendor/three/build/three.module.js";
52
- import "../shared-utils/three/PointSelector/index.js";
53
51
  import "../shared-utils/three/PointSelector/utils/PointSelectorHelper.js";
54
52
  import "../shared-utils/three/PointSelector/utils/PointHelper.js";
55
53
  import "../shared-utils/three/Assets/index.js";
@@ -74,6 +72,8 @@ import "../shared-utils/isTouchDevice.js";
74
72
  import "../shared-utils/five/getPosition.js";
75
73
  import "../shared-utils/five/getRaycasterByNdcPosition.js";
76
74
  import "../shared-utils/three/PointSelector/utils/contents.js";
75
+ import "../vendor/three/examples/jsm/lines/LineSegmentsGeometry.js";
76
+ import "../vendor/three/build/three.module.js";
77
77
  import "./Modules/DeleteDom/index.js";
78
78
  import "./Modules/DeleteDom/_Assets/delete.svg.js";
79
79
  import "./Modules/DeleteDom/_Assets/delete_bg.png.js";
@@ -2,20 +2,21 @@ var u = Object.defineProperty, D = Object.defineProperties;
2
2
  var f = Object.getOwnPropertyDescriptors;
3
3
  var h = Object.getOwnPropertySymbols;
4
4
  var A = Object.prototype.hasOwnProperty, T = Object.prototype.propertyIsEnumerable;
5
- var m = (i, o, t) => o in i ? u(i, o, { enumerable: !0, configurable: !0, writable: !0, value: t }) : i[o] = t, p = (i, o) => {
5
+ var e = (i, o, t) => o in i ? u(i, o, { enumerable: !0, configurable: !0, writable: !0, value: t }) : i[o] = t, n = (i, o) => {
6
6
  for (var t in o || (o = {}))
7
- A.call(o, t) && m(i, t, o[t]);
7
+ A.call(o, t) && e(i, t, o[t]);
8
8
  if (h)
9
9
  for (var t of h(o))
10
- T.call(o, t) && m(i, t, o[t]);
10
+ T.call(o, t) && e(i, t, o[t]);
11
11
  return i;
12
12
  }, s = (i, o) => D(i, f(o));
13
- var l = (i, o, t) => (m(i, typeof o != "symbol" ? o + "" : o, t), t);
13
+ var l = (i, o, t) => (e(i, typeof o != "symbol" ? o + "" : o, t), t);
14
14
  import { ItemDom as y } from "./base.js";
15
15
  import { getGeometryInfo as I } from "../../../shared-utils/three/geometryUtil.js";
16
16
  import "../../../shared-utils/tag.js";
17
17
  import "three";
18
18
  import "hammerjs";
19
+ import "../../../shared-utils/three/PointSelector/index.js";
19
20
  import "three/examples/jsm/renderers/CSS3DRenderer";
20
21
  import "@realsee/five/line";
21
22
  import "../../../vendor/three/examples/jsm/lines/LineGeometry.js";
@@ -35,13 +36,40 @@ import "../../../shared-utils/Utils/WorkUtil.js";
35
36
  import "../../../shared-utils/five/transformPosition.js";
36
37
  import "../../../shared-utils/three/temp.js";
37
38
  import "../../../shared-utils/dom/resizeObserver.js";
39
+ import "../../../shared-utils/three/PointSelector/utils/PointSelectorHelper.js";
40
+ import "../../../shared-utils/three/Magnifier.js";
41
+ import "../../../shared-utils/three/PointSelector/utils/PointHelper.js";
42
+ import "../../../shared-utils/three/Assets/index.js";
43
+ import "../../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
44
+ import "../../../CSS3DRenderPlugin/utils/even.js";
45
+ import "../../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
46
+ import "../../../shared-utils/three/getObjectVisible.js";
47
+ import "../../../shared-utils/three/PointSelector/utils/html.js";
48
+ import "../../../shared-utils/five/initialCSS3DRender.js";
49
+ import "../../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
50
+ import "../../../CSS3DRenderPlugin/utils/three/THREEJS_CSS3DRenderer.js";
51
+ import "../../../CSS3DRenderPlugin/utils/createResizeObserver.js";
52
+ import "../../../shared-utils/three/PointSelector/utils/PointHelper2.js";
53
+ import "../../../Sculpt/Meshes/Line.js";
54
+ import "../../../Sculpt/typings/style.js";
55
+ import "../../../shared-utils/five/FiveLine.js";
56
+ import "../../../shared-utils/three/IObject3D.js";
57
+ import "../../../Sculpt/utils/removeAllTag.js";
58
+ import "../../../Sculpt/utils/Meshes/getLengthHTML.js";
59
+ import "../../../shared-utils/three/applyObjectMatrixWorld.js";
60
+ import "../../../shared-utils/util.js";
61
+ import "../../../CSS3DRenderPlugin/utils/three/CSS3DSprite.js";
62
+ import "../../../shared-utils/isTouchDevice.js";
63
+ import "../../../shared-utils/five/getPosition.js";
64
+ import "../../../shared-utils/five/getRaycasterByNdcPosition.js";
65
+ import "../../../shared-utils/three/PointSelector/utils/contents.js";
38
66
  import "../../../vendor/three/examples/jsm/lines/LineSegmentsGeometry.js";
39
67
  import "../../../vendor/three/build/three.module.js";
40
- class Y extends y {
68
+ class Ft extends y {
41
69
  constructor(t) {
42
- t.containerStyle = s(p({}, t.containerStyle), {
70
+ t.containerStyle = s(n({}, t.containerStyle), {
43
71
  zIndex: "1"
44
- }), t.contentStyle = s(p({}, t.contentStyle), {
72
+ }), t.contentStyle = s(n({}, t.contentStyle), {
45
73
  background: "#6386FF",
46
74
  borderRadius: "2px"
47
75
  });
@@ -52,21 +80,21 @@ class Y extends y {
52
80
  /**
53
81
  * @description: dom 依赖的多边形的顶点的位置更新时,更新 dom 的位置和面积
54
82
  */
55
- updateArea(t, e) {
83
+ updateArea(t, r) {
56
84
  var c, d;
57
- const n = e != null ? e : this.area.polygon.geometry, r = I(n);
58
- if (!r) {
85
+ const p = r != null ? r : this.area.polygon.geometry, m = I(p);
86
+ if (!m) {
59
87
  this.ndcPosition = null, this.updateDomPosition(t);
60
88
  return;
61
89
  }
62
- const { area: a, center: x } = r;
90
+ const { area: a, center: x } = m;
63
91
  this.ndcPosition = x, this.updateDomPosition(t), (d = (c = this.area.model) == null ? void 0 : c.config) != null && d.getAreaText ? this.contentDom.innerText = this.area.model.config.getAreaText(a) : this.updateAreaText(a, { fix: 2 });
64
92
  }
65
- updateAreaText(t, e) {
66
- const { unit: n = "m²", fix: r } = e != null ? e : {};
67
- this.contentDom.innerText = `${P(r) ? t : t.toFixed(r)}${n}`;
93
+ updateAreaText(t, r) {
94
+ const { unit: p = "m²", fix: m } = r != null ? r : {};
95
+ this.contentDom.innerText = `${P(m) ? t : t.toFixed(m)}${p}`;
68
96
  }
69
97
  }
70
98
  export {
71
- Y as AreaItem
99
+ Ft as AreaItem
72
100
  };