osm-fr / osmose-frontend

Part of osmose that shows results on the website http://osmose.openstreetmap.fr
GNU General Public License v3.0
41 stars 38 forks source link

Marker-map offset when first opened #366

Closed harry-wood closed 3 months ago

harry-wood commented 2 years ago

There's an incorrect offset in the positioning of all the issue markers when the map is first opened. It resolves itself after zooming

For example this red marker is suppose to point directly at the "20" number on the map. After zooming it jumps to the right place.

animation

The offset applies to all markers in the view, at all zoom-levels. The offset is always approx 35 pixels to the left and 35 pixels up, and this is the same pixel distance regardless of zoom level (perhaps something strange with leaflet "anchor" position handling)

frodrigo commented 2 years ago

The issue is know and more complex, time by time, a concurrency issue in JS happen. It results of shifted vector tile display.

It due to hackish usage by Osmose of low support of vector tile on leaflet.

Osmose use Leaflet.VectorGrid https://github.com/Leaflet/Leaflet.VectorGrid

But Leaflet.VectorGrid does not support display outside of tile boundaries. Osmose do a hack on top of this to display Point of issue as non clipped marker.

frodrigo commented 3 months ago

Done with the switch to MapLibre.