24 lines
797 B
PHP
24 lines
797 B
PHP
|
|
<?php
|
||
|
|
|
||
|
|
declare(strict_types=1);
|
||
|
|
|
||
|
|
/**
|
||
|
|
* Vollflächiger Hero mit Hintergrundbild, Titel, Intro und CTAs.
|
||
|
|
* Props: $hero (array aus home.json: title, text, image, ctas)
|
||
|
|
*/
|
||
|
|
?>
|
||
|
|
<section class="hero">
|
||
|
|
<div class="hero__media" aria-hidden="true">
|
||
|
|
<?php component('img', ['image' => $hero['image'], 'sizes' => '100vw', 'eager' => true, 'class' => 'hero__img']); ?>
|
||
|
|
</div>
|
||
|
|
<div class="container hero__content">
|
||
|
|
<h1 class="hero__title"><?= e($hero['title']) ?></h1>
|
||
|
|
<p class="hero__text"><?= e($hero['text']) ?></p>
|
||
|
|
<div class="hero__actions">
|
||
|
|
<?php foreach ($hero['ctas'] as $cta): ?>
|
||
|
|
<?php component('cta', ['cta' => $cta]); ?>
|
||
|
|
<?php endforeach; ?>
|
||
|
|
</div>
|
||
|
|
</div>
|
||
|
|
</section>
|