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

Select list is not scrollable, so there are unreachable items if it overflows the viewport #275

Closed
atuttle opened this issue Jan 13, 2024 · 4 comments

Comments

@atuttle
Copy link

atuttle commented Jan 13, 2024

Describe the bug

If you have a particularly long list of items (or a particularly short viewport), the items list in <Select> overflows outside the viewport and doesn't scroll, causing some items to be unreachable.

Perhaps not worth considering until #235 gets figured out, though.

Reproduction

Easy enough to see it in action on the bits docs; just pull up the select page, pop open dev-tools and resize it to take up most of the vertical space for the page, then toggle open the select, and note that items go off-screen and can't be selected.

Logs

No response

System Info

System:
    OS: macOS 14.2.1
    CPU: (10) arm64 Apple M1 Pro
    Memory: 528.41 MB / 32.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 18.18.0 - ~/n/bin/node
    npm: 10.2.0 - ~/.npm_globals/bin/npm
    pnpm: 8.10.4 - ~/.npm_globals/bin/pnpm
    bun: 1.0.0 - ~/.bun/bin/bun
  Browsers:
    Brave Browser: 120.1.61.101
    Chrome: 119.0.6045.123
    Safari: 17.2.1
  npmPackages:
    @sveltejs/kit: ^2.0.0 => 2.3.2 
    bits-ui: ^0.11.8 => 0.11.8 
    svelte: ^4.2.0 => 4.2.0 


### Severity

annoyance
@huntabyte
Copy link
Owner

Would you mind providing a video/screenshot of the specific behavior you're experiencing so I can determine if it's a styling issue or a floating UI configuration issue?

@atuttle
Copy link
Author

atuttle commented Jan 13, 2024

bits-select-overflow.mov

@atuttle
Copy link
Author

atuttle commented Jan 13, 2024

It's not obvious in the video, but around the 0:15 mark I was trying the scroll gesture to scroll the page/popover. Nothing moves -- I believe this is a feature; the page scrolling gets disabled.

@huntabyte
Copy link
Owner

Yeah, it's a feature but can be disabled using the preventScroll prop. You can also adjust the Floating UI behavior using the <Select.Content /> props. I could set a height and overflow on the content and it would fix itself on the docs I believe!

@huntabyte huntabyte closed this as not planned Won't fix, can't repro, duplicate, stale Jan 19, 2024
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

2 participants