|
@@ -51,9 +51,9 @@
|
|
|
uni.getSystemInfo({
|
|
|
success(res) {
|
|
|
const os = res.system.toLowerCase()
|
|
|
+ console.log(res)
|
|
|
self.$config.os = os
|
|
|
if (os.includes('windows') || os.includes('mac')) {
|
|
|
- // 可在pc端隐藏导航
|
|
|
self.$emit('init', {
|
|
|
detail: {
|
|
|
navbarHeight: 0,
|
|
@@ -70,6 +70,13 @@
|
|
|
// pageHeight: windowInfo.screenHeight - (windowInfo.screenWidth / 750 * 100)
|
|
|
// }
|
|
|
// })
|
|
|
+ } else {
|
|
|
+ self.$emit('init', {
|
|
|
+ detail: {
|
|
|
+ navbarHeight: self.hideNavbar ? 0 : (self.statusBarHeight + self.titleBarHeight),
|
|
|
+ pageHeight: windowInfo.screenHeight - (self.hideNavbar ? 0 : (self.statusBarHeight + self.titleBarHeight)) - res.safeAreaInsets.bottom
|
|
|
+ }
|
|
|
+ })
|
|
|
}
|
|
|
}
|
|
|
})
|
|
@@ -87,16 +94,23 @@
|
|
|
pageHeight: windowInfo.screenHeight - (windowInfo.screenWidth / 750 * 120)
|
|
|
}
|
|
|
})
|
|
|
+ } else {
|
|
|
+ self.$emit('init', {
|
|
|
+ detail: {
|
|
|
+ navbarHeight: self.hideNavbar ? 0 : (self.statusBarHeight + self.titleBarHeight),
|
|
|
+ pageHeight: windowInfo.screenHeight - (self.hideNavbar ? 0 : (self.statusBarHeight + self.titleBarHeight))- res.safeAreaInsets.bottom
|
|
|
+ }
|
|
|
+ })
|
|
|
}
|
|
|
}
|
|
|
})
|
|
|
}
|
|
|
- this.$emit('init', {
|
|
|
- detail: {
|
|
|
- navbarHeight: self.hideNavbar ? 0 : (this.statusBarHeight + this.titleBarHeight),
|
|
|
- pageHeight: windowInfo.screenHeight - (self.hideNavbar ? 0 : (this.statusBarHeight + this.titleBarHeight))
|
|
|
- }
|
|
|
- })
|
|
|
+ // this.$emit('init', {
|
|
|
+ // detail: {
|
|
|
+ // navbarHeight: self.hideNavbar ? 0 : (this.statusBarHeight + this.titleBarHeight),
|
|
|
+ // pageHeight: windowInfo.screenHeight - (self.hideNavbar ? 0 : (this.statusBarHeight + this.titleBarHeight))
|
|
|
+ // }
|
|
|
+ // })
|
|
|
},
|
|
|
methods: {
|
|
|
hasSlot() {
|