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:
parent
e2a56840be
commit
d035bbcd61
2 changed files with 9 additions and 11 deletions
|
|
@ -18,10 +18,8 @@ const { impressum, kontakt } = site;
|
||||||
|
|
||||||
<h2>Kontakt</h2>
|
<h2>Kontakt</h2>
|
||||||
<p>
|
<p>
|
||||||
E-Mail: <a href={`mailto:${kontakt.email}`}>{kontakt.email}</a><br />
|
E-Mail: <a href={`mailto:${kontakt.email}`}>{kontakt.email}</a>
|
||||||
Telefon: {kontakt.phone
|
{kontakt.phone && (<><br />Telefon: {kontakt.phone}</>)}
|
||||||
? kontakt.phone
|
|
||||||
: <span class="placeholder">[Telefonnummer eintragen]</span>}
|
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<h2>Umsatzsteuer-ID</h2>
|
<h2>Umsatzsteuer-ID</h2>
|
||||||
|
|
|
||||||
|
|
@ -277,13 +277,13 @@ const findItem = (src: string) =>
|
||||||
<h2>{kontakt.title}</h2>
|
<h2>{kontakt.title}</h2>
|
||||||
<p class="text-lead" set:html={rich(kontakt.lead)} />
|
<p class="text-lead" set:html={rich(kontakt.lead)} />
|
||||||
|
|
||||||
<div class="contact-detail">
|
{kontakt.phone && (
|
||||||
<p class="contact-label">Lieber anrufen</p>
|
<div class="contact-detail">
|
||||||
<p class={kontakt.phone ? 'contact-phone' : 'placeholder contact-phone'}>
|
<p class="contact-label">Lieber anrufen</p>
|
||||||
{kontakt.phone || '[Telefonnummer eintragen]'}
|
<p class="contact-phone">{kontakt.phone}</p>
|
||||||
</p>
|
{kontakt.hours && <p class="contact-hours">{kontakt.hours}</p>}
|
||||||
{kontakt.hours && <p class="contact-hours">{kontakt.hours}</p>}
|
</div>
|
||||||
</div>
|
)}
|
||||||
|
|
||||||
<div class="contact-detail">
|
<div class="contact-detail">
|
||||||
<p class="contact-label">Oder direkt schreiben</p>
|
<p class="contact-label">Oder direkt schreiben</p>
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue