Merge branch 'master' into develop

This commit is contained in:
Estevao Soares dos Santos 2016-12-19 12:16:22 +00:00
commit d532dea8f0
8 changed files with 17 additions and 19 deletions

13
dist/showdown.js vendored
View File

@ -1,4 +1,4 @@
;/*! showdown 17-12-2016 */
;/*! showdown 19-12-2016 */
(function(){
/**
* Created by Tivie on 13-07-2015.
@ -1258,9 +1258,9 @@ showdown.subParser('blockGamut', function (text, options, globals) {
// Do Horizontal Rules:
var key = showdown.subParser('hashBlock')('<hr />', options, globals);
text = text.replace(/^ {0,2}( ?\* ?){3,}[ \t]*$/gm, key);
text = text.replace(/^ {0,2}( ?- ?){3,}[ \t]*$/gm, key);
text = text.replace(/^ {0,2}( ?_ ?){3,}[ \t]*$/gm, key);
text = text.replace(/^( ?-){3,}[ \t]*$/gm, key);
text = text.replace(/^( ?\*){3,}[ \t]*$$/gm, key);
text = text.replace(/^( ?_){3,}[ \t]*$$/gm, key);
text = showdown.subParser('lists')(text, options, globals);
text = showdown.subParser('codeBlocks')(text, options, globals);
@ -1951,7 +1951,6 @@ showdown.subParser('italicsAndBold', function (text, options, globals) {
*/
showdown.subParser('lists', function (text, options, globals) {
'use strict';
text = globals.converter._dispatch('lists.before', text, options, globals);
/**
* Process the contents of a single ordered or unordered list, splitting it
@ -2026,7 +2025,7 @@ showdown.subParser('lists', function (text, options, globals) {
// <ul><li>- - a</li></ul>
// So, to prevent it, we will put a marker (~A)in the beginning of the line
// Kind of hackish/monkey patching, but seems more effective than overcomplicating the list parser
item = item.replace(/^([-*+]|\d\.)[ \t]+[\s\n]*/g, function (wm2) {
item = item.replace(/^([-*+]|\d\.)[ \t]+[\S\n ]*/g, function (wm2) {
return '~A' + wm2;
});
@ -2049,7 +2048,6 @@ showdown.subParser('lists', function (text, options, globals) {
// now we need to remove the marker (~A)
item = item.replace('~A', '');
// we can finally wrap the line in list item tags
item = '<li' + bulletStyle + '>' + item + '</li>\n';
return item;
@ -2128,7 +2126,6 @@ showdown.subParser('lists', function (text, options, globals) {
// strip sentinel
text = text.replace(/~0/, '');
text = globals.converter._dispatch('lists.after', text, options, globals);
return text;
});

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -14,9 +14,9 @@ showdown.subParser('blockGamut', function (text, options, globals) {
// Do Horizontal Rules:
var key = showdown.subParser('hashBlock')('<hr />', options, globals);
text = text.replace(/^ {0,2}( ?\* ?){3,}[ \t]*$/gm, key);
text = text.replace(/^ {0,2}( ?- ?){3,}[ \t]*$/gm, key);
text = text.replace(/^ {0,2}( ?_ ?){3,}[ \t]*$/gm, key);
text = text.replace(/^( ?-){3,}[ \t]*$/gm, key);
text = text.replace(/^( ?\*){3,}[ \t]*$$/gm, key);
text = text.replace(/^( ?_){3,}[ \t]*$$/gm, key);
text = showdown.subParser('lists')(text, options, globals);
text = showdown.subParser('codeBlocks')(text, options, globals);

View File

@ -3,7 +3,6 @@
*/
showdown.subParser('lists', function (text, options, globals) {
'use strict';
text = globals.converter._dispatch('lists.before', text, options, globals);
/**
* Process the contents of a single ordered or unordered list, splitting it
@ -78,7 +77,7 @@ showdown.subParser('lists', function (text, options, globals) {
// <ul><li>- - a</li></ul>
// So, to prevent it, we will put a marker (~A)in the beginning of the line
// Kind of hackish/monkey patching, but seems more effective than overcomplicating the list parser
item = item.replace(/^([-*+]|\d\.)[ \t]+[\s\n]*/g, function (wm2) {
item = item.replace(/^([-*+]|\d\.)[ \t]+[\S\n ]*/g, function (wm2) {
return '~A' + wm2;
});
@ -101,7 +100,6 @@ showdown.subParser('lists', function (text, options, globals) {
// now we need to remove the marker (~A)
item = item.replace('~A', '');
// we can finally wrap the line in list item tags
item = '<li' + bulletStyle + '>' + item + '</li>\n';
return item;
@ -180,7 +178,6 @@ showdown.subParser('lists', function (text, options, globals) {
// strip sentinel
text = text.replace(/~0/, '');
text = globals.converter._dispatch('lists.after', text, options, globals);
return text;
});

View File

@ -0,0 +1,3 @@
<ul>
<li>- - - -- - - - - - - -- - - - - - - - - - - - - - - - - - - - abcd</li>
</ul>

View File

@ -0,0 +1 @@
- - - - -- - - - - - - -- - - - - - - - - - - - - - - - - - - - abcd