git.iko.soy/typeable/pandoc
on master help sign in
Muse writer: indent lists inside Div
288065cAlexander Krotov
src/Text/Pandoc/Writers/Muse.hs+1−1
@@ -259,7 +259,7 @@ blockToMuse (Table caption _ _ headers rows) = do
259 $$ body
259 $$ body
260 $$ (if null caption then empty else " |+ " <> caption' <> " +|")
260 $$ (if null caption then empty else " |+ " <> caption' <> " +|")
261 $$ blankline
261 $$ blankline
262−blockToMuse (Div _ bs) = blockListToMuse bs
262+blockToMuse (Div _ bs) = flatBlockListToMuse bs
263blockToMuse Null = return empty
263blockToMuse Null = return empty
264
264
265-- | Return Muse representation of notes.
265-- | Return Muse representation of notes.
test/Tests/Writers/Muse.hs+3−1
@@ -282,7 +282,9 @@ tests = [ testGroup "block elements"
282 , " |+ Table 1 +|"
282 , " |+ Table 1 +|"
283 ]
283 ]
284 ]
284 ]
285− -- Div is trivial
285+ , "div with bullet list" =:
286+ divWith nullAttr (bulletList [para $ text "foo"]) =?>
287+ unlines [ " - foo" ] -- Making sure bullets are indented
286 -- Null is trivial
288 -- Null is trivial
287 ]
289 ]
288 , testGroup "inline elements"
290 , testGroup "inline elements"