问题描述:使用 position: fixed; 设置蒙层后,在安卓上正常,ios上下滑动会造成底层盒子上下滚动
解决方案:
watch: {
// 解决ios遮罩层滚动穿透问题
visible: {
handler(flag) {
const parentNode = document.querySelector('.more-operations').parentNode
parentNode.style.overflowY = flag ? 'hidden' : 'auto'
}
}
}
v-model和sync封装【更多操作】弹层