From 31be67cddf057e0c9fb4c095eb9adf9b56889798 Mon Sep 17 00:00:00 2001 From: Delirium Date: Fri, 16 Aug 2024 19:06:29 +0100 Subject: [PATCH] ui: fix audioplayer time comp (#2636) --- .../app/components/Session/Player/ReplayPlayer/AudioPlayer.tsx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/frontend/app/components/Session/Player/ReplayPlayer/AudioPlayer.tsx b/frontend/app/components/Session/Player/ReplayPlayer/AudioPlayer.tsx index e93699fa2..ed79c433b 100644 --- a/frontend/app/components/Session/Player/ReplayPlayer/AudioPlayer.tsx +++ b/frontend/app/components/Session/Player/ReplayPlayer/AudioPlayer.tsx @@ -102,9 +102,11 @@ function DropdownAudioPlayer({ const file = files.find((f) => f.url === key); if (file) { const targetTime = (timeMs + delta * 1000 - file.start) / 1000; + console.log(targetTime, audio.currentTime, timeMs) const fileLength = fileLengths.current[key]; if (targetTime < 0 || (fileLength && targetTime > fileLength)) { audio.pause(); + audio.currentTime = 0; return; } else { audio.currentTime = targetTime;