From 241349af02f1bc2ed69840eb55f49fcfa82cfee5 Mon Sep 17 00:00:00 2001 From: sylenien Date: Thu, 27 Oct 2022 11:27:03 +0200 Subject: [PATCH] fix(ui): fix time skip tooltip --- .../Player/Controls/components/PlayerControls.tsx | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/frontend/app/components/Session_/Player/Controls/components/PlayerControls.tsx b/frontend/app/components/Session_/Player/Controls/components/PlayerControls.tsx index f2f52fd7b..326fa14ad 100644 --- a/frontend/app/components/Session_/Player/Controls/components/PlayerControls.tsx +++ b/frontend/app/components/Session_/Player/Controls/components/PlayerControls.tsx @@ -49,6 +49,7 @@ function PlayerControls(props: Props) { const speedRef = React.useRef(null); const arrowBackRef = React.useRef(null); const arrowForwardRef = React.useRef(null); + const skipRef = React.useRef() React.useEffect(() => { const handleKeyboard = (e: KeyboardEvent) => { @@ -75,6 +76,9 @@ function PlayerControls(props: Props) { const toggleTooltip = () => { setShowTooltip(!showTooltip); }; + const handleClickOutside = () => { + setShowTooltip(false) + } return (
{playButton} @@ -105,6 +109,7 @@ function PlayerControls(props: Props) {
+ (showTooltip ? toggleTooltip() : null)} - >
Jump (Secs) @@ -139,16 +141,16 @@ function PlayerControls(props: Props) {
))}
-
} > -
+
{/* @ts-ignore */} {currentInterval}s
+
{/* @ts-ignore */}