aboutsummaryrefslogtreecommitdiff
path: root/layouts/_default
diff options
context:
space:
mode:
authorFranck Cuny <franck@fcuny.net>2021-04-22 12:44:27 -0700
committerFranck Cuny <franck@fcuny.net>2021-04-22 12:44:27 -0700
commitfedc092d3229ac87b11f8f22b7d7e170e9bc2e88 (patch)
tree2aef7e597b280e864d64ae0dff01c796b26683d8 /layouts/_default
parenttoml: re-configure markup (diff)
downloadfcuny.net-fedc092d3229ac87b11f8f22b7d7e170e9bc2e88.tar.gz
layout: add a navbar
I want to differentiate blog's entries from more general notes. For this, we create two menu entries, and add a navbar at the top. The nav bar let us select between the two kind of articles: blogs or notes. For now we have a single blog entry, and no notes. The page to list entries is simplified: we use the same layout for all lists (tags, notes, blogs). The CSS is updated to support the new nav bar.
Diffstat (limited to 'layouts/_default')
-rw-r--r--layouts/_default/baseof.html1
-rw-r--r--layouts/_default/list.html8
-rw-r--r--layouts/_default/single.html2
3 files changed, 3 insertions, 8 deletions
diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html
index d9ca51a..3fd7011 100644
--- a/layouts/_default/baseof.html
+++ b/layouts/_default/baseof.html
@@ -3,6 +3,7 @@
{{ partial "head.html" . }}
<body>
<div class="main">
+ {{- partial "header.html" . -}}
<main>
{{ block "main" . }}{{ end }}
</main>
diff --git a/layouts/_default/list.html b/layouts/_default/list.html
index 3423cb6..2b7d98a 100644
--- a/layouts/_default/list.html
+++ b/layouts/_default/list.html
@@ -1,10 +1,6 @@
{{ define "main" }}
-<h1>{{ .Title }}</h1>
-{{ range .Pages.ByPublishDate.Reverse }}
-<p>
- <a class="font-125" href="{{ .RelPermalink }}">{{ .Title }}</a>
-</p>
-{{ end }}
+ {{ $pgs := where .Data.Pages "Params.hidden" "ne" "true" }}
+ {{ partial "postlist" $pgs }}
{{ end }}
diff --git a/layouts/_default/single.html b/layouts/_default/single.html
index 0ab5e35..356f344 100644
--- a/layouts/_default/single.html
+++ b/layouts/_default/single.html
@@ -1,7 +1,5 @@
{{ define "main" }}
-<p><a href="/">&larr; Back to Franck's homepage</a></p>
-
<h1>{{ .Title }}</h1>
<div class="meta">