#Example #HtmlComponent #FullScreen #allowFullScreen #requestFullscreen
Demonstrates:
-
HTML Fullscreen API
Links for this example -
Open the Example in the Wix Editor
About this example
The requestFullscreen method of the HTML fullscreen API is used to change the specified element to full screen. This method is still prefixed in some browsers, although the evolving standard will eventually eliminate the prefix.
The code embedded in the HtmlComponent demonstrates how to anticipate and adapt to different browsers, however you might need additional code depending on your requirements.
HTML support for mobile browsers is right now limited to Android devices. To exit full screen on a mobile device: Swipe either from the bottom or the side to bring up the onscreen buttons that are hidden when entering full-screen mode.
Note: Due to differences in the way that an HtmlComponent is handled in the Editor (Preview) and a Live site (Published), full-screen might not work in Preview.