diff --git a/README.md b/README.md index 763cf99..0e3db84 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ Anubis is a simple minimalist theme for [Hugo blog engine](https://gohugo.io/). - Disqus - Utteranc.es - RSS feeds -* Hiding posts from the RSS feed +- Hiding posts from the RSS feed - Translations (en, ru, fr, pl) - Custom CSS/JS - Multilingual mode @@ -153,10 +153,23 @@ Example: ``` Config like this generate github icon with "https://github.com/gohugoio" url. +#### Predefined icons with custom url +To add prefedined icon with custom url, add to `params.social` config: +- id of social network +- full url to your network + +Example: +``` + - id: github + url: "https://github.com/gohugoio/hugo" +``` +Config like this generate github icon with "https://github.com/gohugoio/hugo" url. + #### Custom icons To add custom icon, add to `params.social` config: - id of social network/site -- full url to your network/site +- full url to your network/site + Also you need to create directory `static/fa-icons` and add svg icon of your network/site with name equals to `id` from config. Example: diff --git a/exampleSite/config.toml b/exampleSite/config.toml index 4ff657b..681db9c 100644 --- a/exampleSite/config.toml +++ b/exampleSite/config.toml @@ -28,6 +28,10 @@ utterancesLabel = "" # optional id = "docs" url = "https://gohugo.io/documentation/" +[[params.social]] +id = "github" +url = "https://github.com/mitrichius/hugo-theme-anubis" + [menu] [[menu.main]] diff --git a/exampleSiteMultilingual/config.toml b/exampleSiteMultilingual/config.toml index 388fcc0..eb3e094 100644 --- a/exampleSiteMultilingual/config.toml +++ b/exampleSiteMultilingual/config.toml @@ -29,6 +29,10 @@ utterancesLabel = "" # optional id = "docs" url = "https://gohugo.io/documentation/" +[[params.social]] +id = "github" +url = "https://github.com/mitrichius/hugo-theme-anubis" + [languages.en] languageName = "English" diff --git a/layouts/partials/social.html b/layouts/partials/social.html index e631c68..10e266e 100644 --- a/layouts/partials/social.html +++ b/layouts/partials/social.html @@ -1,7 +1,13 @@