Skip to content

chore(ui): remove unused badgeVariants export#227

Open
andrerfneves wants to merge 1 commit into
mainfrom
maintenance/remove-unused-badge-variants-20260630
Open

chore(ui): remove unused badgeVariants export#227
andrerfneves wants to merge 1 commit into
mainfrom
maintenance/remove-unused-badge-variants-20260630

Conversation

@andrerfneves

Copy link
Copy Markdown
Owner

Summary

Removes the unused badgeVariants export from the badge.tsx shadcn/ui component.

Why

badgeVariants is a CVA variant definition used internally by the Badge component via badgeVariants({ variant }) and VariantProps<typeof badgeVariants>, but it is never imported by any other file in the project.

This is consistent with the established cleanup pattern in the repository:

Changes

  • src/components/ui/badge.tsx: Changed export { Badge, badgeVariants }export { Badge }

The badgeVariants variable and the BadgeProps interface remain in the file since they are used internally by the Badge component.

Test Plan

  • All 52 existing tests pass
  • Production build succeeds
  • No behavior change — internal usage of badgeVariants is unchanged

badgeVariants is a CVA variant definition used internally by the
Badge component, but it is never imported by any other file in the
project. Removing it from the export list keeps the public API
surface minimal and consistent with similar cleanup PRs (dialog,
dropdown-menu, sheet components).

This is consistent with existing cleanup PRs:
- #213, #207, #203 (dialog)
- #201 (dropdown-menu)
- #200 (sheet)
@vercel

vercel Bot commented Jun 30, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
lightning-decoder Ready Ready Preview, Comment Jun 30, 2026 12:06pm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant