We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2ae8d1f commit 3b77141Copy full SHA for 3b77141
src/mapml/utils/Util.js
@@ -533,11 +533,12 @@ export var Util = {
533
layer.parentElement.querySelectorAll('layer-').length === 1
534
)
535
layer.parentElement.projection = layer._layer.getProjection();
536
- if (layer.extent) {
537
- if (zoomTo)
538
- layer.parentElement.zoomTo(+zoomTo.lat, +zoomTo.lng, +zoomTo.z);
539
- else layer.zoomTo();
+ if (!layer.extent) {
+ layer._layer._setLayerElExtent();
540
}
+ if (zoomTo)
+ layer.parentElement.zoomTo(+zoomTo.lat, +zoomTo.lng, +zoomTo.z);
541
+ else layer.zoomTo();
542
if (opacity) layer.opacity = opacity;
543
map.getContainer().focus();
544
});
0 commit comments