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

github.com/qqhann/hugo-primer.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorQiushi Pan <qiu.gits@gmail.com>2018-11-30 21:53:45 +0300
committerQiushi Pan <qiu.gits@gmail.com>2018-11-30 21:53:45 +0300
commit60c8bd49401f1e0fc1c4461308c7ea9279100851 (patch)
tree553eadd230ed7182e4a54eaf83269d571dfc4a5b
parentf49a70804e27bea940e0edb774c46be774bffb07 (diff)
Update: single page to show taxtonomy behind title
-rw-r--r--layouts/_default/single.html23
1 files changed, 22 insertions, 1 deletions
diff --git a/layouts/_default/single.html b/layouts/_default/single.html
index 194e9fc..35c51ba 100644
--- a/layouts/_default/single.html
+++ b/layouts/_default/single.html
@@ -5,8 +5,29 @@
{{ define "main" }}
+<!-- Title -->
+<div class="Subhead">
+ <div class="Subhead-heading">
+ <div class="h1 mt-3 mb-1">{{ .Title }}</div>
+ </div>
+ <div class="Subhead-description">
+ <!-- categories -->
+ {{ with .Params.Categories }}{{ range . }}
+ <a href='{{ "/categories/" | relLangURL }}{{ . | urlize }}' class="muted-link">
+ <span class="Label Label--gray">{{ . }}</span>
+ </a>
+ {{ end }}{{ end }}
+ <!-- tags -->
+ {{ with .Params.Tags }}{{ range . }}
+ <a href='{{ "/tags/" | relLangURL }}{{ . | urlize }}' class="muted-link">
+ <span class="Label Label--outline">{{ . }}</span>
+ </a>
+ {{ end }}{{ end }}
+ <span>{{ .Date.Format "2006-01-01" }}</span>
+ </div>
+</div>
<article>
- <h1>{{ .Title }}</h1>
+ <!-- Content -->
<section>
{{ .Content }}
</section>