Use toggle buttons for the Lunch child picker

This commit is contained in:
iamdoubz committed 2026-11-05 22:05:35 -06:00
1 parent 682fcc5830
commit eac8a6f7d1
1 file changed
+3 -3
+3 -3
View File
@@ -82,9 +82,9 @@
</EmptyState>
{:else}
<div class="stack-lg">
<div class="kids" role="tablist" aria-label="Child">
<div class="kids" role="group" aria-label="Child">
{#each kids as c (c.id)}
<button role="tab" aria-selected={c.id === childId} onclick={() => (childId = c.id)} style:--c={c.color}>
<button aria-pressed={c.id === childId} onclick={() => (childId = c.id)} style:--c={c.color}>
<span class="dot" style:background={c.color} aria-hidden="true"></span>{c.display_name}
</button>
{/each}
@@ -158,7 +158,7 @@
<style>
.kids { display: flex; flex-wrap: wrap; gap: var(--s2); }
.kids button { border-radius: var(--r-full); padding: 0 var(--s4); }
.kids button[aria-selected='true'] { border-color: var(--c); background: color-mix(in srgb, var(--c) 14%, var(--surface)); box-shadow: inset 0 0 0 1px var(--c); }
.kids button[aria-pressed='true'] { border-color: var(--c); background: color-mix(in srgb, var(--c) 14%, var(--surface)); box-shadow: inset 0 0 0 1px var(--c); }
.kids .dot { width: 12px; height: 12px; }
.month-bar { display: flex; align-items: center; gap: var(--s1); }