mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
fix(Tabbar): get correct height in mobile safari (#10185)
This commit is contained in:
parent
03f77d4bba
commit
edaf7ec45b
@ -56,7 +56,13 @@ export default createComponent({
|
|||||||
|
|
||||||
mounted() {
|
mounted() {
|
||||||
if (this.placeholder && this.fixed) {
|
if (this.placeholder && this.fixed) {
|
||||||
this.height = this.$refs.tabbar.getBoundingClientRect().height;
|
const setHeight = () => {
|
||||||
|
this.height = this.$refs.tabbar.getBoundingClientRect().height;
|
||||||
|
};
|
||||||
|
|
||||||
|
setHeight();
|
||||||
|
// https://github.com/youzan/vant/issues/10131
|
||||||
|
setTimeout(setHeight, 100);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user