@realsee/dnalogel 2.21.0-dev.5 → 2.21.0-dev.7
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/components/index.js +329 -329
- package/dist/CSS3DRenderPlugin/Controller.d.ts +4 -1
- package/dist/PanoMeasurePlugin/Controller/EditController.d.ts +2 -13
- package/dist/PanoMeasurePlugin/Controller/index.d.ts +3 -0
- package/dist/PanoMeasurePlugin/Model/area.d.ts +1 -0
- package/dist/PanoMeasurePlugin/Model/index.d.ts +1 -0
- package/dist/PanoMeasurePlugin/Model/line.d.ts +2 -0
- package/dist/PanoMeasurePlugin/Model/polygon.d.ts +3 -0
- package/dist/PanoMeasurePlugin/Modules/UIController/index.d.ts +1 -0
- package/dist/PanoMeasurePlugin/Modules/UIController/style.d.ts +0 -8
- package/dist/PanoMeasurePlugin/typings/data.d.ts +2 -1
- package/dist/PanoMeasurePlugin/typings/event.type.d.ts +3 -0
- package/dist/PanoMeasurePlugin/utils/dom/base.d.ts +4 -0
- package/dist/PanoMeasurePlugin/utils/geometryUtil.d.ts +1 -1
- package/dist/PanoMeasurePlugin/utils/ndc2Screen.d.ts +2 -1
- package/dist/base/BasePlugin.d.ts +4 -1
- package/dist/components/PaintBrush/style.d.ts +1 -1
- package/dist/index.cjs.js +62 -62
- package/dist/index.js +6431 -6190
- package/dist/index.umd.js +55 -55
- package/dist/shared-utils/absoluteUrl.d.ts +5 -0
- package/dist/{PanoMeasurePlugin/utils → shared-utils}/getPointFromHammerEvent.d.ts +1 -1
- package/dist/shared-utils/index.d.ts +1 -1
- package/dist/shared-utils/three/PointSelector.d.ts +37 -3
- package/docs/assets/search.js +1 -1
- package/docs/classes/CSS3DRender.html +32 -31
- package/docs/classes/CruisePluginController.html +46 -43
- package/docs/classes/GuideLineItem.GuideLineItem.html +21 -20
- package/docs/classes/GuideLineModeItem.GuideLineModeItem.html +36 -35
- package/docs/classes/Magnifier.html +21 -20
- package/docs/classes/ModelRoomLabelController.html +12 -11
- package/docs/classes/Object3DHelperController.html +45 -42
- package/docs/classes/PaintBrush.html +16 -15
- package/docs/classes/PanoMeasurePluginLine.html +46 -25
- package/docs/classes/PanoMeasurePluginModel.html +42 -26
- package/docs/classes/PanoMeasurePluginPoint.html +15 -14
- package/docs/classes/PanoMeasurePluginPolyline.html +28 -27
- package/docs/classes/PanoTagPluginController.html +67 -64
- package/docs/classes/Util.BetterTween.html +10 -9
- package/docs/classes/Util.Interval.html +13 -12
- package/docs/classes/Util.Magnifier.html +19 -18
- package/docs/classes/Util.PointDomHelper.html +12 -11
- package/docs/classes/Util.PointHelper.html +12 -11
- package/docs/classes/Util.PointSelectorHelper.html +18 -17
- package/docs/classes/Util.Rectangle.html +14 -13
- package/docs/enums/CameraMovementEffect.html +8 -7
- package/docs/enums/ContentType.html +21 -20
- package/docs/enums/DIRECTION.html +10 -9
- package/docs/enums/DISPLAY_STRATEGY_TYPE.html +10 -9
- package/docs/enums/DimensionType.html +8 -7
- package/docs/enums/FLOOR_PLAN_ATTACHED_TO.html +9 -8
- package/docs/enums/ITEM_LABEL_PLUGIN_DISPLAY_STRATEGY_TYPE.html +10 -9
- package/docs/enums/PaintBrushTypeEnum.html +9 -8
- package/docs/enums/PointType.html +8 -7
- package/docs/enums/Rotation.html +9 -8
- package/docs/functions/CSS3DRenderPlugin.html +5 -4
- package/docs/functions/CameraMovementPlugin.html +5 -4
- package/docs/functions/CruisePlugin.html +5 -4
- package/docs/functions/GuideLinePlugin.html +6 -5
- package/docs/functions/ItemLabelPlugin.html +5 -4
- package/docs/functions/MapviewFloorplanPlugin.html +5 -4
- package/docs/functions/ModelChassisCompassPlugin.html +5 -4
- package/docs/functions/ModelEntryDoorGuidePlugin.html +5 -4
- package/docs/functions/ModelFloorplanPlugin.html +5 -4
- package/docs/functions/ModelItemLabelPlugin.html +5 -4
- package/docs/functions/ModelRoomLabelPlugin.html +5 -4
- package/docs/functions/ModelTVVideoPlugin.html +5 -4
- package/docs/functions/ModelViewPlugin.html +5 -4
- package/docs/functions/Object3DHelperPlugin.html +5 -4
- package/docs/functions/PanoCompassPlugin.html +5 -4
- package/docs/functions/PanoCursorRaycasterPlugin.html +5 -4
- package/docs/functions/PanoDoorLabelPlugin.html +5 -4
- package/docs/functions/PanoFloorplanRadarPlugin.html +5 -4
- package/docs/functions/PanoMeasurePlugin.html +5 -4
- package/docs/functions/PanoRulerPlugin.html +5 -4
- package/docs/functions/PanoRulerProPlugin.html +5 -4
- package/docs/functions/PanoSpatialTagPlugin.html +5 -4
- package/docs/functions/PanoTagPlugin.html +5 -4
- package/docs/functions/PanoVideoPlugin.html +5 -4
- package/docs/functions/TopviewFloorplanPlugin.html +5 -4
- package/docs/functions/Util.absoluteUrl.html +370 -0
- package/docs/functions/Util.getCoordsFromClient.html +6 -5
- package/docs/functions/Util.getCoordsFromElement.html +6 -5
- package/docs/functions/Util.getFrameTime.html +6 -5
- package/docs/functions/Util.getIntersectFromRelativePosition.html +6 -5
- package/docs/functions/Util.getRaycasterFromFivePointer.html +6 -5
- package/docs/functions/Util.isAbsoluteURL.html +6 -5
- package/docs/functions/Util.isModelLike.html +6 -5
- package/docs/functions/Util.isNil.html +6 -5
- package/docs/functions/Util.isPanoramaLike.html +6 -5
- package/docs/functions/Util.nextFrame.html +6 -5
- package/docs/functions/Util.notNil.html +6 -5
- package/docs/functions/Util.requestAnimationFrameInterval.html +6 -5
- package/docs/functions/Util.tweenProgress.html +6 -5
- package/docs/functions/Util.uuid.html +6 -5
- package/docs/functions/pluginFlag.html +6 -5
- package/docs/index.html +6 -5
- package/docs/interfaces/AddTagConfig.html +7 -6
- package/docs/interfaces/CSS3DRenderPluginEventMap.html +12 -11
- package/docs/interfaces/CSS3DRenderPluginState.html +9 -8
- package/docs/interfaces/CameraMovementPluginExportType.html +8 -7
- package/docs/interfaces/CruisePluginTypes.Config.html +9 -8
- package/docs/interfaces/CruisePluginTypes.CruiseKeyframe.html +13 -12
- package/docs/interfaces/CruisePluginTypes.EventMap.html +21 -20
- package/docs/interfaces/CruisePluginTypes.MoveAction.html +13 -12
- package/docs/interfaces/CruisePluginTypes.MoveWithKeyframesAction.html +15 -14
- package/docs/interfaces/CruisePluginTypes.MoveWithPanoIndexAction.html +15 -14
- package/docs/interfaces/CruisePluginTypes.PluginData.html +10 -9
- package/docs/interfaces/CruisePluginTypes.PluginServerData.html +8 -7
- package/docs/interfaces/CruisePluginTypes.PluginState.html +12 -11
- package/docs/interfaces/EventMap.html +16 -15
- package/docs/interfaces/FloorplanBounding.html +9 -8
- package/docs/interfaces/FloorplanData.html +11 -10
- package/docs/interfaces/FloorplanEntrance.html +12 -11
- package/docs/interfaces/FloorplanExtraObject.html +11 -10
- package/docs/interfaces/FloorplanExtraObject3D.html +9 -8
- package/docs/interfaces/FloorplanFloorData.html +10 -9
- package/docs/interfaces/FloorplanImagePosition.html +8 -7
- package/docs/interfaces/FloorplanObserver.html +10 -9
- package/docs/interfaces/FloorplanOutlineItem.html +10 -9
- package/docs/interfaces/FloorplanPosition.html +8 -7
- package/docs/interfaces/FloorplanRoomItem.html +14 -13
- package/docs/interfaces/FloorplanRoomLabelItem.html +8 -7
- package/docs/interfaces/FloorplanServerBounding.html +9 -8
- package/docs/interfaces/FloorplanServerComputedData.html +11 -10
- package/docs/interfaces/FloorplanServerData.html +8 -7
- package/docs/interfaces/FloorplanServerDoorItem.html +11 -10
- package/docs/interfaces/FloorplanServerDoorPosition.html +9 -8
- package/docs/interfaces/FloorplanServerEntrance.html +12 -11
- package/docs/interfaces/FloorplanServerFloorData.html +10 -9
- package/docs/interfaces/FloorplanServerImagePosition.html +8 -7
- package/docs/interfaces/FloorplanServerObserver.html +10 -9
- package/docs/interfaces/FloorplanServerOutlineItem.html +10 -9
- package/docs/interfaces/FloorplanServerPosition.html +8 -7
- package/docs/interfaces/FloorplanServerRoomItem.html +15 -14
- package/docs/interfaces/FloorplanServerRoomLabelItem.html +8 -7
- package/docs/interfaces/GuideLineModeItem.GuideLineTagContainer.html +9 -8
- package/docs/interfaces/GuideLinePluginType.CatmullRomCurve3.html +11 -10
- package/docs/interfaces/GuideLinePluginType.EventMap.html +14 -13
- package/docs/interfaces/GuideLinePluginType.GuideLineGeometryStyle.html +9 -8
- package/docs/interfaces/GuideLinePluginType.GuideLineItemContainer.html +7 -6
- package/docs/interfaces/GuideLinePluginType.GuideLineMaterialStyle.html +14 -13
- package/docs/interfaces/GuideLinePluginType.LineGeometriesConfig.html +9 -8
- package/docs/interfaces/GuideLinePluginType.ModelGuideLineStyle.html +19 -18
- package/docs/interfaces/GuideLinePluginType.ModelGuideLineTagData.html +8 -7
- package/docs/interfaces/GuideLinePluginType.PanoramaGuideLineStyle.html +19 -18
- package/docs/interfaces/GuideLinePluginType.PluginDataV2.html +6 -5
- package/docs/interfaces/GuideLinePluginType.PluginServerData.html +8 -7
- package/docs/interfaces/GuideLinePluginType.PluginState.html +9 -8
- package/docs/interfaces/GuideLinePluginType.Route.html +12 -11
- package/docs/interfaces/GuideLinePluginType.RouteConfig.html +10 -9
- package/docs/interfaces/HelperOffset.html +9 -8
- package/docs/interfaces/ImagePlaneGroup.html +7 -6
- package/docs/interfaces/ItemLabelPluginData.html +7 -6
- package/docs/interfaces/ItemLabelPluginExportReturnsType.html +12 -11
- package/docs/interfaces/ItemLabelPluginParametersType.html +10 -9
- package/docs/interfaces/MinMax.html +8 -7
- package/docs/interfaces/ModelChassisCompassPluginData.html +8 -7
- package/docs/interfaces/ModelChassisCompassPluginExportType.html +9 -8
- package/docs/interfaces/ModelChassisCompassPluginParameterType.html +8 -7
- package/docs/interfaces/ModelEntryDoorGuidePluginData.html +9 -8
- package/docs/interfaces/ModelEntryDoorGuidePluginExportType.html +9 -8
- package/docs/interfaces/ModelItemLabelPluginData.html +7 -6
- package/docs/interfaces/ModelItemLabelPluginExportReturnsType.html +12 -11
- package/docs/interfaces/ModelItemLabelPluginParametersType.html +8 -7
- package/docs/interfaces/ModelRoomLabelPluginData.html +7 -6
- package/docs/interfaces/ModelTVVideoPluginData.html +10 -9
- package/docs/interfaces/ModelTVVideoPluginExportType.html +9 -8
- package/docs/interfaces/ModelTVVideoPluginParameterType.html +7 -6
- package/docs/interfaces/ModelViewPluginExportType.html +12 -11
- package/docs/interfaces/Object3DHelperState.html +9 -8
- package/docs/interfaces/ObjectHelperControllers.html +10 -9
- package/docs/interfaces/PaintBrushAction.html +13 -12
- package/docs/interfaces/PaintBrushConfigs.html +13 -12
- package/docs/interfaces/PaintBrushState.html +11 -10
- package/docs/interfaces/PanoCursorRaycasterPluginExportType.html +11 -10
- package/docs/interfaces/PanoCursorRaycasterPluginParameterType.html +6 -5
- package/docs/interfaces/PanoMeasureParameterType.html +16 -15
- package/docs/interfaces/PanoMeasurePluginLineJson.html +9 -8
- package/docs/interfaces/PanoMeasurePluginOpenParameter.html +8 -7
- package/docs/interfaces/PanoMeasurePluginPointJson.html +8 -7
- package/docs/interfaces/PanoMeasurePluginPolylineJson.html +9 -8
- package/docs/interfaces/PanoRulerPluginExportType.html +11 -10
- package/docs/interfaces/PanoRulerPluginOptions.html +8 -7
- package/docs/interfaces/PanoRulerPluginParameterType.html +9 -8
- package/docs/interfaces/PanoRulerProPluginExportType.html +10 -9
- package/docs/interfaces/PanoRulerProPluginOptions.html +8 -7
- package/docs/interfaces/PanoRulerProPluginParameterType.html +8 -7
- package/docs/interfaces/PanoRulerProPluginState.html +9 -8
- package/docs/interfaces/PanoSpatialTagPluginContentEvent.html +6 -5
- package/docs/interfaces/PanoSpatialTagPluginContentReplacement.html +6 -5
- package/docs/interfaces/PanoSpatialTagPluginData.html +12 -11
- package/docs/interfaces/PanoSpatialTagPluginDataElement.html +11 -10
- package/docs/interfaces/PanoSpatialTagPluginExportType.html +14 -13
- package/docs/interfaces/PanoSpatialTagPluginOriginElement.html +11 -10
- package/docs/interfaces/PanoSpatialTagPluginParameterType.html +14 -13
- package/docs/interfaces/PanoSpatialTagPluginPointElement.html +12 -11
- package/docs/interfaces/PanoSpatialTagPluginTagElement.html +11 -10
- package/docs/interfaces/PanoVideoPluginType.LoadParams.html +7 -6
- package/docs/interfaces/PanoVideoPluginType.PanoVideoItem.html +9 -8
- package/docs/interfaces/PanoVideoPluginType.PluginData.html +7 -6
- package/docs/interfaces/PanoVideoPluginType.PluginEventMap.html +10 -9
- package/docs/interfaces/PanoVideoPluginType.PluginState.html +7 -6
- package/docs/interfaces/PanoVideoPluginType.VideoItem.html +9 -8
- package/docs/interfaces/PanoVideoPluginType.VideoMeshParams.html +11 -10
- package/docs/interfaces/Point.html +9 -8
- package/docs/interfaces/Room.html +10 -9
- package/docs/interfaces/RoomInfo.html +8 -7
- package/docs/interfaces/RoomLabel.html +15 -14
- package/docs/interfaces/RoomRules.html +6 -5
- package/docs/interfaces/Rooms.html +6 -5
- package/docs/interfaces/Scissor.html +10 -9
- package/docs/interfaces/State.html +9 -8
- package/docs/interfaces/TagCacheInterface.html +13 -12
- package/docs/interfaces/TagConfig.html +14 -13
- package/docs/interfaces/TagGLTFObjectGroup.html +7 -6
- package/docs/interfaces/TagIconUrl.html +13 -12
- package/docs/interfaces/TagObjectGroup.html +7 -6
- package/docs/interfaces/TagStyle.html +7 -6
- package/docs/interfaces/Tags.html +10 -9
- package/docs/interfaces/TemporaryState.html +7 -6
- package/docs/interfaces/Util.MagnifierParameter.html +12 -11
- package/docs/interfaces/Util.MouseGroupParameter.html +9 -8
- package/docs/interfaces/Util.PointIntersection.html +9 -8
- package/docs/modules/CruisePluginTypes.html +6 -5
- package/docs/modules/GuideLineItem.html +6 -5
- package/docs/modules/GuideLineModeItem.html +6 -5
- package/docs/modules/GuideLinePluginType.html +6 -5
- package/docs/modules/PanoVideoPluginType.html +6 -5
- package/docs/modules/Util.html +7 -5
- package/docs/modules.html +5 -4
- package/docs/types/ArrayPosition.html +6 -5
- package/docs/types/AudioAppearance.html +6 -5
- package/docs/types/AudioTagTypeConfigKey.html +6 -5
- package/docs/types/CSS3DRenderExportType.html +6 -5
- package/docs/types/CSS3DRenderPluginExportType.html +6 -5
- package/docs/types/CSS3DRenderPluginParameterType.html +6 -5
- package/docs/types/ClassFunctionParameters.html +6 -5
- package/docs/types/Color.html +6 -5
- package/docs/types/ContentTypeConfigKey.html +6 -5
- package/docs/types/ContentTypeConfigKeySplit.html +6 -5
- package/docs/types/ContentTypeMap.html +6 -5
- package/docs/types/Create3DDomContainerReturnType.html +6 -5
- package/docs/types/Create3DElementReturnType.html +6 -5
- package/docs/types/CruisePluginExportType.html +6 -5
- package/docs/types/CruisePluginTypes.CruiseData.html +6 -5
- package/docs/types/CruisePluginTypes.MoveEffect.html +6 -5
- package/docs/types/DeprecatedMediaPlaneProperty.html +6 -5
- package/docs/types/DeprecatedTagProperty.html +6 -5
- package/docs/types/Direction-1.html +6 -5
- package/docs/types/Direction4.html +6 -5
- package/docs/types/ElementRenderer.html +6 -5
- package/docs/types/FloorplanRuleLabels.html +6 -5
- package/docs/types/FloorplanServerRuleLabels.html +6 -5
- package/docs/types/GuideLinePluginExportType.html +6 -5
- package/docs/types/GuideLinePluginType.GuideLineItem.html +6 -5
- package/docs/types/GuideLinePluginType.GuideLineItemEventMap.html +6 -5
- package/docs/types/GuideLinePluginType.GuideLineModeItemMode.html +6 -5
- package/docs/types/GuideLinePluginType.GuideLineStyle.html +6 -5
- package/docs/types/GuideLinePluginType.ModelGuideLineTag.html +6 -5
- package/docs/types/GuideLinePluginType.PathItem.html +6 -5
- package/docs/types/GuideLinePluginType.PluginData.html +6 -5
- package/docs/types/HelperEventMap.html +6 -5
- package/docs/types/LoadTagConfig.html +6 -5
- package/docs/types/MapviewFloorplanPluginParameterType.html +6 -5
- package/docs/types/MapviewFloorplanPluginReturnType.html +6 -5
- package/docs/types/MediaData.html +6 -5
- package/docs/types/MediaStore.html +6 -5
- package/docs/types/ModelEntryDoorGuidePluginParameterType.html +6 -5
- package/docs/types/ModelFloorplanPluginParameterType.html +6 -5
- package/docs/types/ModelFloorplanPluginReturnType.html +6 -5
- package/docs/types/ModelRoomLabelPluginParameters.html +6 -5
- package/docs/types/ModelRoomLabelPluginReturnType.html +6 -5
- package/docs/types/MoveArgs.html +6 -5
- package/docs/types/MoveOpts.html +6 -5
- package/docs/types/Object3DHelperEventMap.html +6 -5
- package/docs/types/ObjectFit.html +6 -5
- package/docs/types/PaintBrushEventMap.html +6 -5
- package/docs/types/PanoCompassPluginData.html +6 -5
- package/docs/types/PanoCompassPluginExportType.html +6 -5
- package/docs/types/PanoCompassPluginParameterType.html +6 -5
- package/docs/types/PanoFloorplanRadarPluginParameterType.html +6 -5
- package/docs/types/PanoFloorplanRadarPluginReturnType.html +6 -5
- package/docs/types/PanoIndex.html +6 -5
- package/docs/types/PanoMeasurePluginEvent.html +6 -5
- package/docs/types/PanoMeasureReturnType.html +6 -5
- package/docs/types/PanoSpatialTagPluginId.html +6 -5
- package/docs/types/PanoTagPluginExportInterface.html +6 -5
- package/docs/types/PanoTagPluginParamsInterface.html +6 -5
- package/docs/types/PanoVideoPluginParameterType.html +6 -5
- package/docs/types/PanoVideoPluginReturnType.html +6 -5
- package/docs/types/PartialObjectDeep.html +6 -5
- package/docs/types/PickTagContentTypeInContentTypeConfigKey.html +6 -5
- package/docs/types/PlaneTag.html +6 -5
- package/docs/types/Point2DTag.html +6 -5
- package/docs/types/Point3DTag.html +6 -5
- package/docs/types/PointTag.html +6 -5
- package/docs/types/PointTagInstance.html +6 -5
- package/docs/types/Position.html +6 -5
- package/docs/types/RotateArgs.html +6 -5
- package/docs/types/RotateOpts.html +6 -5
- package/docs/types/RuleLabelsKey.html +6 -5
- package/docs/types/RuleLabelsValue.html +6 -5
- package/docs/types/StickType.html +6 -5
- package/docs/types/Tag.html +6 -5
- package/docs/types/Tag2D.html +6 -5
- package/docs/types/Tag3D.html +6 -5
- package/docs/types/TagContentType.html +6 -5
- package/docs/types/TagDimensionType.html +6 -5
- package/docs/types/TagElement.html +6 -5
- package/docs/types/TagEvents.html +6 -5
- package/docs/types/TagGLTFObject.html +6 -5
- package/docs/types/TagHooks.html +6 -5
- package/docs/types/TagId.html +6 -5
- package/docs/types/TagInstance.html +6 -5
- package/docs/types/TagPointType.html +6 -5
- package/docs/types/TagRendererMap.html +6 -5
- package/docs/types/TopviewFloorplanPluginParameterType.html +6 -5
- package/docs/types/TopviewFloorplanPluginReturnType.html +6 -5
- package/docs/types/WorkCode.html +6 -5
- package/docs/variables/FLOOR_TYPE_MAP.html +6 -5
- package/docs/variables/PLUGIN.html +6 -5
- package/docs/variables/ROOM_FETILE_TYPE_MAP.html +6 -5
- package/docs/variables/ROOM_TYPE_MAP.html +6 -5
- package/docs/variables/itemLabelPluginServerParams.html +6 -5
- package/docs/variables/modelItemLabelPluginServerParams.html +6 -5
- package/docs/variables/modelRoomLabelPluginServerParams.html +6 -5
- package/libs/CSS3DRenderPlugin/Controller.d.ts +4 -1
- package/libs/CSS3DRenderPlugin/Controller.js +31 -28
- package/libs/CSS3DRenderPlugin/index.js +1 -1
- package/libs/CruisePlugin/Controller.js +1 -1
- package/libs/CruisePlugin/index.js +1 -1
- package/libs/GuideLinePlugin/Components/Tag.js +68 -68
- package/libs/GuideLinePlugin/Controller.js +1 -1
- package/libs/GuideLinePlugin/GuideLineItem.js +1 -1
- package/libs/GuideLinePlugin/GuideLineModeItem/index.js +2 -2
- package/libs/GuideLinePlugin/GuideLineModeItem.js +1 -1
- package/libs/GuideLinePlugin/index.js +1 -1
- package/libs/ItemLabelPlugin/ItemLabelItem.js +82 -82
- package/libs/ModelTVVideoPlugin/Plugin.js +30 -29
- package/libs/ModelTVVideoPlugin/index.js +4 -3
- package/libs/Object3DHelperPlugin/Controller.js +1 -1
- package/libs/Object3DHelperPlugin/index.js +1 -1
- package/libs/PanoCompassPlugin/Controller.js +20 -20
- package/libs/PanoCompassPlugin/index.js +1 -1
- package/libs/PanoDoorLabelPlugin/BaseController.js +1 -1
- package/libs/PanoDoorLabelPlugin/Controller.js +1 -1
- package/libs/PanoDoorLabelPlugin/DoorLabelItem.js +60 -60
- package/libs/PanoDoorLabelPlugin/index.js +1 -1
- package/libs/PanoMeasurePlugin/Components/Controller1.js +225 -155
- package/libs/PanoMeasurePlugin/Controller/EditController.d.ts +2 -13
- package/libs/PanoMeasurePlugin/Controller/EditController.js +142 -110
- package/libs/PanoMeasurePlugin/Controller/WatchController.js +1 -1
- package/libs/PanoMeasurePlugin/Controller/index.d.ts +3 -0
- package/libs/PanoMeasurePlugin/Controller/index.js +63 -66
- package/libs/PanoMeasurePlugin/Model/area.d.ts +1 -0
- package/libs/PanoMeasurePlugin/Model/area.js +10 -5
- package/libs/PanoMeasurePlugin/Model/index.d.ts +1 -0
- package/libs/PanoMeasurePlugin/Model/index.js +47 -39
- package/libs/PanoMeasurePlugin/Model/line.d.ts +2 -0
- package/libs/PanoMeasurePlugin/Model/line.js +6 -0
- package/libs/PanoMeasurePlugin/Model/polygon.d.ts +3 -0
- package/libs/PanoMeasurePlugin/Model/polygon.js +17 -14
- package/libs/PanoMeasurePlugin/Modules/UIController/index.d.ts +1 -0
- package/libs/PanoMeasurePlugin/Modules/UIController/index.js +16 -14
- package/libs/PanoMeasurePlugin/Modules/UIController/style.d.ts +0 -8
- package/libs/PanoMeasurePlugin/Modules/UIController/style.js +16 -24
- package/libs/PanoMeasurePlugin/index.js +19 -17
- package/libs/PanoMeasurePlugin/typings/data.d.ts +2 -1
- package/libs/PanoMeasurePlugin/typings/event.type.d.ts +3 -0
- package/libs/PanoMeasurePlugin/utils/dom/areaDom.js +36 -15
- package/libs/PanoMeasurePlugin/utils/dom/base.d.ts +4 -0
- package/libs/PanoMeasurePlugin/utils/dom/base.js +37 -31
- package/libs/PanoMeasurePlugin/utils/dom/distanceItem.js +38 -23
- package/libs/PanoMeasurePlugin/utils/geometryUtil.d.ts +1 -1
- package/libs/PanoMeasurePlugin/utils/geometryUtil.js +15 -13
- package/libs/PanoMeasurePlugin/utils/ndc2Screen.d.ts +2 -1
- package/libs/PanoSpatialTagPlugin/Plugin.js +1 -1
- package/libs/PanoSpatialTagPlugin/index.js +1 -1
- package/libs/PanoTagPlugin/controller/TagCache.js +1 -1
- package/libs/PanoTagPlugin/controller/TagComputer.js +1 -1
- package/libs/PanoTagPlugin/controller/TagRender.js +1 -1
- package/libs/PanoTagPlugin/controller/TagUtil.js +1 -1
- package/libs/PanoTagPlugin/controller/index.js +1 -1
- package/libs/PanoTagPlugin/index.js +1 -1
- package/libs/PanoVideoPlugin/Controller.js +1 -1
- package/libs/PanoVideoPlugin/index.js +1 -1
- package/libs/base/BasePlugin.d.ts +4 -1
- package/libs/base/BasePlugin.js +14 -11
- package/libs/components/PaintBrush/style.d.ts +1 -1
- package/libs/components/PaintBrush/style.js +4 -4
- package/libs/floorplan/MapviewFloorplanPlugin/Controller.js +1 -1
- package/libs/floorplan/MapviewFloorplanPlugin/index.js +1 -1
- package/libs/floorplan/ModelFloorplanPlugin/Controller.js +1 -1
- package/libs/floorplan/ModelFloorplanPlugin/index.js +1 -1
- package/libs/floorplan/PanoFloorplanRadarPlugin/Controller.js +1 -1
- package/libs/floorplan/PanoFloorplanRadarPlugin/index.js +1 -1
- package/libs/floorplan/TopviewFloorplanPlugin/Controller.js +1 -1
- package/libs/floorplan/TopviewFloorplanPlugin/index.js +1 -1
- package/libs/index.js +4 -4
- package/libs/shared-utils/absoluteUrl.d.ts +5 -0
- package/libs/shared-utils/absoluteUrl.js +10 -0
- package/libs/{PanoMeasurePlugin/utils → shared-utils}/getPointFromHammerEvent.d.ts +1 -1
- package/libs/shared-utils/index.d.ts +1 -1
- package/libs/shared-utils/index.js +17 -16
- package/libs/shared-utils/logger.js +1 -1
- package/libs/shared-utils/three/Magnifier.js +6 -5
- package/libs/shared-utils/three/PointSelector.d.ts +37 -3
- package/libs/shared-utils/three/PointSelector.js +84 -36
- package/libs/vendor/svelte/internal/index.js +392 -345
- package/package.json +1 -1
- package/dist/shared-utils/isAbsoluteURL.d.ts +0 -1
- package/libs/shared-utils/isAbsoluteURL.d.ts +0 -1
- package/libs/shared-utils/isAbsoluteURL.js +0 -6
- /package/dist/{PanoMeasurePlugin/utils → shared-utils}/getIntersectionFromEvent.d.ts +0 -0
- /package/libs/{PanoMeasurePlugin/utils → shared-utils}/getIntersectionFromEvent.d.ts +0 -0
- /package/libs/{PanoMeasurePlugin/utils → shared-utils}/getIntersectionFromEvent.js +0 -0
- /package/libs/{PanoMeasurePlugin/utils → shared-utils}/getPointFromHammerEvent.js +0 -0
|
@@ -1,15 +1,13 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import C from "hammerjs";
|
|
1
|
+
var y = Object.defineProperty;
|
|
2
|
+
var C = (p, a, t) => a in p ? y(p, a, { enumerable: !0, configurable: !0, writable: !0, value: t }) : p[a] = t;
|
|
3
|
+
var s = (p, a, t) => (C(p, typeof a != "symbol" ? a + "" : a, t), t);
|
|
5
4
|
import k from "../Model/line.js";
|
|
6
5
|
import c from "../Model/point.js";
|
|
7
|
-
import { throttle as
|
|
8
|
-
import
|
|
9
|
-
import {
|
|
10
|
-
import
|
|
11
|
-
import v from "../
|
|
12
|
-
import P from "../utils/isIntersecting.js";
|
|
6
|
+
import { throttle as S } from "../../shared-utils/throttle.js";
|
|
7
|
+
import L from "./BaseController.js";
|
|
8
|
+
import { Polyline as f } from "../Model/polyline.js";
|
|
9
|
+
import u from "../Model/area.js";
|
|
10
|
+
import v from "../utils/isIntersecting.js";
|
|
13
11
|
import { PointSelector as A } from "../../shared-utils/three/PointSelector.js";
|
|
14
12
|
import "../../shared-utils/uuid.js";
|
|
15
13
|
import "../utils/line.js";
|
|
@@ -22,7 +20,6 @@ import "../utils/dom/base.js";
|
|
|
22
20
|
import "../utils/isNDCPointInScreen.js";
|
|
23
21
|
import "../../shared-utils/removeArrayItem.js";
|
|
24
22
|
import "../utils/ironbox.js";
|
|
25
|
-
import "../utils/getPointFromHammerEvent.js";
|
|
26
23
|
import "../Model/polygon.js";
|
|
27
24
|
import "../../shared-utils/three/IObject3D.js";
|
|
28
25
|
import "../utils/generatePolygonGeometry.js";
|
|
@@ -32,6 +29,7 @@ import "../utils/geometryUtil.js";
|
|
|
32
29
|
import "../../shared-utils/three/centerPoint.js";
|
|
33
30
|
import "../../shared-utils/three/PointSelectorHelper.js";
|
|
34
31
|
import "../../shared-utils/three/Magnifier.js";
|
|
32
|
+
import "hammerjs";
|
|
35
33
|
import "../../shared-utils/three/getIntersect.js";
|
|
36
34
|
import "../../shared-utils/three/PointHelper.js";
|
|
37
35
|
import "../../shared-utils/three/Assets/index.js";
|
|
@@ -54,45 +52,48 @@ import "../../CSS3DRenderPlugin/utils/three/CSS3DScene.js";
|
|
|
54
52
|
import "../../CSS3DRenderPlugin/utils/three/CSS3DGroup.js";
|
|
55
53
|
import "../../CSS3DRenderPlugin/utils/waitFiveModelLoaded.js";
|
|
56
54
|
import "../../CSS3DRenderPlugin/utils/generateBehindFiveElement.js";
|
|
57
|
-
import "../../shared-utils/
|
|
55
|
+
import "../../shared-utils/absoluteUrl.js";
|
|
58
56
|
import "../../shared-utils/animationFrame/BetterTween.js";
|
|
59
57
|
import "../../shared-utils/animationFrame/index.js";
|
|
60
58
|
import "../../shared-utils/isTouchDevice.js";
|
|
61
|
-
|
|
59
|
+
import "../../shared-utils/getIntersectionFromEvent.js";
|
|
60
|
+
import "../../shared-utils/getPointFromHammerEvent.js";
|
|
61
|
+
const l = () => !1;
|
|
62
|
+
class Ee extends L {
|
|
62
63
|
constructor(t) {
|
|
63
|
-
var
|
|
64
|
+
var e;
|
|
64
65
|
super(t);
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
o(this, "hasAppendDashed", !1);
|
|
71
|
-
o(this, "fiveElement");
|
|
66
|
+
s(this, "type", "edit");
|
|
67
|
+
s(this, "polyline");
|
|
68
|
+
s(this, "area");
|
|
69
|
+
s(this, "hasAppendDashed", !1);
|
|
70
|
+
s(this, "fiveElement");
|
|
72
71
|
/** 上一个端点位置 */
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
o(this, "pointSelector");
|
|
72
|
+
s(this, "lastPoint", null);
|
|
73
|
+
s(this, "pointSelector");
|
|
76
74
|
/** 根据 intersection 更新放大镜和吸附点 */
|
|
77
|
-
|
|
78
|
-
var s;
|
|
79
|
-
const e = t.point;
|
|
80
|
-
(s = this.pressPoint) == null || s.position.copy(e), this.updateDashed(), this.five.needsRender = !0;
|
|
81
|
-
}, 20));
|
|
75
|
+
s(this, "onIntersectionUpdate", S(() => this.updateDashed(), 20));
|
|
82
76
|
/** 撤销编辑 */
|
|
83
|
-
|
|
77
|
+
s(this, "revoke", () => {
|
|
84
78
|
this.currentMeasureType === "area" ? this.revokeArea() : this.currentMeasureType === "line" && this.revokeLine();
|
|
85
79
|
});
|
|
86
80
|
/**
|
|
87
81
|
* @description: 测面积的撤销功能
|
|
88
82
|
*/
|
|
89
|
-
|
|
90
|
-
this.area.points.length !== 0
|
|
83
|
+
s(this, "revokeArea", () => {
|
|
84
|
+
if (this.area.points.length !== 0) {
|
|
85
|
+
if (this.area.popPoint(), this.area.points.length === 0) {
|
|
86
|
+
this.lastPoint = null, this.hasAppendDashed = !1, this.dashed.remove(), this.five.needsRender = !0, this.hook.emit("revoke", { isEmpty: !0 });
|
|
87
|
+
return;
|
|
88
|
+
} else
|
|
89
|
+
this.lastPoint = new c(this.area.points[this.area.points.length - 1]), this.updateDashed();
|
|
90
|
+
this.five.needsRender = !0;
|
|
91
|
+
}
|
|
91
92
|
});
|
|
92
93
|
/**
|
|
93
94
|
* @description: 测距的撤销功能
|
|
94
95
|
*/
|
|
95
|
-
|
|
96
|
+
s(this, "revokeLine", (t) => {
|
|
96
97
|
const e = t || this.polyline;
|
|
97
98
|
if (e.lines.length === 0 && this.lastPoint) {
|
|
98
99
|
this.lastPoint = null, this.hasAppendDashed = !1, this.dashed.remove(), this.hook.emit("anchorChange", null), this.hook.emit("editedDashedLineChange", null), this.five.needsRender = !0;
|
|
@@ -100,140 +101,171 @@ class we extends I {
|
|
|
100
101
|
}
|
|
101
102
|
if (e.lines.length === 0 && !this.lastPoint || !this.lastPoint)
|
|
102
103
|
return;
|
|
103
|
-
const
|
|
104
|
-
|
|
104
|
+
const i = e.lines[e.lines.length - 1], o = i.findAnotherPoint(this.lastPoint);
|
|
105
|
+
o && (this.lastPoint = o, this.hook.emit("anchorChange", o.position), this.group.remove(i.mesh), e.removeLine(i), i.distanceItem.remove(), this.updateDashed(), this.five.needsRender = !0);
|
|
105
106
|
});
|
|
106
|
-
|
|
107
|
-
|
|
107
|
+
// private wantsTapGesture = (raycaster): false => {
|
|
108
|
+
// if (this.editParams.pointSelectorMode === 'cursor') return false // 鼠标选点的话点击动作为选点,所有没有下面的点击删除动作
|
|
109
|
+
// // ================================= 这是选择面的逻辑 =================================
|
|
110
|
+
// const intersections = this.model.areas
|
|
111
|
+
// .map((area) => raycaster.intersectObject(area.polygon, true)[0]) // 获取所有的交点
|
|
112
|
+
// .sort((a, b) => a.distance - b.distance) // 按照距离排序
|
|
113
|
+
// const intersectionObject = intersections[0]?.object.parent
|
|
114
|
+
// if (intersectionObject.isPolygonMesh) {
|
|
115
|
+
// const area = this.model.areas.find((area) => area.polygon === intersectionObject)
|
|
116
|
+
// if (area) {
|
|
117
|
+
// const { x, y } = intersections[0].point.clone().project(this.five.camera)
|
|
118
|
+
// const left = `${((x + 1) / 2) * 100}%`
|
|
119
|
+
// const top = `${((-y + 1) / 2) * 100}%`
|
|
120
|
+
// this.chooseArea(area, { left, top })
|
|
121
|
+
// }
|
|
122
|
+
// }
|
|
123
|
+
// return false
|
|
124
|
+
// // // ================================= 这后面是之前的选择线的逻辑 =================================
|
|
125
|
+
// // const [target] = this.five.model.intersectRaycaster(raycaster)
|
|
126
|
+
// // if (!target) return
|
|
127
|
+
// // const camera = this.five.camera
|
|
128
|
+
// // const ndcTarget = target.point.clone().project(camera)
|
|
129
|
+
// // const screenWidth = this.container.clientWidth
|
|
130
|
+
// // const screenHeight = this.container.clientHeight
|
|
131
|
+
// // const targetScreenPosition = new Vector2(ndcTarget.x * screenWidth, ndcTarget.y * screenHeight)
|
|
132
|
+
// // // 把线的端点全部映射到屏幕上,过滤掉不在视野内的线,同时乘以屏幕宽 & 高
|
|
133
|
+
// // const screenLines = this.model
|
|
134
|
+
// // .getAllLines()
|
|
135
|
+
// // .map((line) => {
|
|
136
|
+
// // const [startPoint, endPoint] = line.points
|
|
137
|
+
// // const ndcStartPoint = startPoint.position.clone().project(camera)
|
|
138
|
+
// // const ndcEndPoint = endPoint.position.clone().project(camera)
|
|
139
|
+
// // if (!isNDCPointInScreen(ndcStartPoint) && !isNDCPointInScreen(ndcEndPoint)) return null
|
|
140
|
+
// // const startScreenPosition = new Vector2(ndcStartPoint.x * screenWidth, ndcStartPoint.y * screenHeight)
|
|
141
|
+
// // const endScreenPosition = new Vector2(ndcEndPoint.x * screenWidth, ndcEndPoint.y * screenHeight)
|
|
142
|
+
// // return { id: line.id, points: [startScreenPosition, endScreenPosition] }
|
|
143
|
+
// // })
|
|
144
|
+
// // .filter((line) => !!line) as { id: string; points: Vector2[] }[]
|
|
145
|
+
// // if (screenLines.length === 0) return
|
|
146
|
+
// // // 找这些线距离鼠标点击位置最近的线
|
|
147
|
+
// // const distanceLines = screenLines
|
|
148
|
+
// // .map((line) => {
|
|
149
|
+
// // const closestPoint = closestPointOnLine(targetScreenPosition, line.points)
|
|
150
|
+
// // return { id: line.id, distance: closestPoint.distanceTo(targetScreenPosition) }
|
|
151
|
+
// // })
|
|
152
|
+
// // .sort((a, b) => a.distance - b.distance)
|
|
153
|
+
// // const closestScreenLine = distanceLines[0]
|
|
154
|
+
// // if (closestScreenLine.distance > 20) return
|
|
155
|
+
// // const closestLine = this.model.getAllLines().find(({ id }) => id === closestScreenLine.id)
|
|
156
|
+
// // if (!closestLine) return
|
|
157
|
+
// // this.chooseLine(closestLine)
|
|
158
|
+
// // return false
|
|
159
|
+
// }
|
|
160
|
+
s(this, "onMouseLeave", () => {
|
|
161
|
+
var t;
|
|
162
|
+
this.lastPoint && ((t = this.pointSelector.position) == null || t.point.copy(this.lastPoint.position), this.updateDashed()), this.area.hideArea();
|
|
108
163
|
});
|
|
109
164
|
/** 编辑线条发生改变时通知外部 */
|
|
110
|
-
|
|
165
|
+
s(this, "onLineChanged", () => {
|
|
111
166
|
this.hook.emit("editedPolylineChange", this.polyline);
|
|
112
167
|
});
|
|
113
|
-
o(this, "onPress", (t) => {
|
|
114
|
-
const [e] = f(this.five, t);
|
|
115
|
-
if (!(e != null && e.face))
|
|
116
|
-
return;
|
|
117
|
-
const s = new c(e.point);
|
|
118
|
-
this.pressPoint = s, this.onIntersectionUpdate(e);
|
|
119
|
-
});
|
|
120
|
-
/**
|
|
121
|
-
* 1. 如果之前没有长按行为「即没有长按点时」-> 滑动全景
|
|
122
|
-
* 2. 如果有长按点,把长按点位置更新为当前位置
|
|
123
|
-
*/
|
|
124
|
-
o(this, "onPan", (t) => {
|
|
125
|
-
if (!this.pressPoint)
|
|
126
|
-
return;
|
|
127
|
-
const [e] = f(this.five, t);
|
|
128
|
-
e != null && e.face && this.onIntersectionUpdate(e);
|
|
129
|
-
});
|
|
130
|
-
o(this, "onPanEnd", () => {
|
|
131
|
-
this.pressPoint && this.onTap();
|
|
132
|
-
});
|
|
133
168
|
/**
|
|
134
169
|
* 1. 如果存在上一个点,需要绘制当前点到上一个点的连线
|
|
135
170
|
* 2. 把上一个点的位置更新为当前点的位置
|
|
136
171
|
* 3. 清除 pointSelector
|
|
137
172
|
*/
|
|
138
|
-
|
|
139
|
-
var
|
|
173
|
+
s(this, "onSelect", () => {
|
|
174
|
+
var o, h, d, m;
|
|
140
175
|
this.hasAppendDashed || (this.dashed.distanceItem.appendTo(this.container), this.group.add(this.dashed.mesh), this.currentMeasureType === "area" && this.group.add(this.perpendicularDashed.mesh)), this.hasAppendDashed = !0;
|
|
141
176
|
const t = (() => {
|
|
177
|
+
var n, r;
|
|
142
178
|
if (this.currentMeasureType === "area")
|
|
143
|
-
return this.area.projectPoint(this.pointSelector.position.point);
|
|
179
|
+
return this.area.projectPoint((n = this.pointSelector.position) == null ? void 0 : n.point);
|
|
144
180
|
if (this.currentMeasureType === "line")
|
|
145
|
-
return this.pointSelector.position.point;
|
|
181
|
+
return (r = this.pointSelector.position) == null ? void 0 : r.point;
|
|
146
182
|
})();
|
|
147
183
|
if (!t)
|
|
148
184
|
return;
|
|
149
|
-
const e = new c(t),
|
|
185
|
+
const e = new c(t), i = this.lastPoint;
|
|
150
186
|
if (this.lastPoint = e, this.currentMeasureType === "line") {
|
|
151
|
-
if (e &&
|
|
152
|
-
const
|
|
153
|
-
|
|
187
|
+
if (e && i) {
|
|
188
|
+
const r = new k(i, e, this.model);
|
|
189
|
+
r.distanceItem.setCanSelect(!1), r.distanceItem.appendTo(this.container), this.polyline.addLine(r), this.group.add(r.mesh), r.distanceItem.update(this.five);
|
|
154
190
|
}
|
|
155
|
-
const n = (
|
|
156
|
-
typeof n == "number" && (this.polyline.getPointLength() >= n ?
|
|
191
|
+
const n = (h = (o = this.editParams) == null ? void 0 : o.autoEndConfig) == null ? void 0 : h.line;
|
|
192
|
+
typeof n == "number" && (this.polyline.getPointLength() >= n ? this.complete() : this.polyline.getPointLength() === n - 1 && this.hook.emit("readyComplete"));
|
|
157
193
|
} else if (this.currentMeasureType === "area") {
|
|
158
194
|
this.area.addPoints(e.position);
|
|
159
|
-
const n = (
|
|
160
|
-
typeof n == "number" && (this.area.points.length >= n ?
|
|
161
|
-
five: this.five,
|
|
162
|
-
model: this.model,
|
|
163
|
-
meshContainer: this.group,
|
|
164
|
-
domContainer: this.container
|
|
165
|
-
}), this.model.addArea(this.area), this.lastPoint = void 0) : this.area.points.length === n - 1 && this.hook.emit("readyComplete"));
|
|
195
|
+
const n = (m = (d = this.editParams) == null ? void 0 : d.autoEndConfig) == null ? void 0 : m.area;
|
|
196
|
+
typeof n == "number" && (this.area.points.length >= n ? this.complete() : this.area.points.length === n - 1 && this.hook.emit("readyComplete"));
|
|
166
197
|
}
|
|
167
|
-
this.
|
|
198
|
+
this.updateDashed(), this.five.needsRender = !0, this.hook.emit("anchorChange", e.position);
|
|
168
199
|
});
|
|
169
|
-
/** 存在长按点时不能移动全景 */
|
|
170
|
-
o(this, "onWantsPanGesture", () => this.pressPoint ? !1 : void 0);
|
|
171
200
|
/** 移动全景时更新 distanceItem 在屏幕上的位置 */
|
|
172
|
-
|
|
201
|
+
s(this, "onCameraUpdate", () => {
|
|
173
202
|
this.updateDistanceUI();
|
|
174
203
|
});
|
|
175
204
|
/** 更新虚线 */
|
|
176
|
-
|
|
205
|
+
s(this, "updateDashed", () => {
|
|
206
|
+
var i;
|
|
177
207
|
if (!this.lastPoint)
|
|
178
208
|
return;
|
|
179
209
|
const t = this.lastPoint.position, e = (() => {
|
|
210
|
+
var o, h;
|
|
180
211
|
if (this.currentMeasureType === "area")
|
|
181
|
-
return this.area.projectPoint(this.pointSelector.position.point);
|
|
212
|
+
return this.area.projectPoint((o = this.pointSelector.position) == null ? void 0 : o.point);
|
|
182
213
|
if (this.currentMeasureType === "line")
|
|
183
|
-
return this.pointSelector.position.point;
|
|
214
|
+
return (h = this.pointSelector.position) == null ? void 0 : h.point;
|
|
184
215
|
})();
|
|
185
|
-
if (this.dashed.setPoints(t, e), this.dashed.distanceItem.update(this.five), this.hook.emit("editedDashedLineChange", this.dashed), this.currentMeasureType === "area")
|
|
186
|
-
this.area.areaItem.setCanSelect(!1)
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
const d = this.area.polyline.lines.map((m) => ({ start: m.points[0].position, end: m.points[1].position })), l = P({ start: t, end: e }, d), n = P({ start: e, end: this.area.points[0] }, d);
|
|
190
|
-
if (l || n)
|
|
216
|
+
if (this.dashed.setPoints(t, e), this.dashed.distanceItem.update(this.five), this.hook.emit("editedDashedLineChange", this.dashed), this.currentMeasureType === "area")
|
|
217
|
+
if (this.area.areaItem.setCanSelect(!1), this.area.points.length >= 2) {
|
|
218
|
+
const o = this.area.polyline.lines.map((n) => ({ start: n.points[0].position, end: n.points[1].position })), h = v({ start: t, end: e }, o), d = v({ start: e, end: this.area.points[0] }, o);
|
|
219
|
+
if (h || d)
|
|
191
220
|
this.area.hideArea(), this.hook.emit("allowAddPointStateChange", "forbid");
|
|
192
221
|
else {
|
|
193
222
|
this.area.showArea();
|
|
194
|
-
const
|
|
195
|
-
this.area.polygon.updatePoints(
|
|
223
|
+
const n = [...this.area.points, e];
|
|
224
|
+
this.area.polygon.updatePoints(n), this.area.areaItem.updateArea(this.five);
|
|
225
|
+
const r = (i = this.pointSelector.position) == null ? void 0 : i.point;
|
|
226
|
+
if (!r) {
|
|
227
|
+
this.perpendicularDashed.hide();
|
|
228
|
+
return;
|
|
229
|
+
}
|
|
230
|
+
const g = r, P = e;
|
|
231
|
+
this.perpendicularDashed.setPoints(g, P), this.perpendicularDashed.show(), this.hook.emit("allowAddPointStateChange", "allow");
|
|
196
232
|
}
|
|
197
233
|
} else
|
|
198
|
-
this.area.hideArea();
|
|
199
|
-
|
|
200
|
-
this.perpendicularDashed.setPoints(i, a), this.perpendicularDashed.distanceItem.update(this.five);
|
|
201
|
-
}
|
|
234
|
+
this.area.hideArea(), this.perpendicularDashed.hide();
|
|
235
|
+
this.five.needsRender = !0;
|
|
202
236
|
});
|
|
203
237
|
this.pointSelector = new A(this.five, {
|
|
204
238
|
mode: this.editParams.pointSelectorMode,
|
|
205
239
|
pointSelectorHelperParams: { magnifierParams: this.magnifierParams }
|
|
206
|
-
}), this.pointSelector.enable(), this.polyline = new
|
|
240
|
+
}), this.pointSelector.enable(), this.polyline = new f({ model: this.model }), this.area = new u(void 0, {
|
|
207
241
|
five: this.five,
|
|
208
242
|
model: this.model,
|
|
209
243
|
meshContainer: this.group,
|
|
210
244
|
domContainer: this.container
|
|
211
245
|
}), this.model.addPolyline(this.polyline), this.model.addArea(this.area), this.model.getAllLines().forEach((i) => {
|
|
212
|
-
i.distanceItem.appendTo(this.container), i.distanceItem.update(this.five), this.group.add(i.mesh);
|
|
246
|
+
i.distanceItem.appendTo(this.container), i.distanceItem.update(this.five), i.distanceItem.setCanSelect(!0), this.group.add(i.mesh);
|
|
213
247
|
}), this.model.getAllAreas().forEach((i) => {
|
|
214
|
-
i.areaItem.appendTo(this.container), i.areaItem.updateDomPosition(this.five), i.areaItem.setCanSelect(!0), this.group.add(i.polygon), i.polyline.lines.forEach((
|
|
215
|
-
|
|
248
|
+
i.areaItem.appendTo(this.container), i.areaItem.updateDomPosition(this.five), i.areaItem.setCanSelect(!0), this.group.add(i.polygon), i.polyline.lines.forEach((o) => {
|
|
249
|
+
o.distanceItem.appendTo(this.container), o.distanceItem.update(this.five), this.group.add(o.mesh);
|
|
216
250
|
});
|
|
217
|
-
}), this.five.on("cameraUpdate", this.onCameraUpdate), this.pointSelector.hook.on("intersectionUpdate", this.onIntersectionUpdate), this.polyline.hook.on("lineAdded", this.onLineChanged), this.polyline.hook.on("lineRemoved", this.onLineChanged);
|
|
218
|
-
const e = this.five.getElement();
|
|
219
|
-
if (e) {
|
|
220
|
-
this.fiveElement = e;
|
|
221
|
-
const i = new C(e);
|
|
222
|
-
this.hammer = i, i.on("tap", this.onTap), i.on("pan", this.onPan), i.on("press", this.onPress), i.on("panend", this.onPanEnd);
|
|
223
|
-
}
|
|
224
|
-
this.five.helperVisible = !1, (s = this.fiveElement) == null || s.addEventListener("mouseleave", this.onMouseLeave), this.hook.emit("anchorChange", null), this.hook.emit("editedDashedLineChange", null), this.five.refresh();
|
|
251
|
+
}), this.five.on("cameraUpdate", this.onCameraUpdate), this.five.on("wantsTapGesture", l), this.five.on("wantsToMoveToPano", l), this.pointSelector.hook.on("intersectionUpdate", this.onIntersectionUpdate), this.pointSelector.hook.on("select", this.onSelect), this.polyline.hook.on("lineAdded", this.onLineChanged), this.polyline.hook.on("lineRemoved", this.onLineChanged), this.five.helperVisible = !1, (e = this.fiveElement) == null || e.addEventListener("mouseleave", this.onMouseLeave), this.hook.emit("anchorChange", null), this.hook.emit("editedDashedLineChange", null), this.five.refresh();
|
|
225
252
|
}
|
|
226
253
|
dispose() {
|
|
227
|
-
var t
|
|
228
|
-
super.dispose(), this.
|
|
254
|
+
var t;
|
|
255
|
+
super.dispose(), this.model.areas.forEach((e) => {
|
|
256
|
+
(e.points.length < 2 || e.polygon.isBlank) && this.model.removeArea(e);
|
|
257
|
+
}), this.five.helperVisible = !0, this.pointSelector.disable(), this.dashed.remove(), this.perpendicularDashed.remove(), this.five.off("cameraUpdate", this.onCameraUpdate), this.five.off("wantsTapGesture", l), this.five.off("wantsToMoveToPano", l), this.pointSelector.hook.off("intersectionUpdate", this.onIntersectionUpdate), this.pointSelector.hook.off("select", this.onSelect), this.polyline.hook.off("lineAdded", this.onLineChanged), this.polyline.hook.off("lineRemoved", this.onLineChanged), (t = this.fiveElement) == null || t.removeEventListener("mouseleave", this.onMouseLeave), this.magnifier.dispose(), this.dashed.distanceItem.remove(), this.five.needsRender = !0;
|
|
229
258
|
}
|
|
230
259
|
getEditingLines() {
|
|
231
260
|
return this.polyline.lines;
|
|
232
261
|
}
|
|
233
262
|
selectPoint() {
|
|
234
|
-
this.
|
|
263
|
+
this.onSelect();
|
|
264
|
+
}
|
|
265
|
+
complete() {
|
|
266
|
+
this.hook.emit("complete"), this.currentMeasureType === "area" ? (this.area = new u(void 0, { five: this.five, model: this.model, meshContainer: this.group, domContainer: this.container }), this.model.addArea(this.area)) : this.currentMeasureType === "line" && (this.polyline = new f({ model: this.model }), this.model.addPolyline(this.polyline)), this.lastPoint = void 0;
|
|
235
267
|
}
|
|
236
268
|
}
|
|
237
269
|
export {
|
|
238
|
-
|
|
270
|
+
Ee as default
|
|
239
271
|
};
|
|
@@ -9,7 +9,7 @@ import { Raycaster as T, Vector2 as u } from "three";
|
|
|
9
9
|
import { closestPointOnLine as U } from "../utils/math.js";
|
|
10
10
|
import { findClosestPoint as b } from "../utils/findClosestPoint.js";
|
|
11
11
|
import { findAssociatedLines as D } from "../utils/findAssociatedLines.js";
|
|
12
|
-
import { getPointFromHammerEvent as w } from "
|
|
12
|
+
import { getPointFromHammerEvent as w } from "../../shared-utils/getPointFromHammerEvent.js";
|
|
13
13
|
import j from "../Model/area.js";
|
|
14
14
|
import x from "../Model/polygon.js";
|
|
15
15
|
import "../Modules/DeleteDom/_Assets/delete.svg.js";
|
|
@@ -12,6 +12,7 @@ import { type UIControllerParams } from '../Modules/UIController';
|
|
|
12
12
|
import { type GuideControllerParams } from '../Modules/GuideController';
|
|
13
13
|
import { Magnifier } from '../../shared-utils';
|
|
14
14
|
import type { MagnifierParameter } from '../../shared-utils';
|
|
15
|
+
import type Area from '../Model/area';
|
|
15
16
|
export type Mode = 'Watch' | 'Edit' | 'Mixed' | 'View';
|
|
16
17
|
export interface PanoMeasureParameterType extends Partial<Config> {
|
|
17
18
|
editParams?: EditParameter;
|
|
@@ -75,6 +76,7 @@ export default class MeasureController {
|
|
|
75
76
|
/** 撤销编辑 */
|
|
76
77
|
revoke(): void;
|
|
77
78
|
removePolyline(polyline: Polyline): void;
|
|
79
|
+
removeArea(area: Area): void;
|
|
78
80
|
removePolylineByID(id: string): void;
|
|
79
81
|
getPolylineByID(id: string): Polyline;
|
|
80
82
|
getEditedPolyline(): void;
|
|
@@ -96,6 +98,7 @@ export default class MeasureController {
|
|
|
96
98
|
/** 导出数据 */
|
|
97
99
|
toJson(): PluginData;
|
|
98
100
|
/**
|
|
101
|
+
* @deprecated 暂不支持
|
|
99
102
|
* @description 改变插件的模式(pc端模式或移动端模式)
|
|
100
103
|
* @param isMobile true为移动端模式,false为pc端
|
|
101
104
|
*/
|