visx icon indicating copy to clipboard operation
visx copied to clipboard

Zoom: Disable or override wheel gesture

Open RamonEspinosa opened this issue 8 months ago • 0 comments

I'm working on a page that shows a map similar to Geo Custom Demo.

The map projection takes a good chunk of the page's width and height. This makes it super hard for users to scroll down to see the rest of the page because the map will intercept the wheel event. Basically, to see the rest of the page, users need to scroll outside the map.

We thought of two solutions to this problem:

  1. Use ctrl + scroll to scroll in the map, similar to what google maps do for embedded maps: image
  2. Disable wheel handler and only allow zooming by using the controls ( + / - / reset)

However, i don't think the @visx/zoom package supports either.

RamonEspinosa avatar May 31 '24 20:05 RamonEspinosa