parent
937bec95a9
commit
ec47079d3e
1 changed files with 5 additions and 4 deletions
|
@ -751,12 +751,13 @@ pandocToEPUB version opts doc@(Pandoc meta _) = do
|
||||||
(writeHtmlStringForEPUB version
|
(writeHtmlStringForEPUB version
|
||||||
opts{ writerTemplate = Nothing }
|
opts{ writerTemplate = Nothing }
|
||||||
(Pandoc nullMeta
|
(Pandoc nullMeta
|
||||||
[Plain $ walk delink tit])) of
|
[Plain $ walk clean tit])) of
|
||||||
Left _ -> TS.pack $ stringify tit
|
Left _ -> TS.pack $ stringify tit
|
||||||
Right x -> x
|
Right x -> x
|
||||||
-- can't have a element inside a...
|
-- can't have <a> elements inside generated links...
|
||||||
delink (Link _ ils _) = Span ("", [], []) ils
|
clean (Link _ ils _) = Span ("", [], []) ils
|
||||||
delink x = x
|
clean (Note _) = Str ""
|
||||||
|
clean x = x
|
||||||
|
|
||||||
let navtag = if epub3 then "nav" else "div"
|
let navtag = if epub3 then "nav" else "div"
|
||||||
tocBlocks <- lift $ evalStateT (mapM (navPointNode navXhtmlFormatter) secs) 1
|
tocBlocks <- lift $ evalStateT (mapM (navPointNode navXhtmlFormatter) secs) 1
|
||||||
|
|
Loading…
Reference in a new issue