@realsee/dnalogel 3.45.0 → 3.46.0

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 (96) hide show
  1. package/CHANGELOG.md +3 -0
  2. package/dist/Sculpt/Meshes/Line.d.ts +6 -1
  3. package/dist/index.cjs.js +53 -53
  4. package/dist/index.js +29609 -29576
  5. package/dist/index.umd.js +49 -49
  6. package/dist/shared-utils/tag.d.ts +6 -3
  7. package/libs/AreaMakerPlugin/Controller.js +150 -78
  8. package/libs/AreaMakerPlugin/index.js +76 -4
  9. package/libs/AreaMakerPlugin/utils/Item.js +190 -111
  10. package/libs/CSS3DRenderPlugin/Controller.js +89 -29
  11. package/libs/CSS3DRenderPlugin/index.js +75 -15
  12. package/libs/CSS3DRenderPlugin/utils/three/CSS3DObject.js +132 -58
  13. package/libs/CSS3DRenderPlugin/utils/three/CSS3DRender.js +181 -116
  14. package/libs/CruisePlugin/BaseController.js +121 -49
  15. package/libs/CruisePlugin/Move.js +73 -21
  16. package/libs/CruisePlugin/Work.js +98 -46
  17. package/libs/CruisePlugin/index.js +79 -27
  18. package/libs/CurrentPanoImagePlugin/Controller.js +176 -104
  19. package/libs/CurrentPanoImagePlugin/index.js +76 -4
  20. package/libs/GuideLinePlugin/Controller.js +82 -30
  21. package/libs/GuideLinePlugin/GuideLineItem.js +82 -30
  22. package/libs/GuideLinePlugin/GuideLineModeItem/index.js +3 -2
  23. package/libs/GuideLinePlugin/GuideLineModeItem.js +81 -29
  24. package/libs/GuideLinePlugin/index.js +79 -27
  25. package/libs/ModelMakerPlugin/Controller.js +139 -82
  26. package/libs/ModelMakerPlugin/index.js +75 -18
  27. package/libs/ModelTVVideoPlugin/Plugin.js +117 -57
  28. package/libs/ModelTVVideoPlugin/index.js +68 -8
  29. package/libs/Object3DHelperPlugin/Controller.js +54 -31
  30. package/libs/Object3DHelperPlugin/index.js +35 -13
  31. package/libs/PanoCompassPlugin/Controller.js +97 -42
  32. package/libs/PanoCompassPlugin/index.js +71 -16
  33. package/libs/PanoDoorLabelPlugin/BaseController.js +98 -26
  34. package/libs/PanoDoorLabelPlugin/Controller.js +187 -115
  35. package/libs/PanoDoorLabelPlugin/index.js +76 -4
  36. package/libs/PanoMeasurePlugin/Components/Controller0.js +140 -88
  37. package/libs/PanoMeasurePlugin/Components/Controller1.js +178 -126
  38. package/libs/PanoMeasurePlugin/Controller/EditController.js +124 -72
  39. package/libs/PanoMeasurePlugin/Controller/WatchController.js +167 -92
  40. package/libs/PanoMeasurePlugin/Controller/index.js +109 -64
  41. package/libs/PanoMeasurePlugin/Model/area.js +114 -38
  42. package/libs/PanoMeasurePlugin/Modules/Magnifier.js +78 -0
  43. package/libs/PanoMeasurePlugin/Modules/UIController/index.js +97 -45
  44. package/libs/PanoMeasurePlugin/index.js +76 -31
  45. package/libs/PanoMeasurePlugin/utils/dom/areaDom.js +98 -20
  46. package/libs/PanoSpatialTagPlugin/Plugin.js +210 -150
  47. package/libs/PanoSpatialTagPlugin/index.js +66 -6
  48. package/libs/PanoTagPlugin/Components/Common/TagPoint.js +133 -53
  49. package/libs/PanoTagPlugin/Components/Tag/MarketingTag.js +295 -216
  50. package/libs/PanoTagPlugin/Components/Tag/index.js +257 -187
  51. package/libs/PanoTagPlugin/Components/TagContainer.js +157 -87
  52. package/libs/PanoTagPlugin/Components/TagItem.js +144 -74
  53. package/libs/PanoTagPlugin/controller/Tag/BaseTag.js +73 -3
  54. package/libs/PanoTagPlugin/controller/Tag/ModelTag.js +109 -39
  55. package/libs/PanoTagPlugin/controller/Tag/PlaneTag.js +105 -35
  56. package/libs/PanoTagPlugin/controller/Tag/PointTag.js +113 -43
  57. package/libs/PanoTagPlugin/controller/TagRender.js +132 -80
  58. package/libs/PanoTagPlugin/controller/TagUtil.js +136 -84
  59. package/libs/PanoTagPlugin/controller/index.js +113 -61
  60. package/libs/PanoTagPlugin/index.js +89 -37
  61. package/libs/PanoTagPlugin/utils/tag/calculateTagConfig.js +121 -41
  62. package/libs/PanoVideoPlugin/Controller.js +137 -65
  63. package/libs/PanoVideoPlugin/VideoMeshController.js +149 -69
  64. package/libs/PanoVideoPlugin/index.js +82 -10
  65. package/libs/PipelinePlugin/Controller.js +199 -128
  66. package/libs/PipelinePlugin/index.js +76 -5
  67. package/libs/PipelinePlugin/utils/Objects/FlowPipe.js +102 -22
  68. package/libs/PipelinePlugin/utils/Objects/HighlightPipe.js +95 -15
  69. package/libs/PipelinePlugin/utils/Objects/Pipe.js +136 -56
  70. package/libs/Sculpt/Meshes/Box.js +6 -5
  71. package/libs/Sculpt/Meshes/Cylinder.js +7 -6
  72. package/libs/Sculpt/Meshes/Line.d.ts +6 -1
  73. package/libs/Sculpt/Meshes/Line.js +76 -56
  74. package/libs/Sculpt/Meshes/Point.js +6 -5
  75. package/libs/Sculpt/Meshes/Polyline.js +5 -4
  76. package/libs/Sculpt/Meshes/Rectangle.js +3 -2
  77. package/libs/Sculpt/Objects/Line/Editor.js +11 -10
  78. package/libs/Sculpt/utils/three/ColoredMesh.js +14 -13
  79. package/libs/base/BasePlugin.js +14 -13
  80. package/libs/floorplan/MapviewFloorplanPlugin/Controller.js +128 -59
  81. package/libs/floorplan/MapviewFloorplanPlugin/index.js +75 -6
  82. package/libs/floorplan/ModelFloorplanPlugin/Controller.js +129 -59
  83. package/libs/floorplan/ModelFloorplanPlugin/index.js +75 -5
  84. package/libs/floorplan/PanoFloorplanRadarPlugin/Controller.js +158 -86
  85. package/libs/floorplan/PanoFloorplanRadarPlugin/index.js +76 -4
  86. package/libs/floorplan/TopviewFloorplanPlugin/Controller.js +151 -81
  87. package/libs/floorplan/TopviewFloorplanPlugin/index.js +75 -5
  88. package/libs/floorplan/index.js +1 -0
  89. package/libs/index.js +67 -67
  90. package/libs/shared-utils/five/index.js +3 -2
  91. package/libs/shared-utils/five/lookObject.js +3 -2
  92. package/libs/shared-utils/logger.js +1 -1
  93. package/libs/shared-utils/tag.d.ts +6 -3
  94. package/libs/shared-utils/tag.js +38 -24
  95. package/libs/shared-utils/three/index.js +1 -0
  96. package/package.json +1 -1
@@ -1,6 +1,6 @@
1
1
  var I = Object.defineProperty;
2
- var R = (c, r, e) => r in c ? I(c, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : c[r] = e;
3
- var s = (c, r, e) => (R(c, typeof r != "symbol" ? r + "" : r, e), e);
2
+ var R = (p, h, t) => h in p ? I(p, h, { enumerable: !0, configurable: !0, writable: !0, value: t }) : p[h] = t;
3
+ var o = (p, h, t) => (R(p, typeof h != "symbol" ? h + "" : h, 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";
@@ -32,137 +32,212 @@ import "../Model/polyline.js";
32
32
  import "../utils/dom/areaDom.js";
33
33
  import "../../shared-utils/three/geometryUtil.js";
34
34
  import "three/examples/jsm/renderers/CSS3DRenderer";
35
+ import "../../Sculpt/utils/Modules/Global.js";
36
+ import "../../Sculpt/utils/Modules/Cursor.js";
37
+ import "../../Object3DHelperPlugin/Controller.js";
38
+ import "../../base/BasePlugin.js";
39
+ import "../../shared-utils/Subscribe.js";
35
40
  import "../../shared-utils/three/THREESphere.js";
36
41
  import "animejs";
37
- import "../../shared-utils/isNil.js";
42
+ import "../../shared-utils/Utils/FiveUtil.js";
43
+ import "../../shared-utils/Utils/BaseUtil.js";
44
+ import "../../shared-utils/Utils/WorkUtil.js";
45
+ import "../../shared-utils/five/transformPosition.js";
46
+ import "../../shared-utils/url/absoluteUrl.js";
38
47
  import "../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
48
+ import "../../shared-utils/Object3DHelper/Helper/MoveHelper.js";
49
+ import "../../shared-utils/Object3DHelper/Base/BaseHelper.js";
50
+ import "../../shared-utils/Object3DHelper/utils/setObjectQuaternion.js";
39
51
  import "../../shared-utils/three/IObject3D.js";
52
+ import "../../shared-utils/three/boundingBox.js";
53
+ import "../../shared-utils/Object3DHelper/Helper/Objects/ArrowGroup.js";
54
+ import "../../shared-utils/Object3DHelper/utils/direction.js";
55
+ import "../../shared-utils/Object3DHelper/Constants/color.js";
56
+ import "../../shared-utils/Object3DHelper/utils/calculateScaleByCamera.js";
57
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DRender.js";
58
+ import "../../shared-utils/positionToVector3.js";
59
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
60
+ import "../../CSS3DRenderPlugin/utils/three/THREEJS_CSS3DRenderer.js";
61
+ import "../../CSS3DRenderPlugin/utils/createResizeObserver.js";
62
+ import "../../CSS3DRenderPlugin/utils/even.js";
63
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
64
+ import "../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
65
+ import "../../shared-utils/three/getObjectVisible.js";
66
+ import "../../shared-utils/isNil.js";
67
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DScene.js";
68
+ import "../../CSS3DRenderPlugin/utils/getAllCSS3DObject.js";
69
+ import "../../shared-utils/util.js";
70
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DGroup.js";
71
+ import "../../shared-utils/Object3DHelper/Helper/RotateHelper.js";
72
+ import "../../shared-utils/Object3DHelper/Helper/HTML/tipsDom.js";
73
+ import "../../shared-utils/Object3DHelper/Helper/HTML/utils/createElement.js";
74
+ import "../../shared-utils/Object3DHelper/Helper/CSS3DScaleHelper.js";
75
+ import "../../shared-utils/Object3DHelper/Helper/HTML/rectangleScaleDom.js";
76
+ import "../../shared-utils/Object3DHelper/Helper/BoundingBoxHelper.js";
77
+ import "../../shared-utils/Object3DHelper/Controller/MoveController.js";
78
+ import "../../shared-utils/Object3DHelper/Base/BaseController.js";
79
+ import "../../shared-utils/threex/domevents/index.js";
80
+ import "../../shared-utils/Object3DHelper/utils/getMouseRaycaster.js";
81
+ import "../../shared-utils/Object3DHelper/utils/calculateThreeMouse.js";
82
+ import "../../Sculpt/utils/three/rayOnLine.js";
83
+ import "../../Object3DHelperPlugin/FiveControllerWrapper.js";
84
+ import "../../shared-utils/Object3DHelper/index.js";
85
+ import "../../shared-utils/Object3DHelper/Controller/RotateController.js";
86
+ import "../../shared-utils/math/rad2Deg.js";
87
+ import "../../shared-utils/math/deg2Rad.js";
88
+ import "../../shared-utils/Object3DHelper/Controller/CSS3DScaleController.js";
89
+ import "../../shared-utils/Object3DHelper/Controller/RectangleScaleController.js";
90
+ import "../../shared-utils/Object3DHelper/utils/vectorIsEqual.js";
91
+ import "../../CSS3DRenderPlugin/utils/generateBehindFiveElement.js";
92
+ import "../../shared-utils/Object3DHelper/Controller/BoundingBoxController.js";
93
+ import "../../shared-utils/Object3DHelper/Helper/ScaleHelper.js";
94
+ import "../../shared-utils/Object3DHelper/Controller/ScaleController.js";
95
+ import "../../shared-utils/five/fiveModelLoad.js";
96
+ import "../../shared-utils/five/FiveDomEvents.js";
97
+ import "../../shared-utils/five/calculateThreeMouse.js";
98
+ import "../../shared-utils/three/THREERaycaster.js";
99
+ import "../../shared-utils/three/PointSelector/index.js";
100
+ import "../../shared-utils/three/PointSelector/utils/PointSelectorHelper.js";
101
+ import "../../shared-utils/three/Magnifier.js";
102
+ import "../../shared-utils/three/PointSelector/utils/PointHelper.js";
103
+ import "../../shared-utils/three/Assets/index.js";
104
+ import "../../shared-utils/three/PointSelector/utils/html.js";
105
+ import "../../shared-utils/five/initialCSS3DRender.js";
106
+ import "../../shared-utils/three/PointSelector/utils/PointHelper2.js";
107
+ import "../../Sculpt/Meshes/Line.js";
108
+ import "../../Sculpt/typings/style.js";
109
+ import "../../shared-utils/tag.js";
110
+ import "../../shared-utils/five/vector3ToScreen.js";
111
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DSprite.js";
112
+ import "../../shared-utils/isTouchDevice.js";
113
+ import "../../shared-utils/five/getPosition.js";
114
+ import "../../shared-utils/five/getRaycasterByNdcPosition.js";
40
115
  import "../../shared-utils/three/generatePolygonGeometry.js";
41
116
  import "../../shared-utils/three/earcut3D.js";
42
117
  import "earcut";
43
118
  import "../../shared-utils/three/getNormal.js";
44
119
  const E = () => !1;
45
- class He extends U {
46
- constructor(e) {
47
- super(e);
48
- s(this, "type", "watch");
49
- s(this, "deleteDom");
50
- s(this, "choose");
120
+ class Ke extends U {
121
+ constructor(t) {
122
+ super(t);
123
+ o(this, "type", "watch");
124
+ o(this, "deleteDom");
125
+ o(this, "choose");
51
126
  // tmd 真没时间改了,先这样吧,理解万岁
52
- s(this, "highlightedLines", []);
53
- s(this, "highlightedArea");
54
- s(this, "fiveElement");
55
- s(this, "editPointState");
56
- s(this, "hammer");
57
- s(this, "onPanStart", (e) => {
58
- var p;
127
+ o(this, "highlightedLines", []);
128
+ o(this, "highlightedArea");
129
+ o(this, "fiveElement");
130
+ o(this, "editPointState");
131
+ o(this, "hammer");
132
+ o(this, "onPanStart", (t) => {
133
+ var l;
59
134
  if (this.model.getAllLines().length === 0 || !this.fiveElement)
60
135
  return;
61
- const i = C(e).point, t = (p = j(this.five, this.model.getAllPoints(), i, 20)) == null ? void 0 : p.point;
62
- if (!t) {
136
+ const i = C(t).point, e = (l = j(this.five, this.model.getAllPoints(), i, 20)) == null ? void 0 : l.point;
137
+ if (!e) {
63
138
  this.editPointState = void 0;
64
139
  return;
65
140
  }
66
- const n = this.model.polylines.find((a) => a.includes(t)), l = {
67
- point: t,
141
+ const n = this.model.polylines.find((a) => a.includes(e)), m = {
142
+ point: e,
68
143
  associatedLines: n.lines
69
144
  };
70
145
  this.hook.emit("wantsDragLine", {
71
- point: t.id,
72
- lines: l.associatedLines.map(({ id: a }) => a)
73
- }) || (this.editPointState = l, this.magnifier.appendTo(this.container), this.magnifier.enable(), this.group.add(this.mouseGroup));
146
+ point: e.id,
147
+ lines: m.associatedLines.map(({ id: a }) => a)
148
+ }) || (this.editPointState = m, this.magnifier.appendTo(this.container), this.magnifier.enable(), this.group.add(this.mouseGroup));
74
149
  });
75
- s(this, "onPanEnd", () => {
76
- this.editPointState && (this.editPointState.associatedLines.forEach((e) => e.mesh.setMaterial({ dashed: !1 })), this.highlightLines(this.editPointState.associatedLines), this.editPointState = void 0, this.magnifier.disable(), this.group.remove(this.mouseGroup));
150
+ o(this, "onPanEnd", () => {
151
+ 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));
77
152
  });
78
- s(this, "onPan", (e) => {
153
+ o(this, "onPan", (t) => {
79
154
  if (!this.editPointState || !this.fiveElement)
80
155
  return;
81
- const i = C(e).ndcPoint, t = new M();
82
- t.setFromCamera(i, this.five.camera);
83
- const [n] = D(this.five).intersectRaycaster(t);
156
+ const i = C(t).ndcPoint, e = new M();
157
+ e.setFromCamera(i, this.five.camera);
158
+ const [n] = D(this.five).intersectRaycaster(e);
84
159
  n && this.onIntersectionUpdate(n);
85
160
  });
86
- s(this, "onIntersectionUpdate", (e, i) => {
161
+ o(this, "onIntersectionUpdate", (t, i) => {
87
162
  if (this.editPointState) {
88
- if (this.clearHighlightLines(), this.editPointState.point.position.copy(e.point), this.editPointState.associatedLines.forEach((t) => {
89
- t.mesh.setPoints(t.points[0].position.clone(), t.points[1].position.clone()), t.lightMesh.setPoints(t.points[0].position.clone(), t.points[1].position.clone()), t.mesh.setMaterial({ dashed: !0 });
90
- }), this.updateDistanceUI(), this.magnifier.renderWithPoint(e.point), this.mouseGroup.position.copy(e.point), i)
163
+ if (this.clearHighlightLines(), this.editPointState.point.position.copy(t.point), this.editPointState.associatedLines.forEach((e) => {
164
+ 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 });
165
+ }), this.updateDistanceUI(), this.magnifier.renderWithPoint(t.point), this.mouseGroup.position.copy(t.point), i)
91
166
  this.mouseGroup.quaternion.copy(i.quaternion);
92
- else if (e.face) {
93
- const n = e.face.normal.clone().multiplyScalar(0.05), d = e.point.clone().add(n).clone().add(n);
94
- this.mouseGroup.lookAt(d);
167
+ else if (t.face) {
168
+ const n = t.face.normal.clone().multiplyScalar(0.05), c = t.point.clone().add(n).clone().add(n);
169
+ this.mouseGroup.lookAt(c);
95
170
  }
96
171
  this.five.needsRender = !0, this.hook.emit(
97
172
  "selectedChange",
98
- this.editPointState.associatedLines.map((t) => t)
173
+ this.editPointState.associatedLines.map((e) => e)
99
174
  );
100
175
  }
101
176
  });
102
- s(this, "wantsPanGesture", () => {
177
+ o(this, "wantsPanGesture", () => {
103
178
  if (this.editPointState)
104
179
  return !1;
105
180
  });
106
- s(this, "wantsTapGesture", (e) => {
181
+ o(this, "wantsTapGesture", (t) => {
107
182
  var S;
108
- const i = this.model.areas.map((o) => e.intersectObject(o.polygon, !0)[0]).sort((o, h) => o.distance - h.distance), t = (S = i[0]) == null ? void 0 : S.object.parent;
109
- if (t instanceof F) {
110
- const o = this.model.areas.find((h) => h.polygon === t);
111
- if (o) {
112
- const { x: h, y: u } = i[0].point.clone().project(this.five.camera), m = `${(h + 1) / 2 * 100}%`, g = `${(-u + 1) / 2 * 100}%`;
113
- return this.chooseArea(o, { left: m, top: g }), !1;
183
+ const i = this.model.areas.map((s) => t.intersectObject(s.polygon, !0)[0]).sort((s, r) => s.distance - r.distance), e = (S = i[0]) == null ? void 0 : S.object.parent;
184
+ if (e instanceof F) {
185
+ const s = this.model.areas.find((r) => r.polygon === e);
186
+ if (s) {
187
+ const { x: r, y: u } = i[0].point.clone().project(this.five.camera), d = `${(r + 1) / 2 * 100}%`, g = `${(-u + 1) / 2 * 100}%`;
188
+ return this.chooseArea(s, { left: d, top: g }), !1;
114
189
  }
115
190
  }
116
- const n = D(this.five), [l] = n.intersectRaycaster(e);
117
- if (!l)
191
+ const n = D(this.five), [m] = n.intersectRaycaster(t);
192
+ if (!m)
118
193
  return;
119
- 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) => {
120
- const [h, u] = o.points, m = h.position.clone().project(d), g = u.position.clone().project(d);
121
- if (!w(m) && !w(g))
194
+ const c = this.five.camera, l = m.point.clone().project(c), a = this.container.clientWidth, f = this.container.clientHeight, P = new L(l.x * a, l.y * f), v = this.model.getAllLines().map((s) => {
195
+ const [r, u] = s.points, d = r.position.clone().project(c), g = u.position.clone().project(c);
196
+ if (!w(d) && !w(g))
122
197
  return null;
123
- const H = new L(m.x * a, m.y * f), k = new L(g.x * a, g.y * f);
124
- return { id: o.id, points: [H, k] };
125
- }).filter((o) => !!o);
198
+ const H = new L(d.x * a, d.y * f), k = new L(g.x * a, g.y * f);
199
+ return { id: s.id, points: [H, k] };
200
+ }).filter((s) => !!s);
126
201
  if (v.length === 0)
127
202
  return;
128
- const y = v.map((o) => {
129
- const h = b(P, o.points);
130
- return { id: o.id, distance: h.distanceTo(P) };
131
- }).sort((o, h) => o.distance - h.distance)[0];
203
+ const y = v.map((s) => {
204
+ const r = b(P, s.points);
205
+ return { id: s.id, distance: r.distanceTo(P) };
206
+ }).sort((s, r) => s.distance - r.distance)[0];
132
207
  if (y.distance > 20)
133
208
  return;
134
- const A = this.model.getAllLines().find(({ id: o }) => o === y.id);
209
+ const A = this.model.getAllLines().find(({ id: s }) => s === y.id);
135
210
  if (A)
136
211
  return this.chooseLine(A), !1;
137
212
  });
138
- s(this, "chooseLine", (e) => {
213
+ o(this, "chooseLine", (t) => {
139
214
  this.choose = "line";
140
- const i = e.getPolyline().lines;
215
+ const i = t.getPolyline().lines;
141
216
  this.deleteDom.setLines(i).updatePosition().show(), this.highlightLines(i), this.five.needsRender = !0, this.hook.emit(
142
217
  "selectedChange",
143
- i.map((t) => t)
218
+ i.map((e) => e)
144
219
  );
145
220
  });
146
- s(this, "chooseArea", (e, i) => {
147
- this.choose = e, this.deleteDom.updatePosition(i.left, `calc(${i.top} - 20px)`).show(), this.highlightArea(e);
221
+ o(this, "chooseArea", (t, i) => {
222
+ this.choose = t, this.deleteDom.updatePosition(i.left, `calc(${i.top} - 20px)`).show(), this.highlightArea(t);
148
223
  });
149
- s(this, "polylineRemoved", (e) => {
150
- e.lines.forEach((i) => this.removeLine(i)), this.hook.emit(
224
+ o(this, "polylineRemoved", (t) => {
225
+ t.lines.forEach((i) => this.removeLine(i)), this.hook.emit(
151
226
  "selectedChange",
152
227
  this.model.getAllLines().filter((i) => i.selected).map((i) => i)
153
228
  );
154
229
  });
155
- s(this, "onCameraUpdate", () => {
230
+ o(this, "onCameraUpdate", () => {
156
231
  this.updateDistanceUI(), this.highlightedLines.length > 0 && this.deleteDom.updatePosition();
157
232
  });
158
- s(this, "deleteArea", (e) => {
159
- this.unHighlightArea(e), e.dispose(), this.deleteDom.hide();
233
+ o(this, "deleteArea", (t) => {
234
+ this.unHighlightArea(t), t.dispose(), this.deleteDom.hide();
160
235
  });
161
- s(this, "deleteLine", () => {
162
- const e = this.highlightedLines[0], i = this.model.getPolylineByLine(e);
236
+ o(this, "deleteLine", () => {
237
+ const t = this.highlightedLines[0], i = this.model.getPolylineByLine(t);
163
238
  i && (this.model.removePolyline(i), this.highlightedLines = [], this.deleteDom.setLines([]).hide());
164
239
  });
165
- s(this, "cancelDeleteClickCallback", () => {
240
+ o(this, "cancelDeleteClickCallback", () => {
166
241
  this.deleteDom.hide(), this.clearHighlightLines(), this.unHighlightArea();
167
242
  });
168
243
  this.deleteDom = new T(this.five, {
@@ -171,49 +246,49 @@ class He extends U {
171
246
  this.choose === "line" ? this.deleteLine() : this.choose instanceof x && this.deleteArea(this.choose);
172
247
  },
173
248
  cancel: this.cancelDeleteClickCallback
174
- }).appendTo(this.container), this.model.getAllLines().forEach((t) => {
175
- t.distanceItem.appendTo(this.container), t.distanceItem.update(this.five), t.hook.on("selected", this.chooseLine), t.distanceItem.setCanSelect(!0), this.group.add(t.mesh);
176
- }), this.model.getAllAreas().forEach((t) => {
177
- t.areaItem.appendTo(this.container), t.areaItem.updateArea(this.five), t.hook.on("selected", this.chooseArea), t.areaItem.setCanSelect(!0), this.group.add(t.polygon), t.polyline.lines.forEach((n) => {
249
+ }).appendTo(this.container), this.model.getAllLines().forEach((e) => {
250
+ e.distanceItem.appendTo(this.container), e.distanceItem.update(this.five), e.hook.on("selected", this.chooseLine), e.distanceItem.setCanSelect(!0), this.group.add(e.mesh);
251
+ }), this.model.getAllAreas().forEach((e) => {
252
+ e.areaItem.appendTo(this.container), e.areaItem.updateArea(this.five), e.hook.on("selected", this.chooseArea), e.areaItem.setCanSelect(!0), this.group.add(e.polygon), e.polyline.lines.forEach((n) => {
178
253
  n.distanceItem.appendTo(this.container), n.distanceItem.update(this.five), this.group.add(n.mesh);
179
254
  });
180
255
  });
181
256
  const i = this.five.getElement();
182
257
  if (i) {
183
258
  this.fiveElement = i;
184
- const t = new G(i);
185
- this.hammer = t, t.on("pan", this.onPan), t.on("panstart", this.onPanStart), t.on("panend", this.onPanEnd);
259
+ const e = new G(i);
260
+ this.hammer = e, e.on("pan", this.onPan), e.on("panstart", this.onPanStart), e.on("panend", this.onPanEnd);
186
261
  }
187
262
  this.updateDistanceUI(), this.five.needsRender = !0, this.five.on("cameraUpdate", this.onCameraUpdate), this.five.on("wantsTapGesture", this.wantsTapGesture), this.five.on("wantsPanGesture", this.wantsPanGesture), this.five.on("wantsChangeMode", E), this.model.hook.on("polylineRemoved", this.polylineRemoved);
188
263
  }
189
264
  dispose() {
190
- var e;
191
- super.dispose(), this.deleteDom.dispose(), this.model.hook.off("polylineRemoved", this.polylineRemoved), this.model.getAllLines().forEach((i) => i.hook.off("selected", this.chooseLine)), this.five.off("cameraUpdate", this.onCameraUpdate), this.five.off("wantsPanGesture", this.wantsPanGesture), this.five.off("wantsTapGesture", this.wantsTapGesture), this.five.off("wantsChangeMode", E), this.five.needsRender = !0, this.hook.emit("selectedChange", []), (e = this.hammer) == null || e.destroy();
265
+ var t;
266
+ super.dispose(), this.deleteDom.dispose(), this.model.hook.off("polylineRemoved", this.polylineRemoved), this.model.getAllLines().forEach((i) => i.hook.off("selected", this.chooseLine)), this.five.off("cameraUpdate", this.onCameraUpdate), this.five.off("wantsPanGesture", this.wantsPanGesture), this.five.off("wantsTapGesture", this.wantsTapGesture), this.five.off("wantsChangeMode", E), this.five.needsRender = !0, this.hook.emit("selectedChange", []), (t = this.hammer) == null || t.destroy();
192
267
  }
193
- highlightLine(e) {
194
- e.selected || (e.selected = !0, this.group.add(e.lightMesh), e.distanceItem.highlight(), this.five.needsRender = !0);
268
+ highlightLine(t) {
269
+ t.selected || (t.selected = !0, this.group.add(t.lightMesh), t.distanceItem.highlight(), this.five.needsRender = !0);
195
270
  }
196
271
  clearHighlightLines() {
197
272
  this.group.children.length !== 0 && (this.unHighlightLines(this.highlightedLines), this.highlightedLines = []);
198
273
  }
199
- highlightArea(e) {
200
- this.unHighlightLines(), this.unHighlightArea(), this.highlightLines(e.polyline.lines), this.five.needsRender = !0;
274
+ highlightArea(t) {
275
+ this.unHighlightLines(), this.unHighlightArea(), this.highlightLines(t.polyline.lines), this.five.needsRender = !0;
201
276
  }
202
- unHighlightArea(e) {
203
- const i = e != null ? e : this.highlightedArea;
277
+ unHighlightArea(t) {
278
+ const i = t != null ? t : this.highlightedArea;
204
279
  i && (this.unHighlightLines(i.polyline.lines), this.five.needsRender = !0);
205
280
  }
206
- highlightLines(e) {
207
- this.unHighlightLines(), this.highlightedLines = e, e.forEach((i) => this.highlightLine(i));
281
+ highlightLines(t) {
282
+ this.unHighlightLines(), this.highlightedLines = t, t.forEach((i) => this.highlightLine(i));
208
283
  }
209
- unHighlightLines(e) {
284
+ unHighlightLines(t) {
210
285
  this.unHighlightArea();
211
- const i = e != null ? e : this.highlightedLines;
212
- i && i.forEach((t) => {
213
- t.selected = !1, t.distanceItem.unHighlight(), this.group.remove(t.lightMesh), this.five.needsRender = !0;
286
+ const i = t != null ? t : this.highlightedLines;
287
+ i && i.forEach((e) => {
288
+ e.selected = !1, e.distanceItem.unHighlight(), this.group.remove(e.lightMesh), this.five.needsRender = !0;
214
289
  });
215
290
  }
216
291
  }
217
292
  export {
218
- He as default
293
+ Ke as default
219
294
  };