aboutsummaryrefslogtreecommitdiff
path: root/src/Text/Pandoc
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2021-06-28 11:27:37 -0700
committerJohn MacFarlane <jgm@berkeley.edu>2021-06-28 11:33:22 -0700
commitdd098d4e15090d12cc71301f91a159c5bfb29b50 (patch)
treeb3cdc73ee9777337d7fd84f5171e4c0980b52e57 /src/Text/Pandoc
parent4a7a0cff294c48d1acd690ea593f4ab2c817ec27 (diff)
downloadpandoc-dd098d4e15090d12cc71301f91a159c5bfb29b50.tar.gz
Markdown writer: put space between Plain and following fenced Div.
Closes #4465.
Diffstat (limited to 'src/Text/Pandoc')
-rw-r--r--src/Text/Pandoc/Writers/Markdown.hs3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/Text/Pandoc/Writers/Markdown.hs b/src/Text/Pandoc/Writers/Markdown.hs
index b13ab57ee..fda2bbcef 100644
--- a/src/Text/Pandoc/Writers/Markdown.hs
+++ b/src/Text/Pandoc/Writers/Markdown.hs
@@ -791,6 +791,9 @@ blockListToMarkdown opts blocks = do
b1 : commentSep : fixBlocks (b2:bs)
fixBlocks (Plain ils : bs@(RawBlock{}:_)) =
Plain ils : fixBlocks bs
+ fixBlocks (Plain ils : bs@(Div{}:_))
+ | isEnabled Ext_fenced_divs opts =
+ Para ils : fixBlocks bs
fixBlocks (Plain ils : bs) | inlist =
Plain ils : fixBlocks bs
fixBlocks (Plain ils : bs) =