P0: x-cloak aktiv + Emojis durch Inline-SVG-Icons ersetzt

- base.html: [x-cloak]-CSS gegen Alpine-Flackern
- Neues zentrales Icon-Makro-Template (icons.html, Heroicons-Stil,
  currentColor, aria-hidden)
- Logo-Würfelbecher, Sync-Pfeile, Sortier-Chevrons, Warn-/Check-Icons,
  dedup-Karten (Gebäude/Tag/Buch/Dokument), Cover-Platzhalter als SVG
- Cover-Platzhalter: 'Kein Cover'-Text in Großansicht, Mindestgröße
  48x68 px in der Kartenansicht
This commit is contained in:
Flo Hartmann
2026-08-26 08:33:37 +00:00
parent 929cea1887
commit e1ef7ba926
13 changed files with 181 additions and 49 deletions

View File

@@ -1,24 +1,31 @@
{# Coverbild-Vorschau des Archiv-Plugins. {# Coverbild-Vorschau.
Erwartete Variablen: cover_bild (URL oder None), cover_titel, Erwartete Variablen: cover_bild (URL oder None), cover_titel,
cover_gross (optional: true für großformatige Ansichten). cover_gross (optional: true für großformatige Ansichten).
Bilder werden direkt von der Quelle eingebettet (Hotlinking, kein Bilder werden direkt von der Quelle eingebettet (Hotlinking, kein
Download) — mit loading="lazy" und decoding="async". Ohne Bild zeigt Download) — mit loading="lazy" und decoding="async". Ohne Bild zeigt
das Partial einen dezenten Platzhalter mit Spielicon-Zeichen. #} das Partial einen dezenten Platzhalter mit SVG-Würfel (in der großen
Ansicht zusätzlich mit dem Hinweis „Kein Cover"). #}
{% from "icons.html" import icon_wuerfel %}
{% set _gross = cover_gross | default(false) %} {% set _gross = cover_gross | default(false) %}
{% if _gross %} {% if _gross %}
{% if cover_bild %} {% if cover_bild %}
<img src="{{ cover_bild }}" alt="Cover: {{ cover_titel }}" loading="lazy" decoding="async" <img src="{{ cover_bild }}" alt="Cover: {{ cover_titel }}" loading="lazy" decoding="async"
class="block h-auto w-auto max-w-[200px] max-h-[280px] rounded-lg border border-slate-200 bg-white shadow-sm"> class="block h-auto w-auto max-w-[200px] max-h-[280px] rounded-lg border border-slate-200 bg-white shadow-sm">
{% else %} {% else %}
<div aria-hidden="true" title="Kein Cover vorhanden" <div role="img" aria-label="Kein Cover vorhanden" title="Kein Cover vorhanden"
class="flex h-[210px] w-[150px] max-w-[200px] items-center justify-center rounded-lg border-2 border-dashed border-slate-300 bg-slate-50 text-6xl text-slate-300 select-none">&#127922;</div> class="flex h-[210px] w-[150px] max-w-[200px] flex-col items-center justify-center gap-2 rounded-lg border-2 border-dashed border-slate-300 bg-slate-50 text-slate-300 select-none">
{{ icon_wuerfel("h-12 w-12") }}
<span class="text-xs font-medium text-slate-400">Kein Cover</span>
</div>
{% endif %} {% endif %}
{% else %} {% else %}
{% if cover_bild %} {% if cover_bild %}
<img src="{{ cover_bild }}" alt="Cover: {{ cover_titel }}" loading="lazy" decoding="async" width="40" height="56" <img src="{{ cover_bild }}" alt="Cover: {{ cover_titel }}" loading="lazy" decoding="async" width="48" height="68"
class="block h-14 w-10 shrink-0 rounded border border-slate-200 bg-slate-50 object-cover"> class="block h-[68px] w-12 shrink-0 rounded border border-slate-200 bg-slate-50 object-cover">
{% else %} {% else %}
<div aria-hidden="true" title="Kein Cover vorhanden" <div role="img" aria-label="Kein Cover vorhanden" title="Kein Cover vorhanden"
class="flex h-14 w-10 shrink-0 items-center justify-center rounded border border-dashed border-slate-300 bg-slate-50 text-lg text-slate-400 select-none">&#127922;</div> class="flex h-[68px] w-12 shrink-0 items-center justify-center rounded border border-dashed border-slate-300 bg-slate-50 text-slate-400 select-none">
{{ icon_wuerfel("h-5 w-5") }}
</div>
{% endif %} {% endif %}
{% endif %} {% endif %}

View File

@@ -92,7 +92,7 @@
<button type="submit" <button type="submit"
class="w-full min-h-[44px] inline-flex items-center justify-center gap-1 bg-emerald-600 hover:bg-emerald-700 active:bg-emerald-800 text-white px-3 py-2 rounded-lg text-sm whitespace-nowrap" class="w-full min-h-[44px] inline-flex items-center justify-center gap-1 bg-emerald-600 hover:bg-emerald-700 active:bg-emerald-800 text-white px-3 py-2 rounded-lg text-sm whitespace-nowrap"
title="Eintrag unverändert zurück in die aktive Liste verschieben"> title="Eintrag unverändert zurück in die aktive Liste verschieben">
&#8635; Wiederherstellen {% from "icons.html" import icon_sync %}{{ icon_sync("h-4 w-4") }} Wiederherstellen
</button> </button>
</form> </form>
</div> </div>
@@ -157,9 +157,9 @@
<td class="px-4 py-3"> <td class="px-4 py-3">
<form method="post" action="/archiv/{{ eintrag.quelle }}/{{ eintrag.id }}/wiederherstellen"> <form method="post" action="/archiv/{{ eintrag.quelle }}/{{ eintrag.id }}/wiederherstellen">
<button type="submit" <button type="submit"
class="text-xs bg-emerald-600 hover:bg-emerald-700 active:bg-emerald-800 text-white px-2.5 py-2 rounded-lg whitespace-nowrap" class="inline-flex items-center gap-1 text-xs bg-emerald-600 hover:bg-emerald-700 active:bg-emerald-800 text-white px-2.5 py-2 rounded-lg whitespace-nowrap"
title="Eintrag unverändert zurück in die aktive Liste verschieben"> title="Eintrag unverändert zurück in die aktive Liste verschieben">
&#8635; Wiederherstellen {% from "icons.html" import icon_sync %}{{ icon_sync("h-4 w-4") }} Wiederherstellen
</button> </button>
</form> </form>
</td> </td>

View File

@@ -9,19 +9,19 @@
<div class="grid md:grid-cols-4 gap-3 mb-6 text-sm"> <div class="grid md:grid-cols-4 gap-3 mb-6 text-sm">
<div class="bg-white border border-slate-200 rounded-xl p-3"> <div class="bg-white border border-slate-200 rounded-xl p-3">
<p class="font-medium text-slate-700 mb-1">&#127962; Verlags-Konflikt</p> <p class="font-medium text-slate-700 mb-1 flex items-center gap-1.5">{% from "icons.html" import icon_gebaeude %}{{ icon_gebaeude("h-4 w-4") }} Verlags-Konflikt</p>
<p class="text-slate-500">Gleiches Spiel bei verschiedenen Verlagen/Vertrieb &rarr; Verlagsauswahl.</p> <p class="text-slate-500">Gleiches Spiel bei verschiedenen Verlagen/Vertrieb &rarr; Verlagsauswahl.</p>
</div> </div>
<div class="bg-white border border-slate-200 rounded-xl p-3"> <div class="bg-white border border-slate-200 rounded-xl p-3">
<p class="font-medium text-slate-700 mb-1">&#127463; Titel-Varianten</p> <p class="font-medium text-slate-700 mb-1 flex items-center gap-1.5">{% from "icons.html" import icon_tag %}{{ icon_tag("h-4 w-4") }} Titel-Varianten</p>
<p class="text-slate-500">Deutsche Version wird bevorzugt (Heuristik + BGG Alternate-Names).</p> <p class="text-slate-500">Deutsche Version wird bevorzugt (Heuristik + BGG Alternate-Names).</p>
</div> </div>
<div class="bg-white border border-slate-200 rounded-xl p-3"> <div class="bg-white border border-slate-200 rounded-xl p-3">
<p class="font-medium text-slate-700 mb-1">&#128214; Bereits besprochen</p> <p class="font-medium text-slate-700 mb-1 flex items-center gap-1.5">{% from "icons.html" import icon_buch %}{{ icon_buch("h-4 w-4") }} Bereits besprochen</p>
<p class="text-slate-500">Spiel oder Vorg&auml;nger (BGG-Erweiterungs-Relation + Fuzzy-Match) schon in der Redaktion.</p> <p class="text-slate-500">Spiel oder Vorg&auml;nger (BGG-Erweiterungs-Relation + Fuzzy-Match) schon in der Redaktion.</p>
</div> </div>
<div class="bg-white border border-slate-200 rounded-xl p-3"> <div class="bg-white border border-slate-200 rounded-xl p-3">
<p class="font-medium text-slate-700 mb-1">&#128203; Schon in Planung</p> <p class="font-medium text-slate-700 mb-1 flex items-center gap-1.5">{% from "icons.html" import icon_dokument %}{{ icon_dokument("h-4 w-4") }} Schon in Planung</p>
<p class="text-slate-500">Titel steht bereits in der Planungsliste eines anderen Rezensenten.</p> <p class="text-slate-500">Titel steht bereits in der Planungsliste eines anderen Rezensenten.</p>
</div> </div>
</div> </div>
@@ -60,8 +60,8 @@
{% if ergebnis %} {% if ergebnis %}
<div class="mt-4 rounded-lg border p-4 text-sm <div class="mt-4 rounded-lg border p-4 text-sm
{% if ergebnis.hat_konflikte %}bg-amber-50 border-amber-300{% else %}bg-emerald-50 border-emerald-200{% endif %}"> {% if ergebnis.hat_konflikte %}bg-amber-50 border-amber-300{% else %}bg-emerald-50 border-emerald-200{% endif %}">
<p class="font-medium mb-2 {% if ergebnis.hat_konflikte %}text-amber-800{% else %}text-emerald-800{% endif %}"> <p class="font-medium mb-2 flex items-center gap-1.5 {% if ergebnis.hat_konflikte %}text-amber-800{% else %}text-emerald-800{% endif %}">
{% if ergebnis.hat_konflikte %}&#9888; {{ ergebnis.konflikte|length }} Treffer f&uuml;r „{{ ergebnis.titel }}“{% else %}&#10003; Keine Treffer f&uuml;r „{{ ergebnis.titel }}“{% endif %} {% if ergebnis.hat_konflikte %}{% from "icons.html" import icon_warnung %}{{ icon_warnung("h-4 w-4") }} {{ ergebnis.konflikte|length }} Treffer f&uuml;r „{{ ergebnis.titel }}“{% else %}{% from "icons.html" import icon_check %}{{ icon_check("h-4 w-4") }} Keine Treffer f&uuml;r „{{ ergebnis.titel }}“{% endif %}
</p> </p>
<ul class="list-disc list-inside space-y-1 text-slate-700"> <ul class="list-disc list-inside space-y-1 text-slate-700">
{% for konflikt in ergebnis.konflikte %} {% for konflikt in ergebnis.konflikte %}

View File

@@ -1,24 +1,31 @@
{# Coverbild-Vorschau des Neuheiten-Plugins. {# Coverbild-Vorschau.
Erwartete Variablen: cover_bild (URL oder None), cover_titel, Erwartete Variablen: cover_bild (URL oder None), cover_titel,
cover_gross (optional: true für großformatige Ansichten). cover_gross (optional: true für großformatige Ansichten).
Bilder werden direkt von der Quelle eingebettet (Hotlinking, kein Bilder werden direkt von der Quelle eingebettet (Hotlinking, kein
Download) — mit loading="lazy" und decoding="async". Ohne Bild zeigt Download) — mit loading="lazy" und decoding="async". Ohne Bild zeigt
das Partial einen dezenten Platzhalter mit Spielicon-Zeichen. #} das Partial einen dezenten Platzhalter mit SVG-Würfel (in der großen
Ansicht zusätzlich mit dem Hinweis „Kein Cover"). #}
{% from "icons.html" import icon_wuerfel %}
{% set _gross = cover_gross | default(false) %} {% set _gross = cover_gross | default(false) %}
{% if _gross %} {% if _gross %}
{% if cover_bild %} {% if cover_bild %}
<img src="{{ cover_bild }}" alt="Cover: {{ cover_titel }}" loading="lazy" decoding="async" <img src="{{ cover_bild }}" alt="Cover: {{ cover_titel }}" loading="lazy" decoding="async"
class="block h-auto w-auto max-w-[200px] max-h-[280px] rounded-lg border border-slate-200 bg-white shadow-sm"> class="block h-auto w-auto max-w-[200px] max-h-[280px] rounded-lg border border-slate-200 bg-white shadow-sm">
{% else %} {% else %}
<div aria-hidden="true" title="Kein Cover vorhanden" <div role="img" aria-label="Kein Cover vorhanden" title="Kein Cover vorhanden"
class="flex h-[210px] w-[150px] max-w-[200px] items-center justify-center rounded-lg border-2 border-dashed border-slate-300 bg-slate-50 text-6xl text-slate-300 select-none">&#127922;</div> class="flex h-[210px] w-[150px] max-w-[200px] flex-col items-center justify-center gap-2 rounded-lg border-2 border-dashed border-slate-300 bg-slate-50 text-slate-300 select-none">
{{ icon_wuerfel("h-12 w-12") }}
<span class="text-xs font-medium text-slate-400">Kein Cover</span>
</div>
{% endif %} {% endif %}
{% else %} {% else %}
{% if cover_bild %} {% if cover_bild %}
<img src="{{ cover_bild }}" alt="Cover: {{ cover_titel }}" loading="lazy" decoding="async" width="40" height="56" <img src="{{ cover_bild }}" alt="Cover: {{ cover_titel }}" loading="lazy" decoding="async" width="48" height="68"
class="block h-14 w-10 shrink-0 rounded border border-slate-200 bg-slate-50 object-cover"> class="block h-[68px] w-12 shrink-0 rounded border border-slate-200 bg-slate-50 object-cover">
{% else %} {% else %}
<div aria-hidden="true" title="Kein Cover vorhanden" <div role="img" aria-label="Kein Cover vorhanden" title="Kein Cover vorhanden"
class="flex h-14 w-10 shrink-0 items-center justify-center rounded border border-dashed border-slate-300 bg-slate-50 text-lg text-slate-400 select-none">&#127922;</div> class="flex h-[68px] w-12 shrink-0 items-center justify-center rounded border border-dashed border-slate-300 bg-slate-50 text-slate-400 select-none">
{{ icon_wuerfel("h-5 w-5") }}
</div>
{% endif %} {% endif %}
{% endif %} {% endif %}

View File

@@ -37,7 +37,7 @@
{% if eintrag.status == 'neuheit' %} {% if eintrag.status == 'neuheit' %}
<form method="post" action="/planung/uebernehmen/{{ eintrag.id }}" class="mt-2"> <form method="post" action="/planung/uebernehmen/{{ eintrag.id }}" class="mt-2">
<button type="submit" title="In die Planungsliste verschieben (läuft durch die dedup-Prüfung)" <button type="submit" title="In die Planungsliste verschieben (läuft durch die dedup-Prüfung)"
class="w-full min-h-[44px] inline-flex items-center justify-center gap-1 bg-emerald-600 hover:bg-emerald-700 active:bg-emerald-800 text-white px-3 py-2 rounded-lg text-sm whitespace-nowrap">&#8594; Zur Planung</button> class="w-full min-h-[44px] inline-flex items-center justify-center gap-1.5 bg-emerald-600 hover:bg-emerald-700 active:bg-emerald-800 text-white px-3 py-2 rounded-lg text-sm whitespace-nowrap">{% from "icons.html" import icon_pfeil_rechts %}{{ icon_pfeil_rechts("h-4 w-4") }} Zur Planung</button>
</form> </form>
{% endif %} {% endif %}
</div> </div>
@@ -61,7 +61,11 @@
<th class="px-4 py-3 font-medium whitespace-nowrap"> <th class="px-4 py-3 font-medium whitespace-nowrap">
{% if sort == key %} {% if sort == key %}
<a href="{{ basis }}&sort={{ key }}&richtung={{ 'auf' if richtung == 'ab' else 'ab' }}" <a href="{{ basis }}&sort={{ key }}&richtung={{ 'auf' if richtung == 'ab' else 'ab' }}"
class="hover:text-emerald-700">{{ label }} {{ '&#9650;' if richtung == 'auf' else '&#9660;' }}</a> class="inline-flex items-center gap-1 hover:text-emerald-700">{{ label }}
{% from "icons.html" import icon_chevron_oben, icon_chevron_unten %}
{% if richtung == 'auf' %}{{ icon_chevron_oben("h-3 w-3") }}{% else %}{{ icon_chevron_unten("h-3 w-3") }}{% endif %}
<span class="sr-only">(sortiert {{ 'aufsteigend' if richtung == 'auf' else 'absteigend' }})</span>
</a>
{% else %} {% else %}
<a href="{{ basis }}&sort={{ key }}&richtung=auf" class="hover:text-emerald-700 text-slate-400">{{ label }}</a> <a href="{{ basis }}&sort={{ key }}&richtung=auf" class="hover:text-emerald-700 text-slate-400">{{ label }}</a>
{% endif %} {% endif %}
@@ -102,7 +106,7 @@
{% if eintrag.status == 'neuheit' %} {% if eintrag.status == 'neuheit' %}
<form method="post" action="/planung/uebernehmen/{{ eintrag.id }}"> <form method="post" action="/planung/uebernehmen/{{ eintrag.id }}">
<button type="submit" title="In die Planungsliste verschieben (läuft durch die dedup-Prüfung)" <button type="submit" title="In die Planungsliste verschieben (läuft durch die dedup-Prüfung)"
class="text-xs bg-emerald-600 hover:bg-emerald-700 text-white px-2.5 py-2 rounded-lg whitespace-nowrap">&#8594; Zur Planung</button> class="inline-flex items-center gap-1 text-xs bg-emerald-600 hover:bg-emerald-700 text-white px-2.5 py-2 rounded-lg whitespace-nowrap">{% from "icons.html" import icon_pfeil_rechts %}{{ icon_pfeil_rechts("h-3.5 w-3.5") }} Zur Planung</button>
</form> </form>
{% endif %} {% endif %}
</td> </td>

View File

@@ -29,8 +29,8 @@
class="w-full min-h-[44px] border border-slate-300 rounded-lg px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-emerald-500"> class="w-full min-h-[44px] border border-slate-300 rounded-lg px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-emerald-500">
</div> </div>
<button type="submit" <button type="submit"
class="min-h-[44px] inline-flex items-center justify-center bg-emerald-600 hover:bg-emerald-700 active:bg-emerald-800 text-white font-medium px-4 py-2 rounded-lg text-sm whitespace-nowrap"> class="min-h-[44px] inline-flex items-center justify-center gap-1.5 bg-emerald-600 hover:bg-emerald-700 active:bg-emerald-800 text-white font-medium px-4 py-2 rounded-lg text-sm whitespace-nowrap">
&#8635; Jetzt synchronisieren {% from "icons.html" import icon_sync %}{{ icon_sync("h-4 w-4") }} Jetzt synchronisieren
</button> </button>
</form> </form>
{% endif %} {% endif %}
@@ -47,8 +47,8 @@
{% if ist_redaktion %} {% if ist_redaktion %}
<form method="post" action="/neuheiten/quellen-sync"> <form method="post" action="/neuheiten/quellen-sync">
<button type="submit" <button type="submit"
class="min-h-[44px] md:min-h-0 bg-sky-600 hover:bg-sky-700 active:bg-sky-800 text-white font-medium px-3 py-1.5 rounded-lg text-xs whitespace-nowrap"> class="min-h-[44px] md:min-h-0 inline-flex items-center gap-1.5 bg-sky-600 hover:bg-sky-700 active:bg-sky-800 text-white font-medium px-3 py-1.5 rounded-lg text-xs whitespace-nowrap">
&#8635; Web-Quellen synchronisieren {% from "icons.html" import icon_sync %}{{ icon_sync("h-3.5 w-3.5") }} Web-Quellen synchronisieren
</button> </button>
</form> </form>
{% endif %} {% endif %}

View File

@@ -1,24 +1,31 @@
{# Coverbild-Vorschau des Planung-Plugins. {# Coverbild-Vorschau.
Erwartete Variablen: cover_bild (URL oder None), cover_titel, Erwartete Variablen: cover_bild (URL oder None), cover_titel,
cover_gross (optional: true für großformatige Ansichten). cover_gross (optional: true für großformatige Ansichten).
Bilder werden direkt von der Quelle eingebettet (Hotlinking, kein Bilder werden direkt von der Quelle eingebettet (Hotlinking, kein
Download) — mit loading="lazy" und decoding="async". Ohne Bild zeigt Download) — mit loading="lazy" und decoding="async". Ohne Bild zeigt
das Partial einen dezenten Platzhalter mit Spielicon-Zeichen. #} das Partial einen dezenten Platzhalter mit SVG-Würfel (in der großen
Ansicht zusätzlich mit dem Hinweis „Kein Cover"). #}
{% from "icons.html" import icon_wuerfel %}
{% set _gross = cover_gross | default(false) %} {% set _gross = cover_gross | default(false) %}
{% if _gross %} {% if _gross %}
{% if cover_bild %} {% if cover_bild %}
<img src="{{ cover_bild }}" alt="Cover: {{ cover_titel }}" loading="lazy" decoding="async" <img src="{{ cover_bild }}" alt="Cover: {{ cover_titel }}" loading="lazy" decoding="async"
class="block h-auto w-auto max-w-[200px] max-h-[280px] rounded-lg border border-slate-200 bg-white shadow-sm"> class="block h-auto w-auto max-w-[200px] max-h-[280px] rounded-lg border border-slate-200 bg-white shadow-sm">
{% else %} {% else %}
<div aria-hidden="true" title="Kein Cover vorhanden" <div role="img" aria-label="Kein Cover vorhanden" title="Kein Cover vorhanden"
class="flex h-[210px] w-[150px] max-w-[200px] items-center justify-center rounded-lg border-2 border-dashed border-slate-300 bg-slate-50 text-6xl text-slate-300 select-none">&#127922;</div> class="flex h-[210px] w-[150px] max-w-[200px] flex-col items-center justify-center gap-2 rounded-lg border-2 border-dashed border-slate-300 bg-slate-50 text-slate-300 select-none">
{{ icon_wuerfel("h-12 w-12") }}
<span class="text-xs font-medium text-slate-400">Kein Cover</span>
</div>
{% endif %} {% endif %}
{% else %} {% else %}
{% if cover_bild %} {% if cover_bild %}
<img src="{{ cover_bild }}" alt="Cover: {{ cover_titel }}" loading="lazy" decoding="async" width="40" height="56" <img src="{{ cover_bild }}" alt="Cover: {{ cover_titel }}" loading="lazy" decoding="async" width="48" height="68"
class="block h-14 w-10 shrink-0 rounded border border-slate-200 bg-slate-50 object-cover"> class="block h-[68px] w-12 shrink-0 rounded border border-slate-200 bg-slate-50 object-cover">
{% else %} {% else %}
<div aria-hidden="true" title="Kein Cover vorhanden" <div role="img" aria-label="Kein Cover vorhanden" title="Kein Cover vorhanden"
class="flex h-14 w-10 shrink-0 items-center justify-center rounded border border-dashed border-slate-300 bg-slate-50 text-lg text-slate-400 select-none">&#127922;</div> class="flex h-[68px] w-12 shrink-0 items-center justify-center rounded border border-dashed border-slate-300 bg-slate-50 text-slate-400 select-none">
{{ icon_wuerfel("h-5 w-5") }}
</div>
{% endif %} {% endif %}
{% endif %} {% endif %}

View File

@@ -82,8 +82,8 @@
class="ml-0.5 text-[10px] uppercase tracking-wide text-sky-600/70 hover:text-sky-800 align-super">{{ eintrag.quelle }}&nbsp;</a> class="ml-0.5 text-[10px] uppercase tracking-wide text-sky-600/70 hover:text-sky-800 align-super">{{ eintrag.quelle }}&nbsp;</a>
{% endif %} {% endif %}
{% if eintrag.pruefung %} {% if eintrag.pruefung %}
<span class="ml-0.5 inline-block px-2 py-0.5 rounded-full bg-amber-100 text-amber-800 text-xs align-middle" <span class="ml-0.5 inline-flex items-center gap-1 px-2 py-0.5 rounded-full bg-amber-100 text-amber-800 text-xs align-middle"
title="Die dedup-Prüfung hatte beim Eintragen Treffer.">&#9888; Pr&uuml;fhinweis</span> title="Die dedup-Prüfung hatte beim Eintragen Treffer.">{% from "icons.html" import icon_warnung %}{{ icon_warnung("h-3.5 w-3.5") }} Pr&uuml;fhinweis</span>
{% endif %} {% endif %}
</h3> </h3>
{% if eintrag.status == 'offen' %} {% if eintrag.status == 'offen' %}
@@ -169,8 +169,8 @@
class="ml-1 text-[10px] uppercase tracking-wide text-sky-600/70 hover:text-sky-800 align-super">{{ eintrag.quelle }}&nbsp;</a> class="ml-1 text-[10px] uppercase tracking-wide text-sky-600/70 hover:text-sky-800 align-super">{{ eintrag.quelle }}&nbsp;</a>
{% endif %} {% endif %}
{% if eintrag.pruefung %} {% if eintrag.pruefung %}
<span class="ml-1 inline-block px-2 py-0.5 rounded-full bg-amber-100 text-amber-800 text-xs" <span class="ml-1 inline-flex items-center gap-1 px-2 py-0.5 rounded-full bg-amber-100 text-amber-800 text-xs"
title="Die dedup-Prüfung hatte beim Eintragen Treffer.">&#9888; Pr&uuml;fhinweis</span> title="Die dedup-Prüfung hatte beim Eintragen Treffer.">{% from "icons.html" import icon_warnung %}{{ icon_warnung("h-3.5 w-3.5") }} Pr&uuml;fhinweis</span>
{% endif %} {% endif %}
</td> </td>
<td class="px-4 py-3">{{ eintrag.verlag or '—' }}</td> <td class="px-4 py-3">{{ eintrag.verlag or '—' }}</td>

View File

@@ -15,7 +15,7 @@
{% include "planung/_cover.html" %} {% include "planung/_cover.html" %}
</div> </div>
<div class="bg-amber-50 border border-amber-300 rounded-xl p-4 mb-0 sm:mb-6 text-sm w-full"> <div class="bg-amber-50 border border-amber-300 rounded-xl p-4 mb-0 sm:mb-6 text-sm w-full">
<p class="font-medium text-amber-800 mb-2">&#9888; {{ konflikte|length }} Treffer f&uuml;r „{{ spiel_titel }}“</p> <p class="font-medium text-amber-800 mb-2 flex items-center gap-1.5">{% from "icons.html" import icon_warnung %}{{ icon_warnung("h-4 w-4") }} {{ konflikte|length }} Treffer f&uuml;r „{{ spiel_titel }}“</p>
<ul class="list-disc list-inside space-y-1 text-slate-700"> <ul class="list-disc list-inside space-y-1 text-slate-700">
{% for konflikt in konflikte %} {% for konflikt in konflikte %}
<li> <li>

View File

@@ -7,11 +7,14 @@
<script src="https://cdn.tailwindcss.com"></script> <script src="https://cdn.tailwindcss.com"></script>
<script src="https://unpkg.com/htmx.org@2.0.4"></script> <script src="https://unpkg.com/htmx.org@2.0.4"></script>
<script defer src="https://cdn.jsdelivr.net/npm/alpinejs@3.14.9/dist/cdn.min.js"></script> <script defer src="https://cdn.jsdelivr.net/npm/alpinejs@3.14.9/dist/cdn.min.js"></script>
<style>[x-cloak] { display: none !important; }</style>
</head> </head>
<body class="bg-slate-100 text-slate-800 min-h-screen flex flex-col"> <body class="bg-slate-100 text-slate-800 min-h-screen flex flex-col">
<header class="bg-white border-b border-slate-200" x-data="{ menue: false }"> <header class="bg-white border-b border-slate-200" x-data="{ menue: false }">
<nav class="max-w-6xl mx-auto px-4 py-2 md:py-3 flex items-center gap-5" aria-label="Hauptnavigation"> <nav class="max-w-6xl mx-auto px-4 py-2 md:py-3 flex items-center gap-5" aria-label="Hauptnavigation">
<a href="/" class="font-bold text-emerald-700 whitespace-nowrap">&#127923; {{ app_name }}</a> <a href="/" class="font-bold text-emerald-700 whitespace-nowrap inline-flex items-center gap-1.5">
{% from "icons.html" import icon_wuerfelbecher %}{{ icon_wuerfelbecher("h-5 w-5") }} {{ app_name }}
</a>
<!-- Desktop: horizontale Navigationsleiste --> <!-- Desktop: horizontale Navigationsleiste -->
<span class="hidden md:flex items-center gap-5 flex-1"> <span class="hidden md:flex items-center gap-5 flex-1">
{% for eintrag in plugin_nav %} {% for eintrag in plugin_nav %}
@@ -35,7 +38,8 @@
{% if user %} {% if user %}
<button type="button" @click="offen = !offen" <button type="button" @click="offen = !offen"
class="text-sm font-medium px-2 py-1 rounded hover:bg-slate-100 inline-flex items-center min-h-[44px] md:min-h-0"> class="text-sm font-medium px-2 py-1 rounded hover:bg-slate-100 inline-flex items-center min-h-[44px] md:min-h-0">
{{ user.display_name }} &#9662; {{ user.display_name }}
{% from "icons.html" import icon_chevron_unten %}{{ icon_chevron_unten("h-3.5 w-3.5") }}
</button> </button>
<div x-show="offen" x-cloak @click.outside="offen = false" <div x-show="offen" x-cloak @click.outside="offen = false"
class="absolute right-0 mt-2 w-56 bg-white border border-slate-200 rounded-lg shadow-lg p-3 text-sm z-10"> class="absolute right-0 mt-2 w-56 bg-white border border-slate-200 rounded-lg shadow-lg p-3 text-sm z-10">

View File

@@ -0,0 +1,101 @@
{# Zentrale Inline-SVG-Icons (Heroicons-Stil, Outline).
Alle Icons sind dekorativ: aria-hidden + focusable=false, Farbe über
currentColor. Aufruf: {% from "icons.html" import icon_refresh %}
{{ icon_refresh("h-4 w-4") }} #}
{% macro _svg(klasse, pfad) -%}
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"
stroke-width="1.8" stroke="currentColor" class="{{ klasse }}"
aria-hidden="true" focusable="false">
<path stroke-linecap="round" stroke-linejoin="round" d="{{ pfad }}"/>
</svg>
{%- endmacro %}
{% macro icon_wuerfelbecher(klasse="h-5 w-5") -%}
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"
stroke-width="1.8" stroke="currentColor" class="{{ klasse }}"
aria-hidden="true" focusable="false">
<path stroke-linecap="round" stroke-linejoin="round"
d="M6.5 3.5h11l-1.6 13.2a2.4 2.4 0 0 1-2.4 2.2h-3a2.4 2.4 0 0 1-2.4-2.2L6.5 3.5z"/>
<path stroke-linecap="round" stroke-linejoin="round" d="M6 7.5h12"/>
<circle cx="10.2" cy="12" r="0.4" fill="currentColor"/>
<circle cx="13.8" cy="12" r="0.4" fill="currentColor"/>
<circle cx="12" cy="14.8" r="0.4" fill="currentColor"/>
</svg>
{%- endmacro %}
{% macro icon_wuerfel(klasse="h-6 w-6") -%}
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"
stroke-width="1.8" stroke="currentColor" class="{{ klasse }}"
aria-hidden="true" focusable="false">
<rect x="3.5" y="3.5" width="17" height="17" rx="3.5"/>
<circle cx="8.4" cy="8.4" r="0.5" fill="currentColor"/>
<circle cx="15.6" cy="8.4" r="0.5" fill="currentColor"/>
<circle cx="12" cy="12" r="0.5" fill="currentColor"/>
<circle cx="8.4" cy="15.6" r="0.5" fill="currentColor"/>
<circle cx="15.6" cy="15.6" r="0.5" fill="currentColor"/>
</svg>
{%- endmacro %}
{% macro icon_sync(klasse="h-4 w-4") -%}
{{ _svg(klasse, "M16.023 9.348h4.992v-.001M2.985 19.644v-4.992m0 0h4.992m-4.993 0l3.181 3.183a8.25 8.25 0 0013.803-3.7M4.031 9.865a8.25 8.25 0 0113.803-3.7l3.181 3.182m0-4.991v4.99") }}
{%- endmacro %}
{% macro icon_pfeil_rechts(klasse="h-4 w-4") -%}
{{ _svg(klasse, "M13.5 4.5L21 12m0 0l-7.5 7.5M21 12H3") }}
{%- endmacro %}
{% macro icon_warnung(klasse="h-4 w-4") -%}
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"
stroke-width="1.8" stroke="currentColor" class="{{ klasse }}"
aria-hidden="true" focusable="false">
<path stroke-linecap="round" stroke-linejoin="round"
d="M12 9v3.75m-9.303 3.376c-.866 1.5.217 3.374 1.948 3.374h14.71c1.73 0 2.813-1.874 1.948-3.374L13.949 3.378c-.866-1.5-3.032-1.5-3.898 0L2.697 16.126zM12 15.75h.007v.008H12v-.008z"/>
</svg>
{%- endmacro %}
{% macro icon_check(klasse="h-4 w-4") -%}
{{ _svg(klasse, "M4.5 12.75l6 6 9-13.5") }}
{%- endmacro %}
{% macro icon_gebaeude(klasse="h-5 w-5") -%}
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"
stroke-width="1.8" stroke="currentColor" class="{{ klasse }}"
aria-hidden="true" focusable="false">
<path stroke-linecap="round" stroke-linejoin="round"
d="M2.25 21h19.5m-18-18v18m10.5-18v18m6-13.5V21M6.75 6.75h.75m-.75 3h.75m-.75 3h.75m3-6h.75m-.75 3h.75m-.75 3h.75M6.75 21v-3.375c0-.621.504-1.125 1.125-1.125h2.25c.621 0 1.125.504 1.125 1.125V21M3 3h12m-.75 4.5H21m-3.75 3.75h.008v.008h-.008v-.008zm0 3h.008v.008h-.008v-.008zm0 3h.008v.008h-.008v-.008z"/>
</svg>
{%- endmacro %}
{% macro icon_tag(klasse="h-5 w-5") -%}
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"
stroke-width="1.8" stroke="currentColor" class="{{ klasse }}"
aria-hidden="true" focusable="false">
<path stroke-linecap="round" stroke-linejoin="round"
d="M9.568 3H5.25A2.25 2.25 0 003 5.25v4.318c0 .597.237 1.17.659 1.591l9.581 9.581c.699.699 1.78.872 2.607.33a18.095 18.095 0 005.223-5.223c.542-.827.369-1.908-.33-2.607L11.16 3.66A2.25 2.25 0 009.568 3z"/>
<path stroke-linecap="round" stroke-linejoin="round" d="M6 6h.008v.008H6V6z"/>
</svg>
{%- endmacro %}
{% macro icon_buch(klasse="h-5 w-5") -%}
{{ _svg(klasse, "M12 6.042A8.967 8.967 0 006 3.75c-1.052 0-2.062.18-3 .512v14.25A8.987 8.987 0 016 18c2.305 0 4.408.867 6 2.292m0-14.25a8.966 8.966 0 016-2.292c1.052 0 2.062.18 3 .512v14.25A8.987 8.987 0 0018 18a8.967 8.967 0 00-6 2.292m0-14.25v14.25") }}
{%- endmacro %}
{% macro icon_dokument(klasse="h-5 w-5") -%}
{{ _svg(klasse, "M19.5 14.25v-2.625a3.375 3.375 0 00-3.375-3.375h-1.5A1.125 1.125 0 0113.5 7.125v-1.5a3.375 3.375 0 00-3.375-3.375H8.25m0 12.75h7.5m-7.5 3H12M10.5 2.25H5.625c-.621 0-1.125.504-1.125 1.125v17.25c0 .621.504 1.125 1.125 1.125h12.75c.621 0 1.125-.504 1.125-1.125V11.25a9 9 0 00-9-9z") }}
{%- endmacro %}
{% macro icon_chevron_unten(klasse="h-3.5 w-3.5") -%}
{{ _svg(klasse, "M19.5 8.25l-7.5 7.5-7.5-7.5") }}
{%- endmacro %}
{% macro icon_chevron_oben(klasse="h-3.5 w-3.5") -%}
{{ _svg(klasse, "M4.5 15.75l7.5-7.5 7.5 7.5") }}
{%- endmacro %}
{% macro icon_chevron_links(klasse="h-4 w-4") -%}
{{ _svg(klasse, "M15.75 19.5L8.25 12l7.5-7.5") }}
{%- endmacro %}
{% macro icon_chevron_rechts(klasse="h-4 w-4") -%}
{{ _svg(klasse, "M8.25 4.5l7.5 7.5-7.5 7.5") }}
{%- endmacro %}

View File

@@ -8,7 +8,7 @@
</head> </head>
<body class="bg-slate-100 text-slate-800 min-h-screen flex items-center justify-center px-4"> <body class="bg-slate-100 text-slate-800 min-h-screen flex items-center justify-center px-4">
<div class="bg-white shadow-md rounded-xl p-8 w-full max-w-sm"> <div class="bg-white shadow-md rounded-xl p-8 w-full max-w-sm">
<h1 class="text-xl font-bold mb-1">&#127923; {{ app_name }}</h1> <h1 class="text-xl font-bold mb-1 flex items-center gap-2">{% from "icons.html" import icon_wuerfelbecher %}{{ icon_wuerfelbecher("h-6 w-6 text-emerald-700") }} {{ app_name }}</h1>
<p class="text-sm text-slate-500 mb-6">Bitte anmelden.</p> <p class="text-sm text-slate-500 mb-6">Bitte anmelden.</p>
{% if fehler %} {% if fehler %}
<div class="mb-4 rounded-lg border border-red-300 bg-red-50 text-red-700 text-sm px-3 py-2" role="alert"> <div class="mb-4 rounded-lg border border-red-300 bg-red-50 text-red-700 text-sm px-3 py-2" role="alert">

View File

@@ -437,7 +437,9 @@ def test_neuheitenliste_rendert_platzhalter_ohne_bild(app, client):
assert antwort.status_code == 200 assert antwort.status_code == 200
liste = antwort.text.split('<div id="neuheiten-liste"')[1].split("</main>")[0] liste = antwort.text.split('<div id="neuheiten-liste"')[1].split("</main>")[0]
assert "<img" not in liste assert "<img" not in liste
assert "&#127922;" in antwort.text # Spielicon-Zeichen im Platzhalter-Div # SVG-Platzhalter statt Emoji: Würfel-Icon + Hinweistext
assert 'aria-label="Kein Cover vorhanden"' in liste
assert "<svg" in liste
def test_planungsliste_zeigt_cover(app, client): def test_planungsliste_zeigt_cover(app, client):