feat: add Storybook component explorer
This commit is contained in:
parent
f1dc95b51c
commit
d95f064189
47 changed files with 1730 additions and 8 deletions
27
src/lib/ui/stories/StatusStrip.stories.svelte
Normal file
27
src/lib/ui/stories/StatusStrip.stories.svelte
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
<script module lang="ts">
|
||||
import { defineMeta } from "@storybook/addon-svelte-csf";
|
||||
import StatusStrip from "../components/StatusStrip.svelte";
|
||||
import { mixedStatusStrip, statusItems } from "./story-data";
|
||||
|
||||
const { Story } = defineMeta({
|
||||
title: "Dashboard Primitives/StatusStrip",
|
||||
component: StatusStrip,
|
||||
tags: ["autodocs"],
|
||||
});
|
||||
</script>
|
||||
|
||||
<Story
|
||||
name="All Operational"
|
||||
args={{
|
||||
items: [
|
||||
{ ...statusItems.ok, id: "status-ok-a" },
|
||||
{ ...statusItems.ok, id: "status-ok-b", label: "Queue" },
|
||||
{ ...statusItems.ok, id: "status-ok-c", label: "Sync" },
|
||||
],
|
||||
}}
|
||||
/>
|
||||
<Story name="Degraded" args={{ items: [statusItems.ok, statusItems.degraded, statusItems.stale] }} />
|
||||
<Story name="Incident" args={{ items: [statusItems.ok, statusItems.incident, statusItems.degraded] }} />
|
||||
<Story name="Syncing" args={{ items: [statusItems.syncing, statusItems.ok, statusItems.action] }} />
|
||||
<Story name="Stale" args={{ items: [statusItems.stale, statusItems.long] }} />
|
||||
<Story name="Mixed Compact" args={{ items: mixedStatusStrip, compact: true }} />
|
||||
Loading…
Add table
Add a link
Reference in a new issue