Leaflet will become even better if you add …

a gestureHandling option to L.Map

Google Maps JS has a gestureHandling option which can be set to 'none', 'greedy', 'cooperative' or 'auto'.

Currently, Leaflet only has a 'greedy' mode where moving with one finger pans the map.
But when Leaflet is used as part of a scrolling page, this one finger panning interferes with page scrolling.

Google Maps' solution is to require two fingers to move the map when gestureHandling is 'cooperative'.

This would make Leaflet a no-brainer to embed in scrolling pages. I couldnt find plugins that enable this behaviour.

More: https://developers.google.com/maps/documentation/javascript/interaction

122 votes
Vote
Sign in
Check!
(thinking…)
Reset
or sign in with
  • facebook
  • google
    Password icon
    Signed in as (Sign out)
    You have left! (?) (thinking…)
    Gijs Nijholt shared this idea  ·   ·  Admin →

    2 comments

    Sign in
    Check!
    (thinking…)
    Reset
    or sign in with
    • facebook
    • google
      Password icon
      Signed in as (Sign out)
      Submitting...

      Feedback and Knowledge Base