fix: one-column teasers without an image no longer break the page
f:image threw when the teaser had no image (teaserImage false), and production showed "Oops, an error occurred!" instead of the element, e.g. three times on the snowzone privacy page. The image is now skipped like in the disturber partials. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
1 parent
3fa4a81e97
commit
fe3af34063
1 file changed
+8
-6
@@ -9,12 +9,14 @@
|
||||
<f:if condition="{context.country}">
|
||||
{ep:icon(icon: 'flag-{context.country.code -> f:format.case(mode: \'lower\')}', class: 'w-8 h-6 absolute top-0 left-0')}
|
||||
</f:if>
|
||||
<f:image image="{teaserImage}"
|
||||
loading="lazy"
|
||||
class="block w-full h-full object-cover"
|
||||
width="400c"
|
||||
height="300c"
|
||||
alt="{teaserImage.alternative}" />
|
||||
<f:if condition="{teaserImage}">
|
||||
<f:image image="{teaserImage}"
|
||||
loading="lazy"
|
||||
class="block w-full h-full object-cover"
|
||||
width="400c"
|
||||
height="300c"
|
||||
alt="{teaserImage.alternative}" />
|
||||
</f:if>
|
||||
</div>
|
||||
<div class="flex-1 flex flex-col pt-4 bg-white border border-t-0 border-zinc-200">
|
||||
<a href="{f:uri.typolink(parameter: data.header_link)}" class="px-2 peer headline--3 mb-2 no-underline">
|
||||
|
||||
Reference in new issue
Block a user