diff options
| author | Owen Jacobson <owen@grimoire.ca> | 2025-07-08 19:45:49 -0400 |
|---|---|---|
| committer | Owen Jacobson <owen@grimoire.ca> | 2025-07-08 19:45:49 -0400 |
| commit | a2a0ec035f74a454df5a76ed999355f536f5b277 (patch) | |
| tree | c960ce63f6e32d859d3c3de501d15c50b144dbcf | |
| parent | c631c8fc855b1854f14fc7fbf1d8afedaa37a0db (diff) | |
Create a swatch for the `Conversation` component.
| -rw-r--r-- | ui/routes/(swatch)/.swatch/+page.svelte | 1 | ||||
| -rw-r--r-- | ui/routes/(swatch)/.swatch/Conversation/+page.svelte | 31 |
2 files changed, 32 insertions, 0 deletions
diff --git a/ui/routes/(swatch)/.swatch/+page.svelte b/ui/routes/(swatch)/.swatch/+page.svelte index abcb53f..165bbad 100644 --- a/ui/routes/(swatch)/.swatch/+page.svelte +++ b/ui/routes/(swatch)/.swatch/+page.svelte @@ -8,5 +8,6 @@ <h2>components</h2> <ul> + <li><a href="Conversation">Conversation</a></li> <li><a href="swatch/EventLog">swatch/EventLog</a></li> </ul> diff --git a/ui/routes/(swatch)/.swatch/Conversation/+page.svelte b/ui/routes/(swatch)/.swatch/Conversation/+page.svelte new file mode 100644 index 0000000..0b98204 --- /dev/null +++ b/ui/routes/(swatch)/.swatch/Conversation/+page.svelte @@ -0,0 +1,31 @@ +<script> + import Conversation from '$lib/components/Conversation.svelte'; + + let id = $state('Czero'); + let name = $state('a long conversation'); + let active = $state(false); + let hasUnreads = $state(false); +</script> + +<h1><code>Conversation</code></h1> + +<nav><p><a href=".">Back to swatches</a></p></nav> + +<h2>properties</h2> + +<div class="component-properties"> + <label>id <input type="text" bind:value={id} /></label> + <label>name <input type="text" bind:value={name} /></label> + <label>active <input type="checkbox" bind:checked={active} /></label> + <label>has unreads <input type="checkbox" bind:checked={hasUnreads} /></label> +</div> + +<h2>rendered</h2> + +<div class="component-preview"> + <nav class="list-nav"> + <ul> + <Conversation {id} {name} {active} {hasUnreads} /> + </ul> + </nav> +</div> |
