git.iko.soy/typeable/pandoc
on master help sign in
EPUB writer: add frontmatter type on body element for nav.xhtml.

Closes #6918.

commit9c6cc79c11d191c74aae8646279a2b94ae253330 authorJohn MacFarlane <jgm@berkeley.edu> dateThu 3 Dec 2020, 21:24 (6 years ago) parent5bbd5a9
1 file changed+3−1
src/Text/Pandoc/Writers/EPUB.hs+3−1
src/Text/Pandoc/Writers/EPUB.hs+3−1
@@ -845,7 +845,9 @@ pandocToEPUB version opts doc = do
845845 [ unode "ol" landmarkItems ]
846846 | not (null landmarkItems)]
847847 navData <- lift $ writeHtml opts'{ writerVariables =
848− Context (M.fromList [("navpage", toVal' "true")])
848+ Context (M.fromList [("navpage", toVal' "true")
849+ ,("body-type", toVal' "frontmatter")
850+ ])
849851 <> cssvars False <> vars }
850852 (Pandoc (setMeta "title"
851853 (walk removeNote $ fromList $ docTitle' meta) nullMeta)