Skip to content

bug: PR #4142 breaks vertical scrolling in <select multiple> with fixed height #4178

@kiyot

Description

@kiyot

Reproduction URL (Required)

https://stackblitz.com/edit/daisyui5-gagcrk76?file=src%2Fmain.js

What version of daisyUI are you using?

5.1.27

Which browsers are you seeing the problem on?

All browsers

Describe your issue

Describe the bug

After upgrading to daisyUI 5.1.27 (which includes PR #4142), <select multiple> elements with a fixed height
no longer have functional vertical scrollbars. The content is cut off and users cannot scroll to see all options.

To Reproduce

  1. Create a <select multiple> element with daisyUI classes
  2. Add options so that scroll is needed
  3. Observe that the scrollbar is either missing or non-functional

Expected behavior

The select element should display a vertical scrollbar and allow users to scroll through all available options when the content exceeds the fixed height.

Code example

<select multiple  class="select w-full select-multiple">
  <option>Option 1</option>
  <option>Option 2</option>
  <!-- ... many more options ... -->
  <option>Option 20</option>
</select>

Affected version

Additional context

PR #4142 was intended to fix text wrapping in select options, but the changes (possibly overflow: hidden) inadvertently disabled scrolling for multiple select elements.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions