From b4af25bbcda17b5c9eeefcf213f40626cc8b4537 Mon Sep 17 00:00:00 2001 From: Stephen Tafoya Date: Thu, 11 Jun 2026 02:30:16 -0600 Subject: [PATCH] fade out --- script.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/script.js b/script.js index 4748acc..624e530 100644 --- a/script.js +++ b/script.js @@ -1040,9 +1040,11 @@ entries.forEach(function(entry) { if (entry.isIntersecting) { entry.target.classList.add('revealed'); + } else { + entry.target.classList.remove('revealed'); } }); - }, { threshold: 0.1 }); + }, { threshold: 0, rootMargin: '-40px 0px' }); reveals.forEach(function(el) { revealObserver.observe(el); }); // Stat counter