diff options
| author | Ariel Costas Guerrero <94913521+arielcostas@users.noreply.github.com> | 2025-03-14 23:33:56 +0100 |
|---|---|---|
| committer | Ariel Costas Guerrero <94913521+arielcostas@users.noreply.github.com> | 2025-03-14 23:33:56 +0100 |
| commit | e3c4bb2efa513973bc26949a8be62fbe66e31a4f (patch) | |
| tree | 75a46cbde3ec2d36cfd33bff63ae7c65d145c182 /src/partials/Header.astro | |
| parent | 54dab1e00b38693e96c801d0c5a020693a35bbda (diff) | |
Implement new page layouts for Home, Contact, Portfolio, and Trajectory; update header and footer for multilingual support
Diffstat (limited to 'src/partials/Header.astro')
| -rw-r--r-- | src/partials/Header.astro | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/src/partials/Header.astro b/src/partials/Header.astro index 35a39ae..bd8c9d6 100644 --- a/src/partials/Header.astro +++ b/src/partials/Header.astro @@ -1,9 +1,16 @@ +--- +import { getRelativeLocaleUrl } from "astro:i18n"; +import { useTranslations } from "../i18n" + +const t = useTranslations(Astro.currentLocale); +--- + <header> - <a href="/">Inicio</a> - <a href="/trajectory">Trayectoria</a> - <a href="/portfolio">Portfolio</a> - <a href="/blog">Blog</a> - <a href="/contact">Contacto</a> + <a href={getRelativeLocaleUrl(Astro.currentLocale!, "")}>{t.header.home}</a> + <a href={getRelativeLocaleUrl(Astro.currentLocale!, "trajectory")}>{t.header.trajectory}</a> + <a href={getRelativeLocaleUrl(Astro.currentLocale!, "portfolio")}>{t.header.portfolio}</a> + <a href={getRelativeLocaleUrl("es", "blog")}>{t.header.blog}</a> + <a href={getRelativeLocaleUrl(Astro.currentLocale!, "contact")}>{t.header.contact}</a> </header> <style lang="scss"> |
