fix: Automatische Aktualisierung von Spiderfy/Unspiderfy im Intervall
- `map.fire("click")` im `setInterval()` hinzugefügt, um Linien sofort auszublenden
- Spiderfy/Unspiderfy wird nun regelmäßig aktualisiert, ohne manuelles Klicken
- Debugging-Log hinzugefügt, um Klick-Event zu überwachen
This commit is contained in:
@@ -868,7 +868,12 @@ const MapComponent = ({ locations, onLocationUpdate, lineCoordinates }) => {
|
||||
// Setze ein Intervall für regelmäßige Updates
|
||||
const intervalId = setInterval(() => {
|
||||
updateAllMarkers();
|
||||
}, 20000); // 20 Sekunden
|
||||
|
||||
if (map) {
|
||||
console.log("🔥 Automatischer Klick-Event ausgelöst, um Spiderfy zu aktualisieren.");
|
||||
map.fire("click");
|
||||
}
|
||||
}, 20000);
|
||||
|
||||
// Aufräumen bei Komponentenentladung
|
||||
return () => {
|
||||
|
||||
Reference in New Issue
Block a user