@@ -169,7 +169,9 @@ inTemplate opts tit auths date toc body' newvars =
169169 [ ("body", dropWhile (=='\n') $ showHtmlFragment body')
170170 , ("pagetitle", topTitle')
171171 , ("title", dropWhile (=='\n') $ showHtmlFragment tit)
172− , ("date", date') ] ++
172+ , ("date", date')
173+ , ("idprefix", writerIdentifierPrefix opts)
174+ ] ++
173175 [ ("html5","true") | writerHtml5 opts ] ++
174176 (case toc of
175177 Just t -> [ ("toc", showHtmlFragment t)]
@@ -198,14 +200,7 @@ tableOfContents opts sects = do
198200 let tocList = catMaybes contents
199201 return $ if null tocList
200202 then Nothing
201− else Just $
202− if writerHtml5 opts
203− then (tag "nav" ! [prefixedId opts' "TOC"] $
204− nl opts +++ unordList opts tocList +++ nl opts)
205− +++ nl opts
206− else (thediv ! [prefixedId opts' "TOC"] $
207− nl opts +++ unordList opts tocList +++ nl opts)
208− +++ nl opts
203+ else Just $ unordList opts tocList
209204
210205-- | Convert section number to string
211206showSecNum :: [Int] -> String