File tree 2 files changed +25
-1
lines changed
2 files changed +25
-1
lines changed Original file line number Diff line number Diff line change @@ -452,7 +452,7 @@ Lexer.prototype.token = function(src, top) {
452
452
type : 'table' ,
453
453
header : splitCells ( cap [ 1 ] . replace ( / ^ * | * \| * $ / g, '' ) ) ,
454
454
align : cap [ 2 ] . replace ( / ^ * | \| * $ / g, '' ) . split ( / * \| * / ) ,
455
- cells : cap [ 3 ] ? cap [ 3 ] . replace ( / (?: * \| * ) ? \n $ / , '' ) . split ( '\n' ) : [ ]
455
+ cells : cap [ 3 ] ? cap [ 3 ] . replace ( / \n $ / , '' ) . split ( '\n' ) : [ ]
456
456
} ;
457
457
458
458
if ( item . header . length === item . align . length ) {
Original file line number Diff line number Diff line change 119
119
"html" : " <p><em>test</em>. <em>test</em>: <em>test</em>! <em>test</em>? <em>test</em>-</p>" ,
120
120
"example" : 15
121
121
},
122
+ {
123
+ "section" : " Table cells" ,
124
+ "markdown" : " 1|2\n -|-\n 1\\ |\\\\ |2\\ |\\\\ " ,
125
+ "html" : " <table><thead><tr><th>1</th><th>2</th></tr></thead><tbody><tr><td>1|\\ </td><td>2|\\ </td></tr></tbody></table>" ,
126
+ "example" : 19
127
+ },
128
+ {
129
+ "section" : " Table cells" ,
130
+ "markdown" : " 1|2\n -|-\n |2" ,
131
+ "html" : " <table><thead><tr><th>1</th><th>2</th></tr></thead><tbody><tr><td></td><td>2</td></tr></tbody></table>" ,
132
+ "example" : 20
133
+ },
134
+ {
135
+ "section" : " Table cells" ,
136
+ "markdown" : " 1|2\n -|-\n 1|2\\ |\n\n 1|2\n -|-\n 1|2\\ |" ,
137
+ "html" : " <table><thead><tr><th>1</th><th>2</th></tr></thead><tbody><tr><td>1</td><td>2|</td></tr></tbody></table>\n\n <table><thead><tr><th>1</th><th>2</th></tr></thead><tbody><tr><td>1</td><td>2|</td></tr></tbody></table>" ,
138
+ "example" : 21
139
+ },
140
+ {
141
+ "section" : " Table cells" ,
142
+ "markdown" : " |1|2|\n |-|-|\n |1|2\\ ||\n\n |1|2|\n |-|-|\n |1|2\\ ||" ,
143
+ "html" : " <table><thead><tr><th>1</th><th>2</th></tr></thead><tbody><tr><td>1</td><td>2|</td></tr></tbody></table>\n\n <table><thead><tr><th>1</th><th>2</th></tr></thead><tbody><tr><td>1</td><td>2|</td></tr></tbody></table>" ,
144
+ "example" : 22
145
+ },
122
146
{
123
147
"section" : " Links" ,
124
148
"markdown" : " [One](https://example.com/1) ([Two](https://example.com/2)) [Three](https://example.com/3)" ,
You can’t perform that action at this time.
0 commit comments