forked from tsc-vfl/hugo-page
Fix home page to allow for global assets in thumbnails as well
This commit is contained in:
parent
3c7977dbae
commit
43b55ef8dd
@ -14,9 +14,14 @@
|
|||||||
<div class="teaser-image">
|
<div class="teaser-image">
|
||||||
{{ $page := . }}
|
{{ $page := . }}
|
||||||
{{ if .Params.Image }}
|
{{ if .Params.Image }}
|
||||||
{{ with (.Resources.GetMatch (.Params.Image)).Fit "290x190 webp" }}
|
{{ $resImage := resources.GetMatch (.Params.Image) }}
|
||||||
|
{{ with .Resources.GetMatch (.Params.Image) }}
|
||||||
|
{{ $resImage = . }}
|
||||||
|
{{ end }}
|
||||||
|
{{/* {{ with ($resImage).Fit "290x190 webp" }} */}}
|
||||||
|
{{ with $resImage }}
|
||||||
<a href="{{ $urlBlogEntry }}">
|
<a href="{{ $urlBlogEntry }}">
|
||||||
<img src="{{ .RelPermalink }}">
|
<img src="{{ (.Fit "290x190 webp").RelPermalink }}">
|
||||||
</a>
|
</a>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
Loading…
Reference in New Issue
Block a user