fix: Do not use large images on post thumbnails

This commit is contained in:
Damillora 2021-04-20 16:35:20 +07:00
parent fc67f3b40b
commit 86e1a1e6de
1 changed files with 2 additions and 4 deletions

View File

@ -13,12 +13,10 @@ for it, and apply those styles to the <header> tag. Else, we just output a <head
<div>
<div class="post-card__image">
{{#if feature_image}}
<img srcset="{{img_url feature_image size=" s"}} 300w, {{img_url feature_image size="m" }} 600w,
{{img_url feature_image size="l" }} 1000w, {{img_url feature_image size="xl" }} 2000w"
<img srcset="{{img_url feature_image size=" s"}} 300w"
src="{{img_url feature_image size=" m"}}" alt="{{title}}" loading="lazy">
{{else}}
<img srcset="{{img_url @site.cover_image size=" s"}} 300w, {{img_url @site.cover_image size="m" }} 600w,
{{img_url @site.cover_image size="l" }} 1000w, {{img_url @site.cover_image size="xl" }} 2000w"
<img srcset="{{img_url feature_image size=" s"}} 300w"
src="{{img_url @site.cover_image size=" m"}}" alt="{{title}}" loading="lazy">
{{/if}}
</div>