login.vue 用了 web-view,引入js作为动画背景,app端的web-view层级太高,代码无法覆盖到背景上面显示(网页端可以用定位显示)
<web-view :style="{height:mapHeight+'px',width:'750rpx',background:'#377df6'}" src="/hybrid/html/demo/index.html"></web-view>
</view> ```
所以在page.json中,给login加入subNVues弹窗
``` {
"path": "pages/login",
"style": {
"navigationBarTitleText": "",
"enablePullDownRefresh": false,
"navigationStyle": "custom",
"navigationBarTextStyle": "white",
"subNVues": [{ //弹出层
"id": "popup",
"path": "pages/subNVue/popup",
"style": {
"position": "popup",
"margin": "auto",
"width": "100%",
//这里的宽高都设置成100%,才能挡住整个页面,虽然底部的tabbar不能遮挡住,但是点击页面不会有反应
"height": "100%",
"background": "rgba(0,0,0,0.1)",
"zindex": "999999"
}
}]
}
}
0 个回复