Title: Use scroll snap after scrollsequence ends
Last modified: June 1, 2023

---

# Use scroll snap after scrollsequence ends

 *  Resolved [frehbein](https://wordpress.org/support/users/frehbein/)
 * (@frehbein)
 * [2 years, 12 months ago](https://wordpress.org/support/topic/use-scroll-snap-after-scrollsequence-ends/)
 * Hi,
 * I’m trying to add a scroll snap “animation” to the section that comes after the
   scrollsequence.
 * After the scrollsequence the scrolling speed looks like it’s too fast because
   of the sudden change of a sticky section to a normal one. As a solution for this
   I’m trying to add a scroll snap to the section that comes right after scrollsequence.
   I tried both, code (HTML, CSS and javascript) and elementor pro’s scroll snap
   option but nothing is working.
 * What I have is:
 * **-Section 1** – Scrollsequence
   **-Section 2** – A text widget that goes above
   section 1 when scrolling. This section scrolls up and sticks to the top until
   section 1 ends.**-Section 3** – a video widget that I want to have the scroll
   snap effect or something similar that slows down or stops the section from scrolling
   so the viewer can adapt its vision from the scrollsequence flow to a normal one.
 * Until now, what I’ve gather is when I add scroll snap to section 3, section 2
   doesn’t unstick when section 1 ends and stays fixed the whole page. The scroll
   snap effect doesn’t works either.
 * This is the code I have for section 2 that is probably in comflit with scroll
   snap:
 * 
   <style>
 * .fixed-div { position: sticky; top: 0; z-index: 999; } **(section 2)**
 * .unfixed { position: absolute !important; }
 * .video-intro { height: 100vh; } **(section3)**
 * </style>
 *     ```wp-block-code
       <script>
   
       var scrollEnabled = true; 
   
       window.addEventListener('scroll', function() { 
       var fixedDiv = document.querySelector('.fixed-div');
       var videoIntro = document.querySelector('.video-intro');
       var scrollY = window.scrollY || window.pageYOffset; 
   
       if (fixedDiv && videoIntro) { 
       var videoIntroPosition = videoIntro.getBoundingClientRect().top; 
       var unstickThreshold = 500; // Adjust this value as needed 
   
       if (videoIntroPosition <= unstickThreshold) { 
       fixedDiv.classList.add('unfixed');
       fixedDiv.style.top = (videoIntroPosition - unstickThreshold +
       scrollY) + 'px';
       } else { 
       fixedDiv.classList.remove('unfixed'); 
       fixedDiv.style.top = '0';
        } 
       // Check if scrolling is temporarily disabled 
       if (!scrollEnabled) {
        window.scrollTo(0, scrollY); 
       } 
       } 
       }); 
   
       // Disable scrolling for a few seconds 
       function disableScrolling(duration) {
       scrollEnabled = false;
       setTimeout(function() {
       scrollEnabled = true;
       }, duration);
       }
   
       // Call the disableScrolling function with the desired duration (in milliseconds)
       disableScrolling(2000); // 2000 milliseconds = 2 seconds
   
       </script>
       ```
   

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Plugin Author [Scrollsequence](https://wordpress.org/support/users/scrollsequence/)
 * (@scrollsequence)
 * [2 years, 11 months ago](https://wordpress.org/support/topic/use-scroll-snap-after-scrollsequence-ends/#post-16795225)
 * Hi [frehbein](https://wordpress.org/support/users/frehbein/),
 * Could you please share the URL with us so I can see what you are doing?
 * Ales
 * Plugin Author
 *  Thread Starter [frehbein](https://wordpress.org/support/users/frehbein/)
 * (@frehbein)
 * [2 years, 11 months ago](https://wordpress.org/support/topic/use-scroll-snap-after-scrollsequence-ends/#post-16795321)
 * Hi Ales,
 * here is an example of what my page looks like: [https://test.aurapartners.pt/?page_id=2805](https://test.aurapartners.pt/?page_id=2805)
 * I’d like the section after the scrollsequence (in this case, the video section)
   to do the scroll snap effect. Example of what I’d like to happen: [https://plasticenergy.com/#Intro](https://plasticenergy.com/#Intro)–
   when you scroll, there is a subtle pause in each section.
 *  Plugin Author [Scrollsequence](https://wordpress.org/support/users/scrollsequence/)
 * (@scrollsequence)
 * [2 years, 11 months ago](https://wordpress.org/support/topic/use-scroll-snap-after-scrollsequence-ends/#post-16795420)
 * Hi [frehbein](https://wordpress.org/support/users/frehbein/),
 * Thanks for the information provided.
 * Scroll snap effect as in the example you have provided is not part of the plugin.
   We try to avoid “scroll jacking” technique because it is quite controversial.
 * Nevertheless I you can just add the video into another Scene – this way it would
   be fixed to the screen and would seem natural. To add a Scene, press the plus
   button at the top of the plugin UI.
 * Also in the premium version you could animate the video position in sync with
   the scroll using a “from” animation to make it even more intuitive.
 * Let me know if any of the above helped you out 🙂
 * Ales
 * Plugin Author
    -  This reply was modified 2 years, 11 months ago by [Scrollsequence](https://wordpress.org/support/users/scrollsequence/).
 *  Plugin Author [Scrollsequence](https://wordpress.org/support/users/scrollsequence/)
 * (@scrollsequence)
 * [2 years, 9 months ago](https://wordpress.org/support/topic/use-scroll-snap-after-scrollsequence-ends/#post-16983212)
 * Closing this topic

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Use scroll snap after scrollsequence ends’ is closed to new replies.

 * ![](https://ps.w.org/scrollsequence/assets/icon-256x256.png?rev=2780206)
 * [Scrollsequence - Cinematic Scroll Image Animation Plugin](https://wordpress.org/plugins/scrollsequence/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/scrollsequence/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/scrollsequence/)
 * [Active Topics](https://wordpress.org/support/plugin/scrollsequence/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/scrollsequence/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/scrollsequence/reviews/)

 * 4 replies
 * 2 participants
 * Last reply from: [Scrollsequence](https://wordpress.org/support/users/scrollsequence/)
 * Last activity: [2 years, 9 months ago](https://wordpress.org/support/topic/use-scroll-snap-after-scrollsequence-ends/#post-16983212)
 * Status: resolved