diff options
author | Michael Hunteman <michael@huntm.net> | 2023-03-07 10:36:03 -0600 |
---|---|---|
committer | Michael Hunteman <michael@huntm.net> | 2023-03-07 10:36:03 -0600 |
commit | 544136925ffe8ebac3b729a9c86ac7a1d2bfb814 (patch) | |
tree | a10226275979ee7aff41d25a7787feabf7da70e0 /layouts |
Initial commit
Diffstat (limited to 'layouts')
-rw-r--r-- | layouts/.DS_Store | bin | 0 -> 6148 bytes | |||
-rw-r--r-- | layouts/_default/list.html | 12 | ||||
-rw-r--r-- | layouts/_default/single.html | 10 | ||||
-rw-r--r-- | layouts/index.html | 15 | ||||
-rw-r--r-- | layouts/partials/footer.html | 13 | ||||
-rw-r--r-- | layouts/partials/head.html | 8 | ||||
-rw-r--r-- | layouts/partials/header.html | 12 |
7 files changed, 70 insertions, 0 deletions
diff --git a/layouts/.DS_Store b/layouts/.DS_Store Binary files differnew file mode 100644 index 0000000..ca4fb0a --- /dev/null +++ b/layouts/.DS_Store diff --git a/layouts/_default/list.html b/layouts/_default/list.html new file mode 100644 index 0000000..03d3faf --- /dev/null +++ b/layouts/_default/list.html @@ -0,0 +1,12 @@ +{{ partial "head.html" . }} +{{ partial "header.html" . }} + +<main> + <ul> + {{ range .Pages }} + <li><a href="{{ .Permalink }}">{{.Date.Format "Jan 2, 2006"}} - {{ .Name }}</a></li> + {{ end }} + </ul> +</main> + +{{ partial "footer.html" . }} diff --git a/layouts/_default/single.html b/layouts/_default/single.html new file mode 100644 index 0000000..5788c52 --- /dev/null +++ b/layouts/_default/single.html @@ -0,0 +1,10 @@ +{{ partial "head.html" . }} +{{ partial "header.html" . }} + +<main> + <article> + {{ .Content }} + </article> +</main> + +{{ partial "footer.html" . }} diff --git a/layouts/index.html b/layouts/index.html new file mode 100644 index 0000000..2384984 --- /dev/null +++ b/layouts/index.html @@ -0,0 +1,15 @@ +{{ partial "head.html" . }} +{{ partial "header.html" . }} +<main> + {{ .Content }} + <hr /> + <h2>Recent Posts</h2> + <ul> + {{ range (where .Site.Pages "Section" "blog") }} + {{ range .Pages }} + <li><a href="{{ .Permalink }}">{{.Date.Format "Jan 2, 2006"}} - {{ .Name }}</a></li> + {{ end }} + {{ end }} + </ul> +</main> +{{ partial "footer.html" . }} diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html new file mode 100644 index 0000000..1226f49 --- /dev/null +++ b/layouts/partials/footer.html @@ -0,0 +1,13 @@ +<footer> + <hr /> + <nav> + <ul class="links"> + {{ range .Site.Menus.footer }} + <li><a href="{{ .URL }}">{{ .Name }}</a></li> + {{ end }} + </ul> + </nav> + <hr /> + Site content is <a href="https://creativecommons.org/licenses/by-sa/4.0/">CC-BY-SA</a>. + Projects are <a href="https://www.gnu.org/licenses/gpl-3.0.en.html">GNU GPL</a>. +</footer> diff --git a/layouts/partials/head.html b/layouts/partials/head.html new file mode 100644 index 0000000..c862011 --- /dev/null +++ b/layouts/partials/head.html @@ -0,0 +1,8 @@ +<!DOCTYPE html> +<html lang="en"> +<head> + <meta charset="utf-8"/> + <meta name="viewport" content="width=device-width, initial-scale=1.0"/> + <link rel="stylesheet" type="text/css" href="{{ .Site.BaseURL }}/style.css"/> + <title>{{ .Title }}</title> +</head> diff --git a/layouts/partials/header.html b/layouts/partials/header.html new file mode 100644 index 0000000..2b68b32 --- /dev/null +++ b/layouts/partials/header.html @@ -0,0 +1,12 @@ +<header> + <h1>{{ .Title }}</h1> + <hr /> + <nav> + <ul class="links"> + {{ range .Site.Menus.header }} + <li><a href="{{ .URL }}">{{ .Name }}</a></li> + {{ end }} + </ul> + </nav> + <hr /> +</header> |