hugo-tufte/layouts/shortcodes/marginnote.html

8 lines
376 B
HTML
Raw Normal View History

2023-04-15 16:31:10 +02:00
{{- $marginnoteDomIdSuffix := (add .Ordinal 1) -}}
{{- $ind := .Get "ind" | default .Site.Params.marginNoteInd -}}
<label for="marginnote-{{ $marginnoteDomIdSuffix }}" class="margin-toggle marginnote-ind">{{ $ind }}</label>
<input type="checkbox" id="marginnote-{{ $marginnoteDomIdSuffix }}" class="margin-toggle"/>
<span class="marginnote">
{{ .Inner | markdownify}}
</span>