-
-
Notifications
You must be signed in to change notification settings - Fork 774
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
rendering incomplete when using setPadding() #5486
Comments
Can you please create a minimal reproduction with minimal layers using jsbin or equivalent? |
5.0.0-pre.5 is good, will provide a more minimal reproduction tomorrow |
Got it down to one layer and put it in a jsbin to play around: NOTE: make the output window as big as possible for better reconstruction <!DOCTYPE html>
<html>
<head>
<script src="https://unpkg.com/maplibre-gl@5.0.0-pre.6/dist/maplibre-gl.js"></script>
<link href="https://unpkg.com/maplibre-gl@5.0.0-pre.6/dist/maplibre-gl.css" rel="stylesheet" />
</head>
<body>
<style>
body, html, #map { height: 100%; width: 100% }
</style>
<div id="map"></div>
<script>
var map = new maplibregl.Map({
style: {
"version": 8,
"sources": {
"sym_vector": {
"type": "vector",
"url": "https://search.ch/map.vector/tilejson/sym_vector.json"
}
},
"layers": [{
"type": "fill",
"paint": { "fill-color": "green" },
"source": "sym_vector",
"source-layer": "wood",
"id": "wood"
}]
},
center: [ 7.881186, 46.291304 ],
zoom: 11,
container: 'map',
hash: true
});
map.showPadding = 1;
map.setPadding({ top:100, left: 300, bottom:100, right: 300 });
</script>
</body>
</html> |
I'm guessing this is related to the covering tiles changes made as part of pre-release 6. pre.5: |
Somehow the map renders not properly anymore when using
map.setPadding()
using our styles.It worked in maplibre-gl-js 4.7.1, and is broken in 5.0.0 and 5.1.0.
Steps to Trigger Behavior
using Firefox or Chromium on Linux on a reasonably big display
Link to Demonstration
https://test.twin.search.ch/pub/maplibre_setpadding_5.1.0.html
Expected Behavior
Map renders properly everywhere.
https://test.twin.search.ch/pub/maplibre_setpadding_4.7.1.html works properly.
Actual Behavior
Map doesn't render properly on the left and right side. See screenshots.
5.1.0:
![Image](https://private-user-images.githubusercontent.com/2202604/411606609-725ee384-4896-480e-bf47-ae7759513ead.png?jwt=eyJhb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JQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI1MDIxMiUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNTAyMTJUMDkwMzM1WiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9ZmQ4YzEyYzNmN2FlOWM2NmZmMDg1N2EyMWI0NjViNWMzZWZhYTYwOTNjZjFjZjdiNTA5NGQ3NWE4ZWJhOTU3YiZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QifQ.eHC4PeSRvdBdUC7-JH4IxdCVyArQqm2d8aQ3v58vFPw)
The text was updated successfully, but these errors were encountered: