diff --git a/src/routes/Player/SideDrawer/SideDrawer.tsx b/src/routes/Player/SideDrawer/SideDrawer.tsx index 11ff4b995..1dcca3b1b 100644 --- a/src/routes/Player/SideDrawer/SideDrawer.tsx +++ b/src/routes/Player/SideDrawer/SideDrawer.tsx @@ -78,15 +78,15 @@ const SideDrawer = memo(forwardRef(({ seriesInfo, classNa const currentlyPlayingVideoRef = useRef(null); - useEffect(() => { + const jumpToPlayingNow = () => { const { current } = currentlyPlayingVideoRef; if (current) { - setTimeout(() => { current.scrollIntoView({ behavior: 'smooth', block: 'center' }); }, 300); + current.scrollIntoView({ behavior: 'smooth', block: 'center' }); } - }, []); + }; return ( -
+