Skip to content

markdown writer: problem with block quote in lists #9908

Closed
@kysko

Description

@kysko

Problem: If the first block of an item list is a block quote, the markdown (and commonmark_x) writer will omit the quote mark (>) on the first line of the block quote.

Consider:

*   > a
    >
    > b

The native output (pandoc -f markdown -t native) is as expected:

[ BulletList
    [ [ BlockQuote [ Para [ Str "a" ] , Para [ Str "b" ] ] ] ]
]

But converting to markdown (pandoc -f markdown -t markdown) will produce:

-   a
    >
    > b

Same for commonmark_x output.
Same problem if we use ordered lists.
(html output is ok.)

A second block quote block in the same list item will output correctly:

*   > a
    >
    > b

    > c

will give:

-   a
    >
    > b

    > c

Possible cause? In a custom writer, pandoc.layout.prefixed also caused this, possibly because it was not considered to be at the beginning of the line. So had to manually prefix the BlockQuote with layout.litteral'> '. Maybe it's similar in the Haskell code.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions