Merge pull request #11 from dwarkeshsp/master

Allows adding link to the citation in the epigraph
This commit is contained in:
slashformotion 2021-08-02 08:57:05 +02:00 committed by GitHub
commit 3d14a3cc3e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 14 additions and 6 deletions

View file

@ -1,6 +1,6 @@
<header class="brand"> <header class="brand">
<h1>{{ .Site.Title}}</h1> <a href="{{ .Site.BaseURL }}"><h1>{{ .Site.Title}}</h1></a>
<h2>{{ .Site.Params.subtitle }}</h2> <h2>{{ .Site.Params.subtitle }}</h2>
{{ partial "nav.html" . }} {{ partial "nav.html" . }}
<hr> <hr />
</header> </header>

View file

@ -5,7 +5,9 @@
{{ if .IsNamedParams }} {{ if .IsNamedParams }}
<footer> <footer>
{{ with .Get "pre" }}{{ . }}{{ end }} {{ with .Get "pre" }}{{ . }}{{ end }}
{{ with .Get "link" }}<a href={{ . }}>{{ end }}
{{ with .Get "cite" }}<cite>{{ . }}</cite>{{ end }} {{ with .Get "cite" }}<cite>{{ . }}</cite>{{ end }}
</a>
{{ with .Get "post" }}{{ . }}{{ end }} {{ with .Get "post" }}{{ . }}{{ end }}
</footer> </footer>
{{ end }} {{ end }}

View file

@ -1,6 +1,12 @@
{{ $marginnoteDomIdSuffix := .Ordinal }} {{ $marginnoteDomIdSuffix := .Ordinal }}
<label for="marginnote-{{.Page.File.UniqueID}}-{{ $marginnoteDomIdSuffix }}"> <label
class="margin-toggle">&#8853; for="marginnote-{{.Page.File.UniqueID}}-{{ $marginnoteDomIdSuffix }}"
class="margin-toggle"
>&#8853;
</label> </label>
<input type="checkbox" id="marginnote-{{.Page.File.UniqueID}}-{{ $marginnoteDomIdSuffix }}" class="margin-toggle" /> <input
type="checkbox"
id="marginnote-{{.Page.File.UniqueID}}-{{ $marginnoteDomIdSuffix }}"
class="margin-toggle"
/>
<span class="marginnote">{{ .Inner }}</span> <span class="marginnote">{{ .Inner }}</span>