data () {
return {
clientHeight: document.documentElement.clientHeight
}
}
mounted () {
var n = navigator.userAgent
if (n.indexOf('iPhone') <= -1) {
window.onresize = () => {
if (this.clientHeight > document.documentElement.clientHeight) {
// 隐藏按钮
this.isShow = true
} else {
// 显示按钮
this.isShow = false
}
}
}
}