Refond la page d’accueil
This commit is contained in:
56
themes/default/layouts/partials/home-hero.html
Normal file
56
themes/default/layouts/partials/home-hero.html
Normal file
@@ -0,0 +1,56 @@
|
||||
{{- $logo := .Logo -}}
|
||||
{{- $title := .Title -}}
|
||||
{{- $description := .Description -}}
|
||||
{{- $content := .Content -}}
|
||||
{{- $total := .TotalArticles -}}
|
||||
{{- $sectionsCount := .SectionsCount -}}
|
||||
{{- $lastUpdated := .LastUpdated -}}
|
||||
{{- $menu := .HeroMenu -}}
|
||||
<section id="hero">
|
||||
<header>
|
||||
{{- with $logo -}}
|
||||
<figure>
|
||||
<img src="{{ .RelPermalink }}" alt="Logo de {{ $title }}" />
|
||||
</figure>
|
||||
{{- end -}}
|
||||
<div>
|
||||
<h1>{{ $title }}</h1>
|
||||
{{- with $description }}
|
||||
<div class="site-description">{{ . }}</div>
|
||||
{{- end }}
|
||||
</div>
|
||||
</header>
|
||||
|
||||
{{- with $content }}
|
||||
<div>
|
||||
{{ . }}
|
||||
</div>
|
||||
{{- end }}
|
||||
|
||||
<ul>
|
||||
<li>
|
||||
<strong>Articles publiés</strong>
|
||||
<span>{{ $total }}</span>
|
||||
</li>
|
||||
<li>
|
||||
<strong>Thématiques</strong>
|
||||
<span>{{ $sectionsCount }}</span>
|
||||
</li>
|
||||
<li>
|
||||
<strong>Dernière mise à jour</strong>
|
||||
<time datetime="{{ $lastUpdated | time.Format "2006-01-02" }}">{{ $lastUpdated | time.Format "02/01/2006" }}</time>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<hr class="hr-mirror">
|
||||
|
||||
{{- with $menu }}
|
||||
<nav>
|
||||
{{- range . }}
|
||||
<a href="{{ .URL }}" title="{{ .Title }}">{{ .Name }}</a>
|
||||
{{- end }}
|
||||
</nav>
|
||||
{{- end }}
|
||||
|
||||
<hr />
|
||||
</section>
|
||||
Reference in New Issue
Block a user