Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

vue2使用van-tabs组件使用scrollspy属性滚动后 ios设备点击标签会自动切换到上一个标签 #13227

Open
sodagreen574 opened this issue Nov 21, 2024 · 1 comment

Comments

@sodagreen574
Copy link

重现链接

https://gofile.io/d/6msw5O

Vant 版本

2.13.2

描述一下你遇到的问题。

在使用vant-tabs组件时。安卓正常。在ios 微信浏览器中。切换tab。会导致定位不准确。会向上切换一级activeName。比如。我切换到下标2应该是第三个tab高亮。bug会直接高亮下标为1的也就是第二个tab高亮了。这是错误的。视频截屏已经能够看得到这个bug的复现形式了。

重现步骤

切换导航。就能复现

设备/浏览器

No response

@sodagreen574
Copy link
Author

目前解决方式 是通过将duration设置成0,但是就没有动画过渡效果了,看起来非常生硬

还有一种解决方式是通过before-change 不return,直接this.$refs.xxx.scrollTo(name),但是这样实现 导航栏是有过渡效果了,但是滚动条滚动还是没有平滑过渡效果。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant