You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sebastian Fuss edited this page Apr 12, 2025
·
2 revisions
Using the pageScrollInterruptible attribute or the service configurationPageScrollConfig.interruptible one can adjust whether user interactions should stop a running scroll animation. The detection is enabled by default.
Whenever the user performs scroll related events (usage of mouse wheel or arrow keys) or events that indicate attempts to stop the scrolling (mouse click), the page scroll animation stops.
To detect user interactions while a page scroll animation is running, event listeners are attached to the body element, listening for common events related to scrolling like mouse wheel, arrow keys or clicks (you may see the whole list in the code).
Once the page scroll animation finishes the event listener are detached/removed.
You may subscribe to the event emitter pageScrollFinish to execute custom logic whenever the scroll animation stops. Using the emitted boolean value you can distinguish between animations that finished due to reaching their target (value true is emitted) or because a user interruption (false is emitted).