diff options
author | Calin Tataru <calintat@gmail.com> | 2019-10-06 03:12:00 +0300 |
---|---|---|
committer | Calin Tataru <calintat@gmail.com> | 2019-10-06 03:12:00 +0300 |
commit | 2662c63c6c4d06b548f146941dcbf8081cb5d230 (patch) | |
tree | 91eb9a57d4cf45af258d117db94d695c7836d36a | |
parent | 6bc3f62cb1314511f272b2e6871a8afde4cab201 (diff) |
Add different layout for pages like about
-rw-r--r-- | layouts/_default/single.html | 11 | ||||
-rw-r--r-- | layouts/page/single.html | 11 |
2 files changed, 21 insertions, 1 deletions
diff --git a/layouts/_default/single.html b/layouts/_default/single.html index 7a6ba5f..cc4aa29 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -2,7 +2,16 @@ <main> - {{ partial "list-item" . }} + {{ .Date.Format (.Site.Params.dateFormat | default "January 2, 2006") | $.Scratch.Set "subtitle" }} + {{ with .Description }} {{ $.Scratch.Set "subtitle" . }} {{ end }} + + <div class="item"> + <h2>{{ .Title }}</h2> + <h5>{{ $.Scratch.Get "subtitle" }}</h5> + {{ range .Params.tags }} + <a href="{{ $.Site.BaseURL }}tags/{{ . | urlize }}"><kbd class="item-tag">{{ . }}</kbd></a> + {{ end }} + </div> <br> <div class="text-justify">{{ .Content }}</div> diff --git a/layouts/page/single.html b/layouts/page/single.html new file mode 100644 index 0000000..463fcf2 --- /dev/null +++ b/layouts/page/single.html @@ -0,0 +1,11 @@ +{{ partial "header" . }} + +<main> + + <h2>{{ .Title }}</h2> + + <br> <div class="text-justify">{{ .Content }}</div> + +</main> + +{{ partial "footer.html" . }} |