mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-17 11:11:25 +00:00
parent
422ac528a7
commit
94dceae1fb
11 changed files with 309 additions and 2 deletions
20
src/components/Notification/Notification.Story.svelte
Normal file
20
src/components/Notification/Notification.Story.svelte
Normal file
|
@ -0,0 +1,20 @@
|
|||
<script>
|
||||
export let story = undefined;
|
||||
|
||||
import Layout from '../../internal/ui/Layout.svelte';
|
||||
import InlineNotification from './InlineNotification.svelte';
|
||||
import ToastNotification from './ToastNotification.svelte';
|
||||
import NotificationActionButton from './NotificationActionButton.svelte';
|
||||
</script>
|
||||
|
||||
<Layout>
|
||||
{#if story === 'inline'}
|
||||
<InlineNotification {...$$props}>
|
||||
<div slot="actions">
|
||||
<NotificationActionButton>{$$props.action}</NotificationActionButton>
|
||||
</div>
|
||||
</InlineNotification>
|
||||
{:else if story === 'toast'}
|
||||
<ToastNotification {...$$props} style="min-width: 30rem; margin-bottom: .5rem" />
|
||||
{/if}
|
||||
</Layout>
|
Loading…
Add table
Add a link
Reference in a new issue