mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-16 10:51:06 +00:00
chore: remove storybook
This commit is contained in:
parent
856086dc71
commit
378fe06e03
116 changed files with 103 additions and 14249 deletions
|
@ -1,24 +0,0 @@
|
|||
<script>
|
||||
export let slot = undefined;
|
||||
export let story = undefined;
|
||||
|
||||
import Tag from "./Tag.svelte";
|
||||
import TagSkeleton from "./Tag.Skeleton.svelte";
|
||||
</script>
|
||||
|
||||
<div>
|
||||
{#if story === 'filter'}
|
||||
<Tag
|
||||
{...$$restProps}
|
||||
on:click="{() => {
|
||||
console.log('click');
|
||||
}}"
|
||||
>
|
||||
{slot}
|
||||
</Tag>
|
||||
{:else if story === 'skeleton'}
|
||||
<TagSkeleton />
|
||||
{:else}
|
||||
<Tag {...$$restProps} class="class">{slot}</Tag>
|
||||
{/if}
|
||||
</div>
|
|
@ -1,54 +0,0 @@
|
|||
import { withKnobs, select, boolean, text } from "@storybook/addon-knobs";
|
||||
import Component from "./Tag.Story.svelte";
|
||||
|
||||
export default { title: "Tag", decorators: [withKnobs] };
|
||||
|
||||
const TYPES = {
|
||||
red: "Red",
|
||||
magenta: "Magenta",
|
||||
purple: "Purple",
|
||||
blue: "Blue",
|
||||
cyan: "Cyan",
|
||||
teal: "Teal",
|
||||
green: "Green",
|
||||
gray: "Gray",
|
||||
"cool-gray": "Cool-Gray",
|
||||
"warm-gray": "Warm-Gray",
|
||||
"high-contrast": "High-Contrast",
|
||||
};
|
||||
|
||||
export const Default = () => ({
|
||||
Component,
|
||||
props: {
|
||||
type: select(
|
||||
"Tag type (type)",
|
||||
Object.keys(TYPES).reduce(
|
||||
(items, item) => ({ ...items, [`${item} (${item})`]: item }),
|
||||
{}
|
||||
),
|
||||
"red"
|
||||
),
|
||||
disabled: boolean("Disabled (disabled)", false),
|
||||
slot: text("Content ($$slot)", "This is a tag"),
|
||||
},
|
||||
});
|
||||
|
||||
export const Filter = () => ({
|
||||
Component,
|
||||
props: {
|
||||
story: "filter",
|
||||
filter: true,
|
||||
type: select(
|
||||
"Tag type (type)",
|
||||
Object.keys(TYPES).reduce(
|
||||
(items, item) => ({ ...items, [`${item} (${item})`]: item }),
|
||||
{}
|
||||
),
|
||||
"red"
|
||||
),
|
||||
disabled: boolean("Disabled (disabled)", false),
|
||||
slot: text("Content ($$slot)", "This is a tag"),
|
||||
},
|
||||
});
|
||||
|
||||
export const Skeleton = () => ({ Component, props: { story: "skeleton" } });
|
Loading…
Add table
Add a link
Reference in a new issue