nativescript-slides icon indicating copy to clipboard operation
nativescript-slides copied to clipboard

Issue with sliding when used inside scroll-view

Open shripalsoni04 opened this issue 9 years ago • 0 comments

When we use this plugin with scroll-view, it is very difficult to swipe the slides.

On iOS, we can swipe the slides but alongwith that scroll-view will also scroll vertically.

On Android, if we do not swipe exact horizontally, it will not move to the next slide.

Here are the previews of issue on Android/iOS.

Preview in iOS

nativescript-slides-scroll-view-issue-ios

Preview in Android

nativescript-slides-scroll-view-issue-android

Sample Project

I have cloned this repository and just added scroll-view related code in main-page.xml. You can find the complete project here: https://github.com/shripalsoni04/ns-slides-scrollview-issue/tree/master/demo

I think the issue is when we swipe, the scroll-view also scrolls vertical by some amount, and due to that the 'pan' gesture is getting cancelled. This results in cancellation of slide move on Android. I don't know how but I think we need to stop the propagation of touch event when deltaX is beyond some threshold, may be +- 3

It will be great if you can suggest any solution or workaround for this issue.

shripalsoni04 avatar Aug 29 '16 12:08 shripalsoni04