diff --git a/src/lib/components/SearchInput.svelte b/src/lib/components/SearchInput.svelte index 753d589..eeae1c7 100644 --- a/src/lib/components/SearchInput.svelte +++ b/src/lib/components/SearchInput.svelte @@ -1,29 +1,158 @@ +{#if showBanner} +
+ + {#if bannerIsIndigo} + Testament & section groups now visible + {:else} + Old & New Testament groups now visible + {/if} +
+{/if} +
+ {#if searchQuery && filteredBooks.length > 0}
+ + + {/each} + {:else} + {#each sectionGroups as group (`${group.testament}:${group.section}`)} +
  • + {#if group.showTestamentHeader} +
    + + {group.testamentLabel} + +
    +
    + {/if} +
    + + {group.section} + +
    +
    + +
  • + {/each} + {/if} {:else if searchQuery}

    No books found

    diff --git a/src/routes/+page.svelte b/src/routes/+page.svelte index e4447de..3ee9cb9 100644 --- a/src/routes/+page.svelte +++ b/src/routes/+page.svelte @@ -25,6 +25,7 @@ type StatsData, } from "$lib/utils/stats-client"; import { createGamePersistence } from "$lib/stores/game-persistence.svelte"; + import { SvelteSet } from "svelte/reactivity"; let { data }: PageProps = $props(); @@ -51,7 +52,7 @@ ); let guessedIds = $derived( - new Set(persistence.guesses.map((g) => g.book.id)), + new SvelteSet(persistence.guesses.map((g) => g.book.id)), ); const currentDate = $derived( @@ -302,7 +303,7 @@ {#if !isWon}
    - +
    {:else if showWinScreen}