diff options
author | Albin Ahlbäck <albin.ahlback@gmail.com> | 2022-03-31 03:19:06 +0300 |
---|---|---|
committer | Albin Ahlbäck <albin.ahlback@gmail.com> | 2022-04-06 01:15:15 +0300 |
commit | abda70d24a200e78a00ba00bf46e78bc0045e462 (patch) | |
tree | 8d7f2ee082f074d01445e7abfcd9cfe9f4ceb7d1 | |
parent | 10365e0179cfea06c66830dba85c462b36562c82 (diff) |
Add Hugo Grotius as a possible favicon for example site
And add corresponding line to its config and to README.
-rw-r--r-- | README.md | 1 | ||||
-rw-r--r-- | exampleSite/config.toml | 1 | ||||
-rw-r--r-- | exampleSite/static/hugo_grotius.png | bin | 0 -> 17196 bytes | |||
-rw-r--r-- | layouts/partials/head.html | 4 | ||||
-rw-r--r-- | layouts/partials/header.html | 4 |
5 files changed, 5 insertions, 5 deletions
@@ -49,6 +49,7 @@ paginate = 4 [params] author = "Hugo de Groot" siteHeading = "Hugo Grotius" # defaults to author + # favicon = "favicon-gnu.png" # add favorite/URL/tab/shortcut icon showBlogLatest = true mainSections = ["blog"] showTaxonomyLinks = false diff --git a/exampleSite/config.toml b/exampleSite/config.toml index 9aed064..157fd1d 100644 --- a/exampleSite/config.toml +++ b/exampleSite/config.toml @@ -10,6 +10,7 @@ paginate = 4 [params] author = "Hugo de Groot" siteHeading = "Hugo Grotius" # defaults to author + favicon = "hugo_grotius.png" # add favorite/URL/tab/shortcut icon showBlogLatest = true mainSections = ["blog"] showTaxonomyLinks = false diff --git a/exampleSite/static/hugo_grotius.png b/exampleSite/static/hugo_grotius.png Binary files differnew file mode 100644 index 0000000..3f28d68 --- /dev/null +++ b/exampleSite/static/hugo_grotius.png diff --git a/layouts/partials/head.html b/layouts/partials/head.html index ad56e1b..5aa6f64 100644 --- a/layouts/partials/head.html +++ b/layouts/partials/head.html @@ -7,7 +7,9 @@ {{ with resources.Get "css/userstyles.css" }} <link rel="stylesheet" type="text/css" href="{{ .Permalink }}"> {{ end }} - <link rel="icon" href={{ "img/icon.png" | absURL }}> + {{ with .Site.Params.favicon }} + <link rel="icon" href="{{ . | absURL }}"> + {{ end }} <meta charset="UTF-8"> <meta name="author" content="{{ .Site.Params.Author }}"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> diff --git a/layouts/partials/header.html b/layouts/partials/header.html index 6c67a1d..8abd754 100644 --- a/layouts/partials/header.html +++ b/layouts/partials/header.html @@ -3,10 +3,6 @@ <div class="myname"> <h2><a href="{{ default .Site.Home .Site.BaseURL }}">{{ default .Site.Params.Author .Site.Params.siteHeading }}</a></h2> </div> - {{ with .Site.Params.favicon }} - <link rel="icon" type="image/ico" href="{{ . | absURL }}"> - {{ end }} - <nav> <ul class="navbar"> {{- /* info about current page */ -}} |