Allow spaces before '!' in MediaWiki table header
This commit is contained in:
parent
21d1a3b57c
commit
acd492c7f4
3 changed files with 14 additions and 1 deletions
|
@ -225,7 +225,7 @@ table = do
|
|||
Nothing -> 1.0
|
||||
caption <- option mempty tableCaption
|
||||
optional rowsep
|
||||
hasheader <- option False $ True <$ (lookAhead (char '!'))
|
||||
hasheader <- option False $ True <$ (lookAhead (skipSpaces *> char '!'))
|
||||
(cellspecs',hdr) <- unzip <$> tableRow
|
||||
let widths = map ((tableWidth *) . snd) cellspecs'
|
||||
let restwidth = tableWidth - sum widths
|
||||
|
|
|
@ -252,6 +252,11 @@ Pandoc (Meta {unMeta = fromList []})
|
|||
[[]]
|
||||
[[[Para [Str "Orange"]]]]
|
||||
,Para [Str "Paragraph",Space,Str "after",Space,Str "the",Space,Str "table."]
|
||||
,Table [] [AlignDefault,AlignDefault] [0.0,0.0]
|
||||
[[Para [Str "fruit"]]
|
||||
,[Para [Str "topping"]]]
|
||||
[[[Para [Str "apple"]]
|
||||
,[Para [Str "ice",Space,Str "cream"]]]]
|
||||
,Header 2 ("notes",[],[]) [Str "notes"]
|
||||
,Para [Str "My",Space,Str "note!",Note [Plain [Str "This."]]]
|
||||
,Para [Str "URL",Space,Str "note.",Note [Plain [Link ("",[],[]) [Str "http://docs.python.org/library/functions.html#range"] ("http://docs.python.org/library/functions.html#range","")]]]]
|
||||
|
|
|
@ -381,6 +381,14 @@ and cheese
|
|||
|Orange
|
||||
|}Paragraph after the table.
|
||||
|
||||
{|
|
||||
!fruit
|
||||
!topping
|
||||
|-
|
||||
|apple
|
||||
|ice cream
|
||||
|}
|
||||
|
||||
== notes ==
|
||||
|
||||
My note!<ref>This.</ref>
|
||||
|
|
Loading…
Add table
Reference in a new issue