Erweitere die Navigation um einen neuen Link zu "Links" und aktualisiere die Logik zur Bestimmung des aktuellen Submenüs, um die neue Route zu berücksichtigen.
Some checks failed
Code Analysis (JS/Vue) / analyze (push) Failing after 57s
Some checks failed
Code Analysis (JS/Vue) / analyze (push) Failing after 57s
This commit is contained in:
@@ -36,7 +36,7 @@
|
||||
|
||||
<button
|
||||
class="px-4 py-2 text-gray-300 hover:text-white font-medium transition-all rounded-lg hover:bg-primary-700/50"
|
||||
:class="(route.path.startsWith('/verein/') || route.path.startsWith('/vorstand') || route.path.startsWith('/vereinsmeisterschaften') || currentSubmenu === 'verein') ? 'text-white bg-primary-600' : ''"
|
||||
:class="(route.path.startsWith('/verein/') || route.path.startsWith('/vorstand') || route.path.startsWith('/vereinsmeisterschaften') || route.path.startsWith('/links') || currentSubmenu === 'verein') ? 'text-white bg-primary-600' : ''"
|
||||
@click="toggleSubmenu('verein')"
|
||||
>
|
||||
Verein
|
||||
@@ -177,6 +177,13 @@
|
||||
>
|
||||
Galerie
|
||||
</NuxtLink>
|
||||
<NuxtLink
|
||||
to="/links"
|
||||
class="px-2.5 py-1 text-xs text-gray-300 hover:text-white hover:bg-primary-700/50 rounded transition-all"
|
||||
active-class="text-white bg-primary-600"
|
||||
>
|
||||
Links
|
||||
</NuxtLink>
|
||||
</template>
|
||||
|
||||
<!-- Mannschaften Submenu -->
|
||||
@@ -514,6 +521,13 @@
|
||||
>
|
||||
Galerie
|
||||
</NuxtLink>
|
||||
<NuxtLink
|
||||
to="/links"
|
||||
class="block px-4 py-2 text-sm text-gray-400 hover:text-white hover:bg-primary-700/50 rounded-lg transition-colors"
|
||||
@click="isMobileMenuOpen = false"
|
||||
>
|
||||
Links
|
||||
</NuxtLink>
|
||||
<NuxtLink
|
||||
to="/newsletter/subscribe"
|
||||
class="block px-4 py-2 text-sm text-gray-400 hover:text-white hover:bg-primary-700/50 rounded-lg transition-colors"
|
||||
@@ -868,6 +882,7 @@ const canAccessContactRequests = computed(() => {
|
||||
const currentSubmenu = computed(() => {
|
||||
const path = route.path
|
||||
if (path.startsWith('/verein/') || path.startsWith('/vorstand') ||
|
||||
path.startsWith('/links') ||
|
||||
path.startsWith('/vereinsmeisterschaften')) {
|
||||
return 'verein'
|
||||
}
|
||||
@@ -987,7 +1002,7 @@ const toggleSubmenu = (menu) => {
|
||||
|
||||
if (menu === 'newsletter' && !path.startsWith('/newsletter')) {
|
||||
navigateTo('/newsletter/subscribe')
|
||||
} else if (menu === 'verein' && !path.startsWith('/verein/') && !path.startsWith('/vorstand') && !path.startsWith('/vereinsmeisterschaften')) {
|
||||
} else if (menu === 'verein' && !path.startsWith('/verein/') && !path.startsWith('/vorstand') && !path.startsWith('/vereinsmeisterschaften') && !path.startsWith('/links')) {
|
||||
navigateTo('/verein/ueber-uns')
|
||||
} else if (menu === 'mannschaften' && !path.startsWith('/mannschaften') && !path.startsWith('/spielsysteme')) {
|
||||
navigateTo('/mannschaften')
|
||||
|
||||
Reference in New Issue
Block a user