fix(form): 优化webview场景下H5导航栏的隐藏逻辑

通过条件编译只在H5环境下隐藏导航栏,避免小程序webview
环境下出现导航栏空白区域
This commit is contained in:
2026-05-28 16:51:50 +08:00
parent a6189a5f9e
commit 8d350b24e5

View File

@@ -80,6 +80,15 @@ export default {
})
}
// #ifdef H5
if (this.isFromMpWebView) {
this.$nextTick(() => {
const navbar = document.querySelector('.uni-page-head')
if (navbar) navbar.style.display = 'none'
})
}
// #endif
this.getData()
},