Spectrum Components API

Schema version: 6.0.0

Toast

Toasts display brief, temporary notifications. They're meant to be noticed without disrupting a user's experience or requiring an action to be taken.

PropertyValuesDefault valueRequired
text
text
-
variant
neutral / informative / positive / negative
neutral
action label
text
If undefined, this button does not appear.
-
is auto dismissible
yes / no
no
{
  "slug": "toast",
  "$schema": "https://opensource.adobe.com/spectrum-design-data/schemas/component.json",
  "$id": "https://opensource.adobe.com/spectrum-design-data/schemas/components/toast.json",
  "title": "Toast",
  "description": "Toasts display brief, temporary notifications. They're meant to be noticed without disrupting a user's experience or requiring an action to be taken.",
  "meta": {
    "category": "feedback",
    "documentationUrl": "https://spectrum.adobe.com/page/toast/"
  },
  "type": "object",
  "properties": {
    "text": {
      "type": "string"
    },
    "variant": {
      "type": "string",
      "enum": [
        "neutral",
        "informative",
        "positive",
        "negative"
      ],
      "default": "neutral"
    },
    "actionLabel": {
      "type": "string",
      "description": "If undefined, this button does not appear."
    },
    "isAutoDismissible": {
      "type": "boolean",
      "default": false
    }
  }
}
← Back to home