carbon-components-svelte/tests/ToastNotification.test.svelte
metonym 8fea168ffd
feat(toast-notification): add fullWidth prop (#1444)
* feat(toast-notification): add `fullWidth` prop

* Run "yarn build:docs"

* test(toast-notification): assert `fullWidth` prop

* docs(toast-notification): add "Full width" example
2022-08-14 14:56:02 -07:00

38 lines
806 B
Svelte

<script lang="ts">
import { ToastNotification } from "../types";
</script>
<ToastNotification fullWidth />
<ToastNotification
hideCloseButton
kind="warning"
title="Upcoming scheduled maintenance"
on:close="{(e) => {
console.log(e.detail.timeout);
}}"
/>
<ToastNotification kind="error" />
<ToastNotification kind="info" />
<ToastNotification kind="info-square" />
<ToastNotification kind="success" />
<ToastNotification kind="warning" />
<ToastNotification kind="warning-alt" />
<ToastNotification lowContrast kind="error" />
<ToastNotification lowContrast kind="info" />
<ToastNotification lowContrast kind="info-square" />
<ToastNotification lowContrast kind="success" />
<ToastNotification lowContrast kind="warning" />
<ToastNotification lowContrast kind="warning-alt" />