Compare commits
4 Commits
9d477b5cb1
...
5eb0125187
Author | SHA1 | Date | |
---|---|---|---|
5eb0125187 | |||
3793481cb2 | |||
b736b97ee5 | |||
0d6182dd36 |
@ -11,7 +11,7 @@
|
|||||||
{{ with (index (.Resources.ByType "image") 0) }}
|
{{ with (index (.Resources.ByType "image") 0) }}
|
||||||
{{ $height := add .Height 0.0}}
|
{{ $height := add .Height 0.0}}
|
||||||
{{ $ratio := div $height .Width}}
|
{{ $ratio := div $height .Width}}
|
||||||
{{ $thumb := .Fit "540x360"}}
|
{{ $thumb := .Fit "540x540 q80 webp"}}
|
||||||
<div class="p-summary{{if gt $ratio 1 }} portrait {{else}} landscape {{end}}">
|
<div class="p-summary{{if gt $ratio 1 }} portrait {{else}} landscape {{end}}">
|
||||||
<div class="summary-image {{if gt $ratio 1 }} portrait {{else}} landscape {{end}}">
|
<div class="summary-image {{if gt $ratio 1 }} portrait {{else}} landscape {{end}}">
|
||||||
<a href="{{ $postPermalink }}"><img src="{{ $thumb.Permalink }}" alt="{{ .Title }}"> </a>
|
<a href="{{ $postPermalink }}"><img src="{{ $thumb.Permalink }}" alt="{{ .Title }}"> </a>
|
||||||
@ -32,4 +32,4 @@
|
|||||||
</a>
|
</a>
|
||||||
</footer>
|
</footer>
|
||||||
</article>
|
</article>
|
||||||
</div>
|
</div>
|
||||||
|
@ -13,7 +13,7 @@
|
|||||||
{{ with (index (.Resources.ByType "image") 0) }}
|
{{ with (index (.Resources.ByType "image") 0) }}
|
||||||
{{ $height := add .Height 0.0}}
|
{{ $height := add .Height 0.0}}
|
||||||
{{ $ratio := div $height .Width}}
|
{{ $ratio := div $height .Width}}
|
||||||
{{ $thumb := .Fit "540x360"}}
|
{{ $thumb := .Fit "540x540 q80 webp"}}
|
||||||
<div class="p-summary{{if gt $ratio 1 }} portrait {{else}} landscape {{end}}">
|
<div class="p-summary{{if gt $ratio 1 }} portrait {{else}} landscape {{end}}">
|
||||||
<div class="summary-image {{if gt $ratio 1 }} portrait {{else}} landscape {{end}}">
|
<div class="summary-image {{if gt $ratio 1 }} portrait {{else}} landscape {{end}}">
|
||||||
<a href="{{ $postPermalink }}"><img src="{{ $thumb.Permalink }}" alt="{{ .Title }}"> </a>
|
<a href="{{ $postPermalink }}"><img src="{{ $thumb.Permalink }}" alt="{{ .Title }}"> </a>
|
||||||
|
Reference in New Issue
Block a user