mirror of
https://github.com/netzmacht/contao-leaflet-maps.git
synced 2025-12-05 06:18:39 +01:00
Fix bounds mode handling.
This commit is contained in:
@@ -29,6 +29,8 @@ L.Map.include({
|
||||
this.eachLayer(this._scanForBounds, this);
|
||||
}
|
||||
|
||||
console.log(this._dynamicBounds);
|
||||
|
||||
if (this._dynamicBounds) {
|
||||
this.fitBounds(this._dynamicBounds);
|
||||
}
|
||||
@@ -75,7 +77,7 @@ L.Map.include({
|
||||
}
|
||||
}
|
||||
} else if ((!layer.options || (layer.options
|
||||
&& layer.options.boundsMode && layer.options.boundsMode == 'extend')) && layer.eachLayer) {
|
||||
&& layer.options.boundsMode && !layer.options.ignoreForBounds)) && layer.eachLayer) {
|
||||
layer.eachLayer(this._scanForBounds, this);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user