drop other em/strong behaviors

This commit is contained in:
Christopher Jeffrey 2012-01-16 22:38:56 -06:00
parent 18e61dc365
commit 2ea9105093

View File

@ -284,24 +284,8 @@ var inline = {
link: /^!?\[((?:\[[^\]]*\]|[^\[\]]|\[|\](?=[^[\]]*\]))*)\]\(([^\)]*)\)/,
reflink: /^!?\[((?:\[[^\]]*\]|[^\[\]]|\[|\](?=[^[\]]*\]))*)\]\s*\[([^\]]*)\]/,
nolink: /^!?\[((?:\[[^\]]*\]|[^\[\]])*)\]/,
// discount em/strong behavior
// strong: /^__([^\0]+?)__(?!_)|^\*\*([^\0]+?)\*\*(?!\*)/,
// em: /^\b_(?=\S)([^\0]*?\S)_\b|^\*(?=\S)([^\0]*?(?:\*\*|[^\s*]))\*(?!\*)/,
// markdown.js em/strong behavior
strong: /^__([^\0]+?)__(?!_)|^\*\*([^\0]+?)\*\*(?!\*)/,
em: /^\b_([^\0]+?)_\b|^\*((?:\*\*|[^\0])+?)\*(?!\*)/,
// upskirt/markdown.pl em/strong behavior
// strong: /^__(?=\S)([^\0]*?\S)__(?!_)|^\*\*(?=\S)([^\0]*?\S)\*\*(?!\*)/,
// em: /^\b_(?=\S)([^\0]*?\S)_\b|^\*(?=\S)([^\0]*?\S)\*(?!\*)/,
// strict em/strong behavior
// closest to being conformant without markdown.pl's bugs
// strong: /^__(?=\S)([^\0]*?\S)__(?!_)|^\*\*(?=\S)([^\0]*?\S)\*\*(?!\*)/,
// em: /^\b_(?=\S)([^\0]*?\S)_\b|^\*(?=\S)([^\0]*?(?:\*\*|[^\s*]))\*(?!\*)/,
code: /^(`+)([^\0]*?[^`])\1(?!`)/,
br: /^ {2,}\n(?!\s*$)/,
text: /^[^\0]+?(?=body|$)/