Advertisement
Igor150195

asasasd

Feb 27th, 2025 (edited)
211
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. const section = document.querySelector(".create-doc-mobile.site-section");
  2. if (window.scrollY > window.innerHeight - 500) {
  3.     section.classList.add("animate-section-button");
  4. } else {
  5.     section.classList.remove("animate-section-button");
  6. }
  7.  
  8. document.addEventListener("scroll", function() {
  9.     const section = document.querySelector(".create-doc-mobile.site-section");
  10.     if (window.scrollY > window.innerHeight - 500) {
  11.         section.classList.add("animate-section-button");
  12.     } else {
  13.         section.classList.remove("animate-section-button");
  14.     }
  15. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement