Files
tsv08kulmbach-website/app/pages/verein.php
fs 3b6f630a72 Unterseiten: Fußball-Übersicht, Mannschaften, Jugend, Verein, Rechtliches
Neue Seiten + Routen: fussball, fussball/{erste-mannschaft,zweite-mannschaft,
damen}, jugendfussball, verein, impressum, datenschutz. Dazu die Komponenten
team, team-cards/-roster/-photo/-bento, faq/faq-contact, key-facts, age-groups,
cta-band, training-location und der contact-slider.

Daten in teams/fussball/jugend/verein.json; club.json um Vorstand, Bankdaten,
Datenschutz-Kontakt erweitert. person-grid bekommt $names-Filter, partner-grid
einen Intro-Stil. Seiten setzen $meta['schema'] via team_/page_schema.
Styles für alle neuen Komponenten in components.css.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01KDQZ6FuchNUh2bxSW9PeNv
2026-06-19 08:13:04 +02:00

85 lines
3.4 KiB
PHP
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<?php
declare(strict_types=1);
/**
* Vereins-Übersichtsseite (Hub). Inhalt: data/verein.json + data/club.json.
* Struktur: Hero → Eckdaten (key-facts) → Leitbild (split) → Abteilungs-Kacheln →
* Gelände/Drohnenbild → CTA → FAQ.
*/
$page = json_load('verein');
$club = json_load('club');
$addr = $club['address'] ?? [];
$mapsQuery = rawurlencode(trim(($addr['venue'] ?? '') . ', ' . ($addr['street'] ?? '') . ', ' . ($addr['zip'] ?? '') . ' ' . ($addr['city'] ?? ''), ', '));
// Zwei Abteilungs-Kacheln. Turnen verlinkt bereits auf /turnen (Seite folgt).
$cards = [
[
'name' => 'Fußball',
'slug' => 'fussball',
'category' => 'Herren · Damen · Jugend',
'image' => ['base' => 'img/pages/fussball-hero', 'widths' => [640, 1000, 1600], 'alt' => 'Fußball beim TSV 08 Kulmbach'],
],
[
'name' => 'Turnabteilung',
'slug' => 'turnen',
'category' => 'Turnen · Trampolin',
'image' => ['base' => 'img/pages/turnen', 'widths' => [640, 1000], 'alt' => 'Turnabteilung des TSV 08 Kulmbach'],
],
];
$meta = [
'title' => 'Der Verein',
'description' => 'Der TSV 1908 Kulmbach e. V. seit 1908 dein Sportverein im Katzbachtal in Kulmbach. Über 650 Mitglieder, die Abteilungen Fußball und Turnen, zuhause auf der Hans-Rausch-Sportanlage.',
'og_image' => 'img/pages/vereinsgelaende-1600.jpg',
'schema' => page_schema(
[
['name' => 'Startseite', 'slug' => ''],
['name' => 'Der Verein', 'slug' => 'verein'],
],
$page['faq'] ?? []
),
];
component('hero', ['hero' => $page['hero']]);
component('key-facts', ['facts' => $page['facts'] ?? [], 'anchor' => 'eckdaten']);
component('section', ['section' => $page['about']]);
component('team-cards', [
'teams' => $cards,
'title' => 'Unsere Abteilungen',
'intro' => $page['abteilungen_intro'] ?? '',
'intro_below' => true,
'anchor' => 'abteilungen',
]);
?>
<section class="section facility" id="gelaende">
<div class="container">
<h2><?= e($page['gelaende']['title']) ?></h2>
<p class="facility__lead"><?= e($page['gelaende']['text']) ?></p>
<figure class="facility__figure">
<?php component('img', ['image' => $page['gelaende']['image'], 'sizes' => '(max-width: 1200px) 100vw, 1200px', 'class' => 'facility__img']); ?>
<?php if (!empty($page['gelaende']['caption'])): ?>
<figcaption class="facility__caption"><?= e($page['gelaende']['caption']) ?></figcaption>
<?php endif; ?>
</figure>
<p class="facility__actions">
<a class="btn btn--outline" href="https://www.google.com/maps/search/?api=1&amp;query=<?= e($mapsQuery) ?>" target="_blank" rel="noopener">Route planen<span class="visually-hidden"> (öffnet Google Maps in neuem Tab)</span></a>
</p>
</div>
</section>
<?php
component('cta-band', ['band' => [
'title' => 'Werde Teil des TSV 08',
'text' => 'Ob Fußball oder Turnen komm unverbindlich vorbei oder schreib uns. Wir finden gemeinsam die passende Gruppe für dich.',
'ctas' => [
['label' => 'Mitglied werden', 'slug' => 'mitglied-werden', 'style' => 'primary'],
['label' => 'Kontakt aufnehmen', 'slug' => '#kontakt', 'style' => 'outline'],
],
]]);
component('faq', ['faq' => $page['faq'] ?? []]);