mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-15 10:21:05 +00:00
parent
5ec9c0089f
commit
9afc149193
7 changed files with 155 additions and 0 deletions
23
src/components/ContentSwitcher/ContentSwitcher.Story.svelte
Normal file
23
src/components/ContentSwitcher/ContentSwitcher.Story.svelte
Normal file
|
@ -0,0 +1,23 @@
|
|||
<script>
|
||||
export let story = undefined;
|
||||
|
||||
import Layout from '../../internal/ui/Layout.svelte';
|
||||
import ContentSwitcher from './ContentSwitcher.svelte';
|
||||
import Switch from './Switch.svelte';
|
||||
</script>
|
||||
|
||||
<Layout>
|
||||
{#if story === 'selected'}
|
||||
<ContentSwitcher>
|
||||
<Switch {...$$props} text="First section" />
|
||||
<Switch {...$$props} text="Second section" selected />
|
||||
<Switch {...$$props} text="Third section" />
|
||||
</ContentSwitcher>
|
||||
{:else}
|
||||
<ContentSwitcher>
|
||||
<Switch {...$$props} text="First section" />
|
||||
<Switch {...$$props} text="Second section" />
|
||||
<Switch {...$$props} text="Third section" />
|
||||
</ContentSwitcher>
|
||||
{/if}
|
||||
</Layout>
|
Loading…
Add table
Add a link
Reference in a new issue