aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn MacFarlane <[email protected]>2021-10-02 08:13:41 -0700
committerJohn MacFarlane <[email protected]>2021-10-02 12:04:42 -0700
commit460721cec99ad9779b8e7cb30e7440ebc8db191b (patch)
treedef18f126fec75581de2595a247929b9dea855f5
parent920096115d8655137ce7e52ee177552d3983bd11 (diff)
Restore markdown writer.
-rw-r--r--src/Text/Pandoc/Writers/Markdown.hs7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/Text/Pandoc/Writers/Markdown.hs b/src/Text/Pandoc/Writers/Markdown.hs
index fb74e8ad5..1dd9301f0 100644
--- a/src/Text/Pandoc/Writers/Markdown.hs
+++ b/src/Text/Pandoc/Writers/Markdown.hs
@@ -166,8 +166,6 @@ valToYaml _ = empty
-- | Return markdown representation of document.
pandocToMarkdown :: PandocMonad m => WriterOptions -> Pandoc -> MD m Text
pandocToMarkdown opts (Pandoc meta blocks) = do
- undefined
-{-
let colwidth = if writerWrapText opts == WrapAuto
then Just $ writerColumns opts
else Nothing
@@ -817,8 +815,8 @@ blockListToMarkdown opts blocks = do
mconcat <$> mapM (blockToMarkdown opts) (fixBlocks blocks)
lineBreakToSpace :: Inline -> Inline
-lineBreakToSpace LineBreak = Space
-lineBreakToSpace SoftBreak = Space
+lineBreakToSpace LineBreak = Str " "
+lineBreakToSpace SoftBreak = Str " "
lineBreakToSpace x = x
-- | Starts with space or soft break.
@@ -829,4 +827,3 @@ startsWithSpace (Str t : _) =
_ -> False
startsWithSpace (SoftBreak : _) = True
startsWithSpace _ = False
--}