Toasts are non-modal, time-based window elements used to display short messages;
they usually appear at the top of the screen and disappear after a few seconds.
See [detailed
usage](https://carbondesignsystem.com/components/notification/usage).
See also: [InlineNotification](InlineNotification)
## Default (error)
## Autoclose
By default, `ToastNotification` does not automatically close.
Specify the `timeout` prop to automatically close the notification after a specified duration (in milliseconds).
## Prevent default close behavior
`ToastNotification` is a controlled component. Prevent the default close behavior using the `e.preventDefault()` method in the dispatched `on:close` event.
{
e.preventDefault();
// custom close logic (e.g., transitions)
}} />
## Full width
Set `fullWidth` to `true` for the notification to span the full width of its containing element.
## Slottable title, subtitle, caption
Error:
An internal server error occurred.
{new Date().toLocaleString()}
## Accessible icon descriptions
The status icon and close button icon descriptions appear on cursor hover and are read
by assistive technology. Default descriptions are provided in English and can be
overridden via `statusIconDescription` and `closeButtonDescription`.
## Hidden close button
## Notification variants
## Low contrast