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

Tabs (v18): Empty tab list #17051

Open
hunhejj opened this issue Dec 13, 2024 · 2 comments · May be fixed by #17235
Open

Tabs (v18): Empty tab list #17051

hunhejj opened this issue Dec 13, 2024 · 2 comments · May be fixed by #17235
Labels
Resolution: Help Wanted Issue or pull request requires extra help and feedback
Milestone

Comments

@hunhejj
Copy link
Contributor

hunhejj commented Dec 13, 2024

Describe the bug

When I have a scrollable tab list (see my demo) and I navigate far to the right,

kép

then filter the underlying tab list such that only a single tab remains should be displayed, then

  1. 🐛 I end up with an empty tab list and
  2. I need to first scroll far back to the right before I see any selectable tab

kép

After navigating back to the beginning of the list, I see my single tab.

  1. 🐛 The right scroll control is still visible although clearly it shouldn't be scrollable anymore because the new tab list is so narrow
  2. 🐛 I can still scroll to the right

kép

When selecting the first tab

  1. 🐛 The right scroll control remains visible
  2. 🐛 However compared to before I can't to the right anymore, clicking on it has no affect.

Note that similar bugs happen, if I start with a single tab, i.e. no scroll controls and then replace the tab list with a loooong tab list. The scroll controls don't necessarily become visible.

Environment

Stackblitz

Reproducer

https://stackblitz.com/edit/stackblitz-starters-v2tohicl

Angular version

18.2.0

PrimeNG version

18.0.0

Expected behavior

  • scroll to visible tabs (ideally scroll to the selected tab if one is selected)
  • update the visibility of the scroll handlers, hide/show them based on the width of the new tab list
@hunhejj hunhejj added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Dec 13, 2024
@mertsincan mertsincan added Resolution: Help Wanted Issue or pull request requires extra help and feedback and removed Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible labels Dec 16, 2024
@mertsincan mertsincan added this to the 19.x milestone Dec 16, 2024
@github-project-automation github-project-automation bot moved this to Review in PrimeNG Dec 16, 2024
Copy link

Due to PrimeNG team's busy roadmap, this issue is available for anyone to work on. Make sure to reference this issue in your pull request. ✨ Thank you for your contribution! ✨

@qwadrox
Copy link
Contributor

qwadrox commented Dec 26, 2024

I could reproduce this bug on the V19 master.

qwadrox added a commit to qwadrox/primeng that referenced this issue Dec 27, 2024
@qwadrox qwadrox linked a pull request Dec 27, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution: Help Wanted Issue or pull request requires extra help and feedback
Projects
Status: Review
Development

Successfully merging a pull request may close this issue.

3 participants