Mache die Premium-Karten mit vorhandenen Fachobjekten nutzbar.
- Themenkarte: alle Säulen wählbar; nicht veröffentlichte nur in der Redaktionsvorschau. - Medienkarte: Kurzbeschreibung, Film (Filmtafel, Hinweis auf den geschützten Film) und Material (Materialsymbol) getrennt; Filmstandbild der Bibliothek nur in der Redaktionsvorschau, markiert; Entwürfe wählbar, gesperrte nicht; Traineranleitungen nie öffentlich. - Programm-/Modulkarte: Lernziel als Text, Dauer und Modulzahl; Programme/Module ohne Anzeigefreigabe für die Vorschau wählbar; Module weiterhin ohne Link. - Fehlende Inhalte nur in der Vorschau als eingeklappte Redaktionshinweise. - Tests bewusst angepasst: Medien zeigen jetzt die Kurzbeschreibung (Betreibervorgabe), unveröffentlichte Themen und Programme ohne Freigabe sind wählbar. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
bc1f84ac89
commit
a08067c078
13 files changed
+611
-151
No files matched your search
@@ -228,6 +228,76 @@ .lf-pc__panel-accent {
|
||||
color: var(--pc-accent);
|
||||
}
|
||||
|
||||
/* Film ohne freigegebenes Bild: Filmtafel (Navy, Filmstreifen-Symbol, kein Abspielsymbol – die Karte spielt nichts ab). */
|
||||
.lf-pc__panel-icon {
|
||||
display: block;
|
||||
inline-size: 44px;
|
||||
block-size: 44px;
|
||||
color: var(--pc-accent);
|
||||
}
|
||||
|
||||
/* Material (Dokument, Text, Hörstück …): ruhige Cremefläche mit Materialsymbol statt Foto. */
|
||||
.lf-pc__panel--material {
|
||||
background: var(--pc-subtle);
|
||||
color: var(--lf-navy);
|
||||
border: 1px solid var(--color-border);
|
||||
}
|
||||
|
||||
.lf-pc__panel--material .lf-pc__panel-icon { color: var(--lf-navy); }
|
||||
|
||||
.lf-pc--material .lf-pc__meta {
|
||||
padding-block: 10px;
|
||||
inline-size: 100%;
|
||||
border-block: 1px solid var(--color-border);
|
||||
}
|
||||
|
||||
/* Nur Redaktionsvorschau: Vorschaubild der Bibliothek ist markiert, weil es öffentlich nicht erscheint. */
|
||||
.lf-pc__library-flag {
|
||||
position: absolute;
|
||||
inset: auto 12px 12px auto;
|
||||
max-inline-size: calc(100% - 24px);
|
||||
padding: 4px 10px;
|
||||
border-radius: var(--radius-pill);
|
||||
color: var(--lf-white);
|
||||
background: rgb(3 37 81 / 86%);
|
||||
font-size: 0.75rem;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.lf-pc__editorial {
|
||||
inline-size: 100%;
|
||||
margin: 0;
|
||||
font-size: 0.8125rem;
|
||||
}
|
||||
|
||||
.lf-pc__editorial summary {
|
||||
cursor: pointer;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.lf-pc__editorial[open] summary {
|
||||
margin-block-end: 0.4rem;
|
||||
}
|
||||
|
||||
.lf-pc__private-flag {
|
||||
margin: 0;
|
||||
padding: 3px 10px;
|
||||
border-radius: var(--radius-pill);
|
||||
background: var(--color-warning-surface, var(--lf-yellow-tint));
|
||||
color: var(--lf-navy);
|
||||
font-size: 0.75rem;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.lf-pc__editorial p,
|
||||
.lf-pc__editorial ul {
|
||||
margin: 0 0 0.35rem;
|
||||
}
|
||||
|
||||
.lf-pc__editorial ul {
|
||||
padding-inline-start: 1.1rem;
|
||||
}
|
||||
|
||||
.lf-pc--catalog .lf-pc__kind { color: var(--color-heading); }
|
||||
.lf-pc--catalog .lf-pc__cta { background: var(--lf-navy); color: var(--lf-white); }
|
||||
.lf-pc--catalog .lf-pc__cta:visited { color: var(--lf-white); }
|
||||
@@ -249,9 +319,11 @@ @container slot (min-width: 520px) {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
/* Neben dem Text wie ein Bild mittig, auch wenn die Karte auf Zeilenhöhe gestreckt ist. */
|
||||
.lf-pc:not(.lf-pc--stacked) .lf-pc__panel {
|
||||
margin: 10px 0 10px 10px;
|
||||
min-block-size: 220px;
|
||||
align-self: center;
|
||||
}
|
||||
|
||||
.lf-pc--contain:not(.lf-pc--stacked) .lf-pc__visual {
|
||||
|
||||
@@ -1,18 +1,32 @@
|
||||
{{--
|
||||
Premium-Karte (Brand-UI-Kit v1.7, Entwurf zur visuellen Freigabe) für Themen-, Medien- und Programmkarten.
|
||||
Premium-Karte (Brand-UI-Kit v1.7, Entwurf zur visuellen Freigabe) für Themen-, Medien-, Material- und Programmkarten.
|
||||
Alle Texte und das Linkziel kommen aus $subject (Fachdaten zur Laufzeit, PublicCatalogReader/PublicMaterialReader);
|
||||
redaktionell sind nur Bild, Alternativtext, Bildausschnitt, Beschriftung der Aktion und Hinweis.
|
||||
Eine Karte, ein expliziter Link, kein über die ganze Karte gestreckter Link. Breitenabhängig über @container slot.
|
||||
redaktionell sind nur Kartenbild, Alternativtext, Bildausschnitt, Beschriftung der Aktion und Hinweis.
|
||||
|
||||
Bildbereich, in dieser Reihenfolge:
|
||||
1. Kartenbild aus dem öffentlichen Website-Bereich (Reiter „Medien“) – öffentlich und in der Vorschau.
|
||||
2. Nur Redaktionsvorschau: Vorschaubild der Bibliothek (Filmstandbild, Modulvorschau), deutlich als nicht
|
||||
öffentlich markiert. Es hat keine Freigabe für die Website und wird öffentlich nie ausgegeben.
|
||||
3. Tafel nach Fachobjekt: Programm/Modul (Navy), Film (Filmtafel), Material (Materialsymbol); Thema ohne Bildbereich.
|
||||
Hinweise auf fehlende Inhalte stehen nur in der Redaktionsvorschau, öffentlich nie.
|
||||
--}}
|
||||
@if ($subject === null)
|
||||
@if ($context->preview)
|
||||
<p class="preview-note">Kein Objekt verknüpft, oder das verknüpfte Objekt ist nicht mehr veröffentlicht beziehungsweise freigegeben. Öffentlich erscheint diese Karte nicht.</p>
|
||||
<p class="preview-note">Kein Objekt verknüpft, oder das verknüpfte Objekt ist archiviert beziehungsweise gesperrt. Öffentlich erscheint diese Karte nicht.</p>
|
||||
@endif
|
||||
@elseif ($subject->public || $context->preview)
|
||||
@php
|
||||
$hasPanel = $cardStyle === 'catalog' && $imageUrl === null;
|
||||
$libraryImage = $imageUrl === null && $context->preview ? $subject->previewImage : null;
|
||||
$panel = $imageUrl === null && $libraryImage === null ? $subject->visual : null;
|
||||
$action = $show['action'] && $subject->url !== null ? ['url' => $subject->url, 'label' => $actionLabel] : null;
|
||||
$meta = $show['meta'] ? $subject->meta : [];
|
||||
$hints = $subject->missing;
|
||||
$panelName = ['catalog' => 'die Navy-Tafel', 'film' => 'die Filmtafel', 'material' => 'das Materialsymbol'][$subject->visual] ?? 'die Karte ohne Bild';
|
||||
if ($context->preview && $imageUrl === null) {
|
||||
$hints[] = $subject->previewImage !== null
|
||||
? 'Das Vorschaubild der Bibliothek ist nicht für die Website freigegeben; öffentlich erscheint stattdessen '.$panelName.'. Ein freigegebenes Motiv kann im Reiter „Medien“ als Kartenbild gewählt werden.'
|
||||
: 'Kein Kartenbild gewählt; öffentlich erscheint '.$panelName.' (Kartenbild im Reiter „Medien“).';
|
||||
}
|
||||
@endphp
|
||||
<article @class([
|
||||
'lf-pc',
|
||||
@@ -20,19 +34,27 @@
|
||||
'lf-pc--'.$format,
|
||||
'lf-pc--'.$fit,
|
||||
'lf-pc--stacked' => $stacked,
|
||||
'lf-pc--without-visual' => $imageUrl === null && ! $hasPanel,
|
||||
'lf-pc--without-visual' => $imageUrl === null && $libraryImage === null && $panel === null,
|
||||
'lf-pc--internal' => ! $subject->public,
|
||||
]) style="--pc-focus-x: {{ $focus['x'] }}%; --pc-focus-y: {{ $focus['y'] }}%">
|
||||
@if ($imageUrl !== null)
|
||||
@if ($imageUrl !== null || $libraryImage !== null)
|
||||
<div class="lf-pc__visual">
|
||||
<img class="lf-pc__image" src="{{ $imageUrl }}" alt="{{ $alt }}" loading="lazy" decoding="async">
|
||||
<img class="lf-pc__image" src="{{ $imageUrl ?? $libraryImage }}" alt="{{ $imageUrl !== null ? $alt : '' }}" loading="lazy" decoding="async">
|
||||
@if ($show['kind'] && $subject->badge !== null)
|
||||
<span class="lf-pc__badge">{{ $subject->badge }}</span>
|
||||
@endif
|
||||
@if ($libraryImage !== null)
|
||||
<span class="lf-pc__library-flag">Bibliotheksbild · nur Vorschau</span>
|
||||
@endif
|
||||
</div>
|
||||
@elseif ($hasPanel)
|
||||
<div class="lf-pc__panel" aria-hidden="true">
|
||||
<span class="lf-pc__panel-label">{{ $subject->kind }}</span>
|
||||
@elseif ($panel !== null)
|
||||
<div class="lf-pc__panel lf-pc__panel--{{ $panel }}" aria-hidden="true">
|
||||
@if ($panel === 'film')
|
||||
<svg class="lf-pc__panel-icon" viewBox="0 0 48 48" focusable="false"><rect x="6" y="10" width="36" height="28" rx="4" fill="none" stroke="currentColor" stroke-width="3"/><path d="M6 17h36M6 31h36M14 10v7M22 10v7M30 10v7M38 10v7M14 31v7M22 31v7M30 31v7M38 31v7" stroke="currentColor" stroke-width="2.5"/></svg>
|
||||
@elseif ($panel === 'material')
|
||||
<svg class="lf-pc__panel-icon" viewBox="0 0 48 48" focusable="false"><path d="M12 5h17l9 9v29H12z" fill="none" stroke="currentColor" stroke-width="3" stroke-linejoin="round"/><path d="M29 5v9h9M18 24h14M18 30h14M18 36h9" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round"/></svg>
|
||||
@endif
|
||||
<span class="lf-pc__panel-label">{{ $subject->visualLabel ?? $subject->kind }}</span>
|
||||
<x-brand.underline class="lf-pc__panel-accent" />
|
||||
</div>
|
||||
@endif
|
||||
@@ -61,8 +83,24 @@
|
||||
@endif
|
||||
</div>
|
||||
@endif
|
||||
@if (! $subject->public && $subject->notice !== null)
|
||||
<p class="preview-note">{{ $subject->notice }}</p>
|
||||
@if ($context->preview && (! $subject->public || $hints !== []))
|
||||
@unless ($subject->public)
|
||||
<p class="lf-pc__private-flag">Nur Redaktionsvorschau</p>
|
||||
@endunless
|
||||
<details class="preview-note lf-pc__editorial">
|
||||
<summary>Hinweise für die Redaktion ({{ count($hints) + ($subject->public ? 0 : 1) }})</summary>
|
||||
@if (! $subject->public && $subject->notice !== null)
|
||||
<p>{{ $subject->notice }}</p>
|
||||
@endif
|
||||
@if ($hints !== [])
|
||||
<p>Für eine vollständige Karte fehlt:</p>
|
||||
<ul>
|
||||
@foreach ($hints as $hint)
|
||||
<li>{{ $hint }}</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
@endif
|
||||
</details>
|
||||
@endif
|
||||
</div>
|
||||
</article>
|
||||
|
||||
Reference in new issue
Block a user