Closed abyrd closed 4 years ago
I'm also noticing some zooms where part of the itinerary is hidden by interface widgets. It might be best if there were no "floating" widgets at all to obstruct the map interface.
@abyrd Did you find a solution?
Not yet, contributions are welcome though if you can improve the behavior!
@abyrd I find a solution what fits in my use case. Just made a window.map = map
variable in the client.js
and thereby I just set window.map.fitBounds = function() {};
in my custom index.js
to disable the fitBounds function without getting any errors. Works perfect for me!
This is a matter of opinion, but I find the zooming and panning of the map when switching between alternative itineraries to make it harder to read. It is of course necessary at some points in the interaction to guide the user to the right area and keep the bulk of the route within the window, but small adjustments are not necessary. Perhaps a good rule would be to skip the zoom/pan step if the origin, destination, and all transfer points are already inside the viewport.