|
|
@ -143,9 +143,12 @@ module.exports = function table(state, startLine, endLine, silent) { |
|
|
|
for (nextLine = startLine + 2; nextLine < endLine; nextLine++) { |
|
|
|
if (state.sCount[nextLine] < state.blkIndent) { break; } |
|
|
|
|
|
|
|
lineText = getLine(state, nextLine).trim(); |
|
|
|
lineText = getLine(state, nextLine); |
|
|
|
if (lineText.indexOf('|') === -1) { break; } |
|
|
|
columns = escapedSplit(lineText.replace(/^\||\|$/g, '')); |
|
|
|
|
|
|
|
// keep spaces at beginning of line to indicate an empty first cell, but
|
|
|
|
// strip trailing whitespace
|
|
|
|
columns = escapedSplit(lineText.replace(/^\||\|\s*$/g, '')); |
|
|
|
|
|
|
|
token = state.push('tr_open', 'tr', 1); |
|
|
|
for (i = 0; i < columnCount; i++) { |
|
|
|