Skip to content

Commit

Permalink
Merge pull request #301 from Deepak1649/FullScreenBug
Browse files Browse the repository at this point in the history
[SOL]  Arrow keys don't work after toggling the Fullscreen unless clicked on the video again. #262
  • Loading branch information
hkirat authored Apr 1, 2024
2 parents be5b6b4 + a2ebf9b commit 219fb7d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/components/VideoPlayer2.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,10 @@ export const VideoPlayer: FunctionComponent<VideoPlayerProps> = ({
onReady(player);
}
});
// Focus the video player when toggling fullscreen
player.on('fullscreenchange', () => {
videoElement.focus();
});
},
));

Expand Down

0 comments on commit 219fb7d

Please sign in to comment.