Maple · Forms

File Upload

Drop zone for attaching files. Always state the accepted formats and size limit up front, and show progress and errors in place.

View in Storybook →

Try it

Drop a file or browse — progress is simulated here.

Drag files here or PNG, JPG or PDF · up to 10 MB
Upload failedThat file type isn’t supported. Use PNG, JPG or PDF.
<FileUpload accept="image/*,.pdf" onFiles={upload} progress={pct} error={err} />

Props

PropTypeDefaultDescription
onFiles(files: File[]) => void—Called on drop or browse.
acceptstring—Accepted types.
hintstring—Formats and size limit.
progressnumber | nullnullShows a progress bar.
errorstring | nullnullError state and message.