@realsee/dnalogel 3.44.5 → 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 (162) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/dist/Sculpt/Meshes/Area.d.ts +1 -1
  3. package/dist/Sculpt/Meshes/Box.d.ts +1 -1
  4. package/dist/Sculpt/Meshes/Circle.d.ts +1 -1
  5. package/dist/Sculpt/Meshes/CircleWithEdge.d.ts +1 -1
  6. package/dist/Sculpt/Meshes/Line.d.ts +8 -2
  7. package/dist/Sculpt/Meshes/LineWithDots.d.ts +1 -1
  8. package/dist/Sculpt/Meshes/Point.d.ts +1 -1
  9. package/dist/Sculpt/Meshes/PolygonWithEdge.d.ts +1 -1
  10. package/dist/Sculpt/Meshes/Prism.d.ts +1 -1
  11. package/dist/Sculpt/Meshes/RectangleWithEdge.d.ts +3 -4
  12. package/dist/Sculpt/Objects/Line/Editor.d.ts +22 -0
  13. package/dist/Sculpt/Objects/Line/index.d.ts +33 -0
  14. package/dist/Sculpt/Objects/Point/index.d.ts +1 -1
  15. package/dist/Sculpt/Objects/Polygon/Editor.d.ts +2 -2
  16. package/dist/Sculpt/Objects/Polygon/index.d.ts +3 -2
  17. package/dist/Sculpt/Objects/Polyline/Editor.d.ts +3 -17
  18. package/dist/Sculpt/Objects/Polyline/index.d.ts +7 -6
  19. package/dist/Sculpt/index.d.ts +5 -0
  20. package/dist/Sculpt/typings/index.d.ts +11 -6
  21. package/dist/Sculpt/{utils/color.d.ts → typings/style.d.ts} +7 -0
  22. package/dist/Sculpt/typings/utils.type.d.ts +2 -0
  23. package/dist/Sculpt/utils/three/ColoredMesh.d.ts +1 -1
  24. package/dist/Sculpt/utils/three/rayOnLine.d.ts +3 -5
  25. package/dist/index.cjs.js +56 -56
  26. package/dist/index.js +29820 -29686
  27. package/dist/index.umd.js +49 -49
  28. package/dist/shared-utils/Utils/WorkUtil.d.ts +6 -6
  29. package/dist/shared-utils/tag.d.ts +6 -3
  30. package/libs/AreaMakerPlugin/Controller.js +150 -78
  31. package/libs/AreaMakerPlugin/index.js +76 -4
  32. package/libs/AreaMakerPlugin/utils/Item.js +190 -111
  33. package/libs/CSS3DRenderPlugin/Controller.js +89 -29
  34. package/libs/CSS3DRenderPlugin/index.js +75 -15
  35. package/libs/CSS3DRenderPlugin/utils/three/CSS3DObject.js +132 -58
  36. package/libs/CSS3DRenderPlugin/utils/three/CSS3DRender.js +181 -116
  37. package/libs/CruisePlugin/BaseController.js +121 -49
  38. package/libs/CruisePlugin/Move.js +73 -21
  39. package/libs/CruisePlugin/Work.js +98 -46
  40. package/libs/CruisePlugin/index.js +79 -27
  41. package/libs/CurrentPanoImagePlugin/Controller.js +176 -104
  42. package/libs/CurrentPanoImagePlugin/index.js +76 -4
  43. package/libs/GuideLinePlugin/Controller.js +82 -30
  44. package/libs/GuideLinePlugin/GuideLineItem.js +82 -30
  45. package/libs/GuideLinePlugin/GuideLineModeItem/index.js +3 -2
  46. package/libs/GuideLinePlugin/GuideLineModeItem.js +81 -29
  47. package/libs/GuideLinePlugin/index.js +79 -27
  48. package/libs/ModelMakerPlugin/Controller.js +140 -83
  49. package/libs/ModelMakerPlugin/index.js +75 -18
  50. package/libs/ModelTVVideoPlugin/Plugin.js +117 -57
  51. package/libs/ModelTVVideoPlugin/index.js +68 -8
  52. package/libs/Object3DHelperPlugin/Controller.js +54 -31
  53. package/libs/Object3DHelperPlugin/index.js +35 -13
  54. package/libs/PanoCompassPlugin/Controller.js +97 -42
  55. package/libs/PanoCompassPlugin/index.js +71 -16
  56. package/libs/PanoDoorLabelPlugin/BaseController.js +98 -26
  57. package/libs/PanoDoorLabelPlugin/Controller.js +187 -115
  58. package/libs/PanoDoorLabelPlugin/index.js +76 -4
  59. package/libs/PanoMeasurePlugin/Components/Controller0.js +141 -89
  60. package/libs/PanoMeasurePlugin/Components/Controller1.js +179 -127
  61. package/libs/PanoMeasurePlugin/Controller/EditController.js +125 -73
  62. package/libs/PanoMeasurePlugin/Controller/WatchController.js +167 -92
  63. package/libs/PanoMeasurePlugin/Controller/index.js +110 -65
  64. package/libs/PanoMeasurePlugin/Model/area.js +114 -38
  65. package/libs/PanoMeasurePlugin/Modules/Magnifier.js +78 -0
  66. package/libs/PanoMeasurePlugin/Modules/UIController/index.js +98 -46
  67. package/libs/PanoMeasurePlugin/index.js +77 -32
  68. package/libs/PanoMeasurePlugin/utils/dom/areaDom.js +98 -20
  69. package/libs/PanoSpatialTagPlugin/Plugin.js +210 -150
  70. package/libs/PanoSpatialTagPlugin/index.js +66 -6
  71. package/libs/PanoTagPlugin/Components/Common/TagPoint.js +133 -53
  72. package/libs/PanoTagPlugin/Components/Tag/MarketingTag.js +295 -216
  73. package/libs/PanoTagPlugin/Components/Tag/index.js +257 -187
  74. package/libs/PanoTagPlugin/Components/TagContainer.js +157 -87
  75. package/libs/PanoTagPlugin/Components/TagItem.js +144 -74
  76. package/libs/PanoTagPlugin/controller/Tag/BaseTag.js +73 -3
  77. package/libs/PanoTagPlugin/controller/Tag/ModelTag.js +109 -39
  78. package/libs/PanoTagPlugin/controller/Tag/PlaneTag.js +105 -35
  79. package/libs/PanoTagPlugin/controller/Tag/PointTag.js +113 -43
  80. package/libs/PanoTagPlugin/controller/TagRender.js +132 -80
  81. package/libs/PanoTagPlugin/controller/TagUtil.js +136 -84
  82. package/libs/PanoTagPlugin/controller/index.js +113 -61
  83. package/libs/PanoTagPlugin/index.js +89 -37
  84. package/libs/PanoTagPlugin/utils/tag/calculateTagConfig.js +121 -41
  85. package/libs/PanoVideoPlugin/Controller.js +137 -65
  86. package/libs/PanoVideoPlugin/VideoMeshController.js +149 -69
  87. package/libs/PanoVideoPlugin/index.js +82 -10
  88. package/libs/PipelinePlugin/Controller.js +199 -128
  89. package/libs/PipelinePlugin/index.js +76 -5
  90. package/libs/PipelinePlugin/utils/Objects/FlowPipe.js +102 -22
  91. package/libs/PipelinePlugin/utils/Objects/HighlightPipe.js +95 -15
  92. package/libs/PipelinePlugin/utils/Objects/Pipe.js +136 -56
  93. package/libs/Sculpt/Meshes/Area.d.ts +1 -1
  94. package/libs/Sculpt/Meshes/Box.d.ts +1 -1
  95. package/libs/Sculpt/Meshes/Box.js +16 -15
  96. package/libs/Sculpt/Meshes/Circle.d.ts +1 -1
  97. package/libs/Sculpt/Meshes/Circle.js +1 -1
  98. package/libs/Sculpt/Meshes/CircleWithEdge.d.ts +1 -1
  99. package/libs/Sculpt/Meshes/Cylinder.js +8 -7
  100. package/libs/Sculpt/Meshes/Line.d.ts +8 -2
  101. package/libs/Sculpt/Meshes/Line.js +93 -65
  102. package/libs/Sculpt/Meshes/LineWithDots.d.ts +1 -1
  103. package/libs/Sculpt/Meshes/LineWithDots.js +26 -26
  104. package/libs/Sculpt/Meshes/Point.d.ts +1 -1
  105. package/libs/Sculpt/Meshes/Point.js +7 -6
  106. package/libs/Sculpt/Meshes/Polygon.js +1 -1
  107. package/libs/Sculpt/Meshes/PolygonWithEdge.d.ts +1 -1
  108. package/libs/Sculpt/Meshes/Polyline.js +5 -4
  109. package/libs/Sculpt/Meshes/Prism.d.ts +1 -1
  110. package/libs/Sculpt/Meshes/Rectangle.js +3 -2
  111. package/libs/Sculpt/Meshes/RectangleWithEdge.d.ts +3 -4
  112. package/libs/Sculpt/Objects/Box/index.js +41 -43
  113. package/libs/Sculpt/Objects/Cylinder/index.js +35 -37
  114. package/libs/Sculpt/Objects/Line/Editor.d.ts +22 -0
  115. package/libs/Sculpt/Objects/Line/Editor.js +62 -0
  116. package/libs/Sculpt/Objects/Line/index.d.ts +33 -0
  117. package/libs/Sculpt/Objects/Line/index.js +107 -0
  118. package/libs/Sculpt/Objects/Point/index.d.ts +1 -1
  119. package/libs/Sculpt/Objects/Polygon/Editor.d.ts +2 -2
  120. package/libs/Sculpt/Objects/Polygon/Editor.js +5 -5
  121. package/libs/Sculpt/Objects/Polygon/index.d.ts +3 -2
  122. package/libs/Sculpt/Objects/Polygon/index.js +80 -80
  123. package/libs/Sculpt/Objects/Polyline/Editor.d.ts +3 -17
  124. package/libs/Sculpt/Objects/Polyline/Editor.js +10 -48
  125. package/libs/Sculpt/Objects/Polyline/index.d.ts +7 -6
  126. package/libs/Sculpt/Objects/Polyline/index.js +63 -58
  127. package/libs/Sculpt/Objects/Prism/index.js +56 -58
  128. package/libs/Sculpt/index.d.ts +5 -0
  129. package/libs/Sculpt/index.js +58 -48
  130. package/libs/Sculpt/typings/index.d.ts +11 -6
  131. package/libs/Sculpt/{utils/color.d.ts → typings/style.d.ts} +7 -0
  132. package/libs/Sculpt/typings/utils.type.d.ts +2 -0
  133. package/libs/Sculpt/utils/three/ColoredMesh.d.ts +1 -1
  134. package/libs/Sculpt/utils/three/ColoredMesh.js +15 -14
  135. package/libs/Sculpt/utils/three/rayOnLine.d.ts +3 -5
  136. package/libs/Sculpt/utils/three/rayOnLine.js +15 -14
  137. package/libs/base/BasePlugin.js +14 -13
  138. package/libs/floorplan/MapviewFloorplanPlugin/Controller.js +131 -61
  139. package/libs/floorplan/MapviewFloorplanPlugin/index.js +75 -6
  140. package/libs/floorplan/ModelFloorplanPlugin/Controller.js +129 -59
  141. package/libs/floorplan/ModelFloorplanPlugin/index.js +75 -5
  142. package/libs/floorplan/PanoFloorplanRadarPlugin/Controller.js +158 -86
  143. package/libs/floorplan/PanoFloorplanRadarPlugin/index.js +76 -4
  144. package/libs/floorplan/TopviewFloorplanPlugin/Controller.js +151 -81
  145. package/libs/floorplan/TopviewFloorplanPlugin/index.js +75 -5
  146. package/libs/floorplan/index.js +1 -0
  147. package/libs/index.js +194 -192
  148. package/libs/shared-utils/Object3DHelper/Controller/MoveController.js +1 -1
  149. package/libs/shared-utils/Object3DHelper/Controller/ScaleController.js +23 -23
  150. package/libs/shared-utils/Utils/WorkUtil.d.ts +6 -6
  151. package/libs/shared-utils/Utils/WorkUtil.js +8 -7
  152. package/libs/shared-utils/five/index.js +3 -2
  153. package/libs/shared-utils/five/lookObject.js +3 -2
  154. package/libs/shared-utils/logger.js +1 -1
  155. package/libs/shared-utils/tag.d.ts +6 -3
  156. package/libs/shared-utils/tag.js +38 -24
  157. package/libs/shared-utils/three/PointSelector/utils/PointSelectorHelper.js +15 -15
  158. package/libs/shared-utils/three/index.js +1 -0
  159. package/package.json +1 -1
  160. package/dist/Sculpt/typings/SimplifyDeep.d.ts +0 -3
  161. package/libs/Sculpt/typings/SimplifyDeep.d.ts +0 -3
  162. /package/libs/Sculpt/{utils/color.js → typings/style.js} +0 -0
@@ -1,44 +1,44 @@
1
- var B = Object.defineProperty, _ = Object.defineProperties;
2
- var x = Object.getOwnPropertyDescriptors;
1
+ var _ = Object.defineProperty, x = Object.defineProperties;
2
+ var E = Object.getOwnPropertyDescriptors;
3
3
  var f = Object.getOwnPropertySymbols;
4
- var E = Object.prototype.hasOwnProperty, O = Object.prototype.propertyIsEnumerable;
5
- var d = (n, i, e) => i in n ? B(n, i, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[i] = e, r = (n, i) => {
4
+ var L = Object.prototype.hasOwnProperty, O = Object.prototype.propertyIsEnumerable;
5
+ var d = (m, i, e) => i in m ? _(m, i, { enumerable: !0, configurable: !0, writable: !0, value: e }) : m[i] = e, r = (m, i) => {
6
6
  for (var e in i || (i = {}))
7
- E.call(i, e) && d(n, e, i[e]);
7
+ L.call(i, e) && d(m, e, i[e]);
8
8
  if (f)
9
9
  for (var e of f(i))
10
- O.call(i, e) && d(n, e, i[e]);
11
- return n;
12
- }, w = (n, i) => _(n, x(i));
13
- var a = (n, i, e) => (d(n, typeof i != "symbol" ? i + "" : i, e), e);
14
- var u = (n, i, e) => new Promise((t, o) => {
15
- var l = (c) => {
10
+ O.call(i, e) && d(m, e, i[e]);
11
+ return m;
12
+ }, w = (m, i) => x(m, E(i));
13
+ var h = (m, i, e) => (d(m, typeof i != "symbol" ? i + "" : i, e), e);
14
+ var c = (m, i, e) => new Promise((t, o) => {
15
+ var l = (u) => {
16
16
  try {
17
- m(e.next(c));
17
+ n(e.next(u));
18
18
  } catch (y) {
19
19
  o(y);
20
20
  }
21
- }, s = (c) => {
21
+ }, s = (u) => {
22
22
  try {
23
- m(e.throw(c));
23
+ n(e.throw(u));
24
24
  } catch (y) {
25
25
  o(y);
26
26
  }
27
- }, m = (c) => c.done ? t(c.value) : Promise.resolve(c.value).then(l, s);
28
- m((e = e.apply(n, i)).next());
27
+ }, n = (u) => u.done ? t(u.value) : Promise.resolve(u.value).then(l, s);
28
+ n((e = e.apply(m, i)).next());
29
29
  });
30
30
  import { globalModules as R } from "./utils/Modules/Global.js";
31
31
  import { Subscribe as S } from "../shared-utils/Subscribe.js";
32
- import { IObject3D as L } from "../shared-utils/three/IObject3D.js";
32
+ import { IObject3D as U } from "../shared-utils/three/IObject3D.js";
33
33
  import "three";
34
34
  import "hammerjs";
35
35
  import "three/examples/jsm/renderers/CSS3DRenderer";
36
36
  import "@realsee/five/line";
37
37
  import "../shared-utils/three/THREESphere.js";
38
38
  import "animejs";
39
- import { notNil as U } from "../shared-utils/isNil.js";
39
+ import { notNil as H } from "../shared-utils/isNil.js";
40
40
  import "../vendor/@tweenjs/tween/dist/tween.esm.js.js";
41
- import { recurveFindObject as H } from "../shared-utils/three/recurveFindObject.js";
41
+ import { recurveFindObject as M } from "../shared-utils/three/recurveFindObject.js";
42
42
  import { Polyline as g } from "./Objects/Polyline/index.js";
43
43
  import { Point as P } from "./Objects/Point/index.js";
44
44
  import { Polygon as I } from "./Objects/Polygon/index.js";
@@ -47,18 +47,19 @@ import { Rectangle as v } from "./Objects/Rectangle/index.js";
47
47
  import { Circle as C } from "./Objects/Circle/index.js";
48
48
  import { Cylinder as D } from "./Objects/Cylinder/index.js";
49
49
  import { Box as j } from "./Objects/Box/index.js";
50
- import { forReverseEach as M } from "../shared-utils/forReverseEach.js";
51
- const p = class extends S {
50
+ import { forReverseEach as k } from "../shared-utils/forReverseEach.js";
51
+ import { Line as B } from "./Objects/Line/index.js";
52
+ const a = class extends S {
52
53
  constructor(e, t) {
53
54
  super();
54
- a(this, "group");
55
- a(this, "five");
56
- a(this, "theme");
57
- this.five = e, this.theme = t, this.group = new L(), this.group.name = "Sculpt", e.scene.add(this.group), p.modules.init(e), p.modules.fiveDomEvents.addEventListener(this.group, "click", ({ intersects: o }) => {
55
+ h(this, "group");
56
+ h(this, "five");
57
+ h(this, "theme");
58
+ this.five = e, this.theme = t, this.group = new U(), this.group.name = "Sculpt", e.scene.add(this.group), a.modules.init(e), a.modules.fiveDomEvents.addEventListener(this.group, "click", ({ intersects: o }) => {
58
59
  var s;
59
- const l = H((s = o == null ? void 0 : o[0]) == null ? void 0 : s.object, (m) => m.isSculptObject);
60
+ const l = M((s = o == null ? void 0 : o[0]) == null ? void 0 : s.object, (n) => n.isSculptObject);
60
61
  return l ? this.emit("click", l) : !1;
61
- }), window.__SCLUPT_DEBUG__ = this, window.__SCLUPT_MODULES_DEBUG__ = p.modules;
62
+ }), window.__SCLUPT_DEBUG__ = this, window.__SCLUPT_MODULES_DEBUG__ = a.modules;
62
63
  }
63
64
  get data() {
64
65
  return {
@@ -68,7 +69,7 @@ const p = class extends S {
68
69
  } catch (t) {
69
70
  return console.error(t), null;
70
71
  }
71
- }).filter(U)
72
+ }).filter(H)
72
73
  };
73
74
  }
74
75
  get items() {
@@ -81,11 +82,11 @@ const p = class extends S {
81
82
  var l;
82
83
  this.clear();
83
84
  const o = (l = e == null ? void 0 : e.items) == null ? void 0 : l.map((s) => {
84
- var c;
85
- const m = w(r({}, s), {
86
- style: r(r({}, (c = this.theme) == null ? void 0 : c[s.type.toLowerCase()]), s.style)
85
+ var u;
86
+ const n = w(r({}, s), {
87
+ style: r(r({}, (u = this.theme) == null ? void 0 : u[s.type.toLowerCase()]), s.style)
87
88
  });
88
- return s.type === "Point" ? new P(m, t) : s.type === "Polyline" ? new g(m, t) : s.type === "Polygon" ? new I(m, t) : s.type === "Prism" ? new b(m, t) : s.type === "Rectangle" ? new v(m, t) : s.type === "Circle" ? new C(m, t) : s.type === "Cylinder" ? new D(m, t) : s.type === "Box" ? new j(m, t) : null;
89
+ return s.type === "Point" ? new P(n, t) : s.type === "line" ? new B(n, t) : s.type === "Polyline" ? new g(n, t) : s.type === "Polygon" ? new I(n, t) : s.type === "Prism" ? new b(n, t) : s.type === "Rectangle" ? new v(n, t) : s.type === "Circle" ? new C(n, t) : s.type === "Cylinder" ? new D(n, t) : s.type === "Box" ? new j(n, t) : null;
89
90
  });
90
91
  this.group.add(...o), this.five.needsRender = !0;
91
92
  }
@@ -101,23 +102,32 @@ const p = class extends S {
101
102
  putObject(e) {
102
103
  var l;
103
104
  this.group.add(e);
104
- const t = p.modules.object3DHelper, o = t.addObject3DHelper(e);
105
+ const t = a.modules.object3DHelper, o = t.addObject3DHelper(e);
105
106
  return (l = o == null ? void 0 : o.moveController) == null || l.moveByMouse(), t;
106
107
  }
107
108
  /**
108
109
  * @description: 开始绘制点
109
110
  */
110
111
  createPoint(e) {
111
- return u(this, null, function* () {
112
+ return c(this, null, function* () {
112
113
  var t;
113
114
  return this.createItem(P, r(r({}, (t = this.theme) == null ? void 0 : t.point), e));
114
115
  });
115
116
  }
117
+ /**
118
+ * @description: 开始绘制线段
119
+ */
120
+ createline(e) {
121
+ return c(this, null, function* () {
122
+ var t;
123
+ return this.createItem(B, r(r({}, (t = this.theme) == null ? void 0 : t.line), e));
124
+ });
125
+ }
116
126
  /**
117
127
  * @description: 开始绘制空间折线
118
128
  */
119
129
  createPolyline(e) {
120
- return u(this, null, function* () {
130
+ return c(this, null, function* () {
121
131
  var t;
122
132
  return this.createItem(g, r(r({}, (t = this.theme) == null ? void 0 : t.polyline), e));
123
133
  });
@@ -126,7 +136,7 @@ const p = class extends S {
126
136
  * @description: 开始绘制平面多边形
127
137
  */
128
138
  createPolygon(e) {
129
- return u(this, null, function* () {
139
+ return c(this, null, function* () {
130
140
  var t;
131
141
  return this.createItem(I, r(r({}, (t = this.theme) == null ? void 0 : t.polygon), e));
132
142
  });
@@ -135,7 +145,7 @@ const p = class extends S {
135
145
  * @description: 开始绘制多棱柱
136
146
  */
137
147
  createPrism(e) {
138
- return u(this, null, function* () {
148
+ return c(this, null, function* () {
139
149
  var t;
140
150
  return this.createItem(b, r(r({}, (t = this.theme) == null ? void 0 : t.prism), e));
141
151
  });
@@ -144,7 +154,7 @@ const p = class extends S {
144
154
  * @description: 开始绘制矩形
145
155
  */
146
156
  createRectangle(e) {
147
- return u(this, null, function* () {
157
+ return c(this, null, function* () {
148
158
  var t;
149
159
  return this.createItem(v, r(r({}, (t = this.theme) == null ? void 0 : t.rectangle), e));
150
160
  });
@@ -153,7 +163,7 @@ const p = class extends S {
153
163
  * @description: 开始绘制圆形
154
164
  */
155
165
  createCircle(e) {
156
- return u(this, null, function* () {
166
+ return c(this, null, function* () {
157
167
  var t;
158
168
  return this.createItem(C, r(r({}, (t = this.theme) == null ? void 0 : t.circle), e));
159
169
  });
@@ -162,7 +172,7 @@ const p = class extends S {
162
172
  * @description: 开始绘制圆柱
163
173
  */
164
174
  createCylinder(e) {
165
- return u(this, null, function* () {
175
+ return c(this, null, function* () {
166
176
  var t;
167
177
  return this.createItem(D, r(r({}, (t = this.theme) == null ? void 0 : t.cylinder), e));
168
178
  });
@@ -171,7 +181,7 @@ const p = class extends S {
171
181
  * @description: 开始绘制 Box
172
182
  */
173
183
  createBox(e) {
174
- return u(this, null, function* () {
184
+ return c(this, null, function* () {
175
185
  var t;
176
186
  return this.createItem(j, r(r({}, (t = this.theme) == null ? void 0 : t.box), e));
177
187
  });
@@ -190,10 +200,10 @@ const p = class extends S {
190
200
  * @description: 清空数据
191
201
  */
192
202
  clear() {
193
- M(this.items, (e) => e.delete()), this.five.needsRender = !0;
203
+ k(this.items, (e) => e.delete()), this.five.needsRender = !0;
194
204
  }
195
205
  createItem(e, ...t) {
196
- return u(this, null, function* () {
206
+ return c(this, null, function* () {
197
207
  const o = new e();
198
208
  return this.group.add(o), yield o.create(...t).catch((l) => {
199
209
  console.error(l), this.group.remove(o);
@@ -201,10 +211,10 @@ const p = class extends S {
201
211
  });
202
212
  }
203
213
  };
204
- let h = p;
205
- a(h, "modules", R);
206
- const se = (n) => new h(n);
214
+ let p = a;
215
+ h(p, "modules", R);
216
+ const me = (m) => new p(m);
207
217
  export {
208
- h as Sculpt,
209
- se as SculptPlugin
218
+ p as Sculpt,
219
+ me as SculptPlugin
210
220
  };
@@ -1,8 +1,9 @@
1
- import type { SimplifyDeep } from './SimplifyDeep';
2
1
  import type { PartialDeep } from 'type-fest';
3
- export type { SimplifyDeep } from './SimplifyDeep';
4
- import type { Polyline, PolylineImportData } from '../Objects/Polyline';
2
+ import type { SimplifyDeep } from './utils.type';
3
+ export type { SimplifyDeep };
5
4
  import type { Point, PointImportData } from '../Objects/Point';
5
+ import type { Line, LineImportData } from '../Objects/Line';
6
+ import type { Polyline, PolylineImportData } from '../Objects/Polyline';
6
7
  import type { Polygon, PolygonImportData } from '../Objects/Polygon';
7
8
  import type { Prism, PrismImportData } from '../Objects/Prism';
8
9
  import type { Rectangle, RectangleImportData } from '../Objects/Rectangle';
@@ -10,6 +11,7 @@ import type { Circle, CircleImportData } from '../Objects/Circle';
10
11
  import type { Cylinder, CylinderImportData } from '../Objects/Cylinder';
11
12
  import type { Box, BoxImportData } from '../Objects/Box';
12
13
  import type { PointStyle } from '../Meshes/Point';
14
+ import type { LineMeshStyle } from '../Meshes/Line';
13
15
  import type { PolylineStyle } from '../Meshes/Polyline';
14
16
  import type { PrismStyle } from '../Meshes/Prism';
15
17
  import type { RectangleWithEdgeMeshStyle as RectangleStyle } from '../Meshes/RectangleWithEdge';
@@ -27,8 +29,9 @@ export declare namespace SculptData {
27
29
  type CylinderData = SimplifyDeep<CylinderImportData>;
28
30
  type BoxData = SimplifyDeep<BoxImportData>;
29
31
  }
30
- export type { Polyline, PolylineImportData };
31
32
  export type { Point, PointImportData };
33
+ export type { Line, LineImportData };
34
+ export type { Polyline, PolylineImportData };
32
35
  export type { Polygon, PolygonImportData };
33
36
  export type { Prism, PrismImportData };
34
37
  export type { Rectangle, RectangleImportData };
@@ -36,6 +39,7 @@ export type { Circle, CircleImportData };
36
39
  export type { Cylinder, CylinderImportData };
37
40
  export type { Box, BoxImportData };
38
41
  export type { PointStyle };
42
+ export type { LineMeshStyle };
39
43
  export type { PolylineStyle };
40
44
  export type { PrismStyle };
41
45
  export type { RectangleStyle };
@@ -43,10 +47,11 @@ export type { CircleStyle };
43
47
  export type { CylinderStyle };
44
48
  export type { BoxStyle };
45
49
  export type { AreaStyle };
46
- export type BuiltInData = PolylineImportData | PointImportData | PolygonImportData | PrismImportData | RectangleImportData | CircleImportData | CylinderImportData | BoxImportData;
47
- export type BuiltInItem = Polyline | Point | Polygon | Prism | Rectangle | Circle | Cylinder | Box;
50
+ export type BuiltInData = PolylineImportData | PointImportData | PolygonImportData | PrismImportData | RectangleImportData | CircleImportData | CylinderImportData | BoxImportData | LineImportData;
51
+ export type BuiltInItem = Polyline | Point | Polygon | Prism | Rectangle | Circle | Cylinder | Box | Line;
48
52
  export type Theme = PartialDeep<{
49
53
  point: PointStyle;
54
+ line: LineMeshStyle;
50
55
  polyline: PolylineStyle;
51
56
  polygon: AreaStyle;
52
57
  prism: PrismStyle;
@@ -31,6 +31,13 @@ export type LineWidthStyle = {
31
31
  */
32
32
  lineWidth?: number;
33
33
  };
34
+ export type LimitPlaneConfig = {
35
+ /**
36
+ * @description 限制折线绘制的平面; `xoz` 限制在水平面; `y` 限制垂直面; `none` 不限制
37
+ * @default `none`
38
+ */
39
+ limit: 'xoz' | 'y' | 'none';
40
+ };
34
41
  export type OcclusionStyle = {
35
42
  /**
36
43
  * @description 是否以一种半透明的方式显示遮挡的部分
@@ -1,6 +1,8 @@
1
1
  import type * as THREE from 'three';
2
2
  import type { Merge, UnknownArray } from 'type-fest';
3
+ import type { ConditionalSimplifyDeep } from 'type-fest/source/conditional-simplify';
3
4
  import type { IsNull, NonRecursiveType } from 'type-fest/source/internal';
5
+ export type SimplifyDeep<T> = ConditionalSimplifyDeep<T, THREE.Color | THREE.Vector3 | Function | Iterable<unknown>, object>;
4
6
  export type ImportDataToExportData<T> = Merge<JsonData<T>, {
5
7
  id: string | number;
6
8
  }>;
@@ -1,5 +1,5 @@
1
1
  import * as THREE from 'three';
2
- import { type ColorStyle, type OpacityStyle, type OcclusionStyle } from '../color';
2
+ import { type ColorStyle, type OpacityStyle, type OcclusionStyle } from '../../typings/style';
3
3
  import { IObject3D } from '../../../shared-utils/three/IObject3D';
4
4
  export type ColoredMeshStyle = OpacityStyle & ColorStyle & OcclusionStyle;
5
5
  export default class ColoredMesh<TGeometry extends THREE.Geometry | THREE.BufferGeometry = THREE.Geometry | THREE.BufferGeometry> extends IObject3D {
@@ -9,28 +9,29 @@ var d = (i, t, e) => t in i ? g(i, t, { enumerable: !0, configurable: !0, writab
9
9
  F.call(t, e) && d(i, e, t[e]);
10
10
  return i;
11
11
  };
12
- var c = (i, t, e) => (d(i, typeof t != "symbol" ? t + "" : t, e), e);
12
+ var r = (i, t, e) => (d(i, typeof t != "symbol" ? t + "" : t, e), e);
13
13
  import * as s from "three";
14
- import { DEFAULT_COLOR as M } from "../color.js";
14
+ import { DEFAULT_COLOR as M } from "../../typings/style.js";
15
15
  import { IObject3D as B } from "../../../shared-utils/three/IObject3D.js";
16
16
  import "hammerjs";
17
17
  import "three/examples/jsm/renderers/CSS3DRenderer";
18
18
  import "@realsee/five/line";
19
+ import "../Modules/Global.js";
19
20
  import "../../../shared-utils/three/THREESphere.js";
20
21
  import "animejs";
21
22
  import { notNil as m } from "../../../shared-utils/isNil.js";
22
23
  import "../../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
23
- class R extends B {
24
+ class _ extends B {
24
25
  constructor(e) {
25
26
  var h, y;
26
27
  super();
27
- c(this, "name", "ColoredMesh");
28
- c(this, "meshFont");
29
- c(this, "meshBackground");
30
- c(this, "paramsStyle", {});
31
- c(this, "_geometry", new s.BufferGeometry());
28
+ r(this, "name", "ColoredMesh");
29
+ r(this, "meshFont");
30
+ r(this, "meshBackground");
31
+ r(this, "paramsStyle", {});
32
+ r(this, "_geometry", new s.BufferGeometry());
32
33
  this.paramsStyle = e != null ? e : {};
33
- const r = new s.MeshBasicMaterial({
34
+ const c = new s.MeshBasicMaterial({
34
35
  color: (h = e == null ? void 0 : e.color) != null ? h : M,
35
36
  transparent: !0,
36
37
  side: s.DoubleSide,
@@ -42,8 +43,8 @@ class R extends B {
42
43
  side: s.DoubleSide,
43
44
  depthTest: !1,
44
45
  depthWrite: !1,
45
- opacity: 0.3 / 0.5 * r.opacity
46
- }), o = new s.Mesh(this.geometry, r), n = new s.Mesh(this.geometry, l);
46
+ opacity: 0.3 / 0.5 * c.opacity
47
+ }), o = new s.Mesh(this.geometry, c), n = new s.Mesh(this.geometry, l);
47
48
  o.name = "MeshFront", n.name = "MeshBackground", o.renderOrder = 1, n.renderOrder = 0, this.meshFont = o, this.meshBackground = n, this.add(o), this.setOcclusionVisibility({ occlusionVisibility: e == null ? void 0 : e.occlusionVisibility, occlusionMode: e == null ? void 0 : e.occlusionMode });
48
49
  }
49
50
  get color() {
@@ -69,10 +70,10 @@ class R extends B {
69
70
  }
70
71
  setOcclusionVisibility(e) {
71
72
  var o, n, h;
72
- const r = (n = (o = e.occlusionMode) != null ? o : this.paramsStyle.occlusionMode) != null ? n : "translucence", l = (h = e.occlusionVisibility) != null ? h : this.paramsStyle.occlusionVisibility;
73
- m(l) && (l ? r === "depthTest" ? (this.meshFont.material.depthTest = !1, this.remove(this.meshBackground)) : r === "translucence" && (this.meshFont.material.depthTest = !0, this.addIfNotExists(this.meshBackground)) : (this.meshFont.material.depthTest = !0, this.remove(this.meshBackground)));
73
+ const c = (n = (o = e.occlusionMode) != null ? o : this.paramsStyle.occlusionMode) != null ? n : "translucence", l = (h = e.occlusionVisibility) != null ? h : this.paramsStyle.occlusionVisibility;
74
+ m(l) && (l ? c === "depthTest" ? (this.meshFont.material.depthTest = !1, this.remove(this.meshBackground)) : c === "translucence" && (this.meshFont.material.depthTest = !0, this.addIfNotExists(this.meshBackground)) : (this.meshFont.material.depthTest = !0, this.remove(this.meshBackground)));
74
75
  }
75
76
  }
76
77
  export {
77
- R as ColoredMesh
78
+ _ as ColoredMesh
78
79
  };
@@ -1,13 +1,11 @@
1
1
  import * as THREE from 'three';
2
2
  /**
3
3
  * @description: 求射线与线段的交点(交点在线段上)
4
- * @param {THREE.Vector3} cameraPosition 摄像机位置
5
- * @param {THREE.Ray} ray 射线
6
- * @param {THREE.Line3} line 线段
7
- * @param {boolean} clampToLine 是否限制交点在线段上,默认为true,不限制则可以相交在线段的延长线上
4
+ * @param {THREE.Raycaster} params.ray 射线
5
+ * @param {THREE.Line3} params.line 线段
6
+ * @param {boolean} params.clampToLine `true` 限制交点在线段上, `false` 可以相交在线段的延长线上;默认为`true`
8
7
  */
9
8
  export declare function rayOnLine(params: {
10
- cameraPosition: THREE.Vector3;
11
9
  raycaster: THREE.Raycaster;
12
10
  line: THREE.Line3;
13
11
  clampToLine?: boolean;
@@ -1,20 +1,21 @@
1
- import * as e from "three";
2
- function w(m) {
3
- var p;
4
- const { cameraPosition: r, raycaster: a, line: n, clampToLine: T = !0 } = m;
5
- if (((p = a.camera) == null ? void 0 : p.type) === "OrthographicCamera") {
6
- const t = a.ray.origin.clone();
7
- return n.closestPointToPoint(t, !1, new e.Vector3());
1
+ import * as t from "three";
2
+ const y = new t.Vector3();
3
+ function O(p) {
4
+ var d;
5
+ const { raycaster: e, line: n, clampToLine: m = !0 } = p;
6
+ if (((d = e.camera) == null ? void 0 : d.type) === "OrthographicCamera") {
7
+ const o = e.ray.origin.clone();
8
+ return n.closestPointToPoint(o, !1, new t.Vector3());
8
9
  }
9
- const s = new e.Plane().setFromNormalAndCoplanarPoint(a.ray.direction.clone().normalize(), r), o = s.projectPoint(n.start, new e.Vector3()), l = s.projectPoint(n.end, new e.Vector3()), P = new e.Line3(o, l), c = P.closestPointToPoint(r, T, new e.Vector3()), d = c.distanceTo(l), u = c.distanceTo(o), i = P.distance();
10
- if (d > u && d > i) {
11
- const t = -c.distanceTo(o) / i, O = n.start.clone().sub(n.end).normalize();
12
- return n.start.sub(O.clone().multiplyScalar(t * n.distance()));
10
+ const a = new t.Plane().setFromNormalAndCoplanarPoint(e.ray.direction.clone().normalize(), e.ray.origin), r = a.projectPoint(n.start, new t.Vector3()), s = a.projectPoint(n.end, new t.Vector3()), l = new t.Line3(r, s), c = l.closestPointToPoint(e.ray.origin, m, y), P = c.distanceTo(s), T = c.distanceTo(r), i = l.distance();
11
+ if (P > T && P > i) {
12
+ const o = -c.distanceTo(r) / i, u = n.start.clone().sub(n.end).normalize();
13
+ return n.start.sub(u.clone().multiplyScalar(o * n.distance()));
13
14
  } else {
14
- const t = c.distanceTo(o) / i;
15
- return new e.Vector3().lerpVectors(n.start, n.end, t);
15
+ const o = c.distanceTo(r) / i;
16
+ return new t.Vector3().lerpVectors(n.start, n.end, o);
16
17
  }
17
18
  }
18
19
  export {
19
- w as rayOnLine
20
+ O as rayOnLine
20
21
  };
@@ -1,31 +1,32 @@
1
1
  var o = Object.defineProperty;
2
- var s = (i, t, r) => t in i ? o(i, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : i[t] = r;
3
- var e = (i, t, r) => (s(i, typeof t != "symbol" ? t + "" : t, r), r);
2
+ var s = (e, t, r) => t in e ? o(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r;
3
+ var i = (e, t, r) => (s(e, typeof t != "symbol" ? t + "" : t, r), r);
4
4
  import { Subscribe as l } from "../shared-utils/Subscribe.js";
5
5
  import "three";
6
6
  import "hammerjs";
7
7
  import "three/examples/jsm/renderers/CSS3DRenderer";
8
8
  import "@realsee/five/line";
9
+ import "../Sculpt/utils/Modules/Global.js";
9
10
  import "../shared-utils/three/THREESphere.js";
10
11
  import "animejs";
11
12
  import { FiveUtil as a } from "../shared-utils/Utils/FiveUtil.js";
12
- import { absoluteUrl as h } from "../shared-utils/url/absoluteUrl.js";
13
+ import { absoluteUrl as m } from "../shared-utils/url/absoluteUrl.js";
13
14
  import "../vendor/@tweenjs/tween/dist/tween.esm.js.js";
14
- let c = class {
15
+ let x = class {
15
16
  constructor(t, r) {
16
17
  /**
17
18
  * @realsee/dnalogel 版本号
18
19
  */
19
- e(this, "VERSION", "3.44.5");
20
- e(this, "NAME");
21
- e(this, "five");
22
- e(this, "workUtil");
23
- e(this, "fiveUtil");
20
+ i(this, "VERSION", "3.46.0");
21
+ i(this, "NAME");
22
+ i(this, "five");
23
+ i(this, "workUtil");
24
+ i(this, "fiveUtil");
24
25
  /**
25
26
  * @description: 插件事件钩子
26
27
  */
27
- e(this, "hooks", new l());
28
- e(this, "staticPrefix", "//vr-image-4.realsee-cdn.cn");
28
+ i(this, "hooks", new l());
29
+ i(this, "staticPrefix", "//vr-image-4.realsee-cdn.cn");
29
30
  this.updateFive(t), r != null && r.staticPrefix && (this.staticPrefix = r.staticPrefix);
30
31
  }
31
32
  set workCode(t) {
@@ -47,11 +48,11 @@ let c = class {
47
48
  * @description: 获取静态资源的url
48
49
  */
49
50
  absoluteUrl(t) {
50
- return h(this.staticPrefix, t);
51
+ return m(this.staticPrefix, t);
51
52
  }
52
53
  onWorkCodeChange() {
53
54
  }
54
55
  };
55
56
  export {
56
- c as Controller
57
+ x as Controller
57
58
  };