diff --git a/data/templates b/data/templates index 7ff2baf592ee..c76c6c522491 160000 --- a/data/templates +++ b/data/templates @@ -1 +1 @@ -Subproject commit 7ff2baf592ee4627da0ad1e5cec60e6be3de5785 +Subproject commit c76c6c52249118e49c5dd1b99fe916724350a590 diff --git a/src/Text/Pandoc/Writers/EPUB.hs b/src/Text/Pandoc/Writers/EPUB.hs index 456158116795..2291c71842a6 100644 --- a/src/Text/Pandoc/Writers/EPUB.hs +++ b/src/Text/Pandoc/Writers/EPUB.hs @@ -358,8 +358,9 @@ writeEPUB opts doc@(Pandoc meta _) = do Nothing -> return ([],[]) Just img -> do let coverImage = "media/" ++ takeFileName img - let cpContent = renderHtml $ writeHtml opts' - (Pandoc meta [RawBlock (Format "html") $ "
\n\"cover\n
"]) + let cpContent = renderHtml $ writeHtml + opts'{ writerVariables = ("coverpage","true"):vars } + (Pandoc meta [RawBlock (Format "html") $ "
\n\"cover\n
"]) imgContent <- B.readFile img return ( [mkEntry "cover.xhtml" cpContent] , [mkEntry coverImage imgContent] )