-
-
Notifications
You must be signed in to change notification settings - Fork 771
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
A way to disable gesture handling on the sheet's content #85
Comments
@adamsoutar thanks for submitting this enhancement, this already in progress , check #75 & #76 👏 |
Thank you! I should've looked harder first |
I just pushed an alpha release for v2, please try it and let me know :) also check out the new documents website ( still in progress ) 🎉 yarn add @gorhom/bottom-sheet@2.0.0-alpha.2 |
@gorhom This now works, thanks! |
For anyone finding this from Google ... |
Feature Request
Hi, for some controls on Android you can't replace the Touchables with ones from this lib. For example, a native
<Switch />
or buttons/tabs from other 3rd party dependencies. This makes quite a few components unusable within sheets.Is there a way to disable gesture handling on the content so only the handle is draggable, leaving normal touchables working in the sheet?
reanimated-bottom-sheet
hasenabledHeaderGestureInteraction
,enabledContentGestureInteraction
, andenabledContentTapInteraction
props which can be composed to get this behaviour on Android.As a side-note, is it possible to produce this behaviour already - perhaps by wrapping the content in a gesture handler and not allowing the events to propagate?
Possible implementation
The implementation might involve wrapping the header & content in separate
TapGestureHandler
/PanGestureHandler
s, and allowing us to toggle whether each is wrapped in them using props.Code sample
Usage might look something like:
The text was updated successfully, but these errors were encountered: