aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/Artplayer.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/Artplayer.js b/lib/Artplayer.js
index 6e3123c..933972b 100644
--- a/lib/Artplayer.js
+++ b/lib/Artplayer.js
@@ -138,6 +138,12 @@ export default function Player({
},
].filter(Boolean),
});
+
+ art.events.proxy(document,"keydown", event => {
+ if (event.key === 'f' || event.key === 'F') {
+ art.fullscreen = !art.fullscreen;
+ }
+ });
if (getInstance && typeof getInstance === "function") {
getInstance(art);