@realsee/dnalogel 2.27.4 → 2.28.0-dev.1
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/GuideLinePlugin/utils/createLineGeometry.d.ts +5 -0
- package/dist/PanoTagPlugin/typings/tag/Tag.d.ts +1 -1
- package/dist/PanoTagPlugin/typings/tag/TagConfig.d.ts +4 -2
- package/dist/PanoTagPlugin/typings/tag/TagData.d.ts +0 -2
- package/dist/base/BasePluginWithData.d.ts +1 -1
- package/dist/floorplan/FloorplanRoomsPlugin/BasePlugin.d.ts +114 -0
- package/dist/floorplan/FloorplanRoomsPlugin/BasePluginWithData.d.ts +23 -0
- package/dist/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/RoomHighlight/Room.svelte.d.ts +1 -0
- package/dist/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/RoomHighlight/RoomHighlight.svelte.d.ts +1 -0
- package/dist/floorplan/FloorplanRoomsPlugin/Components/Main.svelte.d.ts +1 -0
- package/dist/floorplan/FloorplanRoomsPlugin/Controller.d.ts +40 -0
- package/dist/floorplan/FloorplanRoomsPlugin/index.d.ts +6 -0
- package/dist/floorplan/FloorplanRoomsPlugin/typing.d.ts +60 -0
- package/dist/floorplan/index.d.ts +1 -0
- package/dist/index.cjs.js +67 -67
- package/dist/index.d.ts +0 -1
- package/dist/index.js +7269 -6976
- package/dist/index.umd.js +60 -60
- package/dist/shared-utils/index.d.ts +0 -1
- package/dist/shared-utils/math/planimetry.d.ts +1 -1
- package/dist/shared-utils/three/index.d.ts +0 -2
- package/dist/shared-utils/three/loadVideoTexture.d.ts +1 -1
- package/docs/.nojekyll +1 -0
- package/docs/assets/highlight.css +120 -0
- package/docs/assets/main.js +58 -0
- package/docs/assets/search.js +1 -0
- package/docs/assets/style.css +1367 -0
- package/docs/classes/CSS3DRender.html +770 -0
- package/docs/classes/CruisePluginController.html +669 -0
- package/docs/classes/GuideLineItem.GuideLineItem.html +488 -0
- package/docs/classes/GuideLineModeItem.GuideLineModeItem.html +789 -0
- package/docs/classes/Magnifier.html +477 -0
- package/docs/classes/ModelRoomLabelController.html +395 -0
- package/docs/classes/Object3DHelperController.html +637 -0
- package/docs/classes/PaintBrush.html +499 -0
- package/docs/classes/PanoMeasurePluginLine.html +519 -0
- package/docs/classes/PanoMeasurePluginModel.html +568 -0
- package/docs/classes/PanoMeasurePluginPoint.html +359 -0
- package/docs/classes/PanoMeasurePluginPolyline.html +564 -0
- package/docs/classes/PanoTagPluginController.html +1087 -0
- package/docs/classes/Util.BetterTween.html +409 -0
- package/docs/classes/Util.Interval.html +425 -0
- package/docs/classes/Util.Magnifier.html +496 -0
- package/docs/classes/Util.PointDomHelper.html +400 -0
- package/docs/classes/Util.PointHelper.html +391 -0
- package/docs/classes/Util.PointSelectorHelper.html +447 -0
- package/docs/classes/Util.Rectangle.html +448 -0
- package/docs/enums/CameraMovementEffect.html +307 -0
- package/docs/enums/ContentType.html +443 -0
- package/docs/enums/DIRECTION.html +317 -0
- package/docs/enums/DISPLAY_STRATEGY_TYPE.html +317 -0
- package/docs/enums/DimensionType.html +307 -0
- package/docs/enums/FLOOR_PLAN_ATTACHED_TO.html +310 -0
- package/docs/enums/ITEM_LABEL_PLUGIN_DISPLAY_STRATEGY_TYPE.html +317 -0
- package/docs/enums/PaintBrushTypeEnum.html +310 -0
- package/docs/enums/PointType.html +307 -0
- package/docs/enums/Rotation.html +314 -0
- package/docs/functions/CSS3DRenderPlugin.html +285 -0
- package/docs/functions/CameraMovementPlugin.html +290 -0
- package/docs/functions/CruisePlugin.html +287 -0
- package/docs/functions/FloorplanRoomsPlugin.html +285 -0
- package/docs/functions/GuideLinePlugin.html +287 -0
- package/docs/functions/ItemLabelPlugin.html +287 -0
- package/docs/functions/MapviewFloorplanPlugin.html +287 -0
- package/docs/functions/ModelChassisCompassPlugin.html +290 -0
- package/docs/functions/ModelEntryDoorGuidePlugin.html +290 -0
- package/docs/functions/ModelFloorplanPlugin.html +287 -0
- package/docs/functions/ModelItemLabelPlugin.html +287 -0
- package/docs/functions/ModelRoomLabelPlugin.html +285 -0
- package/docs/functions/ModelTVVideoPlugin.html +287 -0
- package/docs/functions/ModelViewPlugin.html +290 -0
- package/docs/functions/Object3DHelperPlugin.html +285 -0
- package/docs/functions/PanoCompassPlugin.html +287 -0
- package/docs/functions/PanoCursorRaycasterPlugin.html +291 -0
- package/docs/functions/PanoDoorLabelPlugin.html +287 -0
- package/docs/functions/PanoFloorplanRadarPlugin.html +287 -0
- package/docs/functions/PanoMeasurePlugin.html +287 -0
- package/docs/functions/PanoRulerPlugin.html +290 -0
- package/docs/functions/PanoRulerProPlugin.html +290 -0
- package/docs/functions/PanoSpatialTagPlugin.html +290 -0
- package/docs/functions/PanoTagPlugin.html +292 -0
- package/docs/functions/PanoVideoPlugin.html +296 -0
- package/docs/functions/PipelinePlugin.html +285 -0
- package/docs/functions/TopviewFloorplanPlugin.html +287 -0
- package/docs/functions/Util.absoluteUrl.html +319 -0
- package/docs/functions/Util.getCoordsFromClient.html +321 -0
- package/docs/functions/Util.getCoordsFromElement.html +321 -0
- package/docs/functions/Util.getFrameTime.html +313 -0
- package/docs/functions/Util.getIntersectFromRelativePosition.html +321 -0
- package/docs/functions/Util.getRaycasterFromFivePointer.html +321 -0
- package/docs/functions/Util.isAbsoluteURL.html +314 -0
- package/docs/functions/Util.isModelLike.html +314 -0
- package/docs/functions/Util.isNil.html +322 -0
- package/docs/functions/Util.isPanoramaLike.html +314 -0
- package/docs/functions/Util.nextFrame.html +327 -0
- package/docs/functions/Util.notNil.html +322 -0
- package/docs/functions/Util.requestAnimationFrameInterval.html +343 -0
- package/docs/functions/Util.tweenProgress.html +316 -0
- package/docs/functions/Util.uuid.html +312 -0
- package/docs/functions/pluginFlag.html +285 -0
- package/docs/index.html +351 -0
- package/docs/interfaces/AddTagConfig.html +300 -0
- package/docs/interfaces/CSS3DRenderPluginEventMap.html +446 -0
- package/docs/interfaces/CSS3DRenderPluginState.html +322 -0
- package/docs/interfaces/CameraMovementPluginExportType.html +355 -0
- package/docs/interfaces/CruisePluginTypes.Config.html +356 -0
- package/docs/interfaces/CruisePluginTypes.CruiseKeyframe.html +358 -0
- package/docs/interfaces/CruisePluginTypes.EventMap.html +693 -0
- package/docs/interfaces/CruisePluginTypes.MoveAction.html +382 -0
- package/docs/interfaces/CruisePluginTypes.MoveWithKeyframesAction.html +418 -0
- package/docs/interfaces/CruisePluginTypes.MoveWithPanoIndexAction.html +408 -0
- package/docs/interfaces/CruisePluginTypes.PluginData.html +348 -0
- package/docs/interfaces/CruisePluginTypes.PluginServerData.html +316 -0
- package/docs/interfaces/CruisePluginTypes.PluginState.html +405 -0
- package/docs/interfaces/EventMap.html +539 -0
- package/docs/interfaces/FloorplanBounding.html +329 -0
- package/docs/interfaces/FloorplanData.html +332 -0
- package/docs/interfaces/FloorplanEntrance.html +357 -0
- package/docs/interfaces/FloorplanExtraObject.html +347 -0
- package/docs/interfaces/FloorplanExtraObject3D.html +336 -0
- package/docs/interfaces/FloorplanFloorData.html +325 -0
- package/docs/interfaces/FloorplanImagePosition.html +311 -0
- package/docs/interfaces/FloorplanObserver.html +329 -0
- package/docs/interfaces/FloorplanOutlineItem.html +325 -0
- package/docs/interfaces/FloorplanPosition.html +311 -0
- package/docs/interfaces/FloorplanRoomItem.html +376 -0
- package/docs/interfaces/FloorplanRoomLabelItem.html +317 -0
- package/docs/interfaces/FloorplanServerBounding.html +329 -0
- package/docs/interfaces/FloorplanServerComputedData.html +328 -0
- package/docs/interfaces/FloorplanServerData.html +311 -0
- package/docs/interfaces/FloorplanServerDoorItem.html +328 -0
- package/docs/interfaces/FloorplanServerDoorPosition.html +314 -0
- package/docs/interfaces/FloorplanServerEntrance.html +357 -0
- package/docs/interfaces/FloorplanServerFloorData.html +325 -0
- package/docs/interfaces/FloorplanServerImagePosition.html +311 -0
- package/docs/interfaces/FloorplanServerObserver.html +329 -0
- package/docs/interfaces/FloorplanServerOutlineItem.html +325 -0
- package/docs/interfaces/FloorplanServerPosition.html +311 -0
- package/docs/interfaces/FloorplanServerRoomItem.html +388 -0
- package/docs/interfaces/FloorplanServerRoomLabelItem.html +317 -0
- package/docs/interfaces/GuideLineModeItem.GuideLineTagContainer.html +320 -0
- package/docs/interfaces/GuideLinePluginType.CatmullRomCurve3.html +358 -0
- package/docs/interfaces/GuideLinePluginType.EventMap.html +522 -0
- package/docs/interfaces/GuideLinePluginType.GuideLineGeometryStyle.html +353 -0
- package/docs/interfaces/GuideLinePluginType.GuideLineItemContainer.html +344 -0
- package/docs/interfaces/GuideLinePluginType.GuideLineMaterialStyle.html +411 -0
- package/docs/interfaces/GuideLinePluginType.LineGeometriesConfig.html +343 -0
- package/docs/interfaces/GuideLinePluginType.ModelGuideLineStyle.html +468 -0
- package/docs/interfaces/GuideLinePluginType.ModelGuideLineTagData.html +340 -0
- package/docs/interfaces/GuideLinePluginType.PanoramaGuideLineStyle.html +468 -0
- package/docs/interfaces/GuideLinePluginType.PluginDataV2.html +305 -0
- package/docs/interfaces/GuideLinePluginType.PluginServerData.html +326 -0
- package/docs/interfaces/GuideLinePluginType.PluginState.html +351 -0
- package/docs/interfaces/GuideLinePluginType.Route.html +367 -0
- package/docs/interfaces/GuideLinePluginType.RouteConfig.html +349 -0
- package/docs/interfaces/HelperOffset.html +329 -0
- package/docs/interfaces/ImagePlaneGroup.html +303 -0
- package/docs/interfaces/ItemLabelPluginData.html +300 -0
- package/docs/interfaces/ItemLabelPluginExportReturnsType.html +385 -0
- package/docs/interfaces/ItemLabelPluginParametersType.html +321 -0
- package/docs/interfaces/MinMax.html +307 -0
- package/docs/interfaces/ModelChassisCompassPluginData.html +307 -0
- package/docs/interfaces/ModelChassisCompassPluginExportType.html +343 -0
- package/docs/interfaces/ModelChassisCompassPluginParameterType.html +307 -0
- package/docs/interfaces/ModelEntryDoorGuidePluginData.html +314 -0
- package/docs/interfaces/ModelEntryDoorGuidePluginExportType.html +351 -0
- package/docs/interfaces/ModelItemLabelPluginData.html +300 -0
- package/docs/interfaces/ModelItemLabelPluginExportReturnsType.html +385 -0
- package/docs/interfaces/ModelItemLabelPluginParametersType.html +307 -0
- package/docs/interfaces/ModelRoomLabelPluginData.html +300 -0
- package/docs/interfaces/ModelTVVideoPluginData.html +321 -0
- package/docs/interfaces/ModelTVVideoPluginExportType.html +345 -0
- package/docs/interfaces/ModelTVVideoPluginParameterType.html +300 -0
- package/docs/interfaces/ModelViewPluginExportType.html +413 -0
- package/docs/interfaces/Object3DHelperState.html +314 -0
- package/docs/interfaces/ObjectHelperControllers.html +321 -0
- package/docs/interfaces/PaintBrushAction.html +360 -0
- package/docs/interfaces/PaintBrushConfigs.html +358 -0
- package/docs/interfaces/PaintBrushState.html +342 -0
- package/docs/interfaces/PanoCursorRaycasterPluginExportType.html +422 -0
- package/docs/interfaces/PanoCursorRaycasterPluginParameterType.html +279 -0
- package/docs/interfaces/PanoMeasureParameterType.html +446 -0
- package/docs/interfaces/PanoMeasurePluginLineJson.html +314 -0
- package/docs/interfaces/PanoMeasurePluginOpenParameter.html +311 -0
- package/docs/interfaces/PanoMeasurePluginPointJson.html +307 -0
- package/docs/interfaces/PanoMeasurePluginPolylineJson.html +317 -0
- package/docs/interfaces/PanoRulerPluginExportType.html +374 -0
- package/docs/interfaces/PanoRulerPluginOptions.html +323 -0
- package/docs/interfaces/PanoRulerPluginParameterType.html +314 -0
- package/docs/interfaces/PanoRulerProPluginExportType.html +350 -0
- package/docs/interfaces/PanoRulerProPluginOptions.html +320 -0
- package/docs/interfaces/PanoRulerProPluginParameterType.html +307 -0
- package/docs/interfaces/PanoRulerProPluginState.html +314 -0
- package/docs/interfaces/PanoSpatialTagPluginContentEvent.html +293 -0
- package/docs/interfaces/PanoSpatialTagPluginContentReplacement.html +282 -0
- package/docs/interfaces/PanoSpatialTagPluginData.html +350 -0
- package/docs/interfaces/PanoSpatialTagPluginDataElement.html +332 -0
- package/docs/interfaces/PanoSpatialTagPluginExportType.html +428 -0
- package/docs/interfaces/PanoSpatialTagPluginOriginElement.html +328 -0
- package/docs/interfaces/PanoSpatialTagPluginParameterType.html +349 -0
- package/docs/interfaces/PanoSpatialTagPluginPointElement.html +335 -0
- package/docs/interfaces/PanoSpatialTagPluginTagElement.html +328 -0
- package/docs/interfaces/PanoVideoPluginType.LoadParams.html +320 -0
- package/docs/interfaces/PanoVideoPluginType.PanoVideoItem.html +338 -0
- package/docs/interfaces/PanoVideoPluginType.PluginData.html +311 -0
- package/docs/interfaces/PanoVideoPluginType.PluginEventMap.html +417 -0
- package/docs/interfaces/PanoVideoPluginType.PluginState.html +311 -0
- package/docs/interfaces/PanoVideoPluginType.VideoItem.html +346 -0
- package/docs/interfaces/PanoVideoPluginType.VideoMeshParams.html +365 -0
- package/docs/interfaces/Point.html +314 -0
- package/docs/interfaces/Room.html +321 -0
- package/docs/interfaces/RoomInfo.html +307 -0
- package/docs/interfaces/RoomLabel.html +383 -0
- package/docs/interfaces/RoomRules.html +282 -0
- package/docs/interfaces/Rooms.html +282 -0
- package/docs/interfaces/Scissor.html +341 -0
- package/docs/interfaces/State.html +328 -0
- package/docs/interfaces/TagCacheInterface.html +352 -0
- package/docs/interfaces/TagConfig.html +542 -0
- package/docs/interfaces/TagGLTFObjectGroup.html +303 -0
- package/docs/interfaces/TagIconUrl.html +360 -0
- package/docs/interfaces/TagObjectGroup.html +303 -0
- package/docs/interfaces/TagStyle.html +313 -0
- package/docs/interfaces/Tags.html +543 -0
- package/docs/interfaces/TemporaryState.html +300 -0
- package/docs/interfaces/Util.MagnifierParameter.html +384 -0
- package/docs/interfaces/Util.MouseGroupParameter.html +343 -0
- package/docs/interfaces/Util.PointIntersection.html +358 -0
- package/docs/modules/CruisePluginTypes.html +325 -0
- package/docs/modules/GuideLineItem.html +286 -0
- package/docs/modules/GuideLineModeItem.html +291 -0
- package/docs/modules/GuideLinePluginType.html +345 -0
- package/docs/modules/PanoVideoPluginType.html +298 -0
- package/docs/modules/Util.html +340 -0
- package/docs/modules.html +534 -0
- package/docs/types/ArrayPosition.html +276 -0
- package/docs/types/AudioAppearance.html +276 -0
- package/docs/types/AudioTagTypeConfigKey.html +276 -0
- package/docs/types/CSS3DRenderExportType.html +276 -0
- package/docs/types/CSS3DRenderPluginExportType.html +276 -0
- package/docs/types/CSS3DRenderPluginParameterType.html +276 -0
- package/docs/types/ClassFunctionParameters.html +283 -0
- package/docs/types/Color.html +276 -0
- package/docs/types/ContentTypeConfigKey.html +276 -0
- package/docs/types/ContentTypeConfigKeySplit.html +276 -0
- package/docs/types/ContentTypeMap.html +276 -0
- package/docs/types/Create3DDomContainerReturnType.html +276 -0
- package/docs/types/Create3DElementReturnType.html +276 -0
- package/docs/types/CruisePluginExportType.html +276 -0
- package/docs/types/CruisePluginTypes.CruiseData.html +315 -0
- package/docs/types/CruisePluginTypes.MoveEffect.html +292 -0
- package/docs/types/DeprecatedMediaPlaneProperty.html +288 -0
- package/docs/types/DeprecatedTagProperty.html +291 -0
- package/docs/types/Direction-1.html +276 -0
- package/docs/types/Direction4.html +276 -0
- package/docs/types/ElementRenderer.html +300 -0
- package/docs/types/FloorplanRoomsPluginParameterType.html +276 -0
- package/docs/types/FloorplanRoomsPluginReturnType.html +276 -0
- package/docs/types/FloorplanRuleLabels.html +279 -0
- package/docs/types/FloorplanServerRuleLabels.html +276 -0
- package/docs/types/GuideLinePluginExportType.html +276 -0
- package/docs/types/GuideLinePluginType.GuideLineItem.html +348 -0
- package/docs/types/GuideLinePluginType.GuideLineItemEventMap.html +369 -0
- package/docs/types/GuideLinePluginType.GuideLineModeItemMode.html +302 -0
- package/docs/types/GuideLinePluginType.GuideLineStyle.html +305 -0
- package/docs/types/GuideLinePluginType.ModelGuideLineTag.html +305 -0
- package/docs/types/GuideLinePluginType.PathItem.html +305 -0
- package/docs/types/GuideLinePluginType.PluginData.html +314 -0
- package/docs/types/HelperEventMap.html +514 -0
- package/docs/types/LoadTagConfig.html +276 -0
- package/docs/types/MapviewFloorplanPluginParameterType.html +276 -0
- package/docs/types/MapviewFloorplanPluginReturnType.html +276 -0
- package/docs/types/MediaData.html +292 -0
- package/docs/types/MediaStore.html +281 -0
- package/docs/types/ModelEntryDoorGuidePluginParameterType.html +283 -0
- package/docs/types/ModelFloorplanPluginParameterType.html +276 -0
- package/docs/types/ModelFloorplanPluginReturnType.html +276 -0
- package/docs/types/ModelRoomLabelPluginParameters.html +276 -0
- package/docs/types/ModelRoomLabelPluginReturnType.html +276 -0
- package/docs/types/MoveArgs.html +286 -0
- package/docs/types/MoveOpts.html +284 -0
- package/docs/types/Object3DHelperEventMap.html +369 -0
- package/docs/types/ObjectFit.html +276 -0
- package/docs/types/PaintBrushEventMap.html +307 -0
- package/docs/types/PanoCompassPluginData.html +276 -0
- package/docs/types/PanoCompassPluginExportType.html +276 -0
- package/docs/types/PanoCompassPluginParameterType.html +276 -0
- package/docs/types/PanoFloorplanRadarPluginParameterType.html +276 -0
- package/docs/types/PanoFloorplanRadarPluginReturnType.html +276 -0
- package/docs/types/PanoIndex.html +276 -0
- package/docs/types/PanoMeasurePluginEvent.html +276 -0
- package/docs/types/PanoMeasureReturnType.html +276 -0
- package/docs/types/PanoSpatialTagPluginId.html +276 -0
- package/docs/types/PanoTagPluginExportInterface.html +276 -0
- package/docs/types/PanoTagPluginParamsInterface.html +276 -0
- package/docs/types/PanoVideoPluginParameterType.html +276 -0
- package/docs/types/PanoVideoPluginReturnType.html +276 -0
- package/docs/types/PickTagContentTypeInContentTypeConfigKey.html +284 -0
- package/docs/types/PipelinePluginParameterType.html +276 -0
- package/docs/types/PipelinePluginReturnType.html +276 -0
- package/docs/types/PlaneTag.html +284 -0
- package/docs/types/Point2DTag.html +284 -0
- package/docs/types/Point3DTag.html +284 -0
- package/docs/types/PointTag.html +281 -0
- package/docs/types/PointTagInstance.html +281 -0
- package/docs/types/Position.html +276 -0
- package/docs/types/RotateArgs.html +288 -0
- package/docs/types/RotateOpts.html +284 -0
- package/docs/types/RuleLabelsKey.html +276 -0
- package/docs/types/RuleLabelsValue.html +276 -0
- package/docs/types/StickType.html +276 -0
- package/docs/types/Tag.html +342 -0
- package/docs/types/Tag2D.html +284 -0
- package/docs/types/Tag3D.html +284 -0
- package/docs/types/TagConfigByKey.html +281 -0
- package/docs/types/TagContentType.html +276 -0
- package/docs/types/TagDimensionType.html +278 -0
- package/docs/types/TagElement.html +286 -0
- package/docs/types/TagEvents.html +329 -0
- package/docs/types/TagGLTFObject.html +299 -0
- package/docs/types/TagHooks.html +276 -0
- package/docs/types/TagId.html +276 -0
- package/docs/types/TagInstance.html +348 -0
- package/docs/types/TagPointType.html +279 -0
- package/docs/types/TagRendererMap.html +281 -0
- package/docs/types/TopviewFloorplanPluginParameterType.html +276 -0
- package/docs/types/TopviewFloorplanPluginReturnType.html +276 -0
- package/docs/types/WorkCode.html +276 -0
- package/docs/variables/FLOOR_TYPE_MAP.html +286 -0
- package/docs/variables/PLUGIN.html +276 -0
- package/docs/variables/ROOM_FETILE_TYPE_MAP.html +279 -0
- package/docs/variables/ROOM_TYPE_MAP.html +286 -0
- package/docs/variables/defaultGlobalConfig.html +276 -0
- package/docs/variables/itemLabelPluginServerParams.html +283 -0
- package/docs/variables/modelItemLabelPluginServerParams.html +283 -0
- package/docs/variables/modelRoomLabelPluginServerParams.html +283 -0
- package/libs/GuideLinePlugin/GuideLineModeItem/index.js +39 -42
- package/libs/GuideLinePlugin/utils/createLineGeometry.d.ts +5 -0
- package/libs/GuideLinePlugin/utils/createLineGeometry.js +13 -13
- package/libs/PanoTagPlugin/controller/TagRender.js +18 -19
- package/libs/PanoTagPlugin/typings/tag/Tag.d.ts +1 -1
- package/libs/PanoTagPlugin/typings/tag/TagConfig.d.ts +4 -2
- package/libs/PanoTagPlugin/typings/tag/TagData.d.ts +0 -2
- package/libs/PanoTagPlugin/utils/model/mediaPlane.js +10 -10
- package/libs/base/BasePlugin.js +1 -1
- package/libs/base/BasePluginWithData.d.ts +1 -1
- package/libs/floorplan/FloorplanRoomsPlugin/BasePlugin.d.ts +114 -0
- package/libs/floorplan/FloorplanRoomsPlugin/BasePlugin.js +51 -0
- package/libs/floorplan/FloorplanRoomsPlugin/BasePluginWithData.d.ts +23 -0
- package/libs/floorplan/FloorplanRoomsPlugin/BasePluginWithData.js +25 -0
- package/libs/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/CurrentFloor.js +188 -0
- package/libs/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/CurrentFloor.svelte.d.ts +1 -0
- package/libs/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/ExtraObjects.js +94 -0
- package/libs/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/ExtraObjects.svelte.d.ts +1 -0
- package/libs/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/RoomHighlight/Room.js +111 -0
- package/libs/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/RoomHighlight/Room.svelte.d.ts +1 -0
- package/libs/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/RoomHighlight/RoomHighlight.js +191 -0
- package/libs/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/RoomHighlight/RoomHighlight.svelte.d.ts +1 -0
- package/libs/floorplan/FloorplanRoomsPlugin/Components/Main.js +237 -0
- package/libs/floorplan/FloorplanRoomsPlugin/Components/Main.svelte.d.ts +1 -0
- package/libs/floorplan/FloorplanRoomsPlugin/Controller.d.ts +40 -0
- package/libs/floorplan/FloorplanRoomsPlugin/Controller.js +207 -0
- package/libs/floorplan/FloorplanRoomsPlugin/index.d.ts +6 -0
- package/libs/floorplan/FloorplanRoomsPlugin/index.js +43 -0
- package/libs/floorplan/FloorplanRoomsPlugin/typing.d.ts +60 -0
- package/libs/floorplan/index.d.ts +1 -0
- package/libs/index.d.ts +0 -1
- package/libs/index.js +122 -120
- package/libs/shared-utils/device.js +1 -0
- package/libs/shared-utils/index.d.ts +0 -1
- package/libs/shared-utils/index.js +21 -27
- package/libs/shared-utils/logger.js +1 -1
- package/libs/shared-utils/math/planimetry.d.ts +1 -1
- package/libs/shared-utils/math/planimetry.js +29 -36
- package/libs/shared-utils/three/index.d.ts +0 -2
- package/libs/shared-utils/three/loadVideoTexture.d.ts +1 -1
- package/libs/shared-utils/three/loadVideoTexture.js +6 -6
- package/libs/vendor/svelte/internal/index.js +85 -79
- package/package.json +2 -2
- package/dist/AreaMakerPlugin/Controller.d.ts +0 -94
- package/dist/AreaMakerPlugin/index.d.ts +0 -4
- package/dist/AreaMakerPlugin/typing.d.ts +0 -148
- package/dist/AreaMakerPlugin/utils/Item.d.ts +0 -114
- package/dist/components/AreaLabel/Assets/roomLabelBg.d.ts +0 -1
- package/dist/shared-utils/three/core/Object3D.d.ts +0 -8
- package/dist/shared-utils/three/objects/LineSegments.d.ts +0 -9
- package/libs/AreaMakerPlugin/Controller.d.ts +0 -94
- package/libs/AreaMakerPlugin/Controller.js +0 -336
- package/libs/AreaMakerPlugin/index.d.ts +0 -4
- package/libs/AreaMakerPlugin/index.js +0 -37
- package/libs/AreaMakerPlugin/typing.d.ts +0 -148
- package/libs/AreaMakerPlugin/utils/Item.d.ts +0 -114
- package/libs/AreaMakerPlugin/utils/Item.js +0 -263
- package/libs/components/AreaLabel/Assets/roomLabelBg.d.ts +0 -1
- package/libs/components/AreaLabel/Assets/roomLabelBg.js +0 -4
- package/libs/components/AreaLabel/LabelItem.js +0 -125
- package/libs/shared-utils/three/core/Object3D.d.ts +0 -8
- package/libs/shared-utils/three/core/Object3D.js +0 -22
- package/libs/shared-utils/three/objects/LineSegments.d.ts +0 -9
- package/libs/shared-utils/three/objects/LineSegments.js +0 -9
- /package/dist/{components/AreaLabel/LabelItem.svelte.d.ts → floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/CurrentFloor.svelte.d.ts} +0 -0
- /package/{libs/components/AreaLabel/LabelItem.svelte.d.ts → dist/floorplan/FloorplanRoomsPlugin/Components/CurrentFloor/ExtraObjects.svelte.d.ts} +0 -0
- /package/libs/{AreaMakerPlugin → floorplan/FloorplanRoomsPlugin}/typing.js +0 -0
|
@@ -17,6 +17,11 @@ interface LineGeometryOption {
|
|
|
17
17
|
* @returns THREE BufferGeometry
|
|
18
18
|
*/
|
|
19
19
|
export declare function createLineGeometry(options: LineGeometryOption): {
|
|
20
|
+
geometry: THREE.BufferGeometry;
|
|
21
|
+
maxU: number;
|
|
22
|
+
curvePath?: undefined;
|
|
23
|
+
curvePoints?: undefined;
|
|
24
|
+
} | {
|
|
20
25
|
geometry: THREE.BufferGeometry;
|
|
21
26
|
maxU: number;
|
|
22
27
|
curvePath: THREE.CurvePath<THREE.Vector3>;
|
|
@@ -11,31 +11,31 @@ const z = 2, M = 3, X = 3, k = 2;
|
|
|
11
11
|
function Q(e) {
|
|
12
12
|
const i = e.width, g = e.unitLength / i, c = i / 2, E = e.path;
|
|
13
13
|
if (E.length === 0)
|
|
14
|
-
return { geometry: new n.BufferGeometry(), maxU: 0
|
|
14
|
+
return { geometry: new n.BufferGeometry(), maxU: 0 };
|
|
15
15
|
const u = new n.CurvePath();
|
|
16
16
|
E.forEach((t) => {
|
|
17
|
-
const
|
|
18
|
-
|
|
17
|
+
const m = I(t);
|
|
18
|
+
m && u.add(m);
|
|
19
19
|
});
|
|
20
20
|
const w = Math.ceil(u.getLength() * 100);
|
|
21
21
|
u.arcLengthDivisions = w;
|
|
22
22
|
const o = u.getPoints(w), y = o.length, L = G(o.map((t) => [t.x, t.z])), B = (y - 1) * z * M, d = 2 * y, C = d * X, U = d * k, r = new Uint32Array(B), s = new Float32Array(C), a = new Float32Array(U);
|
|
23
|
-
let N = 0,
|
|
23
|
+
let N = 0, R = 0;
|
|
24
24
|
for (let t = 0; t < o.length; t++) {
|
|
25
|
-
const [
|
|
26
|
-
s[t * 6 + 0] =
|
|
27
|
-
const
|
|
28
|
-
s[t * 6 + 3] =
|
|
29
|
-
const
|
|
30
|
-
if (
|
|
31
|
-
const V = new n.Vector3().lerpVectors(
|
|
25
|
+
const [m, A] = L[t][0], T = o[t], { x: _, y: b, z: P } = T, f = new x(_ + m * c, b + 0.05, P + A * c);
|
|
26
|
+
s[t * 6 + 0] = f.x, s[t * 6 + 1] = f.y, s[t * 6 + 2] = f.z;
|
|
27
|
+
const h = new x(_ - m * c, b + 0.05, P - A * c);
|
|
28
|
+
s[t * 6 + 3] = h.x, s[t * 6 + 4] = h.y, s[t * 6 + 5] = h.z, N += t > 0 ? o[t - 1].clone().sub(o[t]).length() : 0;
|
|
29
|
+
const v = N / i / g;
|
|
30
|
+
if (R = v, a[t * 4 + 0] = 0, a[t * 4 + 1] = v, a[t * 4 + 2] = 1, a[t * 4 + 3] = v, e.skipPositions) {
|
|
31
|
+
const V = new n.Vector3().lerpVectors(f, h, 0.5);
|
|
32
32
|
if (e.skipPositions.some((F) => F.distanceTo(V) < 0.26))
|
|
33
33
|
continue;
|
|
34
34
|
}
|
|
35
35
|
t !== o.length - 1 && (r[t * 6 + 0] = t * 2 + 0, r[t * 6 + 1] = t * 2 + 2, r[t * 6 + 2] = t * 2 + 1, r[t * 6 + 3] = t * 2 + 2, r[t * 6 + 4] = t * 2 + 3, r[t * 6 + 5] = t * 2 + 1);
|
|
36
36
|
}
|
|
37
|
-
const
|
|
38
|
-
return
|
|
37
|
+
const l = new n.BufferGeometry();
|
|
38
|
+
return l.setAttribute("position", new n.BufferAttribute(s, 3)), l.setAttribute("uv", new n.BufferAttribute(a, 2)), l.setIndex(new n.BufferAttribute(r, 1)), { geometry: l, maxU: R, curvePath: u, curvePoints: o };
|
|
39
39
|
}
|
|
40
40
|
function I(e) {
|
|
41
41
|
if (O(e)) {
|
|
@@ -163,16 +163,15 @@ class ri extends w {
|
|
|
163
163
|
if (!e)
|
|
164
164
|
return;
|
|
165
165
|
const o = F(e).then((r) => {
|
|
166
|
-
var l, m, h,
|
|
166
|
+
var l, m, h, d, u;
|
|
167
167
|
const s = Object.assign(r.scene, {
|
|
168
168
|
customID: t.id,
|
|
169
169
|
isTagModel: !0,
|
|
170
|
-
removeEventListener: t.
|
|
171
|
-
} : this.addObjectClickHandler(t, r.scene, (c) => {
|
|
170
|
+
removeEventListener: this.addObjectClickHandler(t, r.scene, (c) => {
|
|
172
171
|
this.hooks.emit("click", { target: "TagModel", tag: t, event: c });
|
|
173
172
|
})
|
|
174
173
|
});
|
|
175
|
-
return s.visible = this.getCurrentVisibleState(t), new g().fromArray(t.matrix).decompose(s.position, s.quaternion, s.scale), s.updateWorldMatrix(!0, !0), s.visible = this.getVisibleByFiveMode(t), (h = (m = (l = this.config) == null ? void 0 : l.globalConfig) == null ? void 0 : m.modelConfig) != null && h.autoLookAtEnabled && ((u = (
|
|
174
|
+
return s.visible = this.getCurrentVisibleState(t), new g().fromArray(t.matrix).decompose(s.position, s.quaternion, s.scale), s.updateWorldMatrix(!0, !0), s.visible = this.getVisibleByFiveMode(t), (h = (m = (l = this.config) == null ? void 0 : l.globalConfig) == null ? void 0 : m.modelConfig) != null && h.autoLookAtEnabled && ((u = (d = t.config) == null ? void 0 : d.modelConfig) != null && u.autoLookAtEnabled) && s.lookAt(this.five.camera.position.clone().setY(s.position.y)), s;
|
|
176
175
|
});
|
|
177
176
|
t.model = { promise: o };
|
|
178
177
|
const i = yield o;
|
|
@@ -223,7 +222,7 @@ class ri extends w {
|
|
|
223
222
|
var o, i;
|
|
224
223
|
return ((i = (o = e.data.mediaData) == null ? void 0 : o[0]) == null ? void 0 : i.type) === "Video";
|
|
225
224
|
}).forEach((e) => {
|
|
226
|
-
var l, m, h,
|
|
225
|
+
var l, m, h, d, u;
|
|
227
226
|
const o = e.data.mediaData[0];
|
|
228
227
|
if (!o)
|
|
229
228
|
return;
|
|
@@ -231,8 +230,8 @@ class ri extends w {
|
|
|
231
230
|
if (!i)
|
|
232
231
|
return;
|
|
233
232
|
e.mediaPlane && !((m = (l = e.state) == null ? void 0 : l.visible) == null || m) && e.mediaPlane instanceof R && e.mediaPlane.pause();
|
|
234
|
-
const n = e.position.map(C), a = this.getCurrentVisibleState(e), r = (() => !!(e.mediaPlane && !a))(), s = (() => !!(!e.mediaPlane && a))(),
|
|
235
|
-
if ((r ||
|
|
233
|
+
const n = e.position.map(C), a = this.getCurrentVisibleState(e), r = (() => !!(e.mediaPlane && !a))(), s = (() => !!(!e.mediaPlane && a))(), p = (() => !!(e.mediaPlane && e.mediaPlane.src !== i))();
|
|
234
|
+
if ((r || p) && (e.mediaPlane && this.imagePlaneGroup.remove(e.mediaPlane), (h = e.mediaPlane) == null || h.dispose(), (d = e.mediaPlane) == null || d.removeFromParent(), e.mediaPlane = void 0), s || p) {
|
|
236
235
|
const c = new R(i, n, {
|
|
237
236
|
videoCoverSrc: o.videoCoverUrl,
|
|
238
237
|
playButton: e.data.playIcon,
|
|
@@ -258,12 +257,12 @@ class ri extends w {
|
|
|
258
257
|
var o, i;
|
|
259
258
|
return ((i = (o = e.data.mediaData) == null ? void 0 : o[0]) == null ? void 0 : i.type) === "Image";
|
|
260
259
|
}).forEach((e) => {
|
|
261
|
-
var
|
|
260
|
+
var p, l;
|
|
262
261
|
const { url: o } = e.data.mediaData[0];
|
|
263
262
|
if (!o)
|
|
264
263
|
return;
|
|
265
264
|
const i = e.position.map(C), n = this.getCurrentVisibleState(e), a = (() => !!(e.mediaPlane && !n))(), r = (() => !!(!e.mediaPlane && n))(), s = (() => !!(e.mediaPlane && e.mediaPlane.src !== o))();
|
|
266
|
-
(a || s) && (e.mediaPlane && this.imagePlaneGroup.remove(e.mediaPlane), (
|
|
265
|
+
(a || s) && (e.mediaPlane && this.imagePlaneGroup.remove(e.mediaPlane), (p = e.mediaPlane) == null || p.dispose(), (l = e.mediaPlane) == null || l.removeFromParent(), e.mediaPlane = void 0), (r || s) && (e.mediaPlane = new j(o, i, { objectFit: e.data.objectFit }), e.config.clickable !== !1 && this.domEvents.addAutoBindEventListener(e.mediaPlane, "click", (m) => {
|
|
267
266
|
this.hooks.emit("click", { tag: e, target: "TagContent", event: m.origDomEvent });
|
|
268
267
|
}), this.imagePlaneGroup.add(e.mediaPlane));
|
|
269
268
|
});
|
|
@@ -275,9 +274,9 @@ class ri extends w {
|
|
|
275
274
|
this.sort([...this.filterCSS3DTag]).forEach((e) => {
|
|
276
275
|
var o, i, n, a;
|
|
277
276
|
if (e.tag3DContentSvelte) {
|
|
278
|
-
const { svelteApp: r, css3DInstance: s, initialNormal:
|
|
279
|
-
if (r.$set({ tag: e, hooks: this.hooks, state: this.state, temporaryState: this.temporaryState }), !
|
|
280
|
-
const m = new O().setFromUnitVectors(
|
|
277
|
+
const { svelteApp: r, css3DInstance: s, initialNormal: p, currentNormal: l } = e.tag3DContentSvelte;
|
|
278
|
+
if (r.$set({ tag: e, hooks: this.hooks, state: this.state, temporaryState: this.temporaryState }), !p.equals(l)) {
|
|
279
|
+
const m = new O().setFromUnitVectors(p, l);
|
|
281
280
|
s.css3DObject.setRotationFromQuaternion(m);
|
|
282
281
|
}
|
|
283
282
|
return;
|
|
@@ -292,13 +291,13 @@ class ri extends w {
|
|
|
292
291
|
const s = this.getTagNormal(e);
|
|
293
292
|
if (!s)
|
|
294
293
|
return;
|
|
295
|
-
const
|
|
294
|
+
const l = (n = this.getTagConfig(e).tag3DConfig) != null ? n : {};
|
|
296
295
|
if (this.getRenderType(e) === "BehindDom") {
|
|
297
296
|
l.mode = "behind", l.container = document.createElement("div");
|
|
298
|
-
const
|
|
299
|
-
l.container.style.backgroundColor =
|
|
297
|
+
const d = "black";
|
|
298
|
+
l.container.style.backgroundColor = d, l.container.style.border = `3px solid ${d}`, this.css3DRenderPlugin.hooks.on("render", () => {
|
|
300
299
|
var u;
|
|
301
|
-
if (m.css3DObject.opacityMesh
|
|
300
|
+
if (m.css3DObject.opacityMesh) {
|
|
302
301
|
const c = this.addObjectClickHandler(e, m.css3DObject.opacityMesh, (v) => {
|
|
303
302
|
this.hooks.emit("click", { event: v, target: "TagContent", tag: e });
|
|
304
303
|
});
|
|
@@ -369,10 +368,10 @@ class ri extends w {
|
|
|
369
368
|
if (!n || n.length !== 4 || !Array.isArray(n[0]) || !Array.isArray(n[2]))
|
|
370
369
|
return;
|
|
371
370
|
e.updateWorldMatrix(!1, !1);
|
|
372
|
-
const a = e.matrixWorld, r = new D().fromArray(n[0]), s = new D().fromArray(n[2]),
|
|
371
|
+
const a = e.matrixWorld, r = new D().fromArray(n[0]), s = new D().fromArray(n[2]), p = x(r, s).add(new D(0, 0, 5e-4)), l = new g().setPosition(p), m = new g().makeScale(o, o, o), h = new g().multiply(a).multiply(l).multiply(m);
|
|
373
372
|
h.decompose(i.position, i.quaternion, i.scale);
|
|
374
|
-
const
|
|
375
|
-
|
|
373
|
+
const d = i.opacityMesh;
|
|
374
|
+
d && h.decompose(d.position, d.quaternion, d.scale);
|
|
376
375
|
}
|
|
377
376
|
/** 添加模型标签 */
|
|
378
377
|
addMediaModelTag(t) {
|
|
@@ -33,7 +33,7 @@ export type Tag<C extends TagContentType = TagContentType, S extends StickType =
|
|
|
33
33
|
/** 标签 wrapper 的 classname */
|
|
34
34
|
className?: string;
|
|
35
35
|
/** 标签数据 */
|
|
36
|
-
data: ContentTypeMap[C];
|
|
36
|
+
data: C extends TagContentType ? ContentTypeMap[C] : ContentTypeMap[keyof ContentTypeMap];
|
|
37
37
|
/** 「展开/收起」 「可见/不可见」 的策略配置 */
|
|
38
38
|
config?: TagConfig<C>;
|
|
39
39
|
/** 打标签时的 five state */
|
|
@@ -141,7 +141,9 @@ export interface TagConfig<C extends TagContentType = TagContentType> {
|
|
|
141
141
|
* @description: 标签的默认数据,会将 tag.data 深度合并进来
|
|
142
142
|
* @code `tag.data = ObjectAssignDeep(initialData, tag.data)`
|
|
143
143
|
*/
|
|
144
|
-
initialData?: PartialObjectDeep<ContentTypeMap[C]>
|
|
144
|
+
initialData?: (C extends TagContentType ? PartialObjectDeep<ContentTypeMap[C]> : {
|
|
145
|
+
[key: string]: any;
|
|
146
|
+
}) & {
|
|
145
147
|
/**
|
|
146
148
|
* @description: 类似 css 的 !important,会覆盖掉 tag.data 中对应的数据
|
|
147
149
|
* @code
|
|
@@ -171,5 +173,5 @@ export interface TagConfig<C extends TagContentType = TagContentType> {
|
|
|
171
173
|
clickable?: boolean;
|
|
172
174
|
isMerged?: boolean;
|
|
173
175
|
}
|
|
174
|
-
export declare const defaultGlobalConfig: TagConfig
|
|
176
|
+
export declare const defaultGlobalConfig: TagConfig<any>;
|
|
175
177
|
export {};
|
|
@@ -156,8 +156,6 @@ interface ContentTypeMapInterface {
|
|
|
156
156
|
type ContentTypeMapInterfaceWithExtraData = {
|
|
157
157
|
[key in keyof ContentTypeMapInterface]: ContentTypeMapInterface[key] & {
|
|
158
158
|
extraData?: Object;
|
|
159
|
-
} & {
|
|
160
|
-
[key: string]: any;
|
|
161
159
|
};
|
|
162
160
|
};
|
|
163
161
|
export type ContentTypeMap = Pick<ContentTypeMapInterfaceWithExtraData, TagContentType>;
|
|
@@ -24,7 +24,7 @@ import { loadTexture as T } from "../../../shared-utils/three/loadTexture.js";
|
|
|
24
24
|
import { QuadrangleGeometry as F, QuadrangleMesh as I } from "../../../shared-utils/three/Quadrangle.js";
|
|
25
25
|
import { getVideoTexture as B } from "../../../shared-utils/three/loadVideoTexture.js";
|
|
26
26
|
import { Image_Play_Icon_With_Text as L, Image_Play_Icon as b } from "../../Assets/Icon.js";
|
|
27
|
-
import { getPositionsByObjectFit as
|
|
27
|
+
import { getPositionsByObjectFit as g } from "../../../shared-utils/three/getPositionsByObjectFit.js";
|
|
28
28
|
import { FragmentTransparencyMaterial as H } from "../../../shared-utils/three/FragmentTransparencyMaterial.js";
|
|
29
29
|
import "../../../shared-utils/math/pointIsRectangle.js";
|
|
30
30
|
import "../../../shared-utils/device.js";
|
|
@@ -65,15 +65,15 @@ class G extends P {
|
|
|
65
65
|
a = t.map((h) => h.clone().add(i));
|
|
66
66
|
}
|
|
67
67
|
T(e).then((i) => {
|
|
68
|
-
var
|
|
69
|
-
const h = new URL(e, location.href).pathname.endsWith(".png"), u = new l.MeshBasicMaterial({ map: i, transparent: h }), p =
|
|
70
|
-
(
|
|
68
|
+
var f;
|
|
69
|
+
const h = new URL(e, location.href).pathname.endsWith(".png"), u = new l.MeshBasicMaterial({ map: i, transparent: h }), p = g(
|
|
70
|
+
(f = s == null ? void 0 : s.objectFit) != null ? f : "contain",
|
|
71
71
|
a,
|
|
72
72
|
i.image.width / i.image.height
|
|
73
73
|
), m = x(...p), M = p.map((V) => V.clone().sub(m)), y = new F(M);
|
|
74
74
|
this.position.copy(m), this.geometry = y, this.material = u;
|
|
75
75
|
}).catch((i) => {
|
|
76
|
-
console.error(`Imageplane error ${i
|
|
76
|
+
console.error(`Imageplane error ${i}`);
|
|
77
77
|
});
|
|
78
78
|
}
|
|
79
79
|
}
|
|
@@ -155,7 +155,7 @@ class O extends P {
|
|
|
155
155
|
const t = yield this.getImageTexture(this.videoCoverSrc);
|
|
156
156
|
if (!t)
|
|
157
157
|
return;
|
|
158
|
-
const s = new l.MeshBasicMaterial({ transparent: !1, map: t }), o =
|
|
158
|
+
const s = new l.MeshBasicMaterial({ transparent: !1, map: t }), o = g(this.objectFit, this.cornerPoints, t.image.width / t.image.height), a = new I(o, s);
|
|
159
159
|
return a.position.copy(new w(0, 0, 0)), a.name = "videoCoverMesh", a;
|
|
160
160
|
}))();
|
|
161
161
|
return e && (this.children.includes(this.coverMesh) || (this.add(e), this.coverMesh = e)), e;
|
|
@@ -171,9 +171,9 @@ class O extends P {
|
|
|
171
171
|
if (!this.src)
|
|
172
172
|
return;
|
|
173
173
|
const s = this.getVideoTexture(this.src), o = new l.MeshBasicMaterial({ transparent: !1, map: s }), a = yield new Promise((i) => {
|
|
174
|
-
s.metadataLoaded ? i(
|
|
174
|
+
s.metadataLoaded ? i(g(this.objectFit, this.cornerPoints, s.image.videoWidth / s.image.videoHeight)) : s.addEventListener(
|
|
175
175
|
"videoLoaded",
|
|
176
|
-
() => i(
|
|
176
|
+
() => i(g(this.objectFit, this.cornerPoints, s.image.videoWidth / s.image.videoHeight))
|
|
177
177
|
);
|
|
178
178
|
}), n = new I(a, o);
|
|
179
179
|
return n.name = "videoMesh", n.position.copy(new w(0, 0, 0)), n;
|
|
@@ -196,10 +196,10 @@ class O extends P {
|
|
|
196
196
|
if (this.children.includes(this.buttonMesh))
|
|
197
197
|
return;
|
|
198
198
|
const e = yield (() => v(this, null, function* () {
|
|
199
|
-
var m, M, y,
|
|
199
|
+
var m, M, y, f;
|
|
200
200
|
if (this.buttonMesh)
|
|
201
201
|
return this.buttonMesh;
|
|
202
|
-
const t = (M = (m = this.videoMesh) == null ? void 0 : m.geometry.points[0].distanceTo(this.videoMesh.geometry.points[3])) != null ? M : 1 / 0, s = (
|
|
202
|
+
const t = (M = (m = this.videoMesh) == null ? void 0 : m.geometry.points[0].distanceTo(this.videoMesh.geometry.points[3])) != null ? M : 1 / 0, s = (f = (y = this.coverMesh) == null ? void 0 : y.geometry.points[0].distanceTo(this.coverMesh.geometry.points[3])) != null ? f : 1 / 0, o = this.cornerPoints[0].distanceTo(this.cornerPoints[3]), n = Math.min(t, s, o) / o * 0.3, i = yield this.getImageTexture(this.buttonSrc), h = g("contain", this.cornerPoints, i.image.width / i.image.height), u = new I(h, new H(i));
|
|
203
203
|
u.position.copy(new w(0, 0, 0)), u.name = "buttonMesh", u.scale.set(n, n, n), this.domEvents.addAutoBindEventListener(u, "click", () => this.play());
|
|
204
204
|
const p = new l.Vector3().crossVectors(new l.Vector3().subVectors(h[0], h[1]), new l.Vector3().subVectors(h[0], h[3])).normalize().multiplyScalar(1e-4);
|
|
205
205
|
return u.position.add(p), u;
|
package/libs/base/BasePlugin.js
CHANGED
|
@@ -16,7 +16,7 @@ declare abstract class Controller<PluginState extends State, PluginEventMap exte
|
|
|
16
16
|
*/
|
|
17
17
|
abstract load(serverData: PluginServerData, state?: PluginState, userAction?: boolean): Promise<void>;
|
|
18
18
|
/** 把原始数据转化为插件数据 */
|
|
19
|
-
protected abstract formatData?(serverData: PluginServerData): Promise<PluginData
|
|
19
|
+
protected abstract formatData?(serverData: PluginServerData): Promise<PluginData>;
|
|
20
20
|
}
|
|
21
21
|
export type { State, EventMap, Config };
|
|
22
22
|
export type { BaseOptions } from './BasePlugin';
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
import { Subscribe } from '../../shared-utils/Subscribe';
|
|
2
|
+
/**
|
|
3
|
+
* 基本属性字段
|
|
4
|
+
*/
|
|
5
|
+
interface State {
|
|
6
|
+
/**
|
|
7
|
+
* 插件是否启用
|
|
8
|
+
*/
|
|
9
|
+
enabled: boolean;
|
|
10
|
+
/**
|
|
11
|
+
* 插件UI是否展示
|
|
12
|
+
*/
|
|
13
|
+
visible?: boolean;
|
|
14
|
+
/**
|
|
15
|
+
* 插件的配置项
|
|
16
|
+
*/
|
|
17
|
+
config?: unknown;
|
|
18
|
+
}
|
|
19
|
+
interface BaseOptions {
|
|
20
|
+
/** 是否是用户行为 */
|
|
21
|
+
userAction?: boolean;
|
|
22
|
+
}
|
|
23
|
+
interface Config {
|
|
24
|
+
/** 静态资源前缀 */
|
|
25
|
+
staticPrefix?: string;
|
|
26
|
+
/** 国际化转换函数 */
|
|
27
|
+
i18n?: (key: string) => string;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* 插件基本事件
|
|
31
|
+
*/
|
|
32
|
+
type EventMap<PluginState> = {
|
|
33
|
+
/**
|
|
34
|
+
* 插件被销毁
|
|
35
|
+
*/
|
|
36
|
+
dispose: () => void;
|
|
37
|
+
/**
|
|
38
|
+
* 插件状态变化
|
|
39
|
+
* @param params.state 最新的State
|
|
40
|
+
* @param params.prevState 上一个State
|
|
41
|
+
* @param params.userAction 是否是用户触发
|
|
42
|
+
*/
|
|
43
|
+
stateChange: (params: {
|
|
44
|
+
state: PluginState;
|
|
45
|
+
prevState?: PluginState;
|
|
46
|
+
userAction: boolean;
|
|
47
|
+
}) => void;
|
|
48
|
+
};
|
|
49
|
+
/**
|
|
50
|
+
* plugin 的基本控制器
|
|
51
|
+
*/
|
|
52
|
+
declare abstract class Controller<PluginState extends State, PluginEventMap extends EventMap<PluginState>> {
|
|
53
|
+
/**
|
|
54
|
+
* @realsee/dnalogel 版本号
|
|
55
|
+
*/
|
|
56
|
+
readonly VERSION: string;
|
|
57
|
+
/**
|
|
58
|
+
* 插件事件钩子
|
|
59
|
+
*/
|
|
60
|
+
hooks: Subscribe<PluginEventMap>;
|
|
61
|
+
readonly staticPrefix: string;
|
|
62
|
+
/**
|
|
63
|
+
* 当前状态
|
|
64
|
+
* @description
|
|
65
|
+
* ```text
|
|
66
|
+
* 可以通过 plugin.state 和 plugin.setState 来获取和设置。
|
|
67
|
+
* 通过 state 设置后,plugin 会通过合适的动画运动来达到设置的效果。
|
|
68
|
+
* 来迎合一些通过数据驱动的场景。
|
|
69
|
+
* ```
|
|
70
|
+
*/
|
|
71
|
+
abstract state: PluginState;
|
|
72
|
+
constructor(config?: Config);
|
|
73
|
+
/**
|
|
74
|
+
* 获取当前的插件状态,如果当初插件内存在需要通过动画变更的 state 值,则通过此方法可以得到中间状态
|
|
75
|
+
*/
|
|
76
|
+
getCurrentState(): PluginState;
|
|
77
|
+
/**
|
|
78
|
+
* 插件自身DOM添加到父容器
|
|
79
|
+
* @param wrapper
|
|
80
|
+
*/
|
|
81
|
+
appendTo?(wrapper: Element): void;
|
|
82
|
+
/**
|
|
83
|
+
* 展示UI
|
|
84
|
+
*/
|
|
85
|
+
show?(options?: BaseOptions): Promise<void>;
|
|
86
|
+
/**
|
|
87
|
+
* 隐藏UI
|
|
88
|
+
*/
|
|
89
|
+
hide?(options?: BaseOptions): Promise<void>;
|
|
90
|
+
/**
|
|
91
|
+
* 设置state
|
|
92
|
+
* @param state 插件的目标状态
|
|
93
|
+
* @param options 配置项
|
|
94
|
+
*/
|
|
95
|
+
setState?(state: Partial<PluginState>, options?: BaseOptions): void;
|
|
96
|
+
/**
|
|
97
|
+
* @description: 获取静态资源的url
|
|
98
|
+
*/
|
|
99
|
+
absoluteUrl(url: string): string;
|
|
100
|
+
/**
|
|
101
|
+
* 启用插件,让插件能够响应交互
|
|
102
|
+
*/
|
|
103
|
+
abstract enable(options?: BaseOptions): void;
|
|
104
|
+
/**
|
|
105
|
+
* 禁用插件,让插件停止响应交互
|
|
106
|
+
*/
|
|
107
|
+
abstract disable(options?: BaseOptions): void;
|
|
108
|
+
/**
|
|
109
|
+
* 插件进行销毁
|
|
110
|
+
*/
|
|
111
|
+
abstract dispose(): void;
|
|
112
|
+
}
|
|
113
|
+
export type { State, Config, EventMap, BaseOptions };
|
|
114
|
+
export { Controller };
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
var e = Object.defineProperty;
|
|
2
|
+
var m = (r, t, i) => t in r ? e(r, t, { enumerable: !0, configurable: !0, writable: !0, value: i }) : r[t] = i;
|
|
3
|
+
var o = (r, t, i) => (m(r, typeof t != "symbol" ? t + "" : t, i), i);
|
|
4
|
+
import { Subscribe as p } from "../../shared-utils/Subscribe.js";
|
|
5
|
+
import "hammerjs";
|
|
6
|
+
import "three";
|
|
7
|
+
import "@realsee/five";
|
|
8
|
+
import "../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
|
|
9
|
+
import "../../CSS3DRenderPlugin/utils/three/CSS3DRender.js";
|
|
10
|
+
import "../../CSS3DRenderPlugin/utils/generateBehindFiveElement.js";
|
|
11
|
+
import { absoluteUrl as s } from "../../shared-utils/absoluteUrl.js";
|
|
12
|
+
import "../../shared-utils/positionToVector3.js";
|
|
13
|
+
import "../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
|
|
14
|
+
import "three/examples/jsm/renderers/CSS3DRenderer";
|
|
15
|
+
import "../../CSS3DRenderPlugin/utils/getAllCSS3DObject.js";
|
|
16
|
+
import "../../CSS3DRenderPlugin/utils/createResizeObserver.js";
|
|
17
|
+
import "../../CSS3DRenderPlugin/utils/even.js";
|
|
18
|
+
import "../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
|
|
19
|
+
import "../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
|
|
20
|
+
import "../../shared-utils/three/centerPoint.js";
|
|
21
|
+
import "../../CSS3DRenderPlugin/utils/three/CSS3DScene.js";
|
|
22
|
+
import "../../CSS3DRenderPlugin/utils/three/CSS3DGroup.js";
|
|
23
|
+
let O = class {
|
|
24
|
+
constructor(t) {
|
|
25
|
+
/**
|
|
26
|
+
* @realsee/dnalogel 版本号
|
|
27
|
+
*/
|
|
28
|
+
o(this, "VERSION", "2.28.0-dev.1");
|
|
29
|
+
/**
|
|
30
|
+
* 插件事件钩子
|
|
31
|
+
*/
|
|
32
|
+
o(this, "hooks", new p());
|
|
33
|
+
o(this, "staticPrefix", "//vr-image-4.realsee-cdn.cn");
|
|
34
|
+
t != null && t.staticPrefix && (this.staticPrefix = t.staticPrefix);
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* 获取当前的插件状态,如果当初插件内存在需要通过动画变更的 state 值,则通过此方法可以得到中间状态
|
|
38
|
+
*/
|
|
39
|
+
getCurrentState() {
|
|
40
|
+
return this.state;
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* @description: 获取静态资源的url
|
|
44
|
+
*/
|
|
45
|
+
absoluteUrl(t) {
|
|
46
|
+
return s(this.staticPrefix, t);
|
|
47
|
+
}
|
|
48
|
+
};
|
|
49
|
+
export {
|
|
50
|
+
O as Controller
|
|
51
|
+
};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import * as BasePlugin from './BasePlugin';
|
|
2
|
+
type State = BasePlugin.State;
|
|
3
|
+
type Config = BasePlugin.Config;
|
|
4
|
+
interface EventMap<PluginState, PluginData> extends BasePlugin.EventMap<PluginState> {
|
|
5
|
+
/** 数据变更 */
|
|
6
|
+
dataChange: (data: PluginData, prevData?: PluginData) => void;
|
|
7
|
+
/** 数据加载完成 */
|
|
8
|
+
dataLoaded: (data: PluginData) => void;
|
|
9
|
+
}
|
|
10
|
+
declare abstract class Controller<PluginState extends State, PluginEventMap extends EventMap<PluginState, PluginData>, PluginServerData, PluginData> extends BasePlugin.Controller<PluginState, PluginEventMap> {
|
|
11
|
+
protected abstract data?: PluginData;
|
|
12
|
+
/**
|
|
13
|
+
* 加载插件依赖数据
|
|
14
|
+
* @param serverData 插件数据
|
|
15
|
+
* @param state 插件 State
|
|
16
|
+
*/
|
|
17
|
+
abstract load(serverData: PluginServerData, state?: PluginState, userAction?: boolean): Promise<void>;
|
|
18
|
+
/** 把原始数据转化为插件数据 */
|
|
19
|
+
protected abstract formatData?(serverData: PluginServerData): Promise<PluginData>;
|
|
20
|
+
}
|
|
21
|
+
export type { State, EventMap, Config };
|
|
22
|
+
export type { BaseOptions } from './BasePlugin';
|
|
23
|
+
export { Controller };
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { Controller as o } from "./BasePlugin.js";
|
|
2
|
+
import "../../shared-utils/Subscribe.js";
|
|
3
|
+
import "hammerjs";
|
|
4
|
+
import "three";
|
|
5
|
+
import "@realsee/five";
|
|
6
|
+
import "../../vendor/@tweenjs/tween/dist/tween.esm.js.js";
|
|
7
|
+
import "../../CSS3DRenderPlugin/utils/three/CSS3DRender.js";
|
|
8
|
+
import "../../shared-utils/positionToVector3.js";
|
|
9
|
+
import "../../CSS3DRenderPlugin/utils/three/CSS3DRenderer.js";
|
|
10
|
+
import "three/examples/jsm/renderers/CSS3DRenderer";
|
|
11
|
+
import "../../CSS3DRenderPlugin/utils/getAllCSS3DObject.js";
|
|
12
|
+
import "../../CSS3DRenderPlugin/utils/createResizeObserver.js";
|
|
13
|
+
import "../../CSS3DRenderPlugin/utils/even.js";
|
|
14
|
+
import "../../CSS3DRenderPlugin/utils/three/CSS3DObject.js";
|
|
15
|
+
import "../../CSS3DRenderPlugin/utils/three/OpacityMesh.js";
|
|
16
|
+
import "../../shared-utils/three/centerPoint.js";
|
|
17
|
+
import "../../CSS3DRenderPlugin/utils/three/CSS3DScene.js";
|
|
18
|
+
import "../../CSS3DRenderPlugin/utils/three/CSS3DGroup.js";
|
|
19
|
+
import "../../CSS3DRenderPlugin/utils/generateBehindFiveElement.js";
|
|
20
|
+
import "../../shared-utils/absoluteUrl.js";
|
|
21
|
+
let q = class extends o {
|
|
22
|
+
};
|
|
23
|
+
export {
|
|
24
|
+
q as Controller
|
|
25
|
+
};
|