1
0
Fork 0
mirror of https://git.sr.ht/~seirdy/seirdy.one synced 2024-11-24 05:02:10 +00:00

Remove deprecated ARIA, unused classes

This commit is contained in:
Rohan Kumar 2022-04-06 17:49:25 -07:00
parent aab9356cf2
commit 47106441f7
No known key found for this signature in database
GPG key ID: 1E892DB2A5F84479

View file

@ -3,12 +3,16 @@
{{ $references := `(<section class="footnotes" role="doc-endnotes"> {{ $references := `(<section class="footnotes" role="doc-endnotes">
<hr>)` -}} <hr>)` -}}
{{ $heading := .Params.footnote_heading -}} {{ $heading := .Params.footnote_heading -}}
{{ $referencesWithHeading := printf `<section class="footnotes" role="doc-endnotes" aria-labelledby="note-hd"> {{ $referencesWithHeading := printf `<section role="doc-endnotes" aria-labelledby="note-hd">
<h2 id="note-hd">%s</h2>` ($heading) -}} <h2 id="note-hd">%s</h2>` ($heading) -}}
{{ $endnote := `(role="doc-endnote")` }} {{ $endnote := `(role="doc-endnote")` }}
{{ $noEndnote := printf "" }} {{ $noEndnote := printf "" }}
{{ .Content | replaceRE $references $referencesWithHeading | replaceRE $endnote $noEndnote | safeHTML -}}
{{ $preWithTabIndex := `<pre tabindex="0">` }}
{{ $preWithoutTabIndex := `<pre>` }}
{{ .Content | replaceRE $references $referencesWithHeading | replaceRE $endnote $noEndnote | replaceRE $preWithTabIndex $preWithoutTabIndex | safeHTML -}}
{{ else -}} {{ else -}}
{{ .Content -}} {{ .Content -}}
{{ end -}} {{ end -}}