feat: enable live search on all recipe pages
All checks were successful
CI / update (push) Successful in 1m9s

Previously, live client-side search only worked on the main /rezepte and /recipes pages. All other pages (category, tag, favorites, search results, icon, and season pages) fell back to server-side search with form submission.

Now all recipe pages support live filtering as users type, providing consistent UX across the site.
This commit is contained in:
2026-01-02 20:25:43 +01:00
parent f6258ae518
commit 903722b335
10 changed files with 177 additions and 25 deletions

View File

@@ -6,6 +6,8 @@
export let active_icon
export let routePrefix = '/rezepte'
export let lang = 'de'
export let recipes = []
export let onSearchResults = (ids, categories) => {}
</script>
<style>
@@ -74,7 +76,7 @@
{/each}
</div>
<section>
<Search icon={active_icon} {lang}></Search>
<Search icon={active_icon} {lang} {recipes} {onSearchResults}></Search>
</section>
<section>
<slot name=recipes></slot>

View File

@@ -7,6 +7,8 @@
export let active_index;
export let routePrefix = '/rezepte';
export let lang = 'de';
export let recipes = []
export let onSearchResults = (ids, categories) => {}
</script>
<style>
@@ -43,7 +45,7 @@ a.month:hover,
{/each}
</div>
<section>
<Search season={active_index + 1} {lang}></Search>
<Search season={active_index + 1} {lang} {recipes} {onSearchResults}></Search>
</section>
<section>
<slot name=recipes></slot>