feat: add page titles to recipe and glaube routes
All checks were successful
CI / update (push) Successful in 1m20s
All checks were successful
CI / update (push) Successful in 1m20s
- Add titles to category, tag, icon, season routes - Add bilingual support (German/English) for recipe route titles - Use consistent "Bocken Recipes" / "Bocken Rezepte" branding - Change English tagline from "Bocken's Recipes" to "Bocken Recipes" - Add titles to /glaube and /glaube/gebete pages - Make tips-and-tricks page language-aware
This commit is contained in:
@@ -7,7 +7,17 @@
|
||||
import Card from '$lib/components/Card.svelte';
|
||||
import Search from '$lib/components/Search.svelte';
|
||||
let { data } = $props<{ data: PageData }>();
|
||||
|
||||
const isEnglish = $derived(data.lang === 'en');
|
||||
const labels = $derived({
|
||||
title: isEnglish ? 'Icons' : 'Icons',
|
||||
siteTitle: isEnglish ? 'Bocken Recipes' : 'Bocken Rezepte'
|
||||
});
|
||||
</script>
|
||||
|
||||
<svelte:head>
|
||||
<title>{labels.title} - {labels.siteTitle}</title>
|
||||
</svelte:head>
|
||||
<style>
|
||||
a{
|
||||
font-family: "Noto Color Emoji", emoji, sans-serif;
|
||||
|
||||
@@ -8,6 +8,9 @@
|
||||
let { data } = $props<{ data: PageData }>();
|
||||
import { rand_array } from '$lib/js/randomize';
|
||||
|
||||
const isEnglish = $derived(data.lang === 'en');
|
||||
const siteTitle = $derived(isEnglish ? 'Bocken Recipes' : 'Bocken Rezepte');
|
||||
|
||||
// Search state
|
||||
let matchedRecipeIds = $state(new Set());
|
||||
let hasActiveSearch = $state(false);
|
||||
@@ -26,6 +29,11 @@
|
||||
return data.season.filter(r => matchedRecipeIds.has(r._id));
|
||||
});
|
||||
</script>
|
||||
|
||||
<svelte:head>
|
||||
<title>{data.icon} - {siteTitle}</title>
|
||||
</svelte:head>
|
||||
|
||||
<IconLayout icons={data.icons} active_icon={data.icon} routePrefix="/{data.recipeLang}" lang={data.lang} recipes={data.season} isLoggedIn={!!data.session?.user} onSearchResults={handleSearchResults}>
|
||||
{#snippet recipesSlot()}
|
||||
<Recipes>
|
||||
|
||||
Reference in New Issue
Block a user