CaptainCodeman / svelte-headlessui

HeadlessUI components for Svelte
https://captaincodeman.github.io/svelte-headlessui/
MIT License
529 stars 25 forks source link

How to prevent autoclose menu after selecting option? #70

Closed Pawel-Zygmunt closed 1 month ago

Pawel-Zygmunt commented 10 months ago

Do I need to control this with my own state and use this instead $menu.expanded, handle outside click and so on? Or is there an easier way ?

CaptainCodeman commented 10 months ago

I think the best approach might be to allow control via the event itself (e.g. preventDefault or return false) - I'll have a play around and see what feels right.