mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-15 10:21:05 +00:00
chore: remove storybook
This commit is contained in:
parent
856086dc71
commit
378fe06e03
116 changed files with 103 additions and 14249 deletions
|
@ -1,93 +0,0 @@
|
|||
<script>
|
||||
export let story = undefined;
|
||||
|
||||
import CheckmarkFilled16 from "carbon-icons-svelte/lib/CheckmarkFilled16";
|
||||
|
||||
import StructuredListBody from "./StructuredListBody.svelte";
|
||||
import StructuredListCell from "./StructuredListCell.svelte";
|
||||
import StructuredListHead from "./StructuredListHead.svelte";
|
||||
import StructuredListInput from "./StructuredListInput.svelte";
|
||||
import StructuredListRow from "./StructuredListRow.svelte";
|
||||
import StructuredListSkeleton from "./StructuredList.Skeleton.svelte";
|
||||
import StructuredList from "./StructuredList.svelte";
|
||||
|
||||
$: selected = "row-1-value";
|
||||
</script>
|
||||
|
||||
<div>
|
||||
{#if story === 'skeleton'}
|
||||
<div style="width: 800px">
|
||||
<StructuredListSkeleton />
|
||||
</div>
|
||||
{:else if story === 'selection'}
|
||||
<StructuredList selection border bind:selected>
|
||||
<StructuredListHead>
|
||||
<StructuredListRow head>
|
||||
<StructuredListCell head>ColumnA</StructuredListCell>
|
||||
<StructuredListCell head>ColumnB</StructuredListCell>
|
||||
<StructuredListCell head>ColumnC</StructuredListCell>
|
||||
<StructuredListCell head>{''}</StructuredListCell>
|
||||
</StructuredListRow>
|
||||
</StructuredListHead>
|
||||
<StructuredListBody>
|
||||
{#each [0, 1, 2, 3] as item, i (item)}
|
||||
<StructuredListRow label for="row-{i}">
|
||||
<StructuredListCell>Row {i}</StructuredListCell>
|
||||
<StructuredListCell>Row {i}</StructuredListCell>
|
||||
<StructuredListCell>
|
||||
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nunc dui
|
||||
magna, finibus id tortor sed, aliquet bibendum augue. Aenean
|
||||
posuere sem vel euismod dignissim. Nulla ut cursus dolor.
|
||||
Pellentesque vulputate nisl a porttitor interdum.
|
||||
</StructuredListCell>
|
||||
<StructuredListInput
|
||||
id="row-{i}"
|
||||
value="row-{i}-value"
|
||||
title="row-{i}-title"
|
||||
name="row-{i}-name"
|
||||
/>
|
||||
<StructuredListCell>
|
||||
<CheckmarkFilled16
|
||||
class="bx--structured-list-svg"
|
||||
aria-label="select an option"
|
||||
title="select an option"
|
||||
/>
|
||||
</StructuredListCell>
|
||||
</StructuredListRow>
|
||||
{/each}
|
||||
</StructuredListBody>
|
||||
</StructuredList>
|
||||
{:else}
|
||||
<StructuredList>
|
||||
<StructuredListHead>
|
||||
<StructuredListRow head>
|
||||
<StructuredListCell head>ColumnA</StructuredListCell>
|
||||
<StructuredListCell head>ColumnB</StructuredListCell>
|
||||
<StructuredListCell head>ColumnC</StructuredListCell>
|
||||
</StructuredListRow>
|
||||
</StructuredListHead>
|
||||
<StructuredListBody>
|
||||
<StructuredListRow>
|
||||
<StructuredListCell noWrap>Row 1</StructuredListCell>
|
||||
<StructuredListCell>Row 1</StructuredListCell>
|
||||
<StructuredListCell>
|
||||
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nunc dui
|
||||
magna, finibus id tortor sed, aliquet bibendum augue. Aenean posuere
|
||||
sem vel euismod dignissim. Nulla ut cursus dolor. Pellentesque
|
||||
vulputate nisl a porttitor interdum.
|
||||
</StructuredListCell>
|
||||
</StructuredListRow>
|
||||
<StructuredListRow>
|
||||
<StructuredListCell noWrap>Row 2</StructuredListCell>
|
||||
<StructuredListCell>Row 2</StructuredListCell>
|
||||
<StructuredListCell>
|
||||
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nunc dui
|
||||
magna, finibus id tortor sed, aliquet bibendum augue. Aenean posuere
|
||||
sem vel euismod dignissim. Nulla ut cursus dolor. Pellentesque
|
||||
vulputate nisl a porttitor interdum.
|
||||
</StructuredListCell>
|
||||
</StructuredListRow>
|
||||
</StructuredListBody>
|
||||
</StructuredList>
|
||||
{/if}
|
||||
</div>
|
|
@ -1,10 +0,0 @@
|
|||
import { withKnobs } from "@storybook/addon-knobs";
|
||||
import Component from "./StructuredList.Story.svelte";
|
||||
|
||||
export default { title: "StructuredList", decorators: [withKnobs] };
|
||||
|
||||
export const Default = () => ({ Component });
|
||||
|
||||
export const Selection = () => ({ Component, props: { story: "selection" } });
|
||||
|
||||
export const Skeleton = () => ({ Component, props: { story: "skeleton" } });
|
Loading…
Add table
Add a link
Reference in a new issue