about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorAlan Pearce2024-02-18 12:09:15 +0000
committerAlan Pearce2024-02-18 12:09:15 +0000
commit555ff8a5656cf9fc160de3ec19bc827f6e5da9b7 (patch)
tree651f4e22ce35a2bd9111aa57a5181195f067a4bf
parent69c601b5ebd3d386e9a4256d4e285ae8f5b0c80a (diff)
parenta423677c42b7a3f755ee5c2ba434ed77ef6f6b99 (diff)
downloadzola-bearblog-555ff8a5656cf9fc160de3ec19bc827f6e5da9b7.tar.lz
zola-bearblog-555ff8a5656cf9fc160de3ec19bc827f6e5da9b7.tar.zst
zola-bearblog-555ff8a5656cf9fc160de3ec19bc827f6e5da9b7.zip
Merge pull request 'Add Home to extra.main_menu so it can be translated on the multilingual websites' (#8) from dobrvlskyi/zola-bearblog:main-menu into main
Reviewed-on: https://codeberg.org/alanpearce/zola-bearblog/pulls/8
-rw-r--r--README.md4
-rw-r--r--config.toml4
-rw-r--r--templates/nav.html1
3 files changed, 8 insertions, 1 deletions
diff --git a/README.md b/README.md
index db77233..7ebe80b 100644
--- a/README.md
+++ b/README.md
@@ -46,6 +46,10 @@ Create an array in `extra` with a key of `main_menu`. `url` is passed to [`get_u
 
 ```toml
 [[extra.main_menu]]
+name = "Home"
+url = "/"
+
+[[extra.main_menu]]
 name = "Bear"
 url = "@/bear.md"
 
diff --git a/config.toml b/config.toml
index 78e9f9a..bd675af 100644
--- a/config.toml
+++ b/config.toml
@@ -23,6 +23,10 @@ date_format="%d %b, %Y"
 webserver_sends_csp_headers=true
 
 [[extra.main_menu]]
+name = "Home"
+url = "/"
+
+[[extra.main_menu]]
 name = "Bear"
 url = "@/bear.md"
 
diff --git a/templates/nav.html b/templates/nav.html
index e18fda2..a71652e 100644
--- a/templates/nav.html
+++ b/templates/nav.html
@@ -1,4 +1,3 @@
-<a href="{{ config.base_url }}">Home</a>
 {%- if config.extra.main_menu %}
   {%- for item in config.extra.main_menu %}
     {%- if item.url is matching("https?://") %}