@realsee/dnalogel 2.6.6 → 2.6.7-dev.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 (369) hide show
  1. package/dist/CSS3DRenderPlugin/Controller.d.ts +1 -1
  2. package/dist/Object3DHelperPlugin/Controller.d.ts +25 -10
  3. package/dist/Object3DHelperPlugin/FiveControllerWrapper.d.ts +6 -8
  4. package/dist/Object3DHelperPlugin/typings.d.ts +14 -0
  5. package/dist/PanoTagPlugin/controller/TagCacheController.d.ts +1 -0
  6. package/dist/PanoTagPlugin/controller/TagComputer.d.ts +22 -6
  7. package/dist/PanoTagPlugin/controller/index.d.ts +32 -6
  8. package/dist/PanoTagPlugin/typings/controller.d.ts +17 -2
  9. package/dist/PanoTagPlugin/typings/tag/Tag.d.ts +5 -2
  10. package/dist/PanoTagPlugin/typings/tag/TagData.d.ts +19 -3
  11. package/dist/PanoTagPlugin/typings/tag/Utils.d.ts +1 -1
  12. package/dist/PanoTagPlugin/utils/tag/index.d.ts +2 -0
  13. package/dist/PanoTagPlugin/utils/tag/tagCheck.d.ts +2 -1
  14. package/dist/PanoTagPlugin/utils/tagPosition.d.ts +3 -1
  15. package/dist/index.cjs.js +43 -43
  16. package/dist/index.js +5075 -4664
  17. package/dist/index.umd.js +32 -32
  18. package/dist/shared-utils/Object3DHelper/Base/BaseController.d.ts +41 -15
  19. package/dist/shared-utils/Object3DHelper/Base/BaseHelper.d.ts +27 -20
  20. package/dist/shared-utils/Object3DHelper/Controller/BoundingBoxController.d.ts +7 -0
  21. package/dist/shared-utils/Object3DHelper/Controller/CSS3DScaleController.d.ts +1 -0
  22. package/dist/shared-utils/Object3DHelper/Controller/MoveController.d.ts +24 -0
  23. package/dist/shared-utils/Object3DHelper/Controller/RectangleScaleController.d.ts +6 -1
  24. package/dist/shared-utils/Object3DHelper/Controller/RotateController.d.ts +14 -0
  25. package/dist/shared-utils/Object3DHelper/Controller/ScaleController.d.ts +12 -0
  26. package/dist/shared-utils/Object3DHelper/Helper/{OutlineHelper.d.ts → BoundingBoxHelper.d.ts} +3 -2
  27. package/{libs/shared-utils/Object3DHelper/Helper/RectangleScaleHelper.d.ts → dist/shared-utils/Object3DHelper/Helper/CSS3DScaleHelper.d.ts} +3 -8
  28. package/dist/shared-utils/Object3DHelper/Helper/RotateHelper.d.ts +14 -11
  29. package/dist/shared-utils/Object3DHelper/Helper/ScaleHelper.d.ts +5 -0
  30. package/dist/shared-utils/Object3DHelper/Helper/index.d.ts +2 -2
  31. package/dist/shared-utils/Object3DHelper/index.d.ts +4 -27
  32. package/dist/shared-utils/Object3DHelper/typings/Hooks.d.ts +22 -12
  33. package/dist/shared-utils/Object3DHelper/typings/index.d.ts +22 -0
  34. package/dist/shared-utils/Object3DHelper/utils/boundingBox.d.ts +2 -0
  35. package/dist/shared-utils/three/GLTFLoader.d.ts +2 -0
  36. package/docs/assets/search.js +1 -1
  37. package/docs/classes/CSS3DRender.html +31 -31
  38. package/docs/classes/CruisePluginController.html +24 -24
  39. package/docs/classes/Magnifier.html +20 -20
  40. package/docs/classes/ModelRoomLabelController.html +11 -11
  41. package/docs/classes/Object3DHelperController.html +40 -33
  42. package/docs/classes/PaintBrush.html +15 -15
  43. package/docs/classes/PanoMeasurePluginLine.html +23 -23
  44. package/docs/classes/PanoMeasurePluginModel.html +22 -22
  45. package/docs/classes/PanoMeasurePluginPoint.html +14 -14
  46. package/docs/classes/PanoMeasurePluginPolyline.html +26 -26
  47. package/docs/classes/PanoTagPluginController.html +205 -77
  48. package/docs/classes/Util.BetterTween.html +8 -8
  49. package/docs/classes/Util.FivePointSelector.html +12 -12
  50. package/docs/classes/Util.Interval.html +12 -12
  51. package/docs/classes/Util.Magnifier.html +17 -17
  52. package/docs/classes/Util.PointDomHelper.html +11 -11
  53. package/docs/classes/Util.PointHelper.html +11 -11
  54. package/docs/classes/Util.Rectangle.html +13 -13
  55. package/docs/enums/CameraMovementEffect.html +7 -7
  56. package/docs/enums/ContentType.html +34 -16
  57. package/docs/enums/DIRECTION.html +9 -9
  58. package/docs/enums/DISPLAY_STRATEGY_TYPE.html +9 -9
  59. package/docs/enums/DimensionType.html +7 -7
  60. package/docs/enums/FLOOR_PLAN_ATTACHED_TO.html +8 -8
  61. package/docs/enums/ITEM_LABEL_PLUGIN_DISPLAY_STRATEGY_TYPE.html +9 -9
  62. package/docs/enums/PaintBrushTypeEnum.html +8 -8
  63. package/docs/enums/PointType.html +7 -7
  64. package/docs/enums/Rotation.html +8 -8
  65. package/docs/functions/CSS3DRenderPlugin.html +10 -5
  66. package/docs/functions/CameraMovementPlugin.html +10 -5
  67. package/docs/functions/CruisePlugin.html +10 -5
  68. package/docs/functions/GuideLinePlugin.html +10 -5
  69. package/docs/functions/ItemLabelPlugin.html +10 -5
  70. package/docs/functions/MapviewFloorplanPlugin.html +10 -5
  71. package/docs/functions/ModelChassisCompassPlugin.html +10 -5
  72. package/docs/functions/ModelEntryDoorGuidePlugin.html +10 -5
  73. package/docs/functions/ModelFloorplanPlugin.html +10 -5
  74. package/docs/functions/ModelItemLabelPlugin.html +10 -5
  75. package/docs/functions/ModelRoomLabelPlugin.html +10 -5
  76. package/docs/functions/ModelTVVideoPlugin.html +10 -5
  77. package/docs/functions/ModelViewPlugin.html +10 -5
  78. package/docs/functions/Object3DHelperPlugin.html +10 -5
  79. package/docs/functions/PanoCompassPlugin.html +10 -5
  80. package/docs/functions/PanoCursorRaycasterPlugin.html +10 -5
  81. package/docs/functions/PanoDoorLabelPlugin.html +10 -5
  82. package/docs/functions/PanoFloorplanRadarPlugin.html +10 -5
  83. package/docs/functions/PanoMeasurePlugin.html +10 -5
  84. package/docs/functions/PanoRulerPlugin.html +10 -5
  85. package/docs/functions/PanoRulerProPlugin.html +10 -5
  86. package/docs/functions/PanoSpatialTagPlugin.html +10 -5
  87. package/docs/functions/PanoTagPlugin.html +15 -10
  88. package/docs/functions/TopviewFloorplanPlugin.html +10 -5
  89. package/docs/functions/Util.getCoordsFromClient.html +5 -5
  90. package/docs/functions/Util.getCoordsFromElement.html +5 -5
  91. package/docs/functions/Util.getFrameTime.html +5 -5
  92. package/docs/functions/Util.getIntersectFromRelativePosition.html +5 -5
  93. package/docs/functions/Util.getRaycasterFromFivePointer.html +5 -5
  94. package/docs/functions/Util.isNil.html +5 -5
  95. package/docs/functions/Util.nextFrame.html +5 -5
  96. package/docs/functions/Util.notNil.html +5 -5
  97. package/docs/functions/Util.requestAnimationFrameInterval.html +5 -5
  98. package/docs/functions/Util.tweenProgress.html +5 -5
  99. package/docs/functions/pluginFlag.html +10 -5
  100. package/docs/index.html +9 -4
  101. package/docs/interfaces/AddTagConfig.html +6 -6
  102. package/docs/interfaces/CSS3DRenderPluginEventMap.html +11 -11
  103. package/docs/interfaces/CSS3DRenderPluginState.html +8 -8
  104. package/docs/interfaces/CameraMovementPluginExportType.html +7 -7
  105. package/docs/interfaces/EventMap.html +19 -19
  106. package/docs/interfaces/FloorplanBounding.html +8 -8
  107. package/docs/interfaces/FloorplanData.html +10 -10
  108. package/docs/interfaces/FloorplanEntrance.html +11 -11
  109. package/docs/interfaces/FloorplanExtraObject.html +10 -10
  110. package/docs/interfaces/FloorplanExtraObject3D.html +8 -8
  111. package/docs/interfaces/FloorplanFloorData.html +9 -9
  112. package/docs/interfaces/FloorplanImagePosition.html +7 -7
  113. package/docs/interfaces/FloorplanObserver.html +9 -9
  114. package/docs/interfaces/FloorplanOutlineItem.html +9 -9
  115. package/docs/interfaces/FloorplanPosition.html +7 -7
  116. package/docs/interfaces/FloorplanRoomItem.html +13 -13
  117. package/docs/interfaces/FloorplanRoomLabelItem.html +7 -7
  118. package/docs/interfaces/FloorplanServerBounding.html +8 -8
  119. package/docs/interfaces/FloorplanServerComputedData.html +10 -10
  120. package/docs/interfaces/FloorplanServerData.html +7 -7
  121. package/docs/interfaces/FloorplanServerDoorItem.html +10 -10
  122. package/docs/interfaces/FloorplanServerDoorPosition.html +8 -8
  123. package/docs/interfaces/FloorplanServerEntrance.html +11 -11
  124. package/docs/interfaces/FloorplanServerFloorData.html +9 -9
  125. package/docs/interfaces/FloorplanServerImagePosition.html +7 -7
  126. package/docs/interfaces/FloorplanServerObserver.html +9 -9
  127. package/docs/interfaces/FloorplanServerOutlineItem.html +9 -9
  128. package/docs/interfaces/FloorplanServerPosition.html +7 -7
  129. package/docs/interfaces/FloorplanServerRoomItem.html +14 -14
  130. package/docs/interfaces/FloorplanServerRoomLabelItem.html +7 -7
  131. package/docs/interfaces/HelperOffset.html +78 -0
  132. package/docs/interfaces/ItemLabelPluginData.html +6 -6
  133. package/docs/interfaces/ItemLabelPluginExportReturnsType.html +11 -11
  134. package/docs/interfaces/ItemLabelPluginParametersType.html +9 -9
  135. package/docs/interfaces/MinMax.html +7 -7
  136. package/docs/interfaces/ModelChassisCompassPluginData.html +7 -7
  137. package/docs/interfaces/ModelChassisCompassPluginExportType.html +8 -8
  138. package/docs/interfaces/ModelChassisCompassPluginParameterType.html +7 -7
  139. package/docs/interfaces/ModelEntryDoorGuidePluginData.html +8 -8
  140. package/docs/interfaces/ModelEntryDoorGuidePluginExportType.html +8 -8
  141. package/docs/interfaces/ModelItemLabelPluginData.html +6 -6
  142. package/docs/interfaces/ModelItemLabelPluginExportReturnsType.html +11 -11
  143. package/docs/interfaces/ModelItemLabelPluginParametersType.html +7 -7
  144. package/docs/interfaces/ModelRoomLabelPluginData.html +6 -6
  145. package/docs/interfaces/ModelTVVideoPluginData.html +9 -9
  146. package/docs/interfaces/ModelTVVideoPluginExportType.html +8 -8
  147. package/docs/interfaces/ModelTVVideoPluginParameterType.html +6 -6
  148. package/docs/interfaces/ModelViewPluginExportType.html +11 -11
  149. package/docs/interfaces/Object3DHelperState.html +8 -8
  150. package/docs/interfaces/ObjectHelperControllers.html +85 -0
  151. package/docs/interfaces/PaintBrushAction.html +12 -12
  152. package/docs/interfaces/PaintBrushConfigs.html +12 -12
  153. package/docs/interfaces/PaintBrushState.html +10 -10
  154. package/docs/interfaces/PanoCursorRaycasterPluginExportType.html +10 -10
  155. package/docs/interfaces/PanoCursorRaycasterPluginParameterType.html +10 -5
  156. package/docs/interfaces/PanoMeasureParameterType.html +12 -12
  157. package/docs/interfaces/PanoMeasurePluginLineJson.html +8 -8
  158. package/docs/interfaces/PanoMeasurePluginOpenParameter.html +7 -7
  159. package/docs/interfaces/PanoMeasurePluginPointJson.html +7 -7
  160. package/docs/interfaces/PanoMeasurePluginPolylineJson.html +8 -8
  161. package/docs/interfaces/PanoRulerPluginExportType.html +10 -10
  162. package/docs/interfaces/PanoRulerPluginOptions.html +7 -7
  163. package/docs/interfaces/PanoRulerPluginParameterType.html +8 -8
  164. package/docs/interfaces/PanoRulerProPluginExportType.html +9 -9
  165. package/docs/interfaces/PanoRulerProPluginOptions.html +7 -7
  166. package/docs/interfaces/PanoRulerProPluginParameterType.html +7 -7
  167. package/docs/interfaces/PanoRulerProPluginState.html +8 -8
  168. package/docs/interfaces/PanoSpatialTagPluginContentEvent.html +10 -5
  169. package/docs/interfaces/PanoSpatialTagPluginContentReplacement.html +10 -5
  170. package/docs/interfaces/PanoSpatialTagPluginData.html +11 -11
  171. package/docs/interfaces/PanoSpatialTagPluginDataElement.html +10 -10
  172. package/docs/interfaces/PanoSpatialTagPluginExportType.html +13 -13
  173. package/docs/interfaces/PanoSpatialTagPluginOriginElement.html +10 -10
  174. package/docs/interfaces/PanoSpatialTagPluginParameterType.html +13 -13
  175. package/docs/interfaces/PanoSpatialTagPluginPointElement.html +11 -11
  176. package/docs/interfaces/PanoSpatialTagPluginTagElement.html +10 -10
  177. package/docs/interfaces/Point.html +8 -8
  178. package/docs/interfaces/Room.html +9 -9
  179. package/docs/interfaces/RoomInfo.html +7 -7
  180. package/docs/interfaces/RoomLabel.html +14 -14
  181. package/docs/interfaces/RoomRules.html +10 -5
  182. package/docs/interfaces/Rooms.html +10 -5
  183. package/docs/interfaces/Scissor.html +9 -9
  184. package/docs/interfaces/State.html +8 -8
  185. package/docs/interfaces/TagCache.html +25 -16
  186. package/docs/interfaces/TagConfig.html +10 -10
  187. package/docs/interfaces/TagIconUrl.html +9 -9
  188. package/docs/interfaces/Tags.html +11 -11
  189. package/docs/interfaces/TemporaryState.html +6 -6
  190. package/docs/interfaces/Util.MagnifierParameter.html +11 -11
  191. package/docs/interfaces/Util.MouseGroupParameter.html +8 -8
  192. package/docs/modules/Util.html +5 -5
  193. package/docs/modules.html +14 -4
  194. package/docs/types/ArrayPosition.html +10 -5
  195. package/docs/types/AudioAppearance.html +10 -5
  196. package/docs/types/AudioTagTypeConfigKey.html +10 -5
  197. package/docs/types/CSS3DRenderExportType.html +10 -5
  198. package/docs/types/CSS3DRenderPluginExportType.html +10 -5
  199. package/docs/types/CSS3DRenderPluginParameterType.html +10 -5
  200. package/docs/types/ClassFunctionParameters.html +268 -0
  201. package/docs/types/Color.html +10 -5
  202. package/docs/types/ContentTypeConfigKey.html +10 -5
  203. package/docs/types/ContentTypeConfigKeySplit.html +10 -5
  204. package/docs/types/ContentTypeMap.html +10 -5
  205. package/docs/types/Create3DDomContainerReturnType.html +10 -5
  206. package/docs/types/Create3DElementReturnType.html +10 -5
  207. package/docs/types/CruisePluginExportType.html +10 -5
  208. package/docs/types/Direction-1.html +10 -5
  209. package/docs/types/Direction4.html +10 -5
  210. package/docs/types/FloorplanRuleLabels.html +10 -5
  211. package/docs/types/FloorplanServerRuleLabels.html +10 -5
  212. package/docs/types/GuideLinePluginExportType.html +10 -5
  213. package/docs/types/HelperEventMap.html +174 -21
  214. package/docs/types/LoadTagConfig.html +10 -5
  215. package/docs/types/MapviewFloorplanPluginParameterType.html +10 -5
  216. package/docs/types/MapviewFloorplanPluginReturnType.html +10 -5
  217. package/docs/types/MediaData.html +10 -5
  218. package/docs/types/MediaStore.html +10 -5
  219. package/docs/types/ModelElement.html +266 -0
  220. package/docs/types/ModelEntryDoorGuidePluginParameterType.html +10 -5
  221. package/docs/types/ModelFloorplanPluginParameterType.html +10 -5
  222. package/docs/types/ModelFloorplanPluginReturnType.html +10 -5
  223. package/docs/types/ModelRoomLabelPluginParameters.html +10 -5
  224. package/docs/types/ModelRoomLabelPluginReturnType.html +10 -5
  225. package/docs/types/MoveArgs.html +10 -5
  226. package/docs/types/MoveOpts.html +10 -5
  227. package/docs/types/Object3DHelperEventMap.html +10 -5
  228. package/docs/types/ObjectFit.html +10 -5
  229. package/docs/types/PaintBrushEventMap.html +10 -5
  230. package/docs/types/PanoCompassPluginData.html +10 -5
  231. package/docs/types/PanoCompassPluginExportType.html +10 -5
  232. package/docs/types/PanoCompassPluginParameterType.html +10 -5
  233. package/docs/types/PanoFloorplanRadarPluginParameterType.html +10 -5
  234. package/docs/types/PanoFloorplanRadarPluginReturnType.html +10 -5
  235. package/docs/types/PanoIndex.html +10 -5
  236. package/docs/types/PanoMeasurePluginEvent.html +10 -5
  237. package/docs/types/PanoMeasureReturnType.html +10 -5
  238. package/docs/types/PanoSpatialTagPluginId.html +10 -5
  239. package/docs/types/PanoTagPluginExportInterface.html +10 -5
  240. package/docs/types/PanoTagPluginParamsInterface.html +10 -5
  241. package/docs/types/PlaneTag.html +10 -5
  242. package/docs/types/PlaneTagElement.html +10 -5
  243. package/docs/types/Point2DElement.html +10 -5
  244. package/docs/types/Point2DTag.html +10 -5
  245. package/docs/types/Point3DElement.html +10 -5
  246. package/docs/types/Point3DTag.html +10 -5
  247. package/docs/types/PointTag.html +10 -5
  248. package/docs/types/PointTagElement.html +10 -5
  249. package/docs/types/Position.html +10 -5
  250. package/docs/types/RotateArgs.html +10 -5
  251. package/docs/types/RotateOpts.html +10 -5
  252. package/docs/types/RuleLabelsKey.html +10 -5
  253. package/docs/types/RuleLabelsValue.html +10 -5
  254. package/docs/types/StickType.html +11 -6
  255. package/docs/types/Tag.html +11 -6
  256. package/docs/types/Tag2D.html +10 -5
  257. package/docs/types/Tag3D.html +10 -5
  258. package/docs/types/TagContentType.html +11 -6
  259. package/docs/types/TagDimensionType.html +10 -5
  260. package/docs/types/TagElement.html +11 -6
  261. package/docs/types/TagEvents.html +10 -5
  262. package/docs/types/TagGLTFObject.html +261 -0
  263. package/docs/types/TagHooks.html +10 -5
  264. package/docs/types/TagIconSize.html +10 -5
  265. package/docs/types/TagId.html +10 -5
  266. package/docs/types/TagPointType.html +10 -5
  267. package/docs/types/TopviewFloorplanPluginParameterType.html +10 -5
  268. package/docs/types/TopviewFloorplanPluginReturnType.html +10 -5
  269. package/docs/types/WorkCode.html +10 -5
  270. package/docs/variables/FLOOR_TYPE_MAP.html +10 -5
  271. package/docs/variables/PLUGIN.html +10 -5
  272. package/docs/variables/ROOM_FETILE_TYPE_MAP.html +10 -5
  273. package/docs/variables/ROOM_TYPE_MAP.html +10 -5
  274. package/docs/variables/VERSION.html +10 -5
  275. package/docs/variables/itemLabelPluginServerParams.html +10 -5
  276. package/docs/variables/modelItemLabelPluginServerParams.html +10 -5
  277. package/docs/variables/modelRoomLabelPluginServerParams.html +10 -5
  278. package/libs/CSS3DRenderPlugin/CSS3DRender.js +43 -43
  279. package/libs/CSS3DRenderPlugin/Controller.d.ts +1 -1
  280. package/libs/CSS3DRenderPlugin/utils/generateBehindFiveElement.js +15 -14
  281. package/libs/Object3DHelperPlugin/Controller.d.ts +25 -10
  282. package/libs/Object3DHelperPlugin/Controller.js +117 -97
  283. package/libs/Object3DHelperPlugin/FiveControllerWrapper.d.ts +6 -8
  284. package/libs/Object3DHelperPlugin/FiveControllerWrapper.js +29 -22
  285. package/libs/Object3DHelperPlugin/index.js +16 -11
  286. package/libs/Object3DHelperPlugin/typings.d.ts +14 -0
  287. package/libs/PanoTagPlugin/Components/Common/Media.js +3 -2
  288. package/libs/PanoTagPlugin/Components/Common/Text/FlyMText.js +3 -2
  289. package/libs/PanoTagPlugin/Components/Common/Text/FlyText.js +3 -2
  290. package/libs/PanoTagPlugin/Components/Tag/AudioTag/AudioPlaneTag.js +3 -2
  291. package/libs/PanoTagPlugin/Components/Tag/AudioTag/AudioTag.js +3 -2
  292. package/libs/PanoTagPlugin/Components/Tag/AudioTag/index.js +12 -11
  293. package/libs/PanoTagPlugin/Components/Tag/CustomTag.js +33 -33
  294. package/libs/PanoTagPlugin/Components/Tag/ImageTextTag.js +3 -2
  295. package/libs/PanoTagPlugin/Components/Tag/MediaPlane.js +12 -11
  296. package/libs/PanoTagPlugin/Components/Tag/TextTag/TextTag.js +26 -25
  297. package/libs/PanoTagPlugin/Components/Tag/TextTag/index.js +29 -28
  298. package/libs/PanoTagPlugin/Components/Tag/index.js +126 -119
  299. package/libs/PanoTagPlugin/Components/TagContainer.js +4 -2
  300. package/libs/PanoTagPlugin/Components/TagItem.js +4 -2
  301. package/libs/PanoTagPlugin/controller/TagCacheController.d.ts +1 -0
  302. package/libs/PanoTagPlugin/controller/TagCacheController.js +14 -12
  303. package/libs/PanoTagPlugin/controller/TagComputer.d.ts +22 -6
  304. package/libs/PanoTagPlugin/controller/TagComputer.js +242 -176
  305. package/libs/PanoTagPlugin/controller/index.d.ts +32 -6
  306. package/libs/PanoTagPlugin/controller/index.js +176 -91
  307. package/libs/PanoTagPlugin/index.js +15 -12
  308. package/libs/PanoTagPlugin/tag.config.js +9 -0
  309. package/libs/PanoTagPlugin/typings/controller.d.ts +17 -2
  310. package/libs/PanoTagPlugin/typings/controller.js +1 -1
  311. package/libs/PanoTagPlugin/typings/index.js +6 -5
  312. package/libs/PanoTagPlugin/typings/tag/Tag.d.ts +5 -2
  313. package/libs/PanoTagPlugin/typings/tag/TagData.d.ts +19 -3
  314. package/libs/PanoTagPlugin/typings/tag/TagData.js +1 -1
  315. package/libs/PanoTagPlugin/typings/tag/Utils.d.ts +1 -1
  316. package/libs/PanoTagPlugin/utils/addDebugPoints.js +5 -4
  317. package/libs/PanoTagPlugin/utils/color.js +5 -5
  318. package/libs/PanoTagPlugin/utils/index.js +37 -34
  319. package/libs/PanoTagPlugin/utils/planeNormal.js +3 -2
  320. package/libs/PanoTagPlugin/utils/tag/index.d.ts +2 -0
  321. package/libs/PanoTagPlugin/utils/tag/index.js +11 -0
  322. package/libs/PanoTagPlugin/utils/tag/tagCheck.d.ts +2 -1
  323. package/libs/PanoTagPlugin/utils/tag/tagCheck.js +6 -2
  324. package/libs/PanoTagPlugin/utils/tagPosition.d.ts +3 -1
  325. package/libs/PanoTagPlugin/utils/tagPosition.js +20 -8
  326. package/libs/index.js +111 -104
  327. package/libs/shared-utils/Object3DHelper/Base/BaseController.d.ts +41 -15
  328. package/libs/shared-utils/Object3DHelper/Base/BaseController.js +112 -90
  329. package/libs/shared-utils/Object3DHelper/Base/BaseHelper.d.ts +27 -20
  330. package/libs/shared-utils/Object3DHelper/Base/BaseHelper.js +55 -22
  331. package/libs/shared-utils/Object3DHelper/Controller/BoundingBoxController.d.ts +7 -0
  332. package/libs/shared-utils/Object3DHelper/Controller/BoundingBoxController.js +14 -0
  333. package/libs/shared-utils/Object3DHelper/Controller/CSS3DScaleController.d.ts +1 -0
  334. package/libs/shared-utils/Object3DHelper/Controller/CSS3DScaleController.js +14 -10
  335. package/libs/shared-utils/Object3DHelper/Controller/MoveController.d.ts +24 -0
  336. package/libs/shared-utils/Object3DHelper/Controller/MoveController.js +80 -37
  337. package/libs/shared-utils/Object3DHelper/Controller/RectangleScaleController.d.ts +6 -1
  338. package/libs/shared-utils/Object3DHelper/Controller/RectangleScaleController.js +44 -41
  339. package/libs/shared-utils/Object3DHelper/Controller/RotateController.d.ts +14 -0
  340. package/libs/shared-utils/Object3DHelper/Controller/RotateController.js +95 -67
  341. package/libs/shared-utils/Object3DHelper/Controller/ScaleController.d.ts +12 -0
  342. package/libs/shared-utils/Object3DHelper/Controller/ScaleController.js +21 -0
  343. package/libs/shared-utils/Object3DHelper/Helper/{OutlineHelper.d.ts → BoundingBoxHelper.d.ts} +3 -2
  344. package/libs/shared-utils/Object3DHelper/Helper/BoundingBoxHelper.js +87 -0
  345. package/{dist/shared-utils/Object3DHelper/Helper/RectangleScaleHelper.d.ts → libs/shared-utils/Object3DHelper/Helper/CSS3DScaleHelper.d.ts} +3 -8
  346. package/libs/shared-utils/Object3DHelper/Helper/{RectangleScaleHelper.js → CSS3DScaleHelper.js} +5 -7
  347. package/libs/shared-utils/Object3DHelper/Helper/MoveHelper.js +7 -9
  348. package/libs/shared-utils/Object3DHelper/Helper/RotateHelper.d.ts +14 -11
  349. package/libs/shared-utils/Object3DHelper/Helper/RotateHelper.js +72 -66
  350. package/libs/shared-utils/Object3DHelper/Helper/ScaleHelper.d.ts +5 -0
  351. package/libs/shared-utils/Object3DHelper/Helper/ScaleHelper.js +9 -0
  352. package/libs/shared-utils/Object3DHelper/Helper/index.d.ts +2 -2
  353. package/libs/shared-utils/Object3DHelper/Helper/index.js +0 -2
  354. package/libs/shared-utils/Object3DHelper/index.d.ts +4 -27
  355. package/libs/shared-utils/Object3DHelper/index.js +48 -96
  356. package/libs/shared-utils/Object3DHelper/typings/Hooks.d.ts +22 -12
  357. package/libs/shared-utils/Object3DHelper/typings/index.d.ts +22 -0
  358. package/libs/shared-utils/Object3DHelper/typings/index.js +2 -1
  359. package/libs/shared-utils/Object3DHelper/utils/boundingBox.d.ts +2 -0
  360. package/libs/shared-utils/Object3DHelper/utils/boundingBox.js +24 -0
  361. package/libs/shared-utils/Object3DHelper/utils/threex/domevents/index.js +2 -2
  362. package/libs/shared-utils/three/GLTFLoader.d.ts +2 -0
  363. package/libs/shared-utils/three/GLTFLoader.js +16 -0
  364. package/libs/typings/math.type.js +1 -0
  365. package/package.json +4 -4
  366. package/dist/shared-utils/Object3DHelper/utils/getPoint.d.ts +0 -3
  367. package/libs/shared-utils/Object3DHelper/Helper/OutlineHelper.js +0 -2
  368. package/libs/shared-utils/Object3DHelper/utils/getPoint.d.ts +0 -3
  369. package/libs/shared-utils/Object3DHelper/utils/getPoint.js +0 -1
@@ -3,7 +3,12 @@ import type * as THREE from 'three';
3
3
  import { Mesh, Object3D, Vector3 } from 'three';
4
4
  import type { Direction, Direction4 } from '../typings';
5
5
  import type { tipsDom } from '../Helper/HTML/tipsDom';
6
- export declare abstract class BaseHelper<OriginObject3D extends Object3D = Object3D> extends Object3D {
6
+ declare type NonVoid<T> = T extends void ? never : T;
7
+ declare class IObject3D extends Object3D {
8
+ constructor();
9
+ removeFromParent(): this;
10
+ }
11
+ export declare abstract class BaseHelper<OriginObject3D extends Object3D = Object3D> extends IObject3D {
7
12
  protected originObject3D: OriginObject3D;
8
13
  protected onRender: () => any;
9
14
  get helperObject(): Object3D;
@@ -11,17 +16,16 @@ export declare abstract class BaseHelper<OriginObject3D extends Object3D = Objec
11
16
  onRender?: () => any;
12
17
  });
13
18
  render(): void;
19
+ enable(): void;
20
+ disable(): void;
14
21
  show(): void;
15
22
  hide(): void;
16
- updatePosition(): void;
17
- updateQuaternion(): void;
18
- applyHelperScaleMatrix4(matrix: THREE.Matrix4, params?: {
19
- origin?: THREE.Vector3;
20
- helperOrigin?: THREE.Vector3;
21
- }): void;
22
- applyHelperQuaternion(quaternion: THREE.Quaternion, origin?: THREE.Vector3): void;
23
- abstract showDraggingHelper(directions?: Direction[]): void;
24
- abstract dispose(): void;
23
+ initialPosition(): void;
24
+ initQuaternion(): void;
25
+ applyHelperScaleMatrix4(matrix: THREE.Matrix4, origin?: Vector3): void;
26
+ setHelperQuaternion(quaternion: THREE.Quaternion, origin?: Vector3): void;
27
+ applyHelperQuaternion(quaternion: THREE.Quaternion, origin?: Vector3): void;
28
+ dispose(): void;
25
29
  }
26
30
  export declare abstract class MoveHelperAbstract<OriginObject3D extends Object3D = Object3D> extends BaseHelper<OriginObject3D> {
27
31
  abstract xArrow?: Object3D & {
@@ -39,29 +43,32 @@ export declare abstract class MoveHelperAbstract<OriginObject3D extends Object3D
39
43
  line?: Object3D;
40
44
  direction: Direction;
41
45
  };
46
+ abstract showDraggingHelper(directions?: Direction[]): void;
47
+ }
48
+ export declare abstract class BoundingBoxHelperAbstract<OriginObject3D extends Object3D = Object3D> extends BaseHelper<OriginObject3D> {
42
49
  }
43
50
  export declare abstract class RotateHelperAbstract<OriginObject3D extends Object3D = Object3D> extends BaseHelper<OriginObject3D> {
44
- abstract xyCircle: Mesh & {
51
+ abstract xyCircle?: Mesh & {
45
52
  direction: Direction;
46
53
  };
47
- abstract xzCircle: Mesh & {
54
+ abstract xzCircle?: Mesh & {
48
55
  direction: Direction;
49
56
  };
50
- abstract yzCircle: Mesh & {
57
+ abstract yzCircle?: Mesh & {
51
58
  direction: Direction;
52
59
  };
53
- abstract xRingHelper: Object3D;
54
- abstract yRingHelper: Object3D;
55
- abstract zRingHelper: Object3D;
56
- abstract xAngleHelper: Object3D & {
60
+ abstract xRingHelper?: Object3D;
61
+ abstract yRingHelper?: Object3D;
62
+ abstract zRingHelper?: Object3D;
63
+ abstract xAngleHelper?: Object3D & {
57
64
  baseAxes: Vector3;
58
65
  direction: Direction;
59
66
  };
60
- abstract yAngleHelper: Object3D & {
67
+ abstract yAngleHelper?: Object3D & {
61
68
  baseAxes: Vector3;
62
69
  direction: Direction;
63
70
  };
64
- abstract zAngleHelper: Object3D & {
71
+ abstract zAngleHelper?: Object3D & {
65
72
  baseAxes: Vector3;
66
73
  direction: Direction;
67
74
  };
@@ -71,7 +78,6 @@ export declare abstract class RotateHelperAbstract<OriginObject3D extends Object
71
78
  }
72
79
  export declare abstract class ScaleHelperAbstract<OriginObject3D extends Object3D = Object3D> extends BaseHelper<OriginObject3D> {
73
80
  }
74
- declare type NonVoid<T> = T extends void ? never : T;
75
81
  export declare abstract class RectangleScaleHelperAbstract<OriginObject3D extends Object3D, PointType extends Object3D | HTMLElement> extends ScaleHelperAbstract<OriginObject3D> {
76
82
  abstract points: PointType extends Object3D ? {
77
83
  point: PointType;
@@ -84,6 +90,7 @@ export declare abstract class RectangleScaleHelperAbstract<OriginObject3D extend
84
90
  abstract cornerPositions: Vector3[];
85
91
  abstract css3DInstance?: NonVoid<Create3DElementReturnType>;
86
92
  abstract plane?: THREE.Mesh;
93
+ abstract showDraggingHelper(directions?: Direction[]): void;
87
94
  abstract updatePoints(): void;
88
95
  abstract enable(): void;
89
96
  abstract disable(): void;
@@ -1,14 +1,23 @@
1
- var o = Object.defineProperty;
2
- var p = (t, s, e) => s in t ? o(t, s, { enumerable: !0, configurable: !0, writable: !0, value: e }) : t[s] = e;
3
- var i = (t, s, e) => (p(t, typeof s != "symbol" ? s + "" : s, e), e);
4
- import { Object3D as l } from "three";
5
- class n extends l {
6
- constructor(e, r) {
7
- var a;
1
+ var p = Object.defineProperty;
2
+ var l = (t, i, e) => i in t ? p(t, i, { enumerable: !0, configurable: !0, writable: !0, value: e }) : t[i] = e;
3
+ var o = (t, i, e) => (l(t, typeof i != "symbol" ? i + "" : i, e), e);
4
+ import { Vector3 as a, Object3D as c } from "three";
5
+ class h extends c {
6
+ constructor() {
8
7
  super();
9
- i(this, "originObject3D");
10
- i(this, "onRender");
11
- this.originObject3D = e, this.onRender = (a = r == null ? void 0 : r.onRender) != null ? a : () => {
8
+ }
9
+ removeFromParent() {
10
+ const i = this.parent;
11
+ return i !== null && i.remove(this), this;
12
+ }
13
+ }
14
+ class n extends h {
15
+ constructor(e, s) {
16
+ var r;
17
+ super();
18
+ o(this, "originObject3D");
19
+ o(this, "onRender");
20
+ this.originObject3D = e, this.onRender = (r = s == null ? void 0 : s.onRender) != null ? r : () => {
12
21
  };
13
22
  }
14
23
  get helperObject() {
@@ -17,35 +26,59 @@ class n extends l {
17
26
  render() {
18
27
  this.onRender();
19
28
  }
29
+ enable() {
30
+ this.parent.children.includes(this) || this.parent.add(this);
31
+ }
32
+ disable() {
33
+ this.removeFromParent();
34
+ }
20
35
  show() {
21
36
  this.visible = !0, this.render();
22
37
  }
23
38
  hide() {
24
39
  this.visible = !1, this.render();
25
40
  }
26
- updatePosition() {
27
- this.position.copy(this.originObject3D.position);
41
+ initialPosition() {
42
+ this.position.add(this.originObject3D.position);
28
43
  }
29
- updateQuaternion() {
44
+ initQuaternion() {
30
45
  this.quaternion.copy(this.originObject3D.quaternion);
31
46
  }
32
- applyHelperScaleMatrix4(e, r) {
47
+ applyHelperScaleMatrix4(e, s) {
33
48
  this.scale.applyMatrix4(e);
34
49
  }
35
- applyHelperQuaternion(e, r) {
50
+ setHelperQuaternion(e, s) {
51
+ if (s) {
52
+ const r = new a().subVectors(this.position, s).applyQuaternion(e).add(s);
53
+ this.position.copy(r);
54
+ }
55
+ this.quaternion.copy(e);
56
+ }
57
+ applyHelperQuaternion(e, s) {
58
+ if (s) {
59
+ const r = new a().subVectors(this.position, s).applyQuaternion(e).add(s);
60
+ this.position.copy(r);
61
+ }
36
62
  this.applyQuaternion(e);
37
63
  }
64
+ dispose() {
65
+ this.removeFromParent();
66
+ }
67
+ }
68
+ class x extends n {
38
69
  }
39
- class b extends n {
70
+ class y extends n {
40
71
  }
41
- class u extends n {
72
+ class m extends n {
42
73
  }
43
- class c extends n {
74
+ class d extends n {
44
75
  }
45
- class x extends c {
76
+ class v extends d {
46
77
  }
47
78
  export {
48
- b as MoveHelperAbstract,
49
- x as RectangleScaleHelperAbstract,
50
- u as RotateHelperAbstract
79
+ y as BoundingBoxHelperAbstract,
80
+ x as MoveHelperAbstract,
81
+ v as RectangleScaleHelperAbstract,
82
+ m as RotateHelperAbstract,
83
+ d as ScaleHelperAbstract
51
84
  };
@@ -0,0 +1,7 @@
1
+ import { BaseController } from '../Base/BaseController';
2
+ import type { BoundingBoxHelperAbstract } from '../Helper';
3
+ import * as THREE from 'three';
4
+ export declare class BoundingBoxController<OriginObject3D extends THREE.Object3D = THREE.Object3D> extends BaseController<BoundingBoxHelperAbstract<OriginObject3D>> {
5
+ protected name: string;
6
+ constructor(...params: ConstructorParameters<typeof BaseController<BoundingBoxHelperAbstract<OriginObject3D>>>);
7
+ }
@@ -0,0 +1,14 @@
1
+ var t = Object.defineProperty;
2
+ var l = (n, o, r) => o in n ? t(n, o, { enumerable: !0, configurable: !0, writable: !0, value: r }) : n[o] = r;
3
+ var e = (n, o, r) => (l(n, typeof o != "symbol" ? o + "" : o, r), r);
4
+ import { BaseController as s } from "../Base/BaseController.js";
5
+ import "three";
6
+ class p extends s {
7
+ constructor(...r) {
8
+ super(...r);
9
+ e(this, "name", "BoundingBoxController");
10
+ }
11
+ }
12
+ export {
13
+ p as BoundingBoxController
14
+ };
@@ -1,6 +1,7 @@
1
1
  import type { CSS3DObject } from 'three/examples/jsm/renderers/CSS3DRenderer';
2
2
  import { RectangleScaleController } from './RectangleScaleController';
3
3
  export declare class CSS3DScaleController extends RectangleScaleController<CSS3DObject, HTMLElement> {
4
+ protected name: string;
4
5
  constructor(...params: ConstructorParameters<typeof RectangleScaleController<CSS3DObject, HTMLElement>>);
5
6
  private addHTMLEventListener;
6
7
  }
@@ -1,18 +1,22 @@
1
- import { RectangleScaleController as a } from "./RectangleScaleController.js";
2
- import "three";
3
- class c extends a {
4
- constructor(...t) {
5
- super(...t), this.addHTMLEventListener();
1
+ var g = Object.defineProperty;
2
+ var c = (r, t, e) => t in r ? g(r, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : r[t] = e;
3
+ var d = (r, t, e) => (c(r, typeof t != "symbol" ? t + "" : t, e), e);
4
+ import { RectangleScaleController as l } from "./RectangleScaleController.js";
5
+ class E extends l {
6
+ constructor(...e) {
7
+ super(...e);
8
+ d(this, "name", "CSS3DScaleController");
9
+ this.addHTMLEventListener();
6
10
  }
7
11
  addHTMLEventListener() {
8
- this.helperObject3D.points.forEach((t) => {
9
- if (!t)
12
+ this.helperObject3D.points.forEach((e) => {
13
+ if (!e)
10
14
  return;
11
- const e = t.point, r = (s) => this.dragStart(s, t), n = this.dragging.bind(this), d = this.dragEnd.bind(this);
12
- e.addEventListener("dragstart", r), e.addEventListener("drag", n), e.addEventListener("dragend", d);
15
+ const n = e.point, a = (o) => this.dragStart(o, e), s = this.dragging.bind(this), i = this.dragEnd.bind(this);
16
+ n.addEventListener("dragstart", a), n.addEventListener("drag", s), n.addEventListener("dragend", i);
13
17
  });
14
18
  }
15
19
  }
16
20
  export {
17
- c as CSS3DScaleController
21
+ E as CSS3DScaleController
18
22
  };
@@ -1,8 +1,32 @@
1
1
  import { BaseController } from '../Base/BaseController';
2
+ import * as THREE from 'three';
2
3
  import type { MoveHelperAbstract } from '../Helper';
3
4
  export declare class MoveController<T extends MoveHelperAbstract = MoveHelperAbstract> extends BaseController<T> {
5
+ get moveByMouseEnable(): boolean;
6
+ protected name: string;
4
7
  private startInfo?;
8
+ private _moveByMouseEnable;
9
+ private mouseInfo?;
10
+ private mousedownEventListenerDisposer;
5
11
  constructor(...params: ConstructorParameters<typeof BaseController<T>>);
12
+ dispose(): void;
13
+ /**
14
+ * @description: 跟随鼠标移动
15
+ */
16
+ moveByMouse(): void;
17
+ /**
18
+ * @description: 禁用跟随鼠标移动
19
+ */
20
+ disableMoveByMouse(): void;
21
+ onIntersectionOnModelUpdate(intersection: {
22
+ point: THREE.Vector3;
23
+ }): void;
24
+ protected onApplyOriginObjectScale(params: {
25
+ matrix4: THREE.Matrix4;
26
+ origin?: THREE.Vector3;
27
+ }): void;
28
+ private handleMouseDown;
29
+ private handleMouseUp;
6
30
  /**
7
31
  * @description: 拖动开始,找出拖的Direction
8
32
  */
@@ -1,66 +1,109 @@
1
1
  var p = Object.defineProperty;
2
- var f = (s, r, t) => r in s ? p(s, r, { enumerable: !0, configurable: !0, writable: !0, value: t }) : s[r] = t;
3
- var u = (s, r, t) => (f(s, typeof r != "symbol" ? r + "" : r, t), t);
4
- import { BaseController as m } from "../Base/BaseController.js";
5
- import * as c from "three";
6
- import { getMouseRaycaster as b } from "../utils/getMouseRaycaster.js";
7
- class v extends m {
8
- constructor(...t) {
9
- super(...t);
2
+ var v = (c, i, e) => i in c ? p(c, i, { enumerable: !0, configurable: !0, writable: !0, value: e }) : c[i] = e;
3
+ var u = (c, i, e) => (v(c, typeof i != "symbol" ? i + "" : i, e), e);
4
+ import { BaseController as g } from "../Base/BaseController.js";
5
+ import * as d from "three";
6
+ import { getMouseRaycaster as f } from "../utils/getMouseRaycaster.js";
7
+ class w extends g {
8
+ constructor(...e) {
9
+ super(...e);
10
+ u(this, "name", "MoveController");
10
11
  u(this, "startInfo");
11
- const e = this.helperObject3D;
12
- this.hoverListener([e.xArrow, e.yArrow, e.zArrow]);
13
- const o = this.dragStart.bind(this), n = this.dragging.bind(this), a = this.dragEnd.bind(this);
14
- this.domEvents.addEventListener(this.helperObject3D, "mousedown", o), document.addEventListener("mousemove", n), document.addEventListener("mouseup", a);
12
+ u(this, "_moveByMouseEnable", !1);
13
+ u(this, "mouseInfo");
14
+ u(this, "mousedownEventListenerDisposer");
15
+ const o = this.helperObject3D;
16
+ this.hoverListener([o.xArrow, o.yArrow, o.zArrow]);
17
+ const t = this.dragStart.bind(this), r = this.dragging.bind(this), a = this.dragEnd.bind(this), s = this.show.bind(this), n = this.hide.bind(this);
18
+ this.domEvents.addEventListener(this.helperObject3D, "mousedown", t), document.addEventListener("mousemove", r), document.addEventListener("mouseup", a), this.hooks.on("rotateStart", n), this.hooks.on("rotateEnd", s), this.hooks.on("moveByMouseEnable", n), this.hooks.on("moveByMouseDisable", s), this.disposers.push(() => {
19
+ this.domEvents.removeEventListener(this.helperObject3D, "mousedown", t), document.removeEventListener("mousemove", r), document.removeEventListener("mouseup", a), this.hooks.off("rotateStart", n), this.hooks.off("rotateEnd", s), this.hooks.off("moveByMouseEnable", n), this.hooks.off("moveByMouseDisable", s);
20
+ }), this.moveByMouseEnable && this.moveByMouse();
15
21
  }
16
- dragStart(t) {
17
- if (this.isDragging)
22
+ get moveByMouseEnable() {
23
+ return this._moveByMouseEnable;
24
+ }
25
+ dispose() {
26
+ var e;
27
+ super.dispose(), (e = this.disposers) == null || e.forEach((o) => o == null ? void 0 : o());
28
+ }
29
+ moveByMouse() {
30
+ this._moveByMouseEnable = !0;
31
+ const e = this.handleMouseDown.bind(this), o = this.handleMouseUp.bind(this);
32
+ this.hooks.emit("moveByMouseEnable"), setTimeout(() => {
33
+ this.container.addEventListener("mousedown", e), this.container.addEventListener("mouseup", o);
34
+ }), this.mousedownEventListenerDisposer = () => {
35
+ this.container.removeEventListener("mousedown", e), this.container.removeEventListener("mouseup", o);
36
+ };
37
+ }
38
+ disableMoveByMouse() {
39
+ var e;
40
+ this._moveByMouseEnable = !1, this.hooks.emit("moveByMouseDisable"), (e = this.mousedownEventListenerDisposer) == null || e.call(this);
41
+ }
42
+ onIntersectionOnModelUpdate(e) {
43
+ !this.moveByMouseEnable || this.hooks.emit("wantToMove", e.point) || (this.originObject3D.position.copy(e.point), this.hooks.emit("setObjectPosition", e.point), this.hooks.emit("move", e.point));
44
+ }
45
+ onApplyOriginObjectScale(e) {
46
+ }
47
+ handleMouseDown(e) {
48
+ const { x: o, y: t } = e;
49
+ this.mouseInfo = { x: o, y: t, mouseDownTimestamp: Date.now() };
50
+ }
51
+ handleMouseUp(e) {
52
+ if (!this.mouseInfo)
18
53
  return;
19
- const e = t == null ? void 0 : t.intersect;
20
- if (!e)
21
- return this.dragEnd();
22
- const o = (e == null ? void 0 : e.object).direction;
54
+ const { x: o, y: t } = e;
55
+ this.mouseInfo.x === o && this.mouseInfo.y === t && Date.now() - this.mouseInfo.mouseDownTimestamp < 500 && (this.disableMoveByMouse(), this.mouseInfo = void 0);
56
+ }
57
+ dragStart(e) {
58
+ if (this._moveByMouseEnable || this.isDragging)
59
+ return;
60
+ const o = e == null ? void 0 : e.intersect;
23
61
  if (!o)
24
62
  return this.dragEnd();
25
- const n = new c.Vector3(1, 0, 0).applyQuaternion(this.helperObject3D.quaternion), a = new c.Vector3(0, 1, 0).applyQuaternion(this.helperObject3D.quaternion), h = new c.Vector3(0, 0, 1).applyQuaternion(this.helperObject3D.quaternion), d = (() => {
26
- switch (o) {
63
+ const t = (o == null ? void 0 : o.object).direction;
64
+ if (!t)
65
+ return this.dragEnd();
66
+ const r = new d.Vector3(1, 0, 0).applyQuaternion(this.helperObject3D.quaternion), a = new d.Vector3(0, 1, 0).applyQuaternion(this.helperObject3D.quaternion), s = new d.Vector3(0, 0, 1).applyQuaternion(this.helperObject3D.quaternion), n = (() => {
67
+ switch (t) {
27
68
  case "x":
28
- return n;
69
+ return r;
29
70
  case "y":
30
71
  return a;
31
72
  case "z":
32
- return h;
73
+ return s;
33
74
  }
34
- })(), g = (() => {
35
- switch (o) {
75
+ })(), l = (() => {
76
+ switch (t) {
36
77
  case "x":
37
78
  case "y":
38
- return h;
79
+ return s;
39
80
  case "z":
40
- return n;
81
+ return r;
41
82
  }
42
- })(), i = e.point.clone(), l = new c.Plane();
43
- l.setFromNormalAndCoplanarPoint(g, i), this.startInfo = { startVectorProject: i.clone().projectOnVector(d), directionVector: d, plane: l }, this.helperObject3D.showDraggingHelper([o]), this.hooks.emit("moveStart"), this.isDragging = !0, console.log("%c MoveController dragStart", "color: #e5af2e");
83
+ })(), h = o.point.clone(), m = new d.Plane();
84
+ m.setFromNormalAndCoplanarPoint(l, h), this.startInfo = { startVectorProject: h.clone().projectOnVector(n), directionVector: n, plane: m }, this.helperObject3D.showDraggingHelper([t]), this.hooks.emit("moveStart"), this.isDragging = !0, console.log("%c MoveController dragStart", "color: #e5af2e");
44
85
  }
45
- dragging(t) {
86
+ dragging(e) {
46
87
  if (!this.isDragging || !this.startInfo)
47
88
  return;
48
- const e = b(this.camera, t, this.container);
49
- return e ? (console.log("%c RotateController dragging", "color: #49de1b"), this.move(e), !1) : this.dragEnd();
89
+ const o = f(this.camera, e, this.container);
90
+ return o ? (console.log("%c MoveController dragging", "color: #49de1b"), this.move(o), !1) : this.dragEnd();
50
91
  }
51
- move(t) {
92
+ move(e) {
52
93
  if (!this.startInfo)
53
94
  return this.dragEnd();
54
- const { plane: e, directionVector: o, startVectorProject: n } = this.startInfo, a = this.originObject3D, h = t.ray.intersectPlane(e, new c.Vector3());
55
- if (!h)
95
+ const { plane: o, directionVector: t, startVectorProject: r } = this.startInfo, a = this.originObject3D, s = e.ray.intersectPlane(o, new d.Vector3());
96
+ if (!s)
56
97
  return;
57
- const d = h.clone().projectOnVector(o), g = d.clone().sub(n), i = new c.Matrix4();
58
- i.setPosition(g), a.applyMatrix4(i), this.helperObject3D.applyMatrix4(i), n.copy(d), this.hooks.emit("positionUpdate", { matrix4: i });
98
+ const n = s.clone().projectOnVector(t), l = n.clone().sub(r), h = new d.Matrix4();
99
+ h.setPosition(l);
100
+ const m = a.position.clone().applyMatrix4(h);
101
+ this.hooks.emit("wantToMove", m) || (a.applyMatrix4(h), r.copy(n), this.hooks.emit("applyObjectPosition", { matrix4: h }), this.hooks.emit("move", m));
59
102
  }
60
103
  dragEnd() {
61
104
  !this.isDragging || (console.log("%c MoveController dragEnd", "color: #e94e4e"), this.startInfo = void 0, this.isDragging = !1, this.helperObject3D.show(), this.hooks.emit("moveEnd"));
62
105
  }
63
106
  }
64
107
  export {
65
- v as MoveController
108
+ w as MoveController
66
109
  };
@@ -12,13 +12,18 @@ interface StartInfo {
12
12
  dragPointInCenterLeft?: boolean | null;
13
13
  plane: THREE.Plane;
14
14
  }
15
- export declare abstract class RectangleScaleController<OriginObject3D extends THREE.Object3D, PointType extends THREE.Object3D | HTMLElement> extends BaseController<RectangleScaleHelperAbstract<OriginObject3D, PointType>> {
15
+ export declare class RectangleScaleController<OriginObject3D extends THREE.Object3D, PointType extends THREE.Object3D | HTMLElement> extends BaseController<RectangleScaleHelperAbstract<OriginObject3D, PointType>> {
16
16
  protected startInfo?: StartInfo;
17
+ protected name: string;
17
18
  constructor(...params: ConstructorParameters<typeof BaseController<RectangleScaleHelperAbstract<OriginObject3D, PointType>>>);
18
19
  enable(): void;
19
20
  disable(): void;
20
21
  show(): void;
21
22
  hide(): void;
23
+ protected onApplyOriginObjectScale(params: {
24
+ matrix4: THREE.Matrix4;
25
+ origin?: THREE.Vector3;
26
+ }): void;
22
27
  protected getDragPlane(): THREE.Plane;
23
28
  protected dragStart(mousePoint: {
24
29
  x: number;
@@ -1,15 +1,16 @@
1
1
  var X = Object.defineProperty;
2
- var Y = (h, a, s) => a in h ? X(h, a, { enumerable: !0, configurable: !0, writable: !0, value: s }) : h[a] = s;
3
- var N = (h, a, s) => (Y(h, typeof a != "symbol" ? a + "" : a, s), s);
4
- import { BaseController as A } from "../Base/BaseController.js";
5
- import * as D from "three";
2
+ var Y = (h, a, e) => a in h ? X(h, a, { enumerable: !0, configurable: !0, writable: !0, value: e }) : h[a] = e;
3
+ var I = (h, a, e) => (Y(h, typeof a != "symbol" ? a + "" : a, e), e);
4
+ import { BaseController as H } from "../Base/BaseController.js";
5
+ import * as j from "three";
6
6
  import { Vector3 as n } from "three";
7
- import { getMouseRaycaster as H } from "../utils/getMouseRaycaster.js";
8
- import { vectorIsEqual as T } from "../utils/vectorIsEqual.js";
9
- class _ extends A {
10
- constructor(...s) {
11
- super(...s);
12
- N(this, "startInfo");
7
+ import { getMouseRaycaster as T } from "../utils/getMouseRaycaster.js";
8
+ import { vectorIsEqual as G } from "../utils/vectorIsEqual.js";
9
+ class _ extends H {
10
+ constructor(...e) {
11
+ super(...e);
12
+ I(this, "startInfo");
13
+ I(this, "name", "RectangleScaleController");
13
14
  }
14
15
  enable() {
15
16
  this.helperObject3D.enable(), super.enable();
@@ -23,56 +24,58 @@ class _ extends A {
23
24
  hide() {
24
25
  this.helperObject3D.hide(), super.hide();
25
26
  }
27
+ onApplyOriginObjectScale(e) {
28
+ }
26
29
  getDragPlane() {
27
- const s = new D.Plane(), e = this.helperObject3D.cornerPositions;
28
- if (e.length !== 0)
29
- return e.length < 3 ? s.setFromNormalAndCoplanarPoint(this.originObject3D.getWorldDirection(new n()), e[0]) : s.setFromCoplanarPoints(e[0], e[1], e[2]), s;
30
+ const e = new j.Plane(), s = this.helperObject3D.cornerPositions;
31
+ if (s.length !== 0)
32
+ return s.length < 3 ? e.setFromNormalAndCoplanarPoint(this.originObject3D.getWorldDirection(new n()), s[0]) : e.setFromCoplanarPoints(s[0], s[1], s[2]), e;
30
33
  }
31
- dragStart(s, e) {
34
+ dragStart(e, s) {
32
35
  var g, o;
33
36
  (o = (g = this.helperObject3D).updatePoints) == null || o.call(g);
34
37
  const f = this.getDragPlane();
35
38
  if (!f)
36
39
  return this.dragEnd();
37
- this.startInfo = { startPoint: { position: e.position.clone(), direction: e.direction }, plane: f }, this.hooks.emit("scaleStart"), this.render(), this.isDragging = !0, console.log("%c RectangleScaleController dragStart", "color: #e5af2e");
40
+ this.startInfo = { startPoint: { position: s.position.clone(), direction: s.direction }, plane: f }, this.hooks.emit("scaleStart"), this.render(), this.isDragging = !0, console.log("%c RectangleScaleController dragStart", "color: #e5af2e");
38
41
  }
39
- dragging(s) {
42
+ dragging(e) {
40
43
  if (!this.isDragging)
41
44
  return;
42
- const e = H(this.camera, s, this.container);
43
- if (!e)
45
+ const s = T(this.camera, e, this.container);
46
+ if (!s)
44
47
  return this.dragEnd();
45
- this.scale(e), console.log("%c RectangleScaleController dragging", "color: #49de1b");
48
+ this.scale(s), console.log("%c RectangleScaleController dragging", "color: #49de1b");
46
49
  }
47
- scale(s) {
48
- var S, x;
50
+ scale(e) {
51
+ var x, E;
49
52
  if (!this.startInfo)
50
53
  return;
51
- const e = this.originObject3D, { startPoint: f, plane: g } = this.startInfo, o = this.helperObject3D.cornerPositions;
54
+ const s = this.originObject3D, { startPoint: f, plane: g } = this.startInfo, o = this.helperObject3D.cornerPositions;
52
55
  if (o.length < 4)
53
56
  return this.dragEnd();
54
- const p = s.ray.intersectPlane(g, new n());
55
- if (!p || T(p, this.camera.position))
57
+ const p = e.ray.intersectPlane(g, new n());
58
+ if (!p || G(p, this.camera.position))
56
59
  return;
57
- const u = new n().addVectors(o[0], o[2]).divideScalar(2), { position: k, direction: z } = f, j = new n().subVectors(o[1], o[0]), O = new n().subVectors(o[3], o[0]), V = (r) => {
60
+ const O = new n().addVectors(o[0], o[2]).divideScalar(2), { position: k, direction: R } = f, D = new n().subVectors(o[1], o[0]), y = new n().subVectors(o[3], o[0]), S = (r) => {
58
61
  const i = new n(0, 0, 0);
59
62
  if (!this.startInfo)
60
63
  return i;
61
- const t = (r === "ew" ? j : O).clone(), c = k.clone().projectOnVector(t), b = p.clone().projectOnVector(t), E = u.clone().projectOnVector(t);
64
+ const t = (r === "ew" ? D : y).clone(), c = k.clone().projectOnVector(t), b = p.clone().projectOnVector(t), v = O.clone().projectOnVector(t);
62
65
  if (b.equals(c))
63
66
  return i;
64
67
  if (r === "ns" && typeof this.startInfo.dragPointInCenterBottom != "boolean") {
65
- const l = new n().subVectors(b, E), P = l.x < 0 && t.x >= 0, I = l.y < 0 && t.y >= 0, m = l.z < 0 && t.z >= 0;
66
- this.startInfo.dragPointInCenterBottom = P || I || m;
68
+ const l = new n().subVectors(b, v), w = l.x < 0 && t.x >= 0, P = l.y < 0 && t.y >= 0, m = l.z < 0 && t.z >= 0;
69
+ this.startInfo.dragPointInCenterBottom = w || P || m;
67
70
  }
68
71
  if (r === "ew" && typeof this.startInfo.dragPointInCenterLeft != "boolean") {
69
- const l = new n().subVectors(b, E), P = l.x < 0 && t.x >= 0, I = l.y < 0 && t.y >= 0, m = l.z < 0 && t.z >= 0;
70
- this.startInfo.dragPointInCenterLeft = P || I || m;
72
+ const l = new n().subVectors(b, v), w = l.x < 0 && t.x >= 0, P = l.y < 0 && t.y >= 0, m = l.z < 0 && t.z >= 0;
73
+ this.startInfo.dragPointInCenterLeft = w || P || m;
71
74
  }
72
- const v = new n().subVectors(b, c), M = v.length();
73
- return M > 0.3 ? (console.warn("offset.length() > 0.3, skipped", M), i) : v;
74
- }, R = V("ew"), B = V("ns"), y = () => {
75
- const r = R;
75
+ const M = new n().subVectors(b, c), N = M.length();
76
+ return N > 0.3 ? (console.warn("offset.length() > 0.3, skipped", N), i) : M;
77
+ }, z = S("ew"), B = S("ns"), V = () => {
78
+ const r = z;
76
79
  this.helperObject3D.cornerPositions.forEach((i, t) => {
77
80
  var c;
78
81
  (c = this.startInfo) != null && c.dragPointInCenterLeft ? (t === 0 || t === 3) && i.add(r) : (t === 1 || t === 2) && i.add(r);
@@ -84,21 +87,21 @@ class _ extends A {
84
87
  (c = this.startInfo) != null && c.dragPointInCenterBottom ? (t === 0 || t === 1) && i.add(r) : (t === 2 || t === 3) && i.add(r);
85
88
  });
86
89
  };
87
- switch (z) {
90
+ switch (R) {
88
91
  case "ew":
89
- y();
92
+ V();
90
93
  break;
91
94
  case "ns":
92
95
  C();
93
96
  break;
94
97
  case "nesw":
95
98
  case "nwse":
96
- y(), C();
99
+ V(), C();
97
100
  }
98
- const L = new n().subVectors(o[1], o[0]).length() / j.length(), q = new n().subVectors(o[3], o[0]).length() / O.length(), F = new n(L, q, 1), w = new D.Matrix4().scale(F);
99
- e.isCSS3DObjectPlus ? e.applyScaleMatrix4(w) : e.scale.applyMatrix4(w), f.position.copy(p);
100
- const U = new n().addVectors(o[0], o[2]).divideScalar(2), W = new n().subVectors(U, u), d = new D.Matrix4().setPosition(W);
101
- e.applyMatrix4(d), (S = this.helperObject3D.css3DInstance) == null || S.css3DObject.applyMatrix4(d), (x = this.helperObject3D.plane) == null || x.applyMatrix4(d), this.hooks.emit("scaleUpdate", { matrix4: w, helperOrigin: u }), this.hooks.emit("positionUpdate", { matrix4: d }), this.render();
101
+ const L = new n().subVectors(o[1], o[0]).length() / D.length(), q = new n().subVectors(o[3], o[0]).length() / y.length(), A = new n(L, q, 1), u = new j.Matrix4().scale(A);
102
+ s.isCSS3DObjectPlus ? s.applyScaleMatrix4(u) : s.scale.applyMatrix4(u), f.position.copy(p);
103
+ const F = new n().addVectors(o[0], o[2]).divideScalar(2), W = new n().subVectors(F, O), d = new j.Matrix4().setPosition(W);
104
+ s.applyMatrix4(d), (x = this.helperObject3D.css3DInstance) == null || x.css3DObject.applyMatrix4(d), (E = this.helperObject3D.plane) == null || E.applyMatrix4(d), this.hooks.emit("applyObjectScale", { matrix4: u }), this.hooks.emit("applyObjectPosition", { matrix4: d }), this.render();
102
105
  }
103
106
  dragEnd() {
104
107
  !this.isDragging || (this.startInfo = void 0, this.isDragging = !1, this.hooks.emit("scaleEnd"), this.render(), console.log("%c RectangleScaleController dragEnd", "color: #e94e4e"));
@@ -1,12 +1,26 @@
1
1
  import { BaseController } from '../Base/BaseController';
2
2
  import type { RotateHelperAbstract } from '../Helper';
3
+ import * as THREE from 'three';
3
4
  export declare class RotateController<T extends RotateHelperAbstract = RotateHelperAbstract> extends BaseController<T> {
5
+ protected name: string;
6
+ private get rotateCenter();
4
7
  private startInfo?;
5
8
  private lastRotation?;
6
9
  private rotations;
7
10
  private helperObject3DQuaternion;
11
+ private removeListener;
8
12
  constructor(...params: ConstructorParameters<typeof BaseController<T>>);
9
13
  initialHelperQuaternion(): void;
14
+ setRotateAngle(angle: {
15
+ x?: number;
16
+ y?: number;
17
+ z?: number;
18
+ }): void;
19
+ dispose(): void;
20
+ protected onApplyOriginObjectScale(params: {
21
+ matrix4: THREE.Matrix4;
22
+ origin?: THREE.Vector3;
23
+ }): void;
10
24
  /**
11
25
  * @description: 拖动开始,找出拖的Direction
12
26
  */