fix(renderer): use default instead of lqip initial resolution

This commit is contained in:
kdevo
2021-10-11 20:43:57 +02:00
parent 4ee7a57052
commit e73b63ad46
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -13,7 +13,7 @@
srcset="data:{{ .MediaType }};base64,{{ $placeholderB64 }}"
{{- end }}
{{- end -}}
{{- with (default $imgDict.default $imgDict.lqip) }} height="{{ .Height }}" width="{{ .Width }}" {{- end -}}
{{- with $imgDict.default }} height="{{ .Height }}" width="{{ .Width }}" {{- end -}}
{{- if $imgDict.responsive -}}{{ with partial "renderer/_srcset" $imgDict }} data-sizes="auto" data-srcset="{{ . }}"{{- end }} {{- end -}}>
{{ partial "renderer/lqip" (merge . (dict "imgDict" $imgDictFallback)) }}
</picture>
+1 -1
View File
@@ -20,6 +20,6 @@
{{ else }}
src="{{ $imgDict.default.Permalink }}" class="{{ $class }} lazyload"
{{- end -}}
{{- with (default $imgDict.default $imgDict.lqip) }} height="{{ .Height }}" width="{{ .Width }}" {{- end -}}
{{- with $imgDict.default }} height="{{ .Height }}" width="{{ .Width }}" {{- end -}}
{{- if $imgDict.responsive -}}{{ with partial "renderer/_srcset" $imgDict }} data-sizes="auto" data-srcset="{{ . }}"{{- end }} {{- end -}}
{{- with $alt }} alt="{{ . }}" {{- end }}>