phase-2: extract shared utils

This commit is contained in:
Sai Kiran Vella
2026-06-04 11:06:30 -04:00
committed by saikiranvella
parent 5a4b4aa6d1
commit d5cf3fc31f
49 changed files with 299 additions and 120 deletions
+4 -1
View File
@@ -1,7 +1,10 @@
<script>
import { untrack } from 'svelte';
let { ctx, collapsible = false } = $props();
let expanded = $state(!collapsible); // collapsed by default when collapsible=true
// Read collapsible once for initial state — untrack avoids a reactive dep on the prop
let expanded = $state(untrack(() => !collapsible));
const cards = $derived.by(() => {
const b = ctx?.benchmarks ?? {};