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,17 +0,0 @@
|
|||
<script>
|
||||
export let story = undefined;
|
||||
|
||||
import Toggle from "./Toggle.svelte";
|
||||
import ToggleSkeleton from "./Toggle.Skeleton.svelte";
|
||||
|
||||
$: toggled = true;
|
||||
$: console.log("bind:toggled", toggled);
|
||||
</script>
|
||||
|
||||
{#if story === 'toggled'}
|
||||
<Toggle {...$$props} id="toggle-id" name="toggle-name" bind:toggled />
|
||||
{:else if story === 'skeleton'}
|
||||
<ToggleSkeleton />
|
||||
{:else}
|
||||
<Toggle {...$$props} id="toggle-1" />
|
||||
{/if}
|
|
@ -1,35 +0,0 @@
|
|||
import { withKnobs, boolean, text } from "@storybook/addon-knobs";
|
||||
import Component from "./Toggle.Story.svelte";
|
||||
|
||||
export default { title: "Toggle", decorators: [withKnobs] };
|
||||
|
||||
export const Default = () => ({
|
||||
Component,
|
||||
props: {
|
||||
labelText: text("Label toggle input control (labelText)", ""),
|
||||
"aria-label": text("ARIA label of the toggle (aria-label)", ""),
|
||||
labelA: text("Label for untoggled state (labelA)", "Off"),
|
||||
labelB: text("Label for toggled state (labelB)", "On"),
|
||||
disabled: boolean("Disabled (disabled)", false),
|
||||
id: text("Toggle id", "toggle-id"),
|
||||
name: text("Toggle name", "toggle-name"),
|
||||
},
|
||||
});
|
||||
|
||||
Default.story = { name: "Default (untoggled)" };
|
||||
|
||||
export const Toggled = () => ({
|
||||
Component,
|
||||
props: {
|
||||
story: "toggled",
|
||||
labelText: text("Label toggle input control (labelText)", ""),
|
||||
"aria-label": text("ARIA label of the toggle (aria-label)", ""),
|
||||
labelA: text("Label for untoggled state (labelA)", "Off"),
|
||||
labelB: text("Label for toggled state (labelB)", "On"),
|
||||
disabled: boolean("Disabled (disabled)", false),
|
||||
id: text("Toggle id", "toggle-id"),
|
||||
name: text("Toggle name", "toggle-name"),
|
||||
},
|
||||
});
|
||||
|
||||
export const Skeleton = () => ({ Component, props: { story: "skeleton" } });
|
Loading…
Add table
Add a link
Reference in a new issue