Comments (7)
I was running into this issue as well, and managed to resolve it by calling the _update method on the GL layer whenever the map is zoomed.
var map = L.map(...);
var gl = L.mapboxGL(...).addTo(map);
map.on('zoomend',function(){
gl._update();
}
from mapbox-gl-leaflet.
Finally getting a little time to try and fix those issues ...
This one is actually the same issue as one of my other project:
fnicollet/Leaflet#1
at zoom 0/1, the top/left corner coordinates is outside the "world boundaries" and gets clamped, which produce an offset.
This has been fixed by @IvanSanchez in this commit on Renderer.js:
Leaflet/Leaflet@a2595bb
So now, I just have to port it to this project, but so far, I can't figure out how to do the calculation for the top-left corner ...
from mapbox-gl-leaflet.
Having this issue as well! Also when I zoom out and then click on a clustermarker the map sometimes doesn't load at all or the markers are offset a bit.
Is there any discussion on integrating mapbox-gl-leaflet into leaflet core?
Let me know if there's anything I can help?
from mapbox-gl-leaflet.
from mapbox-gl-leaflet.
Thanks for you answer.
Here's a screenshot with the issue from the cluster example. I believe it's exactly the same as mentioned by @EreMaijala .
If you click on a cluster which is far away, the map doesn't load completely and the markers are offset by a bit. However, when you just slightly move the map with the mouse it adjusts and is then shown correctly again. How can we fix this?
from mapbox-gl-leaflet.
Any progress about the shifting issue? It would be more or less perfect if this issue would be gone.
from mapbox-gl-leaflet.
resolved via #95
from mapbox-gl-leaflet.
Related Issues (20)
- missing issue from here HOT 1
- Getting: Error: Source layer "aerodrome_label" does not exist on source "openmaptiles" ..... HOT 4
- Supporting MapLibre HOT 6
- request to enable OAuth access for gh-release in the Mapbox GitHub organization
- Access Token Issue - Mapbox GL JS v2+ HOT 4
- I feel stuck when I quickly drag the map in your example, 'events. html' HOT 1
- Leaflet markers move around on pan, depending on Zoom HOT 8
- Map panning broken in mapbox-gl 2.5 HOT 5
- Mapbox logo/attribution controls not visible
- Canvas image is blank HOT 1
- jsfiddle template from readme not working
- Map keeps shaking with percentage sizes HOT 7
- Polyline moves on pan / zoom
- Map gets stuck with version 2.8.2 of mapbox gl HOT 1
- In interactive mode, Mapbox fires spurious mousemove events on drag/pan HOT 1
- OSM/mapbox vector tiles update HOT 1
- leaflet__WEBPACK_IMPORTED_MODULE_4___default.a.mapboxGL is not a functio HOT 1
- The mapbox gl map does not show if a TileLayer is added to the map. HOT 1
- L.mapboxGL is not a function in production builds of vite, but not in development.
- mapbox layer has a error location when the leaflet map pan to the top
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mapbox-gl-leaflet.