fix: HTML errors
This commit is contained in:
parent
c158ac525d
commit
c7cfdcdb5b
4 changed files with 25 additions and 15 deletions
|
@ -15,23 +15,22 @@
|
|||
class="picture"
|
||||
itemprop="image"
|
||||
>
|
||||
{{- if $isResizable -}}
|
||||
<source srcset="{{- ($src.Resize "1200x webp").RelPermalink -}}" />
|
||||
<source srcset="{{- ($src.Resize "800x png").RelPermalink -}}" media="(max-width: 800px)"/>
|
||||
{{- end -}}
|
||||
|
||||
{{ if $isResizable -}}
|
||||
<source srcset="{{- ($src.Resize "1200x webp").RelPermalink -}}" />
|
||||
<source srcset="{{- ($src.Resize "800x png").RelPermalink -}}" media="(max-width: 800px)"/>
|
||||
{{- end }}
|
||||
<img
|
||||
class="u-photo picture__image"
|
||||
{{- if not $isResizable -}}
|
||||
{{ if not $isResizable -}}
|
||||
src="{{- $src.RelPermalink -}}"
|
||||
{{- else -}}
|
||||
src="{{- ($src.Resize "1200x webp").RelPermalink -}}"
|
||||
width="{{- $src.Width -}}"
|
||||
height="{{- $src.Height -}}"
|
||||
{{- end -}}
|
||||
{{- with $src.Params.alt -}}alt="{{- . -}}"{{- end -}}
|
||||
{{- with $src.Params.title -}}title="{{- . -}}" {{- end -}}
|
||||
{{- end }}
|
||||
{{ with $src.Params.alt -}}alt="{{- . -}}"{{- end }}
|
||||
{{ with $src.Params.title -}}title="{{- . -}}" {{- end }}
|
||||
loading="lazy"
|
||||
role="img"
|
||||
/>
|
||||
</picture>
|
||||
</picture>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue