uwdata / living-papers

Authoring tools for scholarly communication. Create interactive web pages or formal research papers from markdown source.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

preprocess fails when attributes are used in nested fenced divs

joshuahhh opened this issue · comments

::: div1 {a=b}
::: div2
:::
:::

preprocesses to

::: {.div1 a=b}
::: div2
:::
:::

which is expected. But

::: div1
::: div2 {a=b}
:::
:::

preprocesses to

::: div1
::: div2 {a=b}
:::
:::

which pandoc can't parse.

I think I can route around this for now by only using the ::: {.div2 a=b} form in nested divs.

I ran into a related problem (failure of "ensure line blocks in a fence are treated as block elements" in preprocess, in nested divs) and debugged it a bit. Looks like preprocess doesn't handle nested divs in general.