Skip to content
Photo upload with crop preview, light
Light
Photo upload with crop preview, dark
Dark

Every state

  • Photo upload with crop preview, default, light
    Photo upload with crop preview, default, dark

    default

  • Photo upload with crop preview, hover, light
    Photo upload with crop preview, hover, dark

    hover

  • Photo upload with crop preview, focus, light
    Photo upload with crop preview, focus, dark

    focus

  • Photo upload with crop preview, empty, light
    Photo upload with crop preview, empty, dark

    empty

  • Photo upload with crop preview, uploading, light
    Photo upload with crop preview, uploading, dark

    uploading

  • Photo upload with crop preview, error, light
    Photo upload with crop preview, error, dark

    error

Props

PropTypeDefaultWhat it does
namestringDirk-Jan MulderPerson's name, used for the initials when there is no photo.
srcstring/components/people/dirkjan.webpCurrent photo. An empty string shows the empty state.
maxSizeMbnumber2Largest accepted file in megabytes.
acceptstringimage/jpeg,image/png,image/webpAccepted image types.
progressnumber | nullnullUpload progress 0 to 100; null when nothing is uploading.
errorstring | nullnullAn error from your upload. File type and size errors are added by the component.
onSelect(file: File) => voidCalled with a file that passed the checks.
onRemove() => voidCalled when the photo is removed.

More avatars

All 13
avatar-12 is in UI ProGet UI Pro, €199

Preview

Open the page
In UI Pro: get it, €199 once

With every block and theme. 400+ buyers since 2020. Plans