Closed Lawris closed 2 years ago
Have you tried using pagingPriority
@Lawris ?
This can be fixed if you use simulateneousGesture
in your SampleSheet
. Check it out:
Just tested it now, it works flawlessly, thanks a lot for taking the time! Cheers.
Hello, first of all thanks for this fantastic package that I've been playing around with for the past few days! I went through all swipe-related issues without success, so I am openning an issue.
Describe the bug I have a "draggable" bottom sheet wich includes an horizontal pager inside. In order to be draggable (from top to bottom only), the bottom sheet uses .gesture(). It looks like the Pager and the gesture on the bottom sheet are colliding.
I can drag down the bottom sheet by swiping somewhere outside the pager, but when I try to drag down the bottom sheet by swipping on the Pager area, it does not work.
Here is a video to illustrate the current behavior:
https://user-images.githubusercontent.com/15719068/150989607-62f16cd0-c8fb-4d7a-8220-1dc69f9a57da.mov
Here is the code to replicate what's on the video:
I tried replacing .gesture() with .highPriorityGesture(). It does work since it overrides the children gestures, but the Pager is not responsive anymore.
I also tried playing with .swipeInteractionArea(), .delaysTouches() and .pagingPriority() without success.
Maybe it is worth mentionning that using a HStack embedded in a ScrollView does not obstruct the vertical swipe of the upper view.
So my question is: is it possible to tweak the Pager in order for it to not prevent the vertical swipe of the upper view when swipping from the Pager area?
Any help is greatly appreciated.