mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-24 18:36:51 +08:00
[bugfix] Tabs: fix scroll position deviation when sticky (#3949)
This commit is contained in:
parent
43e0bd0123
commit
632e4c1d31
@ -120,7 +120,7 @@ export default createComponent({
|
|||||||
|
|
||||||
// scroll to correct position
|
// scroll to correct position
|
||||||
if (this.stickyFixed) {
|
if (this.stickyFixed) {
|
||||||
setRootScrollTop(getElementTop(this.$el) - this.offsetTop);
|
setRootScrollTop(Math.ceil(getElementTop(this.$el) - this.offsetTop));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
Loading…
x
Reference in New Issue
Block a user