oxil-net1
Version:
Oxford Information Labs Netistrar Theme
48 lines (35 loc) • 1.49 kB
HTML
{{- $bkImg := .Resources.GetMatch "*background*" -}}
{{- $link := .Permalink -}}
<div class="flex flex-wrap gf9" >
{{- with .Params.youtubeid -}}
<div class="w-60 with-link" >
<amp-youtube width="480"
height="270"
layout="responsive"
data-videoid="{{.}}">
</amp-youtube>
<a href="{{$link}}"></a>
</div>
{{- else -}}
<div class="w-60 with-link gf9" >
{{ $img := .Resources.GetMatch "*featured*" }}
{{ with $img }}
{{ $big := .Resize "2000x" }}
{{ $medium := .Resize "1000x" }}
{{ $small := $big.Resize "600x" }}
<amp-img src="{{ $medium.RelPermalink }}" alt="{{ $img.Title }}" width="16" height="9" layout="responsive" ></amp-img>
{{ end }}
<a href="{{.Permalink}}"></a>
</div>
{{- end -}}
<div class="w-40 px1 px4l py1 py2l flex-grid flex-col justify-between gf9">
<div class="mb1">
<div class="f2 lh11 mb050"><a class="inv " href="{{.Permalink}}">{{.Title}}</a>
</div>
<time class="small g8-text" datetime="{{ dateFormat " 2006-01-02T15:04:05-07:00" .Lastmod }}">
{{ dateFormat "2 Jan, 2006" .Lastmod }}
</time>
</div>
<div >{{ range .Params.categories }}<a href="/categories/{{- . | urlize -}}/" class="pipe uppercase text-colour inv normal">{{ . }}</a>{{ end }}: {{ range .Params.tags }}<a href="/tags/{{- . | urlize -}}/" class="com text-colour inv normal">{{ . }}</a>{{ end }}</div>
</div>
</div>