aboutsummaryrefslogtreecommitdiff
path: root/src/lib/components/RegularList.svelte
diff options
context:
space:
mode:
authorKaran Jayachandra <mail@karanjayachandra.com>2026-08-30 22:43:21 +0200
committerKaran Jayachandra <mail@karanjayachandra.com>2026-08-30 22:43:21 +0200
commitfc8d8ab8d0da95ec79056f59e14a150df6fcea89 (patch)
tree33f8050b2f2920c0f1b884a205a8aa4c81d7687c /src/lib/components/RegularList.svelte
parentd37ebfda883bcd03b146a85bc3e5a4657d0abd73 (diff)
Moved to sveltemain
Diffstat (limited to 'src/lib/components/RegularList.svelte')
-rw-r--r--src/lib/components/RegularList.svelte14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/lib/components/RegularList.svelte b/src/lib/components/RegularList.svelte
new file mode 100644
index 0000000..dd8fb7a
--- /dev/null
+++ b/src/lib/components/RegularList.svelte
@@ -0,0 +1,14 @@
+<script>
+ import ToggleButton from "./ToggleButton.svelte";
+ import { getRegulars, toggleRegular } from "../stores/regulars.svelte.js";
+</script>
+
+<div id="Regular-list" class="grid-container">
+ {#each getRegulars() as regular (regular.id)}
+ <ToggleButton
+ label={regular.name}
+ active={regular.status}
+ onclick={() => toggleRegular(regular.id)}
+ />
+ {/each}
+</div>