There is a div that pops up when the user's mouse exits the webpage, containing a survey pertaining to my website.
I want to avoid prompting users to take the survey if they move their cursor out of the page within the first few minutes of browsing. Is there a way I can delay the activation of this mouseleave function?
Below is the code I have currently implemented without any timeout:
$(document).mouseleave(function () {
document.getElementById("Overlay1").style.display = "";
});
Thank you very much!