Welcome to mirror list, hosted at ThFree Co, Russian Federation.

single.html « _default « layouts - github.com/capnfabs/paperesque.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: c96e7a5e4299291f37fb3b2dcf7a85a64ed707a1 (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
34
35
36
37
38
39
40
41
42
43
44
{{ define "body-classes" -}}
  {{ if .Draft }}draft{{ end }} look-sheet-bkg
{{- end }}

{{ define "breadcrumbs" }}
  {{- if not .Parent.IsHome -}}
  <span class="divider">/ </span>
  <a href="{{ .Site.BaseURL  }}{{ .CurrentSection.Type }}">{{.CurrentSection.Name}}</a>
  {{- end -}}
{{ end }}

{{ define "content" }}
{{- partial "single-article" . -}}
{{ end }}

{{ define "footer" }}

<!-- TODO: right now, this gets weird when there's a big title on the right.
There might be better info here: https://stackoverflow.com/questions/34995740/css-when-inline-block-elements-line-break-parent-wrapper-does-not-fit-new-width
and you can test on the android-development-developer-productivity article.

Would also be cool to make this fold on mobile so there's two links on separate lines.
-->
  {{if (or .PrevInSection .NextInSection) }}
    <div class="nav-bkg-50 content-container-narrow-pad bottom-links text-0p75">
      <nav class="flex-row">
      {{if .PrevInSection}}
      <a href="{{.PrevInSection.Permalink}}" class="flex-row v-center no-underline"  style="max-width:45%;">
        <span class="text-1p5">←</span>&nbsp;<span class="re-underline">Previous: {{ .PrevInSection.Title }}</span>
      </a>
      {{else}}
        <span class="flex-row v-center"></span>
      {{end}}
      {{if .NextInSection}}
        <a href="{{.NextInSection.Permalink}}" class="flex-row v-center no-underline" style="max-width: 45%;">
        <span class="re-underline">Next: {{.NextInSection.Title}}</span>&nbsp;<span class="text-1p5">→</span>
        </a>
      {{else}}
        <span class="flex-row v-center"></span>
      {{end}}
      </nav>
    </div>
  {{ end }}
{{ end }}