MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / Badge

Function Badge

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

Source from the content-addressed store, hash-verified

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

Callers

nothing calls this directly

Calls 1

cnFunction · 0.90

Tested by

no test coverage detected