mirror of
https://github.com/thomasjsn/hugo-theme-hello-friend.git
synced 2024-12-26 15:57:38 +01:00
Merge pull request #36 from mpaepper/master
Added ReadingTime indication to give the reader an idea of the read t…
This commit is contained in:
commit
f234269325
@ -67,6 +67,8 @@ paginate = 5
|
||||
defaultTheme = "dark"
|
||||
# if you set this to 0, only submenu trigger will be visible
|
||||
showMenuItems = 2
|
||||
# Enable to show reading time in minutes for posts
|
||||
showReadingTime = false
|
||||
|
||||
[languages]
|
||||
[languages.en]
|
||||
@ -80,6 +82,7 @@ paginate = 5
|
||||
readOtherPosts = "Read other posts"
|
||||
newerPosts = "Newer posts"
|
||||
olderPosts = "Older posts"
|
||||
minuteReadingTime = "min read"
|
||||
|
||||
[languages.en.params.logo]
|
||||
logoText = "hello friend"
|
||||
|
@ -12,8 +12,12 @@
|
||||
{{ .Date.Format "2006-01-02" }}
|
||||
</span>
|
||||
{{ with .Params.Author }}<span class="post-author">— {{ $.Site.Params.WrittenBy | default "Written by" }} {{ . }}</span>{{ end }}
|
||||
{{ if $.Site.Params.ShowReadingTime }}
|
||||
<span class="post-read-time">— ⏰ {{ .ReadingTime }} {{ $.Site.Params.MinuteReadingTime | default "min read" }}</span>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
|
||||
{{ if .Params.tags }}
|
||||
<span class="post-tags">
|
||||
{{ range .Params.tags }}
|
||||
|
@ -8,6 +8,9 @@
|
||||
</span>
|
||||
{{ end }}
|
||||
{{ with .Params.Author }}<span class="post-author">— {{ $.Site.Params.WrittenBy | default "Written by" }} {{ . }}</span>{{ end }}
|
||||
{{ if $.Site.Params.ShowReadingTime }}
|
||||
<span class="post-read-time">— ⏰ {{ .ReadingTime }} {{ $.Site.Params.MinuteReadingTime | default "min read" }}</span>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
{{ if .Params.tags }}
|
||||
|
Loading…
Reference in New Issue
Block a user