RST writer: avoid extra blank line after empty list item.
See #7810 (2).
This commit is contained in:
parent
8736fe11ee
commit
1b7bdb1016
1 changed files with 2 additions and 2 deletions
|
@ -365,7 +365,7 @@ bulletListItemToRST :: PandocMonad m => [Block] -> RST m (Doc Text)
|
|||
bulletListItemToRST items = do
|
||||
contents <- blockListToRST items
|
||||
return $ hang 3 "- " contents $$
|
||||
if endsWithPlain items
|
||||
if null items || endsWithPlain items
|
||||
then cr
|
||||
else blankline
|
||||
|
||||
|
@ -378,7 +378,7 @@ orderedListItemToRST marker items = do
|
|||
contents <- blockListToRST items
|
||||
let marker' = marker <> " "
|
||||
return $ hang (T.length marker') (literal marker') contents $$
|
||||
if endsWithPlain items
|
||||
if null items || endsWithPlain items
|
||||
then cr
|
||||
else blankline
|
||||
|
||||
|
|
Loading…
Reference in a new issue