Theme Files Update

This commit is contained in:
GitHub Action 2023-09-23 05:03:29 +00:00
parent 7fdf67fab5
commit 559c581dba
5 changed files with 56 additions and 29 deletions

View file

@ -1,34 +1,34 @@
baseURL = "https://1bl4z3r.github.io/hermit-V2/" # baseURL - The absolute URL (protocol, host, path, and trailing slash) of your published site baseURL = "https://1bl4z3r.github.io/hermit-V2/" # baseURL - The absolute URL (protocol, host, path, and trailing slash) of your published site
#[languages] # defaultContentLanguage - Content without language indicator will default to this language.
# [languages.en] defaultContentLanguage = "en"
# title = 'My blog'
# weight = 1
# [languages.en.params]
# linkedin = 'https://linkedin.com/whoever'
# [languages.fr]
# title = 'Mon blogue'
# weight = 2
# [languages.fr.params]
# linkedin = 'https://linkedin.com/fr/whoever'
# [languages.it]
# title = 'Il mio blog'
# weight = 3
# [languages.fr.params]
# linkedin = 'https://linkedin.com/fr/whoever'
[languages]
[languages.en]
title = 'Hugo Hermit - V2'
[languages.en.params]
homeSubtitle = "A minimal and fast theme for Hugo."
weight = 1
[languages.fr]
title = 'Hugo Hermit - V2 (FR)'
[languages.fr.params]
homeSubtitle = "Un thème minimal et rapide pour Hugo."
weight = 2
[languages.it]
title = 'Hugo Hermit - V2 (IT)'
[languages.it.params]
homeSubtitle = "Un tema minimale e veloce per Hugo."
weight = 3
defaultContentLanguageInSubdir = true
# languageCode - A language tag as defined by RFC 5646. This value is used to populate: # languageCode - A language tag as defined by RFC 5646. This value is used to populate:
# The <language> element in the internal RSS template # The <language> element in the internal RSS template
# The lang attribute of the <html> element in the internal alias template # The lang attribute of the <html> element in the internal alias template
languageCode = "en-us" languageCode = "en-us"
# defaultContentLanguage - Content without language indicator will default to this language.
defaultContentLanguage = "en"
# title - Site title # title - Site title
title = "Hugo Hermit - V2" # title = "Hugo Hermit - V2"
# enableGitInfo - Enable .GitInfo object for each page (if the Hugo site is versioned by Git). This will then update the Lastmod parameter for each page using the last git commit date for that content file. # enableGitInfo - Enable .GitInfo object for each page (if the Hugo site is versioned by Git). This will then update the Lastmod parameter for each page using the last git commit date for that content file.
#enableGitInfo = true #enableGitInfo = true
@ -53,6 +53,7 @@ enableEmoji = true
[author] [author]
name = "1BL4Z3R" name = "1BL4Z3R"
about = "about-hugo"
[blackfriday] [blackfriday]
# hrefTargetBlank = true # hrefTargetBlank = true
@ -74,9 +75,9 @@ enableEmoji = true
# images = [""] # images = [""]
themeColor = "#494f5c" themeColor = "#494f5c"
homeSubtitle = "A minimal and fast theme for Hugo." #homeSubtitle = "A minimal and fast theme for Hugo."
footerCopyright = ' &#183; <a href="https://creativecommons.org/licenses/by-nc/4.0/" target="_blank" rel="noopener">CC BY-NC 4.0</a>' footerCopyright = ' <a href="https://creativecommons.org/licenses/by-nc/4.0/" target="_blank" rel="noopener">CC BY-NC 4.0</a>'
# bgImg = "" # Homepage background-image URL # bgImg = "" # Homepage background-image URL
# Prefix of link to the git commit detail page. GitInfo must be enabled. # Prefix of link to the git commit detail page. GitInfo must be enabled.
@ -85,7 +86,7 @@ enableEmoji = true
# Toggling this option needs to rebuild SCSS, requires Hugo extended version # Toggling this option needs to rebuild SCSS, requires Hugo extended version
justifyContent = false # Set "text-align: justify" to `.content`. justifyContent = false # Set "text-align: justify" to `.content`.
relatedPosts = false # Add a related content section to all single posts page relatedPosts = true # Add a related content section to all single posts page
code_copy_button = true # Turn on/off the code-copy-button for code-fields code_copy_button = true # Turn on/off the code-copy-button for code-fields
@ -109,6 +110,12 @@ enableEmoji = true
# You can enable Per-Page MathJax support by adding `mathjax : true` in Page frontmatter # You can enable Per-Page MathJax support by adding `mathjax : true` in Page frontmatter
global_mathjax = false global_mathjax = false
# Toggle Reading time for articles
readTime = true
# Specify Separator between wordCount and readTime
readTimeSeparator = "\u002F||\u005C Reading Time:"
# --------------------------------------------------- # ---------------------------------------------------
# Hugo - V2 specific configurations end # Hugo - V2 specific configurations end
# --------------------------------------------------- # ---------------------------------------------------

View file

@ -0,0 +1,10 @@
{{ if .Site.Params.readTime }}
{{ .Site.Params.readTimeSeparator }}
{{ $rT := mul (div (.WordCount) 220.0) 60 }}
{{ $rTH := math.Floor (div $rT 3600) }}
{{ $rTM := math.Floor (div (mod $rT 3600) 60) }}
{{ $rTS := mod (mod $rT 3600) 60 }}
{{ if gt $rTH 0 }}{{ $rTH }}{{ cond (gt $rTH 1) " Hours" " Hour" }}{{- end -}}
{{ if gt $rTM 0 }}{{ cond (gt $rTH 0) ", " "" }}{{ $rTM }}{{ cond (gt $rTM 1) " Minutes" " Minute" }}{{- end -}}
{{ if gt $rTS 0 }}{{ cond (gt $rTM 0) ", " "" }}{{ $rTS }}{{ cond (gt $rTS 1) " Seconds" " Second" }}{{- end -}}
{{ end }}

View file

@ -46,6 +46,8 @@
<svg xmlns="http://www.w3.org/2000/svg" class="feather" width="24" height="24" fill="none" stroke="currentColor" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M22.428 14.359c-.326 1.678-2.92 3.513-5.9 3.87-1.554.185-3.084.355-4.715.28-2.668-.122-4.773-.637-4.773-.637 0 .26.016.507.048.739.347 2.633 2.61 2.79 4.755 2.864 2.164.074 4.092-.534 4.092-.534l.089 1.957s-1.514.813-4.211.962c-1.487.082-3.334-.037-5.485-.606C1.664 22.019.862 17.047.738 12.002.702 10.504.726 9.092.726 7.91c0-5.159 3.38-6.67 3.38-6.67C5.809.456 8.733.126 11.774.102h.074c3.04.024 5.967.354 7.671 1.136 0 0 3.38 1.512 3.38 6.671 0 0 .043 3.806-.471 6.449"/><path d="M18.912 8.31v6.247h-2.474V8.494c0-1.278-.538-1.927-1.614-1.927-1.19 0-1.785.77-1.785 2.291v3.319h-2.46V8.858c0-1.521-.596-2.29-1.786-2.29-1.075 0-1.613.648-1.613 1.926v6.063H4.705V8.31c0-1.276.325-2.29.978-3.041.674-.75 1.555-1.136 2.65-1.136 1.266 0 2.225.487 2.86 1.46l.616 1.034.616-1.033c.634-.974 1.593-1.46 2.86-1.46 1.094 0 1.976.384 2.65 1.135.652.75.977 1.765.977 3.041"/></svg> <svg xmlns="http://www.w3.org/2000/svg" class="feather" width="24" height="24" fill="none" stroke="currentColor" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M22.428 14.359c-.326 1.678-2.92 3.513-5.9 3.87-1.554.185-3.084.355-4.715.28-2.668-.122-4.773-.637-4.773-.637 0 .26.016.507.048.739.347 2.633 2.61 2.79 4.755 2.864 2.164.074 4.092-.534 4.092-.534l.089 1.957s-1.514.813-4.211.962c-1.487.082-3.334-.037-5.485-.606C1.664 22.019.862 17.047.738 12.002.702 10.504.726 9.092.726 7.91c0-5.159 3.38-6.67 3.38-6.67C5.809.456 8.733.126 11.774.102h.074c3.04.024 5.967.354 7.671 1.136 0 0 3.38 1.512 3.38 6.671 0 0 .043 3.806-.471 6.449"/><path d="M18.912 8.31v6.247h-2.474V8.494c0-1.278-.538-1.927-1.614-1.927-1.19 0-1.785.77-1.785 2.291v3.319h-2.46V8.858c0-1.521-.596-2.29-1.786-2.29-1.075 0-1.613.648-1.613 1.926v6.063H4.705V8.31c0-1.276.325-2.29.978-3.041.674-.75 1.555-1.136 2.65-1.136 1.266 0 2.225.487 2.86 1.46l.616 1.034.616-1.033c.634-.974 1.593-1.46 2.86-1.46 1.094 0 1.976.384 2.65 1.135.652.75.977 1.765.977 3.041"/></svg>
{{- else if (eq .name "rss") -}} {{- else if (eq .name "rss") -}}
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-rss"><path d="M4 11a9 9 0 0 1 9 9"></path><path d="M4 4a16 16 0 0 1 16 16"></path><circle cx="5" cy="19" r="1"></circle></svg> <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-rss"><path d="M4 11a9 9 0 0 1 9 9"></path><path d="M4 4a16 16 0 0 1 16 16"></path><circle cx="5" cy="19" r="1"></circle></svg>
{{- else if (eq .name "author") -}}
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-feather"><path d="M20.24 12.24a6 6 0 0 0-8.49-8.49L5 10.5V19h8.5z"></path><line x1="16" y1="8" x2="2" y2="22"></line><line x1="17.5" y1="15" x2="9" y2="15"></line></svg>
{{- else if (eq .name "scrollup") -}} {{- else if (eq .name "scrollup") -}}
<svg fill="#3B3E48" width="64px" height="64px" viewBox="-2.4 -2.4 28.80 28.80" id="up-circle" data-name="Flat Color" xmlns="http://www.w3.org/2000/svg" class="icon flat-color" stroke="#3B3E48" stroke-width="0.00024000000000000003"><g id="SVGRepo_bgCarrier" stroke-width="0"></g><g id="SVGRepo_tracerCarrier" stroke-linecap="round" stroke-linejoin="round" stroke="#CCCCCC" stroke-width="0.9600000000000002"><circle id="primary" cx="12" cy="12" r="10" style="fill: #3B3E48;"></circle><path id="secondary" d="M15,14a1,1,0,0,1-.71-.29L12,11.41l-2.29,2.3a1,1,0,0,1-1.42-1.42l3-3a1,1,0,0,1,1.42,0l3,3a1,1,0,0,1,0,1.42A1,1,0,0,1,15,14Z" style="fill: #018574;"></path></g><g id="SVGRepo_iconCarrier"><circle id="primary" cx="12" cy="12" r="10" style="fill: #3B3E48;"></circle><path id="secondary" d="M15,14a1,1,0,0,1-.71-.29L12,11.41l-2.29,2.3a1,1,0,0,1-1.42-1.42l3-3a1,1,0,0,1,1.42,0l3,3a1,1,0,0,1,0,1.42A1,1,0,0,1,15,14Z" style="fill: #018574;"></path></g></svg> <svg fill="#3B3E48" width="64px" height="64px" viewBox="-2.4 -2.4 28.80 28.80" id="up-circle" data-name="Flat Color" xmlns="http://www.w3.org/2000/svg" class="icon flat-color" stroke="#3B3E48" stroke-width="0.00024000000000000003"><g id="SVGRepo_bgCarrier" stroke-width="0"></g><g id="SVGRepo_tracerCarrier" stroke-linecap="round" stroke-linejoin="round" stroke="#CCCCCC" stroke-width="0.9600000000000002"><circle id="primary" cx="12" cy="12" r="10" style="fill: #3B3E48;"></circle><path id="secondary" d="M15,14a1,1,0,0,1-.71-.29L12,11.41l-2.29,2.3a1,1,0,0,1-1.42-1.42l3-3a1,1,0,0,1,1.42,0l3,3a1,1,0,0,1,0,1.42A1,1,0,0,1,15,14Z" style="fill: #018574;"></path></g><g id="SVGRepo_iconCarrier"><circle id="primary" cx="12" cy="12" r="10" style="fill: #3B3E48;"></circle><path id="secondary" d="M15,14a1,1,0,0,1-.71-.29L12,11.41l-2.29,2.3a1,1,0,0,1-1.42-1.42l3-3a1,1,0,0,1,1.42,0l3,3a1,1,0,0,1,0,1.42A1,1,0,0,1,15,14Z" style="fill: #018574;"></path></g></svg>
{{- else -}} {{- else -}}

View file

@ -26,8 +26,16 @@
{{- with .Params.description }} {{- with .Params.description }}
<p>{{.}}</p> <p>{{.}}</p>
{{- end }} {{- end }}
{{- with $.Param "author" }}
<p><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-feather"><path d="M20.24 12.24a6 6 0 0 0-8.49-8.49L5 10.5V19h8.5z"></path><line x1="16" y1="8" x2="2" y2="22"></line><line x1="17.5" y1="15" x2="9" y2="15"></line></svg>{{ . }}</p> {{- if and .Params.author .Params.authorLink}}
{{ $relreflink := relref . .Params.authorLink }}
<p>{{ partial "svg.html" (dict "context" . "name" "author") }}<a href="{{ $relreflink }}" target="_blank">{{ .Params.author }}</a></p>
{{- else if .Params.author }}
{{ $relreflink := relref . .Site.Author.about }}
<p>{{ partial "svg.html" (dict "context" . "name" "author") }}<a href="{{ $relreflink }}" target="_blank">{{ .Params.author }}</a></p>
{{- else }}
{{ $relreflink := relref . .Site.Author.about }}
<p>{{ partial "svg.html" (dict "context" . "name" "author") }}<a href="{{ $relreflink }}" target="_blank">{{ .Site.Author.name }}</a></p>
{{- end }} {{- end }}
{{- with .Params.tags }} {{- with .Params.tags }}
<p> <p>
@ -37,7 +45,7 @@
{{- end }} {{- end }}
</p> </p>
{{- end }} {{- end }}
<p><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-file-text"><path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"></path><polyline points="14 2 14 8 20 8"></polyline><line x1="16" y1="13" x2="8" y2="13"></line><line x1="16" y1="17" x2="8" y2="17"></line><polyline points="10 9 9 9 8 9"></polyline></svg>{{ i18n "wordCount" . }}</p> <p><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-file-text"><path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"></path><polyline points="14 2 14 8 20 8"></polyline><line x1="16" y1="13" x2="8" y2="13"></line><line x1="16" y1="17" x2="8" y2="17"></line><polyline points="10 9 9 9 8 9"></polyline></svg>{{ i18n "wordCount" . }} {{ partial "readTime.html" . }}</p>
<p><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-calendar"><rect x="3" y="4" width="18" height="18" rx="2" ry="2"></rect><line x1="16" y1="2" x2="16" y2="6"></line><line x1="8" y1="2" x2="8" y2="6"></line><line x1="3" y1="10" x2="21" y2="10"></line></svg>{{ dateFormat .Site.Params.dateformNumTime .Date.Local }} <p><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-calendar"><rect x="3" y="4" width="18" height="18" rx="2" ry="2"></rect><line x1="16" y1="2" x2="16" y2="6"></line><line x1="8" y1="2" x2="8" y2="6"></line><line x1="3" y1="10" x2="21" y2="10"></line></svg>{{ dateFormat .Site.Params.dateformNumTime .Date.Local }}
{{ if .Lastmod }} {{ if .Lastmod }}
{{ if not (eq .Lastmod .Date ) }} {{ if not (eq .Lastmod .Date ) }}

View file

@ -1,10 +1,10 @@
name = "Hermit-V2" name = "Hermit-V2"
license = "MIT" license = "MIT"
licenselink = "https://github.com/Track3/hermit/blob/master/LICENSE" licenselink = "https://github.com/1bl4z3r/hermit-V2/blob/main/LICENSE"
description = "A minimal and fast hugo theme for bloggers." description = "A minimal and fast hugo theme for bloggers."
homepage = "https://github.com/1bl4z3r/hermit-V2" homepage = "https://github.com/1bl4z3r/hermit-V2"
demosite = "https://1bl4z3r.github.io/hermit-V2/" demosite = "https://1bl4z3r.github.io/hermit-V2/"
tags = ["blog", "minimal", "dark", "responsive", fast] tags = ["blog", "minimal", "dark", "responsive", "fast"]
features = [ features = [
"single column", "single column",
"featured image", "featured image",