From e4862f1878769dab7698320aee6bf8750826a827 Mon Sep 17 00:00:00 2001 From: Jonas Date: Fri, 23 Jan 2026 22:59:32 +0100 Subject: [PATCH] - Enhance 404 page design and add link to home - Update routes to include "Login" page - Add dynamic website title updates based on current route - Add "Login" button to layout linking to Login page --- API/app.db | Bin 114688 -> 114688 bytes GUI/src/Layout.vue | 23 ++++++++++- GUI/src/plugins/routesLayout.ts | 51 +++++++++++++++--------- GUI/src/routes/404NotFound.vue | 15 ++++++- GUI/src/routes/authentication/Login.vue | 9 +++++ 5 files changed, 76 insertions(+), 22 deletions(-) create mode 100644 GUI/src/routes/authentication/Login.vue diff --git a/API/app.db b/API/app.db index 2eb27a279617ff7a6b828ba996bdd3b9f03bcbf7..6fecaf75e3e6131c499caca7fa3b29e04320ede3 100644 GIT binary patch delta 31 mcmZo@U~gz(-|$YJ$I{BkSkKbH!qU*#viX<%_FwXhYzqLTCkki) delta 31 mcmZo@U~gz(-|$YJ$H2 -import { onMounted, ref } from 'vue'; +import { onMounted, ref, watch } from 'vue'; import { useTheme } from 'vuetify'; import { Visibility, routes } from './plugins/routesLayout'; import { useRoute } from 'vue-router'; @@ -25,6 +25,25 @@ onMounted(() => { ); showDrawer.value = localStorage.getItem('drawer')?.startsWith('Y') || false; }); + +function changeWebsiteTitle(path: string) { + // Pfad als Parameter + let currentPageInfo = routes.find((x) => x.path === path); + if (currentPageInfo) { + document.title = 'Judoteam - Stadtlohn | ' + currentPageInfo.name; + } else { + document.title = 'Judoteam - Stadtlohn'; + } +} + +// Beobachte die Route auf Änderungen +watch( + () => route.path, + (newPath) => { + changeWebsiteTitle(newPath); + }, + { immediate: true }, +);