Hide the phone placeholder on contact and imprint

An empty kontakt.phone now hides the whole 'Lieber anrufen' block and the
phone line in the imprint instead of showing a red placeholder. Setting a
number brings both back.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Lara 2026-10-21 09:43:36 +02:00
parent e2a56840be
commit d035bbcd61
2 changed files with 9 additions and 11 deletions

View file

@ -18,10 +18,8 @@ const { impressum, kontakt } = site;
<h2>Kontakt</h2>
<p>
E-Mail: <a href={`mailto:${kontakt.email}`}>{kontakt.email}</a><br />
Telefon: {kontakt.phone
? kontakt.phone
: <span class="placeholder">[Telefonnummer eintragen]</span>}
E-Mail: <a href={`mailto:${kontakt.email}`}>{kontakt.email}</a>
{kontakt.phone && (<><br />Telefon: {kontakt.phone}</>)}
</p>
<h2>Umsatzsteuer-ID</h2>

View file

@ -277,13 +277,13 @@ const findItem = (src: string) =>
<h2>{kontakt.title}</h2>
<p class="text-lead" set:html={rich(kontakt.lead)} />
{kontakt.phone && (
<div class="contact-detail">
<p class="contact-label">Lieber anrufen</p>
<p class={kontakt.phone ? 'contact-phone' : 'placeholder contact-phone'}>
{kontakt.phone || '[Telefonnummer eintragen]'}
</p>
<p class="contact-phone">{kontakt.phone}</p>
{kontakt.hours && <p class="contact-hours">{kontakt.hours}</p>}
</div>
)}
<div class="contact-detail">
<p class="contact-label">Oder direkt schreiben</p>