question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Can't zoom with scrollwheel

See original GitHub issue

I’ve tried reading the docs, the source, and the demo that is provided. But I can’t for the life of me figure out why I can’t get zooming to work with the scroll wheel. It works on the demo, so I can’t tell if it’s my code.

<Map
center={[
  geoLocation?.latitude ?? 34.050888,
  geoLocation?.longitude ?? -118.242854
]}
animate={false}
metaWheelZoomWarning={true}
zoom={(geoLocation && 18) ?? 12}
width={600}
height={400}
>
{geoLocation && <Marker
  anchor={[
    geoLocation.latitude,
    geoLocation.longitude
  ]}
  payload={1}
/> }
</Map>

I’ve tried removing the marker.

I don’t get the meta zoom warning overlay.

I’ve tried using Firefox and Chromium. I’m on Ubuntu Linux. I tested on Windows with Edge as well.

Versions

"pigeon-maps": "^0.14.0",
"pigeon-marker": "^0.3.4",

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:11 (5 by maintainers)

github_iconTop GitHub Comments

3reactions
Maark007commented, Jan 31, 2020

Do like that work for me:

    center: [50.1102, 3.1506],
    zoom: 7,
    minZoom: 3,
    maxZoom: 16,
  });
  return (
    <div style={{ height: '100vh', width: '100%' }}>
      <Map
        center={locations.center}
        zoom={locations.zoom}
        minZoom={locations.minZoom}
        maxZoom={locations.maxZoom}
      >
      </Map >
    </div>```
1reaction
mariusandracommented, Dec 1, 2020

That can stay in the if. Make sure to also move the unbindWheelEvent event.

Read more comments on GitHub >

github_iconTop Results From Across the Web

4 Easy Ways to Fix Scroll Wheel Stuck on Zoom
4 Easy Ways to Fix Scroll Wheel Stuck on Zoom · 1. Check for stuck keys. Press Windows + R to open the...
Read more >
How to Fix Mouse Zooming Instead of Scrolling on Windows 10?
Method 1: Testing for stuck CTRL key ... As it turns out, one of the most common causes that will trigger this kind...
Read more >
7 Ways to Fix a Mouse Wheel That Keeps Zooming Instead of ...
7 Ways to Fix a Mouse Wheel That Keeps Zooming Instead of Scrolling on Windows · 1. Ensure the Ctrl Key Isn't Stuck...
Read more >
Mouse wheel is zooming instead of scrolling
There are many reasons why your mouse is only zooming instead of scrolling. Most commonly, this problem occurs when the Ctrl key gets...
Read more >
Windows 10 Touch Screen Zooms Rather than Scolls
One of the most common causes that will trigger this kind of behavior is a stuck CTRL-key. If you didn't know, if you...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found