aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZach Berwaldt <zberwaldt@tutamail.com>2023-09-27 21:50:42 -0400
committerZach Berwaldt <zberwaldt@tutamail.com>2023-09-27 21:50:42 -0400
commitb179606dac7cf36c490512146ad8ce898f7800b2 (patch)
tree5cdc1d48161bcb0bb2c3a4fe06e3bcd4cf14cd51
parentf7ccee9be8569eb2efc2319554e49757f550c77f (diff)
theme tweaks
-rw-r--r--archetypes/post.md3
-rw-r--r--assets/css/main.css6
-rw-r--r--layouts/_default/list.html19
-rw-r--r--layouts/_default/single.html4
-rw-r--r--layouts/_default/summary.html2
-rw-r--r--layouts/partials/head.html2
-rw-r--r--layouts/post/single.html16
7 files changed, 34 insertions, 18 deletions
diff --git a/archetypes/post.md b/archetypes/post.md
index 7b017b9..d62ae73 100644
--- a/archetypes/post.md
+++ b/archetypes/post.md
@@ -1,3 +1,4 @@
1--- 1---
2title: "{{ replace .File.ContentBaseName "-" " " | title }}" 2title: "{{ replace .File.ContentBaseName "-" " " | title }}"
3--- \ No newline at end of file 3date: {{ .Date }}
4---
diff --git a/assets/css/main.css b/assets/css/main.css
index e49a669..934e91b 100644
--- a/assets/css/main.css
+++ b/assets/css/main.css
@@ -50,4 +50,8 @@ footer {
50 width: 100%; 50 width: 100%;
51 padding: 1rem; 51 padding: 1rem;
52 text-align: center; 52 text-align: center;
53} \ No newline at end of file 53}
54
55.post {
56 margin-bottom: 1em;
57}
diff --git a/layouts/_default/list.html b/layouts/_default/list.html
index cf36155..a86ef3a 100644
--- a/layouts/_default/list.html
+++ b/layouts/_default/list.html
@@ -1,10 +1,21 @@
1{{ define "main" }} 1{{ define "main" }}
2 <article> 2 <article>
3 <section>{{- .Content -}}</section> 3 <h1>{{ .Title }}</h1>
4 <section> 4 <section>
5 {{ range .Paginator.Pages }} 5 {{ range sort (.Paginator 3).Pages "Date" "desc" }}
6 <div> 6 <div>{{ .Render "summary" }}</div>
7 {{ .Render "summary" }} 7 {{ end }}
8 {{ with .Paginator }}
9 <div class="grid">
10 <div class='flex'>
11 {{ if .HasPrev }}
12 <a href="{{ .Prev.URL }}">prev</a>
13 {{ end }}
14 <p>{{ .PageNumber }} of {{ .TotalPages }}</p>
15 {{ if .HasNext }}
16 <a href="{{ .Next.URL }}">next</a>
17 {{ end }}
18 </div>
8 </div> 19 </div>
9 {{ end }} 20 {{ end }}
10 </section> 21 </section>
diff --git a/layouts/_default/single.html b/layouts/_default/single.html
index db0c449..1564845 100644
--- a/layouts/_default/single.html
+++ b/layouts/_default/single.html
@@ -1,10 +1,10 @@
1{{ define "main" }} 1{{ define "main" }}
2 <article> 2 <article>
3 <section> 3 <section>
4 <h1>{{ .Title }}</h1> 4 <h1>{{- .Title -}}</h1>
5 </section> 5 </section>
6 <section> 6 <section>
7 {{- .Content -}} 7 {{- .Content -}}
8 </section> 8 </section>
9 </article> 9 </article>
10{{ end }} \ No newline at end of file 10{{ end }}
diff --git a/layouts/_default/summary.html b/layouts/_default/summary.html
index 6ae4fd0..0753995 100644
--- a/layouts/_default/summary.html
+++ b/layouts/_default/summary.html
@@ -1,4 +1,4 @@
1<div> 1<div class='post' style="margin-bottom: 2em;">
2 <div> 2 <div>
3 <h1 class="f3 near-black"> 3 <h1 class="f3 near-black">
4 <a href="{{ .RelPermalink }}" class="link black dim"> 4 <a href="{{ .RelPermalink }}" class="link black dim">
diff --git a/layouts/partials/head.html b/layouts/partials/head.html
index dbc55b1..d7b2381 100644
--- a/layouts/partials/head.html
+++ b/layouts/partials/head.html
@@ -9,4 +9,4 @@
9 {{- template "_internal/opengraph.html" . -}} 9 {{- template "_internal/opengraph.html" . -}}
10 {{- template "_internal/schema.html" . -}} 10 {{- template "_internal/schema.html" . -}}
11 {{- template "_internal/twitter_cards.html" . -}} 11 {{- template "_internal/twitter_cards.html" . -}}
12</head> \ No newline at end of file 12</head>
diff --git a/layouts/post/single.html b/layouts/post/single.html
index 306df48..432b9df 100644
--- a/layouts/post/single.html
+++ b/layouts/post/single.html
@@ -1,11 +1,11 @@
1{{ define "main" }} 1{{ define "main" }}
2 <article> 2<article>
3 <section> 3 <section>
4 <h1>{{ .Title }}</h1> 4 <h1>{{ .Title }}</h1>
5 <h6>{{ .Date | time.Format ":date_full" }}</h6> 5 <h6>{{ .Date | time.Format ":date_full" }}</h6>
6 </section> 6 </section>
7 <section> 7 <section>
8 {{- .Content -}} 8 {{- .Content -}}
9 </section> 9 </section>
10 </article> 10</article>
11{{ end }} \ No newline at end of file 11{{ end }}