uniapp中input框聚焦"/>
uniapp中input框聚焦
在需要聚焦的方法内写入
this.Focus = true;
// 获取软键盘的高度
uni.onKeyboardHeightChange(res => {console.log(res.height);if (res.height === 0) {this.Focus = false;
}
})
然后在失去焦点的时候
this.Focus = false;
更多推荐
uniapp中input框聚焦
发布评论