Add table of contents folded at top of page

This commit is contained in:
Akbar Rahman 2021-10-21 18:08:09 +01:00
parent 0d2889252c
commit e0471c8508
Signed by: alvierahman90
GPG Key ID: 20609519444A1269
3 changed files with 10 additions and 7 deletions

View File

@ -203,7 +203,8 @@ def main(args):
f'--template={args.template}', f'--template={args.template}',
'-V', f'filehistory={filehistory}', '-V', f'filehistory={filehistory}',
'-V', f'licenseFull={notes_license}', '-V', f'licenseFull={notes_license}',
'--mathjax' '--mathjax',
'--toc'
]) ])
pathlib.Path(output_filename).parent.mkdir(parents=True, exist_ok=True) pathlib.Path(output_filename).parent.mkdir(parents=True, exist_ok=True)

View File

@ -45,10 +45,6 @@ summary > * {
display: inline display: inline
} }
li {
margin-bottom: 1em;
}
img, video { img, video {
margin: 0 auto; margin: 0 auto;
display: block; display: block;

View File

@ -10,7 +10,7 @@
<body> <body>
<div id="header"> <div id="header">
<p style="font-size: 0.7em"> tags: [ <p class="smallText"> tags: [
$for(tags)$ $for(tags)$
<a href="/.tags/$tags$.html">$tags$</a>$sep$, <a href="/.tags/$tags$.html">$tags$</a>$sep$,
$endfor$ $endfor$
@ -37,6 +37,12 @@
</summary> </summary>
<pre>$licenseFull$</pre> <pre>$licenseFull$</pre>
</details> </details>
<div> <details>
<summary class="smallText"> Table of Contents </summary>
<div>$toc$</div>
</details>
</div>
<div id="content">
$body$ $body$
</div>
</body> </body>