diff --git a/apps/playnite-web/src/components/GameFigure.tsx b/apps/playnite-web/src/components/GameFigure.tsx index 8f60da233..17da91094 100644 --- a/apps/playnite-web/src/components/GameFigure.tsx +++ b/apps/playnite-web/src/components/GameFigure.tsx @@ -19,6 +19,7 @@ const Image = styled('img', { height: `${width}`, objectFit: 'cover', width, + display: 'block', })) const GameFigure: FC< @@ -39,6 +40,8 @@ const GameFigure: FC< }, []) const { ref } = useInView({ onChange: handleChange }) + const [imageHasError, setImageHasError] = useState(false) + return (
{hasBeenInViewBefore || noDefer @@ -47,13 +50,24 @@ const GameFigure: FC< sx={{ position: 'relative' }} key={`${game.oid.asString}-image`} > - {game.name} {}} - /> + {!imageHasError ? ( + {game.name} { + setImageHasError(true) + }} + /> + ) : ( + + )} ({ position: 'absolute',