Compare commits
1 Commits
7b76e3d900
...
scanning-u
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
fbcd592609 |
@@ -304,6 +304,7 @@ function SeriesCard({ series, onClick }: { series: GameSeries; onClick: () => vo
|
||||
const seriesPlatforms: GamePlatform[] = [
|
||||
...new Set(series.games.flatMap((g) => g.platforms)),
|
||||
]
|
||||
const resolvedCover = series.coverUrl ?? series.games[0]?.coverUrl ?? null
|
||||
|
||||
return (
|
||||
<button
|
||||
@@ -320,9 +321,9 @@ function SeriesCard({ series, onClick }: { series: GameSeries; onClick: () => vo
|
||||
}}
|
||||
>
|
||||
<div className="aspect-[3/4] w-full relative overflow-hidden" style={{ backgroundColor: 'var(--border)' }}>
|
||||
{series.coverUrl ? (
|
||||
{resolvedCover ? (
|
||||
// eslint-disable-next-line @next/next/no-img-element
|
||||
<img src={series.coverUrl} alt={series.title} className="absolute inset-0 w-full h-full object-cover" />
|
||||
<img src={resolvedCover} alt={series.title} className="absolute inset-0 w-full h-full object-cover" />
|
||||
) : (
|
||||
<div className="absolute inset-0 flex items-center justify-center text-4xl">🎮</div>
|
||||
)}
|
||||
|
||||
Reference in New Issue
Block a user