aboutsummaryrefslogtreecommitdiff
path: root/views/gril.html
blob: 776f14f2bb75939bd9c5e93f6acbb5546f0d4e6d (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
68
69
70
71
72
73
74
75
76
77
{{ define "gril" }}
{{ $gril := .gril }}
<html>
        <head>
				{{ template "materialize" }}
                <title>grilist</title>
				<link rel="stylesheet" href="/assets/css/gril.css" />
                <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no">
        </head>
        <body>
			{{ template "navbar" . }}
			<div class="container">
				<h1 id="gril-title">{{ $gril.RomajiName }}<small>{{ $gril.KanjiName }}</small></h1>
				{{ if $gril.OtherNames }}
				<p id="gril-alias">Auch bekannt als:
					{{ range $i, $alias := $gril.OtherNames }}{{ if $i }},{{ end }}
						{{ $alias }}{{ end }}
				</p>
				{{ end }}
				<div class="row center-align">
					<img src="/{{ $gril.ImagePath false }}" />
				</div>
				{{ range $tag := $gril.Tags }}
				<a href="/tag/{{ $tag }}"
				   alt="Mit &quot;{{ $tag }}&quot; getaggte Grils einsehen"
					 title="Mit &quot;{{ $tag }}&quot; getaggte Grils einsehen">
					<div class="chip gril-tag">
						{{ $tag }}
					</div>
				</a>
				{{ end }}
				<br />
				<br />
				<div class="row">
				{{ if $gril.Birthday.Valid }}
				<div class="col s6 m2 l2">
					<div class="card">
						<div class="card-content purple-text text-lighten-2 center-align">
							<span class="card-title big">{{ $gril.Birthday.Value}}</span>
								<p>Geburtstag</p>
						</div>
					</div>
				</div>
				{{ else if $gril.Age.Valid }}
				<div class="col s6 m2 l2">
					<div class="card">
						<div class="card-content purple-text text-lighten-2 center-align">
							<span class="card-title big">{{ $gril.Age.Value }}</span>
								<p>Jahre alt</p>
						</div>
					</div>
				</div>
				{{ end }}
				{{ if $gril.Lists }}
				<div class="col s6 m2 l2">
					<div class="card">
						<div class="card-content center-big purple-text text-lighten-2 center-align">
							<p>in</p>
							<span class="card-title big">{{ len $gril.Lists}}</span>
							<p>Liste{{ if ne (len $gril.Lists) 1 }}n{{ end }}</p>
						</div>
					</div>
				</div>
				{{ end }}
				<div class="col s12 m4 l4">
					<div class="card">
						<div class="card-content purple-text text-lighten-2 center-align">
							<span class="card-title big">{{ $gril.UpdatedAt.Format "Jan 02, 2006" }}</span>
								<p>aktualisiert</p>
						</div>
					</div>
				</div>
				</div>
			</div>
        </body>
</html>
{{ end }}