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

[FR]: tabs的title使用position:sticky定位失效 #2905

Open
lim-c5 opened this issue Jan 31, 2024 · 1 comment
Open

[FR]: tabs的title使用position:sticky定位失效 #2905

lim-c5 opened this issue Jan 31, 2024 · 1 comment
Labels
Feature Request 新功能请求

Comments

@lim-c5
Copy link

lim-c5 commented Jan 31, 2024

NutUI 包名

@nutui/nutui

这个功能解决了什么问题?

  • 排查后发现你们是给元素类名nut-tabs的设置了overflow:hidden;将其重置为unset后,position:sticky生效;
  • 但是这样又引发了另外一个问题,tabs的内容区域,由于overflow:hidden被重置掉,导致页面可以滑动,展示超出视口范围内的内容;
  • 目前我通过修改依赖包中tabs的源码,给元素类目为nut-tabs__content,添加一个父级元素,设置样式overflow:hidden;达到我期望的

你期望的组件设计是怎样的?

期望组件设计稍微调整一下样式和结构,这样既不影响原有功能,也可以达到我想要的功能

@lim-c5 lim-c5 added the Feature Request 新功能请求 label Jan 31, 2024
@jacksyk
Copy link

jacksyk commented Feb 17, 2025

同,遇到了这个问题

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature Request 新功能请求
Projects
None yet
Development

No branches or pull requests

2 participants