react-native-swipe-navigation icon indicating copy to clipboard operation
react-native-swipe-navigation copied to clipboard

Using scrollview inside react-native-swipe-navigation

Open loic-lopez opened this issue 6 years ago • 4 comments

Hi,

Thanks a lot for making this package, it is possible to use a scrollview inside Messages view in the snapchat example?

Thans for reply.

loic-lopez avatar May 05 '18 12:05 loic-lopez

Hi, I didn't try it but I think you can use a scrollview inside a screen but you have to hold the navigation using

nav.onNavigateShouldAllow(() => { return false; // you can do it using component's state for example return this.state.hold });

I'm sorry for the late but I'll try to support this library

AZZB avatar May 07 '18 08:05 AZZB

Thanks for reply, i will try it 👍

loic-lopez avatar May 07 '18 08:05 loic-lopez

@loic-lopez If you do not care about up/down navigation like my case... I got around this problem by modifying Gesture.js as follows

      onMoveShouldSetPanResponderCapture: (e, { dy, dx }) => {
        if (dy > 5 || dy < -5) {
          return false
        }
        ....

silky smooth scrollview and left/right navigation still!

code-matt avatar Sep 08 '18 18:09 code-matt

Really is this library was Good enough for using scrollview inside navigation? Thanks in advance!

stunning0001 avatar Nov 13 '18 02:11 stunning0001