@realsee/dnalogel 2.1.2-alpha.10 → 2.1.2-alpha.12
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.
- package/dist/CSS3DRenderPlugin/CSS3DRender.d.ts +167 -0
- package/dist/CSS3DRenderPlugin/Controller.d.ts +81 -0
- package/dist/CSS3DRenderPlugin/index.d.ts +5 -0
- package/dist/CSS3DRenderPlugin/typing.d.ts +26 -0
- package/dist/CSS3DRenderPlugin/utils/CSS3DObjectPlus.d.ts +34 -0
- package/dist/CSS3DRenderPlugin/utils/centerPoint.d.ts +2 -0
- package/dist/CSS3DRenderPlugin/utils/evenNumber.d.ts +3 -0
- package/dist/CSS3DRenderPlugin/utils/index.d.ts +4 -0
- package/dist/CSS3DRenderPlugin/utils/positionToVector3.d.ts +13 -0
- package/dist/CSS3DRenderPlugin/utils/random.d.ts +1 -0
- package/dist/CameraMovementPlugin/CameraMovementPlugin.d.ts +7 -0
- package/dist/CameraMovementPlugin/index.d.ts +5 -0
- package/dist/CameraMovementPlugin/typing.d.ts +68 -0
- package/dist/CruisePlugin/Controller.d.ts +172 -0
- package/dist/CruisePlugin/index.d.ts +6 -0
- package/dist/CruisePlugin/typing.d.ts +134 -0
- package/dist/CruisePlugin/utils/coordinatesAngle.d.ts +12 -0
- package/dist/CruisePlugin/utils/coordinatesToVector.d.ts +7 -0
- package/dist/CruisePlugin/utils/formatRad.d.ts +7 -0
- package/dist/CruisePlugin/utils/linerValue.d.ts +1 -0
- package/dist/CruisePlugin/utils/safeCall.d.ts +1 -0
- package/dist/CruisePlugin/utils/sleep.d.ts +1 -0
- package/dist/CruisePlugin/utils/vectorToCoordinates.d.ts +7 -0
- package/dist/GuideLinePlugin/Controller.d.ts +51 -0
- package/dist/GuideLinePlugin/index.d.ts +5 -0
- package/dist/GuideLinePlugin/typing.d.ts +34 -0
- package/dist/GuideLinePlugin/utils/getArrowMaterial.d.ts +4 -0
- package/dist/GuideLinePlugin/utils/getLineGeometries.d.ts +16 -0
- package/dist/GuideLinePlugin/utils/polyline-normals.d.ts +3 -0
- package/dist/ItemLabelPlugin/Plugin.d.ts +4 -0
- package/dist/ItemLabelPlugin/events.type.d.ts +9 -0
- package/dist/ItemLabelPlugin/index.d.ts +9 -0
- package/dist/ItemLabelPlugin/typings.d.ts +65 -0
- package/dist/ItemLabelPlugin/utils/getLabelTransform.d.ts +1 -0
- package/dist/ItemLabelPlugin/utils/getStrokeLength.d.ts +5 -0
- package/dist/ItemLabelPlugin/utils/isImpacted.d.ts +8 -0
- package/dist/ItemLabelPlugin/utils/parseData.d.ts +3 -0
- package/dist/ItemLabelPlugin/utils/transform2RenderData.d.ts +3 -0
- package/dist/ModelChassisCompassPlugin/Plugin.d.ts +19 -0
- package/dist/ModelChassisCompassPlugin/index.d.ts +4 -0
- package/dist/ModelEntryDoorGuidePlugin/Plugin.d.ts +26 -0
- package/dist/ModelEntryDoorGuidePlugin/index.d.ts +4 -0
- package/dist/ModelItemLabelPlugin/ModelItemLabelPlugin.d.ts +4 -0
- package/dist/ModelItemLabelPlugin/events.type.d.ts +9 -0
- package/dist/ModelItemLabelPlugin/index.d.ts +9 -0
- package/dist/ModelItemLabelPlugin/typings.d.ts +56 -0
- package/dist/ModelItemLabelPlugin/utils/parseData.d.ts +3 -0
- package/dist/ModelRoomLabelPlugin/Assets/roomLabelBg.d.ts +1 -0
- package/dist/ModelRoomLabelPlugin/Controller.d.ts +36 -0
- package/dist/ModelRoomLabelPlugin/index.d.ts +12 -0
- package/dist/ModelRoomLabelPlugin/typings.d.ts +35 -0
- package/dist/ModelRoomLabelPlugin/utils/parseData.d.ts +3 -0
- package/dist/ModelTVVideoPlugin/Plugin.d.ts +4 -0
- package/dist/ModelTVVideoPlugin/index.d.ts +5 -0
- package/dist/ModelTVVideoPlugin/typings.d.ts +25 -0
- package/dist/ModelTVVideoPlugin/utils/parseData.d.ts +2 -0
- package/dist/ModelViewPlugin/Plugin.d.ts +28 -0
- package/dist/ModelViewPlugin/index.d.ts +4 -0
- package/dist/Object3DHelperPlugin/Controller.d.ts +65 -0
- package/dist/Object3DHelperPlugin/FiveControllerWrapper.d.ts +19 -0
- package/dist/Object3DHelperPlugin/index.d.ts +6 -0
- package/dist/Object3DHelperPlugin/typings.d.ts +24 -0
- package/dist/PanoCompassPlugin/Assets/roomInfoIcon.d.ts +1 -0
- package/dist/PanoCompassPlugin/Controller.d.ts +84 -0
- package/dist/PanoCompassPlugin/getRoomInfoInstance.d.ts +8 -0
- package/dist/PanoCompassPlugin/index.d.ts +7 -0
- package/dist/PanoCompassPlugin/typings.d.ts +57 -0
- package/dist/PanoCursorRaycasterPlugin/index.d.ts +48 -0
- package/dist/PanoDoorLabelPlugin/BaseController.d.ts +60 -0
- package/dist/PanoDoorLabelPlugin/Controller.d.ts +37 -0
- package/dist/PanoDoorLabelPlugin/index.d.ts +7 -0
- package/dist/PanoDoorLabelPlugin/typings.d.ts +38 -0
- package/dist/PanoDoorLabelPlugin/utils.d.ts +5 -0
- package/dist/PanoMeasurePlugin/Controller/BaseController.d.ts +43 -0
- package/dist/PanoMeasurePlugin/Controller/EditController.d.ts +48 -0
- package/dist/PanoMeasurePlugin/Controller/MixedController.d.ts +42 -0
- package/dist/PanoMeasurePlugin/Controller/ShortcutKeyController.d.ts +12 -0
- package/dist/PanoMeasurePlugin/Controller/ViewController.d.ts +16 -0
- package/dist/PanoMeasurePlugin/Controller/WatchController.d.ts +26 -0
- package/dist/PanoMeasurePlugin/Controller/index.d.ts +73 -0
- package/dist/PanoMeasurePlugin/Model/index.d.ts +35 -0
- package/dist/PanoMeasurePlugin/Model/line.d.ts +30 -0
- package/dist/PanoMeasurePlugin/Model/point.d.ts +16 -0
- package/dist/PanoMeasurePlugin/Model/polyline.d.ts +16 -0
- package/dist/PanoMeasurePlugin/Modules/DeleteDom/_Assets/delete.svg.d.ts +2 -0
- package/dist/PanoMeasurePlugin/Modules/DeleteDom/_Assets/delete_bg.png.d.ts +2 -0
- package/dist/PanoMeasurePlugin/Modules/DeleteDom/_Assets/delete_hover_bg.png.d.ts +2 -0
- package/dist/PanoMeasurePlugin/Modules/DeleteDom/index.d.ts +25 -0
- package/dist/PanoMeasurePlugin/Modules/FiveHelper.d.ts +11 -0
- package/dist/PanoMeasurePlugin/Modules/GuideController.d.ts +18 -0
- package/dist/PanoMeasurePlugin/Modules/Magnifier.d.ts +59 -0
- package/dist/PanoMeasurePlugin/Modules/UIController/HTML.d.ts +2 -0
- package/dist/PanoMeasurePlugin/Modules/UIController/MainBtnController.d.ts +15 -0
- package/dist/PanoMeasurePlugin/Modules/UIController/Revoke/index.d.ts +13 -0
- package/dist/PanoMeasurePlugin/Modules/UIController/index.d.ts +20 -0
- package/dist/PanoMeasurePlugin/Modules/UIController/mobileHTML.d.ts +4 -0
- package/dist/PanoMeasurePlugin/Modules/UIController/mobileMainBtnController.d.ts +12 -0
- package/dist/PanoMeasurePlugin/Modules/UIController/style.d.ts +16 -0
- package/dist/PanoMeasurePlugin/Modules/rangePiece/html.d.ts +4 -0
- package/dist/PanoMeasurePlugin/Modules/rangePiece/index.d.ts +44 -0
- package/dist/PanoMeasurePlugin/index.d.ts +10 -0
- package/dist/PanoMeasurePlugin/typings/data.d.ts +37 -0
- package/dist/PanoMeasurePlugin/typings/event.type.d.ts +37 -0
- package/dist/PanoMeasurePlugin/typings/index.d.ts +8 -0
- package/dist/PanoMeasurePlugin/utils/calculateThreeMouse.d.ts +10 -0
- package/dist/PanoMeasurePlugin/utils/constants.d.ts +4 -0
- package/dist/PanoMeasurePlugin/utils/distanceDom.d.ts +28 -0
- package/dist/PanoMeasurePlugin/utils/findAssociatedLines.d.ts +2 -0
- package/dist/PanoMeasurePlugin/utils/findClosestPoint.d.ts +10 -0
- package/dist/PanoMeasurePlugin/utils/getIntersectionFromEvent.d.ts +4 -0
- package/dist/PanoMeasurePlugin/utils/getPointFromHammerEvent.d.ts +10 -0
- package/dist/PanoMeasurePlugin/utils/ironbox.d.ts +1 -0
- package/dist/PanoMeasurePlugin/utils/isNDCPointInScreen.d.ts +2 -0
- package/dist/PanoMeasurePlugin/utils/line.d.ts +17 -0
- package/dist/PanoMeasurePlugin/utils/math.d.ts +17 -0
- package/dist/PanoMeasurePlugin/utils/mouseGroup.d.ts +7 -0
- package/dist/PanoMeasurePlugin/utils/ndc2Screen.d.ts +5 -0
- package/dist/PanoRulerPlugin/Plugin.d.ts +34 -0
- package/dist/PanoRulerPlugin/index.d.ts +5 -0
- package/dist/PanoRulerPlugin/style.d.ts +2 -0
- package/dist/PanoRulerPlugin/typings.d.ts +21 -0
- package/dist/PanoRulerProPlugin/Controller.d.ts +15 -0
- package/dist/PanoRulerProPlugin/index.d.ts +8 -0
- package/dist/PanoRulerProPlugin/typings.d.ts +46 -0
- package/dist/PanoSpatialTagPlugin/Plugin.d.ts +35 -0
- package/dist/PanoSpatialTagPlugin/index.d.ts +5 -0
- package/dist/PanoSpatialTagPlugin/store.d.ts +1 -0
- package/dist/PanoSpatialTagPlugin/style.d.ts +1 -0
- package/dist/PanoSpatialTagPlugin/typings.d.ts +40 -0
- package/dist/PanoTagPlugin/Assets/Icon.d.ts +3 -0
- package/dist/PanoTagPlugin/controller/TagCacheController.d.ts +22 -0
- package/dist/PanoTagPlugin/controller/TagComputer.d.ts +69 -0
- package/dist/PanoTagPlugin/controller/index.d.ts +144 -0
- package/dist/PanoTagPlugin/index.d.ts +8 -0
- package/dist/PanoTagPlugin/tag.config.d.ts +7 -0
- package/dist/PanoTagPlugin/typings/controller.d.ts +103 -0
- package/dist/PanoTagPlugin/typings/index.d.ts +2 -0
- package/dist/PanoTagPlugin/typings/tag.d.ts +247 -0
- package/dist/PanoTagPlugin/utils/actionAfterFiveModelLoad.d.ts +2 -0
- package/dist/PanoTagPlugin/utils/addDebugPoints.d.ts +3 -0
- package/dist/PanoTagPlugin/utils/checkRange.d.ts +4 -0
- package/dist/PanoTagPlugin/utils/constants.d.ts +3 -0
- package/dist/PanoTagPlugin/utils/debounce.d.ts +7 -0
- package/dist/PanoTagPlugin/utils/doUtil.d.ts +1 -0
- package/dist/PanoTagPlugin/utils/index.d.ts +12 -0
- package/dist/PanoTagPlugin/utils/noTypecheck.d.ts +1 -0
- package/dist/PanoTagPlugin/utils/normalPositionToPositions.d.ts +2 -0
- package/dist/PanoTagPlugin/utils/planeNormal.d.ts +4 -0
- package/dist/PanoTagPlugin/utils/resizeObserver.d.ts +4 -0
- package/dist/PanoTagPlugin/utils/search.d.ts +11 -0
- package/dist/PanoTagPlugin/utils/tagPosition.d.ts +3 -0
- package/dist/PanoTagPlugin/utils/throttle.d.ts +7 -0
- package/dist/base/BasePlugin.d.ts +106 -0
- package/dist/base/BasePluginWithData.d.ts +34 -0
- package/dist/components/PaintBrush/Controller.d.ts +43 -0
- package/dist/components/PaintBrush/Subscribe.d.ts +76 -0
- package/dist/components/PaintBrush/index.d.ts +27 -0
- package/dist/components/PaintBrush/style.d.ts +2 -0
- package/dist/components/PaintBrush/tween.d.ts +7 -0
- package/dist/components/PaintBrush/typings.d.ts +58 -0
- package/dist/components/PaintBrush/utils.d.ts +26 -0
- package/dist/components/index.d.ts +2 -0
- package/dist/env.d.ts +1 -0
- package/dist/floorplan/Assets/camera.d.ts +1 -0
- package/dist/floorplan/Assets/compass.d.ts +1 -0
- package/dist/floorplan/Assets/floorplanExtraObject.d.ts +1 -0
- package/dist/floorplan/MapviewFloorplanPlugin/Controller.d.ts +97 -0
- package/dist/floorplan/MapviewFloorplanPlugin/index.d.ts +7 -0
- package/dist/floorplan/MapviewFloorplanPlugin/typing.d.ts +1 -0
- package/dist/floorplan/ModelFloorplanPlugin/Controller.d.ts +99 -0
- package/dist/floorplan/ModelFloorplanPlugin/index.d.ts +7 -0
- package/dist/floorplan/ModelFloorplanPlugin/typing.d.ts +1 -0
- package/dist/floorplan/PanoFloorplanRadarPlugin/Controller.d.ts +36 -0
- package/dist/floorplan/PanoFloorplanRadarPlugin/index.d.ts +7 -0
- package/dist/floorplan/PanoFloorplanRadarPlugin/typing.d.ts +52 -0
- package/dist/floorplan/TopviewFloorplanPlugin/Controller.d.ts +69 -0
- package/dist/floorplan/TopviewFloorplanPlugin/index.d.ts +7 -0
- package/dist/floorplan/TopviewFloorplanPlugin/typing.d.ts +11 -0
- package/dist/floorplan/constant.d.ts +5 -0
- package/dist/floorplan/index.d.ts +7 -0
- package/dist/floorplan/typings/floorplanData.d.ts +137 -0
- package/dist/floorplan/typings/floorplanServerData.d.ts +144 -0
- package/dist/floorplan/typings/index.d.ts +117 -0
- package/dist/floorplan/typings/utility.d.ts +2 -0
- package/dist/floorplan/utils/constant.d.ts +22 -0
- package/dist/floorplan/utils/correctFiveState.d.ts +15 -0
- package/dist/floorplan/utils/formatData.d.ts +5 -0
- package/dist/floorplan/utils/formatPosition.d.ts +36 -0
- package/dist/index.d.ts +23 -0
- package/dist/index.es.js +16650 -0
- package/dist/index.js +556 -0
- package/dist/index.umd.js +556 -0
- package/dist/shared-utils/Object3DHelper/Base/BaseController.d.ts +48 -0
- package/dist/shared-utils/Object3DHelper/Base/BaseHelper.d.ts +91 -0
- package/dist/shared-utils/Object3DHelper/Constants/color.d.ts +12 -0
- package/dist/shared-utils/Object3DHelper/Controller/CSS3DScaleController.d.ts +6 -0
- package/dist/shared-utils/Object3DHelper/Controller/MoveController.d.ts +13 -0
- package/dist/shared-utils/Object3DHelper/Controller/RectangleScaleController.d.ts +37 -0
- package/dist/shared-utils/Object3DHelper/Controller/RotateController.d.ts +22 -0
- package/dist/shared-utils/Object3DHelper/Helper/HTML/rectangleScaleDom.d.ts +11 -0
- package/dist/shared-utils/Object3DHelper/Helper/HTML/tipsDom.d.ts +6 -0
- package/dist/shared-utils/Object3DHelper/Helper/HTML/utils/createElement.d.ts +2 -0
- package/dist/shared-utils/Object3DHelper/Helper/MoveHelper.d.ts +13 -0
- package/dist/shared-utils/Object3DHelper/Helper/Objects/ArrowGroup.d.ts +17 -0
- package/dist/shared-utils/Object3DHelper/Helper/OutlineHelper.d.ts +11 -0
- package/dist/shared-utils/Object3DHelper/Helper/RectangleScaleHelper.d.ts +40 -0
- package/dist/shared-utils/Object3DHelper/Helper/RotateHelper.d.ts +55 -0
- package/dist/shared-utils/Object3DHelper/Helper/index.d.ts +5 -0
- package/dist/shared-utils/Object3DHelper/index.d.ts +71 -0
- package/dist/shared-utils/Object3DHelper/typings/Direction.d.ts +2 -0
- package/dist/shared-utils/Object3DHelper/typings/Hooks.d.ts +45 -0
- package/dist/shared-utils/Object3DHelper/typings/Scissor.d.ts +17 -0
- package/dist/shared-utils/Object3DHelper/typings/index.d.ts +5 -0
- package/dist/shared-utils/Object3DHelper/utils/calculateThreeMouse.d.ts +14 -0
- package/dist/shared-utils/Object3DHelper/utils/direction.d.ts +14 -0
- package/dist/shared-utils/Object3DHelper/utils/filterNotColinearPoints.d.ts +2 -0
- package/dist/shared-utils/Object3DHelper/utils/getMouseRaycaster.d.ts +5 -0
- package/dist/shared-utils/Object3DHelper/utils/getPoint.d.ts +3 -0
- package/dist/shared-utils/Object3DHelper/utils/index.d.ts +8 -0
- package/dist/shared-utils/Object3DHelper/utils/normalPositionToPositions.d.ts +5 -0
- package/dist/shared-utils/Object3DHelper/utils/object3DBoundingPosition.d.ts +1 -0
- package/dist/shared-utils/Object3DHelper/utils/threex/domevents/index.d.ts +34 -0
- package/dist/shared-utils/Object3DHelper/utils/vectorIsEqual.d.ts +2 -0
- package/dist/shared-utils/Subscribe.d.ts +60 -0
- package/dist/shared-utils/animationFrame/BetterTween.d.ts +11 -0
- package/dist/shared-utils/animationFrame/calculateProgress.d.ts +8 -0
- package/dist/shared-utils/animationFrame/formatRad.d.ts +15 -0
- package/dist/shared-utils/animationFrame/index.d.ts +16 -0
- package/dist/shared-utils/animationFrame/tween.d.ts +75 -0
- package/dist/shared-utils/changeModelCanvasOpacity.d.ts +2 -0
- package/dist/shared-utils/createCanvasTextTexture.d.ts +8 -0
- package/dist/shared-utils/createLine/index.d.ts +3 -0
- package/dist/shared-utils/debounce.d.ts +6 -0
- package/dist/shared-utils/equal.d.ts +11 -0
- package/dist/shared-utils/filter.d.ts +27 -0
- package/dist/shared-utils/five/changeMode.d.ts +5 -0
- package/dist/shared-utils/getPxmm.d.ts +19 -0
- package/dist/shared-utils/index.d.ts +4 -0
- package/dist/shared-utils/isNil.d.ts +10 -0
- package/dist/shared-utils/isTruelyObject.d.ts +18 -0
- package/dist/shared-utils/math/Interval.d.ts +13 -0
- package/dist/shared-utils/math/Rectangle.d.ts +27 -0
- package/dist/shared-utils/math/index.d.ts +2 -0
- package/dist/shared-utils/math/planimetry.d.ts +116 -0
- package/dist/shared-utils/math/rad2Deg.d.ts +1 -0
- package/dist/shared-utils/nearlyEqual.d.ts +7 -0
- package/dist/shared-utils/nextFrame.d.ts +1 -0
- package/dist/shared-utils/noop.d.ts +5 -0
- package/dist/shared-utils/object3d2LocalMatrix.d.ts +12 -0
- package/dist/shared-utils/removeArrayItem.d.ts +7 -0
- package/dist/shared-utils/tap.d.ts +8 -0
- package/dist/shared-utils/three/Assets/index.d.ts +3 -0
- package/dist/shared-utils/three/FivePointSelector.d.ts +36 -0
- package/dist/shared-utils/three/Magnifier.d.ts +53 -0
- package/dist/shared-utils/three/PointDomHelper.d.ts +18 -0
- package/dist/shared-utils/three/PointHelper.d.ts +21 -0
- package/dist/shared-utils/three/getCoords.d.ts +9 -0
- package/dist/shared-utils/three/getIntersect.d.ts +6 -0
- package/dist/shared-utils/three/getRaycaster.d.ts +6 -0
- package/dist/shared-utils/three/index.d.ts +7 -0
- package/dist/shared-utils/three/loadTexture.d.ts +2 -0
- package/dist/shared-utils/three/transformPositionToVector3.d.ts +7 -0
- package/dist/shared-utils/three/transfromToMeshBasicMaterial.d.ts +2 -0
- package/dist/shared-utils/throttle.d.ts +7 -0
- package/dist/shared-utils/tinyEJSrender.d.ts +5 -0
- package/dist/shared-utils/to.d.ts +8 -0
- package/dist/shared-utils/uuid.d.ts +5 -0
- package/dist/typings/math.type.d.ts +44 -0
- package/docs/classes/CruisePluginController.html +24 -24
- package/docs/classes/Magnifier.html +16 -16
- package/docs/classes/ModelRoomLabelController.html +11 -11
- package/docs/classes/Object3DHelperController.html +24 -24
- package/docs/classes/PaintBrush.html +15 -15
- package/docs/classes/PanoTagPluginController.html +39 -39
- package/docs/classes/Util.BetterTween.html +8 -8
- package/docs/classes/Util.FivePointSelector.html +12 -12
- package/docs/classes/Util.Interval.html +12 -12
- package/docs/classes/Util.Magnifier.html +17 -17
- package/docs/classes/Util.PointDomHelper.html +11 -11
- package/docs/classes/Util.PointHelper.html +11 -11
- package/docs/classes/Util.Rectangle.html +13 -13
- package/docs/enums/CameraMovementEffect.html +7 -7
- package/docs/enums/ContentType.html +12 -12
- package/docs/enums/DIRECTION.html +9 -9
- package/docs/enums/DISPLAY_STRATEGY_TYPE.html +9 -9
- package/docs/enums/DimensionType.html +7 -7
- package/docs/enums/FLOOR_PLAN_ATTACHED_TO.html +8 -8
- package/docs/enums/ITEM_LABEL_PLUGIN_DISPLAY_STRATEGY_TYPE.html +9 -9
- package/docs/enums/LinkType.html +7 -7
- package/docs/enums/PaintBrushTypeEnum.html +8 -8
- package/docs/enums/PointType.html +7 -7
- package/docs/enums/Rotation.html +8 -8
- package/docs/functions/CSS3DRenderPlugin.html +4 -4
- package/docs/functions/CameraMovementPlugin.html +4 -4
- package/docs/functions/CruisePlugin.html +4 -4
- package/docs/functions/GuideLinePlugin.html +5 -5
- package/docs/functions/ItemLabelPlugin.html +4 -4
- package/docs/functions/MapviewFloorplanPlugin.html +4 -4
- package/docs/functions/ModelChassisCompassPlugin.html +4 -4
- package/docs/functions/ModelEntryDoorGuidePlugin.html +4 -4
- package/docs/functions/ModelFloorplanPlugin.html +4 -4
- package/docs/functions/ModelItemLabelPlugin.html +4 -4
- package/docs/functions/ModelRoomLabelPlugin.html +4 -4
- package/docs/functions/ModelTVVideoPlugin.html +4 -4
- package/docs/functions/ModelViewPlugin.html +4 -4
- package/docs/functions/Object3DHelperPlugin.html +4 -4
- package/docs/functions/PanoCompassPlugin.html +4 -4
- package/docs/functions/PanoCursorRaycasterPlugin.html +4 -4
- package/docs/functions/PanoDoorLabelPlugin.html +4 -4
- package/docs/functions/PanoFloorplanRadarPlugin.html +4 -4
- package/docs/functions/PanoMeasurePlugin.html +4 -4
- package/docs/functions/PanoRulerPlugin.html +4 -4
- package/docs/functions/PanoRulerProPlugin.html +4 -4
- package/docs/functions/PanoSpatialTagPlugin.html +4 -4
- package/docs/functions/PanoTagPlugin.html +4 -4
- package/docs/functions/TopviewFloorplanPlugin.html +4 -4
- package/docs/functions/Util.getCoordsFromClient.html +5 -5
- package/docs/functions/Util.getCoordsFromElement.html +5 -5
- package/docs/functions/Util.getFrameTime.html +5 -5
- package/docs/functions/Util.getIntersectFromRelativePosition.html +5 -5
- package/docs/functions/Util.getRaycasterFromFivePointer.html +5 -5
- package/docs/functions/Util.isNil.html +5 -5
- package/docs/functions/Util.nextFrame.html +5 -5
- package/docs/functions/Util.notNil.html +5 -5
- package/docs/functions/Util.requestAnimationFrameInterval.html +5 -5
- package/docs/functions/Util.tweenProgress.html +5 -5
- package/docs/functions/pluginFlag.html +5 -5
- package/docs/index.html +4 -4
- package/docs/interfaces/CSS3DRenderPluginEventMap.html +11 -11
- package/docs/interfaces/CSS3DRenderPluginState.html +8 -8
- package/docs/interfaces/CameraMovementPluginExportType.html +7 -7
- package/docs/interfaces/ContentTypeMap.html +12 -12
- package/docs/interfaces/FloorplanBounding.html +8 -8
- package/docs/interfaces/FloorplanData.html +10 -10
- package/docs/interfaces/FloorplanEntrance.html +11 -11
- package/docs/interfaces/FloorplanExtraObject.html +10 -10
- package/docs/interfaces/FloorplanExtraObject3D.html +8 -8
- package/docs/interfaces/FloorplanFloorData.html +9 -9
- package/docs/interfaces/FloorplanImagePosition.html +7 -7
- package/docs/interfaces/FloorplanObserver.html +9 -9
- package/docs/interfaces/FloorplanOutlineItem.html +9 -9
- package/docs/interfaces/FloorplanPosition.html +7 -7
- package/docs/interfaces/FloorplanRoomItem.html +13 -13
- package/docs/interfaces/FloorplanRoomLabelItem.html +7 -7
- package/docs/interfaces/FloorplanServerBounding.html +8 -8
- package/docs/interfaces/FloorplanServerComputedData.html +10 -10
- package/docs/interfaces/FloorplanServerData.html +7 -7
- package/docs/interfaces/FloorplanServerDoorItem.html +10 -10
- package/docs/interfaces/FloorplanServerDoorPosition.html +8 -8
- package/docs/interfaces/FloorplanServerEntrance.html +11 -11
- package/docs/interfaces/FloorplanServerFloorData.html +9 -9
- package/docs/interfaces/FloorplanServerImagePosition.html +7 -7
- package/docs/interfaces/FloorplanServerObserver.html +9 -9
- package/docs/interfaces/FloorplanServerOutlineItem.html +9 -9
- package/docs/interfaces/FloorplanServerPosition.html +7 -7
- package/docs/interfaces/FloorplanServerRoomItem.html +14 -14
- package/docs/interfaces/FloorplanServerRoomLabelItem.html +7 -7
- package/docs/interfaces/ItemLabelPluginData.html +6 -6
- package/docs/interfaces/ItemLabelPluginExportReturnsType.html +11 -11
- package/docs/interfaces/ItemLabelPluginParametersType.html +9 -9
- package/docs/interfaces/LineJson.html +7 -7
- package/docs/interfaces/ModelChassisCompassPluginData.html +7 -7
- package/docs/interfaces/ModelChassisCompassPluginExportType.html +8 -8
- package/docs/interfaces/ModelChassisCompassPluginParameterType.html +7 -7
- package/docs/interfaces/ModelEntryDoorGuidePluginData.html +8 -8
- package/docs/interfaces/ModelEntryDoorGuidePluginExportType.html +8 -8
- package/docs/interfaces/ModelItemLabelPluginData.html +6 -6
- package/docs/interfaces/ModelItemLabelPluginExportReturnsType.html +11 -11
- package/docs/interfaces/ModelItemLabelPluginParametersType.html +7 -7
- package/docs/interfaces/ModelRoomLabelPluginData.html +6 -6
- package/docs/interfaces/ModelTVVideoPluginData.html +9 -9
- package/docs/interfaces/ModelTVVideoPluginExportType.html +8 -8
- package/docs/interfaces/ModelTVVideoPluginParameterType.html +6 -6
- package/docs/interfaces/ModelViewPluginExportType.html +8 -8
- package/docs/interfaces/Object3DHelperState.html +8 -8
- package/docs/interfaces/OpenParameter.html +7 -7
- package/docs/interfaces/PaintBrushAction.html +12 -12
- package/docs/interfaces/PaintBrushConfigs.html +12 -12
- package/docs/interfaces/PaintBrushState.html +10 -10
- package/docs/interfaces/PanoCursorRaycasterPluginExportType.html +10 -10
- package/docs/interfaces/PanoCursorRaycasterPluginParameterType.html +5 -5
- package/docs/interfaces/PanoMeasureParameterType.html +11 -11
- package/docs/interfaces/PanoRulerPluginExportType.html +10 -10
- package/docs/interfaces/PanoRulerPluginOptions.html +7 -7
- package/docs/interfaces/PanoRulerPluginParameterType.html +8 -8
- package/docs/interfaces/PanoRulerProPluginExportType.html +9 -9
- package/docs/interfaces/PanoRulerProPluginOptions.html +7 -7
- package/docs/interfaces/PanoRulerProPluginParameterType.html +7 -7
- package/docs/interfaces/PanoRulerProPluginState.html +8 -8
- package/docs/interfaces/PanoSpatialTagPluginContentEvent.html +5 -5
- package/docs/interfaces/PanoSpatialTagPluginContentReplacement.html +5 -5
- package/docs/interfaces/PanoSpatialTagPluginData.html +11 -11
- package/docs/interfaces/PanoSpatialTagPluginDataElement.html +10 -10
- package/docs/interfaces/PanoSpatialTagPluginExportType.html +13 -13
- package/docs/interfaces/PanoSpatialTagPluginOriginElement.html +10 -10
- package/docs/interfaces/PanoSpatialTagPluginParameterType.html +13 -13
- package/docs/interfaces/PanoSpatialTagPluginPointElement.html +11 -11
- package/docs/interfaces/PanoSpatialTagPluginTagElement.html +10 -10
- package/docs/interfaces/Point.html +8 -8
- package/docs/interfaces/PointJson.html +8 -8
- package/docs/interfaces/Room.html +9 -9
- package/docs/interfaces/RoomInfo.html +7 -7
- package/docs/interfaces/RoomLabel.html +14 -14
- package/docs/interfaces/RoomRules.html +5 -5
- package/docs/interfaces/Rooms.html +5 -5
- package/docs/interfaces/Scissor.html +9 -9
- package/docs/interfaces/TagConfig.html +10 -10
- package/docs/interfaces/Tags.html +9 -9
- package/docs/interfaces/Util.MagnifierParameter.html +11 -11
- package/docs/interfaces/Util.MouseGroupParameter.html +8 -8
- package/docs/modules/Util.html +5 -5
- package/docs/modules.html +4 -4
- package/docs/types/ArrayPosition.html +5 -5
- package/docs/types/CSS3DRenderExportType.html +5 -5
- package/docs/types/CSS3DRenderPluginExportType.html +5 -5
- package/docs/types/CSS3DRenderPluginParameterType.html +5 -5
- package/docs/types/Color.html +5 -5
- package/docs/types/ContentTypeConfigKey.html +5 -5
- package/docs/types/ContentTypeConfigKeyArray.html +5 -5
- package/docs/types/Create3DDomContainerReturnType.html +5 -5
- package/docs/types/Create3DElementReturnType.html +5 -5
- package/docs/types/CruisePluginExportType.html +5 -5
- package/docs/types/Direction-1.html +5 -5
- package/docs/types/Direction4.html +5 -5
- package/docs/types/FloorplanRuleLabels.html +5 -5
- package/docs/types/FloorplanServerRuleLabels.html +5 -5
- package/docs/types/GuideLinePluginExportType.html +5 -5
- package/docs/types/HelperEventMap.html +5 -5
- package/docs/types/MapviewFloorplanPluginParameterType.html +5 -5
- package/docs/types/MapviewFloorplanPluginReturnType.html +5 -5
- package/docs/types/MediaData.html +5 -5
- package/docs/types/ModelEntryDoorGuidePluginParameterType.html +5 -5
- package/docs/types/ModelFloorplanPluginParameterType.html +5 -5
- package/docs/types/ModelFloorplanPluginReturnType.html +5 -5
- package/docs/types/ModelRoomLabelPluginParameters.html +5 -5
- package/docs/types/ModelRoomLabelPluginReturnType.html +5 -5
- package/docs/types/MoveArgs.html +5 -5
- package/docs/types/MoveOpts.html +5 -5
- package/docs/types/Object3DHelperEventMap.html +5 -5
- package/docs/types/ObjectFit.html +5 -5
- package/docs/types/PaintBrushEventMap.html +5 -5
- package/docs/types/PanoCompassPluginData.html +5 -5
- package/docs/types/PanoCompassPluginExportType.html +5 -5
- package/docs/types/PanoCompassPluginParameterType.html +5 -5
- package/docs/types/PanoFloorplanRadarPluginParameterType.html +5 -5
- package/docs/types/PanoFloorplanRadarPluginReturnType.html +5 -5
- package/docs/types/PanoMeasurePluginEvent.html +5 -5
- package/docs/types/PanoMeasureReturnType.html +5 -5
- package/docs/types/PanoSpatialTagPluginId.html +5 -5
- package/docs/types/PanoTagPluginExportInterface.html +5 -5
- package/docs/types/PanoTagPluginParamsInterface.html +5 -5
- package/docs/types/PlaneTag.html +5 -5
- package/docs/types/PointTag.html +5 -5
- package/docs/types/Position.html +5 -5
- package/docs/types/RotateArgs.html +5 -5
- package/docs/types/RotateOpts.html +5 -5
- package/docs/types/RuleLabelsKey.html +5 -5
- package/docs/types/RuleLabelsValue.html +5 -5
- package/docs/types/Tag.html +5 -5
- package/docs/types/Tag2D.html +5 -5
- package/docs/types/Tag3D.html +5 -5
- package/docs/types/TagId.html +5 -5
- package/docs/types/TopviewFloorplanPluginParameterType.html +5 -5
- package/docs/types/TopviewFloorplanPluginReturnType.html +5 -5
- package/docs/variables/FLOOR_TYPE_MAP.html +5 -5
- package/docs/variables/PLUGIN.html +5 -5
- package/docs/variables/ROOM_FETILE_TYPE_MAP.html +5 -5
- package/docs/variables/ROOM_TYPE_MAP.html +5 -5
- package/docs/variables/VERSION.html +5 -5
- package/docs/variables/itemLabelPluginServerParams.html +5 -5
- package/docs/variables/modelItemLabelPluginServerParams.html +5 -5
- package/docs/variables/modelRoomLabelPluginServerParams.html +5 -5
- package/package.json +5 -7
- package/dist/CSS3DRenderPlugin/index..js +0 -88
- package/dist/CSS3DRenderPlugin/index.cjs.js +0 -1
- package/dist/CameraMovementPlugin/index..js +0 -11
- package/dist/CameraMovementPlugin/index.cjs.js +0 -1
- package/dist/CruisePlugin/index..js +0 -527
- package/dist/CruisePlugin/index.cjs.js +0 -1
- package/dist/GuideLinePlugin/index..js +0 -214
- package/dist/GuideLinePlugin/index.cjs.js +0 -1
- package/dist/ItemLabelPlugin/index..js +0 -508
- package/dist/ItemLabelPlugin/index.cjs.js +0 -10
- package/dist/ModelChassisCompassPlugin/index..js +0 -9
- package/dist/ModelChassisCompassPlugin/index.cjs.js +0 -1
- package/dist/ModelEntryDoorGuidePlugin/index..js +0 -9
- package/dist/ModelEntryDoorGuidePlugin/index.cjs.js +0 -1
- package/dist/ModelItemLabelPlugin/index..js +0 -334
- package/dist/ModelItemLabelPlugin/index.cjs.js +0 -10
- package/dist/ModelRoomLabelPlugin/index..js +0 -274
- package/dist/ModelRoomLabelPlugin/index.cjs.js +0 -1
- package/dist/ModelTVVideoPlugin/index..js +0 -12
- package/dist/ModelTVVideoPlugin/index.cjs.js +0 -1
- package/dist/ModelViewPlugin/index..js +0 -8
- package/dist/ModelViewPlugin/index.cjs.js +0 -1
- package/dist/Object3DHelperPlugin/index..js +0 -1414
- package/dist/Object3DHelperPlugin/index.cjs.js +0 -1
- package/dist/PanoCompassPlugin/index..js +0 -258
- package/dist/PanoCompassPlugin/index.cjs.js +0 -1
- package/dist/PanoCursorRaycasterPlugin/index..js +0 -63
- package/dist/PanoCursorRaycasterPlugin/index.cjs.js +0 -1
- package/dist/PanoDoorLabelPlugin/index..js +0 -340
- package/dist/PanoDoorLabelPlugin/index.cjs.js +0 -1
- package/dist/PanoMeasurePlugin/index..js +0 -15
- package/dist/PanoMeasurePlugin/index.cjs.js +0 -1
- package/dist/PanoRulerPlugin/index..js +0 -9
- package/dist/PanoRulerPlugin/index.cjs.js +0 -1
- package/dist/PanoRulerProPlugin/index..js +0 -395
- package/dist/PanoRulerProPlugin/index.cjs.js +0 -1
- package/dist/PanoSpatialTagPlugin/index..js +0 -15
- package/dist/PanoSpatialTagPlugin/index.cjs.js +0 -1
- package/dist/PanoTagPlugin/index..js +0 -4522
- package/dist/PanoTagPlugin/index.cjs.js +0 -17
- package/dist/chunks/cjs/BasePlugin.57e5204f.cjs.js +0 -1
- package/dist/chunks/cjs/BasePluginWithData.0a28882d.cjs.js +0 -1
- package/dist/chunks/cjs/CSS3DRender.15349564.cjs.js +0 -1
- package/dist/chunks/cjs/CameraMovementPlugin.2b342576.cjs.js +0 -1
- package/dist/chunks/cjs/Plugin.5f616fb3.cjs.js +0 -1
- package/dist/chunks/cjs/Plugin.609da4aa.cjs.js +0 -94
- package/dist/chunks/cjs/Plugin.67936d0e.cjs.js +0 -16
- package/dist/chunks/cjs/Plugin.8a110c53.cjs.js +0 -1
- package/dist/chunks/cjs/Plugin.9971108a.cjs.js +0 -1
- package/dist/chunks/cjs/Plugin.fd42bf8a.cjs.js +0 -1
- package/dist/chunks/cjs/Subscribe.5398d5c6.cjs.js +0 -1
- package/dist/chunks/cjs/changeModelCanvasOpacity.8d84f111.cjs.js +0 -1
- package/dist/chunks/cjs/correctFiveState.4c8472bd.cjs.js +0 -1
- package/dist/chunks/cjs/debounce.93dfb637.cjs.js +0 -1
- package/dist/chunks/cjs/equal.e9fcbd4e.cjs.js +0 -1
- package/dist/chunks/cjs/filter.cf9ebbb3.cjs.js +0 -1
- package/dist/chunks/cjs/formatData.81e95011.cjs.js +0 -10
- package/dist/chunks/cjs/index.30b7baeb.cjs.js +0 -101
- package/dist/chunks/cjs/index.686e84d1.cjs.js +0 -290
- package/dist/chunks/cjs/index.7d2010ce.cjs.js +0 -1
- package/dist/chunks/cjs/isNil.b3a58990.cjs.js +0 -1
- package/dist/chunks/cjs/planimetry.7fce816a.cjs.js +0 -1
- package/dist/chunks/cjs/throttle.86c209eb.cjs.js +0 -1
- package/dist/chunks/cjs/transfromToMeshBasicMaterial.9db6d46a.cjs.js +0 -1
- package/dist/chunks/cjs/uuid.29ed9c88.cjs.js +0 -1
- package/dist/chunks/es/BasePlugin.813e25f7.es.js +0 -18
- package/dist/chunks/es/BasePluginWithData.4bf4e649.es.js +0 -6
- package/dist/chunks/es/CSS3DRender.5652510e.es.js +0 -393
- package/dist/chunks/es/CameraMovementPlugin.4a7c3e46.es.js +0 -120
- package/dist/chunks/es/Plugin.26c2df05.es.js +0 -106
- package/dist/chunks/es/Plugin.435485ed.es.js +0 -584
- package/dist/chunks/es/Plugin.a98418f0.es.js +0 -82
- package/dist/chunks/es/Plugin.ae4ee6f8.es.js +0 -82
- package/dist/chunks/es/Plugin.dd11e0ad.es.js +0 -180
- package/dist/chunks/es/Plugin.f4cf895f.es.js +0 -355
- package/dist/chunks/es/Subscribe.c73e0f91.es.js +0 -50
- package/dist/chunks/es/changeModelCanvasOpacity.45ef9fd6.es.js +0 -1551
- package/dist/chunks/es/correctFiveState.e7feab9f.es.js +0 -66
- package/dist/chunks/es/debounce.ef83f417.es.js +0 -11
- package/dist/chunks/es/equal.7db4a6f7.es.js +0 -56
- package/dist/chunks/es/filter.97ec06c4.es.js +0 -12
- package/dist/chunks/es/formatData.a2b39ef9.es.js +0 -483
- package/dist/chunks/es/index.a273f06e.es.js +0 -532
- package/dist/chunks/es/index.b8fdb59b.es.js +0 -50
- package/dist/chunks/es/index.f74f4851.es.js +0 -1787
- package/dist/chunks/es/isNil.212842d9.es.js +0 -10
- package/dist/chunks/es/planimetry.b0b4a28d.es.js +0 -43
- package/dist/chunks/es/throttle.db66bac3.es.js +0 -11
- package/dist/chunks/es/transfromToMeshBasicMaterial.849ee069.es.js +0 -24
- package/dist/chunks/es/uuid.676cb2c8.es.js +0 -9
- package/dist/components/PaintBrush/index..js +0 -6
- package/dist/components/PaintBrush/index.cjs.js +0 -1
- package/dist/components/index..js +0 -7
- package/dist/components/index.cjs.js +0 -1
- package/dist/floorplan/MapviewFloorplanPlugin/index..js +0 -324
- package/dist/floorplan/MapviewFloorplanPlugin/index.cjs.js +0 -1
- package/dist/floorplan/ModelFloorplanPlugin/index..js +0 -320
- package/dist/floorplan/ModelFloorplanPlugin/index.cjs.js +0 -1
- package/dist/floorplan/PanoFloorplanRadarPlugin/index..js +0 -613
- package/dist/floorplan/PanoFloorplanRadarPlugin/index.cjs.js +0 -1
- package/dist/floorplan/TopviewFloorplanPlugin/index..js +0 -277
- package/dist/floorplan/TopviewFloorplanPlugin/index.cjs.js +0 -1
- package/dist/index..js +0 -530
- package/dist/index.cjs.js +0 -16
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
function I(r, x) {
|
|
2
|
-
return r.x === x.x && r.y === x.y;
|
|
3
|
-
}
|
|
4
|
-
function N(r, x) {
|
|
5
|
-
return Math.abs(r) === 1 / 0 && Math.abs(x) === 1 / 0 ? !0 : Math.abs(r - x) < 1e-3;
|
|
6
|
-
}
|
|
7
|
-
function m(r, x) {
|
|
8
|
-
return (x.y - r.y) / (x.x - r.x);
|
|
9
|
-
}
|
|
10
|
-
function O(r, x, f) {
|
|
11
|
-
const u = m(r[1], r[0]), y = m(x[1], x[0]);
|
|
12
|
-
if (isNaN(u) || isNaN(y) || N(u, y))
|
|
13
|
-
return !1;
|
|
14
|
-
if (h(r[0], x))
|
|
15
|
-
return r[0];
|
|
16
|
-
if (h(r[1], x))
|
|
17
|
-
return r[1];
|
|
18
|
-
if (h(x[0], r))
|
|
19
|
-
return x[0];
|
|
20
|
-
if (h(x[1], r))
|
|
21
|
-
return x[1];
|
|
22
|
-
if (f && !L(r, x))
|
|
23
|
-
return !1;
|
|
24
|
-
const a = r[0], c = x[0];
|
|
25
|
-
if (Math.abs(u) === 1 / 0)
|
|
26
|
-
return { x: a.x, y: x[1].y - (x[1].x - a.x) * y };
|
|
27
|
-
if (Math.abs(y) === 1 / 0)
|
|
28
|
-
return { x: c.x, y: r[1].y - (r[1].x - c.x) * u };
|
|
29
|
-
const b = (c.y - a.y + u * a.x - y * c.x) / (u - y), K = u * b - u * a.x + a.y;
|
|
30
|
-
return { x: b, y: K };
|
|
31
|
-
}
|
|
32
|
-
function h(r, x) {
|
|
33
|
-
return I(r, x[0]) || I(r, x[1]) ? !0 : (x[0].x - r.x) * (r.x - x[1].x) >= 0 && (x[0].y - r.y) * (r.y - x[1].y) >= 0 && N(m(x[0], r), m(r, x[1]));
|
|
34
|
-
}
|
|
35
|
-
function M(r, x, f) {
|
|
36
|
-
return (r.x - f.x) * (x.y - f.y) - (x.x - f.x) * (r.y - f.y);
|
|
37
|
-
}
|
|
38
|
-
function L(r, x) {
|
|
39
|
-
return Math.max(r[0].x, r[1].x) >= Math.min(x[0].x, x[1].x) && Math.max(x[0].x, x[1].x) >= Math.min(r[0].x, r[1].x) && Math.max(r[0].y, r[1].y) >= Math.min(x[0].y, x[1].y) && M(x[0], r[1], r[0]) * M(r[1], x[1], r[0]) > 0 && M(r[0], x[1], x[0]) * M(x[1], r[1], x[0]) > 0 ? 1 : 0;
|
|
40
|
-
}
|
|
41
|
-
export {
|
|
42
|
-
O as intersectionOfLine
|
|
43
|
-
};
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
var p = Object.defineProperty;
|
|
2
|
-
var i = Object.getOwnPropertySymbols;
|
|
3
|
-
var d = Object.prototype.hasOwnProperty, f = Object.prototype.propertyIsEnumerable;
|
|
4
|
-
var s = (a, e, r) => e in a ? p(a, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : a[e] = r, m = (a, e) => {
|
|
5
|
-
for (var r in e || (e = {}))
|
|
6
|
-
d.call(e, r) && s(a, r, e[r]);
|
|
7
|
-
if (i)
|
|
8
|
-
for (var r of i(e))
|
|
9
|
-
f.call(e, r) && s(a, r, e[r]);
|
|
10
|
-
return a;
|
|
11
|
-
};
|
|
12
|
-
import { MeshBasicMaterial as M } from "three";
|
|
13
|
-
function O(a, e) {
|
|
14
|
-
a.traverse((r) => {
|
|
15
|
-
var n;
|
|
16
|
-
if (r.type === "Mesh") {
|
|
17
|
-
const t = r, o = m({ map: t.material.map || {} }, e);
|
|
18
|
-
t.material = new M(o), t.renderOrder = 1, ((n = r.parent) == null ? void 0 : n.type) === "Mesh" && (r.renderOrder = r.parent.renderOrder + 1);
|
|
19
|
-
}
|
|
20
|
-
});
|
|
21
|
-
}
|
|
22
|
-
export {
|
|
23
|
-
O as transfromToMeshBasicMaterial
|
|
24
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../../chunks/cjs/index.30b7baeb.cjs.js");require("@tweenjs/tween.js");require("../../chunks/cjs/uuid.29ed9c88.cjs.js");exports.PaintBrush=e.PaintBrush;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../chunks/cjs/index.30b7baeb.cjs.js");require("@tweenjs/tween.js");require("../chunks/cjs/uuid.29ed9c88.cjs.js");exports.PaintBrush=e.PaintBrush;exports.PaintBrushTypeEnum=e.PaintBrushTypeEnum;
|
|
@@ -1,324 +0,0 @@
|
|
|
1
|
-
var F = Object.defineProperty, E = Object.defineProperties;
|
|
2
|
-
var C = Object.getOwnPropertyDescriptors;
|
|
3
|
-
var g = Object.getOwnPropertySymbols;
|
|
4
|
-
var P = Object.prototype.hasOwnProperty, y = Object.prototype.propertyIsEnumerable;
|
|
5
|
-
var v = (r, o, t) => o in r ? F(r, o, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[o] = t, l = (r, o) => {
|
|
6
|
-
for (var t in o || (o = {}))
|
|
7
|
-
P.call(o, t) && v(r, t, o[t]);
|
|
8
|
-
if (g)
|
|
9
|
-
for (var t of g(o))
|
|
10
|
-
y.call(o, t) && v(r, t, o[t]);
|
|
11
|
-
return r;
|
|
12
|
-
}, m = (r, o) => E(r, C(o));
|
|
13
|
-
var s = (r, o, t) => (v(r, typeof o != "symbol" ? o + "" : o, t), t);
|
|
14
|
-
var c = (r, o, t) => new Promise((e, i) => {
|
|
15
|
-
var n = (d) => {
|
|
16
|
-
try {
|
|
17
|
-
a(t.next(d));
|
|
18
|
-
} catch (u) {
|
|
19
|
-
i(u);
|
|
20
|
-
}
|
|
21
|
-
}, h = (d) => {
|
|
22
|
-
try {
|
|
23
|
-
a(t.throw(d));
|
|
24
|
-
} catch (u) {
|
|
25
|
-
i(u);
|
|
26
|
-
}
|
|
27
|
-
}, a = (d) => d.done ? e(d.value) : Promise.resolve(d.value).then(n, h);
|
|
28
|
-
a((t = t.apply(r, o)).next());
|
|
29
|
-
});
|
|
30
|
-
import * as x from "three";
|
|
31
|
-
import { checkShowState as I, FloorplanErrorType as f, to as M, correctFiveState as L, SHOW_ANIME_DURATION as _ } from "../../chunks/es/correctFiveState.e7feab9f.es.js";
|
|
32
|
-
import { equal as D } from "../../chunks/es/equal.7db4a6f7.es.js";
|
|
33
|
-
import { FLOOR_PLAN_ATTACHED_TO as O, getPxmm as T, getAttachedY as k, changeModelCanvasOpacity as b, Main as B } from "../../chunks/es/changeModelCanvasOpacity.45ef9fd6.es.js";
|
|
34
|
-
import { CAMERA_IMAGE as H, formatData as S } from "../../chunks/es/formatData.a2b39ef9.es.js";
|
|
35
|
-
import { omit as R } from "../../chunks/es/filter.97ec06c4.es.js";
|
|
36
|
-
import { Controller as G } from "../../chunks/es/BasePluginWithData.4bf4e649.es.js";
|
|
37
|
-
import "svelte/internal";
|
|
38
|
-
import "svelte/easing";
|
|
39
|
-
import "svelte/transition";
|
|
40
|
-
import "svelte/store";
|
|
41
|
-
import "svelte";
|
|
42
|
-
import "../../chunks/es/BasePlugin.813e25f7.es.js";
|
|
43
|
-
import "../../chunks/es/Subscribe.c73e0f91.es.js";
|
|
44
|
-
function W(r) {
|
|
45
|
-
const { latitude: o, longitude: t } = r, e = Math.abs(o - Math.PI / 2) > 5 * Math.PI / 180, i = t > 5 * (Math.PI / 180) && t < 355 * (Math.PI / 180);
|
|
46
|
-
return e || i;
|
|
47
|
-
}
|
|
48
|
-
function z(r) {
|
|
49
|
-
const { latitude: o, longitude: t } = r, e = Math.abs(o - Math.PI / 2) < 10 * Math.PI / 180, i = t < 30 * (Math.PI / 180) || t > 330 * (Math.PI / 180);
|
|
50
|
-
return e && i;
|
|
51
|
-
}
|
|
52
|
-
class N extends G {
|
|
53
|
-
constructor(t, e) {
|
|
54
|
-
super(t);
|
|
55
|
-
s(this, "name", "modelFloorplanPlugin");
|
|
56
|
-
s(this, "state");
|
|
57
|
-
s(this, "data");
|
|
58
|
-
s(this, "showState");
|
|
59
|
-
s(this, "showPromise");
|
|
60
|
-
s(this, "app");
|
|
61
|
-
s(this, "panoIndex", 0);
|
|
62
|
-
s(this, "floorIndex", 0);
|
|
63
|
-
s(this, "selector");
|
|
64
|
-
s(this, "showRejection");
|
|
65
|
-
s(this, "wrapper");
|
|
66
|
-
s(this, "container", document.createElement("div"));
|
|
67
|
-
s(this, "lastPanoramaLongitude", 0);
|
|
68
|
-
s(this, "size", { width: 0, height: 0 });
|
|
69
|
-
s(this, "hasAddedEventListener", !1);
|
|
70
|
-
s(this, "isHiddenByHideFunc", !1);
|
|
71
|
-
s(this, "dispose", () => {
|
|
72
|
-
var t, e;
|
|
73
|
-
this.removeEventListener(), (t = this.app) == null || t.$destroy(), this.app = void 0, (e = this.container) == null || e.remove(), this.data = void 0, this.wrapper = void 0, this.selector = void 0, this.hooks.emit("dispose");
|
|
74
|
-
});
|
|
75
|
-
s(this, "show", (...e) => c(this, [...e], function* (t = {}) {
|
|
76
|
-
if (!this.state.enabled || !this.showPromise && this.state.visible)
|
|
77
|
-
return;
|
|
78
|
-
const i = t.userAction !== void 0 ? t.userAction : !0;
|
|
79
|
-
this.updateState({ visible: !0 }, i), this._show(t);
|
|
80
|
-
}));
|
|
81
|
-
s(this, "hide", (...e) => c(this, [...e], function* (t = {}) {
|
|
82
|
-
!this.state.enabled || (this.isHiddenByHideFunc = !0, this.state.visible !== !1 && (this.updateState({ visible: !1 }, t.userAction || !0), this._hide(t)));
|
|
83
|
-
}));
|
|
84
|
-
s(this, "updateSize", () => {
|
|
85
|
-
if (!this.data || !I(this.five, this.showState) || !this.container || !this.wrapper)
|
|
86
|
-
return;
|
|
87
|
-
const { min: t, max: e } = this.data.bounding, i = e.x - t.x, n = e.y - t.y, h = this.state.config.attachedTo ? { attachedTo: this.state.config.attachedTo } : void 0, a = T(this.five, this.wrapper, this.floorIndex, h), d = Math.ceil(i * a), u = Math.ceil(n * a);
|
|
88
|
-
this.size.width === d && this.size.height === u || (this.container.style.width = d + "px", this.container.style.height = u + "px", this.size = { width: d, height: u });
|
|
89
|
-
});
|
|
90
|
-
s(this, "_disable", (t) => {
|
|
91
|
-
var i, n, h;
|
|
92
|
-
const { userAction: e } = t;
|
|
93
|
-
this.hooks.emit("disable", { userAction: e }), (i = this.showRejection) == null || i.call(this, f.BreakOffByDisable), this.showPromise = void 0, (n = this.app) == null || n.$destroy(), this.app = void 0, (h = this.container) == null || h.remove(), this.removeEventListener();
|
|
94
|
-
});
|
|
95
|
-
s(this, "_enable", (t) => {
|
|
96
|
-
const { userAction: e } = t;
|
|
97
|
-
this.addEventListener(), this.wrapper && (this.wrapper.append(this.container), this.hooks.emit("enable", { userAction: e }), this.state.visible && this._show({ userAction: e }));
|
|
98
|
-
});
|
|
99
|
-
s(this, "_show", (t) => c(this, null, function* () {
|
|
100
|
-
var h;
|
|
101
|
-
if (!this.state.enabled)
|
|
102
|
-
return;
|
|
103
|
-
if (!((h = this.five.model) != null && h.loaded))
|
|
104
|
-
throw new Error(f.ModelNotLoaded);
|
|
105
|
-
if (!this.data)
|
|
106
|
-
throw new Error(f.DataNotLoaded);
|
|
107
|
-
this.isHiddenByHideFunc = !1;
|
|
108
|
-
const e = {
|
|
109
|
-
floorIndex: this.floorIndex,
|
|
110
|
-
modelOpacity: this.state.config.modelOpacity,
|
|
111
|
-
immediately: !1,
|
|
112
|
-
isAutoShow: !1,
|
|
113
|
-
userAction: !0
|
|
114
|
-
}, i = l(l({}, e), t), n = () => c(this, null, function* () {
|
|
115
|
-
this.hooks.emit("show", { userAction: i.userAction, auto: i.isAutoShow });
|
|
116
|
-
let a = !1, d;
|
|
117
|
-
this.showRejection = (A) => {
|
|
118
|
-
a = !0, d = A;
|
|
119
|
-
};
|
|
120
|
-
const [u] = yield M(L(this.five, this.showState, i.userAction));
|
|
121
|
-
if (u)
|
|
122
|
-
throw u;
|
|
123
|
-
if (a)
|
|
124
|
-
throw d ? new Error(d) : new Error(f.UnknownError);
|
|
125
|
-
this.updateSize(), this.updatePosition(), this.floorIndex = i.floorIndex, this.five.model.show(this.floorIndex);
|
|
126
|
-
const p = i.modelOpacity, w = i.immediately ? 0 : _;
|
|
127
|
-
b(this.five, p, w), this.render(w);
|
|
128
|
-
});
|
|
129
|
-
return this.showPromise = n().then(() => {
|
|
130
|
-
this.hooks.emit("showAnimationEnded", {
|
|
131
|
-
auto: i.isAutoShow,
|
|
132
|
-
userAction: i.userAction
|
|
133
|
-
});
|
|
134
|
-
}).catch((a) => {
|
|
135
|
-
if (this.updateState({ visible: !1 }, i.userAction), !i.isAutoShow && a instanceof Error)
|
|
136
|
-
throw a;
|
|
137
|
-
}).finally(() => {
|
|
138
|
-
this.showPromise = void 0, this.showRejection = void 0;
|
|
139
|
-
}), this.showPromise;
|
|
140
|
-
}));
|
|
141
|
-
s(this, "_hide", (t) => {
|
|
142
|
-
var n;
|
|
143
|
-
(n = this.showRejection) == null || n.call(this, f.BreakOffByHide), this.showPromise = void 0;
|
|
144
|
-
const i = l(l({}, {
|
|
145
|
-
userAction: !0,
|
|
146
|
-
isAutoHide: !1
|
|
147
|
-
}), t);
|
|
148
|
-
b(this.five, 1, 0), this.hooks.emit("hide", { auto: i.isAutoHide, userAction: i.userAction }), this.render();
|
|
149
|
-
});
|
|
150
|
-
s(this, "handleClick", () => {
|
|
151
|
-
if (!this.state.visible)
|
|
152
|
-
return;
|
|
153
|
-
if (this.hooks.emit("click"))
|
|
154
|
-
return !1;
|
|
155
|
-
});
|
|
156
|
-
s(this, "onFiveModelLoaded", () => {
|
|
157
|
-
if (this.state.enabled === !1 || this.wrapper || !this.selector)
|
|
158
|
-
return;
|
|
159
|
-
const t = this.selector instanceof Element ? this.selector : document.querySelector(this.selector);
|
|
160
|
-
if (!t)
|
|
161
|
-
throw new Error("\u4E0D\u6B63\u786E\u7684\u7236\u5BB9\u5668\u9009\u62E9\u5668");
|
|
162
|
-
this.wrapper = t, t.append(this.container);
|
|
163
|
-
});
|
|
164
|
-
s(this, "onFiveModeChange", (t) => {
|
|
165
|
-
t !== this.showState.mode && (this.updateState({ visible: !1 }, !1), this._hide({ userAction: !1 }));
|
|
166
|
-
});
|
|
167
|
-
s(this, "onFivePanoArrived", (t) => {
|
|
168
|
-
var e;
|
|
169
|
-
!((e = this.five) != null && e.work) || (this.panoIndex = t, this.floorIndex = this.five.work.observers[t].floorIndex);
|
|
170
|
-
});
|
|
171
|
-
s(this, "onFiveCameraUpdate", (t, e) => {
|
|
172
|
-
if (!this.state.visible || this.showPromise)
|
|
173
|
-
return;
|
|
174
|
-
const i = this.five.getCurrentState();
|
|
175
|
-
this.updatePosition(), this.updateSize(), W(i) && (this.updateState({ visible: !1 }, e), this._hide({ userAction: e }));
|
|
176
|
-
});
|
|
177
|
-
s(this, "onFiveWantsPanGesture", (t, e) => {
|
|
178
|
-
if (this.five.getCurrentState().mode === this.showState.mode && this.state.config.autoShowEnable !== !1) {
|
|
179
|
-
if (e && this.state.visible)
|
|
180
|
-
return this.five.updateCamera(this.showState, 0), !1;
|
|
181
|
-
if (e && !this.state.visible) {
|
|
182
|
-
if (this.isHiddenByHideFunc)
|
|
183
|
-
return;
|
|
184
|
-
const i = this.five.getCurrentState();
|
|
185
|
-
return i.mode !== this.showState.mode || this.state.visible ? void 0 : (z(i) && (this.updateState({ visible: !0 }, !0), this._show({ isAutoShow: !0 })), !1);
|
|
186
|
-
}
|
|
187
|
-
}
|
|
188
|
-
});
|
|
189
|
-
s(this, "onFiveWantsTapGesture", () => this.handleClick());
|
|
190
|
-
s(this, "onFiveWantsChangeMode", (t, e) => {
|
|
191
|
-
e === "Panorama" && t === this.showState.mode && (this.lastPanoramaLongitude = this.five.getCurrentState().longitude);
|
|
192
|
-
});
|
|
193
|
-
s(this, "onModelShownFloorChange", (t) => {
|
|
194
|
-
if (this.floorIndex !== t) {
|
|
195
|
-
if (t === null) {
|
|
196
|
-
const e = this.five.getCurrentState().panoIndex;
|
|
197
|
-
this.floorIndex = this.five.work.observers[e].floorIndex;
|
|
198
|
-
return;
|
|
199
|
-
}
|
|
200
|
-
this.floorIndex = t, this.updateSize(), this.render();
|
|
201
|
-
}
|
|
202
|
-
});
|
|
203
|
-
e != null && e.selector && (this.selector = e.selector, console.warn("\u4E0D\u63A8\u8350\u7EE7\u7EED\u4F7F\u7528 params.selector \u914D\u7F6E\u7236\u5BB9\u5668\uFF0C\u8BF7\u4F7F\u7528 appendTo \u65B9\u6CD5")), this.showState = {
|
|
204
|
-
mode: "Mapview",
|
|
205
|
-
longitude: 0,
|
|
206
|
-
latitude: Math.PI / 2,
|
|
207
|
-
fov: 90
|
|
208
|
-
};
|
|
209
|
-
const i = {
|
|
210
|
-
northDesc: "\u5317",
|
|
211
|
-
modelOpacity: 1,
|
|
212
|
-
hoverEnable: !0,
|
|
213
|
-
compassEnable: !0,
|
|
214
|
-
autoShowEnable: !0,
|
|
215
|
-
ruleLabelsEnable: !0,
|
|
216
|
-
roomLabelsEnable: !0,
|
|
217
|
-
cameraImageUrl: H,
|
|
218
|
-
attachedTo: O.BOUNDING_CENTER,
|
|
219
|
-
getLabelElement: void 0,
|
|
220
|
-
adaptiveRoomLabelVisibleEnable: !0,
|
|
221
|
-
getRoomAreaText: (a) => (a / 1e6).toFixed(1) + "\u33A1",
|
|
222
|
-
getRuleDistanceText: (a) => a.toString()
|
|
223
|
-
}, n = e ? R(e, ["selector", "scale"]) : {}, h = l(l({}, i), n);
|
|
224
|
-
this.state = {
|
|
225
|
-
enabled: !0,
|
|
226
|
-
visible: !1,
|
|
227
|
-
config: h
|
|
228
|
-
}, this.initContainer(), t.model.loaded ? this.onFiveModelLoaded() : t.once("modelLoaded", this.onFiveModelLoaded), t.once("dispose", this.dispose), this.addEventListener();
|
|
229
|
-
}
|
|
230
|
-
load(t, e, i = !0) {
|
|
231
|
-
return c(this, null, function* () {
|
|
232
|
-
function n(p) {
|
|
233
|
-
return Object.prototype.hasOwnProperty.apply(p, ["version"]);
|
|
234
|
-
}
|
|
235
|
-
const h = t;
|
|
236
|
-
h && !h.version && console.warn("\u4F20\u5165 serverData.data \u7684\u65B9\u5F0F\u540E\u7EED\u53EF\u80FD\u4E0D\u518D\u652F\u6301\uFF0C\u8BF7\u628A serverData \u6574\u4F53\u4F20\u5165 load \u51FD\u6570");
|
|
237
|
-
const a = JSON.parse(JSON.stringify(t)), d = n(a) ? a.data : a, u = this.data;
|
|
238
|
-
this.data = yield S(d), this.hooks.emit("dataLoaded", this.data), this.hooks.emit("dataChange", this.data, u), e && this.updateState(e, i), this.render();
|
|
239
|
-
});
|
|
240
|
-
}
|
|
241
|
-
appendTo(t) {
|
|
242
|
-
if (this.wrapper = t, !!this.state.enabled)
|
|
243
|
-
return t.appendChild(this.container), this.render(), this;
|
|
244
|
-
}
|
|
245
|
-
enable(t = {}) {
|
|
246
|
-
if (this.state.enabled)
|
|
247
|
-
return;
|
|
248
|
-
const e = t.userAction !== void 0 ? t.userAction : !0;
|
|
249
|
-
this.updateState({ enabled: !0 }, t.userAction || e), this._enable({ userAction: e });
|
|
250
|
-
}
|
|
251
|
-
disable(t = {}) {
|
|
252
|
-
if (!this.state.enabled)
|
|
253
|
-
return;
|
|
254
|
-
const e = t.userAction !== void 0 ? t.userAction : !0;
|
|
255
|
-
this.updateState({ enabled: !1 }, t.userAction || e), this._disable({ userAction: e });
|
|
256
|
-
}
|
|
257
|
-
setState(t, e = {}) {
|
|
258
|
-
const i = this.state, n = e.userAction !== void 0 ? e.userAction : !0;
|
|
259
|
-
if (this.updateState(t, n), t.enabled !== void 0 && i.enabled !== t.enabled && (t.enabled ? this._enable({ userAction: n }) : this._disable({ userAction: n })), t.visible !== void 0 && i.visible !== t.visible) {
|
|
260
|
-
const h = { userAction: n };
|
|
261
|
-
t.visible ? this._show(h) : this._hide(h);
|
|
262
|
-
}
|
|
263
|
-
}
|
|
264
|
-
changeConfigs(t, e = !0) {
|
|
265
|
-
this.updateState({ config: t }, e), this.render();
|
|
266
|
-
}
|
|
267
|
-
updatePosition() {
|
|
268
|
-
var a;
|
|
269
|
-
const t = k(this.five, this.floorIndex, this.state.config.attachedTo), e = (a = this.five.model) == null ? void 0 : a.bounding.getCenter(new x.Vector3()).setY(t);
|
|
270
|
-
if (!e)
|
|
271
|
-
return;
|
|
272
|
-
const i = e.clone().project(this.five.camera), n = (i.x + 1) / 2, h = -(i.y - 1) / 2;
|
|
273
|
-
this.container.style.left = n * 100 + "%", this.container.style.top = h * 100 + "%";
|
|
274
|
-
}
|
|
275
|
-
formatData(t) {
|
|
276
|
-
return c(this, null, function* () {
|
|
277
|
-
return yield S(t.data);
|
|
278
|
-
});
|
|
279
|
-
}
|
|
280
|
-
updateState(t, e) {
|
|
281
|
-
const i = this.state, n = t.config ? l(l({}, i.config), t.config) : i.config;
|
|
282
|
-
this.state = m(l(l({}, this.state), t), { config: n }), !D(this.state, i, { deep: !0 }) && this.hooks.emit("stateChange", { state: this.state, prevState: i, userAction: e });
|
|
283
|
-
}
|
|
284
|
-
initContainer() {
|
|
285
|
-
this.container.classList.add("floorplan-plugin"), Object.assign(this.container.style, {
|
|
286
|
-
position: "absolute",
|
|
287
|
-
left: "50%",
|
|
288
|
-
top: "50%",
|
|
289
|
-
transform: "translate(-50%, -50%)",
|
|
290
|
-
zIndex: 10,
|
|
291
|
-
pointerEvents: "none"
|
|
292
|
-
}), this.five.addExtraElement(this.container);
|
|
293
|
-
}
|
|
294
|
-
addEventListener() {
|
|
295
|
-
if (!this.state.enabled || this.hasAddedEventListener)
|
|
296
|
-
return;
|
|
297
|
-
const t = this.five;
|
|
298
|
-
t.on("modeChange", this.onFiveModeChange), t.on("panoArrived", this.onFivePanoArrived), t.on("cameraUpdate", this.onFiveCameraUpdate), t.on("wantsPanGesture", this.onFiveWantsPanGesture), t.on("wantsTapGesture", this.onFiveWantsTapGesture), t.on("wantsChangeMode", this.onFiveWantsChangeMode), t.on("modelShownFloorChange", this.onModelShownFloorChange);
|
|
299
|
-
}
|
|
300
|
-
removeEventListener() {
|
|
301
|
-
const t = this.five;
|
|
302
|
-
this.hasAddedEventListener = !1, t.off("modelLoaded", this.onFiveModelLoaded), t.off("modeChange", this.onFiveModeChange), t.off("panoArrived", this.onFivePanoArrived), t.off("cameraUpdate", this.onFiveCameraUpdate), t.off("wantsPanGesture", this.onFiveWantsPanGesture), t.off("wantsTapGesture", this.onFiveWantsTapGesture), t.off("wantsChangeMode", this.onFiveWantsChangeMode), t.off("modelShownFloorChange", this.onModelShownFloorChange);
|
|
303
|
-
}
|
|
304
|
-
render(t) {
|
|
305
|
-
if (!this.state.enabled || !this.container || !this.data || this.size.width === 0)
|
|
306
|
-
return;
|
|
307
|
-
const e = m(l({}, this.state.config), {
|
|
308
|
-
visible: this.state.visible,
|
|
309
|
-
duration: t != null ? t : 0,
|
|
310
|
-
panoIndex: this.panoIndex,
|
|
311
|
-
floorIndex: this.floorIndex,
|
|
312
|
-
floorplanData: this.data,
|
|
313
|
-
lastPanoramaLongitude: this.lastPanoramaLongitude
|
|
314
|
-
});
|
|
315
|
-
if (this.app)
|
|
316
|
-
return this.app.$set(e);
|
|
317
|
-
this.app = new B({ target: this.container, intro: !0, props: e });
|
|
318
|
-
}
|
|
319
|
-
}
|
|
320
|
-
const st = (r, o) => new N(r, o);
|
|
321
|
-
export {
|
|
322
|
-
st as MapviewFloorplanPlugin,
|
|
323
|
-
st as default
|
|
324
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";var A=Object.defineProperty,P=Object.defineProperties;var y=Object.getOwnPropertyDescriptors;var S=Object.getOwnPropertySymbols;var C=Object.prototype.hasOwnProperty,M=Object.prototype.propertyIsEnumerable;var w=(o,n,e)=>n in o?A(o,n,{enumerable:!0,configurable:!0,writable:!0,value:e}):o[n]=e,l=(o,n)=>{for(var e in n||(n={}))C.call(n,e)&&w(o,e,n[e]);if(S)for(var e of S(n))M.call(n,e)&&w(o,e,n[e]);return o},m=(o,n)=>P(o,y(n));var s=(o,n,e)=>(w(o,typeof n!="symbol"?n+"":n,e),e);var f=(o,n,e)=>new Promise((t,i)=>{var a=d=>{try{r(e.next(d))}catch(u){i(u)}},h=d=>{try{r(e.throw(d))}catch(u){i(u)}},r=d=>d.done?t(d.value):Promise.resolve(d.value).then(a,h);r((e=e.apply(o,n)).next())});Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const j=require("three"),c=require("../../chunks/cjs/correctFiveState.4c8472bd.cjs.js"),I=require("../../chunks/cjs/equal.e9fcbd4e.cjs.js"),p=require("../../chunks/cjs/changeModelCanvasOpacity.8d84f111.cjs.js"),g=require("../../chunks/cjs/formatData.81e95011.cjs.js"),x=require("../../chunks/cjs/filter.cf9ebbb3.cjs.js"),_=require("../../chunks/cjs/BasePluginWithData.0a28882d.cjs.js");require("svelte/internal");require("svelte/easing");require("svelte/transition");require("svelte/store");require("svelte");require("../../chunks/cjs/BasePlugin.57e5204f.cjs.js");require("../../chunks/cjs/Subscribe.5398d5c6.cjs.js");function D(o){if(o&&o.__esModule)return o;const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(o){for(const e in o)if(e!=="default"){const t=Object.getOwnPropertyDescriptor(o,e);Object.defineProperty(n,e,t.get?t:{enumerable:!0,get:()=>o[e]})}}return n.default=o,Object.freeze(n)}const O=D(j);function k(o){const{latitude:n,longitude:e}=o,t=Math.abs(n-Math.PI/2)>5*Math.PI/180,i=e>5*(Math.PI/180)&&e<355*(Math.PI/180);return t||i}function L(o){const{latitude:n,longitude:e}=o,t=Math.abs(n-Math.PI/2)<10*Math.PI/180,i=e<30*(Math.PI/180)||e>330*(Math.PI/180);return t&&i}class T extends _.Controller{constructor(e,t){super(e);s(this,"name","modelFloorplanPlugin");s(this,"state");s(this,"data");s(this,"showState");s(this,"showPromise");s(this,"app");s(this,"panoIndex",0);s(this,"floorIndex",0);s(this,"selector");s(this,"showRejection");s(this,"wrapper");s(this,"container",document.createElement("div"));s(this,"lastPanoramaLongitude",0);s(this,"size",{width:0,height:0});s(this,"hasAddedEventListener",!1);s(this,"isHiddenByHideFunc",!1);s(this,"dispose",()=>{var e,t;this.removeEventListener(),(e=this.app)==null||e.$destroy(),this.app=void 0,(t=this.container)==null||t.remove(),this.data=void 0,this.wrapper=void 0,this.selector=void 0,this.hooks.emit("dispose")});s(this,"show",(...t)=>f(this,[...t],function*(e={}){if(!this.state.enabled||!this.showPromise&&this.state.visible)return;const i=e.userAction!==void 0?e.userAction:!0;this.updateState({visible:!0},i),this._show(e)}));s(this,"hide",(...t)=>f(this,[...t],function*(e={}){!this.state.enabled||(this.isHiddenByHideFunc=!0,this.state.visible!==!1&&(this.updateState({visible:!1},e.userAction||!0),this._hide(e)))}));s(this,"updateSize",()=>{if(!this.data||!c.checkShowState(this.five,this.showState)||!this.container||!this.wrapper)return;const{min:e,max:t}=this.data.bounding,i=t.x-e.x,a=t.y-e.y,h=this.state.config.attachedTo?{attachedTo:this.state.config.attachedTo}:void 0,r=p.getPxmm(this.five,this.wrapper,this.floorIndex,h),d=Math.ceil(i*r),u=Math.ceil(a*r);this.size.width===d&&this.size.height===u||(this.container.style.width=d+"px",this.container.style.height=u+"px",this.size={width:d,height:u})});s(this,"_disable",e=>{var i,a,h;const{userAction:t}=e;this.hooks.emit("disable",{userAction:t}),(i=this.showRejection)==null||i.call(this,c.FloorplanErrorType.BreakOffByDisable),this.showPromise=void 0,(a=this.app)==null||a.$destroy(),this.app=void 0,(h=this.container)==null||h.remove(),this.removeEventListener()});s(this,"_enable",e=>{const{userAction:t}=e;this.addEventListener(),this.wrapper&&(this.wrapper.append(this.container),this.hooks.emit("enable",{userAction:t}),this.state.visible&&this._show({userAction:t}))});s(this,"_show",e=>f(this,null,function*(){var h;if(!this.state.enabled)return;if(!((h=this.five.model)!=null&&h.loaded))throw new Error(c.FloorplanErrorType.ModelNotLoaded);if(!this.data)throw new Error(c.FloorplanErrorType.DataNotLoaded);this.isHiddenByHideFunc=!1;const t={floorIndex:this.floorIndex,modelOpacity:this.state.config.modelOpacity,immediately:!1,isAutoShow:!1,userAction:!0},i=l(l({},t),e),a=()=>f(this,null,function*(){this.hooks.emit("show",{userAction:i.userAction,auto:i.isAutoShow});let r=!1,d;this.showRejection=E=>{r=!0,d=E};const[u]=yield c.to(c.correctFiveState(this.five,this.showState,i.userAction));if(u)throw u;if(r)throw d?new Error(d):new Error(c.FloorplanErrorType.UnknownError);this.updateSize(),this.updatePosition(),this.floorIndex=i.floorIndex,this.five.model.show(this.floorIndex);const v=i.modelOpacity,b=i.immediately?0:c.SHOW_ANIME_DURATION;p.changeModelCanvasOpacity(this.five,v,b),this.render(b)});return this.showPromise=a().then(()=>{this.hooks.emit("showAnimationEnded",{auto:i.isAutoShow,userAction:i.userAction})}).catch(r=>{if(this.updateState({visible:!1},i.userAction),!i.isAutoShow&&r instanceof Error)throw r}).finally(()=>{this.showPromise=void 0,this.showRejection=void 0}),this.showPromise}));s(this,"_hide",e=>{var a;(a=this.showRejection)==null||a.call(this,c.FloorplanErrorType.BreakOffByHide),this.showPromise=void 0;const i=l(l({},{userAction:!0,isAutoHide:!1}),e);p.changeModelCanvasOpacity(this.five,1,0),this.hooks.emit("hide",{auto:i.isAutoHide,userAction:i.userAction}),this.render()});s(this,"handleClick",()=>{if(!this.state.visible)return;if(this.hooks.emit("click"))return!1});s(this,"onFiveModelLoaded",()=>{if(this.state.enabled===!1||this.wrapper||!this.selector)return;const e=this.selector instanceof Element?this.selector:document.querySelector(this.selector);if(!e)throw new Error("\u4E0D\u6B63\u786E\u7684\u7236\u5BB9\u5668\u9009\u62E9\u5668");this.wrapper=e,e.append(this.container)});s(this,"onFiveModeChange",e=>{e!==this.showState.mode&&(this.updateState({visible:!1},!1),this._hide({userAction:!1}))});s(this,"onFivePanoArrived",e=>{var t;!((t=this.five)!=null&&t.work)||(this.panoIndex=e,this.floorIndex=this.five.work.observers[e].floorIndex)});s(this,"onFiveCameraUpdate",(e,t)=>{if(!this.state.visible||this.showPromise)return;const i=this.five.getCurrentState();this.updatePosition(),this.updateSize(),k(i)&&(this.updateState({visible:!1},t),this._hide({userAction:t}))});s(this,"onFiveWantsPanGesture",(e,t)=>{if(this.five.getCurrentState().mode===this.showState.mode&&this.state.config.autoShowEnable!==!1){if(t&&this.state.visible)return this.five.updateCamera(this.showState,0),!1;if(t&&!this.state.visible){if(this.isHiddenByHideFunc)return;const i=this.five.getCurrentState();return i.mode!==this.showState.mode||this.state.visible?void 0:(L(i)&&(this.updateState({visible:!0},!0),this._show({isAutoShow:!0})),!1)}}});s(this,"onFiveWantsTapGesture",()=>this.handleClick());s(this,"onFiveWantsChangeMode",(e,t)=>{t==="Panorama"&&e===this.showState.mode&&(this.lastPanoramaLongitude=this.five.getCurrentState().longitude)});s(this,"onModelShownFloorChange",e=>{if(this.floorIndex!==e){if(e===null){const t=this.five.getCurrentState().panoIndex;this.floorIndex=this.five.work.observers[t].floorIndex;return}this.floorIndex=e,this.updateSize(),this.render()}});t!=null&&t.selector&&(this.selector=t.selector,console.warn("\u4E0D\u63A8\u8350\u7EE7\u7EED\u4F7F\u7528 params.selector \u914D\u7F6E\u7236\u5BB9\u5668\uFF0C\u8BF7\u4F7F\u7528 appendTo \u65B9\u6CD5")),this.showState={mode:"Mapview",longitude:0,latitude:Math.PI/2,fov:90};const i={northDesc:"\u5317",modelOpacity:1,hoverEnable:!0,compassEnable:!0,autoShowEnable:!0,ruleLabelsEnable:!0,roomLabelsEnable:!0,cameraImageUrl:g.CAMERA_IMAGE,attachedTo:p.FLOOR_PLAN_ATTACHED_TO.BOUNDING_CENTER,getLabelElement:void 0,adaptiveRoomLabelVisibleEnable:!0,getRoomAreaText:r=>(r/1e6).toFixed(1)+"\u33A1",getRuleDistanceText:r=>r.toString()},a=t?x.omit(t,["selector","scale"]):{},h=l(l({},i),a);this.state={enabled:!0,visible:!1,config:h},this.initContainer(),e.model.loaded?this.onFiveModelLoaded():e.once("modelLoaded",this.onFiveModelLoaded),e.once("dispose",this.dispose),this.addEventListener()}load(e,t,i=!0){return f(this,null,function*(){function a(v){return Object.prototype.hasOwnProperty.apply(v,["version"])}const h=e;h&&!h.version&&console.warn("\u4F20\u5165 serverData.data \u7684\u65B9\u5F0F\u540E\u7EED\u53EF\u80FD\u4E0D\u518D\u652F\u6301\uFF0C\u8BF7\u628A serverData \u6574\u4F53\u4F20\u5165 load \u51FD\u6570");const r=JSON.parse(JSON.stringify(e)),d=a(r)?r.data:r,u=this.data;this.data=yield g.formatData(d),this.hooks.emit("dataLoaded",this.data),this.hooks.emit("dataChange",this.data,u),t&&this.updateState(t,i),this.render()})}appendTo(e){if(this.wrapper=e,!!this.state.enabled)return e.appendChild(this.container),this.render(),this}enable(e={}){if(this.state.enabled)return;const t=e.userAction!==void 0?e.userAction:!0;this.updateState({enabled:!0},e.userAction||t),this._enable({userAction:t})}disable(e={}){if(!this.state.enabled)return;const t=e.userAction!==void 0?e.userAction:!0;this.updateState({enabled:!1},e.userAction||t),this._disable({userAction:t})}setState(e,t={}){const i=this.state,a=t.userAction!==void 0?t.userAction:!0;if(this.updateState(e,a),e.enabled!==void 0&&i.enabled!==e.enabled&&(e.enabled?this._enable({userAction:a}):this._disable({userAction:a})),e.visible!==void 0&&i.visible!==e.visible){const h={userAction:a};e.visible?this._show(h):this._hide(h)}}changeConfigs(e,t=!0){this.updateState({config:e},t),this.render()}updatePosition(){var r;const e=p.getAttachedY(this.five,this.floorIndex,this.state.config.attachedTo),t=(r=this.five.model)==null?void 0:r.bounding.getCenter(new O.Vector3).setY(e);if(!t)return;const i=t.clone().project(this.five.camera),a=(i.x+1)/2,h=-(i.y-1)/2;this.container.style.left=a*100+"%",this.container.style.top=h*100+"%"}formatData(e){return f(this,null,function*(){return yield g.formatData(e.data)})}updateState(e,t){const i=this.state,a=e.config?l(l({},i.config),e.config):i.config;this.state=m(l(l({},this.state),e),{config:a}),!I.equal(this.state,i,{deep:!0})&&this.hooks.emit("stateChange",{state:this.state,prevState:i,userAction:t})}initContainer(){this.container.classList.add("floorplan-plugin"),Object.assign(this.container.style,{position:"absolute",left:"50%",top:"50%",transform:"translate(-50%, -50%)",zIndex:10,pointerEvents:"none"}),this.five.addExtraElement(this.container)}addEventListener(){if(!this.state.enabled||this.hasAddedEventListener)return;const e=this.five;e.on("modeChange",this.onFiveModeChange),e.on("panoArrived",this.onFivePanoArrived),e.on("cameraUpdate",this.onFiveCameraUpdate),e.on("wantsPanGesture",this.onFiveWantsPanGesture),e.on("wantsTapGesture",this.onFiveWantsTapGesture),e.on("wantsChangeMode",this.onFiveWantsChangeMode),e.on("modelShownFloorChange",this.onModelShownFloorChange)}removeEventListener(){const e=this.five;this.hasAddedEventListener=!1,e.off("modelLoaded",this.onFiveModelLoaded),e.off("modeChange",this.onFiveModeChange),e.off("panoArrived",this.onFivePanoArrived),e.off("cameraUpdate",this.onFiveCameraUpdate),e.off("wantsPanGesture",this.onFiveWantsPanGesture),e.off("wantsTapGesture",this.onFiveWantsTapGesture),e.off("wantsChangeMode",this.onFiveWantsChangeMode),e.off("modelShownFloorChange",this.onModelShownFloorChange)}render(e){if(!this.state.enabled||!this.container||!this.data||this.size.width===0)return;const t=m(l({},this.state.config),{visible:this.state.visible,duration:e!=null?e:0,panoIndex:this.panoIndex,floorIndex:this.floorIndex,floorplanData:this.data,lastPanoramaLongitude:this.lastPanoramaLongitude});if(this.app)return this.app.$set(t);this.app=new p.Main({target:this.container,intro:!0,props:t})}}const F=(o,n)=>new T(o,n);exports.MapviewFloorplanPlugin=F;exports.default=F;
|