Answer the question
In order to leave comments, you need to log in
Close the modal window if the user is not active. How?
Good,
the site has a pop-up slider (made on fancybox). It is planned that when there is no action (closing, switching a slide, and other actions with a slide), the current slide is closed (in general, any operation can be hung here).
How can you track the user's inactivity regarding the slider?
It's just that if you track the movement of the mouse, then the user can begin to navigate the site or perform other actions, and the slider will remain open.
Answer the question
In order to leave comments, you need to log in
set a timeout that would be updated when onmousemove on the slider
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question