Closed gregmsanderson closed 2 months ago
Set "max-height" "overflow-y-auto" into
<Select.Root>
<Select.Trigger class="w-[180px]">
<Select.Value placeholder="Theme" />
</Select.Trigger>
<Select.Content class="max-h-[200px] overflow-y-auto">
<Select.Item value="light">Light</Select.Item>
<Select.Item value="dark">Dark</Select.Item>
<Select.Item value="system">System</Select.Item>
</Select.Content>
</Select.Root>
But yes, this isn't the default behavior. It needs a quick fix ASAP.
@FaeWulf Ah, yes, that's a good idea.
It looks like the original React one has max-h-96
on its inner div (which is presumably the Content one). So that prevents it getting too huge.
Closing as fixed in bits-ui@next
Describe the bug
If a select includes many items it does not add up/down arrows, or scroll the way a native select element would (or how the original shadcn behaves, which would be a better comparison).
If you scroll down this page you can see the Scrollable part which demonstrates this:
https://ui.shadcn.com/docs/components/select
Reproduction
https://ui.shadcn.com/docs/components/select
Logs
No response
System Info
Severity
annoyance