This commit is contained in:
Vula Builder
2026-06-04 11:45:19 +00:00
parent 86e6c396c9
commit af9cd4042f
+31
View File
@@ -0,0 +1,31 @@
import { cn } from "@/lib/utils"
interface BadgeProps {
variant?: "default" | "secondary" | "accent" | "outline"
size?: "sm" | "md"
className?: string
children: React.ReactNode
}
export default function Badge({ variant = "default", size = "md", className, children }: BadgeProps) {
return (
<span
className={cn(
"inline-flex items-center rounded-full font-medium transition-colors",
{
"bg-[#ea580c]/10 text-[#ea580c]": variant === "default",
"bg-[#dc2626]/10 text-[#dc2626]": variant === "secondary",
"bg-[#8b5a3c]/10 text-[#8b5a3c]": variant === "accent",
"border border-border text-foreground bg-transparent": variant === "outline"
},
{
"px-2.5 py-0.5 text-xs": size === "sm",
"px-3 py-1 text-sm": size === "md"
},
className
)}
>
{children}
</span>
)
}