Merge pull request #9 from damacus/make-logo-configurable

Make logo configurable
This commit is contained in:
Robert Austin 2019-04-15 20:29:44 +10:00 committed by GitHub
commit c679e0b497
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 4 deletions

View file

@ -34,4 +34,8 @@ pygmentsUseClasses = true
meta_og_description = "Hugo Whisper is a documentation theme built with Hugo." meta_og_description = "Hugo Whisper is a documentation theme built with Hugo."
meta_twitter_card = "summary" meta_twitter_card = "summary"
meta_twitter_site = "@zerostaticio" meta_twitter_site = "@zerostaticio"
meta_twitter_creator = "@zerostaticio" meta_twitter_creator = "@zerostaticio"
[params.logo]
mobile = "/images/logo-mobile.svg"
standard = "/images/logo.svg"

View file

@ -1,12 +1,12 @@
<div class='header'> <div class='header'>
<div class="container"> <div class="container">
<div class="logo"> <div class="logo">
<a href="{{ .Site.BaseURL }}"><img alt="Logo" src="{{ "images/logo.svg" | absURL }}" /></a> <a href="{{ .Site.BaseURL }}"><img alt="Logo" src="{{ .Site.Params.logo.standard | relURL }}" /></a>
</div> </div>
<div class="logo-mobile"> <div class="logo-mobile">
<a href="{{ .Site.BaseURL }}"><img alt="Logo" src="{{ "images/logo-mobile.svg" | absURL }}" /></a> <a href="{{ .Site.BaseURL }}"><img alt="Logo" src="{{ .Site.Params.logo.mobile | relURL }}" /></a>
</div> </div>
{{ partial "main-menu.html" . }} {{ partial "main-menu.html" . }}
{{ partial "hamburger.html" . }} {{ partial "hamburger.html" . }}
</div> </div>
</div> </div>