b2in/resources/views/livewire/web/components/sections/page-hero.blade.php
Kevin Adametz 451e738c8b CMS: Absatz-Tags aus dem Rich-Text-Editor erscheinen nicht mehr als Text
Der Editor packt eingefügten Text in <p>; Felder wie die FAQ-Antwort gibt die Website als Text
aus, die Tags waren sichtbar. Beim Speichern entfernt unwrapParagraphs() die Absätze (ein
Absatz ohne <p>, mehrere mit <br><br>, Blockinhalte unverändert). cms_inline() gibt die
Felder als bereinigtes Inline-HTML aus – auch schon gespeicherte Texte mit <p> erscheinen
sauber, Fett und Hervorhebung werden dargestellt.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-12 06:58:48 +00:00

31 lines
2.1 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.

{{-- Seitenkopf für Unterseiten – abgesetzte graue Fläche wie der Hero auf Startseite und
Netzwerkseite, damit er sich klar von den Blöcken darunter absetzt. --}}
<section id="seitenkopf" class="section-padding flex items-center relative border-b border-border/30 {{ $bg }}">
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 py-10 lg:py-12 bg-hero-container hero-frame rounded-[20px] w-[95%]">
@if (!empty($content['image']))
{{-- 3:2 statt hälftig geteilt – der Text bleibt der Hauptdarsteller, das Bild begleitet ihn nur. --}}
<div class="grid lg:grid-cols-5 gap-10 lg:gap-14 items-center">
<div class="lg:col-span-3 slide-right delay-200">
<x-web.hero-eyebrow :text="$content['eyebrow'] ?? null" class="mb-6" />
<h1 class="text-hero-alt">{!! $content['title'] ?? '' !!}</h1>
<p class="text-large text-muted-foreground leading-relaxed mt-6">{!! cms_inline($content['text'] ?? '') !!}</p>
<x-web.hero-trust :items="$content['stats'] ?? []" class="mt-8" />
</div>
<div class="lg:col-span-2 relative rounded-2xl overflow-hidden border border-white! shadow-elevated slide-left delay-300">
<img src="{{ theme_image_url($content['image']) }}" alt="{{ $content['image_alt'] ?? '' }}"
class="w-full aspect-[4/3] object-cover" />
<div class="absolute inset-0 bg-gradient-to-t from-black/15 to-transparent"></div>
</div>
</div>
@else
{{-- Ohne Motiv bleibt der Textblock allein stehen – kein leerer Platzhalterrahmen. --}}
<div class="max-w-3xl slide-right delay-200">
<x-web.hero-eyebrow :text="$content['eyebrow'] ?? null" class="mb-6" />
<h1 class="text-hero-alt">{!! $content['title'] ?? '' !!}</h1>
<p class="text-large text-muted-foreground leading-relaxed mt-6">{!! cms_inline($content['text'] ?? '') !!}</p>
<x-web.hero-trust :items="$content['stats'] ?? []" class="mt-8" />
</div>
@endif
</div>
</section>