Fix blogPhoto shortcode

w unit inside srcset means width in original photo pixels, not height
This commit is contained in:
Vojtěch Káně 2020-04-20 13:35:43 +02:00
parent 0a61815dcb
commit cc5e75e469

View File

@ -26,4 +26,4 @@ or
{{- $resizedHD := $img.Fit "1280x720 q50" -}}
{{- $resizedSD := $img.Fit "640x360 q50" -}}
<img src="{{ $resizedFullHD.RelPermalink }}" alt="{{ $alt }}" srcset="{{ $resizedFullHD.RelPermalink }} 1080w, {{ $resizedHD.RelPermalink }} 720w, {{ $resizedSD.RelPermalink }} 360w" sizes="(orientation: portrait) 100vw, 50vw">
<img src="{{ $resizedFullHD.RelPermalink }}" alt="{{ $alt }}" srcset="{{ $resizedFullHD.RelPermalink }} 1920w, {{ $resizedHD.RelPermalink }} 1280w, {{ $resizedSD.RelPermalink }} 640w" sizes="(orientation: portrait) 100vw, 50vw">