Enter full screen by left clicking on the page. Exit full screen by pointing on top of the screen. Since:…
Enter full screen by left clicking on the page. Exit full screen by pointing on top of the screen.
Since:
https://superuser.com/questions/1368977/how-to-re-enable-proper-full-screen-mode-in-chrome-with-display-of-toolbar-on-ho
https://groups.google.com/a/chromium.org/g/chromium-discuss/c/f9r8ZsaMm9o/m/43l1YN1KCwAJ
https://support.google.com/chrome/thread/67228761/how-to-show-tabs-bar-in-chrome-full-screen-mode-just-like-in-firefox?hl=en.
Why enter full screen by left clicking on the page, why don't just use the mouseenter event, no need to click?
document.documentElement.requestFullscreen() needs a user gesture, to avoid abuse.
But:
chrome://flags/#automatic-fullscreen-content-setting
https://chromestatus.com/feature/6218822004768768,
the .js would be:
document.addEventListener("mouseenter",$,{once:true})
function $(){document.documentElement.requestFullscreen()
A=new AbortController()
addEventListener("mousemove",e=>{if(e.y==0){document.exitFullscreen()
A.abort()
document.addEventListener("mouseenter",$,{once:true})}},{signal:A.signal})}