From fba5befbf5b9cb9b9026b8f6af7f6c5444e1a8f5 Mon Sep 17 00:00:00 2001 From: Dimitar Trendafilov Date: Thu, 4 Oct 2018 15:15:57 +0300 Subject: Squashed 'website/themes/base16/' content from commit 7b2da73 git-subtree-dir: website/themes/base16 git-subtree-split: 7b2da739c813cd680e44606d2150e3c66a6794e6 --- layouts/404.html | 16 ++++++++++++ layouts/_default/list.html | 8 ++++++ layouts/_default/single.html | 7 ++++++ layouts/index.html | 5 ++++ layouts/partials/article-list-item.html | 12 +++++++++ layouts/partials/article.html | 30 ++++++++++++++++++++++ layouts/partials/footer.html | 10 ++++++++ layouts/partials/header.html | 34 +++++++++++++++++++++++++ layouts/partials/hero.html | 13 ++++++++++ layouts/partials/homepage.html | 44 +++++++++++++++++++++++++++++++++ 10 files changed, 179 insertions(+) create mode 100644 layouts/404.html create mode 100644 layouts/_default/list.html create mode 100644 layouts/_default/single.html create mode 100644 layouts/index.html create mode 100644 layouts/partials/article-list-item.html create mode 100644 layouts/partials/article.html create mode 100644 layouts/partials/footer.html create mode 100644 layouts/partials/header.html create mode 100644 layouts/partials/hero.html create mode 100644 layouts/partials/homepage.html (limited to 'layouts') diff --git a/layouts/404.html b/layouts/404.html new file mode 100644 index 0000000..2340809 --- /dev/null +++ b/layouts/404.html @@ -0,0 +1,16 @@ +{{ partial "header.html" . }} + +
+ +

+ [404] + # _ +

+ +

+ not found +

+ +
+ +{{ partial "footer.html" . }} diff --git a/layouts/_default/list.html b/layouts/_default/list.html new file mode 100644 index 0000000..cf5b2b2 --- /dev/null +++ b/layouts/_default/list.html @@ -0,0 +1,8 @@ +{{ partial "header.html" . }} +
+

{{ .Title }}

+ {{ range .Data.Pages }} + {{ partial "article-list-item.html" . }} + {{ end }} +
+{{ partial "footer.html" . }} diff --git a/layouts/_default/single.html b/layouts/_default/single.html new file mode 100644 index 0000000..b9ff539 --- /dev/null +++ b/layouts/_default/single.html @@ -0,0 +1,7 @@ +{{ partial "header.html" . }} + +
+ {{ partial "article.html" . }} +
+ +{{ partial "footer.html" . }} diff --git a/layouts/index.html b/layouts/index.html new file mode 100644 index 0000000..2744d98 --- /dev/null +++ b/layouts/index.html @@ -0,0 +1,5 @@ +{{ partial "header.html" . }} + +{{ partial "homepage.html" . }} + +{{ partial "footer.html" . }} diff --git a/layouts/partials/article-list-item.html b/layouts/partials/article-list-item.html new file mode 100644 index 0000000..10b8fce --- /dev/null +++ b/layouts/partials/article-list-item.html @@ -0,0 +1,12 @@ +
+

{{ .Title }}{{ if .Draft }} (Draft){{ end }}

+
+{{ if not .Date.IsZero }} + published on + +{{ end }} +
+
+ {{ .Summary }} {{ if .Truncated }} Read More...{{ end }} +
+
diff --git a/layouts/partials/article.html b/layouts/partials/article.html new file mode 100644 index 0000000..c69a76f --- /dev/null +++ b/layouts/partials/article.html @@ -0,0 +1,30 @@ +{{ $page := .Page }} +
+
+{{ if not .Page.Date.IsZero }} + published on + +{{ end }} +{{ with .Params.categories }} + {{ if $page.Date.IsZero }}published {{ end }}in + +{{ range . }} + {{ . }} +{{ end }} + +{{ end }} +{{ with .Params.tags }} +
+ tags: + +{{ range . }} + {{ . }} +{{ end }} + +{{ end }} +
+

{{ .Title }}

+
+ {{ .Content }} +
+
diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html new file mode 100644 index 0000000..13b47a3 --- /dev/null +++ b/layouts/partials/footer.html @@ -0,0 +1,10 @@ + + + + + + diff --git a/layouts/partials/header.html b/layouts/partials/header.html new file mode 100644 index 0000000..715808c --- /dev/null +++ b/layouts/partials/header.html @@ -0,0 +1,34 @@ + + + + + +{{- with $.Param "keywords" }} + +{{- end }} +{{- with $.Param "author" }} + +{{- end }} +{{ .Hugo.Generator }} + + + + +{{ $isHomePage := eq .Title .Site.Title }}{{ .Title }}{{ if eq $isHomePage false }} - {{ .Site.Title }}{{ end }} + + + +
+
+ [{{ .Site.Title }}] + # _ +
+ {{ range $i, $page := (where .Site.Pages "Section" "pages") }} + {{ if not (eq $i 0) }}|{{ end }} + {{ $page.Title }} + {{ end }} +
+
+
+ +
diff --git a/layouts/partials/hero.html b/layouts/partials/hero.html new file mode 100644 index 0000000..a1580ed --- /dev/null +++ b/layouts/partials/hero.html @@ -0,0 +1,13 @@ +{{ $baseurl := .Site.BaseURL }} +

+ [base16] + # _ +

+ + + +
+ Add your own "layouts/partials/hero.html" to replace this text. +
diff --git a/layouts/partials/homepage.html b/layouts/partials/homepage.html new file mode 100644 index 0000000..cdbc78e --- /dev/null +++ b/layouts/partials/homepage.html @@ -0,0 +1,44 @@ +{{ $baseurl := .Site.BaseURL }} +
+ + {{ partial "hero.html" . }} + +

Recent Posts

+ +
+ {{ range first 3 (where .Data.Pages "Section" "post") }} + {{ partial "article-list-item.html" . }} + {{ end }} +
+ +{{ with .Site.Taxonomies.categories }} + +

Categories

+ +
+ {{ range $name, $value := . }} +

+ {{ title $name }} + ({{ .Count }}) +

+ {{ end }} +
+ +{{ end }} + +{{ with .Site.Taxonomies.tags }} + +

Tags

+ +
+ {{ range $name, $value := . }} + + {{ $name }} + ({{ .Count }}) + + {{ end }} +
+ +{{ end }} + +
-- cgit v1.3.1-26-gb76a