mirror of
https://github.com/jgm/pandoc.git
synced 2026-09-01 13:15:51 +00:00
Previously with this configuration, `<span>`s were not treated as inline elements at all. Closes #8711.
119 lines
2.5 KiB
Markdown
119 lines
2.5 KiB
Markdown
```
|
|
% pandoc -f html-native_spans -t native
|
|
<table>
|
|
<tr>
|
|
<td>
|
|
<p><span class="foo">a</span> <span class="bar">b</span></p>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
^D
|
|
[ Table
|
|
( "" , [] , [] )
|
|
(Caption Nothing [])
|
|
[ ( AlignDefault , ColWidthDefault ) ]
|
|
(TableHead ( "" , [] , [] ) [])
|
|
[ TableBody
|
|
( "" , [] , [] )
|
|
(RowHeadColumns 0)
|
|
[]
|
|
[ Row
|
|
( "" , [] , [] )
|
|
[ Cell
|
|
( "" , [] , [] )
|
|
AlignDefault
|
|
(RowSpan 1)
|
|
(ColSpan 1)
|
|
[ Para [ Str "a" , Space , Str "b" ] ]
|
|
]
|
|
]
|
|
]
|
|
(TableFoot ( "" , [] , [] ) [])
|
|
]
|
|
|
|
```
|
|
|
|
```
|
|
% pandoc -f html-native_spans+raw_html -t native
|
|
<table>
|
|
<tr>
|
|
<td>
|
|
<p><span class="foo">a</span> <span class="bar">b</span></p>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
^D
|
|
[ Table
|
|
( "" , [] , [] )
|
|
(Caption Nothing [])
|
|
[ ( AlignDefault , ColWidthDefault ) ]
|
|
(TableHead ( "" , [] , [] ) [])
|
|
[ TableBody
|
|
( "" , [] , [] )
|
|
(RowHeadColumns 0)
|
|
[]
|
|
[ Row
|
|
( "" , [] , [] )
|
|
[ Cell
|
|
( "" , [] , [] )
|
|
AlignDefault
|
|
(RowSpan 1)
|
|
(ColSpan 1)
|
|
[ Para
|
|
[ RawInline (Format "html") "<span class=\"foo\">"
|
|
, Str "a"
|
|
, RawInline (Format "html") "</span>"
|
|
, Space
|
|
, RawInline (Format "html") "<span class=\"bar\">"
|
|
, Str "b"
|
|
, RawInline (Format "html") "</span>"
|
|
]
|
|
]
|
|
]
|
|
]
|
|
]
|
|
(TableFoot ( "" , [] , [] ) [])
|
|
]
|
|
|
|
```
|
|
|
|
```
|
|
% pandoc -f html -t native
|
|
<table>
|
|
<tr>
|
|
<td>
|
|
<p><span class="foo">a</span> <span class="bar">b</span></p>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
^D
|
|
[ Table
|
|
( "" , [] , [] )
|
|
(Caption Nothing [])
|
|
[ ( AlignDefault , ColWidthDefault ) ]
|
|
(TableHead ( "" , [] , [] ) [])
|
|
[ TableBody
|
|
( "" , [] , [] )
|
|
(RowHeadColumns 0)
|
|
[]
|
|
[ Row
|
|
( "" , [] , [] )
|
|
[ Cell
|
|
( "" , [] , [] )
|
|
AlignDefault
|
|
(RowSpan 1)
|
|
(ColSpan 1)
|
|
[ Para
|
|
[ Span ( "" , [ "foo" ] , [] ) [ Str "a" ]
|
|
, Space
|
|
, Span ( "" , [ "bar" ] , [] ) [ Str "b" ]
|
|
]
|
|
]
|
|
]
|
|
]
|
|
]
|
|
(TableFoot ( "" , [] , [] ) [])
|
|
]
|
|
|
|
```
|