From 6ef98c48a45504459a36c05402787a86bd0eafd5 Mon Sep 17 00:00:00 2001 From: Joshua Goins Date: Tue, 23 Aug 2022 12:53:11 -0400 Subject: [PATCH] Add sidebar navigation --- config.toml | 56 ++++++++++++++++++++++++ content/_index.md | 6 +-- themes/red/layouts/_default/baseof.html | 1 + themes/red/layouts/partials/sidebar.html | 7 +++ 4 files changed, 65 insertions(+), 5 deletions(-) create mode 100644 themes/red/layouts/partials/sidebar.html diff --git a/config.toml b/config.toml index df0dada..a120cc6 100644 --- a/config.toml +++ b/config.toml @@ -2,3 +2,59 @@ baseURL = 'http://example.org/' languageCode = 'en-us' title = '~redstrate' theme = 'red' + +[menu] + [[menu.main]] + identifier = 'home' + name = 'Home' + url = '/' + weight = -1 + + [[menu.main]] + identifier = 'blog' + name = 'Blog' + url = '/blog' + weight = 1 + + [[menu.main]] + identifier = 'art' + name = 'Art' + url = '/art' + weight = 2 + + [[menu.main]] + identifier = 'photos' + name = 'Photos' + url = '/photos' + weight = 3 + + [[menu.main]] + identifier = 'music' + name = 'Music' + url = '/music' + weight = 4 + + [[menu.main]] + identifier = 'projects' + name = 'Projects' + url = '/projects' + weight = 6 + + [[menu.main]] + identifier = 'downloads' + name = 'Downloads' + url = '/downloads' + weight = 7 + + [[menu.main]] + identifier = 'extra' + name = 'Extras' + url = '/extra' + weight = 8 + + [[menu.main]] + identifier = 'about' + name = 'About' + url = '/about' + weight = 9 + diff --git a/content/_index.md b/content/_index.md index c9ccace..b8115ad 100644 --- a/content/_index.md +++ b/content/_index.md @@ -1,5 +1 @@ -See my [gallery](/art)! - -See my [photos](/photos)! - -See my [about page](/about)! +Welcome to my personal corner of the Internet! diff --git a/themes/red/layouts/_default/baseof.html b/themes/red/layouts/_default/baseof.html index 5dc4b24..e6812d0 100644 --- a/themes/red/layouts/_default/baseof.html +++ b/themes/red/layouts/_default/baseof.html @@ -3,6 +3,7 @@ {{- partial "head.html" . -}} {{- partial "header.html" . -}} + {{- partial "sidebar.html" . -}} {{- block "main" . }}{{- end }} {{- partial "footer.html" . -}} diff --git a/themes/red/layouts/partials/sidebar.html b/themes/red/layouts/partials/sidebar.html new file mode 100644 index 0000000..120687a --- /dev/null +++ b/themes/red/layouts/partials/sidebar.html @@ -0,0 +1,7 @@ + \ No newline at end of file