From 08cc5260bdc38b7771f7e06963bd4c7d2a43ef3c Mon Sep 17 00:00:00 2001 From: mrjvs Date: Wed, 29 Nov 2023 18:11:10 +0100 Subject: [PATCH] Fix overlay always staying on on touch devices --- src/components/player/hooks/useShouldShowControls.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/player/hooks/useShouldShowControls.tsx b/src/components/player/hooks/useShouldShowControls.tsx index 30eac99a..58a70c09 100644 --- a/src/components/player/hooks/useShouldShowControls.tsx +++ b/src/components/player/hooks/useShouldShowControls.tsx @@ -17,7 +17,7 @@ export function useShouldShowControls() { // when using touch, pause screens can be dismissed by tapping const showTargetsWithoutPause = - isHovering || isHoveringControls || hasOpenOverlay; + isHovering || (isHoveringControls && !isUsingTouch) || hasOpenOverlay; const showTargetsIncludingPause = showTargetsWithoutPause || isPaused; const showTargets = isUsingTouch ? showTargetsWithoutPause