diff --git a/lib/marked.js b/lib/marked.js index dbcd573a..d5522afc 100644 --- a/lib/marked.js +++ b/lib/marked.js @@ -22,7 +22,6 @@ var block = { list: /^( *)(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?!\1bull )\n*|\s*$)/, html: /^ *(?:comment|closed|closing) *(?:\n{2,}|\s*$)/, def: /^ *\[([^\]]+)\]: *([^\s>]+)>?(?: +["(]([^\n]+)[")])? *(?:\n+|$)/, - task: noop, table: noop, paragraph: /^((?:[^\n]+\n?(?!hr|heading|lheading|blockquote|tag|def))+)\n*/, text: /^[^\n]+/ @@ -76,7 +75,6 @@ block.normal = merge({}, block); */ block.gfm = merge({}, block.normal, { - task: /^(\s*\[[x ]\][^\n]+\n)+\n*/, fences: /^ *(`{3,}|~{3,}) *(\S+)? *\n([\s\S]+?)\s*\1 *(?:\n+|$)/, paragraph: /^/ }); @@ -377,33 +375,6 @@ Lexer.prototype.token = function(src, top, bq) { continue; } - // task (gfm) - if (top && (cap = this.rules.task.exec(src)) { - src = src.substring(cap[0].length); - - this.tokens.push({ - type: 'task_list_start' - }); - - cap[0] = cap[0].replace(/^\s+|\s+$/g, ''); - cap = cap[0].split(/\n+/); - - i = 0; - l = cap.length; - - for (; i < l; i++) { - this.tokens.push({ - type: 'task_item', - checked: /^\s*\[x\]/.test(cap[i]), - text: cap[i].replace(/^\s*\[[x ]\]\s*/, '') - }); - } - - this.tokens.push({ - type: 'task_list_end' - }); - } - // table (gfm) if (top && (cap = this.rules.table.exec(src))) { src = src.substring(cap[0].length); @@ -1009,25 +980,6 @@ Parser.prototype.tok = function() { this.token.lang, this.token.escaped); } - case 'task_list_start': { - var body = '' - , i = 1; - - while (this.next().type !== 'task_list_end') { - body += '
'; - } - - return '