mirror of
https://github.com/adityatelange/hugo-PaperMod.git
synced 2025-05-13 06:34:24 -04:00
Fix image dimension condition checks
Update index_profile.html
This commit is contained in:
parent
72615b6d49
commit
f45b5a020d
1 changed files with 1 additions and 1 deletions
|
@ -13,7 +13,7 @@
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
{{- $prod := (hugo.IsProduction | or (eq site.Params.env "production")) }}
|
{{- $prod := (hugo.IsProduction | or (eq site.Params.env "production")) }}
|
||||||
{{- if and (in $processableFormats $img.MediaType.SubType) (eq $prod true)}}
|
{{- if and (in $processableFormats $img.MediaType.SubType) (eq $prod true)}}
|
||||||
{{- if (not (and (not .imageHeight) (not .imageWidth))) }}
|
{{- if and .imageWidth .imageHeight }}
|
||||||
{{- $img = $img.Resize (printf "%dx%d" .imageWidth .imageHeight) }}
|
{{- $img = $img.Resize (printf "%dx%d" .imageWidth .imageHeight) }}
|
||||||
{{- else if .imageHeight }}
|
{{- else if .imageHeight }}
|
||||||
{{- $img = $img.Resize (printf "x%d" .imageHeight) }}
|
{{- $img = $img.Resize (printf "x%d" .imageHeight) }}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue