Overwrite theme default logo to dynamically set text based on page relative directory
This commit is contained in:
parent
84c18e6370
commit
2b9d84b7c8
16
Jafner.dev/layouts/partials/logo.html
Normal file
16
Jafner.dev/layouts/partials/logo.html
Normal file
@ -0,0 +1,16 @@
|
||||
<a href="{{ if .Site.Params.Logo.LogoHomeLink }}{{ .Site.Params.Logo.LogoHomeLink }}{{ else }}{{ .Site.BaseURL | relLangURL }}{{ end }}" style="text-decoration: none;">
|
||||
<div class="logo">
|
||||
{{ if .Site.Params.Logo.path }}
|
||||
<img src="{{ .Site.Params.Logo.path }}" alt="{{ .Site.Params.Logo.alt }}" />
|
||||
{{ else }}
|
||||
<span class="logo__mark" style="font-size: 18px">{{ with .Site.Params.Logo.logoMark }}{{ . }}{{ else }}>{{ end }}</span>
|
||||
<span class="logo__text {{ with.Site.Params.Logo.logoCursorPathname}}logo__pathname{{ end }}">
|
||||
{{ with .RelPermalink }}{{ . }}{{ else }}Jafner.dev{{ end }}</span>
|
||||
<span class="logo__cursor" style=
|
||||
"{{ with.Site.Params.Logo.logoCursorDisabled }}visibility:hidden;{{ end }}
|
||||
{{ with.Site.Params.Logo.logoCursorColor }}background-color:{{ . }};{{ end }}
|
||||
{{ with.Site.Params.Logo.logoCursorAnimate }}animation-duration:{{ . }};{{ end }}">
|
||||
</span>
|
||||
{{ end }}
|
||||
</div>
|
||||
</a>
|
Loading…
Reference in New Issue
Block a user