Phase 5: Erscheinungsbild mit Entwurf, Vorschau und Veröffentlichen
Some checks failed
CI / PHP 8.3 / mariadb:10.6 (pull_request) Successful in 2m7s
CI / PHP 8.4 / mariadb:10.6 (pull_request) Successful in 2m11s
CI / PHP 8.3 / mariadb:11.4 (pull_request) Successful in 2m16s
CI / PHP 8.4 / mariadb:11.4 (pull_request) Successful in 2m18s
CI / PHP 8.3 / mysql:8.0 (pull_request) Failing after 2m49s
CI / PHP 8.4 / mysql:8.0 (pull_request) Failing after 2m46s
CI / PHP 8.3 / mysql:8.4 (pull_request) Failing after 2m41s
CI / PHP 8.4 / mysql:8.4 (pull_request) Failing after 2m33s
CI / Build-Artefakte aktuell (pull_request) Successful in 1m0s

- Theme in den Einstellungen (Entwurf/veröffentlicht), Übernahme der
  Einstellungen aus Phase 0; statische CSS-Datei mit Hash beim Veröffentlichen
- Logos hell/dunkel, Signet, App-Symbol → Favicon, Homescreen-Symbole,
  Web-App-Manifest; SVG-Bereinigung
- Markenfarbe exakt, zweite Akzentfarbe, Kopfleiste hell/Marke/dunkel,
  Kontrastprüfung (WCAG AA) mit automatisch lesbarer Linkfarbe
- Lokale Schriften (Latein), Überschriften-Schrift, eigene WOFF2-Schrift,
  Ecken, Dichte, Dunkelmodus-Regel
- Anmeldeseite (geteilt/zentriert, Bild, Texte), Fußzeile, E-Mails im Design
- Admin: Live-Vorschau (Startseite, Anmeldung, Beispielseite; hell/dunkel),
  Veröffentlichen, Verwerfen, Export/Import, Zurücksetzen, eigenes CSS
- Admin-Bereich übernimmt Logo, Farbe und Favicon; Whitelabel

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Friederich Loheide 2026-09-26 10:46:05 +00:00
parent ee8dde93c0
commit 82bbeef31b
148 changed files with 2884 additions and 362 deletions

View file

@ -2,21 +2,38 @@
import { computed } from 'vue';
import { usePage } from '@inertiajs/vue3';
defineProps({
/**
* Logo aus dem Erscheinungsbild: helle bzw. dunkle Variante je nach Untergrund,
* auf kleinen Bildschirmen (compact) das quadratische Signet, falls vorhanden.
*/
const props = defineProps({
inverted: { type: Boolean, default: false },
compact: { type: Boolean, default: false },
});
const branding = computed(() => usePage().props.branding);
const monogram = computed(() => branding.value.portal_name.trim().charAt(0).toUpperCase());
const onDark = computed(() => branding.value.logo_dark_url ?? branding.value.logo_url);
</script>
<template>
<span class="flex items-center gap-3">
<img v-if="branding.logo_url" :src="branding.logo_url" :alt="branding.portal_name" class="h-8 w-auto" />
<template v-if="branding.logo_url">
<img v-if="compact && branding.logo_mark_url" :src="branding.logo_mark_url" :alt="branding.portal_name" class="size-8 sm:hidden" />
<span :class="compact && branding.logo_mark_url ? 'hidden sm:contents' : 'contents'">
<img v-if="props.inverted" :src="onDark" :alt="branding.portal_name" class="h-8 w-auto" />
<template v-else>
<img :src="branding.logo_url" :alt="branding.portal_name" class="h-8 w-auto dark:hidden" />
<img :src="onDark" :alt="branding.portal_name" class="hidden h-8 w-auto dark:block" />
</template>
</span>
</template>
<template v-else>
<img v-if="branding.logo_mark_url" :src="branding.logo_mark_url" alt="" class="size-8" />
<span
v-else
class="grid size-8 place-items-center rounded-md text-base font-bold"
:class="inverted ? 'bg-white/15 text-white' : 'bg-brand text-brand-foreground'"
:class="props.inverted ? 'bg-white/15 text-current' : 'bg-brand text-brand-foreground'"
>
{{ monogram }}
</span>

View file

@ -25,6 +25,8 @@ defineProps({
const page = usePage();
const user = computed(() => page.props.auth.user);
const branding = computed(() => page.props.branding);
const headerStyle = computed(() => branding.value.header_style ?? 'light');
const navigation = computed(() => page.props.navigation);
const { preference, setPreference } = useThemePreference();
@ -45,8 +47,16 @@ const themeOptions = [
<template>
<Head v-if="title" :title="title" />
<div class="min-h-screen">
<header class="sticky top-0 z-40 border-b bg-card/95 backdrop-blur supports-[backdrop-filter]:bg-card/85">
<div class="flex min-h-screen flex-col">
<div v-if="branding.preview" class="flex flex-wrap items-center justify-center gap-x-3 gap-y-1 bg-amber-400 px-4 py-1.5 text-center text-[13px] font-medium text-amber-950">
Vorschau des Entwurfs – so sieht das Portal nach dem Veröffentlichen aus.
<a href="?vorschau=aus" class="underline">Vorschau beenden</a>
</div>
<header
class="sticky top-0 z-40 border-b"
:class="headerStyle === 'light' ? 'bg-card/95 backdrop-blur supports-[backdrop-filter]:bg-card/85' : ''"
:data-header="headerStyle"
>
<div class="mx-auto flex h-16 max-w-[1440px] items-center gap-2 px-4 lg:gap-6 lg:px-6">
<Sheet v-model:open="mobileNavOpen">
<SheetTrigger class="-ml-2 grid size-10 place-items-center rounded-md text-foreground/80 hover:bg-accent lg:hidden" aria-label="Menü öffnen">
@ -72,7 +82,7 @@ const themeOptions = [
</Sheet>
<Link href="/" class="shrink-0 text-foreground" aria-label="Startseite">
<BrandLogo />
<BrandLogo :inverted="headerStyle !== 'light'" compact />
</Link>
<nav class="hidden h-full lg:block" aria-label="Hauptnavigation">
@ -85,7 +95,7 @@ const themeOptions = [
:aria-current="item.active ? 'page' : undefined"
>
{{ item.label }}
<span v-if="item.active" class="absolute inset-x-3 bottom-0 h-[3px] rounded-t-full bg-brand" />
<span v-if="item.active" class="nav-underline absolute inset-x-3 bottom-0 h-[3px] rounded-t-full bg-brand" />
</Link>
</li>
</ul>
@ -147,6 +157,7 @@ const themeOptions = [
<DropdownMenuItem v-if="user.can_admin" as-child>
<a href="/admin"><Settings /> Administration</a>
</DropdownMenuItem>
<template v-if="!branding.color_mode">
<DropdownMenuSeparator />
<DropdownMenuLabel class="text-xs font-medium text-muted-foreground">Darstellung</DropdownMenuLabel>
<DropdownMenuRadioGroup :model-value="preference" @update:model-value="setPreference">
@ -155,6 +166,7 @@ const themeOptions = [
{{ option.label }}
</DropdownMenuRadioItem>
</DropdownMenuRadioGroup>
</template>
<DropdownMenuSeparator />
<DropdownMenuItem as-child>
<Link href="/logout" method="post" as="button" class="w-full"><LogOut /> Abmelden</Link>
@ -165,9 +177,18 @@ const themeOptions = [
</div>
</header>
<main class="mx-auto max-w-[1440px] px-4 py-6 lg:px-6 lg:py-8">
<main class="mx-auto w-full max-w-[1440px] flex-1 px-4 py-6 lg:px-6 lg:py-8">
<slot />
</main>
<footer v-if="branding.footer.text || branding.footer.links.length" class="border-t">
<div class="mx-auto flex max-w-[1440px] flex-wrap items-center justify-between gap-x-6 gap-y-2 px-4 py-5 text-[13px] text-muted-foreground lg:px-6">
<p v-if="branding.footer.text">{{ branding.footer.text }}</p>
<nav v-if="branding.footer.links.length" class="flex flex-wrap gap-x-5 gap-y-1" aria-label="Fußzeile">
<a v-for="link in branding.footer.links" :key="link.url" :href="link.url" class="hover:text-foreground hover:underline">{{ link.label }}</a>
</nav>
</div>
</footer>
</div>
<Toaster position="bottom-right" />

View file

@ -3,29 +3,56 @@ import { computed } from 'vue';
import { Head, usePage } from '@inertiajs/vue3';
import BrandLogo from '@/components/BrandLogo.vue';
/**
* Anmelden, Passwort vergessen … – Aufteilung, Bild und Texte aus dem Erscheinungsbild.
*/
const props = defineProps({
title: { type: String, default: '' },
description: { type: String, default: '' },
});
const branding = computed(() => usePage().props.branding);
const login = computed(() => branding.value.login ?? { layout: 'split' });
</script>
<template>
<Head :title="props.title" />
<div class="grid min-h-screen lg:grid-cols-[minmax(0,5fr)_minmax(0,6fr)]">
<div v-if="branding.preview" class="bg-amber-400 px-4 py-1.5 text-center text-[13px] font-medium text-amber-950">Vorschau des Entwurfs</div>
<!-- Zentriert: Anmeldung als Karte vor dem Hintergrundbild -->
<div v-if="login.layout === 'centered'" class="relative grid min-h-screen place-items-center bg-brand px-4 py-12">
<img v-if="login.image_url" :src="login.image_url" alt="" class="absolute inset-0 size-full object-cover" />
<div v-if="login.image_url" class="absolute inset-0 bg-black/35" />
<div class="relative w-full max-w-[440px]">
<div class="rounded-xl border bg-card p-8 text-card-foreground shadow-xl sm:p-10">
<div class="mb-8"><BrandLogo /></div>
<h1 class="text-2xl font-semibold tracking-tight">{{ props.title }}</h1>
<p v-if="props.description" class="mt-2 text-sm text-muted-foreground">{{ props.description }}</p>
<div class="mt-8"><slot /></div>
</div>
<p v-if="login.title" class="mt-6 text-center text-sm text-white/90 [text-shadow:0_1px_2px_rgb(0_0_0/0.4)]">{{ login.title }}</p>
</div>
</div>
<!-- Geteilt: Markenfläche bzw. Bild links, Anmeldung rechts -->
<div v-else class="grid min-h-screen lg:grid-cols-[minmax(0,5fr)_minmax(0,6fr)]">
<aside class="relative hidden overflow-hidden bg-brand text-brand-foreground lg:flex lg:flex-col lg:justify-between lg:p-12">
<template v-if="login.image_url">
<img :src="login.image_url" alt="" class="absolute inset-0 size-full object-cover" />
<div class="absolute inset-0 bg-gradient-to-t from-black/70 via-black/25 to-black/10" />
</template>
<div
v-else
class="pointer-events-none absolute inset-0 opacity-[0.12]"
style="background-image: radial-gradient(circle at 20% 20%, white 0, transparent 45%), radial-gradient(circle at 90% 80%, white 0, transparent 40%)"
/>
<BrandLogo inverted class="relative" />
<div class="relative max-w-md">
<p class="text-3xl leading-tight font-semibold tracking-tight">Alles Wichtige für Ihren Arbeitsalltag – an einem Ort.</p>
<p class="mt-4 text-[15px] opacity-80">Neuigkeiten, Ansprechpartner und Anwendungen von {{ branding.portal_name }}.</p>
<BrandLogo inverted class="relative" :class="login.image_url ? 'text-white' : ''" />
<div class="relative max-w-md" :class="login.image_url ? 'text-white' : ''">
<p v-if="login.title" class="text-3xl leading-tight font-semibold tracking-tight">{{ login.title }}</p>
<p class="mt-4 text-[15px] opacity-85">{{ login.text || `Neuigkeiten, Ansprechpartner und Anwendungen von ${branding.portal_name}.` }}</p>
</div>
<p class="relative text-xs opacity-60">© {{ new Date().getFullYear() }} {{ branding.portal_name }}</p>
<p class="relative text-xs opacity-70" :class="login.image_url ? 'text-white' : ''">© {{ new Date().getFullYear() }} {{ branding.portal_name }}</p>
</aside>
<main class="flex items-center justify-center bg-background px-4 py-12 sm:px-8">

View file

@ -0,0 +1,43 @@
<script setup>
import { Bell } from '@lucide/vue';
import { Button } from '@/components/ui/button';
import { Input } from '@/components/ui/input';
import Panel from '@/components/Panel.vue';
import AppLayout from '@/layouts/AppLayout.vue';
import PageContent from '@/pagebuilder/PageContent.vue';
/**
* Beispielseite für die Vorschau im „Erscheinungsbild“.
*/
defineProps({
content: { type: Object, required: true },
});
</script>
<template>
<AppLayout title="Beispielseite">
<div class="grid gap-8 lg:grid-cols-[minmax(0,1fr)_320px]">
<article class="min-w-0">
<p class="text-[11px] font-semibold tracking-wide text-accent2-text uppercase">Kategorie</p>
<h1 class="mt-1 mb-8 text-3xl font-semibold tracking-tight">Beispielseite</h1>
<PageContent :content="content" />
</article>
<aside class="grid content-start gap-6">
<Panel title="Bedienelemente" action-label="Alle anzeigen" action-href="#">
<div class="grid gap-3">
<Input placeholder="Eingabefeld" />
<div class="flex flex-wrap gap-2">
<Button>Primär</Button>
<Button variant="outline">Umrandet</Button>
<Button variant="ghost"><Bell /> Symbol</Button>
</div>
</div>
</Panel>
<section class="rounded-lg bg-brand p-5 text-brand-foreground">
<p class="font-semibold">Fläche in der Markenfarbe</p>
<p class="mt-1 text-sm opacity-85">Zum Beispiel die Begrüßungskarte auf der Startseite.</p>
</section>
</aside>
</div>
</AppLayout>
</template>

View file

@ -9,11 +9,13 @@ import { Label } from '@/components/ui/label';
import FormField from '@/components/FormField.vue';
import GuestLayout from '@/layouts/GuestLayout.vue';
defineProps({
const props = defineProps({
canResetPassword: { type: Boolean, default: false },
status: { type: String, default: null },
providers: { type: Array, default: () => [] },
identityError: { type: String, default: null },
// Vorschau im Admin („Erscheinungsbild“): nur ansehen, nicht anmelden.
preview: { type: Boolean, default: false },
});
const showPassword = ref(false);
@ -25,6 +27,8 @@ const form = useForm({
});
function submit() {
if (props.preview) return;
form.post('/login', {
onFinish: () => form.reset('password'),
});
@ -56,9 +60,10 @@ function submit() {
</svg>
{{ provider.label }}
</a>
<div class="relative my-2 text-center text-xs text-muted-foreground">
<span class="absolute inset-x-0 top-1/2 border-t" />
<span class="relative bg-background px-3">oder mit E-Mail und Passwort</span>
<div class="my-2 flex items-center gap-3 text-xs text-muted-foreground">
<span class="h-px flex-1 bg-border" />
oder mit E-Mail und Passwort
<span class="h-px flex-1 bg-border" />
</div>
</div>