mirror of
https://github.com/CaiJimmy/hugo-theme-stack.git
synced 2024-11-23 10:21:46 +01:00
fix(article list): specify image width in srcset
This commit is contained in:
parent
8c4ad17a09
commit
1e28a661d9
1 changed files with 1 additions and 1 deletions
|
@ -8,7 +8,7 @@
|
|||
{{- $thumbnailRetina := $image.resource.Fill "1600x500" -}}
|
||||
|
||||
<img src="{{ $thumbnail.RelPermalink }}"
|
||||
srcset="{{ $thumbnail.RelPermalink }} 1x, {{ $thumbnailRetina.RelPermalink }} 2x"
|
||||
srcset="{{ $thumbnail.RelPermalink }} 800w, {{ $thumbnailRetina.RelPermalink }} 1600w"
|
||||
width="{{ $thumbnail.Width }}" height="{{ $thumbnail.Height }}" loading="lazy"
|
||||
alt="Featured image of post {{ .Title }}" />
|
||||
{{ else }}
|
||||
|
|
Loading…
Reference in a new issue