blob: e7acf9ed54e905d80a32d9915f12c2a00e414a97 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
<header class="article-header">
<a href="{{ .Permalink }}">
<h1 class="article-title" itemprop="name">
{{ .Title }}
</h1>
</a>
<div class="article-meta">
<div class="article-date">
<i class="fa fa-calendar"></i>
<time datetime="{{ .Date }}" itemprop="datePublished">{{ .Date.Format .Site.Params.date_format }}</time>
·
{{ .WordCount }}
{{ with .Site.Data.l10n.articles.words }}{{.}}{{end}}
·
{{ .ReadingTime }}
{{ with .Site.Data.l10n.articles.readingtime }}{{.}}{{end}}
</div>
{{ if isset .Params "categories" }}
{{ $categoriesLen := len .Params.categories }}
{{ if gt $categoriesLen 0 }}
<div class="article-category">
<i class="fa fa-folder"></i>
{{ range $k, $v := .Params.categories }}
{{ $url := printf "categories/%s" (. | urlize | lower) }}
<a class="article-category-link" href="{{ $url | absURL }}">{{ . }}</a>
{{ if lt $k (sub $categoriesLen 1) }}·{{ end }}
{{ end }}
</div>
{{ end }}
{{ end }}
{{ if isset .Params "tags" }}
{{ $tagsLen := len .Params.tags }}
{{ if gt $tagsLen 0 }}
<div class="article-category">
<i class="fa fa-tags"></i>
{{ range $k, $v := .Params.tags }}
{{ $url := printf "tags/%s" (. | urlize | lower) }}
<a class="article-category-link" href="{{ $url | absURL }}">{{ . }}</a>
{{ if lt $k (sub $tagsLen 1) }}·{{ end }}
{{ end }}
</div>
{{ end }}
{{ end }}
</div>
</header>
|