@realsee/dnalogel 2.1.2-alpha.0 → 2.1.2-alpha.10

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 (494) hide show
  1. package/README.md +3 -12
  2. package/dist/CSS3DRenderPlugin/index..js +88 -0
  3. package/dist/CSS3DRenderPlugin/index.cjs.js +1 -0
  4. package/dist/CameraMovementPlugin/index..js +11 -0
  5. package/dist/CameraMovementPlugin/index.cjs.js +1 -0
  6. package/dist/CruisePlugin/index..js +527 -0
  7. package/dist/CruisePlugin/index.cjs.js +1 -0
  8. package/dist/GuideLinePlugin/index..js +214 -0
  9. package/dist/GuideLinePlugin/index.cjs.js +1 -0
  10. package/dist/ItemLabelPlugin/index..js +508 -0
  11. package/dist/ItemLabelPlugin/index.cjs.js +10 -0
  12. package/dist/ModelChassisCompassPlugin/index..js +9 -0
  13. package/dist/ModelChassisCompassPlugin/index.cjs.js +1 -0
  14. package/dist/ModelEntryDoorGuidePlugin/index..js +9 -0
  15. package/dist/ModelEntryDoorGuidePlugin/index.cjs.js +1 -0
  16. package/dist/ModelItemLabelPlugin/index..js +334 -0
  17. package/dist/ModelItemLabelPlugin/index.cjs.js +10 -0
  18. package/dist/ModelRoomLabelPlugin/index..js +274 -0
  19. package/dist/ModelRoomLabelPlugin/index.cjs.js +1 -0
  20. package/dist/ModelTVVideoPlugin/index..js +12 -0
  21. package/dist/ModelTVVideoPlugin/index.cjs.js +1 -0
  22. package/dist/ModelViewPlugin/index..js +8 -0
  23. package/dist/ModelViewPlugin/index.cjs.js +1 -0
  24. package/dist/Object3DHelperPlugin/index..js +1414 -0
  25. package/dist/Object3DHelperPlugin/index.cjs.js +1 -0
  26. package/dist/PanoCompassPlugin/index..js +258 -0
  27. package/dist/PanoCompassPlugin/index.cjs.js +1 -0
  28. package/dist/PanoCursorRaycasterPlugin/index..js +63 -0
  29. package/dist/PanoCursorRaycasterPlugin/index.cjs.js +1 -0
  30. package/dist/PanoDoorLabelPlugin/index..js +340 -0
  31. package/dist/PanoDoorLabelPlugin/index.cjs.js +1 -0
  32. package/dist/PanoMeasurePlugin/index..js +15 -0
  33. package/dist/PanoMeasurePlugin/index.cjs.js +1 -0
  34. package/dist/PanoRulerPlugin/index..js +9 -0
  35. package/dist/PanoRulerPlugin/index.cjs.js +1 -0
  36. package/dist/PanoRulerProPlugin/index..js +395 -0
  37. package/dist/PanoRulerProPlugin/index.cjs.js +1 -0
  38. package/dist/PanoSpatialTagPlugin/index..js +15 -0
  39. package/dist/PanoSpatialTagPlugin/index.cjs.js +1 -0
  40. package/dist/PanoTagPlugin/index..js +4522 -0
  41. package/dist/PanoTagPlugin/index.cjs.js +17 -0
  42. package/dist/chunks/cjs/BasePlugin.57e5204f.cjs.js +1 -0
  43. package/dist/chunks/cjs/BasePluginWithData.0a28882d.cjs.js +1 -0
  44. package/dist/chunks/cjs/CSS3DRender.15349564.cjs.js +1 -0
  45. package/dist/chunks/cjs/CameraMovementPlugin.2b342576.cjs.js +1 -0
  46. package/dist/chunks/cjs/Plugin.5f616fb3.cjs.js +1 -0
  47. package/dist/chunks/cjs/Plugin.609da4aa.cjs.js +94 -0
  48. package/dist/chunks/cjs/Plugin.67936d0e.cjs.js +16 -0
  49. package/dist/chunks/cjs/Plugin.8a110c53.cjs.js +1 -0
  50. package/dist/chunks/cjs/Plugin.9971108a.cjs.js +1 -0
  51. package/dist/chunks/cjs/Plugin.fd42bf8a.cjs.js +1 -0
  52. package/dist/chunks/cjs/Subscribe.5398d5c6.cjs.js +1 -0
  53. package/dist/chunks/cjs/changeModelCanvasOpacity.8d84f111.cjs.js +1 -0
  54. package/dist/chunks/cjs/correctFiveState.4c8472bd.cjs.js +1 -0
  55. package/dist/chunks/cjs/debounce.93dfb637.cjs.js +1 -0
  56. package/dist/chunks/cjs/equal.e9fcbd4e.cjs.js +1 -0
  57. package/dist/chunks/cjs/filter.cf9ebbb3.cjs.js +1 -0
  58. package/dist/chunks/cjs/formatData.81e95011.cjs.js +10 -0
  59. package/dist/chunks/cjs/index.30b7baeb.cjs.js +101 -0
  60. package/dist/chunks/cjs/index.686e84d1.cjs.js +290 -0
  61. package/dist/chunks/cjs/index.7d2010ce.cjs.js +1 -0
  62. package/dist/chunks/cjs/isNil.b3a58990.cjs.js +1 -0
  63. package/dist/chunks/cjs/planimetry.7fce816a.cjs.js +1 -0
  64. package/dist/chunks/cjs/throttle.86c209eb.cjs.js +1 -0
  65. package/dist/chunks/cjs/transfromToMeshBasicMaterial.9db6d46a.cjs.js +1 -0
  66. package/dist/chunks/cjs/uuid.29ed9c88.cjs.js +1 -0
  67. package/dist/chunks/es/BasePlugin.813e25f7.es.js +18 -0
  68. package/dist/chunks/es/BasePluginWithData.4bf4e649.es.js +6 -0
  69. package/dist/chunks/es/CSS3DRender.5652510e.es.js +393 -0
  70. package/dist/chunks/es/CameraMovementPlugin.4a7c3e46.es.js +120 -0
  71. package/dist/chunks/es/Plugin.26c2df05.es.js +106 -0
  72. package/dist/chunks/es/Plugin.435485ed.es.js +584 -0
  73. package/dist/chunks/es/Plugin.a98418f0.es.js +82 -0
  74. package/dist/chunks/es/Plugin.ae4ee6f8.es.js +82 -0
  75. package/dist/chunks/es/Plugin.dd11e0ad.es.js +180 -0
  76. package/dist/chunks/es/Plugin.f4cf895f.es.js +355 -0
  77. package/dist/chunks/es/Subscribe.c73e0f91.es.js +50 -0
  78. package/dist/chunks/es/changeModelCanvasOpacity.45ef9fd6.es.js +1551 -0
  79. package/dist/chunks/es/correctFiveState.e7feab9f.es.js +66 -0
  80. package/dist/chunks/es/debounce.ef83f417.es.js +11 -0
  81. package/dist/chunks/es/equal.7db4a6f7.es.js +56 -0
  82. package/dist/chunks/es/filter.97ec06c4.es.js +12 -0
  83. package/dist/chunks/es/formatData.a2b39ef9.es.js +483 -0
  84. package/dist/chunks/es/index.a273f06e.es.js +532 -0
  85. package/dist/chunks/es/index.b8fdb59b.es.js +50 -0
  86. package/dist/chunks/es/index.f74f4851.es.js +1787 -0
  87. package/dist/chunks/es/isNil.212842d9.es.js +10 -0
  88. package/dist/chunks/es/planimetry.b0b4a28d.es.js +43 -0
  89. package/dist/chunks/es/throttle.db66bac3.es.js +11 -0
  90. package/dist/chunks/es/transfromToMeshBasicMaterial.849ee069.es.js +24 -0
  91. package/dist/chunks/es/uuid.676cb2c8.es.js +9 -0
  92. package/dist/components/PaintBrush/index..js +6 -0
  93. package/dist/components/PaintBrush/index.cjs.js +1 -0
  94. package/dist/components/index..js +7 -0
  95. package/dist/components/index.cjs.js +1 -0
  96. package/dist/floorplan/MapviewFloorplanPlugin/index..js +324 -0
  97. package/dist/floorplan/MapviewFloorplanPlugin/index.cjs.js +1 -0
  98. package/dist/floorplan/ModelFloorplanPlugin/index..js +320 -0
  99. package/dist/floorplan/ModelFloorplanPlugin/index.cjs.js +1 -0
  100. package/dist/floorplan/PanoFloorplanRadarPlugin/index..js +613 -0
  101. package/dist/floorplan/PanoFloorplanRadarPlugin/index.cjs.js +1 -0
  102. package/dist/floorplan/TopviewFloorplanPlugin/index..js +277 -0
  103. package/dist/floorplan/TopviewFloorplanPlugin/index.cjs.js +1 -0
  104. package/dist/index..js +530 -0
  105. package/dist/index.cjs.js +3 -543
  106. package/docs/classes/CruisePluginController.html +24 -24
  107. package/docs/classes/Magnifier.html +16 -16
  108. package/docs/classes/ModelRoomLabelController.html +11 -11
  109. package/docs/classes/Object3DHelperController.html +24 -24
  110. package/docs/classes/PaintBrush.html +15 -15
  111. package/docs/classes/PanoTagPluginController.html +39 -39
  112. package/docs/classes/Util.BetterTween.html +8 -8
  113. package/docs/classes/Util.FivePointSelector.html +12 -12
  114. package/docs/classes/Util.Interval.html +12 -12
  115. package/docs/classes/Util.Magnifier.html +17 -17
  116. package/docs/classes/Util.PointDomHelper.html +11 -11
  117. package/docs/classes/Util.PointHelper.html +11 -11
  118. package/docs/classes/Util.Rectangle.html +13 -13
  119. package/docs/enums/CameraMovementEffect.html +7 -7
  120. package/docs/enums/ContentType.html +12 -12
  121. package/docs/enums/DIRECTION.html +9 -9
  122. package/docs/enums/DISPLAY_STRATEGY_TYPE.html +9 -9
  123. package/docs/enums/DimensionType.html +7 -7
  124. package/docs/enums/FLOOR_PLAN_ATTACHED_TO.html +8 -8
  125. package/docs/enums/ITEM_LABEL_PLUGIN_DISPLAY_STRATEGY_TYPE.html +9 -9
  126. package/docs/enums/LinkType.html +7 -7
  127. package/docs/enums/PaintBrushTypeEnum.html +8 -8
  128. package/docs/enums/PointType.html +7 -7
  129. package/docs/enums/Rotation.html +8 -8
  130. package/docs/functions/CSS3DRenderPlugin.html +4 -4
  131. package/docs/functions/CameraMovementPlugin.html +4 -4
  132. package/docs/functions/CruisePlugin.html +4 -4
  133. package/docs/functions/GuideLinePlugin.html +5 -5
  134. package/docs/functions/ItemLabelPlugin.html +4 -4
  135. package/docs/functions/MapviewFloorplanPlugin.html +4 -4
  136. package/docs/functions/ModelChassisCompassPlugin.html +4 -4
  137. package/docs/functions/ModelEntryDoorGuidePlugin.html +4 -4
  138. package/docs/functions/ModelFloorplanPlugin.html +4 -4
  139. package/docs/functions/ModelItemLabelPlugin.html +4 -4
  140. package/docs/functions/ModelRoomLabelPlugin.html +4 -4
  141. package/docs/functions/ModelTVVideoPlugin.html +4 -4
  142. package/docs/functions/ModelViewPlugin.html +4 -4
  143. package/docs/functions/Object3DHelperPlugin.html +4 -4
  144. package/docs/functions/PanoCompassPlugin.html +4 -4
  145. package/docs/functions/PanoCursorRaycasterPlugin.html +4 -4
  146. package/docs/functions/PanoDoorLabelPlugin.html +4 -4
  147. package/docs/functions/PanoFloorplanRadarPlugin.html +4 -4
  148. package/docs/functions/PanoMeasurePlugin.html +4 -4
  149. package/docs/functions/PanoRulerPlugin.html +4 -4
  150. package/docs/functions/PanoRulerProPlugin.html +4 -4
  151. package/docs/functions/PanoSpatialTagPlugin.html +4 -4
  152. package/docs/functions/PanoTagPlugin.html +4 -4
  153. package/docs/functions/TopviewFloorplanPlugin.html +4 -4
  154. package/docs/functions/Util.getCoordsFromClient.html +5 -5
  155. package/docs/functions/Util.getCoordsFromElement.html +5 -5
  156. package/docs/functions/Util.getFrameTime.html +5 -5
  157. package/docs/functions/Util.getIntersectFromRelativePosition.html +5 -5
  158. package/docs/functions/Util.getRaycasterFromFivePointer.html +5 -5
  159. package/docs/functions/Util.isNil.html +5 -5
  160. package/docs/functions/Util.nextFrame.html +5 -5
  161. package/docs/functions/Util.notNil.html +5 -5
  162. package/docs/functions/Util.requestAnimationFrameInterval.html +5 -5
  163. package/docs/functions/Util.tweenProgress.html +5 -5
  164. package/docs/functions/pluginFlag.html +5 -5
  165. package/docs/index.html +6 -11
  166. package/docs/interfaces/CSS3DRenderPluginEventMap.html +11 -11
  167. package/docs/interfaces/CSS3DRenderPluginState.html +8 -8
  168. package/docs/interfaces/CameraMovementPluginExportType.html +7 -7
  169. package/docs/interfaces/ContentTypeMap.html +12 -12
  170. package/docs/interfaces/FloorplanBounding.html +8 -8
  171. package/docs/interfaces/FloorplanData.html +10 -10
  172. package/docs/interfaces/FloorplanEntrance.html +11 -11
  173. package/docs/interfaces/FloorplanExtraObject.html +10 -10
  174. package/docs/interfaces/FloorplanExtraObject3D.html +8 -8
  175. package/docs/interfaces/FloorplanFloorData.html +9 -9
  176. package/docs/interfaces/FloorplanImagePosition.html +7 -7
  177. package/docs/interfaces/FloorplanObserver.html +9 -9
  178. package/docs/interfaces/FloorplanOutlineItem.html +9 -9
  179. package/docs/interfaces/FloorplanPosition.html +7 -7
  180. package/docs/interfaces/FloorplanRoomItem.html +13 -13
  181. package/docs/interfaces/FloorplanRoomLabelItem.html +7 -7
  182. package/docs/interfaces/FloorplanServerBounding.html +8 -8
  183. package/docs/interfaces/FloorplanServerComputedData.html +10 -10
  184. package/docs/interfaces/FloorplanServerData.html +7 -7
  185. package/docs/interfaces/FloorplanServerDoorItem.html +10 -10
  186. package/docs/interfaces/FloorplanServerDoorPosition.html +8 -8
  187. package/docs/interfaces/FloorplanServerEntrance.html +11 -11
  188. package/docs/interfaces/FloorplanServerFloorData.html +9 -9
  189. package/docs/interfaces/FloorplanServerImagePosition.html +7 -7
  190. package/docs/interfaces/FloorplanServerObserver.html +9 -9
  191. package/docs/interfaces/FloorplanServerOutlineItem.html +9 -9
  192. package/docs/interfaces/FloorplanServerPosition.html +7 -7
  193. package/docs/interfaces/FloorplanServerRoomItem.html +14 -14
  194. package/docs/interfaces/FloorplanServerRoomLabelItem.html +7 -7
  195. package/docs/interfaces/ItemLabelPluginData.html +6 -6
  196. package/docs/interfaces/ItemLabelPluginExportReturnsType.html +11 -11
  197. package/docs/interfaces/ItemLabelPluginParametersType.html +9 -9
  198. package/docs/interfaces/LineJson.html +7 -7
  199. package/docs/interfaces/ModelChassisCompassPluginData.html +7 -7
  200. package/docs/interfaces/ModelChassisCompassPluginExportType.html +8 -8
  201. package/docs/interfaces/ModelChassisCompassPluginParameterType.html +7 -7
  202. package/docs/interfaces/ModelEntryDoorGuidePluginData.html +8 -8
  203. package/docs/interfaces/ModelEntryDoorGuidePluginExportType.html +8 -8
  204. package/docs/interfaces/ModelItemLabelPluginData.html +6 -6
  205. package/docs/interfaces/ModelItemLabelPluginExportReturnsType.html +11 -11
  206. package/docs/interfaces/ModelItemLabelPluginParametersType.html +7 -7
  207. package/docs/interfaces/ModelRoomLabelPluginData.html +6 -6
  208. package/docs/interfaces/ModelTVVideoPluginData.html +9 -9
  209. package/docs/interfaces/ModelTVVideoPluginExportType.html +8 -8
  210. package/docs/interfaces/ModelTVVideoPluginParameterType.html +6 -6
  211. package/docs/interfaces/ModelViewPluginExportType.html +8 -8
  212. package/docs/interfaces/Object3DHelperState.html +8 -8
  213. package/docs/interfaces/OpenParameter.html +7 -7
  214. package/docs/interfaces/PaintBrushAction.html +12 -12
  215. package/docs/interfaces/PaintBrushConfigs.html +12 -12
  216. package/docs/interfaces/PaintBrushState.html +10 -10
  217. package/docs/interfaces/PanoCursorRaycasterPluginExportType.html +10 -10
  218. package/docs/interfaces/PanoCursorRaycasterPluginParameterType.html +5 -5
  219. package/docs/interfaces/PanoMeasureParameterType.html +11 -11
  220. package/docs/interfaces/PanoRulerPluginExportType.html +10 -10
  221. package/docs/interfaces/PanoRulerPluginOptions.html +7 -7
  222. package/docs/interfaces/PanoRulerPluginParameterType.html +8 -8
  223. package/docs/interfaces/PanoRulerProPluginExportType.html +9 -9
  224. package/docs/interfaces/PanoRulerProPluginOptions.html +7 -7
  225. package/docs/interfaces/PanoRulerProPluginParameterType.html +7 -7
  226. package/docs/interfaces/PanoRulerProPluginState.html +8 -8
  227. package/docs/interfaces/PanoSpatialTagPluginContentEvent.html +5 -5
  228. package/docs/interfaces/PanoSpatialTagPluginContentReplacement.html +5 -5
  229. package/docs/interfaces/PanoSpatialTagPluginData.html +11 -11
  230. package/docs/interfaces/PanoSpatialTagPluginDataElement.html +10 -10
  231. package/docs/interfaces/PanoSpatialTagPluginExportType.html +13 -13
  232. package/docs/interfaces/PanoSpatialTagPluginOriginElement.html +10 -10
  233. package/docs/interfaces/PanoSpatialTagPluginParameterType.html +13 -13
  234. package/docs/interfaces/PanoSpatialTagPluginPointElement.html +11 -11
  235. package/docs/interfaces/PanoSpatialTagPluginTagElement.html +10 -10
  236. package/docs/interfaces/Point.html +8 -8
  237. package/docs/interfaces/PointJson.html +8 -8
  238. package/docs/interfaces/Room.html +9 -9
  239. package/docs/interfaces/RoomInfo.html +7 -7
  240. package/docs/interfaces/RoomLabel.html +14 -14
  241. package/docs/interfaces/RoomRules.html +5 -5
  242. package/docs/interfaces/Rooms.html +5 -5
  243. package/docs/interfaces/Scissor.html +9 -9
  244. package/docs/interfaces/TagConfig.html +10 -10
  245. package/docs/interfaces/Tags.html +9 -9
  246. package/docs/interfaces/Util.MagnifierParameter.html +11 -11
  247. package/docs/interfaces/Util.MouseGroupParameter.html +8 -8
  248. package/docs/modules/Util.html +5 -5
  249. package/docs/modules.html +4 -4
  250. package/docs/types/ArrayPosition.html +5 -5
  251. package/docs/types/CSS3DRenderExportType.html +5 -5
  252. package/docs/types/CSS3DRenderPluginExportType.html +5 -5
  253. package/docs/types/CSS3DRenderPluginParameterType.html +5 -5
  254. package/docs/types/Color.html +5 -5
  255. package/docs/types/ContentTypeConfigKey.html +5 -5
  256. package/docs/types/ContentTypeConfigKeyArray.html +5 -5
  257. package/docs/types/Create3DDomContainerReturnType.html +5 -5
  258. package/docs/types/Create3DElementReturnType.html +5 -5
  259. package/docs/types/CruisePluginExportType.html +5 -5
  260. package/docs/types/Direction-1.html +5 -5
  261. package/docs/types/Direction4.html +5 -5
  262. package/docs/types/FloorplanRuleLabels.html +5 -5
  263. package/docs/types/FloorplanServerRuleLabels.html +5 -5
  264. package/docs/types/GuideLinePluginExportType.html +5 -5
  265. package/docs/types/HelperEventMap.html +5 -5
  266. package/docs/types/MapviewFloorplanPluginParameterType.html +5 -5
  267. package/docs/types/MapviewFloorplanPluginReturnType.html +5 -5
  268. package/docs/types/MediaData.html +5 -5
  269. package/docs/types/ModelEntryDoorGuidePluginParameterType.html +5 -5
  270. package/docs/types/ModelFloorplanPluginParameterType.html +5 -5
  271. package/docs/types/ModelFloorplanPluginReturnType.html +5 -5
  272. package/docs/types/ModelRoomLabelPluginParameters.html +5 -5
  273. package/docs/types/ModelRoomLabelPluginReturnType.html +5 -5
  274. package/docs/types/MoveArgs.html +5 -5
  275. package/docs/types/MoveOpts.html +5 -5
  276. package/docs/types/Object3DHelperEventMap.html +5 -5
  277. package/docs/types/ObjectFit.html +5 -5
  278. package/docs/types/PaintBrushEventMap.html +5 -5
  279. package/docs/types/PanoCompassPluginData.html +5 -5
  280. package/docs/types/PanoCompassPluginExportType.html +5 -5
  281. package/docs/types/PanoCompassPluginParameterType.html +5 -5
  282. package/docs/types/PanoFloorplanRadarPluginParameterType.html +5 -5
  283. package/docs/types/PanoFloorplanRadarPluginReturnType.html +5 -5
  284. package/docs/types/PanoMeasurePluginEvent.html +5 -5
  285. package/docs/types/PanoMeasureReturnType.html +5 -5
  286. package/docs/types/PanoSpatialTagPluginId.html +5 -5
  287. package/docs/types/PanoTagPluginExportInterface.html +5 -5
  288. package/docs/types/PanoTagPluginParamsInterface.html +5 -5
  289. package/docs/types/PlaneTag.html +5 -5
  290. package/docs/types/PointTag.html +5 -5
  291. package/docs/types/Position.html +5 -5
  292. package/docs/types/RotateArgs.html +5 -5
  293. package/docs/types/RotateOpts.html +5 -5
  294. package/docs/types/RuleLabelsKey.html +5 -5
  295. package/docs/types/RuleLabelsValue.html +5 -5
  296. package/docs/types/Tag.html +5 -5
  297. package/docs/types/Tag2D.html +5 -5
  298. package/docs/types/Tag3D.html +5 -5
  299. package/docs/types/TagId.html +5 -5
  300. package/docs/types/TopviewFloorplanPluginParameterType.html +5 -5
  301. package/docs/types/TopviewFloorplanPluginReturnType.html +5 -5
  302. package/docs/variables/FLOOR_TYPE_MAP.html +5 -5
  303. package/docs/variables/PLUGIN.html +5 -5
  304. package/docs/variables/ROOM_FETILE_TYPE_MAP.html +5 -5
  305. package/docs/variables/ROOM_TYPE_MAP.html +5 -5
  306. package/docs/variables/VERSION.html +5 -5
  307. package/docs/variables/itemLabelPluginServerParams.html +5 -5
  308. package/docs/variables/modelItemLabelPluginServerParams.html +5 -5
  309. package/docs/variables/modelRoomLabelPluginServerParams.html +5 -5
  310. package/libs/CSS3DRenderPlugin/CSS3DRender.js +1 -5
  311. package/libs/CSS3DRenderPlugin/Controller.js +6 -7
  312. package/libs/CSS3DRenderPlugin/index.js +3 -4
  313. package/libs/CSS3DRenderPlugin/typing.js +1 -0
  314. package/libs/CSS3DRenderPlugin/utils/CSS3DObjectPlus.js +1 -3
  315. package/libs/CSS3DRenderPlugin/utils/index.js +1 -0
  316. package/libs/CSS3DRenderPlugin/utils/positionToVector3.js +1 -2
  317. package/libs/CSS3DRenderPlugin/utils/random.js +1 -0
  318. package/libs/CameraMovementPlugin/CameraMovementPlugin.js +16 -17
  319. package/libs/CameraMovementPlugin/index.js +3 -0
  320. package/libs/CruisePlugin/Controller.js +4 -4
  321. package/libs/CruisePlugin/index.js +3 -6
  322. package/libs/CruisePlugin/utils/linerValue.js +4 -4
  323. package/libs/GuideLinePlugin/Controller.js +3 -4
  324. package/libs/GuideLinePlugin/index.js +3 -4
  325. package/libs/GuideLinePlugin/utils/getLineGeometries.js +1 -1
  326. package/libs/ItemLabelPlugin/ItemLabelComponent.js +34 -32
  327. package/libs/ItemLabelPlugin/Plugin.js +5 -6
  328. package/libs/ModelChassisCompassPlugin/Plugin.js +3 -4
  329. package/libs/ModelChassisCompassPlugin/index.js +2 -0
  330. package/libs/ModelEntryDoorGuidePlugin/Plugin.js +22 -23
  331. package/libs/ModelEntryDoorGuidePlugin/index.js +2 -0
  332. package/libs/ModelItemLabelPlugin/ItemLabelComponent.js +4 -3
  333. package/libs/ModelItemLabelPlugin/ModelItemLabelPlugin.js +5 -6
  334. package/libs/ModelItemLabelPlugin/events.type.js +1 -0
  335. package/libs/ModelRoomLabelPlugin/RoomLabelItems.js +11 -10
  336. package/libs/ModelRoomLabelPlugin/index.js +0 -1
  337. package/libs/ModelTVVideoPlugin/Plugin.js +1 -2
  338. package/libs/ModelTVVideoPlugin/index.js +2 -0
  339. package/libs/ModelViewPlugin/Plugin.js +1 -2
  340. package/libs/ModelViewPlugin/index.js +2 -0
  341. package/libs/Object3DHelperPlugin/FiveControllerWrapper.js +6 -7
  342. package/libs/Object3DHelperPlugin/index.js +1 -6
  343. package/libs/PanoCompassPlugin/index.js +3 -4
  344. package/libs/PanoCursorRaycasterPlugin/index.js +7 -8
  345. package/libs/PanoDoorLabelPlugin/index.js +1 -2
  346. package/libs/PanoMeasurePlugin/Controller/BaseController.js +3 -3
  347. package/libs/PanoMeasurePlugin/Controller/EditController.js +5 -5
  348. package/libs/PanoMeasurePlugin/Controller/MixedController.js +17 -17
  349. package/libs/PanoMeasurePlugin/Controller/ViewController.js +3 -3
  350. package/libs/PanoMeasurePlugin/Controller/WatchController.js +9 -9
  351. package/libs/PanoMeasurePlugin/Controller/index.js +8 -8
  352. package/libs/PanoMeasurePlugin/Model/index.js +3 -3
  353. package/libs/PanoMeasurePlugin/Model/line.js +11 -11
  354. package/libs/PanoMeasurePlugin/Model/point.js +7 -7
  355. package/libs/PanoMeasurePlugin/Model/polyline.js +1 -1
  356. package/libs/PanoMeasurePlugin/Modules/DeleteDom/_Assets/delete.svg.js +1 -1
  357. package/libs/PanoMeasurePlugin/Modules/DeleteDom/_Assets/delete_bg.png.js +1 -1
  358. package/libs/PanoMeasurePlugin/Modules/DeleteDom/_Assets/delete_hover_bg.png.js +1 -1
  359. package/libs/PanoMeasurePlugin/Modules/DeleteDom/index.js +4 -4
  360. package/libs/PanoMeasurePlugin/Modules/FiveHelper.js +3 -3
  361. package/libs/PanoMeasurePlugin/Modules/Magnifier.js +30 -30
  362. package/libs/PanoMeasurePlugin/Modules/UIController/HTML.js +2 -2
  363. package/libs/PanoMeasurePlugin/Modules/UIController/Revoke/index.js +2 -2
  364. package/libs/PanoMeasurePlugin/Modules/UIController/index.js +3 -3
  365. package/libs/PanoMeasurePlugin/Modules/UIController/mobileHTML.js +1 -1
  366. package/libs/PanoMeasurePlugin/Modules/rangePiece/html.js +3 -4
  367. package/libs/PanoMeasurePlugin/Modules/rangePiece/index.js +5 -5
  368. package/libs/PanoMeasurePlugin/index.js +3 -4
  369. package/libs/PanoMeasurePlugin/utils/calculateThreeMouse.js +1 -1
  370. package/libs/PanoMeasurePlugin/utils/distanceDom.js +1 -1
  371. package/libs/PanoMeasurePlugin/utils/findClosestPoint.js +2 -2
  372. package/libs/PanoMeasurePlugin/utils/isNDCPointInScreen.js +3 -3
  373. package/libs/PanoMeasurePlugin/utils/line.js +0 -1
  374. package/libs/PanoMeasurePlugin/utils/math.js +1 -2
  375. package/libs/PanoMeasurePlugin/utils/ndc2Screen.js +2 -2
  376. package/libs/PanoRulerPlugin/Plugin.js +2 -3
  377. package/libs/PanoRulerPlugin/index.js +2 -0
  378. package/libs/PanoRulerPlugin/style.js +1 -1
  379. package/libs/PanoRulerProPlugin/Controller.js +15 -15
  380. package/libs/PanoRulerProPlugin/RulerItems.js +7 -4
  381. package/libs/PanoRulerProPlugin/index.js +3 -4
  382. package/libs/PanoSpatialTagPlugin/Components/origins.js +3 -2
  383. package/libs/PanoSpatialTagPlugin/Components/tag.js +3 -2
  384. package/libs/PanoSpatialTagPlugin/Plugin.js +2 -3
  385. package/libs/PanoSpatialTagPlugin/index.js +6 -0
  386. package/libs/PanoSpatialTagPlugin/typings.js +1 -0
  387. package/libs/PanoTagPlugin/Components/Common/Line/Polyline.js +1 -1
  388. package/libs/PanoTagPlugin/Components/Common/Line/Straight.js +1 -1
  389. package/libs/PanoTagPlugin/Components/Common/Media.js +43 -36
  390. package/libs/PanoTagPlugin/Components/Common/MultiLineText.js +88 -78
  391. package/libs/PanoTagPlugin/Components/Common/Point/CustomPoint.js +5 -4
  392. package/libs/PanoTagPlugin/Components/Common/Point/DefaultPoint.js +3 -2
  393. package/libs/PanoTagPlugin/Components/Common/Point/PointSwitch.js +30 -27
  394. package/libs/PanoTagPlugin/Components/Common/TextItem.js +106 -0
  395. package/libs/PanoTagPlugin/Components/Tag/AudioTag.js +20 -14
  396. package/libs/PanoTagPlugin/Components/Tag/ImageTextTag.js +114 -92
  397. package/libs/PanoTagPlugin/Components/Tag/LinkTag.js +3 -2
  398. package/libs/PanoTagPlugin/Components/Tag/MarketingTag.js +3 -2
  399. package/libs/PanoTagPlugin/Components/Tag/MediaPlane.js +71 -52
  400. package/libs/PanoTagPlugin/Components/Tag/TextTag.js +62 -50
  401. package/libs/PanoTagPlugin/Components/Tag/index.js +92 -63
  402. package/libs/PanoTagPlugin/Components/TagContainer.js +108 -64
  403. package/libs/PanoTagPlugin/Components/TagWrapper.js +113 -75
  404. package/libs/PanoTagPlugin/controller/index.js +0 -1
  405. package/libs/PanoTagPlugin/index.js +3 -7
  406. package/libs/PanoTagPlugin/tag.config.js +1 -2
  407. package/libs/PanoTagPlugin/typings/controller.js +1 -0
  408. package/libs/PanoTagPlugin/typings/index.js +1 -0
  409. package/libs/PanoTagPlugin/utils/constants.js +1 -2
  410. package/libs/PanoTagPlugin/utils/doUtil.js +6 -6
  411. package/libs/PanoTagPlugin/utils/index.js +1 -0
  412. package/libs/components/PaintBrush/Controller.js +3 -3
  413. package/libs/components/PaintBrush/style.js +1 -1
  414. package/libs/components/PaintBrush/tween.js +4 -4
  415. package/libs/components/index.js +2 -0
  416. package/libs/floorplan/Components/Camera.js +1 -1
  417. package/libs/floorplan/Components/CurrentFloor.js +51 -41
  418. package/libs/floorplan/Components/Main.js +41 -22
  419. package/libs/floorplan/Components/RoomHighlight/Room.js +3 -3
  420. package/libs/floorplan/Components/RoomHighlight/RoomHighlight.js +3 -2
  421. package/libs/floorplan/Components/RoomLabels/RoomLabels.js +37 -36
  422. package/libs/floorplan/Components/RoomMaterials/RoomMaterial.js +1 -1
  423. package/libs/floorplan/MapviewFloorplanPlugin/Controller.js +7 -7
  424. package/libs/floorplan/MapviewFloorplanPlugin/index.js +3 -4
  425. package/libs/floorplan/ModelFloorplanPlugin/Controller.js +7 -7
  426. package/libs/floorplan/ModelFloorplanPlugin/index.js +2 -3
  427. package/libs/floorplan/PanoFloorplanRadarPlugin/Components/Camera.js +1 -1
  428. package/libs/floorplan/PanoFloorplanRadarPlugin/Components/CurrentFloor/CurrentFloor.js +6 -2
  429. package/libs/floorplan/PanoFloorplanRadarPlugin/Components/Main.js +74 -65
  430. package/libs/floorplan/PanoFloorplanRadarPlugin/Controller.js +2 -2
  431. package/libs/floorplan/PanoFloorplanRadarPlugin/index.js +2 -3
  432. package/libs/floorplan/TopviewFloorplanPlugin/Controller.js +5 -5
  433. package/libs/floorplan/TopviewFloorplanPlugin/index.js +3 -4
  434. package/libs/floorplan/index.js +6 -0
  435. package/libs/floorplan/typings/floorplanData.js +1 -0
  436. package/libs/floorplan/utils/correctFiveState.js +19 -19
  437. package/libs/floorplan/utils/formatData.js +16 -16
  438. package/libs/floorplan/utils/formatPosition.js +7 -7
  439. package/libs/index.js +344 -90
  440. package/libs/shared-utils/Object3DHelper/Base/BaseController.js +2 -3
  441. package/libs/shared-utils/Object3DHelper/Base/BaseHelper.js +1 -3
  442. package/libs/shared-utils/Object3DHelper/Constants/color.js +0 -1
  443. package/libs/shared-utils/Object3DHelper/Helper/HTML/utils/createElement.js +1 -2
  444. package/libs/shared-utils/Object3DHelper/Helper/index.js +3 -0
  445. package/libs/shared-utils/Object3DHelper/typings/Direction.js +1 -0
  446. package/libs/shared-utils/Object3DHelper/typings/Hooks.js +1 -0
  447. package/libs/shared-utils/Object3DHelper/typings/Scissor.js +1 -0
  448. package/libs/shared-utils/Object3DHelper/typings/index.js +1 -0
  449. package/libs/shared-utils/Object3DHelper/utils/filterNotColinearPoints.js +1 -0
  450. package/libs/shared-utils/Object3DHelper/utils/getPoint.js +1 -0
  451. package/libs/shared-utils/Object3DHelper/utils/index.js +1 -0
  452. package/libs/shared-utils/Object3DHelper/utils/normalPositionToPositions.js +1 -0
  453. package/libs/shared-utils/Object3DHelper/utils/object3DBoundingPosition.js +1 -0
  454. package/libs/shared-utils/Object3DHelper/utils/threex/domevents/index.js +1 -1
  455. package/libs/shared-utils/animationFrame/index.js +13 -16
  456. package/libs/shared-utils/animationFrame/tween.js +0 -2
  457. package/libs/shared-utils/changeModelCanvasOpacity.js +1 -1
  458. package/libs/shared-utils/createCanvasTextTexture.js +6 -6
  459. package/libs/shared-utils/createLine/index.js +3 -3
  460. package/libs/shared-utils/debounce.js +5 -5
  461. package/libs/shared-utils/equal.js +16 -16
  462. package/libs/shared-utils/filter.js +1 -1
  463. package/libs/shared-utils/five/changeMode.js +14 -14
  464. package/libs/shared-utils/getPxmm.js +7 -8
  465. package/libs/shared-utils/index.js +33 -29
  466. package/libs/shared-utils/isTruelyObject.js +1 -1
  467. package/libs/shared-utils/math/index.js +1 -0
  468. package/libs/shared-utils/math/planimetry.js +1 -6
  469. package/libs/shared-utils/math/rad2Deg.js +3 -3
  470. package/libs/shared-utils/nearlyEqual.js +3 -3
  471. package/libs/shared-utils/noop.js +1 -1
  472. package/libs/shared-utils/object3d2LocalMatrix.js +6 -7
  473. package/libs/shared-utils/removeArrayItem.js +5 -5
  474. package/libs/shared-utils/tap.js +3 -3
  475. package/libs/shared-utils/three/index.js +6 -0
  476. package/libs/shared-utils/three/transformPositionToVector3.js +2 -2
  477. package/libs/shared-utils/three/transfromToMeshBasicMaterial.js +12 -12
  478. package/libs/shared-utils/throttle.js +2 -2
  479. package/libs/shared-utils/tinyEJSrender.js +7 -7
  480. package/libs/shared-utils/to.js +14 -15
  481. package/libs/shared-utils/uuid.js +0 -1
  482. package/libs/{node_modules/.pnpm/swiper@8.4.4/node_modules → vendor}/swiper/components-shared/get-changed-params.js +0 -0
  483. package/libs/{node_modules/.pnpm/swiper@8.4.4/node_modules → vendor}/swiper/components-shared/get-params.js +0 -0
  484. package/libs/{node_modules/.pnpm/swiper@8.4.4/node_modules → vendor}/swiper/components-shared/mount-swiper.js +0 -0
  485. package/libs/{node_modules/.pnpm/swiper@8.4.4/node_modules → vendor}/swiper/components-shared/params-list.js +0 -0
  486. package/libs/{node_modules/.pnpm/swiper@8.4.4/node_modules → vendor}/swiper/components-shared/update-swiper.js +0 -0
  487. package/libs/{node_modules/.pnpm/swiper@8.4.4/node_modules → vendor}/swiper/components-shared/utils.js +0 -0
  488. package/libs/{node_modules/.pnpm/swiper@8.4.4/node_modules → vendor}/swiper/svelte/swiper-slide.js +1 -1
  489. package/libs/vendor/swiper/svelte/swiper-svelte.js +3 -0
  490. package/libs/{node_modules/.pnpm/swiper@8.4.4/node_modules → vendor}/swiper/svelte/swiper.js +1 -1
  491. package/package.json +19 -17
  492. package/dist/index.es.js +0 -16650
  493. package/dist/index.js +0 -16650
  494. package/dist/index.umd.js +0 -556
@@ -0,0 +1,613 @@
1
+ var oe = Object.defineProperty, ae = Object.defineProperties;
2
+ var le = Object.getOwnPropertyDescriptors;
3
+ var V = Object.getOwnPropertySymbols;
4
+ var se = Object.prototype.hasOwnProperty, fe = Object.prototype.propertyIsEnumerable;
5
+ var N = (r, i, e) => i in r ? oe(r, i, { enumerable: !0, configurable: !0, writable: !0, value: e }) : r[i] = e, x = (r, i) => {
6
+ for (var e in i || (i = {}))
7
+ se.call(i, e) && N(r, e, i[e]);
8
+ if (V)
9
+ for (var e of V(i))
10
+ fe.call(i, e) && N(r, e, i[e]);
11
+ return r;
12
+ }, X = (r, i) => ae(r, le(i));
13
+ var b = (r, i, e) => (N(r, typeof i != "symbol" ? i + "" : i, e), e);
14
+ var q = (r, i, e) => new Promise((t, n) => {
15
+ var o = (c) => {
16
+ try {
17
+ f(e.next(c));
18
+ } catch (s) {
19
+ n(s);
20
+ }
21
+ }, a = (c) => {
22
+ try {
23
+ f(e.throw(c));
24
+ } catch (s) {
25
+ n(s);
26
+ }
27
+ }, f = (c) => c.done ? t(c.value) : Promise.resolve(c.value).then(o, a);
28
+ f((e = e.apply(r, i)).next());
29
+ });
30
+ import { SvelteComponent as R, init as T, safe_not_equal as B, append_styles as G, element as k, attr as D, set_style as p, insert as w, append as S, noop as M, detach as I, update_keyed_each as ue, destroy_block as ce, space as P, assign as H, create_component as E, empty as ne, mount_component as C, get_spread_update as W, transition_in as _, group_outros as L, transition_out as v, check_outros as K, destroy_component as z, add_render_callback as he, add_resize_listener as de } from "svelte/internal";
31
+ import { onMount as re } from "svelte";
32
+ import { CAMERA_IMAGE as J, BaseImage as me, RoomHighlight as pe, formatData as Y, formatExtraObjects as ge } from "../../chunks/es/formatData.a2b39ef9.es.js";
33
+ import { throttle as _e } from "../../chunks/es/throttle.db66bac3.es.js";
34
+ import { equal as be } from "../../chunks/es/equal.7db4a6f7.es.js";
35
+ import { Controller as ve } from "../../chunks/es/BasePluginWithData.4bf4e649.es.js";
36
+ import "../../chunks/es/BasePlugin.813e25f7.es.js";
37
+ import "../../chunks/es/Subscribe.c73e0f91.es.js";
38
+ function we(r) {
39
+ G(r, "svelte-1nqrlxd", ".plugin-radar__camera-wrapper.svelte-1nqrlxd{width:100%;height:100%;position:absolute;pointer-events:none}.plugin-radar__camera-position.svelte-1nqrlxd{position:absolute;left:0;top:0;width:0;height:0;transform:none;pointer-events:none;transition:transform 1s linear}.plugin-radar__camera-rotate.svelte-1nqrlxd{position:absolute;left:-0.9375rem;top:-0.9375rem;width:1.0625rem;height:1.0625rem;transform-origin:0.9375rem 0.9375rem;transform:rotate(45deg);background-repeat:no-repeat;background-size:100%}");
40
+ }
41
+ function Ie(r) {
42
+ let i, e, t;
43
+ return {
44
+ c() {
45
+ i = k("div"), e = k("div"), t = k("div"), D(t, "class", "plugin-radar__camera-rotate svelte-1nqrlxd"), p(t, "background-image", "url(" + (r[0] || J) + ")"), p(t, "transform", r[1], !1), D(e, "class", "plugin-radar__camera-position svelte-1nqrlxd"), p(e, "transform", r[2], !1), D(i, "class", "plugin-radar__camera-wrapper svelte-1nqrlxd");
46
+ },
47
+ m(n, o) {
48
+ w(n, i, o), S(i, e), S(e, t);
49
+ },
50
+ p(n, [o]) {
51
+ o & 1 && p(t, "background-image", "url(" + (n[0] || J) + ")"), o & 2 && p(t, "transform", n[1], !1), o & 4 && p(e, "transform", n[2], !1);
52
+ },
53
+ i: M,
54
+ o: M,
55
+ d(n) {
56
+ n && I(i);
57
+ }
58
+ };
59
+ }
60
+ function ke(r) {
61
+ return `rotate(${Math.floor(r / Math.PI * 180) * -1 + 45}deg)`;
62
+ }
63
+ function De(r, i, e) {
64
+ let t, n, { five: o } = i, { pxmm: a } = i, { floorplanData: f } = i, { cameraImageUrl: c } = i, s = o.getCurrentState().panoIndex, l = o.getCurrentState().longitude;
65
+ function h(m, j) {
66
+ const y = m.bounding, d = m.observers[j];
67
+ if (!d)
68
+ return "";
69
+ const F = (y.max.x - y.min.x) * a, U = (y.max.y - y.min.y) * a, A = Math.floor(d.positionInImage.x * F), O = Math.floor(d.positionInImage.y * U);
70
+ return `translate(${A}px, ${O}px)`;
71
+ }
72
+ function u(m) {
73
+ e(6, s = m);
74
+ }
75
+ const g = _e(
76
+ (m) => {
77
+ e(7, l = m.longitude);
78
+ },
79
+ 1e3 / 60
80
+ );
81
+ return re(() => (o.on("panoWillArrive", u), o.on("cameraDirectionUpdate", g), function() {
82
+ o.off("panoWillArrive", u), o.off("cameraDirectionUpdate", g);
83
+ })), r.$$set = (m) => {
84
+ "five" in m && e(3, o = m.five), "pxmm" in m && e(4, a = m.pxmm), "floorplanData" in m && e(5, f = m.floorplanData), "cameraImageUrl" in m && e(0, c = m.cameraImageUrl);
85
+ }, r.$$.update = () => {
86
+ r.$$.dirty & 96 && e(2, t = h(f, s)), r.$$.dirty & 128 && e(1, n = ke(l));
87
+ }, [
88
+ c,
89
+ n,
90
+ t,
91
+ o,
92
+ a,
93
+ f,
94
+ s,
95
+ l
96
+ ];
97
+ }
98
+ class je extends R {
99
+ constructor(i) {
100
+ super(), T(
101
+ this,
102
+ i,
103
+ De,
104
+ Ie,
105
+ B,
106
+ {
107
+ five: 3,
108
+ pxmm: 4,
109
+ floorplanData: 5,
110
+ cameraImageUrl: 0
111
+ },
112
+ we
113
+ );
114
+ }
115
+ }
116
+ function ye(r) {
117
+ G(r, "svelte-1i87fz7", ".plugin-pano-floorplan__extra-objects.svelte-1i87fz7{position:absolute;top:0;left:0;width:100%;height:100%;pointer-events:none}.plugin-pano-floorplan__extra-object-item--position.svelte-1i87fz7{position:absolute;width:0;height:0}.plugin-pano-floorplan__extra-object-item.svelte-1i87fz7{transform:translate(-50%, -50%)}");
118
+ }
119
+ function Z(r, i, e) {
120
+ const t = r.slice();
121
+ return t[1] = i[e], t;
122
+ }
123
+ function $(r, i) {
124
+ let e, t, n = `${i[1].icon.width / 16}rem`, o = `${i[1].icon.height / 16}rem`, a, f = `${i[1].positionInImage.y * 100}%`, c = `${i[1].positionInImage.x * 100}%`;
125
+ return {
126
+ key: r,
127
+ first: null,
128
+ c() {
129
+ e = k("div"), t = k("div"), a = P(), D(t, "class", "plugin-pano-floorplan__extra-object-item svelte-1i87fz7"), p(t, "background-image", `url(${i[1].icon.url})`), p(t, "width", n, !1), p(t, "height", o, !1), D(e, "class", "plugin-pano-floorplan__extra-object-item--position svelte-1i87fz7"), p(e, "top", f, !1), p(e, "left", c, !1), this.first = e;
130
+ },
131
+ m(s, l) {
132
+ w(s, e, l), S(e, t), S(e, a);
133
+ },
134
+ p(s, l) {
135
+ i = s, l & 1 && p(t, "background-image", `url(${i[1].icon.url})`), l & 1 && n !== (n = `${i[1].icon.width / 16}rem`) && p(t, "width", n, !1), l & 1 && o !== (o = `${i[1].icon.height / 16}rem`) && p(t, "height", o, !1), l & 1 && f !== (f = `${i[1].positionInImage.y * 100}%`) && p(e, "top", f, !1), l & 1 && c !== (c = `${i[1].positionInImage.x * 100}%`) && p(e, "left", c, !1);
136
+ },
137
+ d(s) {
138
+ s && I(e);
139
+ }
140
+ };
141
+ }
142
+ function Ae(r) {
143
+ let i, e = [], t = /* @__PURE__ */ new Map(), n = r[0];
144
+ const o = (a) => a[1].id;
145
+ for (let a = 0; a < n.length; a += 1) {
146
+ let f = Z(r, n, a), c = o(f);
147
+ t.set(c, e[a] = $(c, f));
148
+ }
149
+ return {
150
+ c() {
151
+ i = k("div");
152
+ for (let a = 0; a < e.length; a += 1)
153
+ e[a].c();
154
+ D(i, "class", "plugin-pano-floorplan__extra-objects svelte-1i87fz7");
155
+ },
156
+ m(a, f) {
157
+ w(a, i, f);
158
+ for (let c = 0; c < e.length; c += 1)
159
+ e[c].m(i, null);
160
+ },
161
+ p(a, [f]) {
162
+ f & 1 && (n = a[0], e = ue(e, f, o, 1, a, n, t, i, ce, $, null, Z));
163
+ },
164
+ i: M,
165
+ o: M,
166
+ d(a) {
167
+ a && I(i);
168
+ for (let f = 0; f < e.length; f += 1)
169
+ e[f].d();
170
+ }
171
+ };
172
+ }
173
+ function xe(r, i, e) {
174
+ let { extraObjects: t = [] } = i;
175
+ return r.$$set = (n) => {
176
+ "extraObjects" in n && e(0, t = n.extraObjects);
177
+ }, [t];
178
+ }
179
+ class Oe extends R {
180
+ constructor(i) {
181
+ super(), T(this, i, xe, Ae, B, { extraObjects: 0 }, ye);
182
+ }
183
+ }
184
+ function ee(r) {
185
+ let i, e;
186
+ const t = [
187
+ {
188
+ five: r[0],
189
+ pxmm: r[1],
190
+ floorIndex: r[2],
191
+ floorplanData: r[4],
192
+ onRoomHeightClick: r[6]
193
+ }
194
+ ];
195
+ let n = {};
196
+ for (let o = 0; o < t.length; o += 1)
197
+ n = H(n, t[o]);
198
+ return i = new pe({ props: n }), {
199
+ c() {
200
+ E(i.$$.fragment);
201
+ },
202
+ m(o, a) {
203
+ C(i, o, a), e = !0;
204
+ },
205
+ p(o, a) {
206
+ const f = a & 87 ? W(t, [
207
+ {
208
+ five: o[0],
209
+ pxmm: o[1],
210
+ floorIndex: o[2],
211
+ floorplanData: o[4],
212
+ onRoomHeightClick: o[6]
213
+ }
214
+ ]) : {};
215
+ i.$set(f);
216
+ },
217
+ i(o) {
218
+ e || (_(i.$$.fragment, o), e = !0);
219
+ },
220
+ o(o) {
221
+ v(i.$$.fragment, o), e = !1;
222
+ },
223
+ d(o) {
224
+ z(i, o);
225
+ }
226
+ };
227
+ }
228
+ function qe(r) {
229
+ let i, e, t, n, o, a;
230
+ const f = [
231
+ {
232
+ floorIndex: r[2],
233
+ floorplanData: r[4]
234
+ }
235
+ ];
236
+ let c = {};
237
+ for (let l = 0; l < f.length; l += 1)
238
+ c = H(c, f[l]);
239
+ i = new me({ props: c }), t = new Oe({
240
+ props: {
241
+ extraObjects: r[5]
242
+ }
243
+ });
244
+ let s = r[3] && ee(r);
245
+ return {
246
+ c() {
247
+ E(i.$$.fragment), e = P(), E(t.$$.fragment), n = P(), s && s.c(), o = ne();
248
+ },
249
+ m(l, h) {
250
+ C(i, l, h), w(l, e, h), C(t, l, h), w(l, n, h), s && s.m(l, h), w(l, o, h), a = !0;
251
+ },
252
+ p(l, [h]) {
253
+ const u = h & 20 ? W(f, [
254
+ {
255
+ floorIndex: l[2],
256
+ floorplanData: l[4]
257
+ }
258
+ ]) : {};
259
+ i.$set(u);
260
+ const g = {};
261
+ h & 32 && (g.extraObjects = l[5]), t.$set(g), l[3] ? s ? (s.p(l, h), h & 8 && _(s, 1)) : (s = ee(l), s.c(), _(s, 1), s.m(o.parentNode, o)) : s && (L(), v(s, 1, 1, () => {
262
+ s = null;
263
+ }), K());
264
+ },
265
+ i(l) {
266
+ a || (_(i.$$.fragment, l), _(t.$$.fragment, l), _(s), a = !0);
267
+ },
268
+ o(l) {
269
+ v(i.$$.fragment, l), v(t.$$.fragment, l), v(s), a = !1;
270
+ },
271
+ d(l) {
272
+ z(i, l), l && I(e), z(t, l), l && I(n), s && s.d(l), l && I(o);
273
+ }
274
+ };
275
+ }
276
+ function Se(r, i, e) {
277
+ let t, { five: n } = i, { pxmm: o } = i, { floorIndex: a } = i, { hoverEnable: f } = i, { floorplanData: c } = i, { extraObjects: s = [] } = i;
278
+ const l = void 0;
279
+ return r.$$set = (h) => {
280
+ "five" in h && e(0, n = h.five), "pxmm" in h && e(1, o = h.pxmm), "floorIndex" in h && e(2, a = h.floorIndex), "hoverEnable" in h && e(3, f = h.hoverEnable), "floorplanData" in h && e(4, c = h.floorplanData), "extraObjects" in h && e(7, s = h.extraObjects);
281
+ }, r.$$.update = () => {
282
+ r.$$.dirty & 132 && e(5, t = s == null ? void 0 : s.filter((h) => h.floorIndex === a));
283
+ }, [
284
+ n,
285
+ o,
286
+ a,
287
+ f,
288
+ c,
289
+ t,
290
+ l,
291
+ s
292
+ ];
293
+ }
294
+ class Ee extends R {
295
+ constructor(i) {
296
+ super(), T(this, i, Se, qe, B, {
297
+ five: 0,
298
+ pxmm: 1,
299
+ floorIndex: 2,
300
+ hoverEnable: 3,
301
+ floorplanData: 4,
302
+ extraObjects: 7
303
+ });
304
+ }
305
+ }
306
+ function Ce(r) {
307
+ G(r, "svelte-1mvqyqq", ".plugin-floorplan-radar.svelte-1mvqyqq{width:100%;height:100%;display:flex;justify-content:center;align-items:center}.plugin-floorplan-radar-container.svelte-1mvqyqq{position:relative}");
308
+ }
309
+ function te(r) {
310
+ let i, e, t, n = r[6] !== 0 && ie(r);
311
+ return {
312
+ c() {
313
+ i = k("div"), n && n.c(), D(i, "class", "plugin-floorplan-radar svelte-1mvqyqq"), he(() => r[12].call(i));
314
+ },
315
+ m(o, a) {
316
+ w(o, i, a), n && n.m(i, null), e = de(i, r[12].bind(i)), t = !0;
317
+ },
318
+ p(o, a) {
319
+ o[6] !== 0 ? n ? (n.p(o, a), a & 64 && _(n, 1)) : (n = ie(o), n.c(), _(n, 1), n.m(i, null)) : n && (L(), v(n, 1, 1, () => {
320
+ n = null;
321
+ }), K());
322
+ },
323
+ i(o) {
324
+ t || (_(n), t = !0);
325
+ },
326
+ o(o) {
327
+ v(n), t = !1;
328
+ },
329
+ d(o) {
330
+ o && I(i), n && n.d(), e();
331
+ }
332
+ };
333
+ }
334
+ function ie(r) {
335
+ let i, e, t, n, o = `${r[8]}px`, a = `${r[11]}px`, f;
336
+ const c = [
337
+ {
338
+ five: r[0],
339
+ pxmm: r[9],
340
+ floorIndex: r[10],
341
+ floorplanData: r[3],
342
+ hoverEnable: r[2],
343
+ extraObjects: r[5]
344
+ }
345
+ ];
346
+ let s = {};
347
+ for (let u = 0; u < c.length; u += 1)
348
+ s = H(s, c[u]);
349
+ e = new Ee({ props: s });
350
+ const l = [
351
+ {
352
+ pxmm: r[9],
353
+ five: r[0],
354
+ floorplanData: r[3],
355
+ cameraImageUrl: r[4]
356
+ }
357
+ ];
358
+ let h = {};
359
+ for (let u = 0; u < l.length; u += 1)
360
+ h = H(h, l[u]);
361
+ return n = new je({ props: h }), {
362
+ c() {
363
+ i = k("div"), E(e.$$.fragment), t = P(), E(n.$$.fragment), D(i, "class", "plugin-floorplan-radar-container svelte-1mvqyqq"), p(i, "width", o, !1), p(i, "height", a, !1);
364
+ },
365
+ m(u, g) {
366
+ w(u, i, g), C(e, i, null), S(i, t), C(n, i, null), f = !0;
367
+ },
368
+ p(u, g) {
369
+ const m = g & 1581 ? W(c, [
370
+ {
371
+ five: u[0],
372
+ pxmm: u[9],
373
+ floorIndex: u[10],
374
+ floorplanData: u[3],
375
+ hoverEnable: u[2],
376
+ extraObjects: u[5]
377
+ }
378
+ ]) : {};
379
+ e.$set(m);
380
+ const j = g & 537 ? W(l, [
381
+ {
382
+ pxmm: u[9],
383
+ five: u[0],
384
+ floorplanData: u[3],
385
+ cameraImageUrl: u[4]
386
+ }
387
+ ]) : {};
388
+ n.$set(j), g & 256 && o !== (o = `${u[8]}px`) && p(i, "width", o, !1), g & 2048 && a !== (a = `${u[11]}px`) && p(i, "height", a, !1);
389
+ },
390
+ i(u) {
391
+ f || (_(e.$$.fragment, u), _(n.$$.fragment, u), f = !0);
392
+ },
393
+ o(u) {
394
+ v(e.$$.fragment, u), v(n.$$.fragment, u), f = !1;
395
+ },
396
+ d(u) {
397
+ u && I(i), z(e), z(n);
398
+ }
399
+ };
400
+ }
401
+ function ze(r) {
402
+ let i, e, t = r[1] && te(r);
403
+ return {
404
+ c() {
405
+ t && t.c(), i = ne();
406
+ },
407
+ m(n, o) {
408
+ t && t.m(n, o), w(n, i, o), e = !0;
409
+ },
410
+ p(n, [o]) {
411
+ n[1] ? t ? (t.p(n, o), o & 2 && _(t, 1)) : (t = te(n), t.c(), _(t, 1), t.m(i.parentNode, i)) : t && (L(), v(t, 1, 1, () => {
412
+ t = null;
413
+ }), K());
414
+ },
415
+ i(n) {
416
+ e || (_(t), e = !0);
417
+ },
418
+ o(n) {
419
+ v(t), e = !1;
420
+ },
421
+ d(n) {
422
+ t && t.d(n), n && I(i);
423
+ }
424
+ };
425
+ }
426
+ function Fe(r, i, e) {
427
+ let { five: t } = i, { visible: n } = i, { hoverEnable: o } = i, { floorplanData: a } = i, { cameraImageUrl: f } = i, { extraObjects: c = [] } = i, s = 0, l = 0, h = 0, u = 0, g = 0, m = 0;
428
+ function j(d) {
429
+ e(10, l = t.work.observers[d].floorIndex);
430
+ }
431
+ re(() => (t.on("panoArrived", j), () => {
432
+ t.off("panoArrived", j);
433
+ }));
434
+ function y() {
435
+ h = this.clientWidth, u = this.clientHeight, e(6, h), e(7, u);
436
+ }
437
+ return r.$$set = (d) => {
438
+ "five" in d && e(0, t = d.five), "visible" in d && e(1, n = d.visible), "hoverEnable" in d && e(2, o = d.hoverEnable), "floorplanData" in d && e(3, a = d.floorplanData), "cameraImageUrl" in d && e(4, f = d.cameraImageUrl), "extraObjects" in d && e(5, c = d.extraObjects);
439
+ }, r.$$.update = () => {
440
+ if (r.$$.dirty & 456) {
441
+ const d = Math.min(h, u), { max: F, min: U } = a.bounding, A = F.x - U.x, O = F.y - U.y, Q = function() {
442
+ return A > O ? [d, d / A * O] : [d / O * A, d];
443
+ }();
444
+ e(8, g = Q[0]), e(11, m = Q[1]), e(9, s = g / A);
445
+ }
446
+ }, [
447
+ t,
448
+ n,
449
+ o,
450
+ a,
451
+ f,
452
+ c,
453
+ h,
454
+ u,
455
+ g,
456
+ s,
457
+ l,
458
+ m,
459
+ y
460
+ ];
461
+ }
462
+ class Ue extends R {
463
+ constructor(i) {
464
+ super(), T(
465
+ this,
466
+ i,
467
+ Fe,
468
+ ze,
469
+ B,
470
+ {
471
+ five: 0,
472
+ visible: 1,
473
+ hoverEnable: 2,
474
+ floorplanData: 3,
475
+ cameraImageUrl: 4,
476
+ extraObjects: 5
477
+ },
478
+ Ce
479
+ );
480
+ }
481
+ }
482
+ class Me extends ve {
483
+ constructor(e, t) {
484
+ super(e);
485
+ b(this, "name", "panoFloorplanRadarPlugin");
486
+ b(this, "state");
487
+ b(this, "data");
488
+ b(this, "app");
489
+ b(this, "wrapperSelector", "");
490
+ b(this, "wrapper", null);
491
+ b(this, "disposed", !1);
492
+ b(this, "extraObjects", []);
493
+ b(this, "dispose", () => {
494
+ var e;
495
+ this.disposed = !0, (e = this.app) == null || e.$destroy(), this.wrapper = null, this.wrapperSelector = "", this.hooks.emit("dispose");
496
+ });
497
+ b(this, "_disable", (e) => {
498
+ var n;
499
+ const { userAction: t } = e;
500
+ (n = this.app) == null || n.$destroy(), this.app = void 0, this.hooks.emit("disable", { userAction: t });
501
+ });
502
+ this.five = e;
503
+ const n = {
504
+ hoverEnable: !1,
505
+ cameraImageUrl: J
506
+ }, o = t != null && t.configs ? t.configs : {}, a = x(x({}, n), o);
507
+ this.state = { enabled: !0, visible: !0, config: a }, t != null && t.wrapper && console.warn("\u4E0D\u63A8\u8350\u7EE7\u7EED\u4F7F\u7528 params.selector \u914D\u7F6E\u7236\u5BB9\u5668\uFF0C\u8BF7\u4F7F\u7528 appendTo \u65B9\u6CD5"), typeof (t == null ? void 0 : t.wrapper) == "string" ? this.wrapperSelector = t.wrapper : (t == null ? void 0 : t.wrapper) instanceof Element && (this.wrapper = t.wrapper), e.once("dispose", this.dispose);
508
+ }
509
+ load(e, t, n = !0) {
510
+ return q(this, null, function* () {
511
+ function o(s) {
512
+ return Object.prototype.hasOwnProperty.apply(s, ["version"]);
513
+ }
514
+ const a = JSON.parse(JSON.stringify(e)), f = o(a) ? a.data : a, c = this.data;
515
+ this.data = yield Y(f), this.hooks.emit("dataLoaded", this.data), this.hooks.emit("dataChange", this.data, c), t && this.updateState(t, n), this.render();
516
+ });
517
+ }
518
+ show() {
519
+ return q(this, arguments, function* (e = {}) {
520
+ if (this.state.visible)
521
+ return;
522
+ const t = e.userAction !== void 0 ? e.userAction : !0;
523
+ this.updateState({ visible: !0 }, t), this._show({ userAction: t });
524
+ });
525
+ }
526
+ hide() {
527
+ return q(this, arguments, function* (e = {}) {
528
+ if (!this.state.visible)
529
+ return;
530
+ const t = e.userAction !== void 0 ? e.userAction : !0;
531
+ this.updateState({ visible: !1 }, t), this._hide({ userAction: t });
532
+ });
533
+ }
534
+ enable(e = {}) {
535
+ if (this.state.enabled)
536
+ return;
537
+ const t = e.userAction !== void 0 ? e.userAction : !0;
538
+ this.updateState({ enabled: !0 }, e.userAction || t), this._enable({ userAction: t });
539
+ }
540
+ disable(e = {}) {
541
+ if (!this.state.enabled)
542
+ return;
543
+ const t = e.userAction !== void 0 ? e.userAction : !0;
544
+ this.updateState({ enabled: !1 }, e.userAction || t), this._disable({ userAction: t });
545
+ }
546
+ setState(e, t = {}) {
547
+ const n = this.state, o = t.userAction !== void 0 ? t.userAction : !0;
548
+ if (this.updateState(e, o), e.enabled !== void 0 && n.enabled !== e.enabled) {
549
+ const a = { userAction: o };
550
+ e.enabled ? this._enable(a) : this._disable(a);
551
+ }
552
+ if (e.visible !== void 0 && n.visible !== e.visible) {
553
+ const a = { userAction: o };
554
+ e.visible ? this._show(a) : this._hide(a);
555
+ }
556
+ }
557
+ appendTo(e) {
558
+ this.wrapper = e, this.render();
559
+ }
560
+ changeConfigs(e, t = !0) {
561
+ this.setState({ config: e }, { userAction: t }), this.render();
562
+ }
563
+ setExtraObjectsWith3DPositions(e) {
564
+ !this.data || (this.extraObjects = ge(e, this.five, this.data), this.render());
565
+ }
566
+ formatData(e) {
567
+ return q(this, null, function* () {
568
+ return yield Y(e.data);
569
+ });
570
+ }
571
+ _enable(e) {
572
+ const { userAction: t } = e;
573
+ this.hooks.emit("enable", { userAction: t }), this.state.visible && this._show({ userAction: t });
574
+ }
575
+ _show(e) {
576
+ if (this.disposed || !this.state.enabled)
577
+ return;
578
+ const { userAction: t } = e;
579
+ this.hooks.emit("show", { userAction: t }), this.render();
580
+ }
581
+ _hide(e) {
582
+ if (this.disposed || !this.state.enabled)
583
+ return;
584
+ const { userAction: t } = e;
585
+ this.hooks.emit("hide", { userAction: t }), this.render();
586
+ }
587
+ updateState(e, t) {
588
+ const n = this.state;
589
+ this.state = x(x({}, this.state), e), !be(this.state, n, { deep: !0 }) && this.hooks.emit("stateChange", { state: this.state, prevState: n, userAction: t });
590
+ }
591
+ render() {
592
+ if (this.disposed || !this.state.enabled)
593
+ return;
594
+ if (!this.wrapper && this.wrapperSelector) {
595
+ const t = document.querySelector(this.wrapperSelector);
596
+ this.wrapper = t;
597
+ }
598
+ if (!this.data || !this.wrapper)
599
+ return;
600
+ const e = X(x({}, this.state.config), {
601
+ five: this.five,
602
+ floorplanData: this.data,
603
+ visible: this.state.visible,
604
+ extraObjects: this.extraObjects
605
+ });
606
+ this.app ? this.app.$set(e) : this.app = new Ue({ target: this.wrapper, props: e });
607
+ }
608
+ }
609
+ const Ke = (r, i) => new Me(r, i);
610
+ export {
611
+ Ke as PanoFloorplanRadarPlugin,
612
+ Ke as default
613
+ };
@@ -0,0 +1 @@
1
+ "use strict";var R=Object.defineProperty,W=Object.defineProperties;var H=Object.getOwnPropertyDescriptors;var x=Object.getOwnPropertySymbols;var B=Object.prototype.hasOwnProperty,T=Object.prototype.propertyIsEnumerable;var A=(o,i,e)=>i in o?R(o,i,{enumerable:!0,configurable:!0,writable:!0,value:e}):o[i]=e,j=(o,i)=>{for(var e in i||(i={}))B.call(i,e)&&A(o,e,i[e]);if(x)for(var e of x(i))T.call(i,e)&&A(o,e,i[e]);return o},E=(o,i)=>W(o,H(i));var g=(o,i,e)=>(A(o,typeof i!="symbol"?i+"":i,e),e);var I=(o,i,e)=>new Promise((n,r)=>{var s=h=>{try{c(e.next(h))}catch(f){r(f)}},a=h=>{try{c(e.throw(h))}catch(f){r(f)}},c=h=>h.done?n(h.value):Promise.resolve(h.value).then(s,a);c((e=e.apply(o,i)).next())});Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("svelte/internal"),z=require("svelte"),b=require("../../chunks/cjs/formatData.81e95011.cjs.js"),N=require("../../chunks/cjs/throttle.86c209eb.cjs.js"),G=require("../../chunks/cjs/equal.e9fcbd4e.cjs.js"),J=require("../../chunks/cjs/BasePluginWithData.0a28882d.cjs.js");require("../../chunks/cjs/BasePlugin.57e5204f.cjs.js");require("../../chunks/cjs/Subscribe.5398d5c6.cjs.js");function L(o){t.append_styles(o,"svelte-1nqrlxd",".plugin-radar__camera-wrapper.svelte-1nqrlxd{width:100%;height:100%;position:absolute;pointer-events:none}.plugin-radar__camera-position.svelte-1nqrlxd{position:absolute;left:0;top:0;width:0;height:0;transform:none;pointer-events:none;transition:transform 1s linear}.plugin-radar__camera-rotate.svelte-1nqrlxd{position:absolute;left:-0.9375rem;top:-0.9375rem;width:1.0625rem;height:1.0625rem;transform-origin:0.9375rem 0.9375rem;transform:rotate(45deg);background-repeat:no-repeat;background-size:100%}")}function K(o){let i,e,n;return{c(){i=t.element("div"),e=t.element("div"),n=t.element("div"),t.attr(n,"class","plugin-radar__camera-rotate svelte-1nqrlxd"),t.set_style(n,"background-image","url("+(o[0]||b.CAMERA_IMAGE)+")"),t.set_style(n,"transform",o[1],!1),t.attr(e,"class","plugin-radar__camera-position svelte-1nqrlxd"),t.set_style(e,"transform",o[2],!1),t.attr(i,"class","plugin-radar__camera-wrapper svelte-1nqrlxd")},m(r,s){t.insert(r,i,s),t.append(i,e),t.append(e,n)},p(r,[s]){s&1&&t.set_style(n,"background-image","url("+(r[0]||b.CAMERA_IMAGE)+")"),s&2&&t.set_style(n,"transform",r[1],!1),s&4&&t.set_style(e,"transform",r[2],!1)},i:t.noop,o:t.noop,d(r){r&&t.detach(i)}}}function Q(o){return`rotate(${Math.floor(o/Math.PI*180)*-1+45}deg)`}function V(o,i,e){let n,r,{five:s}=i,{pxmm:a}=i,{floorplanData:c}=i,{cameraImageUrl:h}=i,f=s.getCurrentState().panoIndex,l=s.getCurrentState().longitude;function d(_,v){const y=_.bounding,p=_.observers[v];if(!p)return"";const D=(y.max.x-y.min.x)*a,q=(y.max.y-y.min.y)*a,w=Math.floor(p.positionInImage.x*D),k=Math.floor(p.positionInImage.y*q);return`translate(${w}px, ${k}px)`}function u(_){e(6,f=_)}const m=N.throttle(_=>{e(7,l=_.longitude)},1e3/60);return z.onMount(()=>(s.on("panoWillArrive",u),s.on("cameraDirectionUpdate",m),function(){s.off("panoWillArrive",u),s.off("cameraDirectionUpdate",m)})),o.$$set=_=>{"five"in _&&e(3,s=_.five),"pxmm"in _&&e(4,a=_.pxmm),"floorplanData"in _&&e(5,c=_.floorplanData),"cameraImageUrl"in _&&e(0,h=_.cameraImageUrl)},o.$$.update=()=>{o.$$.dirty&96&&e(2,n=d(c,f)),o.$$.dirty&128&&e(1,r=Q(l))},[h,r,n,s,a,c,f,l]}class X extends t.SvelteComponent{constructor(i){super(),t.init(this,i,V,K,t.safe_not_equal,{five:3,pxmm:4,floorplanData:5,cameraImageUrl:0},L)}}function Y(o){t.append_styles(o,"svelte-1i87fz7",".plugin-pano-floorplan__extra-objects.svelte-1i87fz7{position:absolute;top:0;left:0;width:100%;height:100%;pointer-events:none}.plugin-pano-floorplan__extra-object-item--position.svelte-1i87fz7{position:absolute;width:0;height:0}.plugin-pano-floorplan__extra-object-item.svelte-1i87fz7{transform:translate(-50%, -50%)}")}function O(o,i,e){const n=o.slice();return n[1]=i[e],n}function C(o,i){let e,n,r=`${i[1].icon.width/16}rem`,s=`${i[1].icon.height/16}rem`,a,c=`${i[1].positionInImage.y*100}%`,h=`${i[1].positionInImage.x*100}%`;return{key:o,first:null,c(){e=t.element("div"),n=t.element("div"),a=t.space(),t.attr(n,"class","plugin-pano-floorplan__extra-object-item svelte-1i87fz7"),t.set_style(n,"background-image",`url(${i[1].icon.url})`),t.set_style(n,"width",r,!1),t.set_style(n,"height",s,!1),t.attr(e,"class","plugin-pano-floorplan__extra-object-item--position svelte-1i87fz7"),t.set_style(e,"top",c,!1),t.set_style(e,"left",h,!1),this.first=e},m(f,l){t.insert(f,e,l),t.append(e,n),t.append(e,a)},p(f,l){i=f,l&1&&t.set_style(n,"background-image",`url(${i[1].icon.url})`),l&1&&r!==(r=`${i[1].icon.width/16}rem`)&&t.set_style(n,"width",r,!1),l&1&&s!==(s=`${i[1].icon.height/16}rem`)&&t.set_style(n,"height",s,!1),l&1&&c!==(c=`${i[1].positionInImage.y*100}%`)&&t.set_style(e,"top",c,!1),l&1&&h!==(h=`${i[1].positionInImage.x*100}%`)&&t.set_style(e,"left",h,!1)},d(f){f&&t.detach(e)}}}function Z(o){let i,e=[],n=new Map,r=o[0];const s=a=>a[1].id;for(let a=0;a<r.length;a+=1){let c=O(o,r,a),h=s(c);n.set(h,e[a]=C(h,c))}return{c(){i=t.element("div");for(let a=0;a<e.length;a+=1)e[a].c();t.attr(i,"class","plugin-pano-floorplan__extra-objects svelte-1i87fz7")},m(a,c){t.insert(a,i,c);for(let h=0;h<e.length;h+=1)e[h].m(i,null)},p(a,[c]){c&1&&(r=a[0],e=t.update_keyed_each(e,c,s,1,a,r,n,i,t.destroy_block,C,null,O))},i:t.noop,o:t.noop,d(a){a&&t.detach(i);for(let c=0;c<e.length;c+=1)e[c].d()}}}function $(o,i,e){let{extraObjects:n=[]}=i;return o.$$set=r=>{"extraObjects"in r&&e(0,n=r.extraObjects)},[n]}class ee extends t.SvelteComponent{constructor(i){super(),t.init(this,i,$,Z,t.safe_not_equal,{extraObjects:0},Y)}}function M(o){let i,e;const n=[{five:o[0],pxmm:o[1],floorIndex:o[2],floorplanData:o[4],onRoomHeightClick:o[6]}];let r={};for(let s=0;s<n.length;s+=1)r=t.assign(r,n[s]);return i=new b.RoomHighlight({props:r}),{c(){t.create_component(i.$$.fragment)},m(s,a){t.mount_component(i,s,a),e=!0},p(s,a){const c=a&87?t.get_spread_update(n,[{five:s[0],pxmm:s[1],floorIndex:s[2],floorplanData:s[4],onRoomHeightClick:s[6]}]):{};i.$set(c)},i(s){e||(t.transition_in(i.$$.fragment,s),e=!0)},o(s){t.transition_out(i.$$.fragment,s),e=!1},d(s){t.destroy_component(i,s)}}}function te(o){let i,e,n,r,s,a;const c=[{floorIndex:o[2],floorplanData:o[4]}];let h={};for(let l=0;l<c.length;l+=1)h=t.assign(h,c[l]);i=new b.BaseImage({props:h}),n=new ee({props:{extraObjects:o[5]}});let f=o[3]&&M(o);return{c(){t.create_component(i.$$.fragment),e=t.space(),t.create_component(n.$$.fragment),r=t.space(),f&&f.c(),s=t.empty()},m(l,d){t.mount_component(i,l,d),t.insert(l,e,d),t.mount_component(n,l,d),t.insert(l,r,d),f&&f.m(l,d),t.insert(l,s,d),a=!0},p(l,[d]){const u=d&20?t.get_spread_update(c,[{floorIndex:l[2],floorplanData:l[4]}]):{};i.$set(u);const m={};d&32&&(m.extraObjects=l[5]),n.$set(m),l[3]?f?(f.p(l,d),d&8&&t.transition_in(f,1)):(f=M(l),f.c(),t.transition_in(f,1),f.m(s.parentNode,s)):f&&(t.group_outros(),t.transition_out(f,1,1,()=>{f=null}),t.check_outros())},i(l){a||(t.transition_in(i.$$.fragment,l),t.transition_in(n.$$.fragment,l),t.transition_in(f),a=!0)},o(l){t.transition_out(i.$$.fragment,l),t.transition_out(n.$$.fragment,l),t.transition_out(f),a=!1},d(l){t.destroy_component(i,l),l&&t.detach(e),t.destroy_component(n,l),l&&t.detach(r),f&&f.d(l),l&&t.detach(s)}}}function ne(o,i,e){let n,{five:r}=i,{pxmm:s}=i,{floorIndex:a}=i,{hoverEnable:c}=i,{floorplanData:h}=i,{extraObjects:f=[]}=i;const l=void 0;return o.$$set=d=>{"five"in d&&e(0,r=d.five),"pxmm"in d&&e(1,s=d.pxmm),"floorIndex"in d&&e(2,a=d.floorIndex),"hoverEnable"in d&&e(3,c=d.hoverEnable),"floorplanData"in d&&e(4,h=d.floorplanData),"extraObjects"in d&&e(7,f=d.extraObjects)},o.$$.update=()=>{o.$$.dirty&132&&e(5,n=f==null?void 0:f.filter(d=>d.floorIndex===a))},[r,s,a,c,h,n,l,f]}class ie extends t.SvelteComponent{constructor(i){super(),t.init(this,i,ne,te,t.safe_not_equal,{five:0,pxmm:1,floorIndex:2,hoverEnable:3,floorplanData:4,extraObjects:7})}}function re(o){t.append_styles(o,"svelte-1mvqyqq",".plugin-floorplan-radar.svelte-1mvqyqq{width:100%;height:100%;display:flex;justify-content:center;align-items:center}.plugin-floorplan-radar-container.svelte-1mvqyqq{position:relative}")}function P(o){let i,e,n,r=o[6]!==0&&F(o);return{c(){i=t.element("div"),r&&r.c(),t.attr(i,"class","plugin-floorplan-radar svelte-1mvqyqq"),t.add_render_callback(()=>o[12].call(i))},m(s,a){t.insert(s,i,a),r&&r.m(i,null),e=t.add_resize_listener(i,o[12].bind(i)),n=!0},p(s,a){s[6]!==0?r?(r.p(s,a),a&64&&t.transition_in(r,1)):(r=F(s),r.c(),t.transition_in(r,1),r.m(i,null)):r&&(t.group_outros(),t.transition_out(r,1,1,()=>{r=null}),t.check_outros())},i(s){n||(t.transition_in(r),n=!0)},o(s){t.transition_out(r),n=!1},d(s){s&&t.detach(i),r&&r.d(),e()}}}function F(o){let i,e,n,r,s=`${o[8]}px`,a=`${o[11]}px`,c;const h=[{five:o[0],pxmm:o[9],floorIndex:o[10],floorplanData:o[3],hoverEnable:o[2],extraObjects:o[5]}];let f={};for(let u=0;u<h.length;u+=1)f=t.assign(f,h[u]);e=new ie({props:f});const l=[{pxmm:o[9],five:o[0],floorplanData:o[3],cameraImageUrl:o[4]}];let d={};for(let u=0;u<l.length;u+=1)d=t.assign(d,l[u]);return r=new X({props:d}),{c(){i=t.element("div"),t.create_component(e.$$.fragment),n=t.space(),t.create_component(r.$$.fragment),t.attr(i,"class","plugin-floorplan-radar-container svelte-1mvqyqq"),t.set_style(i,"width",s,!1),t.set_style(i,"height",a,!1)},m(u,m){t.insert(u,i,m),t.mount_component(e,i,null),t.append(i,n),t.mount_component(r,i,null),c=!0},p(u,m){const _=m&1581?t.get_spread_update(h,[{five:u[0],pxmm:u[9],floorIndex:u[10],floorplanData:u[3],hoverEnable:u[2],extraObjects:u[5]}]):{};e.$set(_);const v=m&537?t.get_spread_update(l,[{pxmm:u[9],five:u[0],floorplanData:u[3],cameraImageUrl:u[4]}]):{};r.$set(v),m&256&&s!==(s=`${u[8]}px`)&&t.set_style(i,"width",s,!1),m&2048&&a!==(a=`${u[11]}px`)&&t.set_style(i,"height",a,!1)},i(u){c||(t.transition_in(e.$$.fragment,u),t.transition_in(r.$$.fragment,u),c=!0)},o(u){t.transition_out(e.$$.fragment,u),t.transition_out(r.$$.fragment,u),c=!1},d(u){u&&t.detach(i),t.destroy_component(e),t.destroy_component(r)}}}function oe(o){let i,e,n=o[1]&&P(o);return{c(){n&&n.c(),i=t.empty()},m(r,s){n&&n.m(r,s),t.insert(r,i,s),e=!0},p(r,[s]){r[1]?n?(n.p(r,s),s&2&&t.transition_in(n,1)):(n=P(r),n.c(),t.transition_in(n,1),n.m(i.parentNode,i)):n&&(t.group_outros(),t.transition_out(n,1,1,()=>{n=null}),t.check_outros())},i(r){e||(t.transition_in(n),e=!0)},o(r){t.transition_out(n),e=!1},d(r){n&&n.d(r),r&&t.detach(i)}}}function se(o,i,e){let{five:n}=i,{visible:r}=i,{hoverEnable:s}=i,{floorplanData:a}=i,{cameraImageUrl:c}=i,{extraObjects:h=[]}=i,f=0,l=0,d=0,u=0,m=0,_=0;function v(p){e(10,l=n.work.observers[p].floorIndex)}z.onMount(()=>(n.on("panoArrived",v),()=>{n.off("panoArrived",v)}));function y(){d=this.clientWidth,u=this.clientHeight,e(6,d),e(7,u)}return o.$$set=p=>{"five"in p&&e(0,n=p.five),"visible"in p&&e(1,r=p.visible),"hoverEnable"in p&&e(2,s=p.hoverEnable),"floorplanData"in p&&e(3,a=p.floorplanData),"cameraImageUrl"in p&&e(4,c=p.cameraImageUrl),"extraObjects"in p&&e(5,h=p.extraObjects)},o.$$.update=()=>{if(o.$$.dirty&456){const p=Math.min(d,u),{max:D,min:q}=a.bounding,w=D.x-q.x,k=D.y-q.y,S=function(){return w>k?[p,p/w*k]:[p/k*w,p]}();e(8,m=S[0]),e(11,_=S[1]),e(9,f=m/w)}},[n,r,s,a,c,h,d,u,m,f,l,_,y]}class ae extends t.SvelteComponent{constructor(i){super(),t.init(this,i,se,oe,t.safe_not_equal,{five:0,visible:1,hoverEnable:2,floorplanData:3,cameraImageUrl:4,extraObjects:5},re)}}class le extends J.Controller{constructor(e,n){super(e);g(this,"name","panoFloorplanRadarPlugin");g(this,"state");g(this,"data");g(this,"app");g(this,"wrapperSelector","");g(this,"wrapper",null);g(this,"disposed",!1);g(this,"extraObjects",[]);g(this,"dispose",()=>{var e;this.disposed=!0,(e=this.app)==null||e.$destroy(),this.wrapper=null,this.wrapperSelector="",this.hooks.emit("dispose")});g(this,"_disable",e=>{var r;const{userAction:n}=e;(r=this.app)==null||r.$destroy(),this.app=void 0,this.hooks.emit("disable",{userAction:n})});this.five=e;const r={hoverEnable:!1,cameraImageUrl:b.CAMERA_IMAGE},s=n!=null&&n.configs?n.configs:{},a=j(j({},r),s);this.state={enabled:!0,visible:!0,config:a},n!=null&&n.wrapper&&console.warn("\u4E0D\u63A8\u8350\u7EE7\u7EED\u4F7F\u7528 params.selector \u914D\u7F6E\u7236\u5BB9\u5668\uFF0C\u8BF7\u4F7F\u7528 appendTo \u65B9\u6CD5"),typeof(n==null?void 0:n.wrapper)=="string"?this.wrapperSelector=n.wrapper:(n==null?void 0:n.wrapper)instanceof Element&&(this.wrapper=n.wrapper),e.once("dispose",this.dispose)}load(e,n,r=!0){return I(this,null,function*(){function s(f){return Object.prototype.hasOwnProperty.apply(f,["version"])}const a=JSON.parse(JSON.stringify(e)),c=s(a)?a.data:a,h=this.data;this.data=yield b.formatData(c),this.hooks.emit("dataLoaded",this.data),this.hooks.emit("dataChange",this.data,h),n&&this.updateState(n,r),this.render()})}show(){return I(this,arguments,function*(e={}){if(this.state.visible)return;const n=e.userAction!==void 0?e.userAction:!0;this.updateState({visible:!0},n),this._show({userAction:n})})}hide(){return I(this,arguments,function*(e={}){if(!this.state.visible)return;const n=e.userAction!==void 0?e.userAction:!0;this.updateState({visible:!1},n),this._hide({userAction:n})})}enable(e={}){if(this.state.enabled)return;const n=e.userAction!==void 0?e.userAction:!0;this.updateState({enabled:!0},e.userAction||n),this._enable({userAction:n})}disable(e={}){if(!this.state.enabled)return;const n=e.userAction!==void 0?e.userAction:!0;this.updateState({enabled:!1},e.userAction||n),this._disable({userAction:n})}setState(e,n={}){const r=this.state,s=n.userAction!==void 0?n.userAction:!0;if(this.updateState(e,s),e.enabled!==void 0&&r.enabled!==e.enabled){const a={userAction:s};e.enabled?this._enable(a):this._disable(a)}if(e.visible!==void 0&&r.visible!==e.visible){const a={userAction:s};e.visible?this._show(a):this._hide(a)}}appendTo(e){this.wrapper=e,this.render()}changeConfigs(e,n=!0){this.setState({config:e},{userAction:n}),this.render()}setExtraObjectsWith3DPositions(e){!this.data||(this.extraObjects=b.formatExtraObjects(e,this.five,this.data),this.render())}formatData(e){return I(this,null,function*(){return yield b.formatData(e.data)})}_enable(e){const{userAction:n}=e;this.hooks.emit("enable",{userAction:n}),this.state.visible&&this._show({userAction:n})}_show(e){if(this.disposed||!this.state.enabled)return;const{userAction:n}=e;this.hooks.emit("show",{userAction:n}),this.render()}_hide(e){if(this.disposed||!this.state.enabled)return;const{userAction:n}=e;this.hooks.emit("hide",{userAction:n}),this.render()}updateState(e,n){const r=this.state;this.state=j(j({},this.state),e),!G.equal(this.state,r,{deep:!0})&&this.hooks.emit("stateChange",{state:this.state,prevState:r,userAction:n})}render(){if(this.disposed||!this.state.enabled)return;if(!this.wrapper&&this.wrapperSelector){const n=document.querySelector(this.wrapperSelector);this.wrapper=n}if(!this.data||!this.wrapper)return;const e=E(j({},this.state.config),{five:this.five,floorplanData:this.data,visible:this.state.visible,extraObjects:this.extraObjects});this.app?this.app.$set(e):this.app=new ae({target:this.wrapper,props:e})}}const U=(o,i)=>new le(o,i);exports.PanoFloorplanRadarPlugin=U;exports.default=U;