Änderungen

322 Bytes hinzugefügt ,  19:50, 5. Mai 2021
K
fix #36
Zeile 159: Zeile 159:  
$( document ).ready(function() {
 
$( document ).ready(function() {
 
   $('.tabs-label').click(function(e) {
 
   $('.tabs-label').click(function(e) {
     setTimeout(function() {
+
     var mapExists = setInterval(function() {
    const maplist = window.mapsLeafletList;
+
    var counter = 0;
    if (maplist) maplist.forEach(l => {
+
    console.log("[mapResize] couter:", counter);
    if (l.map) l.map.invalidateSize(false);  
+
const maplist = window.mapsLeafletList;
     });
+
if (maplist) {
    }, 200);
+
maplist.forEach(l => {
 +
if (l.map) {
 +
console.log("[mapResize] invalidateSize");
 +
l.map.invalidateSize(false);
 +
    clearInterval(mapExists);
 +
    }
 +
    });
 +
     }
 +
    if (counter++ > 10) {
 +
    console.warn("[mapResize] watchdog exit, couter:", counter);
 +
    clearInterval(mapExists);
 +
    }
 +
}, 100);
 
   });
 
   });
 
});
 
});