small fixes

This commit is contained in:
teldra 2022-06-15 22:23:00 +02:00
parent ad1c7cc95d
commit 51cad7172f
1 changed files with 2 additions and 2 deletions

View File

@ -82,7 +82,7 @@
{{- $banner := .Resources.GetMatch "banner*" -}}
{{- if $banner -}}
{{- $c = printf "<p><img loading=\"lazy\" style=\"width: 65%s;\" src=\"%s\" width=\"%d\" height=\"%d\" /></p>%s" "%" $banner.Permalink $banner.Width $banner.Height $c -}}
{{- $c = printf "<p style=\"width: 65%s;\"><img loading=\"lazy\" src=\"%s\" width=\"%d\" height=\"%d\" /></p>%s" "%" $banner.Permalink $banner.Width $banner.Height $c -}}
{{- end -}}
{{- if $when -}}
@ -92,7 +92,7 @@
{{- range .Resources.ByType "image" -}}
{{- $img := . -}}
{{- if not (hasPrefix $img.Name "banner") -}}
{{- $c = printf "%s<p><img loading=\"lazy\" style=\"width: 65%s;\" src=\"%s\" width=\"%d\" height=\"%d\" /></p>" $c "%" $img.Permalink $img.Width $img.Height -}}
{{- $c = printf "%s<p style=\"width: 65%s;\"><img loading=\"lazy\" src=\"%s\" width=\"%d\" height=\"%d\" /></p>" $c "%" $img.Permalink $img.Width $img.Height -}}
{{- end -}}
{{- end -}}