fix(blockQuote): fix 'github style codeblocks' not being parsed inside 'blockquote'

Closes #192
This commit is contained in:
Estevão Soares dos Santos 2015-08-25 21:10:49 +01:00
parent e754668814
commit ed2cf595b0
7 changed files with 35 additions and 5 deletions

3
dist/showdown.js vendored
View File

@ -1,4 +1,4 @@
;/*! showdown 23-08-2015 */
;/*! showdown 25-08-2015 */
(function(){
/**
* Created by Tivie on 13-07-2015.
@ -1077,6 +1077,7 @@ showdown.subParser('blockQuotes', function (text, options, globals) {
bq = bq.replace(/~0/g, '');
bq = bq.replace(/^[ \t]+$/gm, ''); // trim whitespace-only lines
bq = showdown.subParser('githubCodeBlocks')(bq, options, globals);
bq = showdown.subParser('blockGamut')(bq, options, globals); // recurse
bq = bq.replace(/(^|\n)/g, '$1 ');

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

@ -25,6 +25,7 @@ showdown.subParser('blockQuotes', function (text, options, globals) {
bq = bq.replace(/~0/g, '');
bq = bq.replace(/^[ \t]+$/gm, ''); // trim whitespace-only lines
bq = showdown.subParser('githubCodeBlocks')(bq, options, globals);
bq = showdown.subParser('blockGamut')(bq, options, globals); // recurse
bq = bq.replace(/(^|\n)/g, '$1 ');

View File

@ -0,0 +1,15 @@
<blockquote>
<p>Define a function in javascript:</p>
<pre><code>function MyFunc(a) {
var s = '`';
}
</code></pre>
<blockquote>
<p>And some nested quote</p>
<pre><code class="html language-html">&lt;div&gt;HTML!&lt;/div&gt;
</code></pre>
</blockquote>
</blockquote>

View File

@ -0,0 +1,13 @@
> Define a function in javascript:
>
> ```
> function MyFunc(a) {
> var s = '`';
> }
> ```
>
>> And some nested quote
>>
>> ```html
>> <div>HTML!</div>
>> ```