This commit is contained in:
Vula Builder
2026-07-25 11:17:56 +00:00
parent dd6ce39c7f
commit 9f562f4de7
+38
View File
@@ -0,0 +1,38 @@
import { cn } from "@/lib/utils"
import React from "react"
interface BadgeProps {
variant?: "default" | "secondary" | "accent" | "outline"
size?: "sm" | "md" | "lg"
className?: string
children: React.ReactNode
}
export default function Badge({
variant = "default",
size = "sm",
className,
children
}: BadgeProps) {
return (
<span
className={cn(
"inline-flex items-center rounded-full font-medium",
{
"bg-[#C0392B] text-white": variant === "default",
"bg-[#E67E22] text-white": variant === "secondary",
"bg-[#F1C40F] text-[#33211f]": variant === "accent",
"border border-[#ddd5d4] text-[#33211f] bg-transparent": variant === "outline"
},
{
"text-xs px-2.5 py-0.5": size === "sm",
"text-sm px-3 py-1": size === "md",
"text-base px-4 py-1.5": size === "lg"
},
className
)}
>
{children}
</span>
)
}