Some checks failed
CI / PHP 8.4 / mariadb:10.6 (pull_request) Successful in 11m34s
CI / PHP 8.3 / mariadb:10.6 (pull_request) Successful in 12m8s
CI / PHP 8.4 / mariadb:11.4 (pull_request) Successful in 15m14s
CI / PHP 8.3 / mariadb:11.4 (pull_request) Successful in 15m47s
CI / PHP 8.4 / mysql:8.0 (pull_request) Failing after 13m48s
CI / PHP 8.3 / mysql:8.0 (pull_request) Failing after 14m15s
CI / PHP 8.4 / mysql:8.4 (pull_request) Failing after 16m38s
CI / PHP 8.3 / mysql:8.4 (pull_request) Failing after 17m2s
CI / Bekannte Sicherheitslücken in Paketen (pull_request) Successful in 1m16s
CI / Build-Artefakte aktuell (pull_request) Successful in 1m53s
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
57 lines
2.6 KiB
Vue
57 lines
2.6 KiB
Vue
<script setup>
|
||
import { computed } from 'vue';
|
||
import { Link, usePage } from '@inertiajs/vue3';
|
||
import { House, ListChecks, Menu, Search, Users } from '@lucide/vue';
|
||
|
||
// Untere Menüleiste der Mitarbeiter-App-Oberfläche am Handy – wie in der App:
|
||
// die festen Ziele des Kerns, alles andere hinter „Mehr“ (das Hauptmenü).
|
||
defineProps({ moreOpen: { type: Boolean, default: false } });
|
||
const emit = defineEmits(['more']);
|
||
|
||
const page = usePage();
|
||
const path = computed(() => page.url.split('?')[0]);
|
||
|
||
const items = [
|
||
{ href: '/', label: 'Start', icon: House, match: (p) => p === '/' },
|
||
{ href: '/aufgaben', label: 'Aufgaben', icon: ListChecks, match: (p) => p.startsWith('/aufgaben') },
|
||
{ href: '/personen', label: 'Personen', icon: Users, match: (p) => p.startsWith('/personen') },
|
||
{ href: '/suche', label: 'Suche', icon: Search, match: (p) => p.startsWith('/suche') },
|
||
];
|
||
</script>
|
||
|
||
<template>
|
||
<nav
|
||
class="fixed inset-x-0 bottom-0 z-40 border-t bg-card/95 pb-[env(safe-area-inset-bottom,0px)] shadow-[0_-4px_16px_rgb(0_0_0/0.04)] backdrop-blur lg:hidden print:hidden"
|
||
aria-label="Schnellnavigation"
|
||
>
|
||
<ul class="mx-auto grid h-16 max-w-xl grid-cols-5">
|
||
<li v-for="item in items" :key="item.href">
|
||
<Link
|
||
:href="item.href"
|
||
class="flex h-full flex-col items-center justify-center gap-1 text-[11px] font-medium"
|
||
:class="item.match(path) && !moreOpen ? 'text-brand-text' : 'text-muted-foreground hover:text-foreground'"
|
||
:aria-current="item.match(path) ? 'page' : undefined"
|
||
>
|
||
<span class="grid h-7 w-12 place-items-center rounded-pill transition-colors" :class="{ 'bg-brand-soft': item.match(path) && !moreOpen }">
|
||
<component :is="item.icon" class="size-5" />
|
||
</span>
|
||
{{ item.label }}
|
||
</Link>
|
||
</li>
|
||
<li>
|
||
<button
|
||
type="button"
|
||
class="flex h-full w-full flex-col items-center justify-center gap-1 text-[11px] font-medium"
|
||
:class="moreOpen ? 'text-brand-text' : 'text-muted-foreground hover:text-foreground'"
|
||
:aria-expanded="moreOpen"
|
||
@click="emit('more')"
|
||
>
|
||
<span class="grid h-7 w-12 place-items-center rounded-pill transition-colors" :class="{ 'bg-brand-soft': moreOpen }">
|
||
<Menu class="size-5" />
|
||
</span>
|
||
Mehr
|
||
</button>
|
||
</li>
|
||
</ul>
|
||
</nav>
|
||
</template>
|