huntabyte / vaul-svelte

An unstyled drawer component for Svelte.
https://vaul-svelte.com
MIT License
467 stars 19 forks source link

Support `[data-vaul-no-drag]` to prevent dragging on specific elements #63

Closed didier closed 8 months ago

didier commented 8 months ago

Describe the feature in detail (code, mocks, or screenshots encouraged)

The React version of Vaul recently added support to disable dragging on specific elements. I'm currently experiencing issues with drag on inputs - when I drag and release above an input, the input gets focused and the scroll does a jagged snap.

[data-vaul-no-drag]: When interacting with an element with this data attribute, the drawer won't be dragged. https://arc.net/l/quote/fvdgmtwh

What type of pull request would this be?

New Feature

Provide relevant links or additional information.

https://arc.net/l/quote/fvdgmtwh https://github.com/emilkowalski/vaul#root

shyakadavis commented 8 months ago

Salut;

Found something that could resolve this; let me see if I can submit a P.R for it in a few. 🙂