FileUpload
Drag-and-drop zone with click-to-upload, file type filtering, and size limits.
Installation
Examples
Default drop zone
Drag files or click to browse.
Drop files here or browse
PNG, JPG, PDF up to 10MB
With file list
Displays accepted files with remove option.
Drop more files here
design-v2.fig
4.2 MB
report-q1.pdf
1.8 MB
API Reference
| Prop | Type | Default | Description |
|---|---|---|---|
| onDrop* | (files: File[]) => void | required | Called when files are dropped. |
| accept | string[] | — | Allowed MIME types. |
| maxSize | number | — | Max file size in bytes. |
| multiple | boolean | true | Allow multiple file selection. |
| disabled | boolean | false | Disables the drop zone. |