aboutsummaryrefslogtreecommitdiffstats
path: root/layouts/partials/header.html
blob: 93ebfd17a1e7a0ec518b6900f77f037a37f9a69f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
{{ if .Site.Author.gravataremail }}
    {{ .Scratch.Set "authorPicture" (printf "//www.gravatar.com/avatar/%s" (urlize (md5 (.Site.Author.gravataremail )))) }}
{{ else if .Site.Author.picture }}
    {{ .Scratch.Set "authorPicture" (absURL .Site.Author.picture) }}
{{ end }}

<nav class="dt w-100 border-box pa2">

    <i class="dtc dib v-mid dim fa fa-lg fa-bars"></i>

    <a href="{{ "/" | relLangURL }}" class="dtc v-mid link dim tc">
        <div class="f4 dib black-50">{{ .Site.Title }}</div>
    </a>

    {{ with ($.Scratch.Get "authorPicture") }}
    <a href="/#about" class="dtc dim tr">
        <img class="dib v-mid dib w2 h2 br-100" src="{{ . }}{{ if in . "//www.gravatar.com/avatar/" }}?s=90{{ end }}"/>
    </a>
    {{ end }}
</nav>

<nav id="sidebar" class="w-25-ns ba">
    <div class="tc pv4">
        <a href="/#about" class="">
            {{ with ($.Scratch.Get "authorPicture") }}
            <img class="br-100" src="{{ . }}{{ if in . "//www.gravatar.com/avatar/" }}?s=110{{ end }}"/>
            {{ end }}
            <h3 class="f3">
                {{ .Site.Author.name }}
            </h3>
        </a>
    </div>
</nav>