1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

use a 'keydown' listener in video/index.js instead

This commit is contained in:
Steve Hoffing 2024-06-09 16:03:10 -04:00 committed by Bill Thornton
parent e28b55721d
commit 5ef0428bba
2 changed files with 9 additions and 19 deletions

View file

@ -1775,8 +1775,13 @@ export default function (view) {
}
});
nowPlayingPositionSlider.addEventListener('playpause', function () {
playbackManager.playPause(currentPlayer);
nowPlayingPositionSlider.addEventListener('keydown', function (e) {
if (e.defaultPrevented) return;
const key = keyboardnavigation.getKeyName(e);
if (key === 'Enter') {
playbackManager.playPause(currentPlayer);
}
});
nowPlayingPositionSlider.updateBubbleHtml = function(bubble, value) {