summaryrefslogtreecommitdiff
path: root/themes/new_theme/layouts/_default/list.html
blob: 2bc036c56b6330a5f3fe0d367574e56e667a8d06 (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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
{{ partial "header.html" . }}

{{ $section := .Section }}

{{ if and ( ne $section "blog" ) ( ne $section "" ) }}
<div class="main-content content" role="main" itemprop="mainContentOfPage">
	<article class="post">
		<header class="post__header clearfix">
			<h1 class="post__title">{{ .Title }}</h1>
		</header>
		<div class="post__content clearfix">
			{{ if ( eq $section "search" ) }}
				{{ partial "ranklist.html" . }}
				{{ .Content }}
			{{ else }}
				{{ .Content }}
			{{ end }}
		</div>
	</article>
</div>
{{ else }}
	<div class="main-content loop content" role="main">
		{{- if not .IsHome }}
		<header class="page-header">
			<h1 class="page-header__title">{{ .Title }}</h1>
		</header>
		{{- end }}
		{{- range .Pages }}
		<article class="loop__item post clearfix">
			{{- if .Params.thumbnail }}
			<figure class="loop__thumbnail">
				<a href="{{ .Permalink }}">
					<img src="{{ .Params.thumbnail | absURL }}" alt="{{ .Title }}" />
				</a>
			</figure>
			{{- end }}
			<div class="loop__content clearfix">
				<header class="loop__header">
					<h3 class="loop__title post__title ">
						<a href="{{ .Permalink }}" rel="bookmark">{{ .Title }}</a>
					</h3>
					<div class="loop__meta meta">
						<svg class="icon icon-time" height="14" viewBox="0 0 16 16" width="14" xmlns="http://www.w3.org/2000/svg"><path d="m8-.0000003c-4.4 0-8 3.6-8 8 0 4.4000003 3.6 8.0000003 8 8.0000003 4.4 0 8-3.6 8-8.0000003 0-4.4-3.6-8-8-8zm0 14.4000003c-3.52 0-6.4-2.88-6.4-6.4000003 0-3.52 2.88-6.4 6.4-6.4 3.52 0 6.4 2.88 6.4 6.4 0 3.5200003-2.88 6.4000003-6.4 6.4000003zm.4-10.4000003h-1.2v4.8l4.16 2.5600003.64-1.04-3.6-2.1600003z"/></svg>
						<time class="loop__meta-date" datetime="{{ .Date }}">{{.Date.Format "January 02, 2006"}}</time>
						{{- if .Params.categories }}
						<span class="post__meta-categories meta-categories">
							<svg class="icon icon-category" height="16" viewBox="0 0 16 16" width="16" xmlns="http://www.w3.org/2000/svg"><path d="m7 2l1 2h8v11h-16v-13z"/></svg>
							{{ range $index, $category := .Params.categories }}{{ if gt $index 0 }}, {{ end }}<a class="meta-categories__link" href="{{ "/categories/" | relLangURL }}{{ . | urlize | lower }}" rel="category">{{ . }}</a>{{ end }}</span>
						{{- end }}
					</div>
				</header>
				<div class="loop__excerpt post__content">
					{{ .Summary }}
				</div>
				<div class="post__content">
					<a href="{{ .URL }}">View full post</a>
				</div>
			</div>
		</article>
		{{- end }}

		{{ partial "pagination.html" . }}
	</div>
{{ end }}

{{ partial "sidebar.html" . }}
{{ partial "footer.html" . }}