From 21ef771a1d3d1387f9c062189b5aff39b859704d Mon Sep 17 00:00:00 2001 From: Simon Michael Date: Sat, 1 Oct 2011 17:09:13 +0000 Subject: [PATCH] site: update pandoc template to fix table of contents style --- site/hakyll.hs | 51 +++++++++++++++++++++++++++++++++++++------------- 1 file changed, 38 insertions(+), 13 deletions(-) diff --git a/site/hakyll.hs b/site/hakyll.hs index 71b413811..6eb8df5d9 100644 --- a/site/hakyll.hs +++ b/site/hakyll.hs @@ -65,19 +65,44 @@ pandocWriterOptions = defaultWriterOptions { writerStandalone = True, -- ^ Include header and footer -- needs to be true to have a toc writerTemplate = -- ^ Template to use in standalone mode unlines - [ "$if(title)$" - , "

$title$

" - , "$endif$" - , "$for(include-before)$" - , "$include-before$" - , "$endfor$" - , "$if(toc)$" - , "$toc$" - , "$endif$" - , "$body$" - , "$for(include-after)$" - , "$include-after$" - , "$endfor$" + [ + "$for(include-before)$", + "$include-before$", + "$endfor$", + "$if(title)$", + "$if(html5)$", + "
", + "$else$", + "
", + "$endif$", + "

$title$

", + "$for(author)$", + "

$author$

", + "$endfor$", + "$if(date)$", + "

$date$

", + "$endif$", + "$if(html5)$", + "
", + "$else$", + "", + "$endif$", + "$endif$", + "$if(toc)$", + "$if(html5)$", + "", + "$else$", + "
", + "$toc$", + "
", + "$endif$", + "$endif$", + "$body$", + "$for(include-after)$", + "$include-after$", + "$endfor$" ], -- writerVariables = [], -- ^ Variables to set in template -- writerIncludeBefore = "", -- ^ Text to include before the body