Javascript Exit Full Screen Speed

Viewed 36

I am developing an educational web app that enteres/exits full screen to remove distractions from students when they are studying. The enter/exit full screen animation speed is slow and doesn't look great and doesn't seem to serve any purpose.

i.e. Calling these:

    document.exitFullscreen();
    document.webkitExitFullscreen();
    document.mozCancelFullScreen();
    document.msExitFullscreen();

Is there a way to tell the browser to just exit full screen without a lengthy animation? Or is this OS dependent? (I've tried googling this and haven't found anything much useful)

1 Answers

It appears to be OS dependent, testing this demo on Big Sur and latest Chrome, there's a lengthy animation. Enabling Accessibility-Display-Reduce motion from System Preferences shorten the transition. On Windows 10 there's no animation at all on Chrome, that's with all Animate options enabled on Performance Options.

Related