update
This commit is contained in:
@@ -10,15 +10,11 @@ import { cn } from "@/lib/utils"
|
||||
import { Image } from "./Image"
|
||||
import { Typography } from "./Typography"
|
||||
|
||||
export interface CardTag {
|
||||
tag: string
|
||||
}
|
||||
|
||||
export interface CardProps extends React.ComponentProps<typeof ShadcnCard> {
|
||||
image?: string
|
||||
title?: string
|
||||
subtitle?: string
|
||||
tags?: CardTag[]
|
||||
tags?: string[]
|
||||
}
|
||||
|
||||
function Card({
|
||||
@@ -58,9 +54,9 @@ function Card({
|
||||
|
||||
{tags && tags.length > 0 ? (
|
||||
<CardContent className="flex flex-wrap gap-2">
|
||||
{tags.map((item, index) => (
|
||||
<Badge key={`${item.tag}-${index}`} variant="secondary">
|
||||
{item.tag}
|
||||
{tags.map((tag, index) => (
|
||||
<Badge key={`${tag}-${index}`} variant="secondary">
|
||||
{tag}
|
||||
</Badge>
|
||||
))}
|
||||
</CardContent>
|
||||
|
||||
Reference in New Issue
Block a user