MCPcopy Create free account
hub / github.com/R44VC0RP/opencode.cafe / Badge

Function Badge

components/ui/badge.tsx:32–48  ·  view source on GitHub ↗
({
  className,
  variant,
  asChild = false,
  ...props
}: React.ComponentProps<"span"> &
  VariantProps<typeof badgeVariants> & { asChild?: boolean })

Source from the content-addressed store, hash-verified

30)
31
32function Badge({
33 className,
34 variant,
35 asChild = false,
36 ...props
37}: React.ComponentProps<"span"> &
38 VariantProps<typeof badgeVariants> & { asChild?: boolean }) {
39 const Comp = asChild ? Slot : "span"
40
41 return (
42 <Comp
43 data-slot="badge"
44 className={cn(badgeVariants({ variant }), className)}
45 {...props}
46 />
47 )
48}
49
50export { Badge, badgeVariants }

Callers

nothing calls this directly

Calls 1

cnFunction · 0.90

Tested by

no test coverage detected