diff --git a/client/src/components/netflix-grid.tsx b/client/src/components/netflix-grid.tsx index 917f9c2..cfeee0e 100644 --- a/client/src/components/netflix-grid.tsx +++ b/client/src/components/netflix-grid.tsx @@ -64,14 +64,18 @@ export default function NetflixGrid({ videos, isLoading }: NetflixGridProps) { title: "Meist Angesehen", videos: sortedByViews.slice(0, 10) }, - ...(folxStadlVideos.length > 0 ? [{ + { title: "FOLX STADL", videos: (() => { + // If no specific FOLX STADL videos found, show some recent videos as placeholder + if (folxStadlVideos.length === 0) { + return sortedByDate.slice(0, 10); + } // Shuffle FOLX STADL videos randomly const shuffled = [...folxStadlVideos].sort(() => Math.random() - 0.5); return shuffled.slice(0, 10); })() - }] : []), + }, { title: "VIDEO", videos: (() => { @@ -103,54 +107,55 @@ export default function NetflixGrid({ videos, isLoading }: NetflixGridProps) { })() }, { - title: "GIPFELSTAMMTISCH", + title: "VOLKSMUSIK", videos: (() => { - // Filter videos that contain "Gipfelstammtisch" in various forms - const gipfelVideos = videos.filter(video => { + // Filter videos by popular Volksmusik artists + const volksmusikVideos = videos.filter(video => { const title = video.title.toLowerCase(); - return title.includes("gipfelstammtisch") || - title.includes("gipfel stammtisch") || - title.includes("gipfel-stammtisch"); + return title.includes("die alpentaler") || + title.includes("die ladiner") || + title.includes("kastelruther spatzen") || + title.includes("zillertaler") || + title.includes("ursprung buam") || + title.includes("tiroler") || + title.includes("kärntner") || + title.includes("steirer"); }); - // Shuffle the Gipfelstammtisch videos randomly - const shuffled = [...gipfelVideos].sort(() => Math.random() - 0.5); + // If no specific volksmusik videos found, use fallback + if (volksmusikVideos.length === 0) { + return sortedByDate.slice(10, 20); + } - // Return 10 random videos from the GIPFELSTAMMTISCH collection + const shuffled = [...volksmusikVideos].sort(() => Math.random() - 0.5); return shuffled.slice(0, 10); })() }, { - title: "DIE Geschichte des Liedes", + title: "SCHLAGER & POP", videos: (() => { - // Filter videos that contain "Geschichte des Liedes" in various forms - const gdlVideos = videos.filter(video => { + // Filter videos that might be schlager or pop + const schlagerVideos = videos.filter(video => { const title = video.title.toLowerCase(); - const desc = video.description?.toLowerCase() || ""; - return title.includes("geschichte des liedes") || - title.includes("gschichte des liedes") || - title.includes("die geschichte des liedes") || - desc.includes("geschichte des liedes") || - desc.includes("gschichte des liedes"); + return title.includes("band") || + title.includes("duo") || + title.includes("sänger") || + title.includes("musik") || + title.includes("hit"); }); - // If no specific "Geschichte des Liedes" videos found, fallback to general filter - if (gdlVideos.length === 0) { - const fallbackVideos = videos.filter(video => - !video.title.includes("FOLX STADL") && - !video.title.includes("FOLXSTADL") && - !video.title.includes("Gipfelstammtisch") - ); - const shuffled = [...fallbackVideos].sort(() => Math.random() - 0.5); - return shuffled.slice(0, 10); + // If no specific schlager videos found, show different range + if (schlagerVideos.length === 0) { + return sortedByDate.slice(20, 30); } - // Shuffle the Geschichte des Liedes videos randomly - const shuffled = [...gdlVideos].sort(() => Math.random() - 0.5); - - // Return 10 random videos from the collection + const shuffled = [...schlagerVideos].sort(() => Math.random() - 0.5); return shuffled.slice(0, 10); })() + }, + { + title: "NEUE VIDEOS", + videos: sortedByDate.slice(0, 10) } ]; }, [videos]);