diff options
author | Jan Raasch <jan@janraasch.com> | 2020-08-31 15:40:11 +0200 |
---|---|---|
committer | Jan Raasch <jan@janraasch.com> | 2020-09-03 20:22:23 +0200 |
commit | 58805381571574f39ff3ddeaf98f64d708486ca7 (patch) | |
tree | c0c73917c2f507a505e993a3fd368f5ad4fd046a /layouts/partials | |
download | hugo-bearcub-58805381571574f39ff3ddeaf98f64d708486ca7.tar.gz hugo-bearcub-58805381571574f39ff3ddeaf98f64d708486ca7.tar.bz2 |
chore: initial commit
Diffstat (limited to 'layouts/partials')
-rw-r--r-- | layouts/partials/custom_body.html | 3 | ||||
-rw-r--r-- | layouts/partials/custom_head.html | 3 | ||||
-rw-r--r-- | layouts/partials/favicon.html | 2 | ||||
-rw-r--r-- | layouts/partials/footer.html | 1 | ||||
-rw-r--r-- | layouts/partials/head.html | 14 | ||||
-rw-r--r-- | layouts/partials/header.html | 4 | ||||
-rw-r--r-- | layouts/partials/nav.html | 5 | ||||
-rw-r--r-- | layouts/partials/seo_tags.html | 13 | ||||
-rw-r--r-- | layouts/partials/style.html | 99 |
9 files changed, 144 insertions, 0 deletions
diff --git a/layouts/partials/custom_body.html b/layouts/partials/custom_body.html new file mode 100644 index 0000000..951fb15 --- /dev/null +++ b/layouts/partials/custom_body.html @@ -0,0 +1,3 @@ + <!-- A partial to be overwritten by the user. + Simply place a custom_body.html into + your local /layouts/partials-directory --> diff --git a/layouts/partials/custom_head.html b/layouts/partials/custom_head.html new file mode 100644 index 0000000..4c53c40 --- /dev/null +++ b/layouts/partials/custom_head.html @@ -0,0 +1,3 @@ +<!-- A partial to be overwritten by the user. + Simply place a custom_head.html into + your local /layouts/partials-directory --> diff --git a/layouts/partials/favicon.html b/layouts/partials/favicon.html new file mode 100644 index 0000000..ccf1a5d --- /dev/null +++ b/layouts/partials/favicon.html @@ -0,0 +1,2 @@ +{{ with .Site.Params.favicon }} +<link rel="shortcut icon" href="{{ . | absURL }}" />{{ end }} diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html new file mode 100644 index 0000000..8eca955 --- /dev/null +++ b/layouts/partials/footer.html @@ -0,0 +1 @@ +{{ if ne .Site.Params.hideMadeWithLine true }}Made with <a href="https://github.com/janraasch/hugo-bearblog/">Hugo ʕ•ᴥ•ʔ Bear</a>{{ end }} diff --git a/layouts/partials/head.html b/layouts/partials/head.html new file mode 100644 index 0000000..69488a7 --- /dev/null +++ b/layouts/partials/head.html @@ -0,0 +1,14 @@ +<meta http-equiv="X-Clacks-Overhead" content="GNU Terry Pratchett" /> +<meta charset="utf-8"> +<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0,user-scalable=0" /> +{{- partial "favicon.html" . -}} +<title>{{- block "title" . }}{{ .Site.Title }}{{- end }}</title> + +{{- partial "seo_tags.html" . -}} +<meta name="referrer" content="no-referrer-when-downgrade" /> + +{{ with .OutputFormats.Get "rss" -}} +{{ printf `<link rel="%s" type="%s" href="%s" title="%s" />` .Rel .MediaType.Type .Permalink $.Site.Title | safeHTML }} +{{ end -}} + +{{- partial "style.html" . -}} diff --git a/layouts/partials/header.html b/layouts/partials/header.html new file mode 100644 index 0000000..e47df70 --- /dev/null +++ b/layouts/partials/header.html @@ -0,0 +1,4 @@ +<a href="{{ "/" | relURL }}" class="title"> + <h2>{{ .Site.Title }}</h2> +</a> +<nav>{{- partial "nav.html" . -}}</nav> diff --git a/layouts/partials/nav.html b/layouts/partials/nav.html new file mode 100644 index 0000000..dd06f47 --- /dev/null +++ b/layouts/partials/nav.html @@ -0,0 +1,5 @@ +<a href="{{ "/" | relURL }}">Home</a> +{{ range .Site.Menus.main }} +<a href="{{ .URL }}">{{ .Name }}</a> +{{ end }} +<a href="{{ "/blog" | relURL }}">Blog</a> diff --git a/layouts/partials/seo_tags.html b/layouts/partials/seo_tags.html new file mode 100644 index 0000000..0b01f8b --- /dev/null +++ b/layouts/partials/seo_tags.html @@ -0,0 +1,13 @@ +<!-- Primary Meta Tags --> +<meta name="title" content="{{ with .Title }}{{ . }}{{ else }}{{ .Site.Title }}{{ end }}" /> +<meta name="description" content="{{ with .Description }}{{ . }}{{ else }}{{if .IsPage}}{{ .Summary }}{{ else }}{{ with .Site.Params.description }}{{ . }}{{ end }}{{ end }}{{ end }}" /> +<meta name="keywords" content="{{ if .IsPage}}{{ range $index, $tag := .Params.tags }}{{ $tag }},{{ end }}{{ else }}{{ range $plural, $terms := .Site.Taxonomies }}{{ range $term, $val := $terms }}{{ printf "%s," $term }}{{ end }}{{ end }}{{ end }}" /> + +<!-- Open Graph / Facebook --> +{{ template "_internal/opengraph.html" . }} + +<!-- Twitter --> +{{ template "_internal/twitter_cards.html" . }} + +<!-- Microdata --> +{{ template "_internal/schema.html" . }} diff --git a/layouts/partials/style.html b/layouts/partials/style.html new file mode 100644 index 0000000..d429eb2 --- /dev/null +++ b/layouts/partials/style.html @@ -0,0 +1,99 @@ +<style> + body { + font-family: Verdana, sans-serif; + margin: auto; + padding: 20px; + max-width: 720px; + text-align: left; + background-color: white; + word-wrap: break-word; + overflow-wrap: break-word; + line-height: 1.5; + color: #444; + } + + h1, + h2, + h3, + h4, + h5, + h6, + strong, + b { + color: #222; + } + + a { + color: #3273dc; + } + + .title { + text-decoration: none; + border: 0; + } + + .title span { + font-weight: 400; + } + + nav a { + margin-right: 10px; + } + + textarea { + width: 100%; + font-size: 16px; + } + + input { + font-size: 16px; + } + + content { + line-height: 1.6; + } + + table { + width: 100%; + } + + img { + max-width: 100%; + } + + code { + padding: 2px 5px; + background-color: #eee; + } + + pre code { + border-left: 1px solid #999; + color: #555; + display: block; + padding: 10px; + white-space: pre-wrap; + } + + blockquote { + border-left: 1px solid #999; + color: #555; + padding-left: 10px; + font-style: italic; + } + + footer { + padding: 25px; + text-align: center; + } + + .helptext { + color: #777; + font-size: small; + } + + .errorlist { + color: #eba613; + font-size: small; + } + +</style> |