Skip to content

@agala-labs/ui

File Upload

Selects files through an inline action or drag-and-drop surface.

Examples

Default

Drag and drop files here

or click to browse

<AgalaFileUpload v-model="files" accept="image/*" multiple :max-files="4" />

Import

import { AgalaFileUpload } from '@agala-labs/ui'

API

PropTypeDefaultDescription
modelValueFileItem[]Files used by v-model.
variant'dropzone' | 'inline''dropzone'Presentation.
acceptstringAccepted MIME types/extensions.
multiplebooleanfalseAllows multiple files.
maxSize / maxFilesnumberSize and count constraints.
label / helperstringVisible field copy.
dragText / browseText / buttonTextstringAction copy.
disabledbooleanfalseDisables selection.

Events

  • update:modelValue(files: FileItem[])
  • change(files)
  • remove(file)
  • error(message)

Accessibility

Retains a keyboard-operable native file input behind the custom surface.

Released under the MIT License.