@realsee/dnalogel 2.0.0-alpha.43 → 2.0.0-alpha.44
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/CSS3DRenderPlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/CameraMovementPlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/ItemLabelPlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/ItemLabelPlugin/index.js +138 -73
- package/dist/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/ModelChassisCompassPlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/ModelEntryDoorGuidePlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/ModelItemLabelPlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/ModelRoomLabelPlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/ModelTVVideoPlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/ModelViewPlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/PanoCompassPlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/PanoCursorRaycasterPlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/PanoMeasurePlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/PanoRulerPlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/PanoRulerProPlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/PanoSpatialTagPlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/floorplan/ModelFloorplanPlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/floorplan/PanoFloorplanRadarPlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/floorplan/TopviewFloorplanPlugin/ItemLabelPlugin/typings.d.ts +1 -0
- package/dist/index.es.js +156 -91
- package/dist/index.js +156 -91
- package/dist/index.umd.js +156 -91
- package/docs/classes/Magnifier.html +4 -4
- package/docs/classes/ModelRoomLabelController.html +4 -4
- package/docs/enums/CameraMovementEffect.html +1 -1
- package/docs/enums/DIRECTION.html +1 -1
- package/docs/enums/DISPLAY_STRATEGY_TYPE.html +1 -1
- package/docs/enums/FLOOR_PLAN_ATTACHED_TO.html +1 -1
- package/docs/enums/ITEM_LABEL_PLUGIN_DISPLAY_STRATEGY_TYPE.html +1 -1
- package/docs/enums/Rotation.html +1 -1
- package/docs/interfaces/CSS3DRenderPluginExportType.html +2 -2
- package/docs/interfaces/CameraMovementPluginExportType.html +2 -2
- package/docs/interfaces/FloorplanBounding.html +3 -3
- package/docs/interfaces/FloorplanData.html +1 -1
- package/docs/interfaces/FloorplanEntrance.html +6 -6
- package/docs/interfaces/FloorplanExtraObject.html +2 -2
- package/docs/interfaces/FloorplanExtraObject3D.html +1 -1
- package/docs/interfaces/FloorplanFloorData.html +1 -1
- package/docs/interfaces/FloorplanImagePosition.html +1 -1
- package/docs/interfaces/FloorplanObserver.html +1 -1
- package/docs/interfaces/FloorplanOutlineItem.html +1 -1
- package/docs/interfaces/FloorplanPosition.html +1 -1
- package/docs/interfaces/FloorplanRoomItem.html +5 -5
- package/docs/interfaces/FloorplanRoomLabelItem.html +2 -2
- package/docs/interfaces/FloorplanServerBounding.html +3 -3
- package/docs/interfaces/FloorplanServerComputedData.html +1 -1
- package/docs/interfaces/FloorplanServerData.html +1 -1
- package/docs/interfaces/FloorplanServerEntrance.html +6 -6
- package/docs/interfaces/FloorplanServerFloorData.html +1 -1
- package/docs/interfaces/FloorplanServerImagePosition.html +1 -1
- package/docs/interfaces/FloorplanServerObserver.html +1 -1
- package/docs/interfaces/FloorplanServerOutlineItem.html +1 -1
- package/docs/interfaces/FloorplanServerPosition.html +1 -1
- package/docs/interfaces/FloorplanServerRoomItem.html +6 -6
- package/docs/interfaces/FloorplanServerRoomLabelItem.html +2 -2
- package/docs/interfaces/ItemLabelPluginData.html +1 -1
- package/docs/interfaces/ItemLabelPluginExportReturnsType.html +1 -1
- package/docs/interfaces/ItemLabelPluginParametersType.html +1 -1
- package/docs/interfaces/LineJson.html +1 -1
- package/docs/interfaces/ModelChassisCompassPluginData.html +1 -1
- package/docs/interfaces/ModelChassisCompassPluginExportType.html +1 -1
- package/docs/interfaces/ModelChassisCompassPluginParameterType.html +1 -1
- package/docs/interfaces/ModelEntryDoorGuidePluginData.html +1 -1
- package/docs/interfaces/ModelEntryDoorGuidePluginExportType.html +1 -1
- package/docs/interfaces/ModelItemLabelPluginData.html +1 -1
- package/docs/interfaces/ModelItemLabelPluginExportReturnsType.html +1 -1
- package/docs/interfaces/ModelItemLabelPluginParametersType.html +1 -1
- package/docs/interfaces/ModelRoomLabelPluginData.html +1 -1
- package/docs/interfaces/ModelTVVideoPluginData.html +1 -1
- package/docs/interfaces/ModelTVVideoPluginExportType.html +1 -1
- package/docs/interfaces/ModelTVVideoPluginParameterType.html +1 -1
- package/docs/interfaces/ModelViewPluginExportType.html +1 -1
- package/docs/interfaces/OpenParameter.html +1 -1
- package/docs/interfaces/PanoCursorRaycasterPluginExportType.html +6 -6
- package/docs/interfaces/PanoMeasureParameterType.html +1 -1
- package/docs/interfaces/PanoRulerPluginExportType.html +1 -1
- package/docs/interfaces/PanoRulerPluginOptions.html +1 -1
- package/docs/interfaces/PanoRulerPluginParameterType.html +1 -1
- package/docs/interfaces/PanoRulerProPluginExportType.html +1 -1
- package/docs/interfaces/PanoRulerProPluginOptions.html +1 -1
- package/docs/interfaces/PanoRulerProPluginParameterType.html +1 -1
- package/docs/interfaces/PanoRulerProPluginState.html +1 -1
- package/docs/interfaces/PanoSpatialTagPluginData.html +1 -1
- package/docs/interfaces/PanoSpatialTagPluginDataElement.html +1 -1
- package/docs/interfaces/PanoSpatialTagPluginExportType.html +1 -1
- package/docs/interfaces/PanoSpatialTagPluginOriginElement.html +1 -1
- package/docs/interfaces/PanoSpatialTagPluginParameterType.html +1 -1
- package/docs/interfaces/PanoSpatialTagPluginPointElement.html +1 -1
- package/docs/interfaces/PanoSpatialTagPluginTagElement.html +1 -1
- package/docs/interfaces/Point.html +1 -1
- package/docs/interfaces/PointJson.html +1 -1
- package/docs/interfaces/Room.html +1 -1
- package/docs/interfaces/RoomInfo.html +1 -1
- package/docs/interfaces/RoomLabel.html +7 -7
- package/docs/modules.html +18 -18
- package/libs/ItemLabelPlugin/ItemLabelComponent.js +2 -2
- package/libs/ItemLabelPlugin/ItemLabelComponent.svelte +251 -0
- package/libs/ItemLabelPlugin/ItemLabelItem.js +141 -74
- package/libs/ItemLabelPlugin/ItemLabelItem.svelte +180 -0
- package/libs/ItemLabelPlugin/Plugin.js +1 -1
- package/libs/ItemLabelPlugin/typings.d.ts +3 -1
- package/libs/ModelItemLabelPlugin/ItemLabelComponent.js +2 -2
- package/libs/ModelItemLabelPlugin/ItemLabelComponent.svelte +155 -0
- package/libs/ModelItemLabelPlugin/ItemLabelItem.js +6 -6
- package/libs/ModelItemLabelPlugin/ItemLabelItem.svelte +100 -0
- package/libs/ModelItemLabelPlugin/ModelItemLabelPlugin.js +1 -1
- package/libs/ModelItemLabelPlugin/typings.d.ts +1 -1
- package/libs/ModelRoomLabelPlugin/Controller.js +1 -1
- package/libs/ModelRoomLabelPlugin/RoomLabelItem.js +4 -4
- package/libs/ModelRoomLabelPlugin/RoomLabelItem.svelte +63 -0
- package/libs/ModelRoomLabelPlugin/RoomLabelItems.js +2 -2
- package/libs/ModelRoomLabelPlugin/RoomLabelItems.svelte +94 -0
- package/libs/PanoRulerProPlugin/Controller.js +1 -1
- package/libs/PanoRulerProPlugin/RulerItem.js +9 -9
- package/libs/PanoRulerProPlugin/RulerItem.svelte +166 -0
- package/libs/PanoRulerProPlugin/RulerItems.svelte +212 -0
- package/libs/PanoSpatialTagPlugin/Components/origins.js +2 -2
- package/libs/PanoSpatialTagPlugin/Components/origins.svelte +58 -0
- package/libs/PanoSpatialTagPlugin/Components/tag.js +9 -9
- package/libs/PanoSpatialTagPlugin/Components/tag.svelte +292 -0
- package/libs/PanoSpatialTagPlugin/Plugin.js +2 -2
- package/libs/floorplan/Components/BaseImage.js +2 -2
- package/libs/floorplan/Components/BaseImage.svelte +26 -0
- package/libs/floorplan/Components/Camera.js +3 -3
- package/libs/floorplan/Components/Camera.svelte +46 -0
- package/libs/floorplan/Components/Compass.js +4 -4
- package/libs/floorplan/Components/Compass.svelte +51 -0
- package/libs/floorplan/Components/CurrentFloor.js +3 -3
- package/libs/floorplan/Components/CurrentFloor.svelte +46 -0
- package/libs/floorplan/Components/Main.js +2 -2
- package/libs/floorplan/Components/Main.svelte +51 -0
- package/libs/floorplan/Components/Normalmage.js +2 -2
- package/libs/floorplan/Components/Normalmage.svelte +11 -0
- package/libs/floorplan/Components/RoomHighlight/Room.js +2 -2
- package/libs/floorplan/Components/RoomHighlight/Room.svelte +27 -0
- package/libs/floorplan/Components/RoomHighlight/RoomHighlight.js +3 -3
- package/libs/floorplan/Components/RoomHighlight/RoomHighlight.svelte +29 -0
- package/libs/floorplan/Components/RoomLabels/RoomLabel.js +3 -3
- package/libs/floorplan/Components/RoomLabels/RoomLabel.svelte +119 -0
- package/libs/floorplan/Components/RoomLabels/RoomLabels.js +2 -2
- package/libs/floorplan/Components/RoomLabels/RoomLabels.svelte +35 -0
- package/libs/floorplan/Components/RoomMaterials/RoomMaterial.js +3 -3
- package/libs/floorplan/Components/RoomMaterials/RoomMaterial.svelte +42 -0
- package/libs/floorplan/Components/RoomMaterials/RoomMaterial_0.svelte +7 -0
- package/libs/floorplan/Components/RoomMaterials/RoomMaterial_1.svelte +24 -0
- package/libs/floorplan/Components/RoomMaterials/RoomMaterial_2.svelte +33 -0
- package/libs/floorplan/Components/RuleLabels/RuleItem.js +9 -9
- package/libs/floorplan/Components/RuleLabels/RuleItem.svelte +174 -0
- package/libs/floorplan/Components/RuleLabels/RuleLabels.js +2 -2
- package/libs/floorplan/Components/RuleLabels/RuleLabels.svelte +32 -0
- package/libs/floorplan/Components/SvgImage.js +3 -4
- package/libs/floorplan/Components/SvgImage.svelte +28 -0
- package/libs/floorplan/ModelFloorplanPlugin/Controller.js +1 -1
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/Camera.js +4 -4
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/Camera.svelte +85 -0
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/CurrentFloor/CurrentFloor.svelte +18 -0
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/CurrentFloor/ExtraObjects.js +4 -4
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/CurrentFloor/ExtraObjects.svelte +40 -0
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/Main.js +3 -3
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/Main.svelte +64 -0
- package/libs/floorplan/PanoFloorplanRadarPlugin/Controller.js +1 -1
- package/libs/floorplan/TopviewFloorplanPlugin/Controller.js +1 -1
- package/package.json +2 -1
|
@@ -22,7 +22,7 @@ import '../typings';
|
|
|
22
22
|
import { currentTarget } from '../store';
|
|
23
23
|
|
|
24
24
|
function add_css(target) {
|
|
25
|
-
append_styles(target, "svelte-
|
|
25
|
+
append_styles(target, "svelte-eb8bdm", ".PanoSpatialTagPlugin__tag-x.svelte-eb8bdm.svelte-eb8bdm{position:absolute;top:0;left:0;display:block;white-space:nowrap;box-sizing:border-box;width:25rem;height:14rem;color:#FFF;transform:translate(0, -100%);transition:height .5s linear}.PanoSpatialTagPlugin__tag-shadow.svelte-eb8bdm.svelte-eb8bdm{content:'';position:absolute;width:30rem;height:30rem;top:-15rem;left:-15rem;z-index:-1;opacity:0;transition:opacity .8s .6s;background:url('https://vrlab-image4.ljcdn.com/release/web/PanoSpatialTagPlugin__blur.png');background-size:30rem 30rem}.PanoSpatialTagPlugin__tag-line.svelte-eb8bdm.svelte-eb8bdm{position:absolute;left:-1rem;width:2rem;height:100%;overflow:hidden}.PanoSpatialTagPlugin__tag-flagpole.svelte-eb8bdm.svelte-eb8bdm{position:absolute;top:0;left:1rem;height:calc(100% - 1.5rem);width:.15rem;background:linear-gradient(to bottom, rgba(255, 255, 255, 1), rgba(255, 255, 255, .1));box-shadow:0 .1rem .5rem rgba(0, 0, 0, .2);opacity:0;transform:translate(-50%, 60%) scaleY(0);transition:transform .4s cubic-bezier(.44,.44,.74,.98) , opacity .4s cubic-bezier(.44,.44,.74,.98), width .5s linear, height .5s linear ;transform-origin:center bottom}.PanoSpatialTagPlugin__tag-line1.svelte-eb8bdm.svelte-eb8bdm{position:absolute;top:0;left:0.3rem;height:1.8rem;width:.1rem;background:#fff;opacity:0;transform:translate(-50%, 200%) scaleY(0);transform-origin:center top}.PanoSpatialTagPlugin__tag-line2.svelte-eb8bdm.svelte-eb8bdm{position:absolute;top:0;left:0.5rem;height:1.8rem;width:.1rem;background:#fff;opacity:0;transform:translate(-50%, 200%) scaleY(0);transform-origin:center top}.PanoSpatialTagPlugin__tag-show.svelte-eb8bdm .PanoSpatialTagPlugin__tag-line1.svelte-eb8bdm{-webkit-animation:svelte-eb8bdm-PanoSpatialTagPlugin__tag-line1 linear .5s forwards .45s;animation:svelte-eb8bdm-PanoSpatialTagPlugin__tag-line1 linear .5s forwards .45s}.PanoSpatialTagPlugin__tag-show.svelte-eb8bdm .PanoSpatialTagPlugin__tag-line2.svelte-eb8bdm{-webkit-animation:svelte-eb8bdm-PanoSpatialTagPlugin__tag-line2 linear .5s forwards .65s;animation:svelte-eb8bdm-PanoSpatialTagPlugin__tag-line2 linear .5s forwards .65s}.PanoSpatialTagPlugin__tag-x.PanoSpatialTagPlugin__tag-upside-down.svelte-eb8bdm.svelte-eb8bdm{transform:translate(0, 0)}.PanoSpatialTagPlugin__tag-upside-down.svelte-eb8bdm .PanoSpatialTagPlugin__tag-line.svelte-eb8bdm{transform:scaleY(-1)}.PanoSpatialTagPlugin__tag-animate.svelte-eb8bdm.svelte-eb8bdm{position:relative;height:100%;overflow:hidden;transform-origin:left top;transition:transform .5s linear}.PanoSpatialTagPlugin__tag-upside-down.svelte-eb8bdm .PanoSpatialTagPlugin__tag-animate.svelte-eb8bdm{transform-origin:left bottom}.PanoSpatialTagPlugin__tag-content.svelte-eb8bdm.svelte-eb8bdm{position:absolute;display:inline-block;transform:translate(-100%, 0);transition:transform .9s cubic-bezier(0,.65,.16,1.08) .6s;padding-left:.5rem;font-size:1rem}.PanoSpatialTagPlugin__tag-upside-down.svelte-eb8bdm .PanoSpatialTagPlugin__tag-content.svelte-eb8bdm{bottom:0}.PanoSpatialTagPlugin__tag-show.svelte-eb8bdm .PanoSpatialTagPlugin__tag-flagpole.svelte-eb8bdm{opacity:1;transform:translate(-50%, 0) scaleY(1)}.PanoSpatialTagPlugin__tag-upside-down.svelte-eb8bdm .PanoSpatialTagPlugin__tag-shadow.svelte-eb8bdm{top:unset;bottom:-15rem}.PanoSpatialTagPlugin__tag-show.svelte-eb8bdm .PanoSpatialTagPlugin__tag-shadow.svelte-eb8bdm{opacity:.32}.PanoSpatialTagPlugin__tag-show.svelte-eb8bdm .PanoSpatialTagPlugin__tag-content.svelte-eb8bdm{transform:translate(0, 0)}.PanoSpatialTagPlugin__tag-hide.svelte-eb8bdm .PanoSpatialTagPlugin__tag-flagpole.svelte-eb8bdm{opacity:0;transform:translate(-50%, 60%) scaleY(0);transition:transform .5s .55s, opacity .4s .55s}.PanoSpatialTagPlugin__tag-hide.svelte-eb8bdm .PanoSpatialTagPlugin__tag-shadow.svelte-eb8bdm{opacity:0;transition:opacity .8s}.PanoSpatialTagPlugin__tag-hide.svelte-eb8bdm .PanoSpatialTagPlugin__tag-content.svelte-eb8bdm{transform:translate(-100%, 0);transition:transform .6s cubic-bezier(.53,.06,.88,.59)}.PanoSpatialTagPlugin__tag-hide.svelte-eb8bdm .PanoSpatialTagPlugin__tag-content .svelte-eb8bdm{pointer-events:none}.PanoSpatialTagPlugin__tag-hide.svelte-eb8bdm .PanoSpatialTagPlugin__tag-line1.svelte-eb8bdm{opacity:0.5;transform:translate(-50%, 10%) scaleY(0);-webkit-animation:svelte-eb8bdm-PanoSpatialTagPlugin__tag-line1-hide linear .28s forwards .3s;animation:svelte-eb8bdm-PanoSpatialTagPlugin__tag-line1-hide linear .28s forwards .3s}.PanoSpatialTagPlugin__tag-hide.svelte-eb8bdm .PanoSpatialTagPlugin__tag-line2.svelte-eb8bdm{opacity:0.5;transform:translate(-50%, 0) scaleY(0);-webkit-animation:svelte-eb8bdm-PanoSpatialTagPlugin__tag-line2-hide linear .28s forwards .45s;animation:svelte-eb8bdm-PanoSpatialTagPlugin__tag-line2-hide linear .28s forwards .45s}@-webkit-keyframes svelte-eb8bdm-PanoSpatialTagPlugin__tag-line1{0%{opacity:0;transform:translate(-50%, 250%) scaleY(1)}50%{opacity:0.5;transform:translate(-50%, 135%) scaleY(1)}100%{opacity:0.5;transform:translate(-50%, 20%) scaleY(0)}}@keyframes svelte-eb8bdm-PanoSpatialTagPlugin__tag-line1{0%{opacity:0;transform:translate(-50%, 250%) scaleY(1)}50%{opacity:0.5;transform:translate(-50%, 135%) scaleY(1)}100%{opacity:0.5;transform:translate(-50%, 20%) scaleY(0)}}@-webkit-keyframes svelte-eb8bdm-PanoSpatialTagPlugin__tag-line2{0%{opacity:0;transform:translate(-50%, 250%) scaleY(1)}50%{opacity:0.5;transform:translate(-50%, 125%) scaleY(1)}100%{opacity:0.5;transform:translate(-50%, 0) scaleY(0)}}@keyframes svelte-eb8bdm-PanoSpatialTagPlugin__tag-line2{0%{opacity:0;transform:translate(-50%, 250%) scaleY(1)}50%{opacity:0.5;transform:translate(-50%, 125%) scaleY(1)}100%{opacity:0.5;transform:translate(-50%, 0) scaleY(0)}}@-webkit-keyframes svelte-eb8bdm-PanoSpatialTagPlugin__tag-line1-hide{0%{opacity:0.5;transform:translate(-50%, 10%) scaleY(0)}50%{opacity:0.2;transform:translate(-50%, 105%) scaleY(1)}100%{opacity:0;transform:translate(-50%, 200%) scaleY(0)}}@keyframes svelte-eb8bdm-PanoSpatialTagPlugin__tag-line1-hide{0%{opacity:0.5;transform:translate(-50%, 10%) scaleY(0)}50%{opacity:0.2;transform:translate(-50%, 105%) scaleY(1)}100%{opacity:0;transform:translate(-50%, 200%) scaleY(0)}}@-webkit-keyframes svelte-eb8bdm-PanoSpatialTagPlugin__tag-line2-hide{0%{opacity:0.5;transform:translate(-50%, 0) scaleY(0)}50%{opacity:0.2;transform:translate(-50%, 100%) scaleY(1)}100%{opacity:0;transform:translate(-50%, 200%) scaleY(0)}}@keyframes svelte-eb8bdm-PanoSpatialTagPlugin__tag-line2-hide{0%{opacity:0.5;transform:translate(-50%, 0) scaleY(0)}50%{opacity:0.2;transform:translate(-50%, 100%) scaleY(1)}100%{opacity:0;transform:translate(-50%, 200%) scaleY(0)}}");
|
|
26
26
|
}
|
|
27
27
|
|
|
28
28
|
function create_fragment(ctx) {
|
|
@@ -56,19 +56,19 @@ function create_fragment(ctx) {
|
|
|
56
56
|
t3 = space();
|
|
57
57
|
div3 = element("div");
|
|
58
58
|
div2 = element("div");
|
|
59
|
-
attr(div0, "class", "PanoSpatialTagPlugin__tag-shadow svelte-
|
|
59
|
+
attr(div0, "class", "PanoSpatialTagPlugin__tag-shadow svelte-eb8bdm");
|
|
60
60
|
set_style(div0, "transform", "translate(" + /*contentWidth*/ ctx[7] / 2 * /*contentZoom*/ ctx[3] * 3 + "px, " + /*contentHeight*/ ctx[8] / 2 * (/*upsideDown*/ ctx[1] ? -1 : 1) * /*contentZoom*/ ctx[3] * 3 + "px) scale(" + 1 / /*contentZoom*/ ctx[3] + ")");
|
|
61
|
-
attr(i0, "class", "PanoSpatialTagPlugin__tag-flagpole svelte-
|
|
61
|
+
attr(i0, "class", "PanoSpatialTagPlugin__tag-flagpole svelte-eb8bdm");
|
|
62
62
|
set_style(i0, "width", /*lineWidthZoom*/ ctx[4] + "rem");
|
|
63
|
-
attr(i1, "class", "PanoSpatialTagPlugin__tag-line1 svelte-
|
|
64
|
-
attr(i2, "class", "PanoSpatialTagPlugin__tag-line2 svelte-
|
|
65
|
-
attr(div1, "class", "PanoSpatialTagPlugin__tag-line svelte-
|
|
66
|
-
attr(div2, "class", "PanoSpatialTagPlugin__tag-content svelte-
|
|
67
|
-
attr(div3, "class", "PanoSpatialTagPlugin__tag-animate svelte-
|
|
63
|
+
attr(i1, "class", "PanoSpatialTagPlugin__tag-line1 svelte-eb8bdm");
|
|
64
|
+
attr(i2, "class", "PanoSpatialTagPlugin__tag-line2 svelte-eb8bdm");
|
|
65
|
+
attr(div1, "class", "PanoSpatialTagPlugin__tag-line svelte-eb8bdm");
|
|
66
|
+
attr(div2, "class", "PanoSpatialTagPlugin__tag-content svelte-eb8bdm");
|
|
67
|
+
attr(div3, "class", "PanoSpatialTagPlugin__tag-animate svelte-eb8bdm");
|
|
68
68
|
set_style(div3, "transform", "scale(" + /*contentZoom*/ ctx[3] * 3 + ")");
|
|
69
69
|
attr(div4, "id", div4_id_value = 'PanoSpatialTagPlugin__' + /*id*/ ctx[0]);
|
|
70
70
|
set_style(div4, "height", 20 * /*lineHeightZoom*/ ctx[5] + "rem");
|
|
71
|
-
attr(div4, "class", "svelte-
|
|
71
|
+
attr(div4, "class", "svelte-eb8bdm");
|
|
72
72
|
toggle_class(div4, "PanoSpatialTagPlugin__tag-x", true);
|
|
73
73
|
toggle_class(div4, "PanoSpatialTagPlugin__tag-upside-down", /*upsideDown*/ ctx[1]);
|
|
74
74
|
toggle_class(div4, "PanoSpatialTagPlugin__tag-show", /*show*/ ctx[10]);
|
|
@@ -0,0 +1,292 @@
|
|
|
1
|
+
<script>import { onMount, onDestroy, afterUpdate } from 'svelte';
|
|
2
|
+
import '../typings';
|
|
3
|
+
import { currentTarget } from '../store';
|
|
4
|
+
export let id;
|
|
5
|
+
export let upsideDown;
|
|
6
|
+
export let content;
|
|
7
|
+
export let contentZoom;
|
|
8
|
+
export let lineWidthZoom;
|
|
9
|
+
export let lineHeightZoom;
|
|
10
|
+
export let destroying = false;
|
|
11
|
+
export let folded;
|
|
12
|
+
export let dispose;
|
|
13
|
+
export let events;
|
|
14
|
+
export let hooks;
|
|
15
|
+
let contentWidth = 0;
|
|
16
|
+
let contentHeight = 0;
|
|
17
|
+
let contentDom;
|
|
18
|
+
let show;
|
|
19
|
+
let timeoutId = setTimeout(() => {
|
|
20
|
+
if (!folded)
|
|
21
|
+
show = true;
|
|
22
|
+
timeoutId = undefined;
|
|
23
|
+
}, 100);
|
|
24
|
+
const handleClickContent = event => {
|
|
25
|
+
const eventsName = Object.keys(events);
|
|
26
|
+
let node = event.target;
|
|
27
|
+
while (node) {
|
|
28
|
+
const classNames = node.getAttribute('class');
|
|
29
|
+
if (!classNames) {
|
|
30
|
+
node = node.parentNode;
|
|
31
|
+
continue;
|
|
32
|
+
}
|
|
33
|
+
if (classNames.includes('PanoSpatialTagPlugin__tag-content')) {
|
|
34
|
+
node = null;
|
|
35
|
+
break;
|
|
36
|
+
}
|
|
37
|
+
eventsName.forEach(key => {
|
|
38
|
+
if (classNames.includes(key))
|
|
39
|
+
events[key](id);
|
|
40
|
+
});
|
|
41
|
+
node = node.parentNode;
|
|
42
|
+
}
|
|
43
|
+
};
|
|
44
|
+
onMount(() => {
|
|
45
|
+
hooks.emit('initTag', { id });
|
|
46
|
+
});
|
|
47
|
+
const unsubscribe = currentTarget.subscribe((str) => {
|
|
48
|
+
if (str === null)
|
|
49
|
+
return;
|
|
50
|
+
const [currentId, date] = str.split('-PanoSpatialTagPlugin-');
|
|
51
|
+
if (id === currentId) {
|
|
52
|
+
hooks.emit('clickOrigin', { id, show });
|
|
53
|
+
if (!timeoutId) {
|
|
54
|
+
show = folded;
|
|
55
|
+
folded = !folded;
|
|
56
|
+
timeoutId = setTimeout(() => {
|
|
57
|
+
timeoutId = undefined;
|
|
58
|
+
}, 1500);
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
});
|
|
62
|
+
afterUpdate(() => {
|
|
63
|
+
contentWidth = contentDom.offsetWidth;
|
|
64
|
+
contentHeight = contentDom.offsetHeight;
|
|
65
|
+
if (timeoutId)
|
|
66
|
+
return;
|
|
67
|
+
show = !folded;
|
|
68
|
+
});
|
|
69
|
+
onDestroy(() => {
|
|
70
|
+
hooks.emit('destroyTag', { id });
|
|
71
|
+
unsubscribe();
|
|
72
|
+
dispose();
|
|
73
|
+
});
|
|
74
|
+
</script>
|
|
75
|
+
|
|
76
|
+
<div
|
|
77
|
+
class:PanoSpatialTagPlugin__tag-x={true}
|
|
78
|
+
class:PanoSpatialTagPlugin__tag-upside-down={upsideDown}
|
|
79
|
+
class:PanoSpatialTagPlugin__tag-show={show}
|
|
80
|
+
class:PanoSpatialTagPlugin__tag-hide={show === false || destroying}
|
|
81
|
+
id={'PanoSpatialTagPlugin__' + id}
|
|
82
|
+
style="height: {20 * lineHeightZoom}rem"
|
|
83
|
+
>
|
|
84
|
+
<div class="PanoSpatialTagPlugin__tag-shadow"
|
|
85
|
+
style="transform: translate({contentWidth / 2 * contentZoom * 3}px, {
|
|
86
|
+
contentHeight / 2 * (upsideDown ? -1 : 1) * contentZoom * 3
|
|
87
|
+
}px) scale({1 / contentZoom})"
|
|
88
|
+
/>
|
|
89
|
+
<div class="PanoSpatialTagPlugin__tag-line">
|
|
90
|
+
<i class="PanoSpatialTagPlugin__tag-flagpole"
|
|
91
|
+
style="width: {lineWidthZoom}rem;"
|
|
92
|
+
/>
|
|
93
|
+
<i class="PanoSpatialTagPlugin__tag-line1"/>
|
|
94
|
+
<i class="PanoSpatialTagPlugin__tag-line2"/>
|
|
95
|
+
</div>
|
|
96
|
+
<div class="PanoSpatialTagPlugin__tag-animate" style="transform: scale({contentZoom * 3})">
|
|
97
|
+
<div class="PanoSpatialTagPlugin__tag-content" on:click="{handleClickContent}" bind:this={contentDom}>
|
|
98
|
+
{@html content}
|
|
99
|
+
</div>
|
|
100
|
+
</div>
|
|
101
|
+
</div>
|
|
102
|
+
|
|
103
|
+
<style>
|
|
104
|
+
.PanoSpatialTagPlugin__tag-x {
|
|
105
|
+
position: absolute;
|
|
106
|
+
top: 0;
|
|
107
|
+
left: 0;
|
|
108
|
+
display: block;
|
|
109
|
+
white-space: nowrap;
|
|
110
|
+
box-sizing: border-box;
|
|
111
|
+
width: 25rem;
|
|
112
|
+
height: 14rem;
|
|
113
|
+
color: #FFF;
|
|
114
|
+
transform: translate(0, -100%);
|
|
115
|
+
transition: height .5s linear;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.PanoSpatialTagPlugin__tag-shadow {
|
|
119
|
+
content: '';
|
|
120
|
+
position: absolute;
|
|
121
|
+
width: 30rem;
|
|
122
|
+
height: 30rem;
|
|
123
|
+
top: -15rem;
|
|
124
|
+
left: -15rem;
|
|
125
|
+
z-index: -1;
|
|
126
|
+
opacity: 0;
|
|
127
|
+
transition: opacity .8s .6s;
|
|
128
|
+
background: url('https://vrlab-image4.ljcdn.com/release/web/PanoSpatialTagPlugin__blur.png');
|
|
129
|
+
background-size: 30rem 30rem;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
.PanoSpatialTagPlugin__tag-line {
|
|
133
|
+
position: absolute;
|
|
134
|
+
left: -1rem;
|
|
135
|
+
width: 2rem;
|
|
136
|
+
height: 100%;
|
|
137
|
+
overflow: hidden;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
.PanoSpatialTagPlugin__tag-flagpole {
|
|
141
|
+
position: absolute;
|
|
142
|
+
top: 0;
|
|
143
|
+
left: 1rem;
|
|
144
|
+
height: calc(100% - 1.5rem);
|
|
145
|
+
width: .15rem;
|
|
146
|
+
background: linear-gradient(to bottom, rgba(255, 255, 255, 1), rgba(255, 255, 255, .1));
|
|
147
|
+
box-shadow: 0 .1rem .5rem rgba(0, 0, 0, .2);
|
|
148
|
+
opacity: 0;
|
|
149
|
+
transform: translate(-50%, 60%) scaleY(0);
|
|
150
|
+
transition: transform .4s cubic-bezier(.44,.44,.74,.98) , opacity .4s cubic-bezier(.44,.44,.74,.98), width .5s linear, height .5s linear ;
|
|
151
|
+
transform-origin: center bottom;
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
.PanoSpatialTagPlugin__tag-line1 {
|
|
155
|
+
position: absolute;
|
|
156
|
+
top: 0;
|
|
157
|
+
left: 0.3rem;
|
|
158
|
+
height: 1.8rem;
|
|
159
|
+
width: .1rem;
|
|
160
|
+
background: #fff;
|
|
161
|
+
opacity: 0;
|
|
162
|
+
transform: translate(-50%, 200%) scaleY(0);
|
|
163
|
+
transform-origin: center top;
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
.PanoSpatialTagPlugin__tag-line2 {
|
|
167
|
+
position: absolute;
|
|
168
|
+
top: 0;
|
|
169
|
+
left: 0.5rem;
|
|
170
|
+
height: 1.8rem;
|
|
171
|
+
width: .1rem;
|
|
172
|
+
background: #fff;
|
|
173
|
+
opacity: 0;
|
|
174
|
+
transform: translate(-50%, 200%) scaleY(0);
|
|
175
|
+
transform-origin: center top;
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
.PanoSpatialTagPlugin__tag-show .PanoSpatialTagPlugin__tag-line1 {
|
|
179
|
+
animation: PanoSpatialTagPlugin__tag-line1 linear .5s forwards .45s;
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
.PanoSpatialTagPlugin__tag-show .PanoSpatialTagPlugin__tag-line2 {
|
|
183
|
+
animation: PanoSpatialTagPlugin__tag-line2 linear .5s forwards .65s;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
.PanoSpatialTagPlugin__tag-x.PanoSpatialTagPlugin__tag-upside-down {
|
|
187
|
+
transform: translate(0, 0);
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
.PanoSpatialTagPlugin__tag-upside-down .PanoSpatialTagPlugin__tag-line {
|
|
191
|
+
transform: scaleY(-1);
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
.PanoSpatialTagPlugin__tag-animate {
|
|
195
|
+
position: relative;
|
|
196
|
+
height: 100%;
|
|
197
|
+
overflow: hidden;
|
|
198
|
+
transform-origin: left top;
|
|
199
|
+
transition: transform .5s linear;
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
.PanoSpatialTagPlugin__tag-upside-down .PanoSpatialTagPlugin__tag-animate{
|
|
203
|
+
transform-origin: left bottom;
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
.PanoSpatialTagPlugin__tag-content {
|
|
207
|
+
position: absolute;
|
|
208
|
+
display: inline-block;
|
|
209
|
+
transform: translate(-100%, 0);
|
|
210
|
+
transition: transform .9s cubic-bezier(0,.65,.16,1.08) .6s;
|
|
211
|
+
padding-left: .5rem;
|
|
212
|
+
font-size: 1rem;
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
.PanoSpatialTagPlugin__tag-upside-down .PanoSpatialTagPlugin__tag-content{
|
|
216
|
+
bottom: 0;
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
.PanoSpatialTagPlugin__tag-show .PanoSpatialTagPlugin__tag-flagpole {
|
|
220
|
+
opacity: 1;
|
|
221
|
+
transform: translate(-50%, 0) scaleY(1);
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
.PanoSpatialTagPlugin__tag-upside-down .PanoSpatialTagPlugin__tag-shadow {
|
|
225
|
+
top: unset;
|
|
226
|
+
bottom: -15rem;
|
|
227
|
+
}
|
|
228
|
+
|
|
229
|
+
.PanoSpatialTagPlugin__tag-show .PanoSpatialTagPlugin__tag-shadow {
|
|
230
|
+
opacity: .32;
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
.PanoSpatialTagPlugin__tag-show .PanoSpatialTagPlugin__tag-content {
|
|
234
|
+
transform: translate(0, 0);
|
|
235
|
+
}
|
|
236
|
+
|
|
237
|
+
.PanoSpatialTagPlugin__tag-hide .PanoSpatialTagPlugin__tag-flagpole {
|
|
238
|
+
opacity: 0;
|
|
239
|
+
transform: translate(-50%, 60%) scaleY(0);
|
|
240
|
+
transition: transform .5s .55s, opacity .4s .55s;
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
.PanoSpatialTagPlugin__tag-hide .PanoSpatialTagPlugin__tag-shadow {
|
|
244
|
+
opacity: 0;
|
|
245
|
+
transition: opacity .8s;
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
.PanoSpatialTagPlugin__tag-hide .PanoSpatialTagPlugin__tag-content {
|
|
249
|
+
transform: translate(-100%, 0);
|
|
250
|
+
transition: transform .6s cubic-bezier(.53,.06,.88,.59);
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
.PanoSpatialTagPlugin__tag-hide .PanoSpatialTagPlugin__tag-content * {
|
|
254
|
+
pointer-events: none;
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
.PanoSpatialTagPlugin__tag-hide .PanoSpatialTagPlugin__tag-line1 {
|
|
258
|
+
opacity: 0.5;
|
|
259
|
+
transform: translate(-50%, 10%) scaleY(0);
|
|
260
|
+
animation: PanoSpatialTagPlugin__tag-line1-hide linear .28s forwards .3s;
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
.PanoSpatialTagPlugin__tag-hide .PanoSpatialTagPlugin__tag-line2 {
|
|
264
|
+
opacity: 0.5;
|
|
265
|
+
transform: translate(-50%, 0) scaleY(0);
|
|
266
|
+
animation: PanoSpatialTagPlugin__tag-line2-hide linear .28s forwards .45s;
|
|
267
|
+
}
|
|
268
|
+
|
|
269
|
+
@keyframes PanoSpatialTagPlugin__tag-line1 {
|
|
270
|
+
0% { opacity: 0; transform: translate(-50%, 250%) scaleY(1); }
|
|
271
|
+
50% { opacity: 0.5; transform: translate(-50%, 135%) scaleY(1); }
|
|
272
|
+
100% { opacity: 0.5; transform: translate(-50%, 20%) scaleY(0); }
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
@keyframes PanoSpatialTagPlugin__tag-line2 {
|
|
276
|
+
0% { opacity: 0; transform: translate(-50%, 250%) scaleY(1); }
|
|
277
|
+
50% { opacity: 0.5; transform: translate(-50%, 125%) scaleY(1); }
|
|
278
|
+
100% { opacity: 0.5; transform: translate(-50%, 0) scaleY(0); }
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
@keyframes PanoSpatialTagPlugin__tag-line1-hide {
|
|
282
|
+
0% { opacity: 0.5; transform: translate(-50%, 10%) scaleY(0); }
|
|
283
|
+
50% { opacity: 0.2; transform: translate(-50%, 105%) scaleY(1); }
|
|
284
|
+
100% { opacity: 0; transform: translate(-50%, 200%) scaleY(0); }
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
@keyframes PanoSpatialTagPlugin__tag-line2-hide {
|
|
288
|
+
0% { opacity: 0.5; transform: translate(-50%, 0) scaleY(0); }
|
|
289
|
+
50% { opacity: 0.2; transform: translate(-50%, 100%) scaleY(1); }
|
|
290
|
+
100% { opacity: 0; transform: translate(-50%, 200%) scaleY(0); }
|
|
291
|
+
}
|
|
292
|
+
</style>
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import { Five, Subscribe } from '@realsee/five';
|
|
3
3
|
import CSS3DRenderPlugin from '../CSS3DRenderPlugin';
|
|
4
|
-
import Origins from './Components/origins';
|
|
5
|
-
import Tag from './Components/tag';
|
|
4
|
+
import Origins from './Components/origins.svelte';
|
|
5
|
+
import Tag from './Components/tag.svelte';
|
|
6
6
|
import { pluginStyle } from './style';
|
|
7
7
|
import render from '../shared-utils/tinyEJSrender';
|
|
8
8
|
const MESH_SIZE = 0.001;
|
|
@@ -21,7 +21,7 @@ import NormalImage from './Normalmage';
|
|
|
21
21
|
import SvgImage from './SvgImage';
|
|
22
22
|
|
|
23
23
|
function add_css(target) {
|
|
24
|
-
append_styles(target, "svelte-
|
|
24
|
+
append_styles(target, "svelte-ozpg4a", ".floorplan-plugin__base-image.svelte-ozpg4a{position:absolute;z-index:10;width:100%;height:100%;pointer-events:none}");
|
|
25
25
|
}
|
|
26
26
|
|
|
27
27
|
// (13:22)
|
|
@@ -117,7 +117,7 @@ function create_fragment(ctx) {
|
|
|
117
117
|
c() {
|
|
118
118
|
div = element("div");
|
|
119
119
|
if (if_block) if_block.c();
|
|
120
|
-
attr(div, "class", "floorplan-plugin__base-image svelte-
|
|
120
|
+
attr(div, "class", "floorplan-plugin__base-image svelte-ozpg4a");
|
|
121
121
|
},
|
|
122
122
|
m(target, anchor) {
|
|
123
123
|
insert(target, div, anchor);
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<script>var _a, _b;
|
|
2
|
+
import NormalImage from './Normalmage.svelte';
|
|
3
|
+
import SvgImage from './SvgImage.svelte';
|
|
4
|
+
export let floorIndex;
|
|
5
|
+
export let floorplanData;
|
|
6
|
+
$: imageData = floorplanData.outlines[floorIndex];
|
|
7
|
+
$: svgContent = (_b = (_a = floorplanData.outlines) === null || _a === void 0 ? void 0 : _a[floorIndex]) === null || _b === void 0 ? void 0 : _b.svgContent;
|
|
8
|
+
</script>
|
|
9
|
+
|
|
10
|
+
<div class="floorplan-plugin__base-image">
|
|
11
|
+
{#if svgContent}
|
|
12
|
+
<SvgImage content={svgContent} />
|
|
13
|
+
{:else if imageData}
|
|
14
|
+
<NormalImage url={imageData.url} />
|
|
15
|
+
{/if}
|
|
16
|
+
</div>
|
|
17
|
+
|
|
18
|
+
<style>
|
|
19
|
+
.floorplan-plugin__base-image {
|
|
20
|
+
position: absolute;
|
|
21
|
+
z-index: 10;
|
|
22
|
+
width: 100%;
|
|
23
|
+
height: 100%;
|
|
24
|
+
pointer-events: none;
|
|
25
|
+
}
|
|
26
|
+
</style>
|
|
@@ -17,7 +17,7 @@ import { CAMERA_IMAGE } from '../Assets/camera';
|
|
|
17
17
|
import rad2Deg from '../../shared-utils/math/rad2Deg';
|
|
18
18
|
|
|
19
19
|
function add_css(target) {
|
|
20
|
-
append_styles(target, "svelte-
|
|
20
|
+
append_styles(target, "svelte-17cl35n", ".floorplan__camera-position.svelte-17cl35n{position:absolute;width:0;height:0}.floorplan__camera-rotate.svelte-17cl35n{position:absolute;background-repeat:no-repeat;background-size:100%}");
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
function create_fragment(ctx) {
|
|
@@ -28,7 +28,7 @@ function create_fragment(ctx) {
|
|
|
28
28
|
c() {
|
|
29
29
|
div1 = element("div");
|
|
30
30
|
div0 = element("div");
|
|
31
|
-
attr(div0, "class", "floorplan__camera-rotate svelte-
|
|
31
|
+
attr(div0, "class", "floorplan__camera-rotate svelte-17cl35n");
|
|
32
32
|
set_style(div0, "background-image", `url(${/*cameraImageUrl*/ ctx[0] || CAMERA_IMAGE})`);
|
|
33
33
|
set_style(div0, "width", /*domSizeStyle*/ ctx[4], false);
|
|
34
34
|
set_style(div0, "height", /*domSizeStyle*/ ctx[4], false);
|
|
@@ -36,7 +36,7 @@ function create_fragment(ctx) {
|
|
|
36
36
|
set_style(div0, "top", '-' + /*domSizeStyle*/ ctx[4], false);
|
|
37
37
|
set_style(div0, "transform", `rotate(${/*rotate*/ ctx[3]}deg)`, false);
|
|
38
38
|
set_style(div0, "transform-origin", `${/*domSizeStyle*/ ctx[4]} ${/*domSizeStyle*/ ctx[4]}`, false);
|
|
39
|
-
attr(div1, "class", "floorplan__camera-position svelte-
|
|
39
|
+
attr(div1, "class", "floorplan__camera-position svelte-17cl35n");
|
|
40
40
|
set_style(div1, "left", /*positionLeft*/ ctx[1], false);
|
|
41
41
|
set_style(div1, "top", /*positionTop*/ ctx[2], false);
|
|
42
42
|
},
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
<script>import { CAMERA_IMAGE } from '../Assets/camera';
|
|
2
|
+
import rad2Deg from '../../shared-utils/math/rad2Deg';
|
|
3
|
+
export let panoIndex;
|
|
4
|
+
export let floorplanData;
|
|
5
|
+
export let lastPanoramaLongitude;
|
|
6
|
+
export let cameraImageUrl;
|
|
7
|
+
const { observers } = floorplanData;
|
|
8
|
+
const observer = observers[panoIndex];
|
|
9
|
+
const leftRatio = observer.positionInImage.x;
|
|
10
|
+
const topRatio = observer.positionInImage.y;
|
|
11
|
+
const positionLeft = leftRatio * 100 + '%';
|
|
12
|
+
const positionTop = topRatio * 100 + '%';
|
|
13
|
+
const rotate = -rad2Deg(lastPanoramaLongitude) + 45;
|
|
14
|
+
// TODO: 统一这里的判断条件,目前写了多处
|
|
15
|
+
const bodyWidth = document.body.clientWidth;
|
|
16
|
+
const bodyHeight = document.body.clientHeight;
|
|
17
|
+
const size = bodyWidth < 500 || bodyHeight < 500 ? 17 : 37;
|
|
18
|
+
const domSizeStyle = `${size / 16}rem`;
|
|
19
|
+
</script>
|
|
20
|
+
|
|
21
|
+
<div class="floorplan__camera-position" style:left={positionLeft} style:top={positionTop}>
|
|
22
|
+
<div
|
|
23
|
+
class="floorplan__camera-rotate"
|
|
24
|
+
style:width={domSizeStyle}
|
|
25
|
+
style:height={domSizeStyle}
|
|
26
|
+
style:left={'-' + domSizeStyle}
|
|
27
|
+
style:top={'-' + domSizeStyle}
|
|
28
|
+
style:transform={`rotate(${rotate}deg)`}
|
|
29
|
+
style:transform-origin={`${domSizeStyle} ${domSizeStyle}`}
|
|
30
|
+
style="background-image: {`url(${cameraImageUrl || CAMERA_IMAGE})`}"
|
|
31
|
+
/>
|
|
32
|
+
</div>
|
|
33
|
+
|
|
34
|
+
<style lang="postcss">
|
|
35
|
+
.floorplan__camera-position {
|
|
36
|
+
position: absolute;
|
|
37
|
+
width: 0;
|
|
38
|
+
height: 0;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.floorplan__camera-rotate {
|
|
42
|
+
position: absolute;
|
|
43
|
+
background-repeat: no-repeat;
|
|
44
|
+
background-size: 100%;
|
|
45
|
+
}
|
|
46
|
+
</style>
|
|
@@ -20,7 +20,7 @@ import {
|
|
|
20
20
|
import { COMPASS_IMAGE } from '../Assets/compass';
|
|
21
21
|
|
|
22
22
|
function add_css(target) {
|
|
23
|
-
append_styles(target, "svelte-
|
|
23
|
+
append_styles(target, "svelte-z9kwkx", ".floorplan-plugin__compass.svelte-z9kwkx{position:absolute;left:50%;top:-2.39583rem;width:12.03125rem;height:2.13542rem;will-change:opacity;transform-origin:center 9.58333rem}.floorplan-plugin__compass-image.svelte-z9kwkx{width:100%;height:100%;position:absolute;left:0;top:0;opacity:0.1;background-repeat:no-repeat;background-size:100% 100%}.floorplan-plugin__compass-text.svelte-z9kwkx{position:absolute;left:50%;top:0.78125rem;transform:translateX(-50%);opacity:0.2;font-weight:bold;font-size:0.52083rem;color:#fff}");
|
|
24
24
|
}
|
|
25
25
|
|
|
26
26
|
// (14:0) {#if canCompassShow}
|
|
@@ -38,10 +38,10 @@ function create_if_block(ctx) {
|
|
|
38
38
|
t0 = space();
|
|
39
39
|
span = element("span");
|
|
40
40
|
t1 = text(/*northDesc*/ ctx[0]);
|
|
41
|
-
attr(div0, "class", "floorplan-plugin__compass-image svelte-
|
|
41
|
+
attr(div0, "class", "floorplan-plugin__compass-image svelte-z9kwkx");
|
|
42
42
|
set_style(div0, "background-image", `url(${COMPASS_IMAGE})`);
|
|
43
|
-
attr(span, "class", "floorplan-plugin__compass-text svelte-
|
|
44
|
-
attr(div1, "class", "floorplan-plugin__compass svelte-
|
|
43
|
+
attr(span, "class", "floorplan-plugin__compass-text svelte-z9kwkx");
|
|
44
|
+
attr(div1, "class", "floorplan-plugin__compass svelte-z9kwkx");
|
|
45
45
|
set_style(div1, "transform", /*compassTransformStyle*/ ctx[2], false);
|
|
46
46
|
},
|
|
47
47
|
m(target, anchor) {
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
<script>var _a;
|
|
2
|
+
import { COMPASS_IMAGE } from '../Assets/compass';
|
|
3
|
+
function rad2Deg(rad) {
|
|
4
|
+
return (rad / Math.PI) * 180;
|
|
5
|
+
}
|
|
6
|
+
export let floorplanData;
|
|
7
|
+
export let northDesc;
|
|
8
|
+
const northRad = (_a = floorplanData.entrance) === null || _a === void 0 ? void 0 : _a.northRad;
|
|
9
|
+
const canCompassShow = typeof northRad === 'number';
|
|
10
|
+
const rotate = !northRad ? 0 : rad2Deg(northRad);
|
|
11
|
+
const compassTransformStyle = `translateX(-50%) translateZ(10px) rotate(${-rotate + 90}deg)`;
|
|
12
|
+
</script>
|
|
13
|
+
|
|
14
|
+
{#if canCompassShow}
|
|
15
|
+
<div class="floorplan-plugin__compass" style:transform={compassTransformStyle}>
|
|
16
|
+
<div class="floorplan-plugin__compass-image" style="background-image: {`url(${COMPASS_IMAGE})`}" />
|
|
17
|
+
<span class="floorplan-plugin__compass-text"> {northDesc} </span>
|
|
18
|
+
</div>
|
|
19
|
+
{/if}
|
|
20
|
+
|
|
21
|
+
<style>
|
|
22
|
+
.floorplan-plugin__compass {
|
|
23
|
+
position: absolute;
|
|
24
|
+
left: 50%;
|
|
25
|
+
top: -46px;
|
|
26
|
+
width: 231px;
|
|
27
|
+
height: 41px;
|
|
28
|
+
will-change: opacity;
|
|
29
|
+
transform-origin: center 184px;
|
|
30
|
+
}
|
|
31
|
+
.floorplan-plugin__compass-image {
|
|
32
|
+
width: 100%;
|
|
33
|
+
height: 100%;
|
|
34
|
+
position: absolute;
|
|
35
|
+
left: 0;
|
|
36
|
+
top: 0;
|
|
37
|
+
opacity: 0.1;
|
|
38
|
+
background-repeat: no-repeat;
|
|
39
|
+
background-size: 100% 100%;
|
|
40
|
+
}
|
|
41
|
+
.floorplan-plugin__compass-text {
|
|
42
|
+
position: absolute;
|
|
43
|
+
left: 50%;
|
|
44
|
+
top: 15px;
|
|
45
|
+
transform: translateX(-50%);
|
|
46
|
+
opacity: 0.2;
|
|
47
|
+
font-weight: bold;
|
|
48
|
+
font-size: 10px;
|
|
49
|
+
color: #fff;
|
|
50
|
+
}
|
|
51
|
+
</style>
|
|
@@ -30,7 +30,7 @@ import RoomMaterial from './RoomMaterials/RoomMaterial';
|
|
|
30
30
|
import RoomHighlight from './RoomHighlight/RoomHighlight';
|
|
31
31
|
|
|
32
32
|
function add_css(target) {
|
|
33
|
-
append_styles(target, "svelte-
|
|
33
|
+
append_styles(target, "svelte-bl8zrz", ".floorplan-plugin__floor.svelte-bl8zrz{position:absolute;left:0;top:0;width:100%;height:100%;opacity:0;pointer-events:none}.floorplan-plugin__floor--is-current.svelte-bl8zrz{opacity:1;pointer-events:auto}");
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
// (20:2) {#if hoverEnable}
|
|
@@ -265,7 +265,7 @@ function create_fragment(ctx) {
|
|
|
265
265
|
|
|
266
266
|
attr(div, "class", div_class_value = "" + (null_to_empty(`floorplan-plugin__floor${/*isCurrent*/ ctx[0]
|
|
267
267
|
? ' floorplan-plugin__floor--is-current'
|
|
268
|
-
: ''}`) + " svelte-
|
|
268
|
+
: ''}`) + " svelte-bl8zrz"));
|
|
269
269
|
},
|
|
270
270
|
m(target, anchor) {
|
|
271
271
|
insert(target, div, anchor);
|
|
@@ -374,7 +374,7 @@ function create_fragment(ctx) {
|
|
|
374
374
|
|
|
375
375
|
if (!current || dirty & /*isCurrent*/ 1 && div_class_value !== (div_class_value = "" + (null_to_empty(`floorplan-plugin__floor${/*isCurrent*/ ctx[0]
|
|
376
376
|
? ' floorplan-plugin__floor--is-current'
|
|
377
|
-
: ''}`) + " svelte-
|
|
377
|
+
: ''}`) + " svelte-bl8zrz"))) {
|
|
378
378
|
attr(div, "class", div_class_value);
|
|
379
379
|
}
|
|
380
380
|
},
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
<script>import { writable } from 'svelte/store';
|
|
2
|
+
import BaseImage from './BaseImage.svelte';
|
|
3
|
+
import RoomLabels from './RoomLabels/RoomLabels.svelte';
|
|
4
|
+
import RuleLabels from './RuleLabels/RuleLabels.svelte';
|
|
5
|
+
import RoomMaterial from './RoomMaterials/RoomMaterial.svelte';
|
|
6
|
+
import RoomHighlight from './RoomHighlight/RoomHighlight.svelte';
|
|
7
|
+
export let isCurrent;
|
|
8
|
+
export let floorIndex;
|
|
9
|
+
export let hoverEnable;
|
|
10
|
+
export let roomLabelsEnable;
|
|
11
|
+
export let ruleLabelsEnable;
|
|
12
|
+
export let floorplanData;
|
|
13
|
+
export let getLabelElement;
|
|
14
|
+
export let adaptiveRoomLabelVisibleEnable;
|
|
15
|
+
const hoveredRoom = writable(undefined);
|
|
16
|
+
</script>
|
|
17
|
+
|
|
18
|
+
<div class={`floorplan-plugin__floor${isCurrent ? ' floorplan-plugin__floor--is-current' : ''}`}>
|
|
19
|
+
<RoomMaterial {...{ floorIndex, floorplanData }} />
|
|
20
|
+
{#if hoverEnable}
|
|
21
|
+
<RoomHighlight {...{ floorIndex, floorplanData, hoveredRoom }} />
|
|
22
|
+
{/if}
|
|
23
|
+
<BaseImage {...{ floorplanData, floorIndex }} />
|
|
24
|
+
{#if roomLabelsEnable}
|
|
25
|
+
<RoomLabels {...{ floorplanData, floorIndex, getLabelElement, hoveredRoom, adaptiveRoomLabelVisibleEnable }} />
|
|
26
|
+
{/if}
|
|
27
|
+
{#if ruleLabelsEnable}
|
|
28
|
+
<RuleLabels {...{ floorplanData, floorIndex }} />
|
|
29
|
+
{/if}
|
|
30
|
+
</div>
|
|
31
|
+
|
|
32
|
+
<style>
|
|
33
|
+
.floorplan-plugin__floor {
|
|
34
|
+
position: absolute;
|
|
35
|
+
left: 0;
|
|
36
|
+
top: 0;
|
|
37
|
+
width: 100%;
|
|
38
|
+
height: 100%;
|
|
39
|
+
opacity: 0;
|
|
40
|
+
pointer-events: none;
|
|
41
|
+
}
|
|
42
|
+
.floorplan-plugin__floor--is-current {
|
|
43
|
+
opacity: 1;
|
|
44
|
+
pointer-events: auto;
|
|
45
|
+
}
|
|
46
|
+
</style>
|
|
@@ -32,7 +32,7 @@ import Compass from './Compass';
|
|
|
32
32
|
import CurrentFloor from './CurrentFloor';
|
|
33
33
|
|
|
34
34
|
function add_css(target) {
|
|
35
|
-
append_styles(target, "svelte-
|
|
35
|
+
append_styles(target, "svelte-86bqav", ".floorplan-main.svelte-86bqav{width:100%;height:100%;pointer-events:none}");
|
|
36
36
|
}
|
|
37
37
|
|
|
38
38
|
function get_each_context(ctx, list, i) {
|
|
@@ -90,7 +90,7 @@ function create_if_block(ctx) {
|
|
|
90
90
|
create_component(camera.$$.fragment);
|
|
91
91
|
t1 = space();
|
|
92
92
|
if (if_block) if_block.c();
|
|
93
|
-
attr(div, "class", "floorplan-main svelte-
|
|
93
|
+
attr(div, "class", "floorplan-main svelte-86bqav");
|
|
94
94
|
},
|
|
95
95
|
m(target, anchor) {
|
|
96
96
|
insert(target, div, anchor);
|