From 3a92ac735eb78b03cab776de380025a95e17974d Mon Sep 17 00:00:00 2001 From: Robin Date: Thu, 11 Dec 2025 14:46:23 +0000 Subject: [PATCH 1/4] Add 404 page Fixes #452 --- src/layouts/groups/Contact.astro | 2 +- src/pages/404.astro | 61 ++++++++++++++++++++++++++++++++ 2 files changed, 62 insertions(+), 1 deletion(-) create mode 100644 src/pages/404.astro diff --git a/src/layouts/groups/Contact.astro b/src/layouts/groups/Contact.astro index 52549127..f84427ac 100644 --- a/src/layouts/groups/Contact.astro +++ b/src/layouts/groups/Contact.astro @@ -21,7 +21,7 @@ const locale = currentLocale.get(); { - withoutLanguageSwitcher ? null : ( + withoutLanguageSwitcher || !translations ? null : (
  • diff --git a/src/pages/404.astro b/src/pages/404.astro new file mode 100644 index 00000000..f21f1070 --- /dev/null +++ b/src/pages/404.astro @@ -0,0 +1,61 @@ +--- +import Button from "../components/Button.astro"; +import Shell from "../layouts/Shell.astro"; +import Article from "../layouts/templates/Article.astro"; +--- + + + + +
    +
    +
    +

    Sorry, the page you are looking for does not exist.

    + +
    +
    +
    +
    +
    +
    +

    Entschuldigung, die von Ihnen gesuchte Seite existiert nicht.

    + +
    +
    +
    + + +
    From 802044d8f006f499a2cdbb1aa1cd163e51eb1700 Mon Sep 17 00:00:00 2001 From: Robin Date: Thu, 11 Dec 2025 14:48:37 +0000 Subject: [PATCH 2/4] chore: simplify code --- src/pages/404.astro | 25 ++++++++----------------- 1 file changed, 8 insertions(+), 17 deletions(-) diff --git a/src/pages/404.astro b/src/pages/404.astro index f21f1070..8e731a21 100644 --- a/src/pages/404.astro +++ b/src/pages/404.astro @@ -35,23 +35,14 @@ import Article from "../layouts/templates/Article.astro"; - + register(); + document.addEventListener("astro:after-swap", register); +