|
@ -1,4 +1,4 @@ |
|
|
/*! markdown-it 8.3.1 https://github.com//markdown-it/markdown-it @license MIT */(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.markdownit = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){ |
|
|
/*! markdown-it 8.3.2 https://github.com//markdown-it/markdown-it @license MIT */(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.markdownit = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){ |
|
|
// HTML5 entities map: { name -> utf16string }
|
|
|
// HTML5 entities map: { name -> utf16string }
|
|
|
//
|
|
|
//
|
|
|
'use strict'; |
|
|
'use strict'; |
|
@ -1185,7 +1185,7 @@ var _rules = [ |
|
|
[ 'table', require('./rules_block/table'), [ 'paragraph', 'reference' ] ], |
|
|
[ 'table', require('./rules_block/table'), [ 'paragraph', 'reference' ] ], |
|
|
[ 'code', require('./rules_block/code') ], |
|
|
[ 'code', require('./rules_block/code') ], |
|
|
[ 'fence', require('./rules_block/fence'), [ 'paragraph', 'reference', 'blockquote', 'list' ] ], |
|
|
[ 'fence', require('./rules_block/fence'), [ 'paragraph', 'reference', 'blockquote', 'list' ] ], |
|
|
[ 'blockquote', require('./rules_block/blockquote'), [ 'paragraph', 'reference', 'list' ] ], |
|
|
[ 'blockquote', require('./rules_block/blockquote'), [ 'paragraph', 'reference', 'blockquote', 'list' ] ], |
|
|
[ 'hr', require('./rules_block/hr'), [ 'paragraph', 'reference', 'blockquote', 'list' ] ], |
|
|
[ 'hr', require('./rules_block/hr'), [ 'paragraph', 'reference', 'blockquote', 'list' ] ], |
|
|
[ 'list', require('./rules_block/list'), [ 'paragraph', 'reference', 'blockquote' ] ], |
|
|
[ 'list', require('./rules_block/list'), [ 'paragraph', 'reference', 'blockquote' ] ], |
|
|
[ 'reference', require('./rules_block/reference') ], |
|
|
[ 'reference', require('./rules_block/reference') ], |
|
@ -1250,7 +1250,7 @@ ParserBlock.prototype.tokenize = function (state, startLine, endLine) { |
|
|
if (ok) { break; } |
|
|
if (ok) { break; } |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
// set state.tight iff we had an empty line before current tag
|
|
|
// set state.tight if we had an empty line before current tag
|
|
|
// i.e. latest empty line should not count
|
|
|
// i.e. latest empty line should not count
|
|
|
state.tight = !hasEmptyLines; |
|
|
state.tight = !hasEmptyLines; |
|
|
|
|
|
|
|
@ -1778,7 +1778,7 @@ default_rules.fence = function (tokens, idx, options, env, slf) { |
|
|
return highlighted + '\n'; |
|
|
return highlighted + '\n'; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
// If language exists, inject class gently, without mudofying original token.
|
|
|
// If language exists, inject class gently, without modifying original token.
|
|
|
// May be, one day we will add .clone() for token and simplify this part, but
|
|
|
// May be, one day we will add .clone() for token and simplify this part, but
|
|
|
// now we prefer to keep things local.
|
|
|
// now we prefer to keep things local.
|
|
|
if (info) { |
|
|
if (info) { |
|
@ -2423,7 +2423,6 @@ module.exports = function blockquote(state, startLine, endLine, silent) { |
|
|
ch, |
|
|
ch, |
|
|
i, |
|
|
i, |
|
|
initial, |
|
|
initial, |
|
|
isOutdented, |
|
|
|
|
|
l, |
|
|
l, |
|
|
lastLineEmpty, |
|
|
lastLineEmpty, |
|
|
lines, |
|
|
lines, |
|
@ -2439,6 +2438,7 @@ module.exports = function blockquote(state, startLine, endLine, silent) { |
|
|
terminate, |
|
|
terminate, |
|
|
terminatorRules, |
|
|
terminatorRules, |
|
|
token, |
|
|
token, |
|
|
|
|
|
wasOutdented, |
|
|
oldLineMax = state.lineMax, |
|
|
oldLineMax = state.lineMax, |
|
|
pos = state.bMarks[startLine] + state.tShift[startLine], |
|
|
pos = state.bMarks[startLine] + state.tShift[startLine], |
|
|
max = state.eMarks[startLine]; |
|
|
max = state.eMarks[startLine]; |
|
@ -2519,6 +2519,7 @@ module.exports = function blockquote(state, startLine, endLine, silent) { |
|
|
|
|
|
|
|
|
oldParentType = state.parentType; |
|
|
oldParentType = state.parentType; |
|
|
state.parentType = 'blockquote'; |
|
|
state.parentType = 'blockquote'; |
|
|
|
|
|
wasOutdented = false; |
|
|
|
|
|
|
|
|
// Search the end of the block
|
|
|
// Search the end of the block
|
|
|
//
|
|
|
//
|
|
@ -2547,7 +2548,7 @@ module.exports = function blockquote(state, startLine, endLine, silent) { |
|
|
// > current blockquote
|
|
|
// > current blockquote
|
|
|
// 2. checking this line
|
|
|
// 2. checking this line
|
|
|
// ```
|
|
|
// ```
|
|
|
isOutdented = state.sCount[nextLine] < state.blkIndent; |
|
|
if (state.sCount[nextLine] < state.blkIndent) wasOutdented = true; |
|
|
|
|
|
|
|
|
pos = state.bMarks[nextLine] + state.tShift[nextLine]; |
|
|
pos = state.bMarks[nextLine] + state.tShift[nextLine]; |
|
|
max = state.eMarks[nextLine]; |
|
|
max = state.eMarks[nextLine]; |
|
@ -2557,7 +2558,7 @@ module.exports = function blockquote(state, startLine, endLine, silent) { |
|
|
break; |
|
|
break; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
if (state.src.charCodeAt(pos++) === 0x3E/* > */ && !isOutdented) { |
|
|
if (state.src.charCodeAt(pos++) === 0x3E/* > */ && !wasOutdented) { |
|
|
// This line is inside the blockquote.
|
|
|
// This line is inside the blockquote.
|
|
|
|
|
|
|
|
|
// skip spaces after ">" and re-calculate offset
|
|
|
// skip spaces after ">" and re-calculate offset
|
|
@ -2657,8 +2658,6 @@ module.exports = function blockquote(state, startLine, endLine, silent) { |
|
|
break; |
|
|
break; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
if (isOutdented) break; |
|
|
|
|
|
|
|
|
|
|
|
oldBMarks.push(state.bMarks[nextLine]); |
|
|
oldBMarks.push(state.bMarks[nextLine]); |
|
|
oldBSCount.push(state.bsCount[nextLine]); |
|
|
oldBSCount.push(state.bsCount[nextLine]); |
|
|
oldTShift.push(state.tShift[nextLine]); |
|
|
oldTShift.push(state.tShift[nextLine]); |
|
@ -3103,7 +3102,7 @@ module.exports = function lheading(state, startLine, endLine/*, silent*/) { |
|
|
var isSpace = require('../common/utils').isSpace; |
|
|
var isSpace = require('../common/utils').isSpace; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Search `[-+*][\n ]`, returns next pos arter marker on success
|
|
|
// Search `[-+*][\n ]`, returns next pos after marker on success
|
|
|
// or -1 on fail.
|
|
|
// or -1 on fail.
|
|
|
function skipBulletListMarker(state, startLine) { |
|
|
function skipBulletListMarker(state, startLine) { |
|
|
var marker, pos, max, ch; |
|
|
var marker, pos, max, ch; |
|
@ -3131,7 +3130,7 @@ function skipBulletListMarker(state, startLine) { |
|
|
return pos; |
|
|
return pos; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
// Search `\d+[.)][\n ]`, returns next pos arter marker on success
|
|
|
// Search `\d+[.)][\n ]`, returns next pos after marker on success
|
|
|
// or -1 on fail.
|
|
|
// or -1 on fail.
|
|
|
function skipOrderedListMarker(state, startLine) { |
|
|
function skipOrderedListMarker(state, startLine) { |
|
|
var ch, |
|
|
var ch, |
|
@ -3308,12 +3307,10 @@ module.exports = function list(state, startLine, endLine, silent) { |
|
|
while (pos < max) { |
|
|
while (pos < max) { |
|
|
ch = state.src.charCodeAt(pos); |
|
|
ch = state.src.charCodeAt(pos); |
|
|
|
|
|
|
|
|
if (isSpace(ch)) { |
|
|
|
|
|
if (ch === 0x09) { |
|
|
if (ch === 0x09) { |
|
|
offset += 4 - (offset + state.bsCount[nextLine]) % 4; |
|
|
offset += 4 - (offset + state.bsCount[nextLine]) % 4; |
|
|
} else { |
|
|
} else if (ch === 0x20) { |
|
|
offset++; |
|
|
offset++; |
|
|
} |
|
|
|
|
|
} else { |
|
|
} else { |
|
|
break; |
|
|
break; |
|
|
} |
|
|
} |
|
@ -3414,7 +3411,7 @@ module.exports = function list(state, startLine, endLine, silent) { |
|
|
if (markerCharCode !== state.src.charCodeAt(posAfterMarker - 1)) { break; } |
|
|
if (markerCharCode !== state.src.charCodeAt(posAfterMarker - 1)) { break; } |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
// Finilize list
|
|
|
// Finalize list
|
|
|
if (isOrdered) { |
|
|
if (isOrdered) { |
|
|
token = state.push('ordered_list_close', 'ol', -1); |
|
|
token = state.push('ordered_list_close', 'ol', -1); |
|
|
} else { |
|
|
} else { |
|
@ -4980,7 +4977,7 @@ module.exports = function entity(state, silent) { |
|
|
}; |
|
|
}; |
|
|
|
|
|
|
|
|
},{"../common/entities":1,"../common/utils":4}],42:[function(require,module,exports){ |
|
|
},{"../common/entities":1,"../common/utils":4}],42:[function(require,module,exports){ |
|
|
// Proceess escaped chars and hardbreaks
|
|
|
// Process escaped chars and hardbreaks
|
|
|
|
|
|
|
|
|
'use strict'; |
|
|
'use strict'; |
|
|
|
|
|
|
|
|