2024-06-20 18:02:25 +00:00
|
|
|
import { Genre } from "@prisma/client";
|
|
|
|
import { ComponentProps } from "react";
|
|
|
|
import { Badge } from "@/components/ui/badge";
|
|
|
|
|
|
|
|
export default function GenreBadges(props: ComponentProps<"div"> & { genres: Array<Genre> }) {
|
|
|
|
return (
|
2024-07-24 20:41:46 +00:00
|
|
|
<div className={"flex flex-wrap gap-1 justify-center " + props.className}>
|
2024-09-27 10:17:37 +00:00
|
|
|
{props.genres.map((e: Genre) => (<Badge className="text-xs md:text-sm" key={e.name}>{e.name}</Badge>))}
|
2024-06-20 18:02:25 +00:00
|
|
|
</div>
|
|
|
|
)
|
|
|
|
}
|