Merge pull request #919 from Stremio/feat/shell-fullscreen-key-f
Some checks are pending
Build / build (push) Waiting to run

App(Shell): toggle fullscreen with F key
This commit is contained in:
Tim 2025-05-27 10:34:37 +02:00 committed by GitHub
commit b3bd68eb32
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 4 additions and 10 deletions

View file

@ -46,6 +46,10 @@ const useFullscreen = () => {
exitFullscreen();
}
if (event.code === 'KeyF') {
toggleFullscreen();
}
if (event.code === 'F11' && shell.active) {
toggleFullscreen();
}

View file

@ -56,16 +56,6 @@ function KeyboardShortcuts() {
window.history.back();
}
break;
}
case 'KeyF': {
event.preventDefault();
if (document.fullscreenElement === document.documentElement) {
document.exitFullscreen();
} else {
document.documentElement.requestFullscreen();
}
break;
}
}