"use client"; import type { ComponentRenderProps } from "./types"; import { baseClass, getCustomClass } from "./utils"; export function Badge({ element }: ComponentRenderProps) { const { props } = element; const customClass = getCustomClass(props); const badgeVariant = props.variant as string; const badgeClass = badgeVariant === "success" ? "bg-green-100 text-green-800" : badgeVariant === "warning" ? "bg-yellow-100 text-yellow-800" : badgeVariant === "danger" ? "bg-red-100 text-red-800" : "bg-muted text-foreground"; return ( {props.text as string} ); }