|
@@ -107,9 +107,7 @@ import { ref, computed, watch, onMounted, onBeforeUnmount, inject } from "vue"
|
|
import { useRoute, useRouter } from "vue-router"
|
|
import { useRoute, useRouter } from "vue-router"
|
|
import { useStore } from "vuex"
|
|
import { useStore } from "vuex"
|
|
import useSizeAdapt from '@/useFunctions/useSizeAdapt.js'
|
|
import useSizeAdapt from '@/useFunctions/useSizeAdapt.js'
|
|
-import { useDevicePixelRatio } from '@vueuse/core'
|
|
|
|
-
|
|
|
|
-const { pixelRatio } = useDevicePixelRatio()
|
|
|
|
|
|
+import { useWindowSize } from "@vueuse/core"
|
|
|
|
|
|
const route = useRoute()
|
|
const route = useRoute()
|
|
const router = useRouter()
|
|
const router = useRouter()
|
|
@@ -122,6 +120,9 @@ const {
|
|
|
|
|
|
const $env = inject('$env')
|
|
const $env = inject('$env')
|
|
|
|
|
|
|
|
+const { width: windowWidth, height: windowHeight } = useWindowSize()
|
|
|
|
+const windowHeightDesign = 1080 - 71 - 37 // 设计稿里视口高度。注意要减去上下边栏
|
|
|
|
+
|
|
const hotspot1X = ref(-100)
|
|
const hotspot1X = ref(-100)
|
|
const hotspot1Y = ref(-100)
|
|
const hotspot1Y = ref(-100)
|
|
const hotspot2X = ref(-100)
|
|
const hotspot2X = ref(-100)
|
|
@@ -243,15 +244,15 @@ const activeVideoIdx = ref(0)
|
|
|
|
|
|
>button.play-video{
|
|
>button.play-video{
|
|
position: absolute;
|
|
position: absolute;
|
|
- bottom: calc(37px / v-bind('pixelRatio'));
|
|
|
|
- right: calc(33px / v-bind('pixelRatio'));
|
|
|
|
|
|
+ bottom: calc(37px / v-bind('windowHeightDesign') * v-bind('windowHeight'));
|
|
|
|
+ right: calc(33px / v-bind('windowHeightDesign') * v-bind('windowHeight'));
|
|
display: flex;
|
|
display: flex;
|
|
flex-direction: column;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
align-items: center;
|
|
>img{
|
|
>img{
|
|
- width: calc(48px / v-bind('pixelRatio'));
|
|
|
|
- height: calc(48px / v-bind('pixelRatio'));
|
|
|
|
- margin-bottom: calc(14px / v-bind('pixelRatio'));
|
|
|
|
|
|
+ width: calc(48px / v-bind('windowHeightDesign') * v-bind('windowHeight'));
|
|
|
|
+ height: calc(48px / v-bind('windowHeightDesign') * v-bind('windowHeight'));
|
|
|
|
+ margin-bottom: calc(14px / v-bind('windowHeightDesign') * v-bind('windowHeight'));
|
|
}
|
|
}
|
|
>img.icon-normal{
|
|
>img.icon-normal{
|
|
display: block;
|
|
display: block;
|
|
@@ -262,9 +263,9 @@ const activeVideoIdx = ref(0)
|
|
>span{
|
|
>span{
|
|
font-family: KaiTi, KaiTi;
|
|
font-family: KaiTi, KaiTi;
|
|
font-weight: 400;
|
|
font-weight: 400;
|
|
- font-size: calc(20px / v-bind('pixelRatio'));
|
|
|
|
|
|
+ font-size: calc(20px / v-bind('windowHeightDesign') * v-bind('windowHeight'));
|
|
color: #7B916B;
|
|
color: #7B916B;
|
|
- line-height: calc(23px / v-bind('pixelRatio'));
|
|
|
|
|
|
+ line-height: calc(23px / v-bind('windowHeightDesign') * v-bind('windowHeight'));
|
|
}
|
|
}
|
|
}
|
|
}
|
|
>button.play-video:hover{
|
|
>button.play-video:hover{
|