Compare commits

...

2 Commits

Author SHA1 Message Date
eb02e1e6b0 Fix broken link 2019-12-24 15:30:12 -08:00
b2fc6ea5a8 Add numbered sidenotes 2019-12-09 23:11:28 -08:00
2 changed files with 10 additions and 1 deletions

View File

@ -10,7 +10,7 @@ I found that __sidenotes__ were a feature that I didn't even know I needed.
A lot of my writing seems to use small parenthesized remarks (like this), which,
although it doesn't break the flow in a grammatical sense, lengthens the
sentence, and makes it harder to follow. Since I do my best to write content
to help explain stuff (like the [compiler series]({{ relref "00_compiler_intro.md" }})),
to help explain stuff (like the [compiler series]({{< relref "00_compiler_intro.md" >}})),
making sentences __more__ difficult to understand is a no-go.
So, what do they look like?

View File

@ -0,0 +1,9 @@
{{ .Page.Scratch.Add "numbernote-id" 1 }}
{{ $id := .Page.Scratch.Get "numbernote-id" }}
<span class="sidenote">
<label class="sidenote-label" for="numbernote-{{ $id }}">({{ $id }})</label>
<input class="sidenote-checkbox" type="checkbox" id="numbernote-{{ $id }}"></input>
<span class="sidenote-content sidenote-{{ .Get 0 }}">
{{ .Inner }}
</span>
</span>