Replies: 2 comments 4 replies
-
did you manage to solve this, i am facing the same problem? |
Beta Was this translation helpful? Give feedback.
1 reply
-
I solved it using |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm trying to implement a bottom sheet from scratch where the container sheet panning and inner scrollview scrolling would seamlessly switch gesture handling based on sheet's position/offset.
Here's my code so far:
the idea behind this implementation is that, once sheetOffset hits the top (sheetOffset.value <= positions[0]), customGesture should not active therefore nativeGesture would activate itself.
it works perfectly for one direction: from customGesture to nativeGesture but I can't deactivate/fail nativeGesture back again in order to continue handling the gesture move with customGesture.
ideal UX would be a user holding their finger and moving sheet from the middle (position[1]) all the way up and continue moving their finger while customGesture to nativeGesture handling transition happens WITHOUT requiring user to lift their finger and touch screen again. this works fine with the above code.
the problem is, when user starts to move their finger back down again, scrollview scrolls up but never deactivates and gives it back to customGesture in order to move the container sheet down when scrollview is already at the top. (again, hopefully this should not require user to lift their finger and put back onto screen).
so, how can I seamlessly switch gesture handling between my customGesture (Pan) and nativeGesture (ScrollView) on the fly while user is moving their finger on the screen?
any suggestion and/or API or source code reference would be great!
Beta Was this translation helpful? Give feedback.
All reactions