Commit 4c8d0a17 authored by youjie's avatar youjie

行程绝对定位

parent 768841c9
<template> <template>
<div style="min-height: 80vh"> <div style="min-height: 80vh">
<div class=""
style="max-width: 1200px; margin: auto;position: relative;">
<div style="position: fixed; left: 0; right: 0; top: 0; border-top: 1px solid #eee; box-shadow: 0 2px 8px rgb(0 0 0 / 20%); z-index: 9999999" class="bg-white" <div style="position: fixed; left: 0; right: 0; top: 0; border-top: 1px solid #eee; box-shadow: 0 2px 8px rgb(0 0 0 / 20%); z-index: 9999999" class="bg-white"
v-if="(currentHeight > navs[0].top + 100&&$q.platform.is.desktop)|| v-if="(currentHeight > navs[0].top + 100&&$q.platform.is.desktop)||
(currentHeight>priceListHeight&&currentHeight < navs[0].top&&$q.platform.is.mobile)" (currentHeight>priceListHeight&&currentHeight < navs[0].top&&$q.platform.is.mobile)"
...@@ -204,9 +206,9 @@ ...@@ -204,9 +206,9 @@
> >
<!-- col q-ml-xl position-relative --> <!-- col q-ml-xl position-relative -->
<!-- days.length>0&&dayList.length>3&&currentHeight > days[0].top-60&&currentHeight < navs[2].top&&$q.platform.is.desktop --> <!-- days.length>0&&dayList.length>3&&currentHeight > days[0].top-60&&currentHeight < navs[2].top&&$q.platform.is.desktop -->
<div :class="{'fixed':$q.platform.is.desktop}" <div
:style="{'top':currentHeight>navs[1].top?'200px':'200px', class="absolute" style="z-index: 999;left:-116px;"
'left':currentHeight>navs[1].top?'120px':'130px',}" :style="{'top':currentHeight>navs[1].top?(currentHeight+100)+'px':(currentHeight+200)+'px'}"
v-if=" v-if="
dataList.priceList.length > 0&&$q.platform.is.desktop&&currentHeight>navs[1].top-400 dataList.priceList.length > 0&&$q.platform.is.desktop&&currentHeight>navs[1].top-400
&&currentHeight<navs[2].top &&currentHeight<navs[2].top
...@@ -278,11 +280,10 @@ ...@@ -278,11 +280,10 @@
<!-- <div class="col-1"></div> --> <!-- <div class="col-1"></div> -->
<!-- col q-ml-xl position-relative --> <!-- col q-ml-xl position-relative -->
<div <div
:class="{'absolute':currentHeight<1000, class="absolute" style="z-index: 999;right: -150px;"
'fixed':currentHeight>1000}" :style="{'top':currentHeight<1000?'1000px':(currentHeight+100)+'px'}">
:style="{'top':currentHeight<1000?'0':'100px', <!-- position: sticky; top: 100px -->
'right':currentHeight<1000?'-150px':'70px',}"> <div style="">
<div style="position: sticky; top: 100px">
<div <div
class="text-subtitle2 text-grey-6 cursor-pointer q-mb-md" class="text-subtitle2 text-grey-6 cursor-pointer q-mb-md"
v-for="(x, i) in navs" v-for="(x, i) in navs"
...@@ -298,6 +299,8 @@ ...@@ -298,6 +299,8 @@
</div> </div>
</template> </template>
</div> </div>
</div>
<div class="goBackTop bg-primary" :class="{ showGoback: isShowTop }" @click="hangleGoUp"> <div class="goBackTop bg-primary" :class="{ showGoback: isShowTop }" @click="hangleGoUp">
<i class="iconfont iconarrow-top"></i> <i class="iconfont iconarrow-top"></i>
</div> </div>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment