diff --git a/components/player/DesktopVideoPlayer.tsx b/components/player/DesktopVideoPlayer.tsx index c3bfe29..5bf4da2 100644 --- a/components/player/DesktopVideoPlayer.tsx +++ b/components/player/DesktopVideoPlayer.tsx @@ -549,10 +549,11 @@ export function DesktopVideoPlayer({ // Format time helper const formatTime = (seconds: number) => { - if (isNaN(seconds)) return '0:00'; - const mins = Math.floor(seconds / 60); + if (isNaN(seconds)) return '0:00:00'; + const hours = Math.floor(seconds / 3600); + const mins = Math.floor((seconds % 3600) / 60); const secs = Math.floor(seconds % 60); - return `${mins}:${secs.toString().padStart(2, '0')}`; + return `${hours}:${mins.toString().padStart(2, '0')}:${secs.toString().padStart(2, '0')}`; }; return ( diff --git a/components/player/MobileVideoPlayer.tsx b/components/player/MobileVideoPlayer.tsx index 7237850..31a8b8b 100644 --- a/components/player/MobileVideoPlayer.tsx +++ b/components/player/MobileVideoPlayer.tsx @@ -401,10 +401,11 @@ export function MobileVideoPlayer({ const speeds = [0.5, 0.75, 1, 1.25, 1.5, 2]; const formatTime = (seconds: number) => { - if (isNaN(seconds)) return '0:00'; - const mins = Math.floor(seconds / 60); + if (isNaN(seconds)) return '0:00:00'; + const hours = Math.floor(seconds / 3600); + const mins = Math.floor((seconds % 3600) / 60); const secs = Math.floor(seconds % 60); - return `${mins}:${secs.toString().padStart(2, '0')}`; + return `${hours}:${mins.toString().padStart(2, '0')}:${secs.toString().padStart(2, '0')}`; }; return (