Fixing how the consent banner loads
Deploy Company Site / test (push) Successful in 10s
Deploy Company Site / deploy (push) Successful in 5s

This commit is contained in:
2026-06-28 07:14:35 -05:00
parent 0f2b255b59
commit 63edf8c64f
@@ -28,17 +28,17 @@
} }
} }
function hideBanner() {
var banner = document.getElementById('cookie-consent-banner');
if (banner) {
banner.hidden = true;
}
}
function showBanner() { function showBanner() {
var banner = document.getElementById('cookie-consent-banner'); var banner = document.getElementById('cookie-consent-banner');
if (banner) { if (banner) {
banner.hidden = false; banner.removeAttribute('hidden');
}
}
function hideBanner() {
var banner = document.getElementById('cookie-consent-banner');
if (banner) {
banner.setAttribute('hidden', '');
} }
} }
@@ -140,7 +140,7 @@
}); });
}; };
document.addEventListener('DOMContentLoaded', function () { function initConsent() {
bindBannerControls(); bindBannerControls();
var consent = getConsent(); var consent = getConsent();
@@ -155,5 +155,7 @@
} }
showBanner(); showBanner();
}); }
initConsent();
})(); })();