Feedback & overlays / Toast

Feedback & overlays

Toast

Bottom-left toasts: a title you can read in half a second, plus an optional line that says what it means, in four status types.

import { EcoToaster, EcoToast, useToast } from "vue-ecosphere"

Push a toast

Each button pushes a toast to the bottom-left stack. Confirmations dismiss themselves; failures stay until dismissed.

Types

The left rule and icon carry the status; the surface stays white.

Destination added

Primary cluster is receiving traffic. The first batch lands within a minute.

Certificate expires in 6 days

Auto-renewal is off for api.internal, so this one needs a manual rotation.

Rotation failed

The old connection pool still holds four sessions. Nothing changed — retry once they drain.

Export queued

You will get a notification when the file is ready to download.

Neutral, and title only

Rebuilding search index

About nine minutes. Results stay available from the old index until it finishes.

Record saved

API

NameTypeDefaultDescription
useToast(){ push, success, warning, danger, info, accent, dismiss, clear, toasts }—push(options) returns an id; the tone shortcuts take (title, options?).
options.titlestring—A fact, not a sentence: “Rotation failed”.
options.descriptionstring—What did not happen and what to do. Drop it for “Record saved”.
options.tone"success" | "warning" | "danger" | "info" | "accent""accent"Maps to toast--*; accent has no modifier (progress). Each tone has a fixed icon.
options.action / onActionstring / () => void—One action link at most; clicking it runs onAction and dismisses.
options.durationnumber6000Auto-dismiss in ms. 0 keeps it until dismissed.
<EcoToaster>component—The fixed bottom-left toasts stack, newest at the bottom. Mount once. The stack is the polite live region that reads each toast out.
<EcoToast>component—One toast: title, description, tone, icon?, action, dismissible, leaving, live (role="status", default true; the toaster sets false); emits dismiss and action.