rra
3 years ago
2 changed files with 51 additions and 29 deletions
@ -1,33 +1,36 @@ |
|||||
<div class='network card'> |
<div class='network card'> |
||||
<article class="h-entry network"> |
<article class="h-entry network"> |
||||
<header> |
<header> |
||||
|
{{ $postPermalink := .Permalink}} |
||||
<h2 class="p-name"><a href="{{ .Permalink }}" class="u-url">{{ .Title }}</a></h2> |
<h2 class="p-name"><a href="{{ .Permalink }}" class="u-url">{{ .Title }}</a></h2> |
||||
<div class="header-metadata"> |
|
||||
<time class="dt-published" datetime="{{ .Date.Format `Jan 02 2006` }}">{{ .Date.Format "Jan 02, 2006" }}</time> |
|
||||
<div class="filler"></div> |
|
||||
</div> |
|
||||
</header> |
</header> |
||||
|
|
||||
<div class="network-source"><span class="from p-author">From {{ if .Params.author }}<b>{{.Params.author}}</b> at {{ end }}<a href="{{ "/categories/" | relLangURL }}{{ .Params.feed_name | urlize }}">{{ .Params.feed_name }}</a></span></div> |
<div class="network-source"><span class="from p-author">From {{ if .Params.author }}<b>{{.Params.author}}</b> at {{ end }}<a href="{{ "/categories/" | relLangURL }}{{ .Params.feed_name | urlize }}">{{ .Params.feed_name }}</a></span></div> |
||||
|
{{ with (index (.Resources.ByType "image") 0) }} |
||||
<div class="p-summary {{if .Truncated}} truncated {{end}} img" > |
{{ $height := add .Height 0.0}} |
||||
{{ with (index (.Resources.ByType "image") 0) }} |
{{ $ratio := div $height .Width}} |
||||
{{ $thumb := .Fit "540x360"}} |
{{ $thumb := .Fit "540x360"}} |
||||
<div class="summary-image"> |
<div class="p-summary{{if gt $ratio 1 }} portrait {{else}} landscape {{end}}"> |
||||
<img src="{{ $thumb.Permalink }}" alt="{{ .Title }}"> |
<div class="summary-image {{if gt $ratio 1 }} portrait {{else}} landscape {{end}}"> |
||||
</div> |
<a href="{{ $postPermalink }}"><img src="{{ $thumb.Permalink }}" alt="{{ .Title }}"> </a> |
||||
|
</div> |
||||
|
{{ else }} |
||||
|
<div class="p-summary"> |
||||
{{ end }} |
{{ end }} |
||||
<div class="summary-text"> |
<div class="summary-text"> |
||||
{{ .Summary }} |
{{ .Summary }} |
||||
</div> |
</div> |
||||
|
</div> |
||||
|
|
||||
</div> |
<footer class='post-footer'> |
||||
{{ if .Truncated }} |
<div class='footer-filler'> |
||||
<footer class='post-footer'> |
<time class="dt-published" datetime="{{ .Date.Format `Jan 02 2006` }}">{{ .Date.Format "Jan 02, 2006" }}</time> |
||||
|
</div> |
||||
|
{{ if .Truncated }} |
||||
<div class='read-more'><a href="{{ .RelPermalink }}">Read More…</a></div> |
<div class='read-more'><a href="{{ .RelPermalink }}">Read More…</a></div> |
||||
<div class='footer-filler'></div> |
{{ end }} |
||||
</footer> |
</footer> |
||||
{{ end }} |
|
||||
|
|
||||
</article> |
</article> |
||||
</div> |
</div> |
Loading…
Reference in new issue