@realsee/dnalogel 2.28.0-dev.1 → 2.28.1-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 (421) hide show
  1. package/dist/AreaMakerPlugin/Controller.d.ts +94 -0
  2. package/dist/AreaMakerPlugin/index.d.ts +4 -0
  3. package/dist/AreaMakerPlugin/typing.d.ts +148 -0
  4. package/dist/AreaMakerPlugin/utils/Item.d.ts +115 -0
  5. package/dist/GuideLinePlugin/utils/createLineGeometry.d.ts +0 -5
  6. package/dist/PanoTagPlugin/typings/tag/Tag.d.ts +1 -1
  7. package/dist/PanoTagPlugin/typings/tag/TagConfig.d.ts +2 -4
  8. package/dist/PanoTagPlugin/typings/tag/TagData.d.ts +2 -0
  9. package/dist/base/BasePluginWithData.d.ts +1 -1
  10. package/dist/components/AreaLabel/Assets/roomLabelBg.d.ts +1 -0
  11. package/dist/floorplan/index.d.ts +0 -1
  12. package/dist/floorplan/utils/correctFiveState.d.ts +2 -0
  13. package/dist/index.cjs.js +67 -67
  14. package/dist/index.d.ts +1 -0
  15. package/dist/index.js +6901 -7187
  16. package/dist/index.umd.js +60 -60
  17. package/dist/shared-utils/index.d.ts +1 -0
  18. package/dist/shared-utils/math/planimetry.d.ts +1 -1
  19. package/dist/shared-utils/three/core/Object3D.d.ts +8 -0
  20. package/dist/shared-utils/three/index.d.ts +2 -0
  21. package/dist/shared-utils/three/loadVideoTexture.d.ts +1 -1
  22. package/dist/shared-utils/three/objects/LineSegments.d.ts +9 -0
  23. package/docs/assets/search.js +1 -1
  24. package/docs/classes/AreaMakerPluginPluginType.AreaMakerController.html +711 -0
  25. package/docs/classes/AreaMakerPluginPluginType.AreaMakerItem.html +671 -0
  26. package/docs/classes/CSS3DRender.html +33 -34
  27. package/docs/classes/CruisePluginController.html +29 -30
  28. package/docs/classes/GuideLineItem.GuideLineItem.html +22 -23
  29. package/docs/classes/GuideLineModeItem.GuideLineModeItem.html +37 -38
  30. package/docs/classes/Magnifier.html +22 -23
  31. package/docs/classes/ModelRoomLabelController.html +13 -14
  32. package/docs/classes/Object3DHelperController.html +27 -28
  33. package/docs/classes/PaintBrush.html +17 -18
  34. package/docs/classes/PanoMeasurePluginLine.html +29 -30
  35. package/docs/classes/PanoMeasurePluginModel.html +29 -30
  36. package/docs/classes/PanoMeasurePluginPoint.html +13 -14
  37. package/docs/classes/PanoMeasurePluginPolyline.html +29 -30
  38. package/docs/classes/PanoTagPluginController.html +52 -53
  39. package/docs/classes/Util.BetterTween.html +13 -11
  40. package/docs/classes/Util.Interval.html +16 -14
  41. package/docs/classes/Util.LineSegments.html +379 -0
  42. package/docs/classes/Util.Magnifier.html +24 -22
  43. package/docs/classes/Util.Object3D.html +401 -0
  44. package/docs/classes/Util.PointDomHelper.html +15 -13
  45. package/docs/classes/Util.PointHelper.html +15 -13
  46. package/docs/classes/Util.PointSelectorHelper.html +20 -18
  47. package/docs/classes/Util.Rectangle.html +17 -15
  48. package/docs/enums/CameraMovementEffect.html +9 -10
  49. package/docs/enums/ContentType.html +22 -23
  50. package/docs/enums/DIRECTION.html +11 -12
  51. package/docs/enums/DISPLAY_STRATEGY_TYPE.html +11 -12
  52. package/docs/enums/DimensionType.html +9 -10
  53. package/docs/enums/FLOOR_PLAN_ATTACHED_TO.html +10 -11
  54. package/docs/enums/ITEM_LABEL_PLUGIN_DISPLAY_STRATEGY_TYPE.html +11 -12
  55. package/docs/enums/PaintBrushTypeEnum.html +10 -11
  56. package/docs/enums/PointType.html +9 -10
  57. package/docs/enums/Rotation.html +10 -11
  58. package/docs/functions/{FloorplanRoomsPlugin.html → AreaMakerPluginPlugin.html} +12 -13
  59. package/docs/functions/CSS3DRenderPlugin.html +6 -7
  60. package/docs/functions/CameraMovementPlugin.html +6 -7
  61. package/docs/functions/CruisePlugin.html +7 -8
  62. package/docs/functions/GuideLinePlugin.html +7 -8
  63. package/docs/functions/ItemLabelPlugin.html +6 -7
  64. package/docs/functions/MapviewFloorplanPlugin.html +6 -7
  65. package/docs/functions/ModelChassisCompassPlugin.html +6 -7
  66. package/docs/functions/ModelEntryDoorGuidePlugin.html +6 -7
  67. package/docs/functions/ModelFloorplanPlugin.html +6 -7
  68. package/docs/functions/ModelItemLabelPlugin.html +6 -7
  69. package/docs/functions/ModelRoomLabelPlugin.html +6 -7
  70. package/docs/functions/ModelTVVideoPlugin.html +6 -7
  71. package/docs/functions/ModelViewPlugin.html +6 -7
  72. package/docs/functions/Object3DHelperPlugin.html +6 -7
  73. package/docs/functions/PanoCompassPlugin.html +6 -7
  74. package/docs/functions/PanoCursorRaycasterPlugin.html +6 -7
  75. package/docs/functions/PanoDoorLabelPlugin.html +6 -7
  76. package/docs/functions/PanoFloorplanRadarPlugin.html +6 -7
  77. package/docs/functions/PanoMeasurePlugin.html +6 -7
  78. package/docs/functions/PanoRulerPlugin.html +6 -7
  79. package/docs/functions/PanoRulerProPlugin.html +6 -7
  80. package/docs/functions/PanoSpatialTagPlugin.html +6 -7
  81. package/docs/functions/PanoTagPlugin.html +6 -7
  82. package/docs/functions/PanoVideoPlugin.html +6 -7
  83. package/docs/functions/PipelinePlugin.html +6 -7
  84. package/docs/functions/TopviewFloorplanPlugin.html +6 -7
  85. package/docs/functions/Util.absoluteUrl.html +9 -7
  86. package/docs/functions/Util.equal.html +333 -0
  87. package/docs/functions/Util.getCoordsFromClient.html +9 -7
  88. package/docs/functions/Util.getCoordsFromElement.html +9 -7
  89. package/docs/functions/Util.getFrameTime.html +9 -7
  90. package/docs/functions/Util.getIntersectFromRelativePosition.html +9 -7
  91. package/docs/functions/Util.getRaycasterFromFivePointer.html +9 -7
  92. package/docs/functions/Util.isAbsoluteURL.html +9 -7
  93. package/docs/functions/Util.isModelLike.html +9 -7
  94. package/docs/functions/Util.isNil.html +9 -7
  95. package/docs/functions/Util.isPanoramaLike.html +9 -7
  96. package/docs/functions/Util.nextFrame.html +9 -7
  97. package/docs/functions/Util.notNil.html +9 -7
  98. package/docs/functions/Util.requestAnimationFrameInterval.html +9 -7
  99. package/docs/functions/Util.tweenProgress.html +9 -7
  100. package/docs/functions/Util.uuid.html +9 -7
  101. package/docs/functions/pluginFlag.html +7 -8
  102. package/docs/index.html +7 -8
  103. package/docs/interfaces/AddTagConfig.html +8 -9
  104. package/docs/interfaces/AreaMakerPluginPluginType.AnimeOptions.html +325 -0
  105. package/docs/interfaces/AreaMakerPluginPluginType.Config.html +330 -0
  106. package/docs/interfaces/AreaMakerPluginPluginType.EventMap.html +616 -0
  107. package/docs/interfaces/AreaMakerPluginPluginType.Params.html +329 -0
  108. package/docs/interfaces/AreaMakerPluginPluginType.ServerAreaMakerItem.html +379 -0
  109. package/docs/interfaces/AreaMakerPluginPluginType.ServerAreaMakerItemV1.html +364 -0
  110. package/docs/interfaces/AreaMakerPluginPluginType.ServerDataV1.html +329 -0
  111. package/docs/interfaces/AreaMakerPluginPluginType.ServerDataV2.html +322 -0
  112. package/docs/interfaces/AreaMakerPluginPluginType.ShowHideOptions.html +321 -0
  113. package/docs/interfaces/AreaMakerPluginPluginType.State.html +350 -0
  114. package/docs/interfaces/CSS3DRenderPluginEventMap.html +13 -14
  115. package/docs/interfaces/CSS3DRenderPluginState.html +10 -11
  116. package/docs/interfaces/CameraMovementPluginExportType.html +9 -10
  117. package/docs/interfaces/CruisePluginTypes.Config.html +10 -11
  118. package/docs/interfaces/CruisePluginTypes.CruiseKeyframe.html +14 -15
  119. package/docs/interfaces/CruisePluginTypes.EventMap.html +22 -23
  120. package/docs/interfaces/CruisePluginTypes.MoveAction.html +14 -15
  121. package/docs/interfaces/CruisePluginTypes.MoveWithKeyframesAction.html +16 -17
  122. package/docs/interfaces/CruisePluginTypes.MoveWithPanoIndexAction.html +16 -17
  123. package/docs/interfaces/CruisePluginTypes.PluginData.html +11 -12
  124. package/docs/interfaces/CruisePluginTypes.PluginServerData.html +8 -9
  125. package/docs/interfaces/CruisePluginTypes.PluginState.html +13 -14
  126. package/docs/interfaces/EventMap.html +17 -18
  127. package/docs/interfaces/FloorplanBounding.html +10 -11
  128. package/docs/interfaces/FloorplanData.html +12 -13
  129. package/docs/interfaces/FloorplanEntrance.html +13 -14
  130. package/docs/interfaces/FloorplanExtraObject.html +12 -13
  131. package/docs/interfaces/FloorplanExtraObject3D.html +10 -11
  132. package/docs/interfaces/FloorplanFloorData.html +11 -12
  133. package/docs/interfaces/FloorplanImagePosition.html +9 -10
  134. package/docs/interfaces/FloorplanObserver.html +11 -12
  135. package/docs/interfaces/FloorplanOutlineItem.html +11 -12
  136. package/docs/interfaces/FloorplanPosition.html +9 -10
  137. package/docs/interfaces/FloorplanRoomItem.html +15 -16
  138. package/docs/interfaces/FloorplanRoomLabelItem.html +9 -10
  139. package/docs/interfaces/FloorplanServerBounding.html +10 -11
  140. package/docs/interfaces/FloorplanServerComputedData.html +12 -13
  141. package/docs/interfaces/FloorplanServerData.html +9 -10
  142. package/docs/interfaces/FloorplanServerDoorItem.html +12 -13
  143. package/docs/interfaces/FloorplanServerDoorPosition.html +10 -11
  144. package/docs/interfaces/FloorplanServerEntrance.html +13 -14
  145. package/docs/interfaces/FloorplanServerFloorData.html +11 -12
  146. package/docs/interfaces/FloorplanServerImagePosition.html +9 -10
  147. package/docs/interfaces/FloorplanServerObserver.html +11 -12
  148. package/docs/interfaces/FloorplanServerOutlineItem.html +11 -12
  149. package/docs/interfaces/FloorplanServerPosition.html +9 -10
  150. package/docs/interfaces/FloorplanServerRoomItem.html +16 -17
  151. package/docs/interfaces/FloorplanServerRoomLabelItem.html +9 -10
  152. package/docs/interfaces/GuideLineModeItem.GuideLineTagContainer.html +10 -11
  153. package/docs/interfaces/GuideLinePluginType.CatmullRomCurve3.html +12 -13
  154. package/docs/interfaces/GuideLinePluginType.EventMap.html +15 -16
  155. package/docs/interfaces/GuideLinePluginType.GuideLineGeometryStyle.html +10 -11
  156. package/docs/interfaces/GuideLinePluginType.GuideLineItemContainer.html +8 -9
  157. package/docs/interfaces/GuideLinePluginType.GuideLineMaterialStyle.html +15 -16
  158. package/docs/interfaces/GuideLinePluginType.LineGeometriesConfig.html +10 -11
  159. package/docs/interfaces/GuideLinePluginType.ModelGuideLineStyle.html +20 -21
  160. package/docs/interfaces/GuideLinePluginType.ModelGuideLineTagData.html +9 -10
  161. package/docs/interfaces/GuideLinePluginType.PanoramaGuideLineStyle.html +20 -21
  162. package/docs/interfaces/GuideLinePluginType.PluginDataV2.html +7 -8
  163. package/docs/interfaces/GuideLinePluginType.PluginServerData.html +8 -9
  164. package/docs/interfaces/GuideLinePluginType.PluginState.html +10 -11
  165. package/docs/interfaces/GuideLinePluginType.Route.html +13 -14
  166. package/docs/interfaces/GuideLinePluginType.RouteConfig.html +11 -12
  167. package/docs/interfaces/HelperOffset.html +10 -11
  168. package/docs/interfaces/ImagePlaneGroup.html +8 -9
  169. package/docs/interfaces/ItemLabelPluginData.html +8 -9
  170. package/docs/interfaces/ItemLabelPluginExportReturnsType.html +13 -14
  171. package/docs/interfaces/ItemLabelPluginParametersType.html +11 -12
  172. package/docs/interfaces/MinMax.html +9 -10
  173. package/docs/interfaces/ModelChassisCompassPluginData.html +9 -10
  174. package/docs/interfaces/ModelChassisCompassPluginExportType.html +10 -11
  175. package/docs/interfaces/ModelChassisCompassPluginParameterType.html +9 -10
  176. package/docs/interfaces/ModelEntryDoorGuidePluginData.html +10 -11
  177. package/docs/interfaces/ModelEntryDoorGuidePluginExportType.html +10 -11
  178. package/docs/interfaces/ModelItemLabelPluginData.html +8 -9
  179. package/docs/interfaces/ModelItemLabelPluginExportReturnsType.html +13 -14
  180. package/docs/interfaces/ModelItemLabelPluginParametersType.html +9 -10
  181. package/docs/interfaces/ModelRoomLabelPluginData.html +8 -9
  182. package/docs/interfaces/ModelTVVideoPluginData.html +11 -12
  183. package/docs/interfaces/ModelTVVideoPluginExportType.html +10 -11
  184. package/docs/interfaces/ModelTVVideoPluginParameterType.html +8 -9
  185. package/docs/interfaces/ModelViewPluginExportType.html +13 -14
  186. package/docs/interfaces/Object3DHelperState.html +10 -11
  187. package/docs/interfaces/ObjectHelperControllers.html +11 -12
  188. package/docs/interfaces/PaintBrushAction.html +14 -15
  189. package/docs/interfaces/PaintBrushConfigs.html +14 -15
  190. package/docs/interfaces/PaintBrushState.html +12 -13
  191. package/docs/interfaces/PanoCursorRaycasterPluginExportType.html +12 -13
  192. package/docs/interfaces/PanoCursorRaycasterPluginParameterType.html +7 -8
  193. package/docs/interfaces/PanoMeasureParameterType.html +18 -19
  194. package/docs/interfaces/PanoMeasurePluginLineJson.html +10 -11
  195. package/docs/interfaces/PanoMeasurePluginOpenParameter.html +9 -10
  196. package/docs/interfaces/PanoMeasurePluginPointJson.html +9 -10
  197. package/docs/interfaces/PanoMeasurePluginPolylineJson.html +10 -11
  198. package/docs/interfaces/PanoRulerPluginExportType.html +12 -13
  199. package/docs/interfaces/PanoRulerPluginOptions.html +9 -10
  200. package/docs/interfaces/PanoRulerPluginParameterType.html +10 -11
  201. package/docs/interfaces/PanoRulerProPluginExportType.html +11 -12
  202. package/docs/interfaces/PanoRulerProPluginOptions.html +9 -10
  203. package/docs/interfaces/PanoRulerProPluginParameterType.html +9 -10
  204. package/docs/interfaces/PanoRulerProPluginState.html +10 -11
  205. package/docs/interfaces/PanoSpatialTagPluginContentEvent.html +7 -8
  206. package/docs/interfaces/PanoSpatialTagPluginContentReplacement.html +7 -8
  207. package/docs/interfaces/PanoSpatialTagPluginData.html +13 -14
  208. package/docs/interfaces/PanoSpatialTagPluginDataElement.html +12 -13
  209. package/docs/interfaces/PanoSpatialTagPluginExportType.html +15 -16
  210. package/docs/interfaces/PanoSpatialTagPluginOriginElement.html +12 -13
  211. package/docs/interfaces/PanoSpatialTagPluginParameterType.html +15 -16
  212. package/docs/interfaces/PanoSpatialTagPluginPointElement.html +13 -14
  213. package/docs/interfaces/PanoSpatialTagPluginTagElement.html +12 -13
  214. package/docs/interfaces/PanoVideoPluginType.LoadParams.html +8 -9
  215. package/docs/interfaces/PanoVideoPluginType.PanoVideoItem.html +10 -11
  216. package/docs/interfaces/PanoVideoPluginType.PluginData.html +8 -9
  217. package/docs/interfaces/PanoVideoPluginType.PluginEventMap.html +11 -12
  218. package/docs/interfaces/PanoVideoPluginType.PluginState.html +8 -9
  219. package/docs/interfaces/PanoVideoPluginType.VideoItem.html +10 -11
  220. package/docs/interfaces/PanoVideoPluginType.VideoMeshParams.html +12 -13
  221. package/docs/interfaces/Point.html +10 -11
  222. package/docs/interfaces/Room.html +11 -12
  223. package/docs/interfaces/RoomInfo.html +9 -10
  224. package/docs/interfaces/RoomLabel.html +16 -17
  225. package/docs/interfaces/RoomRules.html +7 -8
  226. package/docs/interfaces/Rooms.html +7 -8
  227. package/docs/interfaces/Scissor.html +11 -12
  228. package/docs/interfaces/State.html +10 -11
  229. package/docs/interfaces/TagCacheInterface.html +14 -15
  230. package/docs/interfaces/TagConfig.html +17 -18
  231. package/docs/interfaces/TagGLTFObjectGroup.html +8 -9
  232. package/docs/interfaces/TagIconUrl.html +14 -15
  233. package/docs/interfaces/TagObjectGroup.html +8 -9
  234. package/docs/interfaces/TagStyle.html +8 -9
  235. package/docs/interfaces/Tags.html +11 -12
  236. package/docs/interfaces/TemporaryState.html +8 -9
  237. package/docs/interfaces/Util.MagnifierParameter.html +15 -13
  238. package/docs/interfaces/Util.MouseGroupParameter.html +12 -10
  239. package/docs/interfaces/Util.PointIntersection.html +12 -10
  240. package/docs/modules/AreaMakerPluginPluginType.html +319 -0
  241. package/docs/modules/CruisePluginTypes.html +7 -8
  242. package/docs/modules/GuideLineItem.html +7 -8
  243. package/docs/modules/GuideLineModeItem.html +7 -8
  244. package/docs/modules/GuideLinePluginType.html +7 -8
  245. package/docs/modules/PanoVideoPluginType.html +7 -8
  246. package/docs/modules/Util.html +12 -7
  247. package/docs/modules.html +10 -12
  248. package/docs/types/AreaMakerPluginPluginType.AreaMakerItemEventMap.html +327 -0
  249. package/docs/types/{FloorplanRoomsPluginReturnType.html → AreaMakerPluginPluginType.PluginData.html} +35 -14
  250. package/docs/types/{FloorplanRoomsPluginParameterType.html → AreaMakerPluginPluginType.ServerData.html} +35 -14
  251. package/docs/types/ArrayPosition.html +7 -8
  252. package/docs/types/AudioAppearance.html +7 -8
  253. package/docs/types/AudioTagTypeConfigKey.html +7 -8
  254. package/docs/types/CSS3DRenderExportType.html +7 -8
  255. package/docs/types/CSS3DRenderPluginExportType.html +7 -8
  256. package/docs/types/CSS3DRenderPluginParameterType.html +7 -8
  257. package/docs/types/ClassFunctionParameters.html +7 -8
  258. package/docs/types/Color.html +7 -8
  259. package/docs/types/ContentTypeConfigKey.html +7 -8
  260. package/docs/types/ContentTypeConfigKeySplit.html +7 -8
  261. package/docs/types/ContentTypeMap.html +7 -8
  262. package/docs/types/Create3DDomContainerReturnType.html +7 -8
  263. package/docs/types/Create3DElementReturnType.html +7 -8
  264. package/docs/types/CruisePluginExportType.html +7 -8
  265. package/docs/types/CruisePluginTypes.CruiseData.html +7 -8
  266. package/docs/types/CruisePluginTypes.MoveEffect.html +7 -8
  267. package/docs/types/DeprecatedMediaPlaneProperty.html +7 -8
  268. package/docs/types/DeprecatedTagProperty.html +7 -8
  269. package/docs/types/Direction-1.html +7 -8
  270. package/docs/types/Direction4.html +7 -8
  271. package/docs/types/ElementRenderer.html +7 -8
  272. package/docs/types/FloorplanRuleLabels.html +7 -8
  273. package/docs/types/FloorplanServerRuleLabels.html +7 -8
  274. package/docs/types/GuideLinePluginExportType.html +7 -8
  275. package/docs/types/GuideLinePluginType.GuideLineItem.html +7 -8
  276. package/docs/types/GuideLinePluginType.GuideLineItemEventMap.html +7 -8
  277. package/docs/types/GuideLinePluginType.GuideLineModeItemMode.html +7 -8
  278. package/docs/types/GuideLinePluginType.GuideLineStyle.html +7 -8
  279. package/docs/types/GuideLinePluginType.ModelGuideLineTag.html +7 -8
  280. package/docs/types/GuideLinePluginType.PathItem.html +7 -8
  281. package/docs/types/GuideLinePluginType.PluginData.html +7 -8
  282. package/docs/types/HelperEventMap.html +7 -8
  283. package/docs/types/LoadTagConfig.html +7 -8
  284. package/docs/types/MapviewFloorplanPluginParameterType.html +7 -8
  285. package/docs/types/MapviewFloorplanPluginReturnType.html +7 -8
  286. package/docs/types/MediaData.html +7 -8
  287. package/docs/types/MediaStore.html +7 -8
  288. package/docs/types/ModelEntryDoorGuidePluginParameterType.html +7 -8
  289. package/docs/types/ModelFloorplanPluginParameterType.html +7 -8
  290. package/docs/types/ModelFloorplanPluginReturnType.html +7 -8
  291. package/docs/types/ModelRoomLabelPluginParameters.html +7 -8
  292. package/docs/types/ModelRoomLabelPluginReturnType.html +7 -8
  293. package/docs/types/MoveArgs.html +7 -8
  294. package/docs/types/MoveOpts.html +7 -8
  295. package/docs/types/Object3DHelperEventMap.html +7 -8
  296. package/docs/types/ObjectFit.html +7 -8
  297. package/docs/types/PaintBrushEventMap.html +7 -8
  298. package/docs/types/PanoCompassPluginData.html +7 -8
  299. package/docs/types/PanoCompassPluginExportType.html +7 -8
  300. package/docs/types/PanoCompassPluginParameterType.html +7 -8
  301. package/docs/types/PanoFloorplanRadarPluginParameterType.html +7 -8
  302. package/docs/types/PanoFloorplanRadarPluginReturnType.html +7 -8
  303. package/docs/types/PanoIndex.html +7 -8
  304. package/docs/types/PanoMeasurePluginEvent.html +7 -8
  305. package/docs/types/PanoMeasureReturnType.html +7 -8
  306. package/docs/types/PanoSpatialTagPluginId.html +7 -8
  307. package/docs/types/PanoTagPluginExportInterface.html +7 -8
  308. package/docs/types/PanoTagPluginParamsInterface.html +7 -8
  309. package/docs/types/PanoVideoPluginParameterType.html +7 -8
  310. package/docs/types/PanoVideoPluginReturnType.html +7 -8
  311. package/docs/types/PickTagContentTypeInContentTypeConfigKey.html +7 -8
  312. package/docs/types/PipelinePluginParameterType.html +7 -8
  313. package/docs/types/PipelinePluginReturnType.html +7 -8
  314. package/docs/types/PlaneTag.html +7 -8
  315. package/docs/types/Point2DTag.html +7 -8
  316. package/docs/types/Point3DTag.html +7 -8
  317. package/docs/types/PointTag.html +7 -8
  318. package/docs/types/PointTagInstance.html +7 -8
  319. package/docs/types/Position.html +7 -8
  320. package/docs/types/RotateArgs.html +7 -8
  321. package/docs/types/RotateOpts.html +7 -8
  322. package/docs/types/RuleLabelsKey.html +7 -8
  323. package/docs/types/RuleLabelsValue.html +7 -8
  324. package/docs/types/StickType.html +7 -8
  325. package/docs/types/Tag.html +9 -10
  326. package/docs/types/Tag2D.html +7 -8
  327. package/docs/types/Tag3D.html +7 -8
  328. package/docs/types/TagConfigByKey.html +7 -8
  329. package/docs/types/TagContentType.html +7 -8
  330. package/docs/types/TagDimensionType.html +7 -8
  331. package/docs/types/TagElement.html +7 -8
  332. package/docs/types/TagEvents.html +7 -8
  333. package/docs/types/TagGLTFObject.html +7 -8
  334. package/docs/types/TagHooks.html +7 -8
  335. package/docs/types/TagId.html +7 -8
  336. package/docs/types/TagInstance.html +7 -8
  337. package/docs/types/TagPointType.html +7 -8
  338. package/docs/types/TagRendererMap.html +7 -8
  339. package/docs/types/TopviewFloorplanPluginParameterType.html +7 -8
  340. package/docs/types/TopviewFloorplanPluginReturnType.html +7 -8
  341. package/docs/types/WorkCode.html +7 -8
  342. package/docs/variables/FLOOR_TYPE_MAP.html +7 -8
  343. package/docs/variables/PLUGIN.html +7 -8
  344. package/docs/variables/ROOM_FETILE_TYPE_MAP.html +7 -8
  345. package/docs/variables/ROOM_TYPE_MAP.html +7 -8
  346. package/docs/variables/defaultGlobalConfig.html +8 -9
  347. package/docs/variables/itemLabelPluginServerParams.html +7 -8
  348. package/docs/variables/modelItemLabelPluginServerParams.html +7 -8
  349. package/docs/variables/modelRoomLabelPluginServerParams.html +7 -8
  350. package/libs/AreaMakerPlugin/Controller.d.ts +94 -0
  351. package/libs/AreaMakerPlugin/Controller.js +336 -0
  352. package/libs/AreaMakerPlugin/index.d.ts +4 -0
  353. package/libs/AreaMakerPlugin/index.js +37 -0
  354. package/libs/AreaMakerPlugin/typing.d.ts +148 -0
  355. package/libs/AreaMakerPlugin/utils/Item.d.ts +115 -0
  356. package/libs/AreaMakerPlugin/utils/Item.js +266 -0
  357. package/libs/GuideLinePlugin/GuideLineModeItem/index.js +42 -39
  358. package/libs/GuideLinePlugin/utils/createLineGeometry.d.ts +0 -5
  359. package/libs/GuideLinePlugin/utils/createLineGeometry.js +13 -13
  360. package/libs/PanoTagPlugin/controller/TagRender.js +19 -18
  361. package/libs/PanoTagPlugin/typings/tag/Tag.d.ts +1 -1
  362. package/libs/PanoTagPlugin/typings/tag/TagConfig.d.ts +2 -4
  363. package/libs/PanoTagPlugin/typings/tag/TagData.d.ts +2 -0
  364. package/libs/PanoTagPlugin/utils/model/mediaPlane.js +10 -10
  365. package/libs/base/BasePlugin.js +1 -1
  366. package/libs/base/BasePluginWithData.d.ts +1 -1
  367. package/libs/components/AreaLabel/Assets/roomLabelBg.d.ts +1 -0
  368. package/libs/components/AreaLabel/Assets/roomLabelBg.js +4 -0
  369. package/libs/components/AreaLabel/LabelItem.js +125 -0
  370. package/libs/floorplan/MapviewFloorplanPlugin/Controller.js +49 -48
  371. package/libs/floorplan/index.d.ts +0 -1
  372. package/libs/floorplan/utils/correctFiveState.d.ts +2 -0
  373. package/libs/floorplan/utils/correctFiveState.js +28 -28
  374. package/libs/index.d.ts +1 -0
  375. package/libs/index.js +120 -122
  376. package/libs/shared-utils/device.js +0 -1
  377. package/libs/shared-utils/five/changeMode.js +32 -29
  378. package/libs/shared-utils/index.d.ts +1 -0
  379. package/libs/shared-utils/index.js +27 -21
  380. package/libs/shared-utils/logger.js +1 -1
  381. package/libs/shared-utils/math/planimetry.d.ts +1 -1
  382. package/libs/shared-utils/math/planimetry.js +36 -29
  383. package/libs/shared-utils/three/core/Object3D.d.ts +8 -0
  384. package/libs/shared-utils/three/core/Object3D.js +22 -0
  385. package/libs/shared-utils/three/index.d.ts +2 -0
  386. package/libs/shared-utils/three/loadVideoTexture.d.ts +1 -1
  387. package/libs/shared-utils/three/loadVideoTexture.js +6 -6
  388. package/libs/shared-utils/three/objects/LineSegments.d.ts +9 -0
  389. package/libs/shared-utils/three/objects/LineSegments.js +9 -0
  390. package/libs/vendor/svelte/internal/index.js +79 -85
  391. package/package.json +2 -2
  392. package/dist/floorplan/FloorplanRoomsPlugin/BasePlugin.d.ts +0 -114
  393. package/dist/floorplan/FloorplanRoomsPlugin/BasePluginWithData.d.ts +0 -23
  394. package/dist/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/RoomHighlight/Room.svelte.d.ts +0 -1
  395. package/dist/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/RoomHighlight/RoomHighlight.svelte.d.ts +0 -1
  396. package/dist/floorplan/FloorplanRoomsPlugin/Components/Main.svelte.d.ts +0 -1
  397. package/dist/floorplan/FloorplanRoomsPlugin/Controller.d.ts +0 -40
  398. package/dist/floorplan/FloorplanRoomsPlugin/index.d.ts +0 -6
  399. package/dist/floorplan/FloorplanRoomsPlugin/typing.d.ts +0 -60
  400. package/libs/floorplan/FloorplanRoomsPlugin/BasePlugin.d.ts +0 -114
  401. package/libs/floorplan/FloorplanRoomsPlugin/BasePlugin.js +0 -51
  402. package/libs/floorplan/FloorplanRoomsPlugin/BasePluginWithData.d.ts +0 -23
  403. package/libs/floorplan/FloorplanRoomsPlugin/BasePluginWithData.js +0 -25
  404. package/libs/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/CurrentFloor.js +0 -188
  405. package/libs/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/CurrentFloor.svelte.d.ts +0 -1
  406. package/libs/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/ExtraObjects.js +0 -94
  407. package/libs/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/ExtraObjects.svelte.d.ts +0 -1
  408. package/libs/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/RoomHighlight/Room.js +0 -111
  409. package/libs/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/RoomHighlight/Room.svelte.d.ts +0 -1
  410. package/libs/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/RoomHighlight/RoomHighlight.js +0 -191
  411. package/libs/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/RoomHighlight/RoomHighlight.svelte.d.ts +0 -1
  412. package/libs/floorplan/FloorplanRoomsPlugin/Components/Main.js +0 -237
  413. package/libs/floorplan/FloorplanRoomsPlugin/Components/Main.svelte.d.ts +0 -1
  414. package/libs/floorplan/FloorplanRoomsPlugin/Controller.d.ts +0 -40
  415. package/libs/floorplan/FloorplanRoomsPlugin/Controller.js +0 -207
  416. package/libs/floorplan/FloorplanRoomsPlugin/index.d.ts +0 -6
  417. package/libs/floorplan/FloorplanRoomsPlugin/index.js +0 -43
  418. package/libs/floorplan/FloorplanRoomsPlugin/typing.d.ts +0 -60
  419. /package/dist/{floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/CurrentFloor.svelte.d.ts → components/AreaLabel/LabelItem.svelte.d.ts} +0 -0
  420. /package/libs/{floorplan/FloorplanRoomsPlugin → AreaMakerPlugin}/typing.js +0 -0
  421. /package/{dist/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/ExtraObjects.svelte.d.ts → libs/components/AreaLabel/LabelItem.svelte.d.ts} +0 -0
@@ -0,0 +1,336 @@
1
+ var C = Object.defineProperty, M = Object.defineProperties;
2
+ var A = Object.getOwnPropertyDescriptors;
3
+ var f = Object.getOwnPropertySymbols;
4
+ var S = Object.prototype.hasOwnProperty, _ = Object.prototype.propertyIsEnumerable;
5
+ var m = (h, o, t) => o in h ? C(h, o, { enumerable: !0, configurable: !0, writable: !0, value: t }) : h[o] = t, d = (h, o) => {
6
+ for (var t in o || (o = {}))
7
+ S.call(o, t) && m(h, t, o[t]);
8
+ if (f)
9
+ for (var t of f(o))
10
+ _.call(o, t) && m(h, t, o[t]);
11
+ return h;
12
+ }, p = (h, o) => M(h, A(o));
13
+ var r = (h, o, t) => (m(h, typeof o != "symbol" ? o + "" : o, t), t);
14
+ var u = (h, o, t) => new Promise((i, e) => {
15
+ var s = (n) => {
16
+ try {
17
+ c(t.next(n));
18
+ } catch (l) {
19
+ e(l);
20
+ }
21
+ }, a = (n) => {
22
+ try {
23
+ c(t.throw(n));
24
+ } catch (l) {
25
+ e(l);
26
+ }
27
+ }, c = (n) => n.done ? i(n.value) : Promise.resolve(n.value).then(s, a);
28
+ c((t = t.apply(h, o)).next());
29
+ });
30
+ import * as g from "three";
31
+ import { Controller as k } from "../base/BasePluginWithData.js";
32
+ import "hammerjs";
33
+ import "@realsee/five";
34
+ import "../vendor/@tweenjs/tween/dist/tween.esm.js.js";
35
+ import "../CSS3DRenderPlugin/utils/three/CSS3DRender.js";
36
+ import "../CSS3DRenderPlugin/utils/generateBehindFiveElement.js";
37
+ import { equal as I } from "../shared-utils/equal.js";
38
+ import { AreaMakerItem as D } from "./utils/Item.js";
39
+ import "../base/BasePlugin.js";
40
+ import "../shared-utils/Subscribe.js";
41
+ import "../shared-utils/absoluteUrl.js";
42
+ import "../shared-utils/positionToVector3.js";
43
+ import "../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
44
+ import "three/examples/jsm/renderers/CSS3DRenderer";
45
+ import "../CSS3DRenderPlugin/utils/getAllCSS3DObject.js";
46
+ import "../CSS3DRenderPlugin/utils/createResizeObserver.js";
47
+ import "../CSS3DRenderPlugin/utils/even.js";
48
+ import "../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
49
+ import "../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
50
+ import "../shared-utils/three/centerPoint.js";
51
+ import "../CSS3DRenderPlugin/utils/three/CSS3DScene.js";
52
+ import "../CSS3DRenderPlugin/utils/three/CSS3DGroup.js";
53
+ import "../shared-utils/isTruelyObject.js";
54
+ import "../shared-utils/three/core/Object3D.js";
55
+ import "../shared-utils/three/objects/LineSegments.js";
56
+ import "../shared-utils/animationFrame/BetterTween.js";
57
+ import "../shared-utils/animationFrame/index.js";
58
+ import "../components/AreaLabel/LabelItem.js";
59
+ import "../vendor/svelte/internal/index.js";
60
+ import "../components/AreaLabel/Assets/roomLabelBg.js";
61
+ import "../shared-utils/math/planimetry.js";
62
+ class ot extends k {
63
+ /** AreaMakerPlugin
64
+ * @param `five` `<Five>` Five 实例
65
+ * @param `params` `<PluginType.Params> | <undefined>` 插件初始化参数
66
+ * @param `params.initialState` `<PluginType.State> | <undefined>` 插件初始化后,使用的状态
67
+ */
68
+ constructor(t, i) {
69
+ super(t);
70
+ // ==================== public properties ====================
71
+ /** 插件当前状态 */
72
+ r(this, "state");
73
+ /** 标注模型 { id: item } 的映射表 */
74
+ r(this, "itemMap");
75
+ /** 标注模型容器 */
76
+ r(this, "modelGroup");
77
+ /** 当前使用的数据 */
78
+ r(this, "data");
79
+ /** tag 容器 */
80
+ r(this, "tagDomContainer");
81
+ /** 查询问题使用的调试对象 */
82
+ r(this, "checkMsg", {
83
+ childrenMountedState: ""
84
+ });
85
+ // ==================== private properties ====================
86
+ /** 是否在 Five Change Mode 动画中 */
87
+ r(this, "isInFiveChangeModeAnime", !1);
88
+ /** 子组件是否挂载 */
89
+ r(this, "childrenMountedState", !1);
90
+ /** config 的原始值 */
91
+ r(this, "_config");
92
+ /** disposed 的原始值 */
93
+ r(this, "_disposed", !1);
94
+ /** 销毁插件,移除所有副作用,销毁后将不响应任何 API */
95
+ r(this, "dispose", () => {
96
+ this.five.scene.remove(this.modelGroup);
97
+ });
98
+ r(this, "onFiveInitAnimationWillStart", () => {
99
+ this.isInFiveChangeModeAnime = !0, this.updateChildrenMountedState();
100
+ });
101
+ r(this, "onFiveInitAnimationEnded", () => {
102
+ this.isInFiveChangeModeAnime = !1, this.updateChildrenMountedState();
103
+ });
104
+ r(this, "onFiveCameraUpdate", () => {
105
+ const t = this.five.camera;
106
+ [...this.itemMap.values()].sort((e, s) => {
107
+ const a = e.tagPosition.distanceTo(t.position);
108
+ return s.tagPosition.distanceTo(t.position) - a;
109
+ }).forEach((e, s) => {
110
+ var a;
111
+ (a = this.getMaskItemByID(e.id)) == null || a.setTagZIndex(s * 10);
112
+ });
113
+ });
114
+ r(this, "onFiveModeChange", () => {
115
+ this.updateChildrenMountedState();
116
+ });
117
+ r(this, "onMakerTagClick", (t) => {
118
+ this.hooks.emit("wantsTap", { target: t.target, intersectObjects: [] });
119
+ });
120
+ r(this, "onWantsFiveTapGesture", (t) => {
121
+ const i = Array.from(this.itemMap.values()).filter((n) => n.mounted && n.visible).map((n) => ({
122
+ makerItem: n,
123
+ intersects: n.modelGroup.getRaycastIntersects(t)
124
+ })).filter(({ intersects: n }) => n.length > 0);
125
+ if (i.length === 0)
126
+ return;
127
+ const e = i.reduce((n, l) => {
128
+ const v = n.intersects[0].distance, b = l.intersects[0].distance;
129
+ return v < b ? n : l;
130
+ }), s = this.five.model.intersectRaycaster(t)[0];
131
+ if (this.config.modelDepthTest && s && s.distance < e.intersects[0].distance)
132
+ return;
133
+ if (this.hooks.emit("wantsTap", {
134
+ target: e.makerItem,
135
+ intersectObjects: e.intersects
136
+ }))
137
+ return !1;
138
+ });
139
+ this.five = t, this.tagDomContainer = document.createElement("div"), this.tagDomContainer.style.position = "absolute", this.tagDomContainer.style.top = "0", this.tagDomContainer.style.left = "0", this.tagDomContainer.style.width = "100%", this.tagDomContainer.style.height = "100%", this.tagDomContainer.style.pointerEvents = "none";
140
+ const e = {
141
+ enabled: !0,
142
+ visible: !0
143
+ };
144
+ this.state = Object.assign(e, i == null ? void 0 : i.initialState);
145
+ const s = d({
146
+ modelDepthTest: !0
147
+ }, i == null ? void 0 : i.config);
148
+ this._config = s, this.modelGroup = new g.Group(), this.modelGroup.name = "ModelMakerPluginGroup", this.itemMap = /* @__PURE__ */ new Map(), this.state.enabled && this._enable({ userAction: !1 });
149
+ }
150
+ /** 插件配置项 */
151
+ get config() {
152
+ return d({}, this._config);
153
+ }
154
+ /** 是否已经被销毁 */
155
+ get disposed() {
156
+ return this._disposed;
157
+ }
158
+ /** 加载数据,重复调用会使用新数据覆盖旧数据 */
159
+ load(t) {
160
+ return u(this, null, function* () {
161
+ const i = this.data;
162
+ this.data = this.formatData(t), this.hooks.emit("dataChange", this.data, i), this.modelGroup.remove(...this.modelGroup.children), this.itemMap.clear(), this.data.list.forEach((e) => {
163
+ const s = new D(this, e);
164
+ this.modelGroup.add(s.modelGroup), this.itemMap.set(e.id, s), s.hooks.on("tagClick", this.onMakerTagClick);
165
+ });
166
+ });
167
+ }
168
+ /** 将插件的 DOM 容器添加到指定的 DOM 元素上 */
169
+ appendTo(t) {
170
+ t.appendChild(this.tagDomContainer);
171
+ }
172
+ /** 启用插件
173
+ * @param `options` `<Option> | <undefined>`
174
+ * @param `options.userAction` `<boolean> | <undefined>` 是否是用户操作。默认是 true。
175
+ */
176
+ enable(t = {}) {
177
+ var e;
178
+ if (this.state.enabled)
179
+ return;
180
+ const i = (e = t.userAction) != null ? e : !0;
181
+ this.updateState({ enabled: !0 }, i), this._enable({ userAction: i });
182
+ }
183
+ /** 禁用插件
184
+ * @param `options` `<Option> | <undefined>`
185
+ * @param `options.userAction` `<boolean> | <undefined>` 是否是用户操作。默认是 true。
186
+ */
187
+ disable(t = {}) {
188
+ var e;
189
+ if (this.state.enabled === !1)
190
+ return;
191
+ const i = (e = t.userAction) != null ? e : !0;
192
+ this.updateState({ enabled: !1 }, i), this._disable({ userAction: i });
193
+ }
194
+ /** 展示标注
195
+ * @param `options` `<Partial<ShowHideOptions>> | <undefined>`
196
+ * @param `options.userAction` `<boolean> | <undefined>` 是否是用户操作。默认是 true。
197
+ */
198
+ show(t) {
199
+ return u(this, null, function* () {
200
+ if (this.state.visible)
201
+ return Promise.resolve();
202
+ if (this.disposed)
203
+ return Promise.reject(new Error("不能在已销毁的插件上调用 show"));
204
+ const i = d({ userAction: !0 }, t);
205
+ this.updateState({ visible: !0 }, i.userAction), yield this._show(i);
206
+ });
207
+ }
208
+ /** 插件内容整体隐藏
209
+ * @param `options` `<Partial<ShowHideOptions>> | <undefined>`
210
+ * @param `options.userAction` `<boolean> | <undefined>` 是否是用户操作。默认是 true。
211
+ */
212
+ hide(t) {
213
+ return u(this, null, function* () {
214
+ if (this.state.visible === !1)
215
+ return;
216
+ const i = d({ userAction: !0 }, t);
217
+ this.updateState({ visible: !1 }, i.userAction), yield this._hide(i);
218
+ });
219
+ }
220
+ // 目前带动画的展示和隐藏功能有些需求细节没有确定,暂时不实现
221
+ // /** 展示标注
222
+ // * @param `options` `<Partial<ShowHideOptions>> | <undefined>`
223
+ // * @param `options.userAction` `<boolean> | <undefined>` 是否是用户操作。默认是 true。
224
+ // * @param `options.anime` `<AnimeOptions> | <undefined>` 动画配置。
225
+ // * @param `options.anime.duration` `<number> | <undefined>` 动画时间,默认是 500ms。
226
+ // */
227
+ // public async show(options?: Partial<PluginType.ShowHideOptions>): Promise<void> {
228
+ // if (this.state.visible) return Promise.resolve()
229
+ // if (this.disposed) return Promise.reject(new Error('不能在已销毁的插件上调用 show'))
230
+ // const mergedOptions: PluginType.ShowHideOptions = {
231
+ // userAction: true,
232
+ // anime: { duration: 500, ...options?.anime },
233
+ // ...options,
234
+ // }
235
+ // this.updateState({ visible: true }, mergedOptions.userAction)
236
+ // await this._show(mergedOptions)
237
+ // }
238
+ // /** 插件内容整体隐藏
239
+ // * @param `options` `<Partial<ShowHideOptions>> | <undefined>`
240
+ // * @param `options.userAction` `<boolean> | <undefined>` 是否是用户操作。默认是 true。
241
+ // * @param `options.anime` `<AnimeOptions> | <undefined>` 动画配置。
242
+ // * @param `options.anime.duration` `<number> | <undefined>` 动画时间,默认是 500ms。
243
+ // */
244
+ // public async hide(options?: Partial<PluginType.ShowHideOptions>) {
245
+ // if (this.state.visible === false) return
246
+ // const mergedOptions: PluginType.ShowHideOptions = {
247
+ // userAction: true,
248
+ // anime: { duration: 500, ...options?.anime },
249
+ // ...options,
250
+ // }
251
+ // this.updateState({ visible: false }, mergedOptions.userAction)
252
+ // await this._hide(mergedOptions)
253
+ // }
254
+ /** 更改插件 State
255
+ * @param `state` `<Partial<Plugin.State>>` 插件属性 `state` 的子集。
256
+ * @param `options` `<Option> | <undefined>`
257
+ * @param `options.userAction` `<boolean> | <undefined>` 是否是用户操作。默认是 true。
258
+ */
259
+ setState(t, i = {}) {
260
+ const e = this.state;
261
+ if (I(t, e, { deep: !0 }))
262
+ return;
263
+ const s = i.userAction !== void 0 ? i.userAction : !0;
264
+ if (this.updateState(t, s), t.enabled !== void 0 && e.enabled !== t.enabled && (t.enabled ? this._enable({ userAction: s }) : this._disable({ userAction: s })), t.visible !== void 0 && e.visible !== t.visible) {
265
+ const a = { userAction: s, anime: { duration: 500 } };
266
+ t.visible ? this._show(a) : this._hide(a);
267
+ }
268
+ }
269
+ /** 更改插件 Config
270
+ * @param `config` `<Partial<Plugin.Config>>` 插件属性 `config` 的子集。
271
+ * @param `options` `<Option> | <undefined>`
272
+ */
273
+ updateConfig(t, i = {}) {
274
+ var a;
275
+ const e = this.config, s = d(d({}, e), t);
276
+ this._config = s, this.hooks.emit("configChange", { prevConfig: e, config: s, userAction: (a = i.userAction) != null ? a : !0 });
277
+ }
278
+ /** 根据 ID 获取标注 */
279
+ getMaskItemByID(t) {
280
+ return this.itemMap.get(t);
281
+ }
282
+ formatData(t) {
283
+ function i(e) {
284
+ return e.list.length === 0 ? !0 : !("shape" in e.list[0].object_data);
285
+ }
286
+ return i(t) ? {
287
+ list: t.list.filter((e) => e.object_data.points.length >= 3).map((e) => {
288
+ const s = new g.Shape(), a = e.object_data.points[0];
289
+ return s.moveTo(a[0], a[2]), e.object_data.points.slice(1).forEach((n) => s.lineTo(n[0], n[2])), s.lineTo(a[0], a[2]), p(d({}, e), {
290
+ floor_index: e.object_data.floorIndex,
291
+ object_data: p(d({}, e.object_data), {
292
+ bottom_y: a[1] + e.object_data.fixedY,
293
+ shape: s.toJSON(),
294
+ height: e.object_data.height + e.object_data.fixedHeight
295
+ })
296
+ });
297
+ })
298
+ } : t;
299
+ }
300
+ checkChildrenMountedState() {
301
+ const t = this.state, i = this.five;
302
+ if (!t.enabled)
303
+ return { result: !1, msg: "插件不可用" };
304
+ const e = i.getCurrentState().mode;
305
+ return e === "Panorama" ? { result: !1, msg: `Five 模态不符合条件, 当前模态为:${e}` } : this.isInFiveChangeModeAnime ? { result: !1, msg: "切换模态动画中不展示" } : { result: !0, msg: "" };
306
+ }
307
+ updateChildrenMountedState() {
308
+ const { result: t, msg: i } = this.checkChildrenMountedState();
309
+ this.checkMsg.childrenMountedState = i, t !== this.childrenMountedState && (this.childrenMountedState = t, this.itemMap.forEach((e) => {
310
+ this.childrenMountedState ? e.mount() : e.unmount();
311
+ }));
312
+ }
313
+ updateState(t, i) {
314
+ const e = this.state;
315
+ this.state = d(d({}, this.state), t), this.hooks.emit("stateChange", { state: this.state, prevState: e, userAction: i });
316
+ }
317
+ _enable(t) {
318
+ this.hooks.emit("enable", { userAction: t.userAction }), this.five.scene.add(this.modelGroup), this.five.needsRender = !0, this.five.on("wantsTapGesture", this.onWantsFiveTapGesture), this.five.on("initAnimationWillStart", this.onFiveInitAnimationWillStart), this.five.on("initAnimationEnded", this.onFiveInitAnimationEnded), this.five.on("modeChange", this.onFiveModeChange), this.five.on("cameraUpdate", this.onFiveCameraUpdate);
319
+ }
320
+ _disable(t) {
321
+ this.hooks.emit("disable", { userAction: t.userAction }), this.five.scene.remove(this.modelGroup), this.five.needsRender = !0, this.five.off("wantsTapGesture", this.onWantsFiveTapGesture), this.five.off("initAnimationWillStart", this.onFiveInitAnimationWillStart), this.five.off("initAnimationEnded", this.onFiveInitAnimationEnded), this.five.off("modeChange", this.onFiveModeChange), this.five.off("cameraUpdate", this.onFiveCameraUpdate);
322
+ }
323
+ _show(t) {
324
+ return u(this, null, function* () {
325
+ this.hooks.emit("show", t), this.five.needsRender = !0;
326
+ });
327
+ }
328
+ _hide(t) {
329
+ return u(this, null, function* () {
330
+ this.hooks.emit("hide", t), this.five.needsRender = !0;
331
+ });
332
+ }
333
+ }
334
+ export {
335
+ ot as Controller
336
+ };
@@ -0,0 +1,4 @@
1
+ import type { Five } from '@realsee/five';
2
+ import type * as AreaMakerPluginType from './typing';
3
+ export declare const AreaMakerPlugin: (five: Five) => AreaMakerPluginType.AreaMakerController;
4
+ export type { AreaMakerPluginType };
@@ -0,0 +1,37 @@
1
+ import { Controller as o } from "./Controller.js";
2
+ import "three";
3
+ import "../base/BasePluginWithData.js";
4
+ import "../base/BasePlugin.js";
5
+ import "../shared-utils/Subscribe.js";
6
+ import "hammerjs";
7
+ import "@realsee/five";
8
+ import "../vendor/@tweenjs/tween/dist/tween.esm.js.js";
9
+ import "../CSS3DRenderPlugin/utils/three/CSS3DRender.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 "../CSS3DRenderPlugin/utils/createResizeObserver.js";
15
+ import "../CSS3DRenderPlugin/utils/even.js";
16
+ import "../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
17
+ import "../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
18
+ import "../shared-utils/three/centerPoint.js";
19
+ import "../CSS3DRenderPlugin/utils/three/CSS3DScene.js";
20
+ import "../CSS3DRenderPlugin/utils/three/CSS3DGroup.js";
21
+ import "../CSS3DRenderPlugin/utils/generateBehindFiveElement.js";
22
+ import "../shared-utils/absoluteUrl.js";
23
+ import "../shared-utils/equal.js";
24
+ import "../shared-utils/isTruelyObject.js";
25
+ import "./utils/Item.js";
26
+ import "../shared-utils/three/core/Object3D.js";
27
+ import "../shared-utils/three/objects/LineSegments.js";
28
+ import "../shared-utils/animationFrame/BetterTween.js";
29
+ import "../shared-utils/animationFrame/index.js";
30
+ import "../components/AreaLabel/LabelItem.js";
31
+ import "../vendor/svelte/internal/index.js";
32
+ import "../components/AreaLabel/Assets/roomLabelBg.js";
33
+ import "../shared-utils/math/planimetry.js";
34
+ const H = (r) => new o(r);
35
+ export {
36
+ H as AreaMakerPlugin
37
+ };
@@ -0,0 +1,148 @@
1
+ import type * as BasePlugin from '../base/BasePluginWithData';
2
+ import type * as THREE from 'three';
3
+ import type { AreaMakerItem } from './utils/Item';
4
+ export type { Controller as AreaMakerController } from './Controller';
5
+ export type { AreaMakerItem };
6
+ /** 插件初始化参数 */
7
+ export interface Params {
8
+ config?: Partial<Config>;
9
+ initialState?: Partial<State>;
10
+ }
11
+ /** 插件状态 */
12
+ export interface State extends BasePlugin.State {
13
+ /** 插件是否启用 */
14
+ enabled: boolean;
15
+ /** 插件整体是否可见 */
16
+ visible: boolean;
17
+ }
18
+ /** 插件配置 */
19
+ export interface Config {
20
+ /** 标注模型是否开启深度检测,此配置仅对模型生效,不会影响标签的展示效果。
21
+ * @default true
22
+ * @description 关闭后,标注模型不会被其他模型遮挡
23
+ */
24
+ modelDepthTest: boolean;
25
+ }
26
+ /** 插件事件 */
27
+ export interface EventMap extends BasePlugin.EventMap<State, ServerData> {
28
+ /** visible 从 false 到 true 的回调
29
+ * @param event.userAction 是否是用户操作
30
+ */
31
+ show: (event: {
32
+ userAction: boolean;
33
+ }) => void;
34
+ /** visible 从 true 到 false 的回调
35
+ * @param event.userAction 是否是用户操作
36
+ */
37
+ hide: (event: {
38
+ userAction: boolean;
39
+ }) => void;
40
+ /** enabled 从 false 到 true 的回调
41
+ * @param event.userAction 是否是用户操作
42
+ */
43
+ enable: (event: {
44
+ userAction: boolean;
45
+ }) => void;
46
+ /** enabled 从 true 到 false 的回调
47
+ * @param event.userAction 是否是用户操作
48
+ */
49
+ disable: (event: {
50
+ userAction: boolean;
51
+ }) => void;
52
+ /** config 变更的回调
53
+ * @param event.prevConfig 变更前的 config
54
+ * @param event.config 变更后的 config
55
+ * @param event.userAction 是否是用户操作
56
+ */
57
+ configChange: (event: {
58
+ prevConfig: Config;
59
+ config: Config;
60
+ userAction: boolean;
61
+ }) => void;
62
+ /** 插件内容点击的回调
63
+ * @param event.target 点击的标注实例
64
+ * @param event.intersectObjects 射线与标注模型的交点集合
65
+ * @param event.wantsFiveTapGestureParams Five wantsFiveTapGesture 的回调参数
66
+ * @returns <boolean> | <void> 返回 false 会阻止 Five wantsFiveTapGesture 的回调,其余 return 值会被忽略
67
+ */
68
+ wantsTap: (event: {
69
+ target: AreaMakerItem;
70
+ intersectObjects: THREE.Intersection[];
71
+ }) => boolean | void;
72
+ }
73
+ /** 标注实例事件 */
74
+ export type AreaMakerItemEventMap = {
75
+ /** 标注标签点击的回调
76
+ * @param event.target 点击的标注实例
77
+ * @param event.nativeEvent 点击事件的的原始 MouseEvent
78
+ */
79
+ tagClick: (event: {
80
+ target: AreaMakerItem;
81
+ nativeEvent: MouseEvent;
82
+ }) => void;
83
+ };
84
+ /** 动画相关的配置 */
85
+ export interface AnimeOptions {
86
+ /** 动画时长,单位是毫秒 */
87
+ duration?: number;
88
+ }
89
+ export interface ShowHideOptions extends BasePlugin.BaseOptions {
90
+ userAction: boolean;
91
+ }
92
+ /** 第一版数据
93
+ * @description 为什么会存在两种数据?
94
+ * 目前数据是线上已经存在的,这一版数据目前存在以下问题:
95
+ * 1. 无法描述弧线。
96
+ * 2. 数据结构不够清晰,数据存在一定产品逻辑上的抽象,比如说标注的高度,是由楼层高度和人工设置的高度修正组成的。
97
+ */
98
+ export interface ServerDataV1 {
99
+ list: ServerAreaMakerItemV1[];
100
+ }
101
+ /** 第二版数据 */
102
+ export interface ServerDataV2 {
103
+ list: ServerAreaMakerItem[];
104
+ }
105
+ /** load 的数据 */
106
+ export type ServerData = ServerDataV1 | ServerDataV2;
107
+ /** 插件使用的数据 */
108
+ export type PluginData = ServerDataV2;
109
+ export interface ServerAreaMakerItem {
110
+ id: number | string;
111
+ /** 标注名称 */
112
+ name?: string;
113
+ /** 标注所在楼层 */
114
+ floor_index: number;
115
+ /** 标注物体 */
116
+ object_data: {
117
+ /** 标注底面形状,THREE.Shape().toJSON() 的结果 */
118
+ shape: Record<string, any>;
119
+ /** 标注底面 y 坐标 */
120
+ bottom_y: number;
121
+ /** 标注高度,指标注顶部距离底部的距离。只能为正值,单位是米 */
122
+ height: number;
123
+ /** 标注颜色
124
+ * @example "#ffffff"
125
+ */
126
+ color?: string;
127
+ /** 标注透明度 */
128
+ opacity?: number;
129
+ };
130
+ }
131
+ export interface ServerAreaMakerItemV1 {
132
+ id: number;
133
+ name: string;
134
+ object_data: {
135
+ /** 绘制平面的三维世界坐标点集合 */
136
+ points: number[][];
137
+ /** 楼层索引 */
138
+ floorIndex: number;
139
+ /** 楼层高度 */
140
+ height: number;
141
+ /** 人工设置的y坐标方向偏移 */
142
+ fixedY: number;
143
+ /** 人工设置的高度修正 */
144
+ fixedHeight: number;
145
+ color: string;
146
+ opacity?: number;
147
+ };
148
+ }
@@ -0,0 +1,115 @@
1
+ import * as THREE from 'three';
2
+ import { Object3D } from '../../shared-utils';
3
+ import { LineSegments } from '../../shared-utils';
4
+ import type { Controller } from '../Controller';
5
+ import type * as PluginType from '../typing';
6
+ import LabelItem from '../../components/AreaLabel/LabelItem.svelte';
7
+ import { Subscribe } from '../../shared-utils/Subscribe';
8
+ declare class AreaMakerModelGroup extends Object3D {
9
+ private areaMakerItem;
10
+ constructor(areaMakerItem: AreaMakerItem);
11
+ raycast(raycaster: THREE.Raycaster, intersects: THREE.Intersection[]): void;
12
+ }
13
+ export declare class AreaMakerItem {
14
+ id: string | number;
15
+ /** 标注名称 */
16
+ name: string;
17
+ /** 标注几何体 */
18
+ makerObject: THREE.Mesh<THREE.ExtrudeBufferGeometry, THREE.MeshBasicMaterial>;
19
+ /** 标注几何体的边框 */
20
+ outline: LineSegments<THREE.EdgesGeometry, THREE.LineBasicMaterial>;
21
+ /** 标注底面 Y 坐标 */
22
+ bottomY: PluginType.ServerAreaMakerItem['object_data']['bottom_y'];
23
+ /** 标注透明度 */
24
+ opacity: PluginType.ServerAreaMakerItem['object_data']['opacity'];
25
+ /** 标注高度 */
26
+ height: PluginType.ServerAreaMakerItem['object_data']['height'];
27
+ /** 标注所在楼层 */
28
+ floorIndex: PluginType.ServerAreaMakerItem['floor_index'];
29
+ /** 标注底面形状 */
30
+ shape: THREE.Shape;
31
+ /** 是否被挂载 */
32
+ mounted: boolean;
33
+ /** 查询问题使用的调试对象 */
34
+ checkMsg: {
35
+ /** 当标注没有展示时,可以通过这个字段查看原因 */
36
+ checkVisibleMsg: string;
37
+ /** 当标注标签没有展示时,可以通过这个字段查看原因 */
38
+ checkTagVisibleMsg: string;
39
+ };
40
+ /** 模型容器 */
41
+ modelGroup: AreaMakerModelGroup;
42
+ /** 标注是否可见 */
43
+ visible: boolean;
44
+ /** 标注标签实例 */
45
+ tagApp: LabelItem | null;
46
+ /** 标注标签是否可见 */
47
+ tagVisible: boolean;
48
+ /** 标注标签的世界坐标 */
49
+ tagPosition: THREE.Vector3;
50
+ /** 标注标签的 NDC 坐标 */
51
+ tagNDCPosition: THREE.Vector3;
52
+ /** 标注标签的 transform */
53
+ tagTransform: {
54
+ left: number;
55
+ top: number;
56
+ };
57
+ /** 标注标签的显示层级 */
58
+ tagZIndex: number;
59
+ hooks: Subscribe<PluginType.AreaMakerItemEventMap>;
60
+ /** Plugin 实例 */
61
+ private plugin;
62
+ /** 标注透明度动画 */
63
+ private opacityAnime?;
64
+ constructor(plugin: Controller, data: PluginType.ServerAreaMakerItem);
65
+ /** 挂载标注 */
66
+ mount(): void;
67
+ /** 卸载标注 */
68
+ unmount(): void;
69
+ /** 更改标注透明度
70
+ * @param opacity 标注透明度,范围:0-1
71
+ */
72
+ setOpacity(opacity: number): void;
73
+ /** 更改标注颜色
74
+ * @param color 标注颜色,支持 hex
75
+ * @example setColor('#FF0000')
76
+ */
77
+ setColor(color: string): void;
78
+ /** 更改标注高度
79
+ * @param height 标注高度,单位:米
80
+ */
81
+ setHeight(height: number): void;
82
+ /** 更改标注标签的显示层级
83
+ * @description 为什么需要这个方法
84
+ * 在相机朝向或位置发生变化时,各个标签所在的坐标与相机的远近关系发生了变化,所以标签的层级也会有变化。
85
+ * 比如:
86
+ * - 相机 -> 标签 A -> 标签 B: 标签 A 在标签 B 的前面
87
+ * - 标签 A <- 标签 B <- 相机: 标签 A 在标签 B 的后面
88
+ * 但是当前元素是无法感知到这种变化的,所以需要通过父元素调用这个方法来更新标签的层级。
89
+ */
90
+ setTagZIndex(zIndex: number): void;
91
+ /** 显示标注 */
92
+ /** 隐藏标注 */
93
+ /** 透明度动画 */
94
+ private doOpacityAnime;
95
+ /** 插件 Config 变化时更新自身 depthTest */
96
+ private onPluginConfigChange;
97
+ private onPluginStateChange;
98
+ /** 更新标注可见性 */
99
+ private updateVisible;
100
+ /** 检测标注是否可见 */
101
+ private checkVisible;
102
+ /** 更新标注标签 */
103
+ private updateTag;
104
+ /** 更新标注标签的 NDC Position */
105
+ private updateTagNDCPosition;
106
+ /** 更新标注标签的 transform */
107
+ private updateTagDomTransform;
108
+ /** 更新标注标签可见性 */
109
+ private updateTagVisible;
110
+ /** 检测标注标签是否可见 */
111
+ private checkTagVisible;
112
+ /** 相机位姿发生变化时,更新标签 */
113
+ private onFiveCameraUpdate;
114
+ }
115
+ export {};