UploadKit
SDK@uploadkitdev/react

UploadDropzoneMinimal

A Stripe/Resend-inspired ultra-clean dropzone with subtle border animations and pill-shaped file chips.

A multi-file dropzone stripped to its essence — thin 1px borders, generous whitespace, monochrome palette with a single accent color. The border pulses subtly on drag-over and file chips fade in with a stagger.

Design inspiration: Stripe Checkout, Resend, Linear settings.

motion is an optional peerDependency. Without it, transitions use CSS only. pnpm add motion for spring-animated chip entrances and border glow.

Drop files here or click to upload

Stripe · Resend — ultra-minimal

Basic usage

import { UploadDropzoneMinimal } from '@uploadkitdev/react';

export default function Page() {
  return (
    <UploadDropzoneMinimal
      route="imageUploader"
      accept={['image/*']}
      maxFiles={5}
      onUploadComplete={(results) => {
        console.log('Uploaded:', results.map((r) => r.url));
      }}
    />
  );
}

Props

PropTypeDefaultDescription
routestringRequired. Route name from your file router.
acceptstring[]Accepted MIME types. Supports wildcards: 'image/*'.
maxSizenumberMaximum file size in bytes.
maxFilesnumberMaximum number of files per drop or selection.
metadataRecord<string, unknown>JSON-serializable metadata forwarded to the server.
onUploadComplete(results: UploadResult[]) => voidCalled after all files upload successfully.
onUploadError(error: Error) => voidCalled on individual file failure.
disabledbooleanfalseDisables the dropzone.
classNamestringAdditional CSS class(es) for the outer wrapper.
childrenReactNodeOverride the default label text.

UploadDropzoneMinimal accepts a ref forwarded to the outer <div>.

Theming

VariablePurpose
--uk-primaryDrag-over border color and progress bar fill
--uk-bgContainer background
--uk-bg-secondaryFile chip background
--uk-borderDefault border color
--uk-text, --uk-text-secondaryLabel and subtitle colors
--uk-success, --uk-errorChip border tint on completion/failure

Accessibility

  • role="button" with aria-label and aria-disabled
  • Focusable via keyboard; Enter and Space open the file picker
  • focus-visible outline uses --uk-primary
  • Respects prefers-reduced-motion

On this page