@realsee/dnalogel 3.43.0 → 3.44.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 (158) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/dist/CSS3DRenderPlugin/utils/three/CSS3DObject.d.ts +4 -2
  3. package/dist/CSS3DRenderPlugin/utils/three/CSS3DRenderer.d.ts +2 -1
  4. package/dist/CSS3DRenderPlugin/utils/three/CSS3DSprite.d.ts +4 -0
  5. package/dist/PanoMeasurePlugin/Controller/BaseController.d.ts +6 -1
  6. package/dist/PanoMeasurePlugin/Controller/EditController.d.ts +1 -1
  7. package/dist/PanoMeasurePlugin/Controller/index.d.ts +2 -0
  8. package/dist/Sculpt/Meshes/Line.d.ts +19 -1
  9. package/dist/Sculpt/utils/color.d.ts +1 -1
  10. package/dist/index.cjs.js +102 -68
  11. package/dist/index.js +7374 -7116
  12. package/dist/index.umd.js +106 -72
  13. package/dist/shared-utils/five/getPosition.d.ts +12 -4
  14. package/dist/shared-utils/five/initialCSS3DRender.d.ts +2 -0
  15. package/dist/shared-utils/math/deg2Rad.d.ts +1 -1
  16. package/dist/shared-utils/math/rad2Deg.d.ts +1 -1
  17. package/dist/shared-utils/positionToVector3.d.ts +6 -6
  18. package/{libs/shared-utils/three/PointSelector.d.ts → dist/shared-utils/three/PointSelector/index.d.ts} +23 -7
  19. package/dist/shared-utils/three/{PointHelper.d.ts → PointSelector/utils/PointHelper.d.ts} +11 -3
  20. package/dist/shared-utils/three/PointSelector/utils/PointHelper2.d.ts +30 -0
  21. package/dist/shared-utils/three/{PointSelectorHelper.d.ts → PointSelector/utils/PointSelectorHelper.d.ts} +9 -10
  22. package/dist/shared-utils/three/PointSelector/utils/typing.d.ts +8 -0
  23. package/dist/shared-utils/three/index.d.ts +2 -3
  24. package/libs/AreaMakerPlugin/Controller.js +5 -18
  25. package/libs/AreaMakerPlugin/index.js +4 -17
  26. package/libs/AreaMakerPlugin/utils/Item.js +13 -26
  27. package/libs/CSS3DRenderPlugin/Controller.js +9 -6
  28. package/libs/CSS3DRenderPlugin/index.js +12 -9
  29. package/libs/CSS3DRenderPlugin/utils/getAllCSS3DObject.js +6 -6
  30. package/libs/CSS3DRenderPlugin/utils/three/CSS3DObject.d.ts +4 -2
  31. package/libs/CSS3DRenderPlugin/utils/three/CSS3DObject.js +73 -56
  32. package/libs/CSS3DRenderPlugin/utils/three/CSS3DRender.js +11 -4
  33. package/libs/CSS3DRenderPlugin/utils/three/CSS3DRenderer.d.ts +2 -1
  34. package/libs/CSS3DRenderPlugin/utils/three/CSS3DRenderer.js +14 -14
  35. package/libs/CSS3DRenderPlugin/utils/three/CSS3DSprite.d.ts +4 -0
  36. package/libs/CSS3DRenderPlugin/utils/three/CSS3DSprite.js +13 -0
  37. package/libs/CSS3DRenderPlugin/utils/three/THREEJS_CSS3DRenderer.js +85 -0
  38. package/libs/CruisePlugin/BaseController.js +20 -33
  39. package/libs/CruisePlugin/Move.js +25 -23
  40. package/libs/CruisePlugin/Work.js +10 -8
  41. package/libs/CruisePlugin/index.js +23 -21
  42. package/libs/CurrentPanoImagePlugin/Controller.js +30 -43
  43. package/libs/CurrentPanoImagePlugin/index.js +5 -18
  44. package/libs/GuideLinePlugin/Controller.js +15 -13
  45. package/libs/GuideLinePlugin/GuideLineItem.js +19 -17
  46. package/libs/GuideLinePlugin/GuideLineModeItem/index.js +4 -5
  47. package/libs/GuideLinePlugin/GuideLineModeItem.js +21 -19
  48. package/libs/GuideLinePlugin/index.js +23 -21
  49. package/libs/ModelMakerPlugin/Controller.js +19 -30
  50. package/libs/ModelMakerPlugin/index.js +11 -22
  51. package/libs/ModelTVVideoPlugin/Plugin.js +13 -10
  52. package/libs/ModelTVVideoPlugin/index.js +12 -9
  53. package/libs/Object3DHelperPlugin/Controller.js +7 -5
  54. package/libs/Object3DHelperPlugin/index.js +23 -21
  55. package/libs/PanoCompassPlugin/Controller.js +18 -15
  56. package/libs/PanoCompassPlugin/index.js +21 -18
  57. package/libs/PanoDoorLabelPlugin/BaseController.js +24 -37
  58. package/libs/PanoDoorLabelPlugin/Controller.js +56 -69
  59. package/libs/PanoDoorLabelPlugin/index.js +5 -18
  60. package/libs/PanoMeasurePlugin/Components/Controller0.js +40 -47
  61. package/libs/PanoMeasurePlugin/Components/Controller1.js +72 -79
  62. package/libs/PanoMeasurePlugin/Controller/BaseController.d.ts +6 -1
  63. package/libs/PanoMeasurePlugin/Controller/BaseController.js +53 -39
  64. package/libs/PanoMeasurePlugin/Controller/EditController.d.ts +1 -1
  65. package/libs/PanoMeasurePlugin/Controller/EditController.js +177 -153
  66. package/libs/PanoMeasurePlugin/Controller/MixedController.js +1 -1
  67. package/libs/PanoMeasurePlugin/Controller/WatchController.js +60 -74
  68. package/libs/PanoMeasurePlugin/Controller/index.d.ts +2 -0
  69. package/libs/PanoMeasurePlugin/Controller/index.js +59 -60
  70. package/libs/PanoMeasurePlugin/Model/area.js +30 -44
  71. package/libs/PanoMeasurePlugin/Modules/Magnifier.js +3 -16
  72. package/libs/PanoMeasurePlugin/Modules/UIController/index.js +42 -49
  73. package/libs/PanoMeasurePlugin/Modules/rangePiece/index.js +1 -1
  74. package/libs/PanoMeasurePlugin/index.js +35 -40
  75. package/libs/PanoMeasurePlugin/utils/dom/areaDom.js +23 -36
  76. package/libs/PanoSpatialTagPlugin/Plugin.js +41 -38
  77. package/libs/PanoSpatialTagPlugin/index.js +10 -7
  78. package/libs/PanoTagPlugin/Components/Common/TagPoint.js +29 -43
  79. package/libs/PanoTagPlugin/Components/Tag/MarketingTag.js +55 -69
  80. package/libs/PanoTagPlugin/Components/Tag/index.js +9 -19
  81. package/libs/PanoTagPlugin/Components/TagContainer.js +42 -52
  82. package/libs/PanoTagPlugin/Components/TagItem.js +9 -19
  83. package/libs/PanoTagPlugin/controller/Tag/BaseTag.js +23 -33
  84. package/libs/PanoTagPlugin/controller/Tag/ModelTag.js +29 -39
  85. package/libs/PanoTagPlugin/controller/Tag/PlaneTag.js +11 -21
  86. package/libs/PanoTagPlugin/controller/Tag/PointTag.js +18 -28
  87. package/libs/PanoTagPlugin/controller/TagRender.js +18 -16
  88. package/libs/PanoTagPlugin/controller/TagUtil.js +12 -9
  89. package/libs/PanoTagPlugin/controller/index.js +27 -25
  90. package/libs/PanoTagPlugin/index.js +28 -26
  91. package/libs/PanoTagPlugin/utils/tag/calculateTagConfig.js +43 -57
  92. package/libs/PanoVideoPlugin/Controller.js +52 -65
  93. package/libs/PanoVideoPlugin/VideoMeshController.js +11 -25
  94. package/libs/PanoVideoPlugin/index.js +8 -21
  95. package/libs/PipelinePlugin/Controller.js +44 -57
  96. package/libs/PipelinePlugin/index.js +5 -18
  97. package/libs/PipelinePlugin/utils/Objects/FlowPipe.js +20 -34
  98. package/libs/PipelinePlugin/utils/Objects/HighlightPipe.js +16 -30
  99. package/libs/PipelinePlugin/utils/Objects/Pipe.js +39 -53
  100. package/libs/Sculpt/Meshes/Box.js +3 -3
  101. package/libs/Sculpt/Meshes/Cylinder.js +14 -14
  102. package/libs/Sculpt/Meshes/Line.d.ts +19 -1
  103. package/libs/Sculpt/Meshes/Line.js +40 -41
  104. package/libs/Sculpt/Meshes/LineWithDots.js +5 -6
  105. package/libs/Sculpt/Meshes/Point.js +3 -3
  106. package/libs/Sculpt/Meshes/Polyline.js +3 -3
  107. package/libs/Sculpt/Meshes/Prism.js +11 -12
  108. package/libs/Sculpt/Meshes/Rectangle.js +3 -3
  109. package/libs/Sculpt/Objects/Point/Editor.js +10 -10
  110. package/libs/Sculpt/Objects/Polygon/Editor.js +6 -6
  111. package/libs/Sculpt/Objects/Polyline/Editor.js +4 -4
  112. package/libs/Sculpt/index.js +3 -3
  113. package/libs/Sculpt/utils/Modules/Global.js +1 -1
  114. package/libs/Sculpt/utils/color.d.ts +1 -1
  115. package/libs/Sculpt/utils/three/ColoredMesh.js +3 -3
  116. package/libs/base/BasePlugin.js +4 -4
  117. package/libs/floorplan/Components/Compass.js +29 -31
  118. package/libs/floorplan/MapviewFloorplanPlugin/Controller.js +9 -22
  119. package/libs/floorplan/MapviewFloorplanPlugin/index.js +6 -19
  120. package/libs/floorplan/ModelFloorplanPlugin/Controller.js +5 -18
  121. package/libs/floorplan/ModelFloorplanPlugin/index.js +5 -18
  122. package/libs/floorplan/PanoFloorplanRadarPlugin/Controller.js +48 -61
  123. package/libs/floorplan/PanoFloorplanRadarPlugin/index.js +5 -18
  124. package/libs/floorplan/TopviewFloorplanPlugin/Controller.js +28 -41
  125. package/libs/floorplan/TopviewFloorplanPlugin/index.js +5 -18
  126. package/libs/floorplan/index.js +3 -3
  127. package/libs/index.js +140 -137
  128. package/libs/shared-utils/five/getPosition.d.ts +12 -4
  129. package/libs/shared-utils/five/getPosition.js +23 -23
  130. package/libs/shared-utils/five/index.js +2 -2
  131. package/libs/shared-utils/five/initialCSS3DRender.d.ts +2 -0
  132. package/libs/shared-utils/five/initialCSS3DRender.js +17 -0
  133. package/libs/shared-utils/five/lookObject.js +3 -3
  134. package/libs/shared-utils/index.js +38 -40
  135. package/libs/shared-utils/logger.js +1 -1
  136. package/libs/shared-utils/math/deg2Rad.d.ts +1 -1
  137. package/libs/shared-utils/math/rad2Deg.d.ts +1 -1
  138. package/libs/shared-utils/positionToVector3.d.ts +6 -6
  139. package/{dist/shared-utils/three/PointSelector.d.ts → libs/shared-utils/three/PointSelector/index.d.ts} +23 -7
  140. package/libs/shared-utils/three/{PointSelector.js → PointSelector/index.js} +54 -45
  141. package/libs/shared-utils/three/{PointHelper.d.ts → PointSelector/utils/PointHelper.d.ts} +11 -3
  142. package/libs/shared-utils/three/PointSelector/utils/PointHelper.js +95 -0
  143. package/libs/shared-utils/three/PointSelector/utils/PointHelper2.d.ts +30 -0
  144. package/libs/shared-utils/three/PointSelector/utils/PointHelper2.js +153 -0
  145. package/libs/shared-utils/three/{PointSelectorHelper.d.ts → PointSelector/utils/PointSelectorHelper.d.ts} +9 -10
  146. package/libs/shared-utils/three/PointSelector/utils/PointSelectorHelper.js +60 -0
  147. package/libs/{PanoMeasurePlugin/Modules/rangePiece → shared-utils/three/PointSelector/utils}/html.js +3 -4
  148. package/libs/shared-utils/three/PointSelector/utils/typing.d.ts +8 -0
  149. package/libs/shared-utils/three/index.d.ts +2 -3
  150. package/libs/shared-utils/three/index.js +3 -3
  151. package/package.json +3 -3
  152. package/dist/shared-utils/three/PointDomHelper.d.ts +0 -18
  153. package/libs/shared-utils/three/PointDomHelper.d.ts +0 -18
  154. package/libs/shared-utils/three/PointDomHelper.js +0 -62
  155. package/libs/shared-utils/three/PointHelper.js +0 -73
  156. package/libs/shared-utils/three/PointSelectorHelper.js +0 -52
  157. /package/dist/{PanoMeasurePlugin/Modules/rangePiece → shared-utils/three/PointSelector/utils}/html.d.ts +0 -0
  158. /package/libs/{PanoMeasurePlugin/Modules/rangePiece → shared-utils/three/PointSelector/utils}/html.d.ts +0 -0
@@ -1,6 +1,6 @@
1
1
  var I = Object.defineProperty;
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);
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);
4
4
  import G from "hammerjs";
5
5
  import T from "../Modules/DeleteDom/index.js";
6
6
  import w from "../utils/isNDCPointInScreen.js";
@@ -31,34 +31,20 @@ import "../utils/ndc2Screen.js";
31
31
  import "../Model/polyline.js";
32
32
  import "../utils/dom/areaDom.js";
33
33
  import "../../shared-utils/three/geometryUtil.js";
34
- import "../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
35
- import "../../CSS3DRenderPlugin/utils/three/CSS3DRender.js";
36
- import "../../shared-utils/positionToVector3.js";
37
- import "../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
38
34
  import "three/examples/jsm/renderers/CSS3DRenderer";
39
- import "../../CSS3DRenderPlugin/utils/getAllCSS3DObject.js";
40
- import "../../shared-utils/util.js";
41
- import "../../CSS3DRenderPlugin/utils/createResizeObserver.js";
42
- import "../../CSS3DRenderPlugin/utils/even.js";
43
- import "../../shared-utils/Subscribe.js";
44
- import "../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
45
- import "../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
46
- import "../../shared-utils/three/getObjectVisible.js";
47
- import "../../CSS3DRenderPlugin/utils/three/CSS3DScene.js";
48
- import "../../CSS3DRenderPlugin/utils/three/CSS3DGroup.js";
49
- import "../../CSS3DRenderPlugin/utils/generateBehindFiveElement.js";
50
35
  import "../../shared-utils/three/THREESphere.js";
51
36
  import "animejs";
52
37
  import "../../shared-utils/isNil.js";
38
+ import "../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
53
39
  import "../../shared-utils/three/IObject3D.js";
54
40
  import "../../shared-utils/three/generatePolygonGeometry.js";
55
41
  import "../../shared-utils/three/earcut3D.js";
56
42
  import "earcut";
57
43
  import "../../shared-utils/three/getNormal.js";
58
44
  const E = () => !1;
59
- class Vt extends U {
60
- constructor(t) {
61
- super(t);
45
+ class He extends U {
46
+ constructor(e) {
47
+ super(e);
62
48
  s(this, "type", "watch");
63
49
  s(this, "deleteDom");
64
50
  s(this, "choose");
@@ -68,48 +54,48 @@ class Vt extends U {
68
54
  s(this, "fiveElement");
69
55
  s(this, "editPointState");
70
56
  s(this, "hammer");
71
- s(this, "onPanStart", (t) => {
57
+ s(this, "onPanStart", (e) => {
72
58
  var p;
73
59
  if (this.model.getAllLines().length === 0 || !this.fiveElement)
74
60
  return;
75
- const i = C(t).point, e = (p = j(this.five, this.model.getAllPoints(), i, 20)) == null ? void 0 : p.point;
76
- if (!e) {
61
+ const i = C(e).point, t = (p = j(this.five, this.model.getAllPoints(), i, 20)) == null ? void 0 : p.point;
62
+ if (!t) {
77
63
  this.editPointState = void 0;
78
64
  return;
79
65
  }
80
- const n = this.model.polylines.find((a) => a.includes(e)), l = {
81
- point: e,
66
+ const n = this.model.polylines.find((a) => a.includes(t)), l = {
67
+ point: t,
82
68
  associatedLines: n.lines
83
69
  };
84
70
  this.hook.emit("wantsDragLine", {
85
- point: e.id,
71
+ point: t.id,
86
72
  lines: l.associatedLines.map(({ id: a }) => a)
87
73
  }) || (this.editPointState = l, this.magnifier.appendTo(this.container), this.magnifier.enable(), this.group.add(this.mouseGroup));
88
74
  });
89
75
  s(this, "onPanEnd", () => {
90
- 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));
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));
91
77
  });
92
- s(this, "onPan", (t) => {
78
+ s(this, "onPan", (e) => {
93
79
  if (!this.editPointState || !this.fiveElement)
94
80
  return;
95
- const i = C(t).ndcPoint, e = new M();
96
- e.setFromCamera(i, this.five.camera);
97
- const [n] = D(this.five).intersectRaycaster(e);
81
+ const i = C(e).ndcPoint, t = new M();
82
+ t.setFromCamera(i, this.five.camera);
83
+ const [n] = D(this.five).intersectRaycaster(t);
98
84
  n && this.onIntersectionUpdate(n);
99
85
  });
100
- s(this, "onIntersectionUpdate", (t, i) => {
86
+ s(this, "onIntersectionUpdate", (e, i) => {
101
87
  if (this.editPointState) {
102
- if (this.clearHighlightLines(), this.editPointState.point.position.copy(t.point), this.editPointState.associatedLines.forEach((e) => {
103
- 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
- }), this.updateDistanceUI(), this.magnifier.renderWithPoint(t.point), this.mouseGroup.position.copy(t.point), i)
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)
105
91
  this.mouseGroup.quaternion.copy(i.quaternion);
106
- else if (t.face) {
107
- const n = t.face.normal.clone().multiplyScalar(0.05), d = t.point.clone().add(n).clone().add(n);
92
+ else if (e.face) {
93
+ const n = e.face.normal.clone().multiplyScalar(0.05), d = e.point.clone().add(n).clone().add(n);
108
94
  this.mouseGroup.lookAt(d);
109
95
  }
110
96
  this.five.needsRender = !0, this.hook.emit(
111
97
  "selectedChange",
112
- this.editPointState.associatedLines.map((e) => e)
98
+ this.editPointState.associatedLines.map((t) => t)
113
99
  );
114
100
  }
115
101
  });
@@ -117,17 +103,17 @@ class Vt extends U {
117
103
  if (this.editPointState)
118
104
  return !1;
119
105
  });
120
- s(this, "wantsTapGesture", (t) => {
106
+ s(this, "wantsTapGesture", (e) => {
121
107
  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;
123
- if (e instanceof F) {
124
- const o = this.model.areas.find((h) => h.polygon === e);
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);
125
111
  if (o) {
126
112
  const { x: h, y: u } = i[0].point.clone().project(this.five.camera), m = `${(h + 1) / 2 * 100}%`, g = `${(-u + 1) / 2 * 100}%`;
127
113
  return this.chooseArea(o, { left: m, top: g }), !1;
128
114
  }
129
115
  }
130
- const n = D(this.five), [l] = n.intersectRaycaster(t);
116
+ const n = D(this.five), [l] = n.intersectRaycaster(e);
131
117
  if (!l)
132
118
  return;
133
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) => {
@@ -149,19 +135,19 @@ class Vt extends U {
149
135
  if (A)
150
136
  return this.chooseLine(A), !1;
151
137
  });
152
- s(this, "chooseLine", (t) => {
138
+ s(this, "chooseLine", (e) => {
153
139
  this.choose = "line";
154
- const i = t.getPolyline().lines;
140
+ const i = e.getPolyline().lines;
155
141
  this.deleteDom.setLines(i).updatePosition().show(), this.highlightLines(i), this.five.needsRender = !0, this.hook.emit(
156
142
  "selectedChange",
157
- i.map((e) => e)
143
+ i.map((t) => t)
158
144
  );
159
145
  });
160
- s(this, "chooseArea", (t, i) => {
161
- this.choose = t, this.deleteDom.updatePosition(i.left, `calc(${i.top} - 20px)`).show(), this.highlightArea(t);
146
+ s(this, "chooseArea", (e, i) => {
147
+ this.choose = e, this.deleteDom.updatePosition(i.left, `calc(${i.top} - 20px)`).show(), this.highlightArea(e);
162
148
  });
163
- s(this, "polylineRemoved", (t) => {
164
- t.lines.forEach((i) => this.removeLine(i)), this.hook.emit(
149
+ s(this, "polylineRemoved", (e) => {
150
+ e.lines.forEach((i) => this.removeLine(i)), this.hook.emit(
165
151
  "selectedChange",
166
152
  this.model.getAllLines().filter((i) => i.selected).map((i) => i)
167
153
  );
@@ -169,11 +155,11 @@ class Vt extends U {
169
155
  s(this, "onCameraUpdate", () => {
170
156
  this.updateDistanceUI(), this.highlightedLines.length > 0 && this.deleteDom.updatePosition();
171
157
  });
172
- s(this, "deleteArea", (t) => {
173
- this.unHighlightArea(t), t.dispose(), this.deleteDom.hide();
158
+ s(this, "deleteArea", (e) => {
159
+ this.unHighlightArea(e), e.dispose(), this.deleteDom.hide();
174
160
  });
175
161
  s(this, "deleteLine", () => {
176
- const t = this.highlightedLines[0], i = this.model.getPolylineByLine(t);
162
+ const e = this.highlightedLines[0], i = this.model.getPolylineByLine(e);
177
163
  i && (this.model.removePolyline(i), this.highlightedLines = [], this.deleteDom.setLines([]).hide());
178
164
  });
179
165
  s(this, "cancelDeleteClickCallback", () => {
@@ -185,49 +171,49 @@ class Vt extends U {
185
171
  this.choose === "line" ? this.deleteLine() : this.choose instanceof x && this.deleteArea(this.choose);
186
172
  },
187
173
  cancel: this.cancelDeleteClickCallback
188
- }).appendTo(this.container), this.model.getAllLines().forEach((e) => {
189
- 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);
190
- }), this.model.getAllAreas().forEach((e) => {
191
- 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) => {
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) => {
192
178
  n.distanceItem.appendTo(this.container), n.distanceItem.update(this.five), this.group.add(n.mesh);
193
179
  });
194
180
  });
195
181
  const i = this.five.getElement();
196
182
  if (i) {
197
183
  this.fiveElement = i;
198
- const e = new G(i);
199
- this.hammer = e, e.on("pan", this.onPan), e.on("panstart", this.onPanStart), e.on("panend", this.onPanEnd);
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);
200
186
  }
201
187
  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);
202
188
  }
203
189
  dispose() {
204
- var t;
205
- 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();
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();
206
192
  }
207
- highlightLine(t) {
208
- t.selected || (t.selected = !0, this.group.add(t.lightMesh), t.distanceItem.highlight(), this.five.needsRender = !0);
193
+ highlightLine(e) {
194
+ e.selected || (e.selected = !0, this.group.add(e.lightMesh), e.distanceItem.highlight(), this.five.needsRender = !0);
209
195
  }
210
196
  clearHighlightLines() {
211
197
  this.group.children.length !== 0 && (this.unHighlightLines(this.highlightedLines), this.highlightedLines = []);
212
198
  }
213
- highlightArea(t) {
214
- this.unHighlightLines(), this.unHighlightArea(), this.highlightLines(t.polyline.lines), this.five.needsRender = !0;
199
+ highlightArea(e) {
200
+ this.unHighlightLines(), this.unHighlightArea(), this.highlightLines(e.polyline.lines), this.five.needsRender = !0;
215
201
  }
216
- unHighlightArea(t) {
217
- const i = t != null ? t : this.highlightedArea;
202
+ unHighlightArea(e) {
203
+ const i = e != null ? e : this.highlightedArea;
218
204
  i && (this.unHighlightLines(i.polyline.lines), this.five.needsRender = !0);
219
205
  }
220
- highlightLines(t) {
221
- this.unHighlightLines(), this.highlightedLines = t, t.forEach((i) => this.highlightLine(i));
206
+ highlightLines(e) {
207
+ this.unHighlightLines(), this.highlightedLines = e, e.forEach((i) => this.highlightLine(i));
222
208
  }
223
- unHighlightLines(t) {
209
+ unHighlightLines(e) {
224
210
  this.unHighlightArea();
225
- const i = t != null ? t : this.highlightedLines;
226
- i && i.forEach((e) => {
227
- e.selected = !1, e.distanceItem.unHighlight(), this.group.remove(e.lightMesh), this.five.needsRender = !0;
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;
228
214
  });
229
215
  }
230
216
  }
231
217
  export {
232
- Vt as default
218
+ He as default
233
219
  };
@@ -15,10 +15,12 @@ import { Magnifier } from '../../shared-utils';
15
15
  import type { MagnifierParameter } from '../../shared-utils';
16
16
  import type Area from '../Model/area';
17
17
  import * as BasePlugin from '../../base/BasePlugin';
18
+ import type { PointSelectorConfig } from '../../shared-utils/three/PointSelector';
18
19
  export type Mode = 'Watch' | 'Edit' | 'Mixed' | 'View';
19
20
  export interface PanoMeasureParameterType extends Partial<Config> {
20
21
  editParams?: EditParameter;
21
22
  magnifierParams?: MagnifierParameter;
23
+ pointSelectorConfig?: PointSelectorConfig;
22
24
  openParams?: OpenParameter;
23
25
  useUIController?: boolean | UIControllerParams;
24
26
  useGuideController?: boolean | GuideControllerParams;
@@ -1,40 +1,39 @@
1
- var k = Object.defineProperty;
2
- var P = Object.getOwnPropertySymbols;
3
- var T = Object.prototype.hasOwnProperty, U = Object.prototype.propertyIsEnumerable;
4
- var c = (n, s, t) => s in n ? k(n, s, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[s] = t, m = (n, s) => {
1
+ var x = Object.defineProperty;
2
+ var I = Object.getOwnPropertySymbols;
3
+ var D = Object.prototype.hasOwnProperty, E = Object.prototype.propertyIsEnumerable;
4
+ var c = (n, s, t) => s in n ? x(n, s, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[s] = t, m = (n, s) => {
5
5
  for (var t in s || (s = {}))
6
- T.call(s, t) && c(n, t, s[t]);
7
- if (P)
8
- for (var t of P(s))
9
- U.call(s, t) && c(n, t, s[t]);
6
+ D.call(s, t) && c(n, t, s[t]);
7
+ if (I)
8
+ for (var t of I(s))
9
+ E.call(s, t) && c(n, t, s[t]);
10
10
  return n;
11
11
  };
12
12
  var r = (n, s, t) => (c(n, typeof s != "symbol" ? s + "" : s, t), t);
13
13
  import h from "./EditController.js";
14
- import v from "./ViewController.js";
15
- import b from "./WatchController.js";
14
+ import k from "./ViewController.js";
15
+ import T from "./WatchController.js";
16
16
  import a from "./MixedController.js";
17
- import { omit as x } from "../../shared-utils/filter.js";
18
- import { Group as D } from "three";
19
- import { Model as E } from "../Model/index.js";
20
- import { getMouseGroup as G } from "../utils/mouseGroup.js";
21
- import { UIController as L } from "../Modules/UIController/index.js";
22
- import { GuideController as O } from "../Modules/GuideController.js";
23
- import { ShortcutKeyController as S } from "./ShortcutKeyController.js";
24
- import { safeObj as I } from "../../shared-utils/safeObj.js";
25
- import { Magnifier as W } from "../../shared-utils/three/Magnifier.js";
26
- import "../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
27
- import "../../CSS3DRenderPlugin/utils/three/CSS3DRender.js";
28
- import "../../CSS3DRenderPlugin/utils/generateBehindFiveElement.js";
17
+ import { omit as G } from "../../shared-utils/filter.js";
18
+ import { Group as S } from "three";
19
+ import { Model as L } from "../Model/index.js";
20
+ import { getMouseGroup as O } from "../utils/mouseGroup.js";
21
+ import { UIController as W } from "../Modules/UIController/index.js";
22
+ import { GuideController as A } from "../Modules/GuideController.js";
23
+ import { ShortcutKeyController as B } from "./ShortcutKeyController.js";
24
+ import { safeObj as U } from "../../shared-utils/safeObj.js";
25
+ import { Magnifier as V } from "../../shared-utils/three/Magnifier.js";
26
+ import "three/examples/jsm/renderers/CSS3DRenderer";
27
+ import "@realsee/five/line";
29
28
  import "../../shared-utils/three/THREESphere.js";
30
29
  import "animejs";
31
- import { isTouchDevice as A } from "../../shared-utils/isTouchDevice.js";
32
- import { Controller as B } from "../../base/BasePlugin.js";
30
+ import "../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
31
+ import { isTouchDevice as K } from "../../shared-utils/isTouchDevice.js";
32
+ import { Controller as H } from "../../base/BasePlugin.js";
33
33
  import "../Model/line.js";
34
34
  import "../../shared-utils/uuid.js";
35
35
  import "../utils/line.js";
36
36
  import "../../shared-utils/five/FiveLine.js";
37
- import "@realsee/five/line";
38
37
  import "../utils/constants.js";
39
38
  import "@realsee/five";
40
39
  import "../utils/dom/distanceItem.js";
@@ -58,34 +57,28 @@ import "../../shared-utils/three/geometryUtil.js";
58
57
  import "hammerjs";
59
58
  import "../../shared-utils/isNil.js";
60
59
  import "../utils/isIntersecting.js";
61
- import "../../shared-utils/three/PointSelector.js";
62
- import "../../shared-utils/three/PointSelectorHelper.js";
63
- import "../../shared-utils/three/PointHelper.js";
60
+ import "../../shared-utils/three/PointSelector/index.js";
61
+ import "../../shared-utils/three/PointSelector/utils/PointSelectorHelper.js";
62
+ import "../../shared-utils/three/PointSelector/utils/PointHelper.js";
64
63
  import "../../shared-utils/three/Assets/index.js";
65
- import "../../shared-utils/three/PointDomHelper.js";
66
- import "../Modules/rangePiece/html.js";
67
- import "../../CSS3DRenderPlugin/index.js";
68
- import "../../CSS3DRenderPlugin/Controller.js";
69
- import "../../shared-utils/url/absoluteUrl.js";
70
- import "../../shared-utils/five/fiveModelLoad.js";
71
- import "../../shared-utils/five/getFiveModel.js";
72
- import "../../shared-utils/positionToVector3.js";
73
- import "../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
74
- import "three/examples/jsm/renderers/CSS3DRenderer";
75
- import "../../CSS3DRenderPlugin/utils/getAllCSS3DObject.js";
76
- import "../../shared-utils/util.js";
77
- import "../../CSS3DRenderPlugin/utils/createResizeObserver.js";
64
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
78
65
  import "../../CSS3DRenderPlugin/utils/even.js";
79
66
  import "../../shared-utils/Subscribe.js";
80
- import "../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
81
67
  import "../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
82
68
  import "../../shared-utils/three/getObjectVisible.js";
83
- import "../../CSS3DRenderPlugin/utils/three/CSS3DScene.js";
84
- import "../../CSS3DRenderPlugin/utils/three/CSS3DGroup.js";
85
- import "../../shared-utils/animationFrame/BetterTween.js";
86
- import "../../shared-utils/animationFrame/index.js";
69
+ import "../../shared-utils/three/PointSelector/utils/html.js";
70
+ import "../../shared-utils/five/initialCSS3DRender.js";
71
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
72
+ import "../../CSS3DRenderPlugin/utils/three/THREEJS_CSS3DRenderer.js";
73
+ import "../../CSS3DRenderPlugin/utils/createResizeObserver.js";
74
+ import "../../shared-utils/three/PointSelector/utils/PointHelper2.js";
75
+ import "../../Sculpt/Meshes/Line.js";
76
+ import "../../Sculpt/utils/color.js";
77
+ import "../../shared-utils/positionToVector3.js";
78
+ import "../../CSS3DRenderPlugin/utils/three/CSS3DSprite.js";
87
79
  import "../../shared-utils/five/getPosition.js";
88
80
  import "../../shared-utils/five/getRaycasterByNdcPosition.js";
81
+ import "../../shared-utils/five/getFiveModel.js";
89
82
  import "../Modules/DeleteDom/index.js";
90
83
  import "../Modules/DeleteDom/_Assets/delete.svg.js";
91
84
  import "../Modules/DeleteDom/_Assets/delete_bg.png.js";
@@ -95,6 +88,7 @@ import "../utils/findClosestPoint.js";
95
88
  import "../utils/ndc2Screen.js";
96
89
  import "../../shared-utils/getPointFromHammerEvent.js";
97
90
  import "../Modules/rangePiece/index.js";
91
+ import "../../shared-utils/animationFrame/index.js";
98
92
  import "../../shared-utils/noop.js";
99
93
  import "../../shared-utils/five/calculateThreeMouse.js";
100
94
  import "../../shared-utils/tap.js";
@@ -120,9 +114,10 @@ import "../../shared-utils/Utils/FiveUtil.js";
120
114
  import "../../shared-utils/Utils/BaseUtil.js";
121
115
  import "../../shared-utils/Utils/WorkUtil.js";
122
116
  import "../../shared-utils/five/transformPosition.js";
123
- class je extends B {
117
+ import "../../shared-utils/url/absoluteUrl.js";
118
+ class Ke extends H {
124
119
  constructor(t, e) {
125
- var l, u, d, f, g, y, M, C, w;
120
+ var l, u, d, f, g, y, C, M, w, P, b, v;
126
121
  super(t);
127
122
  r(this, "state", { enabled: !0 });
128
123
  r(this, "hasOpen", !1);
@@ -151,7 +146,7 @@ class je extends B {
151
146
  var t, e, i, o;
152
147
  this.hasOpen = !1, this.state.enabled = !1, this.container.style.visibility = "hidden", this.container.style.opacity = "0", (t = this.controller) == null || t.dispose(), (e = this.useUIController) == null || e.hide(), (i = this.useGuideController) == null || i.hide(), (o = this.shortcutKeyController) == null || o.dispose(), this.controller = null, this.five.helperVisible = !0, this.five.scene.remove(this.group), this.five.needsRender = !0, this.hook.emit("disable", !0);
153
148
  });
154
- r(this, "getCurrentMode", () => this.controller instanceof h ? "Edit" : this.controller instanceof b ? "Watch" : this.controller instanceof a ? "Mixed" : this.controller instanceof v ? "View" : null);
149
+ r(this, "getCurrentMode", () => this.controller instanceof h ? "Edit" : this.controller instanceof T ? "Watch" : this.controller instanceof a ? "Mixed" : this.controller instanceof k ? "View" : null);
155
150
  /** 变更场景
156
151
  * @description 如果从编辑场景改变到观看场景,不会自动保存,默认丢弃所有改动
157
152
  */
@@ -161,8 +156,8 @@ class je extends B {
161
156
  return;
162
157
  (o = this.controller) == null || o.dispose();
163
158
  const e = {
164
- View: v,
165
- Watch: b,
159
+ View: k,
160
+ Watch: T,
166
161
  Edit: h,
167
162
  Mixed: a
168
163
  };
@@ -177,8 +172,11 @@ class je extends B {
177
172
  r(this, "changeMeasureType", (t) => {
178
173
  this.currentMeasureType = t, this.hook.emit("measureTypeChange", t);
179
174
  });
180
- this.five = t, this.hook = this.hooks, this.params = e, this.config = x(e, ["openParams", "magnifierParams"]), this.model = new E(this.config), this.isMobile = (u = (l = e == null ? void 0 : e.openParams) == null ? void 0 : l.isMobile) != null ? u : !1, this.magnifier = new W(t, (d = e.magnifierParams) != null ? d : { width: 190, height: 190, scale: 2 }), this.allowMeasureType = Array.from(new Set((g = (f = e.editParams) == null ? void 0 : f.allowMeasureType) != null ? g : ["line"])), this.currentMeasureType = (y = this.allowMeasureType[0]) != null ? y : "line", this.group = new D(), this.group.name = "plugin-measure-group", this.container.classList.add("five-plugin-measure-container"), this.container.style.position = "absolute", this.container.style.left = "0", this.container.style.top = "0", this.container.style.pointerEvents = "none", this.container.style.width = "100%", this.container.style.height = "100%", this.container.style.opacity = "0";
181
- const i = (C = (M = e.editParams) == null ? void 0 : M.pointSelectorMode) != null ? C : A ? "fixed" : "cursor", o = (w = this.params.openParams) != null ? w : {};
175
+ this.five = t, this.hook = this.hooks, this.params = e, this.config = G(e, ["openParams", "magnifierParams"]), this.model = new L(this.config), this.isMobile = (u = (l = e == null ? void 0 : e.openParams) == null ? void 0 : l.isMobile) != null ? u : !1, this.magnifier = new V(
176
+ t,
177
+ (y = (g = e.magnifierParams) != null ? g : (f = (d = e.pointSelectorConfig) == null ? void 0 : d.helper) == null ? void 0 : f.magnifierParams) != null ? y : { width: 190, height: 190, scale: 2 }
178
+ ), this.allowMeasureType = Array.from(new Set((M = (C = e.editParams) == null ? void 0 : C.allowMeasureType) != null ? M : ["line"])), this.currentMeasureType = (w = this.allowMeasureType[0]) != null ? w : "line", this.group = new S(), this.group.name = "plugin-measure-group", this.container.classList.add("five-plugin-measure-container"), this.container.style.position = "absolute", this.container.style.left = "0", this.container.style.top = "0", this.container.style.visibility = "hidden", this.container.style.width = "100%", this.container.style.height = "100%", this.container.style.opacity = "0";
179
+ const i = (b = (P = e.editParams) == null ? void 0 : P.pointSelectorMode) != null ? b : K ? "fixed" : "cursor", o = (v = this.params.openParams) != null ? v : {};
182
180
  if (this.params.useUIController !== !1) {
183
181
  const p = m({
184
182
  container: this.container,
@@ -186,16 +184,16 @@ class je extends B {
186
184
  i18n: e.i18n,
187
185
  pointSelectorMode: i,
188
186
  useNewUI: this.allowMeasureType.length > 1
189
- }, I(this.params.useUIController));
190
- this.useUIController = new L(this, p);
187
+ }, U(this.params.useUIController));
188
+ this.useUIController = new W(this, p);
191
189
  }
192
190
  if (this.params.useGuideController !== !1) {
193
191
  const p = m({
194
192
  container: this.container,
195
193
  pointSelectorMode: i,
196
194
  i18n: e.i18n
197
- }, I(this.params.useGuideController));
198
- this.useGuideController = new O(this, p);
195
+ }, U(this.params.useGuideController));
196
+ this.useGuideController = new A(this, p);
199
197
  }
200
198
  }
201
199
  appendTo(t) {
@@ -221,7 +219,7 @@ class je extends B {
221
219
  */
222
220
  enable(t) {
223
221
  var e, i;
224
- this.hasOpen || (this.state.enabled = !0, this.hasOpen = !0, this.group.matrix.copy(this.workUtil.transform), this.group.matrix.decompose(this.group.position, this.group.quaternion, this.group.scale), this.group.updateMatrixWorld(), this.five.scene.add(this.group), this.container.style.visibility = "visible", this.container.style.opacity = "1", t != null && t.mode ? this.changeMode(t.mode) : this.isMobile ? this.changeMode("Mixed") : this.changeMode("Watch"), (e = this.useUIController) == null || e.show(), (i = this.useGuideController) == null || i.show(), this.shortcutKeyController = new S(this, this.five), this.hook.emit("enable", !0));
222
+ this.hasOpen || (this.state.enabled = !0, this.hasOpen = !0, this.group.matrix.copy(this.workUtil.transform), this.group.matrix.decompose(this.group.position, this.group.quaternion, this.group.scale), this.group.updateMatrixWorld(), this.five.scene.add(this.group), this.container.style.visibility = "visible", this.container.style.opacity = "1", t != null && t.mode ? this.changeMode(t.mode) : this.isMobile ? this.changeMode("Mixed") : this.changeMode("Watch"), (e = this.useUIController) == null || e.show(), (i = this.useGuideController) == null || i.show(), this.shortcutKeyController = new B(this, this.five), this.hook.emit("enable", !0));
225
223
  }
226
224
  /** 进入编辑模式 */
227
225
  edit(t) {
@@ -317,13 +315,14 @@ class je extends B {
317
315
  workUtil: this.workUtil,
318
316
  openParams: t,
319
317
  editParams: e,
318
+ pointSelectorConfig: this.params.pointSelectorConfig,
320
319
  magnifierParams: this.params.magnifierParams,
321
320
  getMeasureType: () => this.currentMeasureType,
322
- mouseGroup: G(m({}, t.crossHairParameter)),
321
+ mouseGroup: O(m({}, t.crossHairParameter)),
323
322
  userDistanceItemCreator: this.params.userDistanceItemCreator
324
323
  };
325
324
  }
326
325
  }
327
326
  export {
328
- je as default
327
+ Ke as default
329
328
  };
@@ -1,6 +1,6 @@
1
- var l = Object.defineProperty;
2
- var d = (o, t, e) => t in o ? l(o, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : o[t] = e;
3
- var i = (o, t, e) => (d(o, typeof t != "symbol" ? t + "" : t, e), e);
1
+ var m = Object.defineProperty;
2
+ var d = (o, t, i) => t in o ? m(o, t, { enumerable: !0, configurable: !0, writable: !0, value: i }) : o[t] = i;
3
+ var e = (o, t, i) => (d(o, typeof t != "symbol" ? t + "" : t, i), i);
4
4
  import * as r from "three";
5
5
  import { uuid as f } from "../../shared-utils/uuid.js";
6
6
  import { Subscribe as c } from "@realsee/five";
@@ -24,62 +24,48 @@ import "earcut";
24
24
  import "../../shared-utils/three/getNormal.js";
25
25
  import "../../shared-utils/three/geometryUtil.js";
26
26
  import "hammerjs";
27
- import "../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
28
- import "../../CSS3DRenderPlugin/utils/three/CSS3DRender.js";
29
- import "../../shared-utils/positionToVector3.js";
30
- import "../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
31
27
  import "three/examples/jsm/renderers/CSS3DRenderer";
32
- import "../../CSS3DRenderPlugin/utils/getAllCSS3DObject.js";
33
- import "../../shared-utils/util.js";
34
- import "../../CSS3DRenderPlugin/utils/createResizeObserver.js";
35
- import "../../CSS3DRenderPlugin/utils/even.js";
36
- import "../../shared-utils/Subscribe.js";
37
- import "../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
38
- import "../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
39
- import "../../shared-utils/three/getObjectVisible.js";
40
- import "../../CSS3DRenderPlugin/utils/three/CSS3DScene.js";
41
- import "../../CSS3DRenderPlugin/utils/three/CSS3DGroup.js";
42
- import "../../CSS3DRenderPlugin/utils/generateBehindFiveElement.js";
43
28
  import "../../shared-utils/three/THREESphere.js";
44
29
  import "animejs";
45
30
  import "../../shared-utils/isNil.js";
46
- class rt {
47
- constructor(t, e) {
48
- i(this, "id", f());
49
- i(this, "selected", !1);
50
- i(this, "text");
51
- i(this, "type", "area");
52
- i(this, "lightMesh");
53
- i(this, "areaItem");
54
- i(this, "hook", new c());
55
- i(this, "model");
31
+ import "../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
32
+ class G {
33
+ constructor(t, i) {
34
+ e(this, "id", f());
35
+ e(this, "selected", !1);
36
+ e(this, "text");
37
+ e(this, "type", "area");
38
+ e(this, "lightMesh");
39
+ e(this, "areaItem");
40
+ e(this, "hook", new c());
41
+ e(this, "model");
56
42
  /** 多边形mesh */
57
- i(this, "polygon");
43
+ e(this, "polygon");
58
44
  /** 多边形顶点 */
59
- i(this, "points", []);
45
+ e(this, "points", []);
60
46
  /** 多边形前三个点组成的平面,用来使得后面加的点也落在这个平面上 */
61
- i(this, "planeHelper");
47
+ e(this, "planeHelper");
62
48
  /** 多边形边框 */
63
- i(this, "polyline");
49
+ e(this, "polyline");
64
50
  /** 多边形mesh容器 */
65
- i(this, "meshContainer");
51
+ e(this, "meshContainer");
66
52
  /** 多边形dom容器 */
67
- i(this, "domContainer");
68
- i(this, "five");
53
+ e(this, "domContainer");
54
+ e(this, "five");
69
55
  /**
70
56
  * @description: five camera update 时,更新Dom的位置
71
57
  */
72
- i(this, "updateDom", () => {
58
+ e(this, "updateDom", () => {
73
59
  this.five && (this.polyline.lines.forEach((t) => t.distanceItem.update(this.five)), this.areaItem.updateDomPosition(this.five));
74
60
  });
75
61
  var n;
76
- t && (this.points = t), this.model = e.model, this.polygon = new v(t), this.polyline = new y({ model: e.model }), this.areaItem = new C({
62
+ t && (this.points = t), this.model = i.model, this.polygon = new v(t), this.polyline = new y({ model: i.model }), this.areaItem = new C({
77
63
  area: this,
78
64
  clickCallback: (p, s) => {
79
- const h = p.clientX + "px", m = p.clientY + "px";
80
- this.hook.emit("selected", this, { left: h, top: m });
65
+ const h = p.clientX + "px", l = p.clientY + "px";
66
+ this.hook.emit("selected", this, { left: h, top: l });
81
67
  }
82
- }), 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);
68
+ }), this.domContainer = i.domContainer || null, this.meshContainer = i.meshContainer || null, this.five = i.five || null, this.areaItem.appendTo(this.domContainer), (n = this.five) == null || n.on("cameraUpdate", this.updateDom);
83
69
  }
84
70
  /**
85
71
  * @description: 多边形的端点是否闭合
@@ -91,9 +77,9 @@ class rt {
91
77
  addPoints(t) {
92
78
  var p;
93
79
  this.points = this.points.concat(t);
94
- const e = this.points.at(-2), n = this.points.at(-1);
95
- if (e && n) {
96
- const s = new u(new a(e), new a(n), this.polyline.model);
80
+ const i = this.points.at(-2), n = this.points.at(-1);
81
+ if (i && n) {
82
+ const s = new u(new a(i), new a(n), this.polyline.model);
97
83
  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));
98
84
  }
99
85
  (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);
@@ -142,5 +128,5 @@ class rt {
142
128
  }
143
129
  }
144
130
  export {
145
- rt as default
131
+ G as default
146
132
  };
@@ -1,25 +1,12 @@
1
1
  import "three";
2
2
  import { Magnifier as o } from "../../shared-utils/three/Magnifier.js";
3
- import "../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
4
- import "../../CSS3DRenderPlugin/utils/three/CSS3DRender.js";
5
- import "../../CSS3DRenderPlugin/utils/generateBehindFiveElement.js";
3
+ import "three/examples/jsm/renderers/CSS3DRenderer";
4
+ import "@realsee/five/line";
6
5
  import "../../shared-utils/three/THREESphere.js";
7
6
  import "animejs";
7
+ import "../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
8
8
  import "hammerjs";
9
9
  import "../../shared-utils/Subscribe.js";
10
- import "../../shared-utils/positionToVector3.js";
11
- import "../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
12
- import "three/examples/jsm/renderers/CSS3DRenderer";
13
- import "../../CSS3DRenderPlugin/utils/getAllCSS3DObject.js";
14
- import "../../shared-utils/util.js";
15
- import "../../CSS3DRenderPlugin/utils/createResizeObserver.js";
16
- import "../../CSS3DRenderPlugin/utils/even.js";
17
- import "../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
18
- import "../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
19
- import "../../shared-utils/three/centerPoint.js";
20
- import "../../shared-utils/three/getObjectVisible.js";
21
- import "../../CSS3DRenderPlugin/utils/three/CSS3DScene.js";
22
- import "../../CSS3DRenderPlugin/utils/three/CSS3DGroup.js";
23
10
  export {
24
11
  o as default
25
12
  };