Back to Components
Inputs

File Upload

Drag and drop file upload zone with previews and file details.

Drag files here or click to upload

Accepted: image/* (max 2.0 MB)

Dependencies

  • clsx
  • tailwind-merge

Files

  • components/ui/file-upload.tsx

Installation

Using shadcn CLI

npx shadcn add file-upload --url https://ui.hampton.io

Manual installation

Copy the component file to your project and install dependencies:

npm install clsx tailwind-merge