diff --git a/client/src/components/netflix-grid.tsx b/client/src/components/netflix-grid.tsx index e6c796b..6bd474e 100644 --- a/client/src/components/netflix-grid.tsx +++ b/client/src/components/netflix-grid.tsx @@ -164,7 +164,9 @@ function CategoryRow({ category, onVideoClick }: CategoryRowProps) { scrollIntervalRef.current = setInterval(() => { setTranslateX(prev => { - const speed = direction === 'right' ? -baseSpeed : baseSpeed; + const videosPerStep = 4; // Move 4 videos at once + const adjustedSpeed = speedMode === 'fast' ? videosPerStep * videoWidth * 0.03 : videosPerStep * videoWidth * 0.01; + const speed = direction === 'right' ? -adjustedSpeed : adjustedSpeed; const newX = prev + speed; const totalWidth = category.videos.length * videoWidth; @@ -196,8 +198,9 @@ function CategoryRow({ category, onVideoClick }: CategoryRowProps) { // Start continuous smooth scrolling with variable speed scrollIntervalRef.current = setInterval(() => { setTranslateX(prev => { - // Speed changes based on mode: normal (0.8px) or fast (2.5px) - const baseSpeed = speedMode === 'fast' ? 2.5 : 0.8; + // Speed changes based on mode: move by full videos (4 videos at once) + const videosPerStep = 4; // Move 4 videos at once + const baseSpeed = speedMode === 'fast' ? videosPerStep * videoWidth * 0.03 : videosPerStep * videoWidth * 0.01; const speed = direction === 'right' ? -baseSpeed : baseSpeed; const newX = prev + speed; const totalWidth = category.videos.length * videoWidth;