Account for content pages without content or a scroll indicator

This commit is contained in:
Jake Howard 2024-01-05 14:18:50 +00:00
parent 3984660e2b
commit e0ffa6a14d
Signed by: jake
GPG key ID: 57AFB45680EDD477

View file

@ -23,11 +23,13 @@ function handleScrollIndicator() {
}
window.addEventListener("load", () => {
window.addEventListener("resize", handleScrollIndicator);
window.addEventListener("scroll", handleScrollIndicator);
if (CONTENT && SCROLL_INDICATOR) {
window.addEventListener("resize", handleScrollIndicator);
window.addEventListener("scroll", handleScrollIndicator);
// Initialize the indicator
handleScrollIndicator();
}
GLightbox({});
// Initialize the indicator
handleScrollIndicator();
});