diff --git a/layouts/_default/_markup/render-image.html b/layouts/_default/_markup/render-image.html index 304aab1a3..8f6ec8c30 100644 --- a/layouts/_default/_markup/render-image.html +++ b/layouts/_default/_markup/render-image.html @@ -4,11 +4,15 @@ (dict "Process" "resize 1200x webp q75" "descriptor" "1200w") (dict "Process" "resize 1600x webp q75" "descriptor" "1600w") -}} + +{{- if .Title -}}
{{- dict "Src" .Destination "Title" .Text "Caption" .Title "Linked" $lightgallery "Loading" "lazy" "Sizes" "auto" "Resources" .Page.Resources "OptimConfig" $optim | partial "plugin/image.html" -}} - {{- if .Title -}} -
- {{- .Title | safeHTML -}} -
- {{- end -}} +
+ {{- .Title | safeHTML -}} +
+{{- else -}} + {{- dict "Src" .Destination "Class" "tw-inline" "Title" .Text "Caption" .Title "Loading" "lazy" "Sizes" "auto" "Resources" .Page.Resources "OptimConfig" $optim | partial "plugin/image.html" -}} +{{- end -}} +