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/_default/taxonomy.html')
-rw-r--r--layouts/_default/taxonomy.html35
1 files changed, 35 insertions, 0 deletions
diff --git a/layouts/_default/taxonomy.html b/layouts/_default/taxonomy.html
new file mode 100644
index 0000000..a528fe6
--- /dev/null
+++ b/layouts/_default/taxonomy.html
@@ -0,0 +1,35 @@
+{{ define "main" }}
+{{- partial "header.html" . -}}
+<!-- {{- partial "posts.html" . -}} -->
+<section class="section">
+ <div class="container">
+ <div class="content">
+ {{ if eq .Data.Singular "category" }}
+ <h3>
+ 分类
+ <span class="tag mytag">{{ .Data.Term }}</span>
+ 中的文章
+ </h3>
+ {{ else if eq .Data.Singular "tag" }}
+ <h3>
+ 包含标签
+ <span class="tag mytag"><a>{{ .Data.Term }}</a></span>
+ 的文章
+ </h3>
+ {{ end }}
+ </div>
+ <div class="post-lists">
+ {{ $paginator := .Paginate (where .Data.Pages "Type" "post") }}
+ {{ range $paginator.Pages }}
+ <div class="one-post box">
+ <div class="is-6">{{ .Date.Format "2006/01/02" }}</div>
+ <div><a href="{{.Permalink }}" class="title is-size-5">{{ .Title }}</a></div>
+ </div>
+ {{ end }}
+ {{ partial "paginator.html" . }}
+ </div>
+
+ </div>
+</section>
+
+{{ end }}