Skip to content

Cannot Open Listbox in Mobile Chrome (Android) #3750

@rubber-duck-software

Description

@rubber-duck-software

What package within Headless UI are you using?

@headlessui/react

What version of that package are you using?

v2.2.4

What browser are you using?

Chrome

Reproduction URL

This bug is easy to see in Catalyst when using Mobile Chrome on Android or when in Mobile viewer for chrome dev tools.

https://catalyst.tailwindui.com/docs/listbox.

Describe your issue

Attempt to open the listbox in mobile Chrome. Let your click be just a tiny big sluggish (> 100ms). The listbox will close immediately, preventing the user from making a selection. See video below

CleanShot.2025-06-25.at.11.12.06.mp4

Headless UI recently started using the pointerdown event for ListboxButton instead of the click event. On mobile chrome, this now results in the following sequence

  1. User Begins Click
  2. ListboxButton receives pointerdown event
  3. ListboxOptions opens
  4. User Finishes Click
  5. ListboxOption receives click event
  6. ListboxOptions closes

This all happens in the space of 100ms or so and in a single user tap.

This bug affects any mobile ui where the ListboxOptions element covers the ListboxButton element.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions