headlessui icon indicating copy to clipboard operation
headlessui copied to clipboard

Mobile - Dropdowns automatically close when scrolling outside of the dropdown element.

Open jeroen-fonky opened this issue 1 year ago • 3 comments

What package within Headless UI are you using? @headlessui/vue

What version of that package are you using? 1.7.17

What browser are you using? Chrome

Reproduction URL https://headlessui.com/vue/listbox

Description On mobile phone, opened dropdowns automatically close when scrolling outside of the dropdown element. The error 986-51ff325a1976a40c.js:1 [Intervention] Ignored attempt to cancel a touchend event with cancelable=false, for example because scrolling is in progress and cannot be interrupted. is thrown.

Steps to reproduce:

  • Open https://headlessui.com/vue/listbox
  • Open the dropdown
  • Open dev tools
  • Use Dimensions: responsive and make the page so small that a scrollbar appears within the scrollbar
  • Click outside of the modal and move down (like scrolling down on your mobile phone)
  • Your dropdown automatically closes, which is annoying
  • There's an error in the console

jeroen-fonky avatar Mar 15 '24 14:03 jeroen-fonky

I have the same issue with the Popover

peter-neumann-dev avatar Apr 21 '24 19:04 peter-neumann-dev

Me too!

oebiesoft avatar May 21 '24 13:05 oebiesoft

Me too !

zenodegenkamp avatar May 24 '24 07:05 zenodegenkamp

Reproducable, @peter-neumann-dev @oebiesoft @zenodegenkamp have you guys found a way to fix it?

nikitas avatar May 30 '24 12:05 nikitas

Hey!

This should be fixed by #3266, and will be available in the next release.

You can already try it using:

  • npm install @headlessui/react@insiders.
  • npm install @headlessui/vue@insiders.

RobinMalfait avatar Jun 03 '24 14:06 RobinMalfait

Thanks for your efforts, keep up the good work!

jeroen-fonky avatar Jun 04 '24 08:06 jeroen-fonky