document.addEventListener("DOMContentLoaded", function() { console.log("test"); setTimeout(function() { const markers = document.querySelectorAll("[aria-label]"); markers.forEach(marker => { let status = marker.getAttribute("aria-label"); let colors = { "Active": "#2ECC71", "En cours de création": "#3498DB", "En veille": "#F39C12" }; for (const key in colors) { if (status.includes(key)) { marker.querySelector('img').style.filter = `hue-rotate(180deg) saturate(100%) brightness(100%)`; marker.querySelector('img').style.backgroundColor = colors[key]; } } }); }, 2000); });