Skip to content

FileInput ​

Native file input with drop zone

A form field that takes files: click or drop, see what was picked, remove one. Submits with the form like any other field. When the files start uploading the moment they land — progress, retry, a queue — that is Uploader.

Basic
  • label here is the copy inside the zone. The field's own label comes from a BlessField around it, which also wires id, invalid and describedby.
  • accept filters the picker and dropped files, so the hint you write is what gets in.
  • The v-model is the truth. With multiple, picks accumulate and remove is per file, which the native <input> cannot mirror — on submit, append files to your FormData rather than reading the input.

Usage ​

ts
import { BlessFileInput } from "blessing-ui";

API ​

Props

NameTypeDefaultDescription
idstring—
acceptstring—
multipleboolean—
disabledboolean—
invalidboolean—
labelstring"Drop files here or click to browse"drop zone copy
hintstring—
listbooleantrueshow the chosen files under the zone
modelValueFile[][]

Events

NamePayloadDescription
update:modelValue[value: File[]]

Slots

NameScopeDescription
icon—
default—

Released under the MIT License. Character names and artwork belong to their owners.