feat: accessibility and performance improvement
This commit is contained in:
@@ -25,7 +25,33 @@
|
|||||||
<div class="card-front absolute w-full h-full backface-hidden overflow-hidden shadow-lg">
|
<div class="card-front absolute w-full h-full backface-hidden overflow-hidden shadow-lg">
|
||||||
<f:if condition="{card.images}">
|
<f:if condition="{card.images}">
|
||||||
<f:then>
|
<f:then>
|
||||||
<f:image image="{card.images.0}" alt="{card.images.0.alternative}" class="w-full h-full object-cover grayscale group-hover:grayscale-0 transition-all duration-500" />
|
<picture class="w-full h-full object-cover grayscale group-hover:grayscale-0 transition-all duration-500">
|
||||||
|
<!-- WEBP source -->
|
||||||
|
<source
|
||||||
|
type="image/webp"
|
||||||
|
srcset="
|
||||||
|
{f:uri.image(image:card.images.0, width:'320c', cropVariant:'default', fileExtension:'webp')} 320w,
|
||||||
|
{f:uri.image(image:card.images.0, width:'768c', cropVariant:'default', fileExtension:'webp')} 768w,
|
||||||
|
{f:uri.image(image:card.images.0, width:'1024c', cropVariant:'default', fileExtension:'webp')} 1024w"
|
||||||
|
sizes="(max-width: 767px) 90vw,
|
||||||
|
{f:if(condition: '{data.imagesize} == 1', then: '(min-width: 768px) 40vw', else: '(min-width: 768px) 50vw')}" />
|
||||||
|
<!-- Fallback source -->
|
||||||
|
<source
|
||||||
|
srcset="
|
||||||
|
{f:uri.image(image:card.images.0, width:'320c', cropVariant:'default')} 320w,
|
||||||
|
{f:uri.image(image:card.images.0, width:'400c', cropVariant:'default')} 768w,
|
||||||
|
{f:uri.image(image:card.images.0, width:'538c', cropVariant:'default')} 1024w"
|
||||||
|
sizes="(max-width: 767px) 90vw,
|
||||||
|
{f:if(condition: '{data.imagesize} == 1', then: '(min-width: 768px) 40vw', else: '(min-width: 768px) 50vw')}" />
|
||||||
|
<f:image
|
||||||
|
image="{card.images.0}"
|
||||||
|
treatIdAsReference="1"
|
||||||
|
cropVariant="default"
|
||||||
|
width="538c"
|
||||||
|
alt="{card.images.0.alternative}"
|
||||||
|
class="w-full h-full object-cover"
|
||||||
|
/>
|
||||||
|
</picture>
|
||||||
</f:then>
|
</f:then>
|
||||||
<f:else>
|
<f:else>
|
||||||
<div class="w-full h-full bg-gray-300 flex items-center justify-center">
|
<div class="w-full h-full bg-gray-300 flex items-center justify-center">
|
||||||
|
|||||||
@@ -80,13 +80,13 @@
|
|||||||
|
|
||||||
<!-- Social icons -->
|
<!-- Social icons -->
|
||||||
<div class="space-x-3">
|
<div class="space-x-3">
|
||||||
<a href="#" class="w-6 h-6 md:w-10 md:h-10 bg-primary text-white rounded-full inline-flex items-center justify-center hover:bg-primary-dark hover:text-white">
|
<a href="#" aria-label="LinkedIn" class="w-6 h-6 md:w-10 md:h-10 bg-primary text-white rounded-full inline-flex items-center justify-center hover:bg-primary-dark hover:text-white">
|
||||||
<i class="ci ci-linkedin"></i>
|
<i class="ci ci-linkedin"></i>
|
||||||
</a>
|
</a>
|
||||||
<a href="#" class="w-6 h-6 md:w-10 md:h-10 bg-primary text-white rounded-full inline-flex items-center justify-center hover:bg-primary-dark hover:text-white">
|
<a href="#" aria-label="Instagram" class="w-6 h-6 md:w-10 md:h-10 bg-primary text-white rounded-full inline-flex items-center justify-center hover:bg-primary-dark hover:text-white">
|
||||||
<i class="ci ci-instagram"></i>
|
<i class="ci ci-instagram"></i>
|
||||||
</a>
|
</a>
|
||||||
<a href="#" class="w-6 h-6 md:w-10 md:h-10 bg-primary text-white rounded-full inline-flex items-center justify-center hover:bg-primary-dark hover:text-white">
|
<a href="#" aria-label="Facebook" class="w-6 h-6 md:w-10 md:h-10 bg-primary text-white rounded-full inline-flex items-center justify-center hover:bg-primary-dark hover:text-white">
|
||||||
<i class="ci ci-facebook"></i>
|
<i class="ci ci-facebook"></i>
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -22,15 +22,15 @@
|
|||||||
|
|
||||||
<!-- Kontaktiere uns -->
|
<!-- Kontaktiere uns -->
|
||||||
<div>
|
<div>
|
||||||
<h5 class="text-white">Kontaktiere uns</h5>
|
<h3 class="text-white text-sm">Kontaktiere uns</h3>
|
||||||
<ul class="space-y-4">
|
<ul class="space-y-4">
|
||||||
<li class="flex items-center">
|
<li class="flex items-center pl-0">
|
||||||
<!-- mail -->
|
<!-- mail -->
|
||||||
<a href="mailto:inquiry@dialogrelations.com" class="hover:text-white text-white">
|
<a href="mailto:inquiry@dialogrelations.com" class="hover:text-white text-white">
|
||||||
inquiry@dialogrelations.com
|
inquiry@dialogrelations.com
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li class="flex items-center">
|
<li class="flex items-center pl-0">
|
||||||
<!-- phone -->
|
<!-- phone -->
|
||||||
<a href="tel:+4312313435" class="hover:text-white text-white">
|
<a href="tel:+4312313435" class="hover:text-white text-white">
|
||||||
+43 1231 3435
|
+43 1231 3435
|
||||||
@@ -41,7 +41,7 @@
|
|||||||
|
|
||||||
<!-- Folge uns -->
|
<!-- Folge uns -->
|
||||||
<div class="flex flex-col items-start md:items-end">
|
<div class="flex flex-col items-start md:items-end">
|
||||||
<h5 class="text-white">Folge uns</h5>
|
<h3 class="text-white text-sm">Folge uns</h3>
|
||||||
<div class="flex space-x-4">
|
<div class="flex space-x-4">
|
||||||
<!-- Social buttons -->
|
<!-- Social buttons -->
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user