From 359021328678dea966c7d94cb12882ed7b9df7c0 Mon Sep 17 00:00:00 2001 From: ISA Date: Tue, 18 Jun 2024 11:25:57 +0200 Subject: [PATCH] =?UTF-8?q?fix:=20Blickfeld=20aus=20initialwert=20lassen?= =?UTF-8?q?=20in=20MapComponent.js=20map.fitBounds(group.getBounds().pad(0?= =?UTF-8?q?.5));.=20Diese=20Zeile=20passt=20die=20Karte=20an,=20sodass=20a?= =?UTF-8?q?lle=20Elemente=20in=20group=20(also=20Marker=20und=20Polylinien?= =?UTF-8?q?)=20im=20Blickfeld=20sind.=20Dies=20kann=20dazu=20f=C3=BChren,?= =?UTF-8?q?=20dass=20der=20Zoom-Level=20ge=C3=A4ndert=20wird,?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/MapComponent.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/MapComponent.js b/components/MapComponent.js index e6b781cc6..a0e625fd9 100644 --- a/components/MapComponent.js +++ b/components/MapComponent.js @@ -2199,7 +2199,7 @@ const MapComponent = ({ locations, onLocationUpdate, lineCoordinates }) => { // Fit map to show all markers and polylines const group = new L.featureGroup([...markers, polyline]); - map.fitBounds(group.getBounds().pad(0.5)); + // map.fitBounds(group.getBounds().pad(0.5)); }); }, [map, linePositions, lineColors]); // Run this effect when `map` is ready