Add logo image
This commit is contained in:
parent
f7a755e7e0
commit
8a094e628f
2 changed files with 10 additions and 1 deletions
|
@ -23,6 +23,7 @@ theme = "hyde-hyde"
|
|||
dateformat = "Jan 2, 2006"
|
||||
|
||||
# sidebar, copyright & license
|
||||
#logoimage = "/img/hugo.png"
|
||||
copyright = "htr3n"
|
||||
license = "CC BY-SA 4.0"
|
||||
licenseURL = "https://creativecommons.org/licenses/by-sa/4.0"
|
||||
|
|
|
@ -3,7 +3,15 @@
|
|||
<div class="container {{ with .Site.Params.sidebarSticky }}sidebar-sticky{{ end }}">
|
||||
<div class="sidebar-about">
|
||||
<span class="site__title">
|
||||
<a href="{{ .Site.BaseURL }}">{{ .Site.Title }}</a>
|
||||
<a href="{{ .Site.BaseURL }}">
|
||||
{{ with .Site.Params.logoimage }}
|
||||
{{ $strippedSlash := ($.Site.Params.logoimage | replaceRE "^(/)+(.*)" "$2") }}
|
||||
{{ $logoImage := (printf "%s%s" $.Site.BaseURL $strippedSlash) }}
|
||||
<img src="{{$logoImage}}" alt="Logo Image" class="element--center">
|
||||
{{ else }}
|
||||
{{ .Site.Title }}
|
||||
{{ end }}
|
||||
</a>
|
||||
</span>
|
||||
{{ if and (isset .Site.Params "authorimage") (not (isset .Site.Params.social "gravatar")) }}
|
||||
{{ with .Site.Params.authorimage }}
|
||||
|
|
Loading…
Reference in a new issue