react-native-zoomable-view icon indicating copy to clipboard operation
react-native-zoomable-view copied to clipboard

Scroll with two fingers

Open libasoles opened this issue 5 years ago • 4 comments

Hi. This library is great, thank you.

Just one thing: scrolling while zooming should be possible. That's the common behaviour if you zoom in chrome by example.

By other hand, in my case i'm not zooming a static image, but a drawing canvas. So, I'm disabling the one finger gestures like this:

handleMoveShouldSetPanResponder = (e, gestureState) => {
    return gestureState.numberActiveTouches === 2;
  };

However, doing that makes it impossible to scroll now. Because I can't scroll with two fingers.

libasoles avatar Aug 30 '19 17:08 libasoles

Sorry for the late reply. I am working on a new version of this package. I plan to release a beta in about 2 weeks, that should have this functionality.

SimonErich avatar Nov 06 '19 12:11 SimonErich

Sorry for the long response times. Unfortunately version 2 of this package never really made sense. I planned on refactoring it, but ended up with something very similar in performance. If somebody has time to pick this issue up, I would really appreciate it.

SimonErich avatar Jun 10 '21 08:06 SimonErich

Looking for a React Native component that supports two-finger pan and zoom as well.

tlmader avatar Mar 12 '22 22:03 tlmader

@tlmader look no further. Check out OpenSpace Labs fork of react-native-zoomable-view. Fyi this is officially the successor of this library.

From the README:

What sets this library apart from the other zoom-pan libraries? This library offers a much better user experience than the others:

  • The ability to zoom and pan at the same time.
  • No jittering during zooming.
  • Zoom center correctly placed at the pinch center - currently this is the ONLY react-native library that offers this.
  • And many other goodies. Check out the documentation below for more details.

Disclaimer: I'm a contributor of the OpenSpace Labs fork

thomasttvo avatar May 18 '22 20:05 thomasttvo