diff options
author | John MacFarlane <jgm@berkeley.edu> | 2020-02-08 09:38:07 -0800 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2020-02-08 09:38:07 -0800 |
commit | 5f0bd5222169129cc3474d0284a0f1ecb702a770 (patch) | |
tree | 92cdd40a20823ea164280bbebe922264dc86ac40 /src/Text/Pandoc/Writers | |
parent | f2f559003e4fe40c3623d1b7acfbeea5a8da9f34 (diff) | |
download | pandoc-5f0bd5222169129cc3474d0284a0f1ecb702a770.tar.gz |
reveal.js: ensure that pauses work even in title slides.
Closes #5819.
Diffstat (limited to 'src/Text/Pandoc/Writers')
-rw-r--r-- | src/Text/Pandoc/Writers/HTML.hs | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/Text/Pandoc/Writers/HTML.hs b/src/Text/Pandoc/Writers/HTML.hs index 0608701ed..a393df6d0 100644 --- a/src/Text/Pandoc/Writers/HTML.hs +++ b/src/Text/Pandoc/Writers/HTML.hs @@ -666,13 +666,15 @@ blockToHtml opts (Div (ident, "section":dclasses, dkvs) let inDiv zs = RawBlock (Format "html") ("<div class=\"" <> fragmentClass <> "\">") : (zs ++ [RawBlock (Format "html") "</div>"]) + let breakOnPauses zs = case splitBy isPause zs of + [] -> [] + y:ys -> y ++ concatMap inDiv ys let (titleBlocks, innerSecs) = if titleSlide -- title slides have no content of their own - then break isSec xs - else case splitBy isPause xs of - [] -> ([],[]) - (z:zs) -> ([],z ++ concatMap inDiv zs) + then let (as, bs) = break isSec xs + in (breakOnPauses as, bs) + else ([], breakOnPauses xs) let secttag = if html5 then H5.section else H.div |