I am working on an ajax request and I have implemented a feature where the cursor changes appearance.
document.body.style.cursor = "wait";
This immediately shows the cursor as a spinning circle when the request starts.
At the end of the request, I change it back to the original state with:
document.body.style.cursor = "default";
However, I noticed that if the mouse remains still, the cursor does not revert back to its original state until it is moved by the user. This behavior doesn't occur when setting it to "auto" or any other style, as the change only happens upon movement of the cursor.
Any suggestions for resolving this issue?