Back to Components
Components

Mention Badge

Inline @username badge with avatar and optional hover card for profile preview.

Thanks jordanlee@jordanlee for the feedback!

Working with AL@alexmorganALAlex Morgan@alexmorganProduct designer exploring tech and creativity. on the new feature.

Dependencies

  • clsx
  • tailwind-merge

Files

  • components/ui/mention-badge.tsx

Installation

Using shadcn CLI

npx shadcn add mention-badge --url https://ui.hampton.io

Manual installation

Copy the component file to your project and install dependencies:

npm install clsx tailwind-merge