73 lines
1.7 KiB
HTML
73 lines
1.7 KiB
HTML
|
{{ define "main" }}
|
||
|
<div class=blogarticle>
|
||
|
<div class=blogarticlehead>
|
||
|
<div class=blogarticletitle>
|
||
|
<h1>{{ .Title }}</h1>
|
||
|
</div>
|
||
|
<div class=blogarticleinfos>
|
||
|
{{ if isset .Params "categories" }}
|
||
|
<span class=categories>
|
||
|
{{ $catlen := (len .Params.categories) }}
|
||
|
{{ if (gt $catlen 0) }}
|
||
|
{{ if (gt $catlen 1) }}
|
||
|
Dans les catégories
|
||
|
{{ else }}
|
||
|
Dans la catégorie
|
||
|
{{ end }}
|
||
|
{{ range $index, $element := .Params.categories }}
|
||
|
<a class=category href="/categories/{{ $element | urlize }}">{{ $element }}</a>
|
||
|
{{ if (not (eq (add $index 1) $catlen)) }}
|
||
|
,
|
||
|
{{ end }}
|
||
|
{{ end }}
|
||
|
{{ end }}
|
||
|
</span>
|
||
|
<span name=separator> - </span>
|
||
|
{{ end }}
|
||
|
{{ if isset .Params "tags" }}
|
||
|
<span class=tags>
|
||
|
{{ $taglen := (len .Params.tags) }}
|
||
|
{{ if (gt $taglen 0) }}
|
||
|
{{ if (gt $taglen 1) }}
|
||
|
Avec les tags
|
||
|
{{ else }}
|
||
|
Avec le tag
|
||
|
{{ end }}
|
||
|
{{ range $index, $element := .Params.tags }}
|
||
|
<a class=tag href="/tags/{{ $element | urlize }}">{{ $element }}</a>
|
||
|
{{ if (not (eq (add $index 1) $taglen)) }}
|
||
|
,
|
||
|
{{ end }}
|
||
|
{{ end }}
|
||
|
{{ end }}
|
||
|
</span>
|
||
|
<span name=separator> - </span>
|
||
|
{{ end }}
|
||
|
{{ if isset .Params "authors" }}
|
||
|
<span class=authors>
|
||
|
Fait par
|
||
|
{{ $len := (len .Params.authors) }}
|
||
|
{{ range $index, $element := .Params.authors }}
|
||
|
<a href="/authors/{{ (lower $element) | urlize }}/"><span class=author>{{ $element }}</span></a>
|
||
|
{{ if (not (eq (add $index 1) $len)) }}
|
||
|
et
|
||
|
{{ end }}
|
||
|
|
||
|
{{ end }}
|
||
|
</span>
|
||
|
<span name=separator> - </span>
|
||
|
{{ end }}
|
||
|
<time class=date>
|
||
|
{{.Date.Format "2006-01-02"}}
|
||
|
</time>
|
||
|
</div>
|
||
|
</div>
|
||
|
<div class=blogarticlecontent>
|
||
|
{{ .Content }}
|
||
|
</div>
|
||
|
<div class=blogarticlecomments>
|
||
|
|
||
|
</div>
|
||
|
</div>
|
||
|
{{ end }}
|