Skip to content

itinerary: 'mousewheel' handler calling stopPropagation breaks scroll in Firefox #721

@DennisOSRM

Description

@DennisOSRM

Description:
The itinerary control adds a 'mousewheel' listener that calls L.DomEvent.stopPropagation(e), which in Firefox can cause the page to zoom instead of letting the directions pane scroll.

Reproduction:

  1. Open https://map.project-osrm.org/
  2. Click two locations to create a route
  3. Attempt to scroll the directions list with mouse wheel in Firefox — page zooms instead of the list scrolling.

Suggested fix:
Replace the explicit 'mousewheel' handler with L.DomEvent.disableScrollPropagation(this._container) so Leaflet handles cross-browser 'wheel' events correctly.

References:

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions