mirror of
https://github.com/jgm/pandoc.git
synced 2026-09-02 05:35:38 +00:00
0d2114e introduced a bug where Markdown writer would ignore attributes
on the figure if it has class or key-value attributes set.
This commit fixes that and adds a regression test.
Closes #10867
27 lines
529 B
Markdown
27 lines
529 B
Markdown
```
|
|
% pandoc -f native -t markdown-raw_html
|
|
[ Figure
|
|
( "fig:foo" , [] , [ ( "label" , "1.1" ) ] )
|
|
(Caption
|
|
Nothing
|
|
[ Plain
|
|
[ Str "Figure" , Space , Str "1.1:" , Space , Str "Figure" ]
|
|
])
|
|
[ Plain
|
|
[ Image
|
|
( "" , [] , [] )
|
|
[ Str "Figure" , Space , Str "1.1:" , Space , Str "Figure" ]
|
|
( "./image.png" , "" )
|
|
]
|
|
]
|
|
]
|
|
^D
|
|
:::: {#fig:foo .figure label="1.1"}
|
|

|
|
|
|
::: caption
|
|
Figure 1.1: Figure
|
|
:::
|
|
::::
|
|
```
|