primitives icon indicating copy to clipboard operation
primitives copied to clipboard

[Dialog] Unable to pinch zoom using trackpad

Open chesterhow opened this issue 2 years ago • 6 comments

Bug report

Congrats on the 1.0 release! I see that the allowPinchZoom prop has been removed and now defaults to true. However, there is still an issue with pinch zooming: it is not supported on trackpads.

I understand that allowPinchZoom is a prop for the underlying react-remove-scroll library, and I filed an issue with them a couple of weeks back (https://github.com/theKashey/react-remove-scroll/issues/75). The maintainer has acknowledged the issue but it doesn't seem like there will be a fix anytime soon.

Current Behavior

When a dialog is open (or any primitive that uses react-remove-scroll), I am unable to pinch-and-zoom the webpage using the trackpad.

Expected behavior

I should still be able to pinch-and-zoom using the webpage when the dialog is open.

Reproducible example

This is reproducible in the dialog example in the Radix docs: https://www.radix-ui.com/docs/primitives/components/dialog

Additional context

I am using Dialog to render a full-screen modal of sorts which displays an image. An expected common behavior here would be that I am able to pinch-and-zoom on the image.

chesterhow avatar Jul 22 '22 04:07 chesterhow