diff --git a/layouts/article/single.html b/layouts/article/single.html index 049b03a..b86ed9d 100644 --- a/layouts/article/single.html +++ b/layouts/article/single.html @@ -1,43 +1,19 @@ {{ define "header" }}{{ partial "page-header.html" . }}{{ end }} {{ define "main" }} -{{ $currentPageUrl := .URL }} - -
- +

{{ humanize .Section | upper }}

-

+

{{ .Title }}

- - - {{ if .Params.tags }} -
- {{ $name := index .Params.tags 0 }} - {{ $name := $name | urlize }} - {{ $tags := index .Site.Taxonomies.tags $name }} - - -
- {{end}} - -
- Last Update: {{ .Lastmod.Format "January 2, 2006" }} -
- + + {{ partial "tags.html" . }}
{{ end }} diff --git a/layouts/partials/site-header.html b/layouts/partials/site-header.html index a49b62e..6b6c4a7 100755 --- a/layouts/partials/site-header.html +++ b/layouts/partials/site-header.html @@ -3,7 +3,9 @@
{{ partial "site-navigation.html" .}}
-

{{ .Title | default .Site.Title }}

+

+ {{ .Title | default .Site.Title }} +

{{ if .Params.description }}

{{ .Params.description }} @@ -17,7 +19,9 @@
{{ partial "site-navigation.html" . }}
-

{{ .Title | default .Site.Title }}

+

+ {{ .Title | default .Site.Title }} +

{{ if .Params.description }}

{{ .Params.description }} diff --git a/layouts/partials/tags.html b/layouts/partials/tags.html new file mode 100644 index 0000000..5aadec7 --- /dev/null +++ b/layouts/partials/tags.html @@ -0,0 +1,22 @@ +{{ $currentPageUrl := .URL }} +{{ if .Params.tags }} +
+ {{ $name := index .Params.tags 0 }} + {{ $name := $name | urlize }} + {{ $tags := index .Site.Taxonomies.tags $name }} +
    +
  • + Related: +
  • + {{ range $tags.Pages }} + {{ if ne .URL $currentPageUrl }} +
  • + + {{ .LinkTitle }} + +
  • + {{ end }} + {{end}} +
+
+{{end}} diff --git a/layouts/section/article.html b/layouts/section/article.html index e0ba09a..eb651f2 100644 --- a/layouts/section/article.html +++ b/layouts/section/article.html @@ -1,17 +1,16 @@ {{ define "main" }} -
{{ .Content }}
- {{ $section := .Paginate (where .Data.Pages "Section" .Section) 5 }} + {{ $section := .Paginate (where .Data.Pages "Section" .Section) }}
{{ range sort $section.Pages "Date" "desc" }} {{ .Render "summary" }} {{ end }}
-{{ template "_internal/pagination.html" . }} + {{ template "_internal/pagination.html" . }}
{{ end }}