Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/wlh320/hugo-theme-hulga.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'layouts/archives/single.html')
-rw-r--r--layouts/archives/single.html30
1 files changed, 14 insertions, 16 deletions
diff --git a/layouts/archives/single.html b/layouts/archives/single.html
index 18ce343..9cec5f7 100644
--- a/layouts/archives/single.html
+++ b/layouts/archives/single.html
@@ -4,7 +4,6 @@
<body>
<div id="main">
- {{- partial "nav.html" . -}}
{{- partial "header.html" . -}}
<section class="section">
{{- block "archives-main" . }}{{- end }}
@@ -19,22 +18,21 @@
{{ define "archives-main" }}
<div class="container">
- <div class="box section">
- <div class="content">
- <p>本博客共 {{len (where (where .Site.Pages "Type" "post") "Kind" "page")}} 篇博文</p>
- <div class="post-archive">
- {{ range (where (where .Site.Pages "Type" "post") "Kind" "page").GroupByDate "2006" }}
- <h2>{{ .Key }}</h2>
- <ul class="listing">
- {{ range .Pages }}
- <li>
- <span class="date">{{ .Date.Format "2006/01/02" }} </span>
- <a href="{{ .Permalink }}" title="{{ .Title }}">{{ .Title }}</a>
- </li>
- {{ end }}
- </ul>
+ <div class="box content">
+ {{ $count := len (where (where .Site.Pages "Type" "post") "Kind" "page") }}
+ <p>{{ i18n "archives" (dict "Count" $count) }}</p>
+ <div class="post-archive">
+ {{ range (where (where .Site.Pages "Type" "post") "Kind" "page").GroupByDate "2006" }}
+ <h2>{{ .Key }}</h2>
+ <ul class="listing">
+ {{ range .Pages }}
+ <li>
+ <span class="date">{{ .Date.Format "2006/01/02" }} </span>
+ <a href="{{ .Permalink }}" title="{{ .Title }}">{{ .Title }}</a>
+ </li>
{{ end }}
- </div>
+ </ul>
+ {{ end }}
</div>
</div>
</div>