This component no longer exists. It was in ondo-ui’s manifest when we first indexed it and is not there now — the registry served its inventory on 2026-08-09 and this item was not on it. The install command below will fail. It is kept here because a tutorial somewhere still tells people to run it.
badge
ondo-ui/badgeRemovedComponent
Displays a badge or a component that looks like a badge.
Install it
npx shadcn@latest add https://ui.ondo.dou.so/r/badge.jsonSource
1import { mergeProps } from "@base-ui/react/merge-props"2import { useRender } from "@base-ui/react/use-render"3import { cva, type VariantProps } from "class-variance-authority"45import { cn } from "@/lib/utils"67const badgeVariants = cva(8 "group/badge inline-flex h-5 w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-4xl border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-all focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3!",9 {10 variants: {11 variant: {12 default: "bg-primary text-primary-foreground [a]:hover:bg-primary/80",13 secondary:14 "bg-secondary text-secondary-foreground [a]:hover:bg-secondary/80",15 info: "bg-info/10 text-info focus-visible:ring-info/20 dark:bg-info/20 dark:focus-visible:ring-info/40 [a]:hover:bg-info/20",16 success:17 "bg-success/10 text-success focus-visible:ring-success/20 dark:bg-success/20 dark:focus-visible:ring-success/40 [a]:hover:bg-success/20",18 warning:19 "bg-warning/10 text-warning focus-visible:ring-warning/20 dark:bg-warning/20 dark:focus-visible:ring-warning/40 [a]:hover:bg-warning/20",20 destructive:21 "bg-destructive/10 text-destructive focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:focus-visible:ring-destructive/40 [a]:hover:bg-destructive/20",22 outline:23 "border-border text-foreground [a]:hover:bg-muted [a]:hover:text-muted-foreground",24 ghost:25 "hover:bg-muted hover:text-muted-foreground dark:hover:bg-muted/50",26 link: "text-primary underline-offset-4 hover:underline",27 },28 },29 defaultVariants: {30 variant: "default",31 },32 }33)3435function Badge({36 className,37 variant = "default",38 render,39 ...props40}: useRender.ComponentProps<"span"> & VariantProps<typeof badgeVariants>) {41 return useRender({42 defaultTagName: "span",43 props: mergeProps<"span">(44 {45 className: cn(badgeVariants({ variant }), className),46 },47 props48 ),49 render,50 state: {51 slot: "badge",52 variant,53 },54 })55}5657export { Badge, badgeVariants }
What it pulls in
npm packages
Other registry items
