Remove the sizes attribute
It defaults to 100vw, which may be wasteful sometimes, but it guarantees smooth experience. I am not aware of any simple way of requesting the current widescreen behavior "make it as wide as possible while not exceeding 30rem height" using the sizes attribute. This setting may be especially wasteful for portrait images, as their rendered width will be much smaller than the viewport width.
This commit is contained in:
parent
5be48c59c6
commit
058de79991
@ -46,6 +46,6 @@ where possible named params are:
|
||||
{{- end -}}
|
||||
|
||||
<figure>
|
||||
<img src="{{ $largest.RelPermalink }}" alt="{{ $alt }}" srcset="{{ delimit $srcset ", " }}" sizes="(orientation: portrait) 100vw, 50vw">
|
||||
<img src="{{ $largest.RelPermalink }}" alt="{{ $alt }}" srcset="{{ delimit $srcset ", " }}">
|
||||
{{ if (ne $caption false) }}<figcaption>{{ $caption }}</figcaption>{{ end }}
|
||||
</figure>
|
||||
|
Loading…
Reference in New Issue
Block a user