uniapp 全屏蒙版下的其他view禁止滑动

有使生效有时无效

template===

<view class="bottom" >
<text @tap.stop="tabMask">底部区域</text>
<view class="mask" v-if="maskT" @touchmove.stop.prevent="moveHandle">
<view class="mask-con" @tap="tabMask" >
蒙版内部
</view>
</view>
</view>

script===

data() {
return {
maskT:false
}
},
methods: {
tabMask(){
this.maskT = !this.maskT
},
moveHandle(){ //禁止蒙版下内容滑动

},

}

style===

.bottom{
690rpx;
height: 600rpx;
margin: 0 auto;
text-align: center;
margin-top: 300rpx;
font-size: 48rpx;

}
.mask{
position: fixed;
top: 0;
left: 0;
100vw;
height: 100vh;
z-index: 999;
background-color: rgba(0,0,0,0.5);
}
.mask-con{
position: absolute;
top: calc(50% - 300rpx);
left: calc(50% - 345rpx);
690rpx;
height: 600rpx;
background-color: #FFFFFF;
border-radius: 32rpx;
display: flex;
justify-content: center;
align-items: center;
font-size: 48rpx;
}

忍一时,越想越气; 退一步,哎呦我去!
原文地址:https://www.cnblogs.com/l-ialiu/p/14680153.html