This commit is contained in:
Christopher Jeffrey 2011-08-20 09:01:22 -05:00
parent 3c0baff53a
commit dc99c0e9f6
2 changed files with 2 additions and 3 deletions

View File

@ -16,7 +16,7 @@ var block = {
lheading: /^([^\n]+)\n *(=|-){3,}/, lheading: /^([^\n]+)\n *(=|-){3,}/,
hr: /^( ?[\-*_]){3,}/, hr: /^( ?[\-*_]){3,}/,
blockquote: /^ *>[^\n]*(?:\n *>[^\n]*)*/, blockquote: /^ *>[^\n]*(?:\n *>[^\n]*)*/,
list: /^(?: *(\*|\+|-|\d+\.)[^\n]+(?:\n[^\n]+)*(?:\n{1,2}|$)){2,}/g, list: /^(?:( *)(\*|\+|-|\d+\.)[^\n]+(?:\n[^\n]+)*(?:\n{1,2}|$)){2,}/g,
html: /^<([^\/\s>]+)[^\n>]*>[^\n]*(?:\n[^\n]+)*\n?<\/\1>/, html: /^<([^\/\s>]+)[^\n>]*>[^\n]*(?:\n[^\n]+)*\n?<\/\1>/,
text: /^[^\n]+/ text: /^[^\n]+/
}; };
@ -128,7 +128,7 @@ block.token = function(str, tokens) {
).test(cap[0]); ).test(cap[0]);
tokens.push({ tokens.push({
type: 'list_start', type: 'list_start',
ordered: isFinite(cap[1]) ordered: isFinite(cap[2])
}); });
// get each top-level // get each top-level
// item in the list // item in the list

View File

@ -23,7 +23,6 @@ markdown.js doesnt acknowledge arbitrary html blocks =/</aside>
The last item The last item
* List Item 3 * List Item 3
The final item. The final item.
* List Item 4 * List Item 4
The real final item. The real final item.