d3-zoom icon indicating copy to clipboard operation
d3-zoom copied to clipboard

macOS trackpad pinch zoom on Safari is not working

Open moklick opened this issue 4 years ago • 3 comments

Hey!

I can not use pinch zoom on a macbook trackpad on Safari. The issue is reproducible with this example: https://observablehq.com/@d3/delaunay-find-zoom?collection=@d3/d3-zoom

It seems that Safari is not using event.ctrlKey + event.type === 'wheel' for identifying a pinch zoom but uses gesturestart, gesturechange and gestureend. Are you planing to implement listeners for these events or should we implement them on our own?

moklick avatar Jan 26 '21 11:01 moklick

Thanks for the report. Yes, we would want to implement this — contributions are welcome.

Fil avatar Jan 26 '21 15:01 Fil

Thanks for the fast reply! I'm not sure if I can help here but I'll look into it.

moklick avatar Jan 26 '21 16:01 moklick

Looks like https://github.com/antimatter15/d3-pinch-zoom was an attempt at this.

Richard-Mlynarik avatar May 22 '22 20:05 Richard-Mlynarik

This seems to be fixed. The example above is now working in Safari.

moklick avatar Jun 11 '24 09:06 moklick