Upload

The upload widget over the Live upload protocol, with a progress bar and a message for every state.

Every state the widget shows, set without a server. This site accepts no uploads.

Open in new tab

Each preview is its own Live page in a frame, because this site is a Vue 3.5 app built on the Pulsar starter kit. An open list or popover stays inside its frame; in your application it opens over the page.

Installation

bash
suprnova live:add upload

Usage

html
{% import "suprnova-ui/upload/upload.html" as upload %}
{% call upload::upload("avatar", "Avatar", "image/png") %}{% endcall %}

Keyboard and accessibility

suprnova.upload - the upload widget over the shipped upload protocol (FORM-005). The native file input carries live:upload for the island's upload field; the progress element is the runtime's progress root and receives data-live-upload-state, the bounded byte counts and the announcements; cancel, retry and remove act through the runtime on the opaque temporary reference. Every state name the domain knows (queued, transferring, verifying, ready, finalizing, finalized, rejected, canceled, expired, failed) is rendered as text and shown by CSS from the progress root's state, so the widget never claims a durable save before the finalizing action runs: "ready" reads as awaiting that action. The widget adds no transfer path: every request the runtime makes goes to the __live/upload route. Every attribute is a required parameter, so the view stays flat under the checker's branch limit. Classification: varies with the island that mounts it.

API reference

upload

ParameterDefaultDescription
nameRequiredThe component's field that carries an upload policy.
labelRequiredThe visible label.
acceptRequiredThe accepted types, as in the HTML `accept` attribute.