Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/pravin/hugo-theme-prav.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPravin Paratey <pravin@paratey.com>2020-04-29 17:32:44 +0300
committerPravin Paratey <pravin@paratey.com>2020-04-29 17:32:44 +0300
commit117ed6d64460e656b03932a803156d9a01a17949 (patch)
tree976b02b33705220a76e02674bec1e810ec6f87e4
parentd29f910825bb6266f91d1401f7b9c1c31454b4d4 (diff)
Easier to add author image and blurb to the sidebar
-rw-r--r--exampleSite/config.toml26
-rw-r--r--layouts/partials/sidebar.html10
2 files changed, 19 insertions, 17 deletions
diff --git a/exampleSite/config.toml b/exampleSite/config.toml
index cc02bd1..0d74ace 100644
--- a/exampleSite/config.toml
+++ b/exampleSite/config.toml
@@ -14,24 +14,26 @@ pygmentsStyle = "perldoc"
# The settings below are used throughout the theme.
# Please update!
[params]
- title = "Hugo Theme - Prav"
- tagline = "Lorem ipsum dolor sit amet, consectetur adipiscing elit."
- author = "Pravin Paratey"
+ title = "Hugo Theme - Prav"
+ tagline = "Lorem ipsum dolor sit amet, consectetur adipiscing elit."
+ author = "Pravin Paratey"
+ authorImgPath = "/img/author.png"
+ authorBlurb = "Something about me"
# If you do not want a social icon, just comment it out
# Please update the example values!
[social]
- email = "mailto:example@example.com"
- facebook = "https://www.facebook.com/example"
- twitter = "http://twitter.com/example"
- medium = "https://www.medium.com/@example"
- github = "https://github.com/example"
- linkedin = "http://uk.linkedin.com/in/example"
+ email = "mailto:example@example.com"
+ facebook = "https://www.facebook.com/example"
+ twitter = "http://twitter.com/example"
+ medium = "https://www.medium.com/@example"
+ github = "https://github.com/example"
+ linkedin = "http://uk.linkedin.com/in/example"
# Set unsafe mode to allow markdownify to work with goldmark
# This is important. Please do not delete. It is used to re-render markdown
[markup]
- [markup.goldmark]
- [markup.goldmark.renderer]
- unsafe = true \ No newline at end of file
+ [markup.goldmark]
+ [markup.goldmark.renderer]
+ unsafe = true \ No newline at end of file
diff --git a/layouts/partials/sidebar.html b/layouts/partials/sidebar.html
index 09db687..e0c99e0 100644
--- a/layouts/partials/sidebar.html
+++ b/layouts/partials/sidebar.html
@@ -4,8 +4,8 @@
<a name="about"></a>
<h3>About Me</h3>
<div style="text-align: center;">
- <img src="/img/author.png" alt="{{ .Site.Params.Author }}" class="pure-img" />
- <p><em>{{ .Site.Params.Tagline }}</em></p>
+ <img src="{{ .Site.Params.AuthorImgPath }}" alt="{{ .Site.Params.Author }}" class="pure-img" />
+ <p><em>{{ .Site.Params.AuthorBlurb }}</em></p>
</div>
<h3>Latest Articles</h3>
@@ -22,11 +22,11 @@
</div>
<h3>Categories</h3>
- <div style="text-align:center">
+ <div style="text-align:center" class="tags">
{{ range $.Site.Taxonomies.tags.ByCount }}
{{ if gt .Count 1 }}
- <button href="/tags/{{ .Name }}" class="pure-button pure-button-primary"> {{ .Name }}
- <small>({{ .Count }})</small></button>
+ <a href="/tags/{{ .Name }}" class="pure-button"> {{ .Name }}
+ <small>({{ .Count }})</small></a>
{{ end }}
{{end}}
</div>