From 3421c99ebfd73dd40e4fe73ea0e279e0d2ba3a8d Mon Sep 17 00:00:00 2001 From: vlebert <49779177+vlebert@users.noreply.github.com> Date: Thu, 3 Jun 2021 12:09:08 +0200 Subject: [PATCH] Fix `ressource.Fit` not resizing the image properly Co-authored-by: vlebert --- layouts/partials/cards/project.html | 2 +- layouts/partials/cards/skill.html | 2 +- layouts/partials/helpers/get-author-image.html | 2 +- layouts/partials/sections/home.html | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/layouts/partials/cards/project.html b/layouts/partials/cards/project.html index 93d022d..77cd395 100644 --- a/layouts/partials/cards/project.html +++ b/layouts/partials/cards/project.html @@ -11,7 +11,7 @@ {{ $logoImage:= resources.Get .logo}} {{ if $logoImage }} - {{ $logoImage := $logoImage.Fit "24x24" }} + {{ $logoImage = $logoImage.Fit "24x24" }} {{ .name }} {{ end }} diff --git a/layouts/partials/cards/skill.html b/layouts/partials/cards/skill.html index 1cf229f..cba5529 100644 --- a/layouts/partials/cards/skill.html +++ b/layouts/partials/cards/skill.html @@ -7,7 +7,7 @@ {{/* svg don't support "Fit" operation */}} {{ if ne $logoImage.MediaType.SubType "svg" }} - {{ $logoImage := $logoImage.Fit "24x24" }} + {{ $logoImage = $logoImage.Fit "24x24" }} {{ end }} {{ .name }} diff --git a/layouts/partials/helpers/get-author-image.html b/layouts/partials/helpers/get-author-image.html index 439bafc..914a5ed 100644 --- a/layouts/partials/helpers/get-author-image.html +++ b/layouts/partials/helpers/get-author-image.html @@ -21,7 +21,7 @@ {{/* apply image processing. don't use "Fit" in svg because its not supported */}} {{ $authorImage:= resources.Get $authorImage}} {{ if and $authorImage (ne $authorImage.MediaType.SubType "svg") }} - {{ $authorImage := $authorImage.Fit "120x120" }} + {{ $authorImage = $authorImage.Fit "120x120" }} {{ end }} {{/* return the author image link */}} diff --git a/layouts/partials/sections/home.html b/layouts/partials/sections/home.html index 6ab4cba..4420c85 100644 --- a/layouts/partials/sections/home.html +++ b/layouts/partials/sections/home.html @@ -26,7 +26,7 @@ {{ $authorImage = $author.image }} {{ end }} {{ $authorImage := resources.Get $authorImage }} -{{ $authorImage := $authorImage.Fit "148x148" }} +{{ $authorImage = $authorImage.Fit "148x148" }} {{/* get file that matches the filename as specified as src="" in shortcode */}} {{ $src := resources.Get $backgroundImage }}