Limit displayed videos to 10 per row and randomize their order
Adjusted video grid components to display a maximum of 10 videos per row, implementing a random shuffle for all video rows to enhance content variety. Replit-Commit-Author: Agent Replit-Commit-Session-Id: 2cd2c0bc-434c-4bc9-ad3f-b99d3897a0d1 Replit-Commit-Checkpoint-Type: full_checkpoint Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/8cc42625-c1f5-4e43-99bd-77f2c4dedee2/2cd2c0bc-434c-4bc9-ad3f-b99d3897a0d1/OdlP8Wj
This commit is contained in:
parent
98c5d91fac
commit
d1ba445592
@ -59,7 +59,11 @@ export default function NetflixGrid({ videos, isLoading }: NetflixGridProps) {
|
||||
},
|
||||
...(folxStadlVideos.length > 0 ? [{
|
||||
title: "FOLX STADL",
|
||||
videos: folxStadlVideos.slice(0, 12)
|
||||
videos: (() => {
|
||||
// Shuffle FOLX STADL videos randomly
|
||||
const shuffled = [...folxStadlVideos].sort(() => Math.random() - 0.5);
|
||||
return shuffled.slice(0, 10);
|
||||
})()
|
||||
}] : []),
|
||||
{
|
||||
title: "VIDEO",
|
||||
@ -78,14 +82,14 @@ export default function NetflixGrid({ videos, isLoading }: NetflixGridProps) {
|
||||
!video.title.includes("Gipfelstammtisch")
|
||||
);
|
||||
const shuffled = [...fallbackVideos].sort(() => Math.random() - 0.5);
|
||||
return shuffled.slice(0, 15);
|
||||
return shuffled.slice(0, 10);
|
||||
}
|
||||
|
||||
// Shuffle the Geschichte des Liedes VIDEO videos randomly
|
||||
const shuffled = [...videoVideos].sort(() => Math.random() - 0.5);
|
||||
|
||||
// Return 15 random videos from the VIDEO collection
|
||||
return shuffled.slice(0, 15);
|
||||
// Return 10 random videos from the VIDEO collection
|
||||
return shuffled.slice(0, 10);
|
||||
})()
|
||||
},
|
||||
{
|
||||
|
||||
Loading…
Reference in New Issue
Block a user