feature/share-libs
tsx 29 lines 464 Bytes
Raw
1
2 import Image from "next/image";
3
4 export default function SongVotesImage({
5 imagaeUrl: songProviderImageUrl,
6 name,
7 }: {
8 imagaeUrl: string | null;
9 name: string;
10 }) {
11 if (!songProviderImageUrl) {
12 return <div>
13 {name}
14 </div>;
15 }
16
17 return (
18 <>
19 <Image
20 src={songProviderImageUrl}
21 width={0}
22 height={0}
23 alt={name}
24 sizes="100vw"
25 className="w-full h-auto aspect-video"
26 />
27 </>
28 );
29 }