site: update pandoc template to fix table of contents style
This commit is contained in:
parent
0710ce9b0e
commit
21ef771a1d
@ -65,19 +65,44 @@ pandocWriterOptions = defaultWriterOptions {
|
|||||||
writerStandalone = True, -- ^ Include header and footer -- needs to be true to have a toc
|
writerStandalone = True, -- ^ Include header and footer -- needs to be true to have a toc
|
||||||
writerTemplate = -- ^ Template to use in standalone mode
|
writerTemplate = -- ^ Template to use in standalone mode
|
||||||
unlines
|
unlines
|
||||||
[ "$if(title)$"
|
[
|
||||||
, "<h1 class=\"title\">$title$</h1>"
|
"$for(include-before)$",
|
||||||
, "$endif$"
|
"$include-before$",
|
||||||
, "$for(include-before)$"
|
"$endfor$",
|
||||||
, "$include-before$"
|
"$if(title)$",
|
||||||
, "$endfor$"
|
"$if(html5)$",
|
||||||
, "$if(toc)$"
|
"<header>",
|
||||||
, "$toc$"
|
"$else$",
|
||||||
, "$endif$"
|
"<div id=\"$idprefix$header\">",
|
||||||
, "$body$"
|
"$endif$",
|
||||||
, "$for(include-after)$"
|
"<h1 class=\"title\">$title$</h1>",
|
||||||
, "$include-after$"
|
"$for(author)$",
|
||||||
, "$endfor$"
|
"<h3 class=\"author\">$author$</h3>",
|
||||||
|
"$endfor$",
|
||||||
|
"$if(date)$",
|
||||||
|
"<h4 class=\"date\">$date$</h4>",
|
||||||
|
"$endif$",
|
||||||
|
"$if(html5)$",
|
||||||
|
"</header>",
|
||||||
|
"$else$",
|
||||||
|
"</div>",
|
||||||
|
"$endif$",
|
||||||
|
"$endif$",
|
||||||
|
"$if(toc)$",
|
||||||
|
"$if(html5)$",
|
||||||
|
"<nav id=\"$idprefix$TOC\">",
|
||||||
|
"$toc$",
|
||||||
|
"</nav>",
|
||||||
|
"$else$",
|
||||||
|
"<div id=\"$idprefix$TOC\">",
|
||||||
|
"$toc$",
|
||||||
|
"</div>",
|
||||||
|
"$endif$",
|
||||||
|
"$endif$",
|
||||||
|
"$body$",
|
||||||
|
"$for(include-after)$",
|
||||||
|
"$include-after$",
|
||||||
|
"$endfor$"
|
||||||
],
|
],
|
||||||
-- writerVariables = [], -- ^ Variables to set in template
|
-- writerVariables = [], -- ^ Variables to set in template
|
||||||
-- writerIncludeBefore = "", -- ^ Text to include before the body
|
-- writerIncludeBefore = "", -- ^ Text to include before the body
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user