blob: 280fa3d44274088fd22e64843992bb661ecb2a21 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
{{define "logs_display"}}
<article>
{{ range .Logs }}
<article>
<h2><a href="/log/{{ .Slug }}">{{ .Title }}</a></h2>
<figure>
<a href="/log/{{ .Slug }}"><img src="{{ static .Img.Src }}" alt="{{ .Img.Alt }}"></a>
<figcaption>{{ .Img.Legend }}</figcaption>
</figure>
<p>{{ .Description }}</p>
</article>
{{ end }}
{{ if ne .PagesNumber 1 }}
<div class="pagination">
<nav>
{{ if ne .CurrentPage 1 }}<a href="?page={{ before .CurrentPage }}">Précédent</a>{{else}}<p></p>{{end}}
<p>{{ .CurrentPage }}/{{ .PagesNumber }}</p>
{{ if ne .CurrentPage .PagesNumber }}<a href="?page={{ next .CurrentPage }}">Suivant</a>{{else}}<p></p>{{end}}
</nav>
</div>
{{ end }}
</article>
{{end}}
|