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

Form 组件 scroll-to-error 在使用 tab 滚动吸顶的时候,被吸顶的tab挡住 #12822

Open
DreamSeeker321 opened this issue Apr 23, 2024 · 0 comments

Comments

@DreamSeeker321
Copy link

DreamSeeker321 commented Apr 23, 2024

项目中使用了tab组件, 并且开启了scrollspy sticky, 内部嵌入了form,然后form触发submit的时候,滚动到报错为止后,报错部分被吸顶的tab遮挡。

<van-tabs v-model:active="active" scrollspy sticky>
  <van-tab v-for="index in 8" :title="'选项 ' + index">
    <van-form></van-form>
  </van-tab>
</van-tabs>

可能的解决办法:
1、滚动到错误时,错误的元素在屏幕中间位置。
2、滚动到错误时,可以设置距离顶部的距离。

Tasks

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

No branches or pull requests

1 participant